/* ============================================================
   ANANT GROUP OF COMPANIES — anantgroupofcompanies.com
   Design language: off-white & maroon. Light gallery walls,
   one deep maroon accent throughout.
   Type: Marcellus (engraved headers) · Lora (soft reading)
         · Cinzel (engraved labels)
   ============================================================ */

:root {
  /* Off-white surfaces, maroon reserved for the accent.
     Variable names kept from earlier versions for stability:
     "paper" = surfaces, "ink" = reading colour, "maroon" = accent */
  --velvet: #200E13;        /* the one dark room — footer */
  --paper: #F8F5F0;         /* main background — off-white */
  --paper-deep: #EFEAE2;    /* raised sections */
  --paper-dim: #E4DDD0;     /* inner surfaces of frames */

  --maroon: #7C2430;        /* the accent — deep quiet wine */
  --maroon-soft: #A8434F;   /* claret — glows and fills */

  --ink: #4A0F17;           /* deep maroon for reading */
  --ink-soft: #7A3540;      /* muted maroon secondary */
  --ink-faint: #A6767C;     /* whispers */

  /* light text, used only inside the dark (velvet/footer) section */
  --ink-on-dark: #F8F5F0;
  --ink-on-dark-soft: #CDBBB7;
  --ink-on-dark-faint: #9C8683;

  --hairline: rgba(38, 34, 32, 0.16);
  --hairline-soft: rgba(38, 34, 32, 0.08);

  --max: 1240px;
  --gutter: clamp(20px, 5vw, 72px);

  /* ---- premium motion system ---- */
  --ease: cubic-bezier(0.16, 1, 0.3, 1);       /* expo-out — Apple-style settle */
  --ease-soft: cubic-bezier(0.22, 1, 0.36, 1); /* gentler, for hovers */
  --dur-fast: 0.35s;
  --dur-base: 0.6s;
  --dur-slow: 0.9s;

  --shadow-sm: 0 2px 10px rgba(32, 14, 19, 0.05);
  --shadow-md: 0 14px 34px rgba(32, 14, 19, 0.09);
  --shadow-lg: 0 26px 60px rgba(32, 14, 19, 0.14);
  --shadow-maroon: 0 14px 30px rgba(124, 36, 48, 0.18);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: "Lora", Georgia, serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.75;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* subtle grain — old paper in low light */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0.92 0 0 0 0 0.88 0 0 0 0 0.87 0 0 0 0.022 0'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}

::selection { background: var(--maroon); color: var(--paper); }

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

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

.label {
  font-family: "Cinzel", serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.label--oxide { color: var(--maroon); }

/* signature display type — cursive has no caps-lock voice, no italics */
.display {
  font-family: "Marcellus", serif;
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: 0.01em;
  color: var(--ink);
}

.display em, h1 em, h2 em, h3 em { font-style: italic; }
/* em inside Marcellus headers: render in Lora italic for a true italic */
h1 em, h2 em, .display em {
  font-family: "Lora", serif;
  font-style: italic;
  font-weight: 500;
}


.lede {
  font-size: clamp(19px, 2.2vw, 25px);
  line-height: 1.6;
  font-weight: 400;
}

.lede em { font-style: italic; }

.small-note {
  font-size: 14.5px;
  color: var(--ink-soft);
  font-style: italic;
}

.devanagari, .wordmark__dev {
  font-family: "Tiro Devanagari Sanskrit", serif;
}

/* engraved initial for letters/essays — sized to span exactly 3 text lines
   (body: 18px font-size × 1.75 line-height = 31.5px per line;
   3 lines = 94.5px ÷ 0.9 first-letter line-height = 5.833em) */
.dropcap::first-letter {
  font-family: "Cinzel", serif;
  float: left;
  font-size: 5.833em;
  line-height: 0.9;
  padding: 0.06em 0.16em 0 0;
  color: var(--maroon);
  font-weight: 500;
}

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

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.section { padding: clamp(72px, 10vw, 140px) 0; }
.section--tight { padding: clamp(48px, 7vw, 96px) 0; }

.section--deep {
  background: var(--paper-deep);
  border-top: 1px solid var(--hairline-soft);
  border-bottom: 1px solid var(--hairline-soft);
}

/* velvet — the darkest maroon drawing room */
.section--velvet {
  background: var(--velvet);
  border-top: 1px solid var(--hairline-soft);
  border-bottom: 1px solid var(--hairline-soft);
  color: var(--ink-on-dark);
}

.section--velvet .label { color: var(--maroon-soft); }
.section--velvet .pullquote { color: var(--ink-on-dark); }
.section--velvet .small-note { color: var(--ink-on-dark-soft); }
.section--velvet .display { color: var(--ink-on-dark); }

.section--velvet .btn--oxide {
  border-color: var(--maroon-soft);
  color: var(--ink-on-dark);
}

.section--velvet .btn--oxide:hover {
  background: var(--maroon);
  border-color: var(--maroon);
  color: #F7EEEC;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35);
}

.rule {
  border: 0;
  border-top: 1px solid var(--hairline);
  margin: 0;
}

.chapter-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--hairline);
  margin-bottom: clamp(36px, 5vw, 64px);
}

