* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body, html {
  margin: 0;
  padding: 0;
}

body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #222;
  background-color: #f5f5f5;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #003366;
  border-bottom: 1px solid #ccc;
  padding: 1rem 0;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding-left: 0;
  margin: 0;
}

.nav-links a {
  text-decoration: none;
  color: #ffffff;
  font-weight: bold;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: #D4AF37;
}

.hero {
  background: #f5f5f5;
  padding: 2rem 1rem;
}

.hero-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
}

.hero-text {
  flex: 1;
  padding: 1rem;
}

.hero-text h1 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: #003366;
}

.hero-text p {
  margin-bottom: 1rem;
}

.hero-text button {
  background-color: #9A1F15;
  color: white;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
}

.hero-image {
  flex: 1;
  text-align: right;
  
}

.hero-image img {
  max-width: 100%;
  border-radius: 8px;
}

.products {
  display: flex;
  gap: 2rem;
  padding: 2rem 0;
  flex-wrap: wrap;
}

.product {
  flex: 1 1 45%;
  background: #fff;
  padding: 1.5rem;
  border: 1px solid #ccc;
  border-radius: 8px;
}

.product h2 {
  margin-bottom: 1rem;
  color: #003366;
}

.product a {
  color: #003366;
  text-decoration: none;
  font-weight: bold;
}

.site-footer {
  background-color: #003366;
  color: #fff;
  text-align: center;
  padding: 1rem;
}

.about-us {
  background-color: #ffffff;
  padding: 3rem 1rem;
}

.about-us-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: center;
}

.about-us-text {
  flex: 1;
  min-width: 300px;
}

.about-us-text h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: #003366;
}

.about-us-text p {
  margin-bottom: 1rem;
  font-size: 1rem;
  color: #333;
  line-height: 1.7;
}

.about-us-image {
  flex: 1;
  min-width: 300px;
  text-align: center;
}

.about-us-image img {
  max-width: 100%;
  border-radius: 8px;
}
.full-width-hero {
  width: 100%;
  padding: 0;
  margin: 0;
  overflow: hidden;
}

.full-width-hero .hero-image {
  width: 100%;
  height: 80vh; /* 50% of the viewport height */
}

.full-width-hero .hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}



.final-expense-benefits {
  background: #f9f9f9;
  padding: 3rem 1rem;
  text-align: center;
}

.final-expense-benefits h2 {
  font-size: 2rem;
  margin-bottom: 2rem;
  color: #003366;
}

.benefits-grid {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  justify-content: center;
}

.benefit-item {
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 1.5rem;
  flex: 1 1 300px;
  max-width: 350px;
  text-align: left;
}

.benefit-item img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 1rem;
}

.benefit-item h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: #003366;
}

.benefit-item p {
  font-size: 0.95rem;
  color: #333;
  line-height: 1.5;
}

.quote-highlight {
  background-color: #FFD700;
  color: #003366;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-weight: bold;
}

.nav-links a.active {
  background-color: #ffffff;
  color: #003366;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-weight: bold;
}

/* Base hero container */
.hero.full-width-hero {
  position: relative;
  min-height: 520px;
  display: flex;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
}

/* Background image */
.hero .hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}

/* Content wrapper */
.hero .hero-content {
  display: flex;
  justify-content: flex-end; /* text aligns to right on desktop */
  width: 100%;
  padding: clamp(1rem, 4vw, 4rem);
}

/* Card styling */
.hero .hero-card {
  max-width: 600px;
  background: rgba(255, 255, 255, 0.9);
  padding: clamp(1rem, 2.5vw, 2rem);
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  color: #1a1a1a;
}

/* Headline */
.hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 3vw, 3rem);
  line-height: 1.2;
  font-weight: 800;
}

/* Supporting text */
.hero p {
  margin: 0 0 1.5rem;
  font-size: clamp(1rem, 1.15vw, 1.125rem);
  line-height: 1.6;
}

/* Call to action button */
.hero .cta {
  display: inline-block;
  background: #c96536; /* warm orange */
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  padding: 0.85rem 1.25rem;
  border-radius: 6px;
  transition: transform 0.1s ease, filter 0.2s ease;
}
.hero .cta:hover {
  filter: brightness(0.95);
  transform: translateY(-2px);
}
.hero .cta:focus {
  outline: 2px solid #000;
  outline-offset: 3px;
}

