/*
 Theme Name:   National Wealth Advisors
 Theme URI:    https://nwadvisorsinc.com
 Description:  Genesis child theme for National Wealth Advisors Inc.
 Author:       Lawton Marketing Group
 Author URI:   https://lawtonmg.com
 Template:     genesis
 Version:      1.0.0
 License:      GPL-2.0-or-later
 Text Domain:  nwa
*/

/* mfin1 — custom styles on top of Tailwind
   Placeholders replaced at build time: #002d5c -> primary, #001b35 -> secondary */

:root {
  --color-primary: #002d5c;
  --color-secondary: #001b35;
}

html { scroll-behavior: smooth; }
body {
  font-family: 'Lato', ui-sans-serif, system-ui, sans-serif;
  /* Offset for fixed header when jumping to anchors */
}

/* Header: transparent over the hero on landing, solid white once scrolled
   (with a subtle shadow). On landing the logo + nav render white; on scroll
   they return to the brand colors. */
#site-header {
  background-color: transparent;
}
#site-header.scrolled {
  background-color: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

/* Logo: knocked out to white on landing, full color once scrolled. The
   background override removes the white plate some pages put behind the logo. */
#site-header .logo-white { display: none; }
#site-header .logo-color { display: block; }
#site-header .site-logo,
#site-header .logo-color {
  background-color: transparent;
  filter: brightness(0) invert(1);
  transition: filter 300ms ease;
}
#site-header.scrolled .site-logo,
#site-header.scrolled .logo-color {
  filter: none;
}

/* Hero: localized scrim behind the headline block so the white type stays
   legible without darkening the rest of the image. */
.hero-text-scrim {
  background-image: radial-gradient(
    ellipse 70% 55% at 50% 78%,
    rgba(0, 0, 0, 0.45) 0%,
    rgba(0, 0, 0, 0.28) 45%,
    rgba(0, 0, 0, 0) 75%
  );
}

/* Home hero below lg: center the headline block in the (visible) viewport
   instead of pinning it to the bottom, which left a tall empty gap under
   the logo and pushed the CTA below the fold on phones. */
@media (max-width: 1023px) {
  section.hero {
    min-height: 100vh;
    min-height: 100svh;
    align-items: center;
  }
  section.hero > .relative.z-10 {
    padding-top: 6.5rem;
    padding-bottom: 3rem;
  }
  .hero-text-scrim {
    background-image: radial-gradient(
      ellipse 90% 45% at 50% 55%,
      rgba(0, 0, 0, 0.45) 0%,
      rgba(0, 0, 0, 0.28) 45%,
      rgba(0, 0, 0, 0) 75%
    );
  }
}

/* Page hero "fit" variant (Hero > Show the whole featured image): the banner
   takes the image's own aspect ratio so nothing is cropped. Below lg the
   photo would be too short to hold the title, so it stacks: header band,
   full photo, then the title on the brand color. */
.page-hero.page-hero--fit {
  height: auto;
  min-height: 0;
  flex-direction: column;
  align-items: stretch;
  padding-top: 5rem;
}
.page-hero--fit .page-hero-img {
  position: relative;
  inset: auto;
  width: 100%;
  aspect-ratio: var(--hero-ar);
}
.page-hero--fit .page-hero-shade { display: none; }
.page-hero--fit .page-hero-text {
  padding-top: 1.75rem;
  padding-bottom: 2.25rem;
}
.page-hero--fit h1 { font-size: 3.25rem; }
@media (min-width: 1024px) {
  .page-hero.page-hero--fit {
    display: flex;
    flex-direction: row;
    align-items: flex-end;
    padding-top: 0;
    aspect-ratio: var(--hero-ar);
  }
  .page-hero--fit .page-hero-img {
    position: absolute;
    inset: 0;
    aspect-ratio: auto;
  }
  .page-hero--fit .page-hero-shade { display: block; }
  .page-hero--fit .page-hero-text {
    padding-top: 8rem;
    padding-bottom: 4rem;
  }
  .page-hero--fit h1 { font-size: 4.5rem; }
}

