/* Malvern Financial — static rebuild */

:root {
  --color-bg: #ffffff;
  --color-text: #1a1a1a;
  --color-muted: #555555;
  --color-navy: #00305b;
  --color-navy-40: rgba(0, 48, 91, 0.4);
  --color-navy-72: rgba(0, 48, 91, 0.72);
  --color-cta: #0f4c85;
  --color-cta-hover: #0c3d6b;
  --color-green: #18a44b;
  --color-hero-card: rgba(214, 241, 175, 0.88);
  --color-border: rgba(0, 0, 0, 0.08);
  --color-surface: #f7f8fa;
  --font-wordmark: "Noticia Text", Georgia, serif;
  --font-heading: "Raleway", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Open Sans", "Helvetica Neue", Arial, sans-serif;
  --header-h: 4.5rem;
  --max: 1120px;
  --radius: 12px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 8px 30px rgba(0, 48, 91, 0.12);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 0.75rem);
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--color-cta);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--color-cta-hover);
}

h1, h2, h3 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--color-text);
  margin: 0 0 0.75rem;
}

p {
  margin: 0 0 1rem;
}

p:last-child {
  margin-bottom: 0;
}

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

.skip-link {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 1000;
  background: var(--color-navy);
  color: #fff;
  padding: 0.75rem 1rem;
  border-radius: 6px;
}

.skip-link:focus {
  top: 1rem;
}

.container {
  width: min(100% - 2.5rem, var(--max));
  margin-inline: auto;
}

/* —— Header —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.header-inner {
  width: min(100% - 2.5rem, var(--max));
  margin-inline: auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.brand:hover {
  color: inherit;
}

.brand-logo {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 6px;
  flex-shrink: 0;
}

.brand-name {
  font-family: var(--font-wordmark);
  font-size: 1.25rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.site-nav ul {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.site-nav a {
  display: inline-block;
  padding: 0.55rem 0.9rem;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--color-muted);
  border-radius: 999px;
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
}

.site-nav a:hover,
.site-nav a.is-active {
  color: var(--color-navy);
  background: rgba(0, 48, 91, 0.06);
}

.site-nav a.nav-cta {
  margin-left: 0.35rem;
  background: var(--color-cta);
  color: #fff;
}

.site-nav a.nav-cta:hover,
.site-nav a.nav-cta.is-active {
  background: var(--color-cta-hover);
  color: #fff;
}

.nav-toggle {
  display: none;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle-bar {
  display: block;
  width: 1.15rem;
  height: 2px;
  background: var(--color-navy);
  border-radius: 1px;
  transition: transform 0.25s var(--ease), opacity 0.2s;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* —— Hero —— */
.hero {
  position: relative;
  min-height: min(88vh, 720px);
  display: grid;
  align-items: center;
  overflow: hidden;
  color: var(--color-text);
}

.hero-bg,
.hero-bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(0, 48, 91, 0.45) 0%, rgba(0, 48, 91, 0.15) 45%, transparent 70%),
    linear-gradient(0deg, rgba(0, 0, 0, 0.25), transparent 50%);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(100% - 2.5rem, var(--max));
  margin: 4rem auto;
}

.hero-card {
  max-width: 34rem;
  padding: 2.25rem 2.25rem 2rem;
  background: var(--color-hero-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(4px);
}

.hero-eyebrow,
.section-eyebrow {
  margin: 0 0 0.65rem;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-cta);
}

.section-eyebrow--light {
  color: rgba(214, 241, 175, 0.95);
}

.hero h1 {
  font-size: clamp(2rem, 4.5vw, 3rem);
  margin-bottom: 0.85rem;
  color: var(--color-navy);
}

.hero-sub {
  font-size: 1.0625rem;
  color: var(--color-muted);
  margin-bottom: 1.5rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.8rem 1.35rem;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 8px;
  border: 1.5px solid transparent;
  transition: background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease);
}

.btn-primary {
  background: var(--color-cta);
  color: #fff;
}

.btn-primary:hover {
  background: var(--color-cta-hover);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  border-color: var(--color-navy);
  color: var(--color-navy);
}

.btn-ghost:hover {
  background: var(--color-navy);
  color: #fff;
}

/* —— Sections —— */
.section {
  padding: clamp(3.5rem, 8vw, 6rem) 0;
}

.section-header {
  margin-bottom: clamp(2rem, 4vw, 3rem);
  max-width: 40rem;
}

.section-header--center {
  margin-inline: auto;
  text-align: center;
}

.section-header h2 {
  font-size: clamp(1.85rem, 3.5vw, 2.5rem);
  margin-bottom: 0.75rem;
}

.section-lead {
  font-size: 1.125rem;
  color: var(--color-muted);
  margin: 0;
}