/* ---------- top bar ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 90%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--hairline-soft);
  box-shadow: 0 0 0 rgba(32, 14, 19, 0);
  transition: box-shadow var(--dur-base) var(--ease), background var(--dur-base) var(--ease);
}

.topbar.is-scrolled {
  background: color-mix(in srgb, var(--paper) 96%, transparent);
  box-shadow: var(--shadow-sm);
}

.topbar__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 16px var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.wordmark {
  text-decoration: none;
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.wordmark__main {
  font-family: "Cinzel", serif;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-indent: 0.32em;
  color: var(--ink);
}

.wordmark__dev {
  font-size: 14px;
  color: var(--maroon);
}

.nav {
  display: flex;
  gap: clamp(16px, 3vw, 36px);
}

.nav a {
  position: relative;
  font-family: "Cinzel", serif;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink-soft);
  padding-bottom: 3px;
  transition: color var(--dur-fast) var(--ease-soft);
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--dur-fast) var(--ease);
}

.nav a:hover { color: var(--ink); }
.nav a:hover::after { transform: scaleX(1); }
.nav a.is-active { color: var(--maroon); }
.nav a.is-active::after { transform: scaleX(1); }

/* mobile nav */
.nav-toggle { display: none; }

@media (max-width: 760px) {
  .nav {
    position: fixed;
    inset: 57px 0 auto 0;
    background: var(--paper);
    border-bottom: 1px solid var(--hairline);
    flex-direction: column;
    padding: 24px var(--gutter) 32px;
    gap: 20px;
    transform: translateY(-130%);
    transition: transform 0.35s ease;
  }
  .nav.is-open { transform: translateY(0); }
  .nav-toggle {
    display: block;
    background: none;
    border: 0;
    font-family: "Cinzel", serif;
    font-size: 10.5px;
    font-weight: 500;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--ink);
    cursor: pointer;
    padding: 6px 0;
  }
}

/* ---------- hero (dictionary entry) ---------- */

.hero {
  padding: clamp(80px, 12vw, 170px) 0 clamp(60px, 9vw, 120px);
}

.hero .label { font-size: 13px; }

/* staggered cascade — label, then headline, then copy, then CTAs */
.hero .wrap > .reveal:nth-child(1) { transition-delay: 0s; }
.hero .wrap > .reveal:nth-child(2) { transition-delay: 0.12s; }
.hero .wrap > .reveal:nth-child(3) { transition-delay: 0.24s; }
.hero .wrap > .reveal:nth-child(4) { transition-delay: 0.36s; }

.hero__entry {
  font-family: "Marcellus", serif;
  font-size: clamp(53px, 8.55vw, 125px);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: 0.01em;
  color: var(--ink);
  overflow: hidden;
  padding-top: 0.1em;
  padding-bottom: 0.04em;
}

