/* ==========================================================================
   Matrimonial Law Office | Marriage Registration & Mutual Divorce, Gurgaon
   Design system: "Cause List"
   Palette derives from Indian court stationery — ledger paper, register ink,
   and the mulberry of a court seal. Statute citations are set in mono and
   treated as the primary structural identifier throughout the site.
   ========================================================================== */

:root {
  --paper:      #F2F3EF;
  --paper-2:    #E9EBE4;
  --paper-3:    #DFE2D9;
  --ink:        #161D26;
  --ink-2:      #47525F;
  --ink-3:      #6B7683;
  --indigo:     #2C4468;
  --indigo-lt:  #4A648C;
  --seal:       #7A3B54;
  --seal-lt:    #9C5A74;
  --rule:       #D2D6CC;
  --rule-2:     #BFC5B8;
  --white:      #FCFCFA;

  --f-display: "Eczar", Georgia, serif;
  --f-body:    "IBM Plex Sans", system-ui, -apple-system, sans-serif;
  --f-mono:    "IBM Plex Mono", "SF Mono", Menlo, monospace;

  --wrap: 1180px;
  --gap: clamp(1.25rem, 3vw, 2.5rem);
  --radius: 2px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-feature-settings: "liga" 1, "kern" 1;
}

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

a { color: var(--indigo); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--seal); }
:focus-visible { outline: 2px solid var(--seal); outline-offset: 3px; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gap); }
.narrow { max-width: 760px; }

/* ---------- Type scale ---------- */
h1, h2, h3, h4 { font-family: var(--f-display); font-weight: 600; line-height: 1.15; margin: 0 0 .5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); font-weight: 700; }
h2 { font-size: clamp(1.55rem, 2.9vw, 2.15rem); margin-top: 2.2em; }
h3 { font-size: clamp(1.18rem, 2vw, 1.4rem); margin-top: 1.9em; }
h4 { font-size: 1.05rem; font-family: var(--f-body); font-weight: 600; letter-spacing: .01em; margin-top: 1.6em; }
h2:first-child, h3:first-child { margin-top: 0; }
p { margin: 0 0 1.1em; }

.eyebrow {
  font-family: var(--f-mono);
  font-size: .72rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--seal);
  margin: 0 0 1rem;
  display: flex; align-items: center; gap: .7rem;
}
.eyebrow::after { content: ""; flex: 1; height: 1px; background: var(--rule-2); }

.lede { font-size: 1.15rem; line-height: 1.6; color: var(--ink-2); }

/* ---------- Statute chip: the site's core structural device ---------- */
.stat {
  font-family: var(--f-mono);
  font-size: .74rem;
  letter-spacing: .04em;
  color: var(--indigo);
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-left: 2px solid var(--indigo);
  padding: .2rem .5rem;
  border-radius: var(--radius);
  white-space: nowrap;
  display: inline-block;
}
.stat--seal { color: var(--seal); border-left-color: var(--seal); }

/* ---------- Skip link ---------- */
.skip {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--ink); color: var(--white); padding: .8rem 1.2rem;
}
.skip:focus { left: 0; }

/* ---------- Header ---------- */
.topbar {
  background: var(--ink); color: var(--paper-3);
  font-family: var(--f-mono); font-size: .72rem; letter-spacing: .05em;
}
.topbar .wrap { display: flex; flex-wrap: wrap; gap: .4rem 1.6rem; justify-content: space-between; padding-block: .5rem; }
.topbar a { color: var(--paper-3); text-decoration: none; }
.topbar a:hover { color: var(--white); text-decoration: underline; }

.masthead { background: var(--white); border-bottom: 1px solid var(--rule); position: sticky; top: 0; z-index: 100; }
.masthead .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .85rem; }

.brand { display: flex; align-items: baseline; gap: .6rem; text-decoration: none; color: var(--ink); }
.brand b { font-family: var(--f-display); font-weight: 700; font-size: 1.32rem; letter-spacing: -.02em; }
.brand span { font-family: var(--f-mono); font-size: .66rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }

.nav { display: flex; align-items: center; gap: .2rem; }
.nav a {
  font-size: .88rem; font-weight: 500; text-decoration: none; color: var(--ink-2);
  padding: .5rem .7rem; border-radius: var(--radius);
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); background: var(--paper-2); }
.nav a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--seal); }

