/* ------------------------------------------------------------------
   Base
   ------------------------------------------------------------------ */

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--text-md);
  line-height: 1.5;
  color: var(--cream-100);
  background-color: var(--navy-900);
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font);
  font-weight: 700;
  line-height: 1.15;
  margin: 0;
  color: var(--cream-100);
}

p { margin: 0; }

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

a { color: inherit; text-decoration: none; transition: color 0.2s ease; }

button { font-family: inherit; cursor: pointer; }

ul { margin: 0; padding: 0; list-style: none; }

:focus-visible { outline: var(--focus-ring); outline-offset: 3px; }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--navy-950); }
::-webkit-scrollbar-thumb { background: var(--brand-40); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(0, 130, 175, 0.5); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.honeypot { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Layout helpers */
.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}
.container--md { max-width: var(--container-md); }
.container--sm { max-width: var(--container-sm); }

.section { padding-block: 5rem; }
.section--lg { padding-block: 6rem; }
.section--tight { padding-block: 4rem; }
.bg-navy { background: var(--navy-900); }
.bg-deep { background: var(--navy-950); }

.mt-4  { margin-top: 1rem; }
.mt-6  { margin-top: 1.5rem; }
.mt-8  { margin-top: 2rem; }
.mt-10 { margin-top: 2.5rem; }
.mt-12 { margin-top: 3rem; }
.mt-16 { margin-top: 4rem; }
.mb-6  { margin-bottom: 1.5rem; }
.mb-8  { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.pt-2  { padding-top: 0.5rem; }
.pt-4  { padding-top: 1rem; }

.divider-brass {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--brand-40), transparent);
}

/* Icons */
.icon { width: 1.25rem; height: 1.25rem; flex-shrink: 0; }
.icon--sm { width: 1rem; height: 1rem; }
.icon--xs { width: 0.75rem; height: 0.75rem; }
.icon--brand { color: var(--brass-400); }

.icon-box {
  width: 2.75rem; height: 2.75rem; border-radius: var(--radius-sm);
  background: var(--brand-10); border: 1px solid var(--brand-20);
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.icon-box--sm { width: 2.5rem; height: 2.5rem; }

/* Typography helpers */
.eyebrow {
  font-size: var(--text-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--brass-400);
  margin-bottom: 0.75rem;
}

.h-display { font-size: var(--display-md); letter-spacing: -0.01em; }
.h-xl { font-size: var(--text-xl); }
.h-2xl { font-size: var(--text-2xl); }

.text-sm { font-size: var(--text-sm); }
.text-xs { font-size: var(--text-xs); }
.text-muted { color: var(--text-muted); }
.text-soft { color: var(--text-soft); }
.text-center { text-align: center; }
.text-brand { color: var(--brass-400); }
.strong { color: var(--cream-100); font-weight: 600; }

/* Skip link */
.skip-link {
  position: absolute; top: -100px; left: 1rem; z-index: 200;
  padding: 0.5rem 1rem; background: var(--brass-500); color: #fff; border-radius: var(--radius-xs);
}
.skip-link:focus { top: 0.5rem; color: #fff; }

/* ------------------------------------------------------------------
   Buttons
   ------------------------------------------------------------------ */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: var(--text-sm); font-weight: 600; line-height: 1.25;
  border-radius: var(--radius-xs); border: 1px solid transparent;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  white-space: nowrap;
}
.btn--primary {
  background: var(--brass-500); border-color: var(--brass-500); color: #fff;
  box-shadow: var(--shadow-brass);
}
.btn--primary:hover { background: var(--brass-400); border-color: var(--brass-400); color: #fff; box-shadow: 0 0 30px rgba(0, 130, 175, 0.3); }
.btn--outline { border-color: var(--brand-50); color: var(--brass-400); font-weight: 400; }
.btn--outline:hover { border-color: var(--brass-400); color: var(--brass-300); background: rgba(0, 130, 175, 0.08); }
.btn--outline-dark { border-color: rgba(0, 107, 145, 0.6); color: var(--brass-700); font-weight: 400; }
.btn--outline-dark:hover { color: var(--brass-600); background: var(--brand-10); border-color: var(--brass-600); }
.btn--ghost-border { border-color: var(--navy-600); color: var(--text); font-weight: 400; }
.btn--ghost-border:hover { color: var(--cream-100); }
.btn--sm { padding: 0.5rem 1rem; }
.btn--lg { padding: 1rem 2rem; font-size: var(--text-md); }
.btn--block { width: 100%; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn .icon { width: 1rem; height: 1rem; }

.btn-row { display: flex; flex-wrap: wrap; gap: 1rem; }
.btn-row--center { justify-content: center; }
@media (max-width: 639px) {
  .btn-row--stack .btn { width: 100%; }
}

.text-link { color: var(--brass-400); text-decoration: underline; text-underline-offset: 2px; }
.text-link:hover { color: var(--brass-300); }
.link-brand { color: var(--brass-400); }
.link-brand:hover { color: var(--brass-300); }

/* ------------------------------------------------------------------
   Header + navigation (fixed)
   ------------------------------------------------------------------ */

.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(0, 34, 51, 0.95);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--brand-10);
  transition: box-shadow 0.3s ease;
}
.site-header.is-scrolled { box-shadow: var(--shadow-navy); }

.site-header__inner {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h);
}