.hero__entry span {
  display: inline-block;
  opacity: 0;
  transform: translateY(55px) scale(0.96);
  animation: heroWordIn 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes heroWordIn {
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.hero__entry span:nth-child(1)  { animation-delay: 0s; }
.hero__entry span:nth-child(2)  { animation-delay: 0.045s; }
.hero__entry span:nth-child(3)  { animation-delay: 0.09s; }
.hero__entry span:nth-child(4)  { animation-delay: 0.135s; }
.hero__entry span:nth-child(5)  { animation-delay: 0.18s; }
.hero__entry span:nth-child(6)  { animation-delay: 0.225s; }
.hero__entry span:nth-child(7)  { animation-delay: 0.27s; }
.hero__entry span:nth-child(8)  { animation-delay: 0.315s; }
.hero__entry span:nth-child(9)  { animation-delay: 0.36s; }
.hero__entry span:nth-child(10) { animation-delay: 0.405s; }

@media (prefers-reduced-motion: reduce) {
  .hero__entry span { opacity: 1; transform: none; animation: none; }
}

.hero__phonetic {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 14px 22px;
  margin: 20px 0 34px;
  font-size: clamp(16px, 1.8vw, 20px);
  color: var(--ink-soft);
}

.hero__phonetic .devanagari {
  font-size: 1.25em;
  color: var(--maroon);
}

.hero__definition {
  max-width: 640px;
  font-size: clamp(19px, 2vw, 23px);
  line-height: 1.6;
}

/* ---------- oval placeholder frames (photography to come) ---------- */

.frame {
  position: relative;
  background: linear-gradient(160deg, var(--paper-dim), var(--paper-deep));
  border: 1px solid var(--hairline);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.frame--tall { aspect-ratio: 3 / 4; }
.frame--wide { aspect-ratio: 16 / 10; }
.frame--square { aspect-ratio: 1; }

.frame__oval {
  width: 56%;
  max-width: 260px;
  aspect-ratio: 3 / 4;
  border: 1px solid var(--hairline);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8%;
  text-align: center;
}

.frame__monogram {
  font-family: "Marcellus", serif;
  font-size: clamp(38px, 5vw, 60px);
  font-weight: 400;
  line-height: 1;
  color: var(--maroon);
}

.frame__caption {
  font-family: "Cinzel", serif;
  font-size: 8.5px;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink-faint);
}

figcaption {
  margin-top: 12px;
  font-size: 14.5px;
  font-style: italic;
  color: var(--ink-soft);
}

/* ---------- letter block ---------- */

.letter {
  max-width: 720px;
  margin: 0 auto;
}

.letter p { margin-bottom: 1.4em; font-size: clamp(18px, 1.8vw, 20px); }

.letter__signoff {
  margin-top: 2em;
  font-family: "Lora", serif;
  font-style: italic;
  font-size: 22px;
  line-height: 1.4;
  color: var(--maroon);
}

/* ---------- catalogue (works index) ---------- */

.catalogue { border-top: 1px solid var(--hairline); }

.catalogue__row {
  display: grid;
  grid-template-columns: 90px 1fr auto;
  align-items: baseline;
  gap: 24px;
  padding: 34px 0;
  border-bottom: 1px solid var(--hairline);
  text-decoration: none;
  transition: padding-left 0.3s ease;
}

a.catalogue__row:hover { padding-left: 14px; }
a.catalogue__row:hover .catalogue__title { color: var(--maroon); }

.catalogue__no {
  font-family: "Lora", serif;
  font-size: 15px;
  font-style: italic;
  color: var(--ink-faint);
}

.catalogue__title {
  font-family: "Marcellus", serif;
  font-size: clamp(28px, 3.8vw, 44px);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: 0.01em;
  color: var(--ink);
  transition: color 0.25s;
}

.catalogue__meta { text-align: right; }

.catalogue__row--muted .catalogue__title { color: var(--ink-faint); }

@media (max-width: 640px) {
  .catalogue__row { grid-template-columns: 48px 1fr; }
  .catalogue__meta { grid-column: 2; text-align: left; }
}

/* ---------- essay trio ---------- */

.trio {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(28px, 4vw, 56px);
}

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

.essay h3 {
  font-family: "Marcellus", serif;
  font-size: 25px;
  font-weight: 400;
  line-height: 1.25;
  margin: 14px 0 10px;
  color: var(--ink);
}

.essay p { font-size: 16.5px; color: var(--ink-soft); }

.essay .label { display: block; }

/* ---------- feature split ---------- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 6vw, 88px);
  align-items: center;
}

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

.split h2 {
  font-family: "Marcellus", serif;
  font-weight: 400;
  font-size: clamp(32px, 4.2vw, 52px);
  line-height: 1.12;
  letter-spacing: 0.01em;
  margin: 14px 0 18px;
  color: var(--ink);
}

.split p { color: var(--ink-soft); margin-bottom: 1.2em; }

/* ---------- buttons / text links ---------- */

.btn {
  position: relative;
  display: inline-block;
  overflow: hidden;
  font-family: "Cinzel", serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink);
  border: 1px solid var(--ink-soft);
  padding: 15px 34px;
  transition: background var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease),
    border-color var(--dur-fast) var(--ease), transform var(--dur-fast) var(--ease-soft),
    box-shadow var(--dur-fast) var(--ease-soft);
}

.btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 35%;
  height: 100%;
  background: linear-gradient(115deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: skewX(-18deg);
  transition: left 0.7s var(--ease);
  pointer-events: none;
}

.btn:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
  transform: scale(1.02);
  box-shadow: var(--shadow-md);
}

.btn:hover::before { left: 130%; }
.btn:active { transform: scale(0.99); }

.btn--oxide { border-color: var(--maroon); color: var(--ink); }
.btn--oxide:hover {
  background: var(--maroon);
  border-color: var(--maroon);
  color: #F7EEEC;
  box-shadow: var(--shadow-maroon);
}

.btn.is-loading {
  cursor: progress;
  opacity: 0.72;
  transform: none;
  letter-spacing: 0.16em;
}

@media (prefers-reduced-motion: reduce) {
  .btn { transition: background 0.2s, color 0.2s, border-color 0.2s; }
  .btn:hover { transform: none; }
  .btn::before { display: none; }
}

.textlink {
  font-family: "Cinzel", serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink);
  border-bottom: 1px solid var(--ink-soft);
  padding-bottom: 4px;
  transition: color var(--dur-fast) var(--ease-soft), border-color var(--dur-fast) var(--ease-soft);
}

.textlink:hover { color: var(--maroon); border-color: var(--maroon); }

/* ---------- pull quote — soft serif, easy on the eyes ---------- */

.pullquote {
  font-family: "Lora", serif;
  font-size: clamp(26px, 3.6vw, 44px);
  font-weight: 400;
  font-style: italic;
  line-height: 1.4;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
  color: var(--ink);
}

.pullquote em { color: var(--maroon); }

.pullquote__attr {
  display: block;
  margin-top: 28px;
  font-style: normal;
}

/* ---------- details table (project facts) ---------- */

.facts { border-top: 1px solid var(--hairline); }

.facts__row {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 20px;
  padding: 18px 0;
  border-bottom: 1px solid var(--hairline-soft);
}

.facts__row dt {
  font-family: "Cinzel", serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding-top: 4px;
}

.facts__row dd { font-size: 18px; color: var(--ink); }

@media (max-width: 600px) {
  .facts__row { grid-template-columns: 1fr; gap: 4px; }
}

/* ---------- gallery grid ---------- */

.gallery {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: clamp(16px, 2.5vw, 32px);
}

.gallery > figure:nth-child(1) { grid-column: 1 / 8; }
.gallery > figure:nth-child(2) { grid-column: 8 / 13; margin-top: clamp(32px, 6vw, 96px); }
.gallery > figure:nth-child(3) { grid-column: 2 / 7; margin-top: clamp(16px, 3vw, 48px); }
.gallery > figure:nth-child(4) { grid-column: 7 / 12; }

@media (max-width: 760px) {
  .gallery > figure { grid-column: 1 / 13 !important; margin-top: 0 !important; }
}

/* ---------- forms ---------- */

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px 32px;
}

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

.field { display: flex; flex-direction: column; gap: 10px; }
.field--full { grid-column: 1 / -1; }