.btn {
  display: inline-block; font-family: var(--f-body); font-size: .88rem; font-weight: 600;
  padding: .62rem 1.15rem; border-radius: var(--radius); text-decoration: none;
  background: var(--indigo); color: var(--white); border: 1px solid var(--indigo);
  transition: background .15s ease, border-color .15s ease;
}
.btn:hover { background: var(--seal); border-color: var(--seal); color: var(--white); }
.btn--ghost { background: transparent; color: var(--indigo); }
.btn--ghost:hover { background: var(--indigo); color: var(--white); }

.navtoggle {
  display: none; background: none; border: 1px solid var(--rule); border-radius: var(--radius);
  padding: .5rem .7rem; font-family: var(--f-mono); font-size: .75rem; cursor: pointer; color: var(--ink);
}

@media (max-width: 940px) {
  .navtoggle { display: block; }
  .nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--white); border-bottom: 1px solid var(--rule);
    flex-direction: column; align-items: stretch; padding: .6rem var(--gap) 1.1rem;
    max-height: 75vh; overflow-y: auto;
  }
  .nav.open { display: flex; }
  .nav a { padding: .7rem .4rem; border-bottom: 1px solid var(--paper-2); }
  .nav .btn { text-align: center; margin-top: .6rem; border-bottom: none; }
}

/* ---------- Hero: the cause list ---------- */
.hero { border-bottom: 1px solid var(--rule); background: linear-gradient(180deg, var(--white) 0%, var(--paper) 100%); }
.hero .wrap { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4.5rem); padding-block: clamp(2.75rem, 6vw, 5rem); align-items: start; }
.hero h1 { margin-bottom: .45em; }
.hero h1 em { font-style: normal; color: var(--seal); }

.causelist { border: 1px solid var(--rule-2); background: var(--white); border-radius: var(--radius); overflow: hidden; }
.causelist header {
  background: var(--ink); color: var(--paper-3);
  font-family: var(--f-mono); font-size: .68rem; letter-spacing: .13em; text-transform: uppercase;
  padding: .6rem .95rem; display: flex; justify-content: space-between; gap: 1rem;
}
.causelist ol { list-style: none; margin: 0; padding: 0; counter-reset: cl; }
.causelist li { border-bottom: 1px solid var(--paper-2); }
.causelist li:last-child { border-bottom: 0; }
.causelist a {
  display: grid; grid-template-columns: 6.2rem 1fr; gap: .9rem; align-items: baseline;
  padding: .6rem .95rem; text-decoration: none; color: var(--ink); font-size: .9rem;
  transition: background .12s ease;
}
.causelist a:hover { background: var(--paper-2); }
.causelist a code { font-family: var(--f-mono); font-size: .72rem; color: var(--seal); letter-spacing: .02em; }
.causelist footer { padding: .7rem .95rem; background: var(--paper-2); font-size: .82rem; border-top: 1px solid var(--rule); }

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

/* ---------- Sections ---------- */
.band { padding-block: clamp(2.5rem, 5.5vw, 4.5rem); }
.band--paper { background: var(--paper-2); border-block: 1px solid var(--rule); }
.band--ink { background: var(--ink); color: var(--paper-3); }
.band--ink h2, .band--ink h3 { color: var(--white); }
.band--ink a { color: #A9C0E0; }

.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(272px, 1fr)); }

.card {
  background: var(--white); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 1.4rem 1.5rem; display: flex; flex-direction: column;
  transition: border-color .15s ease, transform .15s ease;
}
.card:hover { border-color: var(--rule-2); }
.card h3 { font-size: 1.16rem; margin: .55rem 0 .45rem; }
.card h3 a { text-decoration: none; color: var(--ink); }
.card h3 a:hover { color: var(--seal); }
.card p { font-size: .93rem; color: var(--ink-2); margin-bottom: .9rem; }
.card .more { margin-top: auto; font-family: var(--f-mono); font-size: .74rem; letter-spacing: .06em; text-transform: uppercase; text-decoration: none; }
.card .more::after { content: " \2192"; }

/* ---------- Article layout ---------- */
.layout { display: grid; grid-template-columns: 250px 1fr; gap: clamp(1.6rem, 4vw, 3.4rem); padding-block: clamp(2rem, 4vw, 3.2rem); align-items: start; }
@media (max-width: 940px) { .layout { grid-template-columns: 1fr; } }