.site-header__brand img {
  height: 2.5rem; width: auto;
  filter: brightness(0) invert(1);
  transition: opacity 0.2s ease;
}
.site-header__brand:hover img { opacity: 0.85; }

.site-nav__list { display: flex; align-items: center; gap: 0.25rem; }
.site-nav__item { position: relative; display: flex; align-items: center; }

.site-nav__link {
  position: relative; display: inline-block;
  padding: 0.5rem 0.75rem;
  font-size: var(--text-sm); font-weight: 500;
  color: rgba(212, 236, 247, 0.8);
}
.site-nav__link::after {
  content: ''; position: absolute; left: 0.75rem; right: 0.75rem; bottom: 0.25rem;
  height: 1px; background: var(--brass-500);
  transform: scaleX(0); transform-origin: left; transition: transform 0.3s ease;
}
.site-nav__link:hover, .site-nav__link.is-active { color: var(--brass-300); }
.site-nav__link:hover::after { transform: scaleX(1); }

.site-nav__toggle {
  background: none; border: 0; padding: 0.25rem; margin-left: -0.5rem;
  color: rgba(212, 236, 247, 0.5); display: inline-flex;
}
.site-nav__toggle .icon { transition: transform 0.2s ease; }

.site-nav__dropdown {
  position: absolute; top: 100%; left: 0; padding-top: 0.5rem; width: 15rem;
  display: none; z-index: 110;
}
.site-nav__dropdown li {
  background: var(--navy-800);
  border-left: 1px solid var(--brand-20); border-right: 1px solid var(--brand-20);
}
.site-nav__dropdown li:first-child { border-top: 1px solid var(--brand-20); border-radius: var(--radius-sm) var(--radius-sm) 0 0; overflow: hidden; }
.site-nav__dropdown li:last-child { border-bottom: 1px solid var(--brand-20); border-radius: 0 0 var(--radius-sm) var(--radius-sm); overflow: hidden; box-shadow: var(--shadow-navy); }
.site-nav__dropdown a {
  display: block; padding: 0.625rem 1rem;
  font-size: var(--text-sm); color: var(--text);
  border-bottom: 1px solid rgba(0, 86, 118, 0.5);
}
.site-nav__dropdown li:last-child a { border-bottom: 0; }
.site-nav__dropdown a:hover { background: var(--navy-700); color: var(--brass-300); }

@media (min-width: 1024px) {
  .site-nav__item--has-children:hover .site-nav__dropdown,
  .site-nav__item--has-children:focus-within .site-nav__dropdown,
  .site-nav__item.is-open .site-nav__dropdown { display: block; }
  .site-nav__item.is-open .site-nav__toggle .icon { transform: rotate(180deg); }
}

.site-nav { display: flex; align-items: center; gap: 1.5rem; }
.site-nav__cta { display: flex; align-items: center; gap: 0.75rem; }
.site-nav__phone {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: var(--text-sm); color: var(--text);
}
.site-nav__phone:hover { color: var(--brass-300); }
.site-nav__phone .icon { color: var(--brass-500); }

.nav-burger {
  display: none; background: none; border: 0; padding: 0.5rem;
  color: var(--text);
}
.nav-burger:hover { color: var(--brass-300); }
.nav-burger .icon { width: 1.5rem; height: 1.5rem; }
.nav-burger__close { display: none; }
.nav-burger[aria-expanded='true'] .nav-burger__open { display: none; }
.nav-burger[aria-expanded='true'] .nav-burger__close { display: inline-flex; }