/* Responsive */
@media (max-width: 900px) {
  .hero .hero-content {
    justify-content: center; /* center the card on mobile */
    padding: 1rem;
  }
  .hero .hero-card {
    margin: 0;
    max-width: 90%;
  }
}


/* Content layout: right-aligned on desktop, centered on mobile */
.hero .hero-content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: clamp(1rem, 3vw, 3rem);
}

/* Card that mimics the comp’s clean text block */
.hero .hero-card {
  max-width: 600px;
  margin-right: clamp(0rem, 6vw, 8rem);
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(2px);
  border-radius: 12px;
  padding: clamp(1rem, 2.5vw, 2rem);
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  color: #1a1a1a;
}

/* Typography */
.hero h1 {
  margin: 0 0 .6rem 0;
  font-weight: 800;
  line-height: 1.1;
  font-size: clamp(1.8rem, 3.2vw, 3rem);
}
.hero p {
  margin: 0 0 1rem 0;
  font-size: clamp(1rem, 1.15vw, 1.125rem);
  line-height: 1.55;
}

/* CTA button */
.hero .cta {
  display: inline-block;
  background: #c96536;       /* warm orange to match comp */
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  padding: .85rem 1.25rem;
  border-radius: .6rem;
  transition: transform .1s ease, filter .2s ease;
}
.hero .cta:hover { filter: brightness(0.95); transform: translateY(-1px); }
.hero .cta:focus { outline: 2px solid #000; outline-offset: 3px; }

/* Mobile adjustments */
@media (max-width: 900px) {
  .hero .hero-content { justify-content: center; }
  .hero .hero-card { margin-right: 0; }
}

/* ====== Mobile Nav / Off-Canvas ====== */

/* ===== Mobile nav tray ===== */

/* Hamburger (white) */
.hamburger {
  display: none;
  gap: 6px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 42px; height: 42px;
  background: transparent;
  border: 1px solid rgba(255,255,255,.35);
  border-radius: 8px;
  cursor: pointer;
}
.hamburger span {
  display: block;
  width: 22px; height: 2px;
  background: #fff;
  border-radius: 2px;
}

/* Overlay */
.nav-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 900;
}

/* Close button inside tray */
.nav-close {
  position: absolute;
  top: 10px; right: 12px;
  width: 40px; height: 40px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
}

/* Mobile tray behavior */
@media (max-width: 900px) {
  .hamburger { display: inline-flex; }

  /* Off-canvas tray */
  .site-nav {
    position: fixed;
    top: 0; right: 0;
    height: 100vh;
    width: min(82vw, 360px);
    background: #003366;
    z-index: 1001;                    /* above overlay */
    box-shadow: -8px 0 24px rgba(0,0,0,.25);
    transform: translateX(100%);      /* hidden by default */
    transition: transform .28s ease;
    padding: 64px 22px 20px;
    display: block;                    /* ensure it exists even if UL is flex */
  }

  .nav-links {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding-left: 0;
    margin: 0;
  }
  .nav-links a {
    color: #fff;
    font-weight: 700;
    text-decoration: none;
    font-size: 1.05rem;
  }
  .nav-links a:hover { color: #D4AF37; }

  .quote-highlight {
    background: #FFD700;
    color: #003366;
    padding: 0.5rem 0.8rem;
    border-radius: 6px;
    display: inline-block;
    font-weight: 800;
  }

  /* Open state (body gets .nav-open) */
  body.nav-open #siteNav { transform: translateX(0); }
  body.nav-open #navOverlay { display: block; }
  .body-lock { overflow: hidden; } /* you already use this with the modal */
}

/* Desktop keeps your current horizontal nav */
@media (min-width: 901px) {
  #navOverlay, .nav-close { display: none !important; }
}

/* Products: two-up on desktop, stack on tablet/mobile */
@media (max-width: 900px) {
  .products {
    flex-direction: column;
    gap: 1.5rem;
  }

  .product {
    flex: 1 1 100%;
    max-width: 100%;
    padding: 1.75rem 1.5rem;
    border-radius: 12px;
    border: 1px solid #e0e4ea;
    background: #fff;
    box-shadow: 0 4px 14px rgba(0,0,0,0.08);
    transition: transform .15s ease, box-shadow .15s ease;
  }

  .product:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
  }

  .product h2 {
    font-size: 1.35rem;
    margin-bottom: 0.75rem;
    color: #003366;
    line-height: 1.3;
  }

  .product p {
    font-size: 1rem;
    line-height: 1.6;
    color: #444;
    margin-bottom: 1rem;
  }

  .product a {
    display: inline-block;
    font-weight: 700;
    color: #0b6d90;
    text-decoration: none;
    margin-top: 0.25rem;
    transition: color .2s ease;
  }
  .product a:hover {
    color: #c96536;
  }
}