.sidebar { position: sticky; top: 84px; font-size: .88rem; }
@media (max-width: 940px) { .sidebar { position: static; } }
.sidebar h4 { font-family: var(--f-mono); font-size: .68rem; letter-spacing: .13em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 .7rem; }
.sidebar nav { border-left: 2px solid var(--rule); margin-bottom: 2rem; }
.sidebar nav a { display: block; padding: .35rem 0 .35rem .85rem; text-decoration: none; color: var(--ink-2); border-left: 2px solid transparent; margin-left: -2px; }
.sidebar nav a:hover { color: var(--seal); border-left-color: var(--seal); }

.article { max-width: 74ch; }
.article > *:first-child { margin-top: 0; }
.article ul, .article ol { margin: 0 0 1.2em; padding-left: 1.25em; }
.article li { margin-bottom: .45em; }
.article ul { list-style: none; padding-left: 0; }
.article ul > li { position: relative; padding-left: 1.3em; }
.article ul > li::before { content: "—"; position: absolute; left: 0; color: var(--seal); font-family: var(--f-mono); font-size: .85em; }
.article ol { padding-left: 0; list-style: none; counter-reset: st; }
.article ol > li { counter-increment: st; position: relative; padding-left: 2.4em; }
.article ol > li::before {
  content: counter(st, decimal-leading-zero); position: absolute; left: 0; top: .1em;
  font-family: var(--f-mono); font-size: .78em; color: var(--seal); letter-spacing: .04em;
}

.breadcrumb { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .04em; color: var(--ink-3); padding-top: 1.4rem; }
.breadcrumb a { color: var(--ink-3); text-decoration: none; }
.breadcrumb a:hover { color: var(--seal); text-decoration: underline; }

/* ---------- Content components ---------- */
.note {
  background: var(--paper-2); border: 1px solid var(--rule); border-left: 3px solid var(--indigo);
  padding: 1.05rem 1.25rem; margin: 1.6rem 0; border-radius: var(--radius); font-size: .95rem;
}
.note strong { color: var(--indigo); }
.note--seal { border-left-color: var(--seal); }
.note--seal strong { color: var(--seal); }
.note > *:last-child { margin-bottom: 0; }

.statrail { display: flex; flex-wrap: wrap; gap: .45rem; margin: 0 0 1.8rem; padding: 0; list-style: none; }
.statrail li { margin: 0; padding: 0; }
.statrail li::before { display: none; }

table { width: 100%; border-collapse: collapse; margin: 1.4rem 0 1.8rem; font-size: .92rem; }
caption { text-align: left; font-family: var(--f-mono); font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); padding-bottom: .6rem; }
th, td { text-align: left; padding: .6rem .75rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
th { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); background: var(--paper-2); font-weight: 500; }
tbody tr:hover { background: var(--paper-2); }
.tablewrap { overflow-x: auto; }

.checklist { border: 1px solid var(--rule); border-radius: var(--radius); background: var(--white); padding: 1.2rem 1.4rem; margin: 1.6rem 0; }
.checklist h4 { margin-top: 0; font-family: var(--f-mono); font-size: .7rem; letter-spacing: .13em; text-transform: uppercase; color: var(--seal); }
.checklist ul { margin-bottom: 0; }
.checklist ul > li::before { content: "\25A2"; font-size: .95em; color: var(--indigo); }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--rule); margin-top: 1rem; }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  cursor: pointer; padding: .95rem 2rem .95rem 0; position: relative;
  font-weight: 600; font-size: 1rem; list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: .3rem; top: .85rem;
  font-family: var(--f-mono); font-size: 1.15rem; color: var(--seal); transition: transform .18s ease;
}
.faq details[open] summary::after { content: "\2212"; }
.faq summary:hover { color: var(--seal); }
.faq .answer { padding: 0 0 1.1rem; color: var(--ink-2); font-size: .96rem; }
.faq .answer > *:last-child { margin-bottom: 0; }