/* Mobile navigation */
@media (max-width: 1023px) {
  .nav-burger { display: inline-flex; }
  .nav-burger[hidden] { display: none; }

  .site-nav {
    display: none;
    position: absolute; top: var(--header-h); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: rgba(0, 34, 51, 0.98);
    -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    border-top: 1px solid var(--brand-10);
    padding: 1rem var(--container-pad);
    max-height: calc(100vh - var(--header-h)); overflow-y: auto;
  }
  .site-nav.is-open { display: flex; }

  .site-nav__list { flex-direction: column; align-items: stretch; gap: 0.25rem; }
  .site-nav__item { flex-wrap: wrap; }
  .site-nav__link {
    flex: 1; padding: 0.625rem 0.75rem; font-size: var(--text-md);
    border-radius: var(--radius-xs);
  }
  .site-nav__link::after { display: none; }
  .site-nav__link:hover { background: var(--navy-800); }
  .site-nav__toggle { margin-left: 0; padding: 0.625rem 0.75rem; color: var(--text-muted); }
  .site-nav__toggle .icon { width: 1rem; height: 1rem; }
  .site-nav__item.is-open .site-nav__toggle .icon { transform: rotate(180deg); }

  .site-nav__dropdown {
    position: static; width: 100%; padding: 0.25rem 0 0.25rem 1rem; display: none;
  }
  .site-nav__item.is-open .site-nav__dropdown { display: block; }
  .site-nav__dropdown li, .site-nav__dropdown li:first-child, .site-nav__dropdown li:last-child {
    background: none; border: 0; box-shadow: none; border-radius: 0;
  }
  .site-nav__dropdown a { padding: 0.5rem 0.75rem; border: 0; border-radius: var(--radius-xs); color: var(--text-muted); }
  .site-nav__dropdown a:hover { background: var(--navy-800); color: var(--brass-400); }

  .site-nav__cta {
    flex-direction: column; align-items: stretch; gap: 0.75rem;
    padding-top: 1rem; margin-top: 0.75rem; border-top: 1px solid var(--navy-700);
  }
  .site-nav__phone { padding: 0.5rem 0.75rem; }
  .site-nav__cta .btn { width: 100%; padding: 0.625rem 1rem; }
}

/* ------------------------------------------------------------------
   Home hero (light — watercolour skyline artwork)
   ------------------------------------------------------------------ */

.hero {
  position: relative; min-height: 100vh; display: flex; align-items: center;
  overflow: hidden; background: #fff;
}
.hero__bg {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center;
}
.hero__scrim {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.7) 50%, transparent 100%);
}
.hero__inner { position: relative; padding-top: 7rem; padding-bottom: 5rem; width: 100%; }
.hero__copy { max-width: 56rem; }

.hero__eyebrow {
  display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1.5rem;
  animation: fadeIn 0.5s ease forwards;
}
.hero__eyebrow::before { content: ''; width: 2rem; height: 1px; background: var(--brass-500); }
.hero__eyebrow span {
  font-size: var(--text-xs); font-weight: 600; letter-spacing: 0.25em; text-transform: uppercase;
  color: var(--brass-600);
}
.hero__title {
  font-size: var(--display-xl); line-height: 1.05; letter-spacing: -0.02em;
  color: var(--navy-900); margin-bottom: 1.5rem;
  animation: fadeUp 0.6s ease forwards;
}
.hero__lead {
  font-size: var(--text-lg); line-height: 1.625; color: var(--navy-700);
  max-width: 42rem; margin-bottom: 2.5rem;
  animation: fadeUp 0.6s ease 0.1s both;
}
@media (min-width: 768px) { .hero__lead { font-size: var(--text-xl); } }

@keyframes fadeUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .hero__eyebrow, .hero__title, .hero__lead { animation: none; }
  html { scroll-behavior: auto; }
}

/* ------------------------------------------------------------------
   Inner page hero
   ------------------------------------------------------------------ */

.page-hero {
  position: relative; overflow: hidden; background: var(--navy-950);
  padding-top: 8rem; padding-bottom: 4rem;
}
.page-hero__grid, .bg-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(0, 130, 175, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 130, 175, 0.05) 1px, transparent 1px);
  background-size: 60px 60px;
}
.page-hero::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 0%, transparent 60%, var(--navy-900) 100%);
}
.page-hero__glow, .glow {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 24rem; height: 12rem; border-radius: 999px;
  background: rgba(0, 130, 175, 0.05); filter: blur(64px);
}
.page-hero__inner { position: relative; z-index: 1; }
.page-hero__title { font-size: var(--display-lg); letter-spacing: -0.02em; line-height: 1.1; max-width: 48rem; }
.page-hero__subtitle { margin-top: 1rem; font-size: var(--text-lg); line-height: 1.625; color: rgba(212, 236, 247, 0.65); max-width: 42rem; }

.crumbs { margin-bottom: 1.5rem; }
.crumbs ol { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; font-size: var(--text-xs); color: var(--text-faint); }
.crumbs li { display: flex; align-items: center; gap: 0.5rem; }
.crumbs a:hover { color: var(--brass-400); }
.crumbs__current { color: var(--brass-400); }

/* ------------------------------------------------------------------
   Prose (long-form page content)
   ------------------------------------------------------------------ */