.field label {
  font-family: "Cinzel", serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-soft);
  transition: color var(--dur-fast) var(--ease-soft), letter-spacing var(--dur-fast) var(--ease-soft);
}

.field:focus-within label { color: var(--maroon); letter-spacing: 0.26em; }

.field input, .field textarea, .field select {
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--hairline);
  font-family: "Lora", serif;
  font-size: 18px;
  color: var(--ink);
  padding: 8px 2px;
  border-radius: 0;
  outline: none;
  transition: border-color var(--dur-fast) var(--ease-soft), box-shadow var(--dur-fast) var(--ease-soft);
}

.field select { color: var(--ink); }
.field select option { background: var(--paper-deep); color: var(--ink); }

.field input:focus, .field textarea:focus, .field select:focus {
  border-color: var(--maroon);
  box-shadow: 0 1px 0 0 var(--maroon), 0 6px 16px -10px rgba(124, 36, 48, 0.5);
}

.field textarea { resize: vertical; min-height: 120px; }

@media (prefers-reduced-motion: reduce) {
  .field label, .field input, .field textarea, .field select { transition: none; }
}

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

.footer {
  background: var(--velvet);
  border-top: 1px solid var(--hairline-soft);
  color: var(--ink-on-dark);
  padding: clamp(64px, 9vw, 120px) 0 40px;
}

.footer .label { color: var(--maroon-soft); }

.footer__mark {
  font-family: "Marcellus", serif;
  font-weight: 400;
  font-size: clamp(48px, 9vw, 130px);
  line-height: 1;
  letter-spacing: 0.04em;
  margin-bottom: clamp(40px, 6vw, 72px);
  color: var(--ink-on-dark);
}

.footer__mark span { color: var(--maroon-soft); }

.footer__cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  padding-top: 32px;
  border-top: 1px solid var(--hairline-soft);
}

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

.footer__cols a {
  display: inline-block;
  color: var(--ink-on-dark);
  text-decoration: none;
  font-size: 16.5px;
  margin-top: 10px;
  opacity: 0.85;
  transition: opacity var(--dur-fast) var(--ease-soft), transform var(--dur-fast) var(--ease-soft), color var(--dur-fast) var(--ease-soft);
}

.footer__cols a:hover { opacity: 1; color: var(--maroon-soft); transform: translateX(3px); }

.footer__legal {
  margin-top: clamp(40px, 6vw, 64px);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
  color: var(--ink-on-dark-faint);
  font-style: italic;
}

/* ---------- line-by-line heading reveal (pagehead h1s, split h2) ---------- */

.line-reveal { overflow: hidden; }

/* the heading itself stays put — only its line spans animate */
.line-reveal.reveal { opacity: 1; transform: none; transition: none; }

.line-reveal .line-reveal__line {
  display: block;
  opacity: 0;
  transform: translateY(60%) scale(0.97);
}

.line-reveal.is-in .line-reveal__line {
  animation: lineRevealIn 1.08s var(--ease) forwards;
}

.line-reveal.is-in .line-reveal__line:nth-child(2) { animation-delay: 0.156s; }

@keyframes lineRevealIn {
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (prefers-reduced-motion: reduce) {
  .line-reveal .line-reveal__line { opacity: 1; transform: none; animation: none; }
}

/* ---------- reveal on scroll ---------- */

.reveal {
  opacity: 0;
  transform: translateY(32px) scale(0.98);
  transition: opacity var(--dur-slow) var(--ease), transform var(--dur-slow) var(--ease);
  will-change: opacity, transform;
}

.reveal.is-in { opacity: 1; transform: none; }

/* gentle stagger for repeated grid items — 80-120ms rhythm */
.cards article:nth-child(1),
.photogrid figure:nth-child(1),
.trio .essay:nth-child(1) { transition-delay: 0s; }

.cards article:nth-child(2),
.photogrid figure:nth-child(2),
.trio .essay:nth-child(2) { transition-delay: 0.09s; }

.cards article:nth-child(3),
.photogrid figure:nth-child(3),
.trio .essay:nth-child(3) { transition-delay: 0.18s; }

.photogrid figure:nth-child(4) { transition-delay: 0.27s; }
.photogrid figure:nth-child(5) { transition-delay: 0.36s; }
.photogrid figure:nth-child(6) { transition-delay: 0.45s; }

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
    transition-delay: 0s !important;
  }
}