/* ---------- People ---------- */
.person { display: grid; grid-template-columns: 84px 1fr; gap: 1.3rem; align-items: start; }
.sigil {
  width: 84px; height: 84px; border: 1px solid var(--rule-2); border-radius: 50%;
  display: grid; place-items: center; background: var(--white);
  font-family: var(--f-display); font-size: 1.5rem; font-weight: 600; color: var(--indigo); letter-spacing: .02em;
}
.person dl { margin: .9rem 0 0; font-size: .88rem; display: grid; grid-template-columns: auto 1fr; gap: .3rem .9rem; }
.person dt { font-family: var(--f-mono); font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); padding-top: .15rem; }
.person dd { margin: 0; }

/* ---------- CTA ---------- */
.cta { border: 1px solid var(--rule-2); background: var(--white); border-radius: var(--radius); padding: 1.6rem 1.8rem; margin: 2.5rem 0 0; }
.cta h3 { margin-top: 0; }
.cta p { color: var(--ink-2); font-size: .95rem; }
.cta .row { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1rem; }

/* ---------- Forms ---------- */
form .field { margin-bottom: 1.05rem; }
label { display: block; font-size: .82rem; font-weight: 600; margin-bottom: .35rem; letter-spacing: .01em; }
input, select, textarea {
  width: 100%; font-family: inherit; font-size: .95rem; color: var(--ink);
  background: var(--white); border: 1px solid var(--rule-2); border-radius: var(--radius);
  padding: .6rem .75rem;
}
input:focus, select:focus, textarea:focus { border-color: var(--indigo); outline: 2px solid rgba(44,68,104,.16); outline-offset: 0; }
textarea { min-height: 130px; resize: vertical; }
.hint { font-size: .8rem; color: var(--ink-3); margin-top: .3rem; }
button.btn { cursor: pointer; font-family: var(--f-body); }

/* ---------- Footer ---------- */
.footer { background: var(--ink); color: var(--paper-3); padding-block: clamp(2.4rem, 5vw, 3.6rem) 0; margin-top: 0; }
.footer a { color: var(--paper-3); text-decoration: none; }
.footer a:hover { color: var(--white); text-decoration: underline; }
.footer h4 { font-family: var(--f-mono); font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 .9rem; }
.footer .cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(158px, 1fr)); gap: 2rem 2rem; align-items: start; }
.footer ul { list-style: none; margin: 0; padding: 0; font-size: .88rem; }
.footer li { margin-bottom: .42rem; }
.footer .colophon {
  margin-top: 2.6rem; border-top: 1px solid #2C3540; padding-block: 1.3rem;
  font-size: .78rem; color: var(--ink-3); display: flex; flex-wrap: wrap; gap: .6rem 1.6rem; justify-content: space-between;
}
.footer .rule36 { font-size: .78rem; color: var(--ink-3); border-top: 1px solid #2C3540; padding-block: 1.2rem; margin-top: 0; line-height: 1.6; }

/* ---------- Utilities ---------- */
.mb0 { margin-bottom: 0; }
.mt2 { margin-top: 2rem; }
.small { font-size: .87rem; color: var(--ink-2); }
.center { text-align: center; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

@media print {
  .masthead, .topbar, .sidebar, .cta { display: none !important; }
  body { background: #fff; font-size: 11pt; }
}

/* ---------- Homepage portrait band ---------- */
.portrait-band { display: grid; grid-template-columns: minmax(0, 380px) 1fr; gap: clamp(1.6rem, 4vw, 3.2rem); align-items: center; }
.portrait { margin: 0; }
.portrait img {
  width: 100%; height: auto; border-radius: var(--radius);
  border: 1px solid var(--rule-2); background: var(--white);
  box-shadow: 0 1px 0 var(--rule-2), 12px 12px 0 -1px var(--paper-3);
}
.portrait figcaption {
  font-family: var(--f-mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-3); margin-top: 1rem; padding-left: .1rem;
}
@media (max-width: 820px) {
  .portrait-band { grid-template-columns: 1fr; }
  .portrait { max-width: 340px; }
  .portrait img { box-shadow: 0 1px 0 var(--rule-2), 8px 8px 0 -1px var(--paper-3); }
}

/* ---------- Specificity corrections ---------- */
/* .nav a sets a dark colour that outranked .btn — restore button contrast. */
.nav a.btn { color: var(--white); }
.nav a.btn:hover { color: var(--white); background: var(--seal); border-color: var(--seal); }
.nav a.btn[aria-current="page"] { box-shadow: none; }
/* Statute chips inside flex-column cards stretched to full width. */
.card > .stat { align-self: flex-start; }