.prose { color: var(--text); line-height: 1.625; }
.prose > * + * { margin-top: 1.25rem; }
.prose h2 { font-size: var(--display-md); letter-spacing: -0.01em; color: var(--cream-100); padding-top: 1.5rem; }
.prose h2:first-child { padding-top: 0; }
.prose h2.h-2xl { font-size: var(--text-2xl); }
.prose h3 { font-size: var(--text-xl); color: var(--cream-100); padding-top: 1rem; }
.prose h4 { font-size: var(--text-md); color: var(--cream-100); }
.prose h4.caps { text-transform: uppercase; letter-spacing: 0.05em; }
.prose strong { color: var(--cream-100); }
.prose .lead-in { color: var(--cream-100); font-weight: 600; }
.prose .bright { color: var(--cream-100); }
.prose a:not(.btn) { color: var(--brass-400); text-decoration: underline; text-underline-offset: 2px; }
.prose a:not(.btn):hover { color: var(--brass-300); }
.prose--sm { font-size: var(--text-sm); }
.prose--sm > * + * { margin-top: 1rem; }
.prose--xs { font-size: var(--text-xs); color: rgba(212, 236, 247, 0.45); }
.prose--xs > * + * { margin-top: 0.75rem; }

/* Dash-marker lists (house style) */
.dash-list { display: grid; gap: 0.5rem; }
.dash-list li { display: flex; align-items: flex-start; gap: 0.75rem; }
.dash-list li::before {
  content: ''; flex-shrink: 0; width: 0.75rem; height: 1px; margin-top: 0.75rem;
  background: var(--brand-60);
}
.dash-list--sm { font-size: var(--text-sm); }
.dash-list--sm li { gap: 0.5rem; }
.dash-list--sm li::before { width: 0.625rem; margin-top: 0.625rem; }
.dash-list--sage li::before { background: var(--sage-60); }

/* Highlighted benefit blocks (equity release ERC benefits) */
.benefit { border-left: 2px solid var(--brand-40); padding-left: 1.25rem; }
.benefit + .benefit { margin-top: 1.5rem; }
.benefit h5 { font-size: var(--text-lg); font-weight: 700; color: var(--cream-100); margin: 0 0 0.75rem; }
.benefit p + p { margin-top: 0.75rem; }

/* ------------------------------------------------------------------
   Cards & panels
   ------------------------------------------------------------------ */

.card {
  background: var(--navy-800); border: 1px solid var(--navy-700);
  border-radius: var(--radius); padding: 1.25rem;
}
.card--lg { padding: 1.75rem; }
.card--hover { transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease; }
.card--hover:hover { transform: translateY(-4px); box-shadow: 0 8px 40px rgba(0, 130, 175, 0.18); border-color: var(--brand-40); }
.card__title { font-size: var(--text-md); font-weight: 600; color: var(--cream-100); margin-bottom: 0.5rem; }
.card__text { font-size: var(--text-sm); line-height: 1.625; color: var(--text-muted); }

.card-grid { display: grid; gap: 1.25rem; }
@media (min-width: 640px) { .card-grid--2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 768px) { .card-grid--3 { grid-template-columns: repeat(3, 1fr); } .card-grid--2md { grid-template-columns: repeat(2, 1fr); } }

.panel {
  background: var(--navy-800); border: 1px solid var(--brand-20);
  border-radius: var(--radius); padding: 1.5rem;
}
.panel--row { display: flex; flex-direction: column; gap: 1rem; align-items: flex-start; }
@media (min-width: 640px) { .panel--row { flex-direction: row; align-items: center; justify-content: space-between; } }
.panel--lg { padding: 2rem; }
.panel__title { font-size: var(--text-xl); margin-bottom: 0.25rem; }
.panel__text { font-size: var(--text-sm); color: var(--text-muted); line-height: 1.625; }
.panel__fine { font-size: var(--text-xs); color: var(--text-faint); margin-top: 0.75rem; }
.panel__fine a { color: rgba(63, 175, 214, 0.7); }
.panel__fine a:hover { color: var(--brass-400); }
.panel--success { border-color: var(--sage-30); text-align: center; }

/* Regulatory notes */
.note {
  background: var(--navy-950); border: 1px solid var(--brand-20);
  border-radius: var(--radius); padding: 1.25rem;
  font-size: var(--text-xs); font-weight: 600; letter-spacing: 0.025em; text-transform: uppercase;
  line-height: 1.625; color: var(--text);
}
.note p + p { margin-top: 0.5rem; }
.note--icon { display: flex; gap: 0.75rem; align-items: flex-start; }
.note__icon { margin-top: 0.125rem; }
.note--muted { border-color: var(--navy-600); }
.note--strong { border-color: var(--brand-30); padding: 1.5rem; }
.note__heading {
  display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.75rem;
  color: var(--brass-400); letter-spacing: 0.1em;
}
.note--plain {
  font-weight: 400; text-transform: none; letter-spacing: 0;
  border-color: var(--sage-20); color: var(--text-muted);
}
.warn-inline {
  font-size: var(--text-xs); font-weight: 600; letter-spacing: 0.025em; text-transform: uppercase;
  line-height: 1.625; color: var(--text-muted);
  background: var(--navy-950); border: 1px solid var(--brand-20); border-radius: var(--radius); padding: 1rem;
}

