/* ============================================================
   Кофейня «Утро» — улучшенное оформление (демо-пример Neobrain)
   ============================================================ */

/* Сброс и базовые стили */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --primary: #6d4c41;
  --primary-dark: #4e342e;
  --secondary: #8d6e63;
  --accent: #ffb74d;
  --accent-dark: #f59e0b;
  --bg: #faf3e8;
  --bg-soft: #fff8ee;
  --text: #3e2723;
  --white: #fff;
  --shadow: rgba(62, 39, 35, 0.12);
  --shadow-lg: rgba(62, 39, 35, 0.18);
  --radius: 18px;
  --transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Georgia', 'Times New Roman', 'Palatino Linotype', serif;
  background:
    radial-gradient(circle at 15% 20%, rgba(255, 183, 77, 0.08), transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(109, 76, 65, 0.06), transparent 45%),
    var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

img { max-width: 100%; display: block; }

a { transition: var(--transition); }

/* ---------- Пометка «демо» ---------- */
.demo-ribbon {
  position: sticky;
  top: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  flex-wrap: wrap;
  padding: 0.55rem 1rem;
  background: linear-gradient(90deg, #111827, #1f2937);
  color: #f3f4f6;
  font: 0.92rem/1.4 -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.25);
}

.demo-ribbon a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px dashed rgba(255, 183, 77, 0.6);
  white-space: nowrap;
}

.demo-ribbon a:hover { color: #ffd59e; }

/* ---------- Шапка ---------- */
.header {
  background: rgba(78, 52, 46, 0.97);
  backdrop-filter: blur(8px);
  padding: 1rem 0;
  position: sticky;
  top: 42px; /* ниже ленты «демо» */
  z-index: 100;
  box-shadow: 0 4px 20px var(--shadow);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--white);
  font-weight: bold;
  font-size: 1.25rem;
  letter-spacing: 0.02em;
}

.logo__icon {
  font-size: 2rem;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
  transition: var(--transition);
}

.logo:hover .logo__icon { transform: rotate(-12deg) scale(1.08); }

.nav {
  display: flex;
  gap: 2.2rem;
}

.nav a {
  color: rgba(255, 255, 255, 0.92);
  text-decoration: none;
  font-size: 1.02rem;
  position: relative;
  padding: 0.25rem 0;
  transition: color 0.3s;
}

.nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
  transition: width 0.3s;
}

.nav a:hover { color: var(--white); }
.nav a:hover::after { width: 100%; }

.burger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 6px;
}

.burger span {
  width: 26px;
  height: 3px;
  background: var(--white);
  border-radius: 3px;
  transition: var(--transition);
}

.burger.active span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.burger.active span:nth-child(2) { opacity: 0; }
.burger.active span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- Герой ---------- */
.hero {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--white);
  padding: 6rem 0;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  transform: scale(1.02);
}

.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(40, 25, 20, 0.55), rgba(40, 25, 20, 0.72)),
    radial-gradient(ellipse at 50% 0%, rgba(109, 76, 65, 0.35), transparent 65%);
}

.hero__inner { position: relative; z-index: 2; }

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.32);
  backdrop-filter: blur(4px);
  padding: 0.45rem 1.1rem;
  border-radius: 999px;
  font-size: 0.92rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  color: #ffe0b2;
}

.hero h1 {
  font-size: 3.1rem;
  margin-bottom: 1rem;
  line-height: 1.15;
  text-shadow: 0 3px 18px rgba(0, 0, 0, 0.45);
}

.hero p {
  font-size: 1.22rem;
  margin-bottom: 2.4rem;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
  color: rgba(255, 255, 255, 0.95);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.4);
}

.hero__cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  color: var(--primary-dark);
  padding: 0.85rem 2.2rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.05rem;
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.35);
  transition: var(--transition);
}

.btn:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 12px 32px rgba(245, 158, 11, 0.45);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.14);
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  color: var(--white);
  box-shadow: none;
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.22);
  box-shadow: none;
}

/* ---------- Секции ---------- */
.section {
  padding: 4rem 0;
}

.section-title {
  text-align: center;
  font-size: 2.1rem;
  margin-bottom: 0.5rem;
  color: var(--primary);
}

.section-sub {
  text-align: center;
  color: var(--secondary);
  margin-bottom: 2.6rem;
  font-size: 1.05rem;
}

/* ---------- Преимущества ---------- */
.features { padding-top: 3rem; }

.features__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.8rem;
}

.feature {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.9rem 1.6rem;
  text-align: center;
  border: 1px solid rgba(109, 76, 65, 0.08);
  box-shadow: 0 6px 20px var(--shadow);
  transition: var(--transition);
}

.feature:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 36px var(--shadow-lg);
  border-color: rgba(255, 183, 77, 0.5);
}

.feature__icon {
  font-size: 2.6rem;
  line-height: 1;
  margin-bottom: 0.8rem;
  display: inline-block;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.12));
  transition: var(--transition);
}