/* ---------- Skyline Realtors — bold entrance, Marvis-inspired ---------- */

.skyline-title {
  font-family: "Marcellus", serif;
  font-weight: 400;
  font-size: clamp(44px, 7vw, 92px);
  line-height: 1.15;
  letter-spacing: 0.01em;
  margin: 28px 0 24px;
  padding-top: 0.15em;
  padding-bottom: 0.06em;
  color: var(--ink);
  overflow: hidden;
}

.skyline-title span {
  display: inline-block;
  opacity: 0;
  transform: translateY(60px) scale(0.96);
  animation: skylineWordIn 1.1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.skyline-title span:nth-child(2) { animation-delay: 0.14s; }

@keyframes skylineWordIn {
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.scroll-cue {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: clamp(40px, 6vw, 64px);
  font-family: "Cinzel", serif;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-faint);
  width: fit-content;
}

.scroll-cue__line {
  width: 1px;
  height: 38px;
  background: var(--maroon);
  transform-origin: top;
  animation: scrollCuePulse 1.8s ease-in-out infinite;
}

@keyframes scrollCuePulse {
  0%, 100% { transform: scaleY(0.35); opacity: 0.35; }
  50% { transform: scaleY(1); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .skyline-title span { opacity: 1; transform: none; animation: none; }
  .scroll-cue__line { animation: none; transform: scaleY(1); opacity: 0.6; }
}

/* the global .reveal (below) now matches this page's premium easing/scale,
   so grid stagger here simply relies on the shared nth-child rules. */

/* ---------- page hero (inner pages) ---------- */

.pagehead {
  padding: clamp(64px, 9vw, 130px) 0 clamp(40px, 6vw, 80px);
}

.pagehead h1 {
  font-family: "Marcellus", serif;
  font-weight: 400;
  font-size: clamp(44px, 7vw, 92px);
  line-height: 1.05;
  letter-spacing: 0.01em;
  margin: 14px 0 22px;
  color: var(--ink);
}

.pagehead .lede { max-width: 680px; color: var(--ink-soft); }

/* ---------- logo ---------- */

.wordmark__logo { height: 36px; width: auto; }

/* the Anant logo as a quiet background watermark */
.has-watermark { position: relative; overflow: hidden; }

.logo-wm {
  position: absolute;
  top: 50%;
  right: 4%;
  transform: translateY(-50%);
  width: clamp(180px, 22vw, 340px);
  opacity: 0.07;
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

.logo-wm--center {
  right: auto;
  left: 50%;
  transform: translate(-50%, -50%);
}

.has-watermark > .wrap { position: relative; z-index: 1; }

/* ---------- photographs ---------- */

.photo {
  border: 1px solid var(--hairline);
  padding: 8px;
  background: var(--paper-deep);
  overflow: hidden;
  transition: box-shadow var(--dur-base) var(--ease), border-color var(--dur-base) var(--ease);
}

.photo:hover { box-shadow: var(--shadow-md); border-color: var(--hairline); }

.photo img { width: 100%; height: auto; transition: transform var(--dur-slow) var(--ease); }
.photo:hover img { transform: scale(1.05); }

.photo--cover img { aspect-ratio: 16 / 10; object-fit: cover; object-position: center top; }
.photo--tall img { aspect-ratio: 3 / 4; object-fit: cover; }

/* slow ambient zoom for large feature photography — subtle, continuous */
.photo--cover img { animation: photoAmbientZoom 22s var(--ease-soft) infinite alternate; }
.photo--cover:hover img { animation-play-state: paused; transform: scale(1.06); }

@keyframes photoAmbientZoom {
  from { transform: scale(1); }
  to { transform: scale(1.035); }
}

@media (prefers-reduced-motion: reduce) {
  .photo, .photo img { transition: none; animation: none; }
  .photo:hover img { transform: none; }
}

/* ---------- stats band ---------- */

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  padding: clamp(28px, 4vw, 48px) 0;
}

@media (max-width: 820px) { .stats { grid-template-columns: repeat(2, 1fr); } }

.stat { text-align: left; }

.stat__num {
  font-family: "Marcellus", serif;
  font-size: clamp(34px, 4.5vw, 56px);
  line-height: 1;
  color: var(--maroon);
  font-variant-numeric: tabular-nums;
  transition: text-shadow 0.3s ease;
}

.stat__num.is-counting {
  text-shadow: 0 0 18px rgba(124, 36, 48, 0.35);
}

.stat__label {
  margin-top: 10px;
  font-family: "Cinzel", serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* ---------- project cards ---------- */

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(20px, 3vw, 36px);
}

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

.card {
  border: 1px solid var(--hairline);
  background: var(--paper-deep);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform var(--dur-base) var(--ease), box-shadow var(--dur-base) var(--ease),
    border-color var(--dur-base) var(--ease), background var(--dur-base) var(--ease);
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--hairline);
  background: var(--paper);
}

.card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  background: var(--paper-dim);
  transition: transform var(--dur-slow) var(--ease);
}

