/* ==========================================================================
   Posey Photo Co. — Complete Stylesheet (css/styles.css)
   Warm botanical minimalism harmonized with Posey-Photo-Co-Logo.png
   ========================================================================== */

:root {
  /* Core surfaces & inks */
  --bg-video: #FFFCF8;        /* Matches polished camera-intro.mp4 background exactly */
  --cream: #FAF8F5;
  --paper: #FFFFFF;
  --sand: #F1ECE3;
  --forest: #141D19;
  --ink: #1B2420;
  --muted: #616961;
  --line: rgba(27, 36, 32, 0.12);

  /* Accents sampled from Posey-Photo-Co-Logo.png */
  --teal: #1E4D54;
  --terracotta: #B85D3B;
  --marigold: #D99B26;
  --olive: #5D6B3C;
  --accent: var(--teal);

  /* Typography */
  --font-display: 'Boska', 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Switzer', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  /* Layout */
  --max-width: 1180px;
  --gutter: clamp(20px, 5vw, 64px);

  /* Exact Canon EOS R5 Mark II LCD overlay coordinates (% of 16:9 video frame) */
  --lcd-left: 29.0%;
  --lcd-top: 40.6%;
  --lcd-width: 33.3%;
  --lcd-height: 44.8%;
}

/* ---------- Reset & Base ---------- */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img, video {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

button {
  font-family: inherit;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.4rem, 5.2vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 3rem); }
h3 { font-size: 1.45rem; }

p {
  margin: 0 0 1em;
  max-width: 62ch;
}

:focus-visible {
  outline: 2px solid var(--marigold);
  outline-offset: 3px;
}

[hidden] {
  display: none !important;
}

/* ==========================================================================
   1. LANDING PAGE — CAMERA INTRO & INTERACTIVE LCD HUB (index.html)
   ========================================================================== */
.page-home {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg-video);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.home-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: clamp(16px, 2.5vw, 28px) clamp(20px, 3.5vw, 40px);
  pointer-events: none;
}

.home-brand {
  pointer-events: auto;
  text-decoration: none;
  display: inline-flex;
  align-items: baseline;
  gap: 0.55em;
  color: var(--ink);
}

.home-brand-main {
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 1.8vw, 1.35rem);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.home-brand-sub {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.home-controls {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 14px;
}

.home-pill-btn {
  appearance: none;
  background: rgba(255, 252, 248, 0.86);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(27, 36, 32, 0.16);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, opacity 0.3s ease;
}

.home-pill-btn:hover {
  background: var(--forest);
  border-color: var(--forest);
  color: var(--bg-video);
}

.stage {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-video);
  padding: 0;
}

.camera-frame {
  position: relative;
  width: min(100vw, 177.7778vh);
  aspect-ratio: 16 / 9;
  background: var(--bg-video);
  overflow: hidden;
}

.camera-end-poster,
.camera-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  user-select: none;
  pointer-events: none;
}

.camera-end-poster {
  z-index: 1;
}

.camera-video {
  z-index: 2;
  transition: opacity 0.45s ease;
}

.stage.is-lcd .camera-video {
  opacity: 0;
}

/* ---- Interactive LCD Screen Overlay ---- */
.lcd-screen {
  position: absolute;
  left: var(--lcd-left);
  top: var(--lcd-top);
  width: var(--lcd-width);
  height: var(--lcd-height);
  z-index: 5;
  container-type: inline-size;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 2.2% 2.6% 2.4%;
  border-radius: 3px;
  background: radial-gradient(ellipse at 30% 15%, rgba(28, 36, 32, 0.96) 0%, rgba(12, 16, 14, 0.98) 85%);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    inset 0 10px 28px rgba(0, 0, 0, 0.55);
  color: #F3EFE7;
  font-family: var(--font-mono);
  opacity: 0;
  visibility: hidden;
  transform: scale(0.985);
  transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.55s;
}

.stage.is-lcd .lcd-screen {
  opacity: 1;
  visibility: visible;
  transform: scale(1);
}

