/* ============================================
   BACKDOOR COFFEE — Brand Styles
   Palette: Emerald (#064E3B) + Cream (#F5F0E8)
   Fonts: Playfair Display (headlines) + Inter (body)
   ============================================ */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --emerald-900: #042F23;
  --emerald-800: #064E3B;
  --emerald-700: #065F46;
  --emerald-600: #047857;
  --cream-50: #FAF8F4;
  --cream-100: #F5F0E8;
  --cream-200: #EDE5D5;
  --cream-300: #E0D5C0;
  --ink-900: #1A1A18;
  --ink-800: #2A2A26;
  --ink-700: #3D3D38;
  --ink-600: #5A5A54;
  --ink-500: #7A7A72;
  --white: #FFFFFF;
  --font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  font-weight: 400;
  line-height: 1.6;
  color: var(--ink-800);
  background-color: var(--cream-50);
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 2px solid transparent;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s var(--ease-out);
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.btn:active {
  transform: translateY(0);
}

.btn--light {
  background: var(--white);
  color: var(--emerald-800);
  border-color: var(--white);
}

.btn--light:hover {
  background: var(--cream-100);
  border-color: var(--cream-100);
}

.btn--outline-light {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.6);
}

.btn--outline-light:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--white);
}

.btn--dark {
  background: var(--ink-900);
  color: var(--cream-100);
  border-color: var(--ink-900);
}

.btn--dark:hover {
  background: var(--ink-700);
  border-color: var(--ink-700);
}

.btn--emerald {
  background: var(--emerald-800);
  color: var(--cream-100);
  border-color: var(--emerald-800);
}

.btn--emerald:hover {
  background: var(--emerald-700);
  border-color: var(--emerald-700);
}

.btn--outline-dark {
  background: transparent;
  color: var(--ink-800);
  border-color: var(--ink-800);
}

.btn--outline-dark:hover {
  background: var(--ink-800);
  color: var(--cream-100);
}

.btn--nav {
  padding: 10px 24px;
  font-size: 0.8125rem;
}

/* ============================================
   SECTION TYPOGRAPHY
   ============================================ */
.section-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--emerald-600);
  margin-bottom: 16px;
}

.section-headline {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 700;
  line-height: 1.1;
  color: var(--ink-900);
  margin-bottom: 24px;
}

.section-headline em {
  font-style: italic;
  color: var(--emerald-700);
}

.section-intro {
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink-600);
  max-width: 560px;
  margin-bottom: 48px;
}

/* ============================================
   HEADER / NAV
   ============================================ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(250, 248, 244, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--cream-200);
  transition: background 0.3s var(--ease-out);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--ink-900);
}

.logo-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--emerald-800);
  color: var(--cream-100);
  font-family: var(--font-serif);
  font-weight: 800;
  font-size: 1.125rem;
  border-radius: 6px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-links a:not(.btn) {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-700);
  letter-spacing: 0.02em;
  transition: color 0.2s ease;
  position: relative;
}

.nav-links a:not(.btn)::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--emerald-700);
  transition: width 0.3s var(--ease-out);
}

.nav-links a:not(.btn):hover {
  color: var(--emerald-800);
}

.nav-links a:not(.btn):hover::after {
  width: 100%;
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--ink-800);
  transition: all 0.3s var(--ease-out);
  transform-origin: center;
}

.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile overlay */
.nav-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: var(--cream-50);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s var(--ease-out);
}

.nav-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.nav-overlay-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
}

.nav-overlay a {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 600;
  color: var(--ink-900);
  transition: color 0.2s ease;
}

.nav-overlay a:hover {
  color: var(--emerald-700);
}

/* ============================================
   HERO
   ============================================ */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--emerald-900);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('https://images.pexels.com/photos/4906454/pexels-photo-4906454.jpeg?auto=compress&cs=tinysrgb&fit=crop&w=1920&h=1080');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(4, 47, 35, 0.72) 0%,
    rgba(4, 47, 35, 0.65) 50%,
    rgba(4, 47, 35, 0.82) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 820px;
  padding: 120px 24px 80px;
}

.hero-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cream-200);
  margin-bottom: 24px;
}

.hero-headline {
  font-family: var(--font-serif);
  font-size: clamp(2.75rem, 7vw, 5.5rem);
  font-weight: 700;
  line-height: 1.05;
  color: var(--white);
  margin-bottom: 28px;
  letter-spacing: -0.01em;
}

.hero-headline em {
  font-style: italic;
  color: var(--cream-200);
}

.hero-sub {
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1.65;
  color: var(--cream-200);
  max-width: 540px;
  margin: 0 auto 40px;
  font-weight: 300;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--cream-200);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0.7;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--cream-200), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; transform: scaleY(0.6); }
  50% { opacity: 1; transform: scaleY(1); }
}

/* ============================================
   MANIFESTO
   ============================================ */
.manifesto {
  background: var(--cream-100);
  padding: 80px 24px;
  border-bottom: 1px solid var(--cream-200);
}

.manifesto-text {
  font-family: var(--font-serif);
  font-size: clamp(1.25rem, 3vw, 1.75rem);
  line-height: 1.55;
  color: var(--ink-800);
  max-width: 860px;
  margin: 0 auto;
  text-align: center;
}

.manifesto-text strong {
  color: var(--emerald-700);
  font-weight: 600;
}