.card:hover img { transform: scale(1.05); }

@media (prefers-reduced-motion: reduce) {
  .card, .card img { transition: none; }
  .card:hover { transform: none; }
  .card:hover img { transform: none; }
}

.card__body { padding: 22px 22px 26px; }

.card__title {
  font-family: "Marcellus", serif;
  font-size: 24px;
  line-height: 1.15;
  color: var(--ink);
  margin-bottom: 6px;
}

.card__meta { font-size: 15px; color: var(--ink-soft); }

.card__tag {
  display: inline-block;
  margin-bottom: 12px;
  font-family: "Cinzel", serif;
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--maroon);
  border: 1px solid var(--maroon);
  padding: 5px 10px;
}

/* ---------- simple project list (completed) ---------- */

.plist { border-top: 1px solid var(--hairline); }

.plist__row {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 16px;
  align-items: baseline;
  padding: 15px 0;
  border-bottom: 1px solid var(--hairline-soft);
}

.plist__no {
  font-family: "Lora", serif;
  font-style: italic;
  font-size: 14px;
  color: var(--ink-faint);
}

.plist__name { font-family: "Marcellus", serif; font-size: 19px; color: var(--ink); }

.plist__loc { font-size: 15px; color: var(--ink-soft); text-align: right; }

@media (max-width: 600px) {
  .plist__row { grid-template-columns: 32px 1fr; }
  .plist__loc { grid-column: 2; text-align: left; }
}

/* ---------- photo gallery grid (simple) ---------- */

.photogrid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(14px, 2vw, 26px);
}

@media (max-width: 820px) { .photogrid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .photogrid { grid-template-columns: 1fr; } }

.photogrid figure { margin: 0; }
/* contain, not cover — the gallery mixes tall facades and wide aerials,
   so a single crop anchor would always cut something off one of them */
.photogrid .photo img { aspect-ratio: 4 / 3; object-fit: contain; background: var(--paper-deep); }

/* ---------- lightbox ---------- */

.zoomable { cursor: zoom-in; transition: opacity 0.2s; }
.zoomable:hover { opacity: 0.88; }

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 5vw, 64px);
  background: rgba(20, 12, 12, 0.92);
  cursor: zoom-out;
}

.lightbox.is-open { display: flex; }

.lightbox__img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.lightbox__close {
  position: absolute;
  top: clamp(14px, 3vw, 28px);
  right: clamp(14px, 3vw, 28px);
  font-family: "Cinzel", serif;
  font-size: 32px;
  line-height: 1;
  color: var(--ink-on-dark);
  opacity: 0.8;
}

.lightbox__close:hover { opacity: 1; }

/* ---------- misc ---------- */

.center { text-align: center; }
.mt-lg { margin-top: clamp(40px, 6vw, 72px); }
.mt-md { margin-top: 32px; }
.mt-sm { margin-top: 18px; }