/* Nav links + menu toggle: white on landing, brand primary once scrolled */
#site-header .nav-link,
#site-header .menu-toggle { color: #ffffff; }
#site-header.scrolled .nav-link,
#site-header.scrolled .menu-toggle { color: var(--color-primary); }

/* Client-login button: white outline on landing, brand primary once scrolled */
#site-header .portal-btn {
  color: #ffffff;
  border-color: #ffffff;
}
#site-header .portal-btn:hover {
  background-color: #ffffff;
  color: var(--color-secondary);
}
#site-header.scrolled .portal-btn {
  color: var(--color-primary);
  border-color: var(--color-primary);
}
#site-header.scrolled .portal-btn:hover {
  background-color: var(--color-primary);
  color: #ffffff;
}

/* Site logo — larger at the top of the page, shrinks on scroll */
#site-header .site-logo {
  height: 3rem;               /* ~48px on mobile when landed */
  max-width: 260px;
  transition:
    height 320ms cubic-bezier(0.4, 0, 0.2, 1),
    max-width 320ms cubic-bezier(0.4, 0, 0.2, 1);
}
@media (min-width: 1024px) {
  #site-header .site-logo {
    height: 4.5rem;            /* ~72px landing on desktop */
    max-width: 380px;
  }
}
#site-header.scrolled .site-logo {
  height: 2.25rem;             /* h-9 — mobile scrolled */
  max-width: 220px;
}
@media (min-width: 1024px) {
  #site-header.scrolled .site-logo {
    height: 2.5rem;            /* h-10 — desktop scrolled */
    max-width: 260px;
  }
}

/* Mobile menu open state */
body.menu-open { overflow: hidden; }

/* Mobile menu panel: capped to the space below the header. dvh tracks the
   visible viewport on iOS (vh includes the area behind the browser toolbar,
   which hid the last items). The header is ~80px tall on mobile. */
#mobile-menu {
  max-height: calc(100vh - 5rem);
  max-height: calc(100dvh - 5rem);
  overscroll-behavior: contain;
  padding-bottom: env(safe-area-inset-bottom);
}

/* ------------------------------------------------------------
   Top-level nav: animated gold bar under each link.
   - Hover/focus: bar scales in from center (scaleX 0 -> 1).
   - `.is-active` keeps the bar pinned for the current page.
   ------------------------------------------------------------ */
#site-header .nav-link {
  position: relative;
  padding-bottom: 6px;
}
#site-header .nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: #ffffff;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 320ms cubic-bezier(0.4, 0, 0.2, 1);
}
#site-header .nav-link:hover::after,
#site-header .nav-link:focus-visible::after,
#site-header .nav-link.is-active::after {
  transform: scaleX(1);
}
/* Underline accent: white on landing, brand dark once scrolled */
#site-header.scrolled .nav-link::after {
  background: var(--color-secondary);
}

/* ------------------------------------------------------------
   Submenu: white card + staggered item entrance.
   Container visibility is handled by Tailwind utilities on the HTML
   (invisible/opacity-0 + group-hover:visible/group-hover:opacity-100).
   The card + per-item animations below trigger on `.nav-item:hover`.
   ------------------------------------------------------------ */
