/* ============================================================
   LANDMARK SURVEYS — shared design system
   Palette: survey navy + brass + warm paper + terracotta clay
   Type: Spectral (display serif) / Archivo (sans) / IBM Plex Mono (technical)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Spectral:ital,wght@0,400;0,500;0,600;0,700;1,400&family=Archivo:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500;600&family=Noto+Serif+Devanagari:wght@400;500;600;700&family=Noto+Sans+Devanagari:wght@400;500;600&display=swap');

:root {
  /* color */
  --paper:        #F4F0E7;
  --paper-deep:   #ECE5D6;
  --paper-card:   #FBF9F3;
  --ink:          #1B1A16;
  --ink-soft:     #514c41;
  --navy:         #142B3F;
  --navy-2:       #1C3A52;
  --navy-line:    #2c4a64;
  --brass:        #7E5F26;
  --brass-bright: #B8924A;
  --clay:         #B0512C;
  --clay-deep:    #97401F;
  --line:         rgba(27, 26, 22, 0.14);
  --line-strong:  rgba(27, 26, 22, 0.28);
  --paper-on-navy: #F4F0E7;

  /* type */
  --serif: 'Spectral', Georgia, serif;
  --sans:  'Archivo', system-ui, sans-serif;
  --mono:  'IBM Plex Mono', ui-monospace, monospace;

  /* spacing rhythm */
  --gut: clamp(20px, 5vw, 80px);
  --maxw: 1240px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
html, body { overflow-x: hidden; }

body {
  margin: 0;
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ---------- layout helpers ---------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gut); }
.section { padding-block: clamp(64px, 9vw, 140px); }
.cluster { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }

/* ---------- type ---------- */
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.05; margin: 0; letter-spacing: -0.01em; }
.display { font-size: clamp(2.7rem, 6.4vw, 5.2rem); font-weight: 600; line-height: 0.98; letter-spacing: -0.022em; }
h2.head { font-size: clamp(2rem, 4vw, 3.2rem); letter-spacing: -0.02em; }
h3 { font-size: clamp(1.3rem, 2vw, 1.7rem); }
p { margin: 0 0 1em; text-wrap: pretty; }
.lead { font-size: clamp(1.12rem, 1.6vw, 1.4rem); line-height: 1.55; color: var(--ink-soft); }

/* eyebrow / mono label */
.eyebrow {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brass);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 26px; height: 1px;
  background: var(--brass);
  display: inline-block;
}
.eyebrow.no-rule::before { display: none; }
.mono { font-family: var(--mono); }
.coord { font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.04em; color: var(--ink-soft); }

/* ---------- buttons ---------- */
.btn {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.96rem;
  letter-spacing: 0.01em;
  padding: 14px 26px;
  border-radius: 2px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .18s ease, background .2s ease, color .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--clay); color: #fff; }
.btn-primary:hover { background: var(--clay-deep); }
.btn-dark { background: var(--navy); color: var(--paper-on-navy); }
.btn-dark:hover { background: var(--navy-2); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--ink); background: rgba(27,26,22,0.04); }
.btn-on-navy { background: transparent; color: var(--paper-on-navy); border-color: rgba(244,240,231,0.4); }
.btn-on-navy:hover { border-color: var(--paper-on-navy); background: rgba(244,240,231,0.08); }
.btn .arrow { transition: transform .2s ease; }
.btn:hover .arrow { transform: translateX(4px); }

/* link with arrow */
.txtlink {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border-bottom: 1px solid var(--line-strong);
  padding-bottom: 3px;
  transition: gap .2s ease, border-color .2s ease, color .2s ease;
}
.txtlink:hover { gap: 14px; border-color: var(--clay); color: var(--clay); }

/* ---------- benchmark crosshair motif ---------- */
.benchmark { position: relative; }
.benchmark::before, .benchmark::after {
  content: ""; position: absolute; background: var(--brass);
}

/* grid-paper background */
.gridpaper {
  background-image:
    linear-gradient(rgba(27,26,22,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(27,26,22,0.05) 1px, transparent 1px);
  background-size: 30px 30px;
}
.gridpaper-navy {
  background-image:
    linear-gradient(rgba(244,240,231,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(244,240,231,0.06) 1px, transparent 1px);
  background-size: 34px 34px;
}

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(244,240,231,0.86);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .25s ease, background .25s ease;
}
.site-header.scrolled { box-shadow: 0 1px 0 var(--line), 0 14px 30px -22px rgba(20,43,63,0.5); }
.header-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gut);
  height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand { display: flex; align-items: center; gap: 13px; }
