/* components.css — buttons, cards, forms, accordion, timeline, bands */

/* ---- Page intro / loading overlay ---- */
.page-intro {
  position: fixed; inset: 0; z-index: 1000;
  display: grid; place-items: center;
  background: #ffffff;
  animation: introOut 1.15s var(--ease-out) forwards;
}
.page-intro img {
  width: clamp(120px, 22vw, 160px); height: auto;
  animation: introLogo 1s var(--ease-out) both;
}
@keyframes introLogo {
  0% { opacity: 0; transform: scale(0.9) translateY(8px); }
  45% { opacity: 1; transform: scale(1) translateY(0); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes introOut {
  0%, 55% { opacity: 1; visibility: visible; }
  100% { opacity: 0; visibility: hidden; pointer-events: none; }
}

/* ---- Hero entrance (Ken Burns on image, headline lift) ---- */
.hero--image .hero__media img,
.cta-band__media img { animation: kenburns 18s ease-out both; }
@keyframes kenburns { from { transform: scale(1.06); } to { transform: scale(1.12); } }
.hero__content > * { animation: heroRise 0.8s var(--ease-out) both; }
.hero__content > *:nth-child(1) { animation-delay: 0.55s; }
.hero__content > *:nth-child(2) { animation-delay: 0.63s; }
.hero__content > *:nth-child(3) { animation-delay: 0.71s; }
.hero__content > *:nth-child(4) { animation-delay: 0.79s; }
.hero__content > *:nth-child(5) { animation-delay: 0.87s; }
@keyframes heroRise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .page-intro { display: none; }
  .hero--image .hero__media img, .cta-band__media img { animation: none; }
  .hero__content > * { animation: none; }
}


/* ---- Cover-image containers: make <picture>+<img> fill their box ---- */
.media-frame, .route-card__media, .image-band { position: relative; }
.hero__media picture, .cta-band__media picture, .media-frame picture, .route-card__media picture, .image-band picture { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__media picture > img, .cta-band__media picture > img, .media-frame picture > img, .route-card__media picture > img, .image-band picture > img { width: 100%; height: 100%; object-fit: cover; }

/* ---- Buttons ---- */
.btn {
  position: relative; display: inline-flex; align-items: center; gap: var(--s-3);
  padding: 14px 26px; border-radius: var(--radius-btn);
  font-size: var(--fs-sm); font-weight: 600; letter-spacing: 0.01em;
  border: 1px solid transparent; overflow: hidden; isolation: isolate;
  transition: transform var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out);
}
.btn svg { width: 16px; height: 16px; transition: transform var(--dur-base) var(--ease-out); }
.btn:hover { transform: translateY(-1px); }
.btn:hover svg { transform: translateX(3px); }

/* primary = gold (matches logo); fills to navy on hover */
.btn--primary { background: var(--gold); color: var(--ink-900); }
.btn--primary::before {
  content: ""; position: absolute; inset: 0; z-index: -1; background: var(--ink-900);
  transform: scaleX(0); transform-origin: left; transition: transform var(--dur-base) var(--ease-out);
}
.btn--primary:hover { color: #fff; }
.btn--primary:hover::before { transform: scaleX(1); }

.btn--gold { background: var(--gold); color: var(--ink-900); }
.btn--gold::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--ink-900); transform: scaleX(0); transform-origin: left; transition: transform var(--dur-base) var(--ease-out); }
.btn--gold:hover { color: #fff; }
.btn--gold:hover::before { transform: scaleX(1); }

.btn--ghost { background: transparent; color: var(--ink-900); border-color: var(--line-strong); }
.btn--ghost:hover { border-color: var(--gold); color: var(--gold-deep); }
.section--dark .btn--ghost, .hero--image .btn--ghost, .hero--dark .btn--ghost { color: #fff; border-color: rgba(255,255,255,.32); }
.section--dark .btn--ghost:hover, .hero--image .btn--ghost:hover, .hero--dark .btn--ghost:hover { border-color: var(--gold-bright); color: var(--gold-bright); }

.link-arrow { display: inline-flex; align-items: center; gap: var(--s-2); font-weight: 600; font-size: var(--fs-sm); color: var(--gold-deep); }
.link-arrow svg { width: 15px; height: 15px; transition: transform var(--dur-base) var(--ease-out); }
.link-arrow:hover svg { transform: translateX(4px); }
.section--dark .link-arrow { color: var(--gold-bright); }

/* ---- Media frame ---- */
.media-frame { border-radius: var(--radius-card); overflow: hidden; background: var(--ink-800); box-shadow: var(--shadow-2); }
.media-frame img { width: 100%; height: 100%; object-fit: cover; filter: var(--img-grade); }
.media-frame--tall { aspect-ratio: 4/5; }
.media-frame.media-fill { height: 100%; min-height: 320px; }
@media (max-width: 860px) { .media-frame.media-fill { height: auto; aspect-ratio: 16/11; min-height: 0; } }
.media-frame--wide { aspect-ratio: 16/10; }
.media-frame--sq { aspect-ratio: 1/1; }

/* ---- Cards ---- */
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card);
  padding: var(--s-8); box-shadow: var(--shadow-1);
  transition: transform var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out);
}
.card:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--gold) 55%, var(--line)); box-shadow: var(--shadow-2); }
.card__icon { width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid var(--line-strong); border-radius: 8px; margin-bottom: var(--s-6); color: var(--gold-deep); }
.card__icon svg { width: 22px; height: 22px; }
.card h3, .card h4 { margin-bottom: var(--s-3); }
.card p { color: var(--text-muted); font-size: var(--fs-sm); }
.card__list { margin-top: var(--s-4); display: flex; flex-direction: column; gap: var(--s-2); }
.card__list li { position: relative; padding-left: var(--s-6); font-size: var(--fs-sm); color: var(--ink-700); }
.card__list li::before { content: ""; position: absolute; left: 0; top: 9px; width: 12px; height: 1px; background: var(--gold); }