.nav-submenu-card {
  opacity: 0;
  transform: translateY(-6px) scale(0.97);
  transform-origin: top center;
  transition: opacity 220ms ease-out, transform 260ms cubic-bezier(0.2, 0.8, 0.2, 1);
}
.nav-item:hover .nav-submenu-card,
.nav-item:focus-within .nav-submenu-card {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.nav-submenu-card > a {
  opacity: 0;
  transform: translateX(-14px);
  transition: opacity 300ms ease-out, transform 360ms cubic-bezier(0.2, 0.8, 0.2, 1), color 180ms ease-out, background-color 180ms ease-out;
}
.nav-item:hover .nav-submenu-card > a,
.nav-item:focus-within .nav-submenu-card > a {
  opacity: 1;
  transform: translateX(0);
}
.nav-item:hover .nav-submenu-card > a:nth-child(1),
.nav-item:focus-within .nav-submenu-card > a:nth-child(1) { transition-delay: 80ms, 80ms, 0ms, 0ms; }
.nav-item:hover .nav-submenu-card > a:nth-child(2),
.nav-item:focus-within .nav-submenu-card > a:nth-child(2) { transition-delay: 140ms, 140ms, 0ms, 0ms; }
.nav-item:hover .nav-submenu-card > a:nth-child(3),
.nav-item:focus-within .nav-submenu-card > a:nth-child(3) { transition-delay: 200ms, 200ms, 0ms, 0ms; }
.nav-item:hover .nav-submenu-card > a:nth-child(4),
.nav-item:focus-within .nav-submenu-card > a:nth-child(4) { transition-delay: 260ms, 260ms, 0ms, 0ms; }
.nav-item:hover .nav-submenu-card > a:nth-child(5),
.nav-item:focus-within .nav-submenu-card > a:nth-child(5) { transition-delay: 320ms, 320ms, 0ms, 0ms; }
.nav-item:hover .nav-submenu-card > a:nth-child(6),
.nav-item:focus-within .nav-submenu-card > a:nth-child(6) { transition-delay: 380ms, 380ms, 0ms, 0ms; }

/* Sub-item active state: gold text for the current page link. */
.nav-submenu-card > a.is-active {
  color: var(--color-secondary);
}

/* ------------------------------------------------------------
   Bio modal (<dialog> element).
   - Native <dialog> handles ESC + focus trap + body scroll lock.
   - @starting-style drives the elegant scale + fade entrance.
   ------------------------------------------------------------ */
dialog.bio-modal,
dialog.content-modal {
  max-width: 1200px;
  width: calc(100% - 2rem);
  height: min(760px, calc(100vh - 4rem));
  max-height: calc(100vh - 4rem);
  padding: 0;
  border: none;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 25px 60px -12px rgba(0, 0, 0, 0.45);
  overflow: visible;
}
dialog.content-modal {
  max-width: 800px;
}
dialog.bio-modal[open],
dialog.content-modal[open] {
  animation: bioModalIn 320ms cubic-bezier(0.2, 0.9, 0.3, 1) both;
}
dialog.bio-modal::backdrop,
dialog.content-modal::backdrop {
  background: rgba(11, 31, 58, 0.72);
  backdrop-filter: blur(4px);
  animation: bioModalBackdropIn 320ms ease-out both;
}
@keyframes bioModalIn {
  from { opacity: 0; transform: scale(0.94) translateY(18px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes bioModalBackdropIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Shared modal internals — applies to bio-modal and content-modal */
.content-modal-body {
  height: 100%;
  overflow-y: auto;
  padding: 2rem;
}
@media (min-width: 768px) { .content-modal-body { padding: 3rem; } }
@media (min-width: 1024px) { .content-modal-body { padding: 4rem; } }

.content-modal-close {
  position: absolute;
  top: -1.25rem;
  right: -1.25rem;
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 9999px;
  background: var(--color-primary);
  color: #ffffff;
  border: 2px solid #ffffff;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  z-index: 10;
  transition: transform 240ms cubic-bezier(0.2, 0.9, 0.3, 1), background-color 200ms ease-out, color 200ms ease-out;
}
.content-modal-close:hover,
.content-modal-close:focus-visible {
  background: var(--color-secondary);
  transform: rotate(90deg) scale(1.05);
  outline: none;
}

.content-modal-icon {
  width: 4rem;
  height: 4rem;
  border-radius: 9999px;
  background: #f8fafc;
  color: var(--color-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  flex-shrink: 0;
}

body:has(dialog.bio-modal[open]),
body:has(dialog.content-modal[open]),
body:has(dialog.leave-modal[open]) { overflow: hidden; }

/* Leaving-site notice — compact confirm dialog (markup in the footer). */
dialog.leave-modal {
  max-width: 560px;
  width: calc(100% - 2rem);
  max-height: calc(100vh - 2rem);
  max-height: calc(100dvh - 2rem);
  padding: 0;
  border: none;
  border-top: 4px solid var(--color-primary);
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 25px 60px -12px rgba(0, 0, 0, 0.45);
  overflow-y: auto;
}
dialog.leave-modal[open] {
  animation: bioModalIn 320ms cubic-bezier(0.2, 0.9, 0.3, 1) both;
}
dialog.leave-modal::backdrop {
  background: rgba(11, 31, 58, 0.72);
  backdrop-filter: blur(4px);
  animation: bioModalBackdropIn 320ms ease-out both;
}
.leave-modal-body { padding: 2rem 1.5rem; }
@media (min-width: 640px) { .leave-modal-body { padding: 2.75rem 3rem; } }
.leave-modal-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.75rem;
}
.leave-modal-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 8.5rem;
  padding: 0.9rem 1.75rem;
  border: 1px solid var(--color-primary);
  background: var(--color-primary);
  color: #ffffff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 200ms ease-out, color 200ms ease-out, border-color 200ms ease-out;
}
.leave-modal-btn:hover,
.leave-modal-btn:focus-visible {
  background: var(--color-secondary);
  border-color: var(--color-secondary);
}
.leave-modal-btn--ghost {
  background: transparent;
  color: var(--color-primary);
}
.leave-modal-btn--ghost:hover,
.leave-modal-btn--ghost:focus-visible {
  background: #f8fafc;
  color: var(--color-secondary);
}
@media (max-width: 479px) {
  .leave-modal-btn { flex: 1 1 0; min-width: 0; }
}

/* Clickable headshot */
.team-card .headshot {
  transition: opacity 220ms ease-out, transform 320ms cubic-bezier(0.2, 0.9, 0.3, 1);
}
.team-card .headshot:hover {
  opacity: 0.92;
  transform: translateY(-2px);
}
/* Only cards that open a bio look clickable; the rest keep the hover motion. */
button.team-card .headshot { cursor: pointer; }
/* <button> centres its content vertically; pin bio cards to the top of the row like the <div> cards */
button.team-card { align-self: flex-start; }

/* ------------------------------------------------------------
   Service cards
   ------------------------------------------------------------ */
.service-card {
  position: relative;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 2.5rem 2rem;
  cursor: default;
  transition: transform 320ms cubic-bezier(0.2, 0.9, 0.3, 1), box-shadow 320ms ease-out, border-color 320ms ease-out;
  overflow: hidden;
}
.service-card[data-modal],
.service-card[role="button"],
a.service-card,
button.service-card { cursor: pointer; }
.service-card:focus-visible {
  outline: 2px solid var(--color-secondary);
  outline-offset: 3px;
}
.service-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--color-secondary);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 360ms cubic-bezier(0.2, 0.9, 0.3, 1);
}
.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -15px rgba(11, 31, 58, 0.25);
  border-color: transparent;
}
.service-card:hover::before {
  transform: scaleX(1);
}