.brand-mark {
  width: 40px; height: 40px; flex: none; position: relative;
  border: 1.5px solid var(--navy); border-radius: 50%;
  display: grid; place-items: center;
}
.brand-mark::before, .brand-mark::after {
  content:""; position: absolute; background: var(--navy);
}
.brand-mark::before { width: 1.5px; height: 24px; }
.brand-mark::after { height: 1.5px; width: 24px; }
.brand-mark .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--clay); z-index: 1; }
.brand-name { display: flex; flex-direction: column; line-height: 1; }
.brand-name b { font-family: var(--serif); font-weight: 600; font-size: 1.18rem; letter-spacing: 0.005em; white-space: nowrap; }
.brand-name span { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-soft); margin-top: 6px; white-space: nowrap; }
.site-footer .brand-name span { color: var(--brass-bright); }

.nav { display: flex; align-items: center; gap: 26px; }
.nav a {
  font-size: 0.93rem; font-weight: 500; color: var(--ink-soft);
  position: relative; padding: 9px 0; transition: color .2s ease;
}
.nav a::after {
  content:""; position: absolute; left: 0; bottom: 0; width: 0; height: 1.5px;
  background: var(--clay); transition: width .22s ease;
}
.nav a:hover, .nav a.active { color: var(--ink); }
.nav a.active::after, .nav a:hover::after { width: 100%; }
.header-cta { display: flex; align-items: center; gap: 14px; }
.phone-link { display: inline-flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: 0.82rem; font-weight: 500; color: var(--ink); white-space: nowrap; }
.phone-link .ico { width: 15px; height: 15px; fill: var(--clay); }

.menu-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; min-width: 44px; min-height: 44px; place-items: center; }
.menu-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; transition: .25s; }
.menu-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle.open span:nth-child(2) { opacity: 0; }
.menu-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* mobile drawer */
.mobile-nav {
  position: fixed; inset: 76px 0 auto 0; z-index: 55;
  background: var(--paper); border-bottom: 1px solid var(--line);
  padding: 16px var(--gut) 28px; transform: translateY(-130%); transition: transform .32s cubic-bezier(.4,0,.1,1);
  display: flex; flex-direction: column; gap: 4px;
}
.mobile-nav.open { transform: translateY(0); }
.mobile-nav a { padding: 14px 4px; font-size: 1.15rem; font-family: var(--serif); border-bottom: 1px solid var(--line); }
.mobile-nav .btn { margin-top: 18px; justify-content: center; }