.cards-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gutter); }
.cards-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gutter); }
.cards-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gutter); }
@media (max-width: 1000px) { .cards-4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 900px) { .cards-3 { grid-template-columns: 1fr; } .cards-2 { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .cards-4 { grid-template-columns: 1fr; } }

/* routing card (owner-type) with image */
.route-card { position: relative; display: flex; flex-direction: column; overflow: hidden; padding: 0; }
.route-card__media { aspect-ratio: 5/4; overflow: hidden; }
.route-card__media img { width: 100%; height: 100%; object-fit: cover; filter: var(--img-grade); transition: transform var(--dur-slow) var(--ease-out); }
.route-card:hover .route-card__media img { transform: scale(1.04); }
.route-card__body { padding: var(--s-6); display: flex; flex-direction: column; gap: var(--s-3); flex: 1; }
.route-card__body .link-arrow { margin-top: auto; }

/* ---- Benefit / feature list (asymmetric) ---- */
.feature-row { display: grid; grid-template-columns: 44px 1fr; gap: var(--s-4); padding: var(--s-6) 0; border-top: 1px solid var(--line); align-items: start; }
.feature-row__num { font-family: var(--font-display); font-size: 1rem; color: var(--gold-deep); line-height: 1; height: 44px; display: flex; align-items: center; justify-content: center; }
.feature-row__num svg { width: 24px; height: 24px; color: var(--gold-deep); }
.section--dark .feature-row__num, .section--dark .feature-row__num svg { color: var(--gold-bright); }
/* when the marker is an icon, give it a subtle tile so it aligns cleanly with the title */
.feature-row__num:has(svg) { width: 44px; border: 1px solid var(--line); border-radius: 8px; }
.section--dark .feature-row__num:has(svg) { border-color: var(--line-dark); }
.feature-row h4 { margin-bottom: var(--s-2); line-height: 1.2; }
.feature-row p { color: var(--text-muted); font-size: var(--fs-sm); }
.section--dark .feature-row { border-color: var(--line-dark); }

/* ---- Process steps ---- */
.steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: var(--gutter); counter-reset: step; }
.steps--4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 980px) { .steps, .steps--4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .steps, .steps--4 { grid-template-columns: 1fr; } }
.step { position: relative; padding-top: var(--s-8); border-top: 2px solid var(--line-strong); }
.step__num { position: absolute; top: -0.9em; left: 0; font-family: var(--font-display); font-size: 2.4rem; font-weight: 500; color: var(--gold); background: var(--bg); padding-right: var(--s-3); line-height: 1; }
.section--dark .step__num { background: var(--ink-900); color: var(--gold-bright); }
.section--dark .step { border-color: var(--line-dark); }
.step h4 { margin-bottom: var(--s-3); }
.step p { font-size: var(--fs-sm); color: var(--text-muted); }
.step dl { margin-top: var(--s-4); font-size: 0.8125rem; }
.step dt { text-transform: uppercase; letter-spacing: 0.1em; color: var(--gold-deep); font-weight: 600; font-size: 0.6875rem; margin-top: var(--s-3); }
.step dd { color: var(--text-muted); }
.section--dark .step dt { color: var(--gold-bright); }