.service-icon {
  width: 4rem;
  height: 4rem;
  border-radius: 9999px;
  background: #f8fafc;
  color: var(--color-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin-bottom: 1.75rem;
  transition: background-color 320ms ease-out, color 320ms ease-out, transform 320ms cubic-bezier(0.2, 0.9, 0.3, 1);
}
.service-card:hover .service-icon {
  background: var(--color-primary);
  color: #ffffff;
  transform: scale(1.05);
}

.service-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  color: var(--color-primary);
  font-size: 11px;
  letter-spacing: 0.25em;
  font-weight: 600;
  text-transform: uppercase;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  transition: color 220ms ease-out, gap 220ms ease-out;
}
.service-more-btn i {
  font-size: 10px;
  transition: transform 320ms cubic-bezier(0.2, 0.9, 0.3, 1);
}
.service-more-btn:hover {
  color: var(--color-secondary);
  gap: 1rem;
}
.service-more-btn:hover i {
  transform: translateX(4px);
}

/* ------------------------------------------------------------
   Process steps — large numeral + title + description row.
   ------------------------------------------------------------ */
.process-step {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem 2rem;
  align-items: center;
  padding: 2rem 0;
  border-bottom: 1px solid #e2e8f0;
}
.process-step:last-child { border-bottom: 0; }