/* ---------- footer ---------- */
.site-footer { background: var(--navy); color: var(--paper-on-navy); }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; padding-block: clamp(56px, 7vw, 92px); }
.footer-top h4 { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--brass-bright); font-weight: 500; margin-bottom: 20px; }
.footer-top a, .footer-top p { color: rgba(244,240,231,0.78); font-size: 0.95rem; margin-bottom: 11px; display: block; transition: color .2s ease; }
.footer-top a:hover { color: #fff; }
.footer-brand .brand-name b { color: var(--paper-on-navy); }
.footer-blurb { color: rgba(244,240,231,0.62) !important; font-size: 0.92rem !important; line-height: 1.6; max-width: 32ch; margin-top: 18px; }
.footer-bottom { border-top: 1px solid var(--navy-line); padding-block: 26px; display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.footer-bottom p { margin: 0; color: rgba(244,240,231,0.66); font-family: var(--mono); font-size: 0.76rem; letter-spacing: 0.04em; }

/* CTA band */
.cta-band { background: var(--clay); color: #fff; position: relative; overflow: hidden; }
.cta-band .wrap { position: relative; z-index: 1; }
.cta-inner { display: flex; justify-content: space-between; align-items: center; gap: 40px; flex-wrap: wrap; }
.cta-inner h2 { color: #fff; font-size: clamp(1.9rem, 3.4vw, 3rem); max-width: 18ch; }
.cta-inner .lead { color: rgba(255,255,255,0.85); margin-top: 14px; max-width: 40ch; }
.cta-band .btn-dark { background: var(--navy); }
.cta-band .btn-light { background: #fff; color: var(--clay-deep); }
.cta-band .btn-light:hover { background: var(--paper); }


/* ---------- Marathi (lang="mr") ---------- */
html[lang="mr"] { --serif: 'Noto Serif Devanagari', 'Spectral', Georgia, serif; --sans: 'Noto Sans Devanagari', 'Archivo', system-ui, sans-serif; --mono: 'Noto Sans Devanagari', 'IBM Plex Mono', ui-monospace, monospace; }
html[lang="mr"] body { line-height: 1.78; }
html[lang="mr"] h1, html[lang="mr"] h2, html[lang="mr"] h3, html[lang="mr"] h4 { line-height: 1.34; letter-spacing: 0; }
html[lang="mr"] .display { line-height: 1.22; letter-spacing: 0; font-size: clamp(2.2rem, 5.2vw, 4.1rem); }
html[lang="mr"] .lead { line-height: 1.75; }
html[lang="mr"] :is(.eyebrow,.mono,.coord,.txtlink,.tag,.num,.pn,.il,.ix-num,.fp-subhead,.fp-flag,.detail-cap,.form-note,.cl-name,.trust-item,.crumbs,.ph-label,.hero-badge,.hero-badge b,.hero-coord,.map-coord,.footer-top h4,.brand-name span,.footer-bottom p,.field label,.hours span,.tl .yr.small,.hero-meta .mi > span,.legacy-stats .ls > span,.metrics-grid .m > span,.fp-meta .fm > span,.detail-tags span,.fp-tags span,.proc .pn,.ty-next,figcaption) { text-transform: none; letter-spacing: 0.015em; }
/* size floor — only for labels authored below 0.8rem, never a cap on larger text */
html[lang="mr"] :is(.eyebrow,.tag,.num,.pn,.il,.ix-num,.fp-subhead,.fp-flag,.detail-cap,.cl-name,.trust-item,.crumbs,.ph-label,.map-coord,.hero-coord,.footer-top h4,.brand-name span,.field label,.hero-meta .mi > span,.legacy-stats .ls > span,.metrics-grid .m > span,.fp-meta .fm > span,.detail-tags span,.fp-tags span,.proc .pn,.ty-next,.fp-journey figcaption) { font-size: 0.8rem; }
html[lang="mr"] .eyebrow { font-weight: 600; font-size: 0.84rem; }
html[lang="mr"] :is(.hero-meta .mi > span,.legacy-stats .ls > span,.metrics-grid .m > span) { font-size: 0.86rem; }
html[lang="mr"] :is(.txtlink,.footer-bottom p,.fp-table th,.form-note) { font-size: 0.86rem; }
html[lang="mr"] .lang-toggle button { font-size: 0.94rem; }
html[lang="mr"] .hero-badge { font-size: 0.72rem; line-height: 1.5; }
html[lang="mr"] .hero-badge b { font-size: 1.3rem; }
html[lang="mr"] .story-body p:first-child::first-letter { font-size: 1em; float: none; padding: 0; color: inherit; }

/* ---------- language toggle ---------- */
.lang-toggle { display: inline-flex; align-items: center; border: 1.5px solid var(--navy); border-radius: 3px; overflow: hidden; position: relative; background: var(--paper-card); flex: none; }
.lang-ico { width: 19px; height: 19px; margin: 0 3px 0 11px; stroke: var(--navy); fill: none; stroke-width: 1.6; flex: none; }
.lang-toggle button { font-family: var(--sans); font-size: 0.9rem; font-weight: 600; letter-spacing: 0; padding: 0 14px; height: 44px; background: transparent; color: var(--navy); border: 0; cursor: pointer; white-space: nowrap; transition: background .2s ease, color .2s ease; }
.lang-toggle button.on { background: var(--navy); color: var(--paper-on-navy); }
.lang-toggle button:not(.on):hover { background: rgba(20,43,63,0.08); }
.mobile-nav .lang-toggle { margin-top: 22px; width: 100%; }
.mobile-nav .lang-toggle button { flex: 1; height: 54px; font-size: 1.02rem; }
.lang-hint { position: absolute; top: calc(100% + 13px); right: 0; z-index: 70; background: var(--clay); color: #fff; font-family: var(--sans); font-size: 0.88rem; font-weight: 600; padding: 11px 15px; border-radius: 3px; box-shadow: 0 14px 26px -14px rgba(20,43,63,0.55); white-space: nowrap; animation: hintIn .45s ease both; }
.lang-hint::before { content: ""; position: absolute; top: -6px; right: 28px; width: 12px; height: 12px; background: var(--clay); transform: rotate(45deg); }
@keyframes hintIn { from { opacity: 0; transform: translateY(-7px); } to { opacity: 1; transform: none; } }
@media (max-width: 560px) { .brand-name span { display: none; } .lang-toggle button { padding: 0 11px; font-size: 0.86rem; } .lang-ico { display: none; } .lang-hint { font-size: 0.8rem; padding: 9px 12px; } }

/* ---------- survey frame + coordinate chip (used on every page) ---------- */
.hero-frame { position: absolute; inset: -1px; pointer-events: none; z-index: 2; }
.hero-frame span { position: absolute; width: 16px; height: 16px; border: 1.5px solid var(--brass); }
.hero-frame span:nth-child(1) { left: -6px; top: -6px; border-right: 0; border-bottom: 0; }
.hero-frame span:nth-child(2) { right: -6px; top: -6px; border-left: 0; border-bottom: 0; }
.hero-frame span:nth-child(3) { left: -6px; bottom: -6px; border-right: 0; border-top: 0; }
.hero-frame span:nth-child(4) { right: -6px; bottom: -6px; border-left: 0; border-top: 0; }
.hero-coord { position: absolute; left: 16px; bottom: 16px; z-index: 3; background: var(--navy); color: var(--paper-on-navy); font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.06em; padding: 9px 13px; display: flex; gap: 10px; align-items: center; }
.hero-coord .pulse { width: 7px; height: 7px; border-radius: 50%; flex: none; background: var(--clay); box-shadow: 0 0 0 0 rgba(176,81,44,.6); animation: pulse 2.2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(176,81,44,.6); } 70% { box-shadow: 0 0 0 9px rgba(176,81,44,0); } 100% { box-shadow: 0 0 0 0 rgba(176,81,44,0); } }
@media (prefers-reduced-motion: reduce) { .hero-coord .pulse { animation: none; } }

/* ---------- generic card ---------- */
.card { background: var(--paper-card); border: 1px solid var(--line); border-radius: 3px; }

/* ---------- image placeholder / slot ---------- */
/* image-slot[id] (0,1,1) beats the component's :host{height:160px} (0,1,0)
   so our width:100% + aspect-ratio rules actually drive the box. */
image-slot[id] { display: block; height: auto; --slot-bg: var(--paper-deep); }
.ph {
  background: var(--paper-deep);
  background-image: repeating-linear-gradient(135deg, rgba(20,43,63,0.07) 0 1px, transparent 1px 11px);
  border: 1px solid var(--line);
  display: grid; place-items: center;
  position: relative; overflow: hidden;
}
.ph .ph-label { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); background: var(--paper); padding: 6px 12px; border: 1px solid var(--line); }

/* ---------- scroll reveal (transform-only: stays visible even if transitions are frozen) ---------- */
.reveal { transform: translateY(22px); transition: transform .7s cubic-bezier(.2,.7,.2,1); will-change: transform; }
.reveal.in { transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- utility ---------- */
.on-navy { background: var(--navy); color: var(--paper-on-navy); }
.on-navy .eyebrow { color: var(--brass-bright); }
.on-navy .eyebrow::before { background: var(--brass-bright); }
.on-navy .lead { color: rgba(244,240,231,0.74); }
.divider { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ---------- responsive ---------- */
@media (max-width: 920px) {
  .footer-top { grid-template-columns: 1fr 1fr; gap: 36px 28px; }
}
@media (max-width: 1050px) {
  .header-cta .phone-link { display: none; }
  .nav { gap: 20px; }
}
@media (max-width: 980px) {
  .nav, .header-cta .btn { display: none; }
  .menu-toggle { display: grid; }
  .header-cta { gap: 4px; }
}
@media (max-width: 640px) {
  .header-inner { gap: 10px; height: 70px; }
  .brand-name b { font-size: 1.02rem; }
  .lang-toggle button { padding: 0 10px; font-size: 0.84rem; height: 42px; }
  .menu-toggle { padding: 6px; }
  .mobile-nav { inset-block-start: 70px; }
}
@media (max-width: 560px) {
  .footer-top { grid-template-columns: 1fr; }
  body { font-size: 16px; }
}
@media (max-width: 380px) {
  .brand-name b { font-size: 0.95rem; }
  .lang-toggle button { padding: 0 8px; font-size: 0.8rem; }
  html[lang="mr"] .lang-toggle button { font-size: 0.86rem; }
}
@media (max-width: 340px) {
  .header-inner { gap: 6px; padding-inline: 14px; }
  .brand-name b { font-size: 0.88rem; }
  .lang-toggle button { padding: 0 6px; font-size: 0.76rem; }
  html[lang="mr"] .lang-toggle button { font-size: 0.8rem; }
}