/* ============================================
   ABOUT
   ============================================ */
.about {
  padding: 120px 24px;
  background: var(--cream-50);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.about-image-wrap {
  overflow: hidden;
  border-radius: 8px;
  aspect-ratio: 4/5;
}

.about-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}

.about-image-wrap:hover img {
  transform: scale(1.03);
}

.about-content {
  max-width: 520px;
}

.about-content p {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--ink-600);
  margin-bottom: 16px;
}

.about-stats {
  display: flex;
  gap: 40px;
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--cream-200);
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-number {
  font-family: var(--font-serif);
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--ink-900);
}

.stat-label {
  font-size: 0.8125rem;
  color: var(--ink-500);
  letter-spacing: 0.03em;
}

/* ============================================
   MENU
   ============================================ */
.menu {
  padding: 120px 24px;
  background: var(--emerald-800);
}

.menu .section-eyebrow {
  color: var(--cream-200);
}

.menu .section-headline {
  color: var(--white);
}

.menu .section-headline em {
  color: var(--cream-200);
}

.menu .section-intro {
  color: var(--cream-200);
}

.menu-headline {
  text-align: center;
}

.menu .container:first-child {
  text-align: center;
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  margin-top: 0;
}

.menu-category {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 32px 28px;
  transition: background 0.3s ease, transform 0.3s var(--ease-out);
}

.menu-category:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-4px);
}

.category-label {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.menu-items {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.menu-items li {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.item-name {
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--cream-100);
  letter-spacing: 0.01em;
}

.item-desc {
  font-size: 0.8125rem;
  color: var(--cream-200);
  line-height: 1.5;
  font-weight: 300;
}

.menu-footer {
  padding-top: 48px;
}

.menu-note {
  font-size: 0.8125rem;
  color: var(--cream-200);
  text-align: center;
  line-height: 1.6;
  opacity: 0.7;
}

/* ============================================
   PHOTO BREAK
   ============================================ */
.photo-break {
  padding: 0;
  background: var(--cream-100);
}

.photo-break-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
}

.photo-break-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 5/4;
  transition: opacity 0.4s ease;
}

.photo-break-grid img:hover {
  opacity: 0.88;
}

/* ============================================
   SHOP
   ============================================ */
.shop {
  padding: 120px 24px;
  background: var(--cream-50);
}

.shop-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.shop-content {
  max-width: 520px;
}

.shop-content p {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--ink-600);
  margin-bottom: 16px;
}

.shop-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 28px 0 36px;
}

.shop-features li {
  font-size: 0.9375rem;
  color: var(--ink-700);
  padding-left: 20px;
  position: relative;
}

.shop-features li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  background: var(--emerald-700);
  border-radius: 50%;
}

.shop-image-wrap {
  overflow: hidden;
  border-radius: 8px;
  aspect-ratio: 11/13;
}

.shop-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}

.shop-image-wrap:hover img {
  transform: scale(1.03);
}

/* ============================================
   VISIT
   ============================================ */
.visit {
  padding: 120px 24px;
  background: var(--cream-100);
}

.visit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.visit-info {
  max-width: 480px;
}

.visit-address {
  font-style: normal;
  font-family: var(--font-serif);
  font-size: 1.25rem;
  line-height: 1.5;
  color: var(--ink-800);
  margin: 28px 0;
  padding: 24px;
  background: var(--cream-50);
  border-radius: 8px;
  border-left: 3px solid var(--emerald-700);
}

.visit-details {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 32px;
}

.detail {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.detail-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--emerald-600);
}

.detail a,
.detail span {
  font-size: 1rem;
  color: var(--ink-700);
  line-height: 1.6;
}

.detail a:hover {
  color: var(--emerald-700);
  text-decoration: underline;
}

.visit-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.visit-map {
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 4/3;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.visit-map iframe {
  width: 100%;
  height: 100%;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: var(--ink-900);
  padding: 48px 24px;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--cream-100);
}

.footer-copy {
  font-size: 0.875rem;
  color: var(--ink-500);
}

.footer-copy-small {
  font-size: 0.75rem;
  color: var(--ink-600);
}

/* ============================================
   SCROLL REVEAL (progressive enhancement)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
  }

  .reveal.visible {
    opacity: 1;
    transform: translateY(0);
  }

  .reveal-delay-1 { transition-delay: 0.1s; }
  .reveal-delay-2 { transition-delay: 0.2s; }
  .reveal-delay-3 { transition-delay: 0.3s; }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .menu-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .photo-break-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }

  .nav-toggle {
    display: flex;
  }

  .hero-content {
    padding: 100px 20px 80px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: center;
  }

  .about-grid,
  .shop-grid,
  .visit-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-image-wrap,
  .shop-image-wrap {
    aspect-ratio: 3/4;
  }

  .menu-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .photo-break-grid {
    grid-template-columns: 1fr 1fr;
  }

  .about-stats {
    gap: 24px;
  }

  .visit-cta {
    flex-direction: column;
  }

  .visit-cta .btn {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .hero-headline {
    font-size: clamp(2.25rem, 10vw, 3rem);
  }

  .manifesto {
    padding: 60px 16px;
  }

  .about,
  .menu,
  .shop,
  .visit {
    padding: 80px 16px;
  }

  .photo-break-grid {
    grid-template-columns: 1fr;
  }

  .about-stats {
    flex-direction: column;
    gap: 20px;
  }
}