/* Pros / cons boxes */
.proscons { display: grid; gap: 1.25rem; }
@media (min-width: 768px) { .proscons { grid-template-columns: repeat(2, 1fr); } }
.proscons__box { background: var(--navy-800); border-radius: var(--radius); padding: 1.25rem; }
.proscons__box--pro { border: 1px solid var(--sage-20); }
.proscons__box--con { border: 1px solid var(--brand-20); }
.proscons__box h4 { font-size: var(--text-md); text-transform: uppercase; letter-spacing: 0.025em; margin-bottom: 0.75rem; }
.proscons__box .dash-list { color: var(--text-muted); }

/* Badges */
.badge {
  display: inline-block; padding: 0.375rem 0.75rem; border-radius: 0.25rem;
  font-size: var(--text-xs); font-weight: 500; background: var(--navy-800);
}
.badge--brand { border: 1px solid var(--brand-20); color: var(--brass-400); }
.badge--sage { border: 1px solid var(--sage-20); color: var(--sage-400); }

/* Document link card */
.doc-link {
  display: flex; align-items: center; gap: 1rem;
  background: var(--navy-800); border: 1px solid var(--brand-20); border-radius: var(--radius);
  padding: 1.5rem; transition: border-color 0.2s ease;
}
.doc-link:hover { border-color: var(--brand-40); }
.doc-link__title { display: block; font-size: var(--text-sm); font-weight: 600; color: var(--cream-100); transition: color 0.2s ease; }
.doc-link:hover .doc-link__title { color: var(--brass-300); }
.doc-link__sub { display: block; font-size: var(--text-xs); color: var(--text-soft); margin-top: 0.125rem; }

/* Social buttons */
.social-btn {
  width: 2.25rem; height: 2.25rem; border-radius: var(--radius-sm);
  background: var(--navy-800); border: 1px solid var(--navy-700);
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--text-soft); transition: color 0.2s ease, border-color 0.2s ease;
}
.social-btn:hover { color: var(--brass-400); border-color: var(--brand-40); }
.social-pill {
  display: inline-flex; align-items: center; gap: 0.625rem; padding: 0.625rem 1rem;
  background: var(--navy-800); border: 1px solid var(--navy-700); border-radius: var(--radius-sm);
  font-size: var(--text-sm); color: var(--text-muted);
}
.social-pill:hover { color: var(--brass-400); border-color: var(--brand-40); }

/* ------------------------------------------------------------------
   Forms
   ------------------------------------------------------------------ */

.input {
  width: 100%; background: var(--navy-700); border: 1px solid var(--navy-600);
  border-radius: var(--radius-sm); padding: 0.75rem 1rem;
  font-family: inherit; font-size: var(--text-sm); color: var(--cream-100);
  transition: border-color 0.2s ease;
}
.input::placeholder { color: rgba(212, 236, 247, 0.3); }
.input:focus { outline: none; border-color: var(--brass-500); }
.input--sm { padding: 0.625rem 1rem; }
textarea.input { resize: vertical; min-height: 7rem; }
select.input { appearance: auto; }

