/* ============================================================
   New Ivory — Design System
   Editorial-clinical: Instrument Serif + Manrope on warm ivory
============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Instrument+Serif:ital@0;1&family=Manrope:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* Brand palette */
  --ivory: #F4EEE3;
  --ivory-2: #EDE5D5;
  --porcelain: #FFFFFF;
  --petrol: #0E4B52;
  --petrol-deep: #08323A;
  --petrol-soft: #1B6168;
  --champagne: #BE9A5E;
  --champagne-soft: #D9C19A;
  --charcoal: #1C2227;
  --slate: #5E6A73;
  --slate-soft: #98A2AA;
  --hairline: #D9D0BE;
  --success: #3E7C5A;
  --shadow-sm: 0 1px 2px rgba(28, 34, 39, 0.04), 0 1px 3px rgba(28, 34, 39, 0.06);
  --shadow-md: 0 8px 24px rgba(28, 34, 39, 0.08), 0 2px 6px rgba(28, 34, 39, 0.04);
  --shadow-lg: 0 24px 60px rgba(28, 34, 39, 0.12);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Manrope', system-ui, sans-serif;
  background: var(--ivory);
  color: var(--charcoal);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

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

button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

/* ---------- typography ---------- */

.serif { font-family: 'Instrument Serif', 'Times New Roman', serif; font-weight: 400; letter-spacing: -0.01em; }
.mono { font-family: 'JetBrains Mono', monospace; font-weight: 400; }

.eyebrow {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--petrol);
}

.eyebrow.gold { color: var(--champagne); }
.eyebrow.slate { color: var(--slate); }

h1, h2, h3, h4 { font-family: 'Instrument Serif', serif; font-weight: 400; letter-spacing: -0.015em; line-height: 1.05; color: var(--petrol-deep); }

.display { font-size: clamp(56px, 8vw, 128px); line-height: 0.96; letter-spacing: -0.02em; }
.display .italic { font-style: italic; color: var(--petrol); }
.display .gold { color: var(--champagne); font-style: italic; }

h2.section { font-size: clamp(40px, 5.5vw, 76px); line-height: 1.0; padding: 0; }
h3 { font-size: clamp(24px, 2.4vw, 32px); line-height: 1.15; }

p { color: var(--slate); }
.lede { font-size: 18px; line-height: 1.55; color: var(--charcoal); max-width: 56ch; }

/* ---------- layout ---------- */

.container { max-width: 1380px; padding: 0 32px; margin: 0 auto; }
@media (max-width: 720px) { .container { padding: 0 20px; } }

.section { padding: clamp(80px, 12vh, 140px) 0; }

.divider-line {
  display: flex; align-items: center; gap: 16px;
  font-family: 'JetBrains Mono', monospace; font-size: 11px;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--slate);
}
.divider-line::after { content: ''; flex: 1; height: 1px; background: var(--hairline); }
.divider-line.center::before { content: ''; flex: 1; height: 1px; background: var(--hairline); }

/* ---------- buttons ---------- */

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 16px 28px; font-size: 14px; font-weight: 500;
  letter-spacing: 0.01em; border-radius: 999px;
  transition: all 240ms cubic-bezier(.2,.7,.3,1);
  position: relative; white-space: nowrap;
}
.btn-primary { background: var(--petrol); color: var(--ivory); }
.btn-primary:hover { background: var(--petrol-deep); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-ghost { background: transparent; color: var(--petrol-deep); border: 1px solid var(--petrol-deep); }
.btn-ghost:hover { background: var(--petrol-deep); color: var(--ivory); }
.btn-gold { background: var(--champagne); color: var(--petrol-deep); }
.btn-gold:hover { background: #a98449; color: var(--ivory); }
.btn .arrow { display: inline-block; transition: transform 240ms; }
.btn:hover .arrow { transform: translateX(4px); }

/* ---------- nav ---------- */

.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 18px 0;
  transition: all 280ms ease;
  background: transparent;
}
.nav.scrolled {
  background: rgba(244, 238, 227, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--hairline);
  padding: 14px 0;
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.nav-logo { display: flex; align-items: center; gap: 10px; }
.nav-logo img { height: 28px; }
.nav-links { display: flex; align-items: center; gap: 28px; font-size: 14px; font-weight: 500; }
.nav-links a { color: var(--charcoal); position: relative; padding: 6px 0; transition: color 200ms; }
.nav-links a:hover { color: var(--petrol); }
.nav-links a.has-arrow::after { content: '↓'; font-size: 10px; margin-left: 4px; opacity: .5; }
.nav-cta { display: flex; align-items: center; gap: 10px; }
.nav-phone { font-family: 'JetBrains Mono', monospace; font-size: 13px; color: var(--charcoal); }

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

/* ---------- chips & badges ---------- */

.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px; font-size: 12px; font-weight: 500;
  background: rgba(255,255,255,0.7); border: 1px solid var(--hairline);
  border-radius: 999px; color: var(--charcoal);
  backdrop-filter: blur(8px);
}
.chip .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--success); }
.chip.dark { background: rgba(8, 50, 58, 0.5); color: var(--ivory); border-color: rgba(255,255,255,0.18); }
.chip.dark .dot { background: var(--champagne); }