@media (min-width: 640px) {
  .process-step {
    grid-template-columns: auto 1fr;
    padding: 2.5rem 0;
  }
}
@media (min-width: 1024px) {
  .process-step {
    grid-template-columns: minmax(140px, 200px) minmax(240px, 360px) 1fr;
    gap: 3rem;
    padding: 3rem 0;
  }
}

.step-number {
  font-family: 'EB Garamond', ui-serif, Georgia, serif;
  font-size: 3.5rem;
  font-weight: 400;
  line-height: 1;
  color: #cbd5e1;
  letter-spacing: 0.02em;
}
@media (min-width: 1024px) {
  .step-number { font-size: 5rem; }
}

.step-title {
  font-family: 'EB Garamond', ui-serif, Georgia, serif;
  font-size: 2rem;
  color: var(--color-primary);
  line-height: 1.2;
}

.step-description {
  color: #475569;
  line-height: 1.65;
  max-width: 640px;
}

/* ------------------------------------------------------------
   Contact form
   ------------------------------------------------------------ */
.contact-form {
  display: flex;
  flex-direction: column;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 2rem;
}
@media (min-width: 640px) {
  .form-grid { grid-template-columns: 1fr 1fr; gap: 1.75rem; }
}
.form-field--full { grid-column: 1 / -1; }

.form-field label {
  display: block;
  font-size: 11px;
  letter-spacing: 0.22em;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: 0.6rem;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0;
  color: #0f172a;
  font-family: inherit;
  font-size: 0.95rem;
  line-height: 1.4;
  transition: border-color 200ms ease-out, box-shadow 200ms ease-out, background-color 200ms ease-out;
  appearance: none;
  -webkit-appearance: none;
}
.form-field textarea {
  resize: vertical;
  min-height: 8rem;
}
/* iOS Safari zooms the page when focusing inputs under 16px */
@media (max-width: 639px) {
  .form-field input,
  .form-field select,
  .form-field textarea { font-size: 16px; }
}
.form-field.is-invalid input,
.form-field.is-invalid textarea { border-color: var(--color-primary); box-shadow: inset 0 0 0 1px var(--color-primary); }
.form-error {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.8rem;
  color: var(--color-primary);
  font-weight: 600;
}
.contact-form-success {
  font-size: 1rem;
  color: #475569;
  line-height: 1.65;
  padding: 2rem;
  background: #f8fafc;
  border-top: 4px solid var(--color-secondary);
}
.contact-form-success:focus { outline: none; }
.form-field input:hover,
.form-field select:hover,
.form-field textarea:hover {
  border-color: #cbd5e1;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--color-secondary);
  box-shadow: 0 0 0 3px rgba(193, 154, 91, 0.18);
  background: #ffffff;
}

.select-wrap { position: relative; }
.select-wrap select { padding-right: 2.75rem; cursor: pointer; }
.select-caret {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-primary);
  font-size: 11px;
  pointer-events: none;
}

.submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1rem 2.25rem;
  background: var(--color-primary);
  color: #ffffff;
  border: 0;
  font-size: 11px;
  letter-spacing: 0.25em;
  font-weight: 600;
  text-transform: uppercase;
  cursor: pointer;
  align-self: flex-start;
  transition: background-color 220ms ease-out, transform 220ms cubic-bezier(0.2, 0.9, 0.3, 1), box-shadow 220ms ease-out, gap 220ms ease-out;
}
.submit-btn i { font-size: 10px; transition: transform 320ms cubic-bezier(0.2, 0.9, 0.3, 1); }
.submit-btn:hover {
  background: var(--color-secondary);
  transform: translateY(-2px);
  box-shadow: 0 12px 24px -10px rgba(193, 154, 91, 0.6);
  gap: 1rem;
}
.submit-btn:hover i { transform: translateX(3px); }
.submit-btn:focus-visible {
  outline: 3px solid rgba(193, 154, 91, 0.35);
  outline-offset: 2px;
}