.field { display: block; }
.field + .field { margin-top: 1.25rem; }
.field__label { display: block; font-size: var(--text-xs); color: var(--text-muted); margin-bottom: 0.375rem; }
.field__label .opt { color: var(--text-ghost); }
.field__error { font-size: var(--text-xs); color: #f87171; margin-bottom: 0.375rem; }
.field--invalid .input { border-color: #f87171; }
.field-grid { display: grid; gap: 1rem; }
@media (min-width: 640px) { .field-grid--2 { grid-template-columns: repeat(2, 1fr); } .field-grid--3 { grid-template-columns: repeat(3, 1fr); } }

.form-error { font-size: var(--text-sm); color: #f87171; margin-bottom: 0.75rem; }
.form-error-summary {
  background: rgba(248, 113, 113, 0.08); border: 1px solid rgba(248, 113, 113, 0.4);
  border-radius: var(--radius); padding: 1rem 1.25rem; font-size: var(--text-sm);
}
.form-error-summary h3 { font-size: var(--text-md); margin-bottom: 0.5rem; }
.form-error-summary ul { display: grid; gap: 0.25rem; }
.form-error-summary a { color: #f87171; text-decoration: underline; }

.consent {
  border: 1px solid var(--navy-600); border-radius: var(--radius); padding: 1.25rem;
  background: rgba(0, 68, 96, 0.5); display: grid; gap: 0.75rem;
}
.consent__heading { font-size: var(--text-xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-soft); }
.check { display: flex; align-items: flex-start; gap: 0.75rem; cursor: pointer; font-size: var(--text-xs); line-height: 1.625; color: rgba(212, 236, 247, 0.65); }
.check input { margin: 0.2rem 0 0; width: 1rem; height: 1rem; flex-shrink: 0; accent-color: var(--brass-500); }
.check strong { color: rgba(212, 236, 247, 0.9); }
.check a { color: rgba(63, 175, 214, 0.8); }
.check a:hover { color: var(--brass-400); }
.check .req { color: rgba(248, 113, 113, 0.7); }

.guide-form__row { display: grid; gap: 0.75rem; margin-top: 1rem; }
@media (min-width: 640px) { .guide-form__row { grid-template-columns: 1fr 1fr auto; } }
.guide-form .input { padding: 0.625rem 1rem; }

/* Contact page */
.contact-layout { display: grid; gap: 4rem; }
@media (min-width: 1024px) { .contact-layout { grid-template-columns: repeat(2, 1fr); } }
.contact-list { display: grid; gap: 1.5rem; }
.contact-item { display: flex; align-items: flex-start; gap: 1rem; }
.contact-item .icon-box { transition: background-color 0.2s ease; }
.contact-item:hover .icon-box { background: var(--brand-20); }
.contact-item__label { display: block; font-size: var(--text-xs); color: rgba(212, 236, 247, 0.45); margin-bottom: 0.125rem; }
.contact-item__value { display: block; font-size: var(--text-sm); color: var(--cream-100); transition: color 0.2s ease; }
.contact-item:hover .contact-item__value { color: var(--brass-300); }
.map-box {
  margin-top: 1.5rem; height: 12rem; display: flex; align-items: center; justify-content: center;
  background: var(--navy-800); border: 1px solid var(--navy-700); border-radius: var(--radius);
}
.map-box a { display: inline-flex; align-items: center; gap: 0.5rem; font-size: var(--text-sm); color: var(--brass-400); }
.map-box a:hover { color: var(--brass-300); }
.contact-form { display: grid; gap: 1.25rem; align-content: start; }
.contact-form h2 { font-size: var(--display-md); }
.contact-form .field + .field { margin-top: 0; }

/* Success state */
.success {
  background: var(--navy-800); border: 1px solid var(--sage-30); border-radius: var(--radius);
  padding: 2.5rem; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 1rem;
}
.success__icon {
  width: 3.5rem; height: 3.5rem; border-radius: 999px; background: var(--sage-20);
  display: inline-flex; align-items: center; justify-content: center; color: var(--sage-400);
}
.success__icon .icon { width: 1.75rem; height: 1.75rem; }
.success h1, .success h2 { font-size: var(--text-xl); }
.success p { font-size: var(--text-sm); color: rgba(212, 236, 247, 0.65); max-width: 26rem; }

/* ------------------------------------------------------------------
   Homepage sections
   ------------------------------------------------------------------ */

.section-head { margin-bottom: 3.5rem; }
.section-head p { margin-top: 0.75rem; color: var(--text-muted); }

.service { display: flex; flex-direction: column; }
.service .icon-box { margin-bottom: 1.25rem; }
.service__title { font-size: var(--text-xl); margin-bottom: 0.75rem; }
.service__title a:hover { color: var(--brass-300); }
.service__text { font-size: var(--text-sm); line-height: 1.625; color: var(--text-muted); margin-bottom: 1.25rem; flex: 1; }
.service__links { display: grid; gap: 0.375rem; margin-bottom: 1.25rem; }
.service__links a { display: flex; align-items: center; gap: 0.5rem; font-size: var(--text-xs); color: var(--text-soft); }
.service__links a::before { content: ''; width: 0.75rem; height: 1px; background: var(--brand-40); flex-shrink: 0; }
.service__links a:hover { color: var(--brass-400); }
.service__more { display: flex; justify-content: flex-end; padding-top: 1rem; border-top: 1px solid var(--navy-700); }
.more-link { display: inline-flex; align-items: center; gap: 0.25rem; font-size: var(--text-xs); font-weight: 500; color: var(--brass-400); }
.more-link:hover { color: var(--brass-300); }
.more-link .icon { width: 0.75rem; height: 0.75rem; }

.split { display: grid; gap: 4rem; align-items: center; position: relative; }
@media (min-width: 1024px) { .split { grid-template-columns: repeat(2, 1fr); } }
.split__intro { font-weight: 600; color: rgba(212, 236, 247, 0.75); margin-bottom: 1.5rem; }
.split .prose { color: rgba(212, 236, 247, 0.65); }
.split .prose > * + * { margin-top: 1rem; }

.about-card { background: var(--navy-800); border: 1px solid var(--brand-20); border-radius: var(--radius); padding: 2rem; }
.about-card h3 { font-size: var(--text-2xl); margin-bottom: 1.25rem; }
.about-card .prose { font-size: var(--text-sm); }

.section--textured { position: relative; overflow: hidden; }
.section--textured .bg-grid { opacity: 0.5; }
.section--textured .container { position: relative; }
.section--textured .glow-right {
  position: absolute; right: 0; top: 50%; transform: translateY(-50%);
  width: 20rem; height: 20rem; border-radius: 999px; background: rgba(0, 130, 175, 0.04); filter: blur(64px);
}
.section--tint::before {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(0, 130, 175, 0.05), transparent, rgba(61, 144, 96, 0.05));
}

.cta-block { text-align: center; }
.cta-block h2 { font-size: var(--display-md); margin-bottom: 1.5rem; }
.cta-block .eyebrow { margin-bottom: 1rem; }
.cta-block p:not(.eyebrow) { color: rgba(212, 236, 247, 0.65); max-width: 36rem; margin: 0 auto 2.5rem; }

/* Carousel (scroll-snap, prev/next buttons) */
.carousel { position: relative; }
.carousel__track {
  display: flex; gap: 1.25rem; overflow-x: auto; padding-bottom: 0.5rem;
  scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none;
}
.carousel__track::-webkit-scrollbar { display: none; }
.carousel__track > * { scroll-snap-align: start; flex-shrink: 0; }
.carousel__nav { display: flex; justify-content: flex-end; gap: 0.5rem; margin-top: 1rem; }
.carousel__btn {
  width: 2.25rem; height: 2.25rem; border-radius: 999px; background: none;
  border: 1px solid var(--navy-600); color: var(--text-muted);
  display: inline-flex; align-items: center; justify-content: center;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.carousel__btn:hover { border-color: var(--brand-50); color: var(--brass-400); }
.carousel__btn .icon { width: 1rem; height: 1rem; }

.lender-card {
  width: 13rem; height: 7rem; padding: 0 1.5rem;
  background: #fff; border: 1px solid var(--navy-700); border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
}
.lender-card img { max-height: 4rem; max-width: 100%; width: auto; height: auto; object-fit: contain; }

.testimonial { width: 20rem; padding: 1.75rem; }
.testimonial p { font-size: var(--text-sm); font-style: italic; color: var(--text-faint); }

/* Trust bar */
.trust-bar { background: var(--navy-950); border-top: 1px solid var(--brand-10); border-bottom: 1px solid var(--brand-10); padding-block: 1.25rem; overflow-x: auto; }
.trust-bar__inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-width: max-content; }
.trust-bar__badge { display: flex; align-items: center; gap: 0.625rem; }
.trust-bar__badge img { height: 2.25rem; width: auto; object-fit: contain; }
.trust-bar__icon { font-size: var(--text-xl); }
.trust-bar__text { display: flex; flex-direction: column; text-align: left; }
.trust-bar__label { font-size: var(--text-xs); font-weight: 600; color: var(--cream-100); transition: color 0.2s ease; }
.trust-bar__badge:hover .trust-bar__label { color: var(--brass-300); }
.trust-bar__detail { font-size: 0.625rem; color: var(--text-soft); }

/* ------------------------------------------------------------------
   Page-specific
   ------------------------------------------------------------------ */

/* Mortgages: type cards */
.type-card__title { font-size: var(--text-lg); margin-bottom: 0.75rem; }
.type-card__title a:hover { color: var(--brass-300); }
.type-card__more { padding-top: 0.5rem; border-top: 1px solid var(--navy-700); }

/* Calculator */
.calc { display: grid; gap: 1.25rem; }
.calc__result { display: none; }
.calc__result.is-visible { display: grid; }
.stat { padding: 1.25rem; border-radius: var(--radius); background: var(--navy-700); border: 1px solid var(--navy-600); }
.stat--brand { border-color: var(--brand-30); }
.stat__label { font-size: var(--text-xs); color: var(--text-soft); margin-bottom: 0.25rem; }
.stat__value { font-size: var(--text-3xl); font-weight: 700; color: rgba(212, 236, 247, 0.8); }
.stat--brand .stat__value { color: var(--brass-400); }

/* Mortgage Brain best buy tables embed */
.embed-frame { background: #fff; border: 1px solid var(--navy-700); border-radius: var(--radius); overflow: hidden; }
#idIframe { width: 100%; height: 748px; scroll-margin-top: 7rem; }
#idIframe iframe { width: 100%; height: 100%; border: 0; display: block; overflow: hidden; }

/* Anchored sections under a fixed header */
.anchor { scroll-margin-top: 7rem; }

/* Home insurance cover cards */
.cover-card h3 { font-size: var(--text-md); font-weight: 600; margin-bottom: 0.5rem; }
.cover-card p { font-size: var(--text-sm); color: var(--text-muted); line-height: 1.625; }

/* Blog empty state */
.empty {
  background: var(--navy-800); border: 1px solid var(--navy-700); border-radius: var(--radius);
  padding: 2.5rem; text-align: center; font-size: var(--text-sm); color: var(--text-soft);
}

/* 404 / error */
.status-page { min-height: 100vh; background: var(--navy-950); display: flex; align-items: center; justify-content: center; padding: 6rem 1rem 4rem; }
.status-page__inner { text-align: center; max-width: 28rem; }
.status-page__code { font-size: 6rem; font-weight: 600; line-height: 1; color: var(--brand-20); margin-bottom: 1rem; }
.status-page h1 { font-size: var(--text-2xl); margin-bottom: 1rem; }
.status-page p { color: var(--text-muted); margin-bottom: 2rem; }

/* Dialog */
.modal {
  background: var(--navy-800); border: 1px solid var(--brand-30); border-radius: var(--radius);
  padding: 1.75rem; max-width: 32rem; width: calc(100% - 2rem); color: var(--cream-100);
  box-shadow: var(--shadow-navy);
}
.modal::backdrop { background: rgba(0, 21, 32, 0.8); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.modal__title { font-size: var(--text-xl); margin-bottom: 1rem; }
.modal__text { font-size: var(--text-sm); line-height: 1.625; color: var(--text); margin-bottom: 1.5rem; }
.modal__actions { display: flex; justify-content: flex-end; gap: 0.75rem; }

/* ------------------------------------------------------------------
   Footer
   ------------------------------------------------------------------ */

.site-footer { background: var(--navy-950); border-top: 1px solid var(--brand-10); }
.site-footer__main { display: grid; gap: 2.5rem; padding-block: 4rem; }
@media (min-width: 768px) { .site-footer__main { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .site-footer__main { grid-template-columns: 2fr 1fr 1fr 1fr; } }

.site-footer__brand img { height: 2.75rem; width: auto; filter: brightness(0) invert(1); opacity: 0.9; margin-bottom: 1.25rem; }
.site-footer__strap { font-size: var(--text-sm); line-height: 1.625; color: var(--text-muted); max-width: 20rem; margin-bottom: 1.5rem; }
.site-footer__contact { display: grid; gap: 0.5rem; font-size: var(--text-sm); color: var(--text-muted); }
.site-footer__contact a:hover { color: var(--brass-400); }
.site-footer__badges { display: flex; gap: 0.75rem; margin-top: 1.5rem; }
.site-footer__social { display: flex; gap: 0.75rem; margin-top: 1.5rem; }

.site-footer__heading {
  font-size: var(--text-xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em;
  color: rgba(0, 130, 175, 0.7); margin-bottom: 1rem;
}
.site-footer__list { display: grid; gap: 0.625rem; }
.site-footer__list a { font-size: var(--text-sm); color: rgba(212, 236, 247, 0.55); }
.site-footer__list a:hover { color: var(--brass-400); }

.site-footer__legal { padding-block: 1.5rem; display: grid; gap: 0.75rem; font-size: var(--text-xs); line-height: 1.625; color: var(--text-ghost); }
.site-footer__legal a { color: rgba(0, 130, 175, 0.6); }
.site-footer__legal a:hover { color: var(--brass-400); }
.site-footer__legal p:last-child a { color: inherit; }
.site-footer__legal p:last-child a:hover { color: var(--text-muted); }
.link-button { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; transition: color 0.2s ease; }
.link-button:hover { color: var(--text-muted); }

/* Marquee carousel (continuous slow scroll, built by main.js) */
.carousel--marquee .carousel__track {
  overflow-x: hidden; scroll-snap-type: none; padding-bottom: 0;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent);
  mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent);
}
.carousel__marquee {
  display: flex; gap: 1.25rem; width: max-content; will-change: transform;
  animation: carousel-marquee var(--marquee-duration, 60s) linear infinite;
}
.carousel__marquee > * { flex-shrink: 0; }
.carousel--marquee:hover .carousel__marquee,
.carousel--marquee:focus-within .carousel__marquee { animation-play-state: paused; }
@keyframes carousel-marquee { to { transform: translateX(var(--marquee-shift, -50%)); } }
@media (prefers-reduced-motion: reduce) {
  .carousel__marquee { animation: none; }
  .carousel--marquee .carousel__track { overflow-x: auto; -webkit-mask-image: none; mask-image: none; }
}