/* Services */
.services {
  background: var(--color-bg);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.service-card {
  padding: 2rem 1.75rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.service-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.service-icon {
  width: 56px;
  height: 56px;
  object-fit: contain;
  margin-bottom: 1.25rem;
}

.service-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.85rem;
  color: var(--color-navy);
}

.service-card p {
  color: var(--color-muted);
  font-size: 1rem;
}

/* Mission */
.mission {
  background: linear-gradient(180deg, #f4f7fb 0%, #ffffff 100%);
}

.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.pillar {
  text-align: center;
  padding: 2rem 1.5rem 2.25rem;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.pillar-icon {
  width: 110px;
  height: 110px;
  object-fit: contain;
  margin: 0 auto 1.25rem;
}

.pillar h3 {
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-navy);
  margin-bottom: 0.75rem;
}

.pillar p {
  color: var(--color-muted);
  font-size: 0.98rem;
}

/* Photo strip */
.photo-strip {
  position: relative;
  height: clamp(220px, 32vw, 380px);
  overflow: hidden;
}

.photo-strip picture,
.photo-strip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
}

.photo-strip::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 48, 91, 0.12), rgba(0, 48, 91, 0.28));
  pointer-events: none;
}

/* About */
.about {
  background: var(--color-bg);
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(240px, 340px) 1fr;
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: start;
}

.about-photo {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  background: var(--color-surface);
}

.about-photo img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  object-position: center top;
}

.about-name {
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
  color: var(--color-navy);
}

.about-role {
  margin: 0 0 1.35rem;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-green);
}

.about-copy p {
  color: var(--color-muted);
  margin-bottom: 1.15rem;
}

/* Contact */
.contact {
  position: relative;
  min-height: 420px;
  display: grid;
  align-items: center;
  padding: clamp(4rem, 8vw, 6rem) 0;
  overflow: hidden;
  color: #fff;
}

.contact-bg,
.contact-bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.contact-overlay {
  position: absolute;
  inset: 0;
  background: var(--color-navy-72);
}

.contact-inner {
  position: relative;
  z-index: 1;
}

.contact-card {
  max-width: 32rem;
  padding: 2.25rem 2rem;
  background: var(--color-navy-40);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  backdrop-filter: blur(6px);
}

.contact-card h2 {
  color: #fff;
  font-size: clamp(1.85rem, 3vw, 2.35rem);
  margin-bottom: 0.35rem;
}

.contact-brand {
  font-family: var(--font-wordmark);
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 1rem;
  color: rgba(255, 255, 255, 0.9);
}

.contact-intro {
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 1.5rem;
}

.contact-list {
  display: grid;
  gap: 1rem;
}

.contact-list li {
  display: grid;
  gap: 0.2rem;
}

.contact-label {
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(214, 241, 175, 0.95);
}

.contact-list a {
  color: #fff;
  font-size: 1.15rem;
  font-weight: 600;
  text-decoration: none;
  word-break: break-word;
}

.contact-list a:hover {
  color: #d6f1af;
}

/* Footer */
.site-footer {
  background: #fff;
  border-top: 1px solid var(--color-border);
  padding: 1.75rem 0 1.5rem;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-wordmark);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.95rem;
}

.footer-brand img {
  width: 36px;
  height: 36px;
  border-radius: 4px;
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--color-muted);
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.footer-social a:hover {
  color: var(--color-cta);
}

.footer-social img {
  width: 28px;
  height: 28px;
}

.back-to-top {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  text-decoration: none;
  color: var(--color-muted);
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.back-to-top:hover {
  color: var(--color-navy);
}

.footer-meta {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--color-border);
}

.footer-meta p {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--color-muted);
}

/* —— Responsive —— */
@media (max-width: 900px) {
  .services-grid,
  .pillars {
    grid-template-columns: 1fr;
  }

  .pillars {
    max-width: 28rem;
    margin-inline: auto;
  }

  .about-grid {
    grid-template-columns: 1fr;
    max-width: 40rem;
  }

  .about-photo {
    max-width: 320px;
  }
}

@media (max-width: 768px) {
  :root {
    --header-h: 4rem;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
    padding: 0.75rem 1.25rem 1.25rem;
    display: none;
  }

  .site-nav.is-open {
    display: block;
  }

  .site-nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0.25rem;
  }

  .site-nav a {
    padding: 0.85rem 1rem;
  }

  .site-nav a.nav-cta {
    margin-left: 0;
    text-align: center;
    justify-content: center;
  }

  .brand-name {
    font-size: 1.05rem;
  }

  .brand-logo {
    width: 40px;
    height: 40px;
  }

  .hero {
    min-height: min(78vh, 640px);
  }

  .hero-card {
    padding: 1.75rem 1.5rem;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .service-card,
  .nav-toggle-bar,
  .btn,
  .site-nav a {
    transition: none;
  }
}