/* ------------------------------------------------------------
   Contact sidebar
   ------------------------------------------------------------ */
.contact-panel {
  background: #f8fafc;
  padding: 2rem 1.5rem;
  border-top: 4px solid var(--color-secondary);
}
@media (min-width: 640px) {
  .contact-panel { padding: 2.5rem 2rem; }
}
@media (min-width: 1024px) {
  .contact-panel { padding: 3rem 2.5rem; }
}

.contact-info-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 1rem;
  padding: 1.25rem 0;
  border-bottom: 1px solid #e2e8f0;
}
.contact-info-row--last { border-bottom: 0; }
.contact-info-icon {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 9999px;
  background: #ffffff;
  color: var(--color-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}
.contact-info-label {
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--color-secondary);
  margin-bottom: 0.35rem;
}
.contact-info-value {
  color: var(--color-primary);
  font-size: 0.95rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.contact-info-link {
  display: inline-block;
  color: var(--color-primary);
  text-decoration: none;
  transition: color 180ms ease-out;
  margin-top: 0.25rem;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.contact-info-link:hover { color: var(--color-secondary); }

.contact-social { margin-top: 2rem; padding: 0 2rem; }
@media (min-width: 1024px) {
  .contact-social { padding: 0 2.5rem; }
}

/* ------------------------------------------------------------
   Our Approach — Tier 1 piecemeal scatter
   Each tile is absolutely positioned at --x/--y and rotated by --rot.
   The container holds a fixed aspect so tiles stay in proportion.
   ------------------------------------------------------------ */
.approach-piecemeal {
  position: relative;
  aspect-ratio: 1 / 1;
}
.approach-tile {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: 38%;
  background: #002d5c;
  color: #ffffff;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.25;
  padding: 0.65rem 0.85rem;
  text-align: center;
  transform: rotate(var(--rot));
  box-shadow: 0 8px 18px rgba(0, 27, 53, 0.18);
}
.approach-tile span {
  display: block;
  font-weight: 400;
  font-size: 11px;
  opacity: 0.85;
  margin-top: 2px;
}

/* Feature card: downward-pointing triangle notch at top-center */
.card-notch {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 18px solid transparent;
  border-right: 18px solid transparent;
  border-top: 14px solid #f1f5f9; /* slate-100, must match card bg */
}

/* ------------------------------------------------------------
   Footer: collapsible legal disclosure block
   ------------------------------------------------------------ */
details.legal > summary { list-style: none; cursor: pointer; }
details.legal > summary::-webkit-details-marker { display: none; }
details.legal > summary .chev { transition: transform 220ms ease-out; }
details.legal[open] > summary .chev { transform: rotate(180deg); }

/* ------------------------------------------------------------
   Bio modal accordions — smooth height + fade reveal.
   Requires browsers supporting interpolate-size: allow-keywords
   (Chrome 129+, Safari/FF fall back to instant show/hide).
   ------------------------------------------------------------ */
:root { interpolate-size: allow-keywords; }

dialog.bio-modal details {
  overflow: hidden;
}
dialog.bio-modal details > summary {
  list-style: none;
}
dialog.bio-modal details > summary::-webkit-details-marker { display: none; }

dialog.bio-modal details::details-content {
  opacity: 0;
  height: 0;
  overflow: hidden;
  transition:
    content-visibility 360ms allow-discrete,
    opacity 240ms ease-out,
    height 360ms cubic-bezier(0.4, 0, 0.2, 1);
}
dialog.bio-modal details[open]::details-content {
  opacity: 1;
  height: auto;
}

/* Icon swap is already handled via Tailwind group-open utilities, but
   add a subtle rotate to the plus icon for an extra touch. */
dialog.bio-modal details > summary i {
  transition: transform 280ms cubic-bezier(0.4, 0, 0.2, 1);
}
dialog.bio-modal details[open] > summary i.lmg-fa-plus {
  transform: rotate(90deg);
}

/* ------------------------------------------------------------
   Scroll reveal — elements with [data-reveal] ease into view
   once the IntersectionObserver adds `.is-visible`.
   Variants:
     data-reveal              → fade + slide up (default)
     data-reveal="fade"       → opacity only
     data-reveal="up"         → slide up (default)
     data-reveal="down"       → slide down
     data-reveal="left"       → slide in from the left
     data-reveal="right"      → slide in from the right
     data-reveal="scale"      → gentle scale + fade
   Parents with [data-reveal-stagger="90"] auto-set the delay on
   descendants (main.js sets --reveal-delay inline).
   ------------------------------------------------------------ */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 900ms cubic-bezier(0.16, 1, 0.3, 1),
    transform 900ms cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}
[data-reveal="fade"]  { transform: none; }
[data-reveal="up"]    { transform: translateY(28px); }
[data-reveal="down"]  { transform: translateY(-28px); }
[data-reveal="left"]  { transform: translateX(-40px); }
[data-reveal="right"] { transform: translateX(40px); }
[data-reveal="scale"] { transform: scale(0.96); }
/* Sideways slides push content past the viewport on phones/tablets — rise instead */
@media (max-width: 1023px) {
  [data-reveal="left"],
  [data-reveal="right"] { transform: translateY(28px); }
}

[data-reveal].is-visible {
  opacity: 1;
  transform: none;
  will-change: auto;
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal],
  [data-reveal].is-visible {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* Footer background override */
.site-footer.bg-brand-primary {
  background-color: var(--color-primary);
}

/* ============================================================
   WordPress additions — Genesis structural + menus + Gravity
   Forms skin. Everything above is the static site's styles.css
   verbatim; everything below adapts it to WP markup.
   ============================================================ */

/* Genesis structural wrappers must never constrain the full-width
   sections that page content is built from. */
.site-inner,
.content-sidebar-wrap,
.content,
.entry,
.entry-content {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
}

/* WP menus: replicate the static nav's "no border on last mobile item" */
#mobile-menu nav a:last-child { border-bottom: 0; }

/* Genesis skip links — visually hidden until focused */
.genesis-skip-link { list-style: none; margin: 0; }
.genesis-skip-link .screen-reader-shortcut {
  position: absolute;
  top: -1000em;
  left: -1000em;
}
.genesis-skip-link .screen-reader-shortcut:focus {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 200;
  background: #ffffff;
  color: var(--color-primary);
  padding: 0.75rem 1.25rem;
  clip: auto !important;
}

/* ------------------------------------------------------------
   Gravity Forms — skin the form to match the static contact form
   (.form-grid / .form-field / .submit-btn styles above).
   ------------------------------------------------------------ */
.gform_wrapper .gform_fields {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem !important;
  margin-bottom: 2rem;
}
@media (min-width: 640px) {
  .gform_wrapper .gform_fields {
    grid-template-columns: repeat(12, 1fr);
    gap: 1.75rem !important;
  }
}
.gform_wrapper .gfield { grid-column: 1 / -1; }
@media (min-width: 640px) {
  .gform_wrapper .gfield--width-half { grid-column: span 6; }
}

.gform_wrapper .gfield_label {
  display: block;
  font-size: 11px !important;
  letter-spacing: 0.22em;
  font-weight: 600 !important;
  text-transform: uppercase;
  color: var(--color-primary) !important;
  margin-bottom: 0.6rem;
}
/* Static form showed plain labels (required conveyed via the HTML
   attribute only) — hide GF's "(Required)" suffix. aria-required
   still announces the state to assistive tech. */
.gform_wrapper .gfield_required,
.gform_wrapper .gform_required_legend {
  display: none;
}

.gform_wrapper input[type="text"],
.gform_wrapper input[type="email"],
.gform_wrapper input[type="tel"],
.gform_wrapper textarea {
  width: 100%;
  padding: 0.875rem 1rem !important;
  background: #ffffff;
  border: 1px solid #e2e8f0 !important;
  border-radius: 0 !important;
  color: #0f172a;
  font-family: inherit;
  font-size: 0.95rem !important;
  line-height: 1.4;
  transition: border-color 200ms ease-out, box-shadow 200ms ease-out, background-color 200ms ease-out;
  appearance: none;
  -webkit-appearance: none;
}
.gform_wrapper textarea {
  resize: vertical;
  min-height: 8rem;
}
@media (max-width: 639px) {
  .gform_wrapper input[type="text"],
  .gform_wrapper input[type="email"],
  .gform_wrapper input[type="tel"],
  .gform_wrapper textarea { font-size: 16px !important; }
}
.gform_wrapper input[type="text"]:hover,
.gform_wrapper input[type="email"]:hover,
.gform_wrapper input[type="tel"]:hover,
.gform_wrapper textarea:hover {
  border-color: #cbd5e1 !important;
}
.gform_wrapper input[type="text"]:focus,
.gform_wrapper input[type="email"]:focus,
.gform_wrapper input[type="tel"]:focus,
.gform_wrapper textarea:focus {
  outline: none;
  border-color: var(--color-secondary) !important;
  box-shadow: 0 0 0 3px rgba(193, 154, 91, 0.18);
  background: #ffffff;
}

.gform_wrapper .gform_footer { padding: 0 !important; margin: 0 !important; }

.gform_confirmation_message {
  font-size: 1rem;
  color: #475569;
  line-height: 1.65;
  padding: 2rem;
  background: #f8fafc;
  border-top: 4px solid var(--color-secondary);
}

/* ------------------------------------------------------------
   404 page
   ------------------------------------------------------------ */
.nwa-404 {
  padding: 5rem 1.5rem;
  text-align: center;
}
.nwa-404 h2 {
  font-family: 'EB Garamond', ui-serif, Georgia, serif;
  font-size: 2.25rem;
  line-height: 1.2;
  color: var(--color-primary);
  margin-bottom: 1rem;
}
.nwa-404 p {
  color: #475569;
  line-height: 1.65;
  margin-bottom: 2rem;
}

/* Modals must fit the visible viewport (dvh, not vh — on iOS vh runs behind
   the toolbar, hiding the bottom of the box and pushing the close button
   off-screen). On phones the modal goes near full-screen with the close
   button tucked inside the corner. */
dialog.bio-modal,
dialog.content-modal {
  height: min(760px, calc(100dvh - 4rem));
  max-height: calc(100dvh - 4rem);
}
@media (max-width: 767px) {
  dialog.bio-modal,
  dialog.content-modal {
    width: calc(100% - 1.5rem);
    height: calc(100vh - 1.5rem);
    height: calc(100dvh - 1.5rem);
    max-height: calc(100dvh - 1.5rem);
  }
  .content-modal-close {
    top: 0.75rem;
    right: 0.75rem;
    width: 2.75rem;
    height: 2.75rem;
    font-size: 1.15rem;
  }
  .content-modal-body {
    padding: 3.75rem 1.25rem 1.5rem;
  }
  dialog.bio-modal .content-modal-body img {
    max-width: 150px;
  }
}

/* Floating BrokerCheck link (markup in the footer). Sits under the header
   (z-40) so the mobile menu covers it, and hides while the menu is open. */
.brokercheck-float {
  position: fixed;
  right: calc(1rem + env(safe-area-inset-right, 0px));
  bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
  z-index: 30;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.1rem;
  background: var(--color-primary);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 10px 25px -8px rgba(0, 27, 53, 0.55);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  line-height: 1;
  transition: background-color 200ms ease-out, transform 200ms ease-out;
}
.brokercheck-float svg { width: 1.1rem; height: 1.1rem; flex-shrink: 0; }
.brokercheck-float:hover,
.brokercheck-float:focus-visible {
  background: var(--color-secondary);
  color: #ffffff;
  transform: translateY(-2px);
}
.brokercheck-float:focus-visible { outline: 2px solid #ffffff; outline-offset: 2px; }
body.menu-open .brokercheck-float { display: none; }
@media (max-width: 479px) {
  .brokercheck-float { padding: 0.6rem 0.9rem; letter-spacing: 0.12em; }
}
@media print { .brokercheck-float { display: none; } }