.logo img {max-width:200px;}

@media (max-width: 900px){
  .products{ flex-direction: column; gap: 1.5rem; }
  .product{
    flex:1 1 100%; max-width:100%;
    padding: 1.75rem 1.5rem;
    border-radius: 12px;
    border: 1px solid #e0e4ea;
    background: #fff;
    box-shadow: 0 4px 14px rgba(0,0,0,.08);
    transition: transform .15s ease, box-shadow .15s ease;
  }
  .product:hover{ transform: translateY(-3px); box-shadow: 0 8px 20px rgba(0,0,0,.12); }
  .product h2{ font-size:1.35rem; margin-bottom:.75rem; line-height:1.3; }
}

.logo img { max-width: 180px; height: auto; }
@media (max-width: 520px){ .logo img { max-width: 150px; } }

/* ===== Mortgage Protection Hero ===== */
.mp-hero{
  position: relative;
  min-height: clamp(360px, 50vw, 640px);
  display: flex;
  align-items: center;
  isolation: isolate;
  /* background image */
  background-image: url("images/mortgage-protection-hero.png");
  background-size: cover;
  background-repeat: no-repeat;
  /* keep family on the right side in view */
  background-position: 70% center;
}

/* subtle left gradient for text contrast (like the comp) */
.mp-hero::before{
  content:"";
  position:absolute; inset:0;
  background:
    linear-gradient(110deg, rgba(0,73,114,.92) 0%, rgba(0,126,167,.85) 42%, rgba(0,126,167,0) 62%);
  z-index:-1;
}

.mp-hero .hero-content{
  width:100%;
  display:flex;
  justify-content:flex-start;
  padding: clamp(1rem, 5vw, 4rem);
}

.mp-hero .hero-card{
   max-width: 640px;
  color:#fff;
  background: none;
  border: none;
  backdrop-filter: none;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  text-shadow: none;
}


.mp-hero h1{
  margin:0 0 .7rem;
  font-weight: 800;
  line-height: 1.1;
  font-size: clamp(1.8rem, 3vw, 3rem);
  letter-spacing: .2px;
}

.mp-hero p{
  margin:0 0 1.25rem;
  line-height:1.6;
  font-size: clamp(1rem, 1.15vw, 1.125rem);
  color: #f1f6fa;
}

/* CTA button (reuses your hero .cta look but on dark bg) */
.mp-hero .cta{
  display:inline-block;
  background:#f7941d;
  color:#000;
  text-decoration:none;
  font-weight:800;
  padding:.9rem 1.25rem;
  border-radius: .6rem;
  transition: transform .08s ease, filter .2s ease;
}
.mp-hero .cta:hover{ filter:brightness(.95); transform: translateY(-1px); }
.mp-hero .cta:focus{ outline:2px solid #fff; outline-offset:3px; }

/* Tablet & down: center the card and adjust the background focal point */
@media (max-width: 900px){
  .mp-hero{ background-position: 65% center; }
  .mp-hero .hero-content{ justify-content:center; }
  .mp-hero .hero-card{ max-width: 92%; }
}

/* Small phones: give more height and soften gradient */
@media (max-width: 520px){
  .mp-hero{ min-height: 440px; background-position: 60% center; }
  .mp-hero::before{
    background: linear-gradient(115deg, rgba(0,73,114,.95) 0%, rgba(0,126,167,.88) 54%, rgba(0,126,167,0) 70%);
  }
}

/* --- Mobile/tablet: add readability support --- */
@media (max-width: 900px){
  /* Darken the left gradient more on small screens */
  .mp-hero::before{
    background: linear-gradient(
      112deg,
      rgba(0,53,90,.92) 0%,
      rgba(0,95,126,.88) 52%,
      rgba(0,126,167,0) 72%
    );
  }

  /* Bring the text to the center and add a soft plate */
  .mp-hero .hero-content{ justify-content: center; }
  .mp-hero .hero-card{
    max-width: 92%;
    padding: 1rem 1.1rem;              /* small breathing room */
    background: rgba(0,0,0,.42);       /* subtle dark plate */
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,.18);
    text-shadow: 0 1px 2px rgba(0,0,0,.35); /* extra contrast for white text */
  }
  .mp-hero h1{ font-size: clamp(1.6rem, 5vw, 2.2rem); }
  .mp-hero p { font-size: 1rem; }
  .mp-hero .cta{
    background:#ffd34d; color:#003366;
  }
}