/* ---- Report-card exhibit (NRI signature) ---- */
.report-sticky { position: sticky; top: calc(var(--header-h) + 24px); }
@media (max-width: 860px) { .report-sticky { position: static; } }
.report-card { background: var(--bone-050); border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: var(--shadow-2); overflow: hidden; width: 100%; }
.report-card__head { display: flex; justify-content: space-between; align-items: flex-start; padding: var(--s-6); border-bottom: 1px solid var(--line); background: var(--ink-900); color: #fff; }
.report-card__head small { display: block; font-size: 0.6875rem; text-transform: uppercase; letter-spacing: 0.14em; color: var(--gold-bright); margin-bottom: 4px; }
.report-card__head strong { font-family: var(--font-display); font-size: 1.25rem; font-weight: 500; }
.report-card__seal { width: 40px; height: 40px; }
.report-card__rows { padding: var(--s-4) var(--s-6); }
.report-line { display: flex; justify-content: space-between; gap: var(--s-4); padding: var(--s-3) 0; border-bottom: 1px dashed var(--line); font-size: var(--fs-sm); }
.report-line:last-child { border-bottom: 0; }
.report-line span:first-child { color: var(--text-muted); }
.report-line span:last-child { font-weight: 600; font-variant-numeric: tabular-nums; }
.report-card__foot { padding: var(--s-4) var(--s-6) var(--s-6); }
.report-total { display: flex; justify-content: space-between; align-items: baseline; padding-top: var(--s-4); border-top: 2px solid var(--ink-900); }
.report-total span:first-child { text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.6875rem; font-weight: 600; color: var(--text-muted); }
.report-total span:last-child { font-family: var(--font-display); font-size: 1.5rem; font-weight: 600; }

/* ---- Accordion ---- */
.accordion { border-top: 1px solid var(--line); max-width: none; width: 100%; }
.acc-item { border-bottom: 1px solid var(--line); }
.acc-trigger {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: var(--s-4);
  padding: var(--s-6) 0; text-align: left; font-family: var(--font-display); font-size: var(--fs-h4); font-weight: 500; color: var(--heading);
}
.acc-trigger .acc-icon { flex-shrink: 0; width: 22px; height: 22px; position: relative; }
.acc-icon::before, .acc-icon::after { content: ""; position: absolute; background: var(--gold-deep); transition: transform var(--dur-base) var(--ease-out); }
.acc-icon::before { top: 10px; left: 0; width: 22px; height: 2px; }
.acc-icon::after { top: 0; left: 10px; width: 2px; height: 22px; }
.acc-trigger[aria-expanded="true"] .acc-icon::after { transform: scaleY(0); }
.acc-panel { overflow: hidden; height: 0; transition: height var(--dur-base) var(--ease-out); }
.acc-panel__inner { padding: 0 0 var(--s-6); color: var(--text-muted); font-size: var(--fs-body); }
.acc-panel__inner p { max-width: 72ch; }
@media (prefers-reduced-motion: reduce) { .acc-panel { transition: none; } }

/* ---- Trust strip ---- */
.trust-strip { display: flex; flex-wrap: wrap; gap: var(--s-6) var(--s-8); margin-top: var(--s-8); padding-top: var(--s-6); border-top: 1px solid rgba(255,255,255,.16); }
.trust-strip.on-light { border-color: var(--line); }
.trust-item { display: flex; align-items: center; gap: var(--s-3); font-size: var(--fs-sm); }
.trust-item svg { width: 20px; height: 20px; color: var(--gold-bright); flex-shrink: 0; }
.on-light .trust-item svg { color: var(--gold-deep); }

/* ---- Stat row ---- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gutter); }
@media (max-width: 760px) { .stats { grid-template-columns: 1fr 1fr; } }
.stat__num { font-family: var(--font-display); font-size: clamp(2.2rem, 1.5rem + 2.4vw, 3rem); font-weight: 500; color: var(--gold-deep); line-height: 1; }
.section--dark .stat__num { color: var(--gold-bright); }
.stat__label { margin-top: var(--s-3); font-size: var(--fs-sm); color: var(--text-muted); }
.section--dark .stat__label { color: var(--slate-300); }

/* ---- CTA band ---- */
.cta-band { position: relative; overflow: hidden; }
.cta-band__media { position: absolute; inset: 0; z-index: 0; }
.cta-band__media img { width: 100%; height: 100%; object-fit: cover; filter: var(--img-grade) brightness(.4); }
.cta-band__inner { position: relative; z-index: 1; text-align: center; max-width: 720px; margin-inline: auto; }
.cta-band .hero__actions { justify-content: center; }

/* ---- Metric grid (credibility band, 2x2) ---- */
.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-4); }
@media (max-width: 480px) { .metric-grid { grid-template-columns: 1fr; } }
.metric { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); padding: var(--s-6); display: flex; flex-direction: column; gap: var(--s-3); box-shadow: var(--shadow-1); }
.metric svg { width: 26px; height: 26px; color: var(--gold-deep); }
.metric--num { justify-content: flex-start; }