.lcd-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: clamp(9px, 2.3cqi, 12px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(243, 239, 231, 0.62);
  padding-bottom: 2cqi;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.lcd-status-left {
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  color: var(--marigold);
}

.lcd-dot {
  width: 0.55em;
  height: 0.55em;
  border-radius: 50%;
  background: #67C587;
  box-shadow: 0 0 8px rgba(103, 197, 135, 0.65);
}

.lcd-folders {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 2.2cqi;
  flex: 1;
  margin-top: 2.2cqi;
}

.lcd-folder {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 2.6cqi;
  width: 100%;
  height: 100%;
  padding: 2.4cqi 3.2cqi;
  text-decoration: none;
  text-align: left;
  color: #F7F4EE;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease, color 0.2s ease;
}

.lcd-folder:hover,
.lcd-folder:focus-visible {
  background: rgba(217, 155, 38, 0.18);
  border-color: var(--marigold);
  color: #FFFFFF;
  transform: translateY(-1px);
}

.lcd-folder--wide {
  grid-column: 1 / -1;
  justify-content: center;
  background: rgba(217, 155, 38, 0.11);
  border-color: rgba(217, 155, 38, 0.35);
}

.lcd-folder-icon {
  width: clamp(15px, 4.6cqi, 24px);
  height: clamp(15px, 4.6cqi, 24px);
  flex-shrink: 0;
  color: var(--marigold);
}

.lcd-folder-label {
  font-family: var(--font-mono);
  font-size: clamp(10px, 3.1cqi, 15px);
  font-weight: 500;
  letter-spacing: 0.06em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.home-hint {
  position: fixed;
  bottom: clamp(16px, 2.8vh, 28px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0;
  transition: opacity 0.6s ease 0.25s;
  pointer-events: none;
  white-space: nowrap;
}

.stage.is-lcd ~ .home-hint {
  opacity: 0.85;
}

/* Mobile Layout for Camera Home (< 760px):
   Keep camera clean at top, and show a spacious, tap-friendly LCD panel below */
@media (max-width: 760px) {
  .page-home {
    overflow-y: auto;
  }

  .stage {
    position: relative;
    inset: auto;
    min-height: 100dvh;
    flex-direction: column;
    justify-content: center;
    padding: 76px 16px 36px;
    gap: 18px;
  }

  .camera-frame {
    width: 100%;
    max-width: 560px;
    aspect-ratio: 16 / 9;
    overflow: visible;
    display: flex;
    flex-direction: column;
  }

  .camera-end-poster,
  .camera-video {
    position: relative;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    border-radius: 10px;
  }

  .camera-video {
    position: absolute;
    top: 0;
    left: 0;
  }

  .lcd-screen {
    position: relative;
    left: auto;
    top: auto;
    width: 100%;
    height: auto;
    margin-top: 14px;
    padding: 18px;
    border-radius: 12px;
    box-shadow: 0 18px 40px rgba(20, 29, 25, 0.14);
  }

  .lcd-status {
    font-size: 11px;
    padding-bottom: 12px;
  }

  .lcd-folders {
    margin-top: 14px;
    gap: 10px;
    grid-template-rows: auto;
  }

  .lcd-folder {
    padding: 14px 16px;
    gap: 10px;
  }

  .lcd-folder-icon {
    width: 18px;
    height: 18px;
  }

  .lcd-folder-label {
    font-size: 13px;
  }

  .home-hint {
    display: none;
  }
}

/* ==========================================================================
   2. SHARED NAVIGATION & LAYOUT (Subpages)
   ========================================================================== */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section {
  padding: clamp(64px, 9vw, 120px) 0;
}

.section--paper {
  background: var(--paper);
}

.section--sand {
  background: var(--sand);
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.9rem;
}

.lede {
  font-size: clamp(1.02rem, 1.3vw, 1.15rem);
  color: var(--muted);
  line-height: 1.7;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 248, 245, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 76px;
}

.wordmark {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  padding: 6px 12px 5px;
  border: 1px solid rgba(27, 36, 32, 0.28);
  color: var(--ink);
  line-height: 1;
  flex-shrink: 0;
}

.wordmark-main {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  padding-left: 0.22em;
}

.wordmark-sub {
  font-family: var(--font-mono);
  font-size: 0.52rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.2vw, 28px);
}

.nav-links a {
  text-decoration: none;
  font-size: 0.88rem;
  letter-spacing: 0.03em;
  color: var(--muted);
  padding: 4px 0;
  border-bottom: 1.5px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: var(--ink);
  border-color: var(--accent);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-toggle {
  display: none;
  appearance: none;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
  width: 40px;
  height: 40px;
  border-radius: 6px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

@media (max-width: 880px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    background: var(--cream);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: flex-start;
    padding: 18px var(--gutter) 24px;
    gap: 14px;
    box-shadow: 0 18px 36px rgba(20, 29, 25, 0.08);
  }

  .nav-links.is-open {
    display: flex;
  }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  padding: 0.9em 1.65em;
  background: var(--accent);
  color: #FFFFFF;
  border: 1px solid var(--accent);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.btn:hover {
  background: transparent;
  color: var(--accent);
}

.btn--sm {
  padding: 0.68em 1.15em;
  font-size: 0.74rem;
}

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: rgba(27, 36, 32, 0.35);
}

.btn--ghost:hover {
  background: var(--ink);
  color: var(--cream);
  border-color: var(--ink);
}

.link-subtle {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  color: var(--accent);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
  transition: opacity 0.2s ease;
}

.link-subtle:hover {
  opacity: 0.72;
}

/* ==========================================================================
   3. CATEGORY HEROES & MOODS
   ========================================================================== */
.theme-weddings { --accent: var(--teal); }
.theme-seniors  { --accent: var(--terracotta); }
.theme-branding { --accent: #1F352E; }
.theme-about    { --accent: var(--olive); }

.cat-hero {
  padding: clamp(52px, 7.5vw, 104px) 0 clamp(44px, 6vw, 84px);
}

.cat-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(32px, 6vw, 88px);
  align-items: center;
}

.cat-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 26px;
  margin-top: 28px;
}

.cat-hero-media {
  margin: 0;
  overflow: hidden;
  background: var(--sand);
  aspect-ratio: 4 / 5;
}

.cat-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.theme-weddings .cat-hero-media {
  border-radius: 50% 50% 0 0 / 16% 16% 0 0;
}

.theme-seniors .cat-hero {
  background: linear-gradient(180deg, #F6EBDC 0%, var(--cream) 100%);
}

.theme-seniors .cat-hero-media {
  border-radius: 16px;
}

.theme-branding .cat-hero-media {
  aspect-ratio: 1 / 1;
}

@media (max-width: 820px) {
  .cat-hero-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   4. CURATED GALLERIES & FULL-SCREEN LIGHTBOX
   ========================================================================== */
.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 32px;
  margin-bottom: clamp(32px, 5vw, 56px);
}

.section-head p {
  color: var(--muted);
  margin: 0;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 2.2vw, 28px);
}

.gallery-tile {
  appearance: none;
  border: 0;
  padding: 0;
  background: var(--sand);
  overflow: hidden;
  cursor: zoom-in;
  aspect-ratio: 4 / 5;
  position: relative;
}

.theme-weddings .gallery-tile:first-child {
  border-radius: 50% 50% 0 0 / 14% 14% 0 0;
}

.theme-seniors .gallery-tile {
  border-radius: 14px;
}

.theme-branding .gallery-tile {
  aspect-ratio: 1 / 1;
}

.gallery-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-tile:hover img {
  transform: scale(1.04);
}

@media (max-width: 720px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(14, 19, 17, 0.94);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(20px, 5vw, 60px);
}

.lightbox-img {
  max-width: 90vw;
  max-height: 82vh;
  object-fit: contain;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
}

.lightbox-btn {
  position: fixed;
  appearance: none;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.22);
  color: #FFFFFF;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1.2rem;
  transition: background 0.2s ease;
}

.lightbox-btn:hover {
  background: var(--marigold);
  border-color: var(--marigold);
  color: var(--forest);
}

.lightbox-close { top: 22px; right: 24px; }
.lightbox-prev  { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-next  { right: 20px; top: 50%; transform: translateY(-50%); }

.lightbox-counter {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  letter-spacing: 0.16em;
  color: rgba(255, 255, 255, 0.75);
}

/* ==========================================================================
   5. PRICING CARDS (Per Category)
   ========================================================================== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 2.5vw, 28px);
}

.price-card {
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border: 1px solid var(--line);
  padding: clamp(26px, 3vw, 38px);
}

.price-card.is-featured {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
}

.price-tag {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.price-amount {
  font-family: var(--font-display);
  font-size: 2.5rem;
  line-height: 1;
  margin: 10px 0 14px;
  color: var(--ink);
}

.price-amount small {
  font-family: var(--font-body);
  font-size: 0.82rem;
  color: var(--muted);
  margin-left: 6px;
}

.price-summary {
  color: var(--muted);
  font-size: 0.94rem;
  margin-bottom: 20px;
}

.price-list {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: grid;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--ink);
}

.price-list li {
  display: flex;
  gap: 10px;
  align-items: baseline;
}

.price-list li::before {
  content: "—";
  color: var(--accent);
  flex-shrink: 0;
}

.price-card .btn {
  margin-top: auto;
  width: 100%;
}

@media (max-width: 900px) {
  .pricing-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   6. ABOUT PAGE & CTA BAND
   ========================================================================== */
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(32px, 6vw, 92px);
  align-items: start;
}

.about-portrait {
  margin: 0;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: var(--sand);
}

.about-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.values-list {
  display: grid;
  gap: 24px;
  margin: 34px 0;
}

.value-item {
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.value-item h3 {
  font-size: 1.3rem;
  margin-bottom: 6px;
}

.value-item p {
  color: var(--muted);
  margin: 0;
  font-size: 0.95rem;
}

@media (max-width: 820px) {
  .about-grid {
    grid-template-columns: 1fr;
  }
}

.cta-band {
  text-align: center;
}

.cta-band p {
  margin: 0 auto 28px;
  color: var(--muted);
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

/* ==========================================================================
   7. FOOTER (Showcasing Posey-Photo-Co-Logo.png on Dark Forest Background)
   ========================================================================== */
.site-footer {
  background: var(--forest);
  color: #EAE4D7;
  padding: clamp(56px, 8vw, 92px) 0 36px;
  text-align: center;
}

.footer-logo {
  width: min(210px, 56vw);
  margin: 0 auto 28px;
  border-radius: 6px;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px 28px;
}

.footer-links a,
.footer-links button {
  background: none;
  border: 0;
  padding: 0;
  color: #EAE4D7;
  text-decoration: none;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.2s ease;
}

.footer-links a:hover,
.footer-links button:hover {
  color: var(--marigold);
}

.footer-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: rgba(234, 228, 215, 0.58);
  margin: 0 auto;
}

/* ==========================================================================
   8. BOTTOM-RIGHT CONTACT POPUP WIDGET (Shared Across All Pages)
   ========================================================================== */
.contact-popup {
  position: fixed;
  right: clamp(14px, 2.5vw, 28px);
  bottom: clamp(14px, 2.5vw, 28px);
  z-index: 150;
  width: min(380px, calc(100vw - 28px));
  background: var(--paper);
  color: var(--ink);
  border: 1px solid rgba(27, 36, 32, 0.15);
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(20, 29, 25, 0.22);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform-origin: bottom right;
  animation: popup-in 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes popup-in {
  from { opacity: 0; transform: translateY(14px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.contact-head {
  background: var(--forest);
  color: #F5F1E8;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.contact-head-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.contact-online-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #67C587;
  box-shadow: 0 0 0 3px rgba(103, 197, 135, 0.22);
  flex-shrink: 0;
}

.contact-head strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  line-height: 1.1;
}

.contact-head small {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  color: rgba(245, 241, 232, 0.68);
  margin-top: 2px;
}

.contact-close {
  appearance: none;
  background: rgba(255, 255, 255, 0.1);
  border: 0;
  color: #F5F1E8;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.contact-close:hover {
  background: rgba(255, 255, 255, 0.22);
}

.contact-body {
  padding: 18px;
  max-height: min(72vh, 470px);
  overflow-y: auto;
}

.contact-bubble {
  background: var(--sand);
  color: var(--ink);
  padding: 12px 14px;
  border-radius: 12px 12px 12px 4px;
  font-size: 0.92rem;
  line-height: 1.5;
  margin-bottom: 16px;
}

.contact-choices {
  display: grid;
  gap: 10px;
}

.contact-choice-btn {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 14px 16px;
  background: var(--paper);
  border: 1px solid rgba(27, 36, 32, 0.18);
  border-radius: 10px;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.15s ease;
}

.contact-choice-btn:hover {
  border-color: var(--teal);
  background: #F6F4EF;
  transform: translateY(-1px);
}

.contact-choice-btn strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
}

.contact-choice-btn span {
  display: block;
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 2px;
}

.contact-choice-arrow {
  font-family: var(--font-mono);
  color: var(--teal);
  font-size: 1rem;
}

.contact-back {
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  margin-bottom: 12px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  cursor: pointer;
}

.contact-back:hover {
  color: var(--ink);
}

/* Email Form View */
.contact-form {
  display: grid;
  gap: 10px;
}

.contact-form label {
  display: block;
  font-size: 0.76rem;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 4px;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid rgba(27, 36, 32, 0.2);
  border-radius: 8px;
  background: var(--cream);
  color: var(--ink);
  font-family: inherit;
  font-size: 0.9rem;
}

.contact-form textarea {
  min-height: 82px;
  resize: vertical;
}

.contact-status {
  padding: 14px;
  border-radius: 10px;
  background: #EDF4EE;
  color: #1F472A;
  font-size: 0.88rem;
  line-height: 1.5;
}

/* Live Chat View */
.chat-thread {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 190px;
  max-height: 240px;
  overflow-y: auto;
  padding-right: 4px;
  margin-bottom: 12px;
}

.chat-msg {
  max-width: 85%;
  padding: 10px 13px;
  border-radius: 12px;
  font-size: 0.88rem;
  line-height: 1.45;
}

.chat-msg--in {
  align-self: flex-start;
  background: var(--sand);
  color: var(--ink);
  border-bottom-left-radius: 4px;
}

.chat-msg--out {
  align-self: flex-end;
  background: var(--forest);
  color: #FAF8F5;
  border-bottom-right-radius: 4px;
}

.chat-composer {
  display: flex;
  gap: 8px;
}

.chat-composer input {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid rgba(27, 36, 32, 0.2);
  border-radius: 999px;
  background: var(--cream);
  color: var(--ink);
  font-family: inherit;
  font-size: 0.88rem;
}

.chat-composer button {
  appearance: none;
  background: var(--forest);
  color: #FAF8F5;
  border: 0;
  border-radius: 999px;
  padding: 0 16px;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
}

.chat-note {
  margin-top: 8px;
  font-size: 0.72rem;
  color: var(--muted);
}