/* --- Very small phones: a touch more height & focus --- */
@media (max-width: 520px){
  .mp-hero{
    min-height: 460px;
    background-position: 58% center;   /* keep faces in frame */
  }
  .mp-hero::before{
    background: linear-gradient(
      115deg,
      rgba(0,53,90,.96) 0%,
      rgba(0,95,126,.92) 58%,
      rgba(0,126,167,0) 74%
    );
  }
}

/* Modal (scroll-safe on mobile) */
.modal{
  display:none; position:fixed; inset:0; z-index:9999;
  background:rgba(0,0,0,.65);
  overflow:auto;                    /* allow page scroll when keyboard opens */
  padding:clamp(12px, 4vw, 24px);   /* breathing room around the dialog */
}
.modal[aria-hidden="false"]{ display:block; }

.modal-dialog{
  background:#fff; width:min(640px, 100%);
  margin:clamp(28px, 6vh, 60px) auto;         /* natural vertical centering */
  border-radius:12px; box-shadow:0 12px 30px rgba(0,0,0,.25);
  padding:1.75rem; position:relative;
  max-height:calc(100vh - 12vh);               /* keep close button visible */
  overflow:auto;                                /* internal scroll if needed */
}
.modal-close{
  position:absolute; top:.5rem; right:.6rem;
  background:none; border:none; font-size:1.75rem; line-height:1; cursor:pointer;
}
.body-lock{ overflow:hidden; }

/* Form visuals */
.form-success{margin-top:1rem;padding:1rem;background:#e6f7ed;border:1px solid #a3e0bb;border-radius:8px;color:#1a7a3e;font-weight:600;text-align:center;}
#quoteTitle{margin:0 0 .75rem;font-size:1.5rem;font-weight:800;}
#quoteForm{display:grid;grid-template-columns:1fr;gap:1rem;margin-top:.25rem;}
@media (min-width:720px){
  #quoteForm{grid-template-columns:1fr 1fr;}
  #quoteForm fieldset,.btn-submit{grid-column:1/-1;}
}
#quoteForm label{display:block;font-size:.9rem;font-weight:600;}
#quoteForm input[type="text"],#quoteForm input[type="date"],#quoteForm input[type="tel"],#quoteForm input[type="email"]{
  width:100%;margin-top:.4rem;padding:.75rem .9rem;border:1px solid #d7dbe0;border-radius:10px;min-height:48px;}
#quoteForm fieldset{border:1px solid #d7dbe0;border-radius:12px;padding:1rem;background:#fafbfc;}
#quoteForm fieldset legend{font-weight:700;font-size:.95rem;}
#quoteForm fieldset label{display:inline-flex;align-items:center;gap:.5rem;margin-right:1rem;}
.btn-submit{background:#0b6d90;color:#fff;border:0;padding:.95rem 1.25rem;border-radius:10px;font-weight:800;cursor:pointer;}
.error-msg{display:block;margin-top:.35rem;font-size:.8rem;color:#c0392b;}
.is-invalid{border-color:#c0392b !important; box-shadow:0 0 0 3px rgba(192,57,43,.18);}
#quoteForm input:focus{outline:none;border-color:#78c0e0;box-shadow:0 0 0 3px rgba(120,192,224,.35);}