.feature:hover .feature__icon { transform: scale(1.12) rotate(-4deg); }

.feature h3 {
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

.feature p {
  color: #6b5a52;
  font-size: 0.97rem;
}

/* ---------- Меню ---------- */
.menu__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.8rem;
}

.menu-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.8rem 1.6rem;
  text-align: center;
  border: 1px solid rgba(109, 76, 65, 0.08);
  box-shadow: 0 6px 20px var(--shadow);
  transition: var(--transition);
  position: relative;
}

.menu-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 36px var(--shadow-lg);
  border-color: rgba(255, 183, 77, 0.5);
}

.menu-card .menu-icon {
  font-size: 2.8rem;
  line-height: 1;
  margin-bottom: 0.8rem;
  display: inline-block;
  filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.12));
  transition: var(--transition);
}

.menu-card:hover .menu-icon { transform: scale(1.12) rotate(-4deg); }

.menu-card h3 {
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
}

.menu-card p {
  margin-bottom: 1rem;
  color: #6b5a52;
  font-size: 0.98rem;
}

.menu-card .price {
  font-weight: bold;
  color: var(--secondary);
  font-size: 1.25rem;
}

/* ---------- Галерея ---------- */
.gallery__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.4rem;
}

.gallery__item {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: 0 8px 24px var(--shadow);
  transition: var(--transition);
  cursor: zoom-in;
}

.gallery__item:hover {
  transform: translateY(-6px) scale(1.015);
  box-shadow: 0 18px 40px var(--shadow-lg);
}

/* ---------- О нас ---------- */
.about__inner {
  display: flex;
  align-items: center;
  gap: 3rem;
  flex-wrap: wrap;
}

.about__text {
  flex: 1;
  min-width: 280px;
}

.about__text p {
  margin-bottom: 1rem;
  color: #57453d;
}

.about__text .btn { margin-top: 0.6rem; }

.about__img {
  flex: 1;
  min-width: 280px;
  max-width: 460px;
  width: 100%;
  height: 340px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: 0 14px 40px var(--shadow-lg);
  border: 6px solid var(--white);
}

/* ---------- Контакты ---------- */
.contacts__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.8rem;
}

.contact-card {
  background: var(--bg-soft);
  padding: 1.8rem 1.4rem;
  border-radius: var(--radius);
  text-align: center;
  border: 1px solid rgba(109, 76, 65, 0.1);
  box-shadow: 0 6px 20px var(--shadow);
  transition: var(--transition);
}

.contact-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 14px 32px var(--shadow-lg);
}

.contact-card .contact-icon {
  font-size: 2rem;
  margin-bottom: 0.6rem;
  display: block;
}

.contact-card h3 {
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.contact-card a {
  color: var(--secondary);
  text-decoration: none;
  border-bottom: 1px dotted rgba(141, 110, 99, 0.5);
  transition: color 0.3s;
}

.contact-card a:hover { color: var(--accent-dark); }

/* ---------- Подвал ---------- */
.footer {
  background: var(--primary-dark);
  color: rgba(255, 255, 255, 0.9);
  text-align: center;
  padding: 2rem 0;
}

.footer p { margin-bottom: 0.25rem; }
.footer .footer-note {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.6);
}

.footer .footer-note a {
  color: var(--accent);
  text-decoration: none;
}

.footer .footer-note a:hover { text-decoration: underline; }

/* ---------- Анимация появления ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Лайтбокс галереи ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(20, 12, 8, 0.88);
  backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  padding: 2rem;
}
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox img {
  max-width: 92vw;
  max-height: 88vh;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}
.lightbox__close {
  position: absolute; top: 18px; right: 22px;
  width: 46px; height: 46px; border: none; border-radius: 50%;
  background: rgba(255, 255, 255, 0.16); color: #fff;
  font-size: 1.8rem; line-height: 1; cursor: pointer; transition: background 0.3s;
}
.lightbox__close:hover { background: rgba(255, 255, 255, 0.3); }

/* ---------- Адаптив ---------- */
@media (max-width: 768px) {
  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--primary-dark);
    flex-direction: column;
    align-items: center;
    gap: 1.1rem;
    padding: 1.4rem 1rem;
    display: none;
    box-shadow: 0 12px 30px var(--shadow-lg);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
  }

  .nav.open { display: flex; }

  .nav a::after { display: none; }

  .burger { display: flex; }

  .hero { min-height: 60vh; padding: 3.5rem 0 4rem; }
  .hero h1 { font-size: 2.1rem; }
  .hero p { font-size: 1.08rem; }

  .about__inner {
    flex-direction: column;
    text-align: center;
  }

  .section-title { font-size: 1.8rem; }

  .demo-ribbon { font-size: 0.82rem; gap: 0.6rem; }
}

@media (max-width: 480px) {
  .container { padding: 0 14px; }
  .hero { min-height: 55vh; padding: 2.6rem 0 3.2rem; }
  .section { padding: 2.8rem 0; }
  .gallery__item { height: 200px; }
  .about__img { height: 250px; }
}