/* ---- Quote ---- */
.quote { max-width: 720px; }
.quote blockquote { font-family: var(--font-display); font-size: clamp(1.15rem, 1rem + 0.9vw, 1.5rem); line-height: 1.4; font-weight: 400; letter-spacing: -0.005em; }
.quote blockquote p { max-width: none; }
.quote blockquote p + p { margin-top: var(--s-4); }
.quote__cite { display: flex; align-items: center; gap: var(--s-4); margin-top: var(--s-8); font-style: normal; }
.quote__cite img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; filter: var(--img-grade); }
.quote__cite b { display: block; font-weight: 600; }
.quote__cite span { color: var(--text-muted); font-size: var(--fs-sm); }
.section--dark .quote__cite span { color: var(--slate-300); }

/* ---- Forms ---- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-6); }
.field--full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } .field--full { grid-column: auto; } }
.form-grid > * { min-width: 0; }
.field { display: flex; flex-direction: column; gap: var(--s-2); min-width: 0; }
.field input, .field select, .field textarea { width: 100%; min-width: 0; }
.field label { font-size: var(--fs-sm); font-weight: 600; }
.field .req { color: var(--seal-red); }
.field input, .field select, .field textarea {
  padding: 13px 14px; background: var(--bone-050); border: 1px solid var(--line-strong); border-radius: var(--radius-btn);
  font-size: var(--fs-sm); transition: border-color var(--dur-fast), box-shadow var(--dur-fast);
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px color-mix(in srgb, var(--gold) 22%, transparent); }
.field[data-invalid="true"] input, .field[data-invalid="true"] select, .field[data-invalid="true"] textarea { border-color: var(--seal-red); }
.field__error { font-size: 0.8125rem; color: var(--seal-red); min-height: 1em; }
.form-note { font-size: 0.8125rem; color: var(--text-muted); }
/* dark-context forms & contact blocks (NRI callback) */
.section--dark .field label { color: #fff; }
.section--dark .form-note { color: var(--slate-300); }
.section--dark .contact-block h4 { color: var(--slate-300); }
.section--dark .contact-block a, .section--dark .contact-block address, .section--dark .contact-block span { color: #fff; }
.section--dark .contact-block svg { color: var(--amber); }
.form-success {
  display: none; padding: var(--s-6); border: 1px solid var(--green); border-radius: var(--radius-card);
  background: color-mix(in srgb, var(--green) 8%, var(--bone-050)); gap: var(--s-4); align-items: flex-start;
}
.form-success[data-show="true"] { display: flex; }
.form-success svg { width: 24px; height: 24px; color: var(--green); flex-shrink: 0; }

/* ---- Pillars / values ---- */
.pillar { padding: var(--s-6); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--surface); }
.pillar svg { width: 26px; height: 26px; color: var(--gold-deep); margin-bottom: var(--s-4); }
.pillar h4 { margin-bottom: var(--s-2); }
.pillar p { font-size: var(--fs-sm); color: var(--text-muted); }

/* ---- Breadcrumb ---- */
.breadcrumb { font-size: 0.8125rem; color: var(--text-muted); display: flex; gap: var(--s-2); flex-wrap: wrap; }
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--gold-deep); }
.hero--image .breadcrumb, .hero--dark .breadcrumb { color: rgba(255,255,255,.7); }
.hero--image .breadcrumb a, .hero--dark .breadcrumb a { color: rgba(255,255,255,.7); }

/* ---- Reveal ---- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal-stagger > * { opacity: 0; transform: translateY(20px); transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out); }
.reveal-stagger.is-in > * { opacity: 1; transform: none; }
.reveal-stagger.is-in > *:nth-child(1){transition-delay:.00s}.reveal-stagger.is-in > *:nth-child(2){transition-delay:.07s}.reveal-stagger.is-in > *:nth-child(3){transition-delay:.14s}.reveal-stagger.is-in > *:nth-child(4){transition-delay:.21s}.reveal-stagger.is-in > *:nth-child(5){transition-delay:.28s}.reveal-stagger.is-in > *:nth-child(6){transition-delay:.35s}
@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal-stagger > * { opacity: 1 !important; transform: none !important; transition: none !important; }
  .btn, .card, .route-card__media img, .nav-link::after { transition: none !important; }
}