.tag {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--petrol);
}
.tag::before { content: ''; width: 18px; height: 1px; background: var(--champagne); }

/* ---------- footer ---------- */

.footer {
  background: var(--petrol-deep); color: var(--ivory);
  padding: 100px 0 32px;
}
.footer h4 { color: var(--ivory); font-family: 'Instrument Serif', serif; font-size: 28px; margin-bottom: 16px; }
.footer .footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 56px; padding-bottom: 64px; border-bottom: 1px solid rgba(255,255,255,0.12); }
.footer .col-title { font-family: 'JetBrains Mono', monospace; font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--champagne-soft); margin-bottom: 20px; }
.footer ul { list-style: none; }
.footer li { padding: 6px 0; }
.footer li a { color: rgba(244, 238, 227, 0.72); font-size: 14px; transition: color 200ms; }
.footer li a:hover { color: var(--ivory); }
.footer .footer-bottom { display: flex; justify-content: space-between; padding-top: 32px; font-size: 12px; color: rgba(244, 238, 227, 0.5); font-family: 'JetBrains Mono', monospace; letter-spacing: 0.08em; }
.footer .footer-logo img { height: 38px; filter: brightness(0) invert(1); margin-bottom: 24px; }
.footer .footer-credit { color: rgba(244, 238, 227, 0.62); font-size: 14px; line-height: 1.7; max-width: 32ch; }

@media (max-width: 900px) { .footer .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; } }
@media (max-width: 600px) { .footer .footer-grid { grid-template-columns: 1fr; } .footer .footer-bottom { flex-direction: column; gap: 12px; } }

/* ---------- mobile bottom bar ---------- */

.mobile-bar { display: none; }
@media (max-width: 720px) {
  .mobile-bar {
    display: grid; grid-template-columns: 1fr 1fr 1.6fr;
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 100;
    background: var(--porcelain); border-top: 1px solid var(--hairline);
    box-shadow: 0 -4px 16px rgba(0,0,0,0.04);
  }
  .mobile-bar a {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    padding: 14px 8px; font-size: 13px; font-weight: 600;
    border-right: 1px solid var(--hairline);
  }
  .mobile-bar a:last-child { border-right: none; background: var(--petrol); color: var(--ivory); }
  body { padding-bottom: 56px; }
}

/* ---------- WhatsApp FAB ---------- */

.wa-fab {
  position: fixed; bottom: 28px; right: 28px; z-index: 90;
  width: 56px; height: 56px; border-radius: 50%;
  background: #25D366; color: white;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.4);
  transition: transform 240ms;
}
.wa-fab:hover { transform: scale(1.08); }
@media (max-width: 720px) { .wa-fab { bottom: 76px; right: 16px; width: 50px; height: 50px; } }

/* ---------- monogram tiles for missing dentist photos ---------- */
.monogram-tile {
  width: 100%; aspect-ratio: 3/4; background: linear-gradient(160deg, var(--petrol-deep), var(--petrol));
  display: flex; align-items: center; justify-content: center;
  color: var(--ivory); position: relative; overflow: hidden;
}
.monogram-tile::after {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 20%, rgba(190, 154, 94, 0.18), transparent 60%);
}
.monogram-tile .mono-letters {
  font-family: 'Instrument Serif', serif; font-size: 96px;
  letter-spacing: -0.04em; line-height: 1;
}
.monogram-tile .mono-label {
  position: absolute; bottom: 20px; left: 20px;
  font-family: 'JetBrains Mono', monospace; font-size: 10px;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--champagne-soft);
}

/* ---------- utility ---------- */

.fade-in { opacity: 1; transform: none; transition: opacity 800ms ease, transform 800ms ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

::selection { background: var(--petrol); color: var(--ivory); }
