/* =============================================
   MSB Insurance — Global / Variables / Reset
   ============================================= */


/* ===== CSS CUSTOM PROPERTIES ===== */
:root {
  /* Brand Colors */
  --navy:        #003366;
  --navy-dark:   #002244;
  --navy-mid:    #004080;
  --white:       #ffffff;
  --light-gray:  #d3d3d3;
  --gray-soft:   #f0f4f8;
  --gray-mid:    #b0b8c4;
  --royal:       #4169e1;
  --royal-light: #6b8ef5;
  --royal-dark:  #2f50c8;
  --orange:      #ff8200;
  --orange-dark: #e06b00;
  --orange-light:#ffaa44;

  /* Semantic */
  --success:     #0d9e6e;
  --danger:      #e53e3e;
  --warning:     #d97706;
  --info:        #3182ce;

  /* Text */
  --text-primary:   #111827;
  --text-secondary: #4b5563;
  --text-muted:     #9ca3af;
  --text-light:     #f9fafb;

  /* Backgrounds */
  --bg-body:     #f8fafc;
  --bg-card:     #ffffff;
  --bg-subtle:   #f1f5f9;

  /* Typography */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'Inter', system-ui, sans-serif;
  --font-label:   'Barlow Condensed', sans-serif;

  /* Sizing */
  --container:   1280px;
  --radius-sm:   6px;
  --radius:      12px;
  --radius-lg:   20px;
  --radius-xl:   32px;
  --radius-full: 999px;

  /* Shadows */
  --shadow-xs:   0 1px 2px rgba(0,51,102,.06);
  --shadow-sm:   0 2px 8px rgba(0,51,102,.08);
  --shadow-md:   0 6px 24px rgba(0,51,102,.12);
  --shadow-lg:   0 16px 48px rgba(0,51,102,.16);
  --shadow-xl:   0 28px 64px rgba(0,51,102,.22);

  /* Transitions */
  --ease:        cubic-bezier(.4,0,.2,1);
  --ease-bounce: cubic-bezier(.34,1.56,.64,1);
  --dur-fast:    150ms;
  --dur:         260ms;
  --dur-slow:    400ms;
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  color: var(--text-primary);
  background: var(--bg-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button, input, select, textarea { font-family: inherit; }
button { cursor: pointer; border: none; background: none; }
h1,h2,h3,h4,h5,h6 { line-height: 1.2; font-weight: 700; }

/* ===== CONTAINER ===== */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== SECTION UTILS ===== */
.section {
  padding: 96px 0;
}
.section-sm { padding: 60px 0; }
.section-lg { padding: 120px 0; }

.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-label);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 12px;
}
.section-eyebrow::before {
  content: '';
  width: 28px; height: 2px;
  background: var(--orange);
  border-radius: 2px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 16px;
}
.section-title span { color: var(--orange); }

.section-subtitle {
  font-size: 17px;
  color: var(--text-secondary);
  max-width: 600px;
  margin-bottom: 48px;
  line-height: 1.75;
}

.section-header-center {
  text-align: center;
}
.section-header-center .section-subtitle {
  margin: 0 auto 48px;
}
.section-header-center .section-eyebrow {
  justify-content: center;
}
.section-header-center .section-eyebrow::before { display: none; }
.section-header-center .section-eyebrow::after {
  content: '';
  width: 28px; height: 2px;
  background: var(--orange);
  border-radius: 2px;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-full);
  font-size: 15px;
  font-weight: 600;
  transition: all var(--dur) var(--ease);
  cursor: pointer;
  border: 2px solid transparent;
  line-height: 1;
  white-space: nowrap;
}

.btn-primary {
  background: var(--orange);
  color: var(--white);
  border-color: var(--orange);
}
.btn-primary:hover {
  background: var(--orange-dark);
  border-color: var(--orange-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255,130,0,.35);
}

.btn-navy {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}
.btn-navy:hover {
  background: var(--navy-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,51,102,.35);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,.5);
}
.btn-outline:hover {
  background: rgba(255,255,255,.1);
  border-color: var(--white);
}

.btn-outline-navy {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}
.btn-outline-navy:hover {
  background: var(--navy);
  color: var(--white);
}

/* White outline — for use on dark/coloured backgrounds */
.btn-outline-white {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,.6);
}
.btn-outline-white:hover {
  background: rgba(255,255,255,.15);
  border-color: var(--white);
}

.btn-royal {
  background: var(--royal);
  color: var(--white);
  border-color: var(--royal);
}
.btn-royal:hover {
  background: var(--royal-dark);
  border-color: var(--royal-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(65,105,225,.35);
}

.btn-sm { padding: 10px 20px; font-size: 13px; }
.btn-lg { padding: 18px 38px; font-size: 17px; }
.btn-full { width: 100%; justify-content: center; }

.btn svg { width: 18px; height: 18px; flex-shrink: 0; }

/* ===== CARDS ===== */
.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: all var(--dur) var(--ease);
  border: 1px solid rgba(0,51,102,.06);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* ===== BADGE ===== */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.badge-success  { background: #d1fae5; color: #065f46; }
.badge-danger   { background: #fee2e2; color: #991b1b; }
.badge-warning  { background: #fef3c7; color: #92400e; }
.badge-info     { background: #dbeafe; color: #1e40af; }
.badge-primary  { background: #ede9fe; color: #5b21b6; }
.badge-secondary{ background: #f3f4f6; color: #374151; }

/* ===== FORM ELEMENTS ===== */
.form-group { margin-bottom: 20px; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
  letter-spacing: .02em;
}
.form-label .req { color: var(--orange); margin-left: 2px; }

.form-control {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--light-gray);
  border-radius: var(--radius);
  font-size: 15px;
  color: var(--text-primary);
  background: var(--white);
  transition: all var(--dur-fast) var(--ease);
  outline: none;
  appearance: none;
}
.form-control:focus {
  border-color: var(--royal);
  box-shadow: 0 0 0 3px rgba(65,105,225,.12);
}
.form-control::placeholder { color: var(--text-muted); }
.form-control.error { border-color: var(--danger); }

textarea.form-control { resize: vertical; min-height: 120px; }
select.form-control { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23003366' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 18px; padding-right: 40px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
@media (max-width: 600px) { .form-row { grid-template-columns: 1fr; } }

/* Checkbox/Radio */
.check-group { display: flex; flex-wrap: wrap; gap: 10px; }
.check-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1.5px solid var(--light-gray);
  border-radius: var(--radius-full);
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: all var(--dur-fast) var(--ease);
  user-select: none;
}
.check-item input { display: none; }
.check-item:has(input:checked) {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

/* ===== FLASH MESSAGES ===== */
.flash-msg {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 20px;
}
.flash-icon {
  width: 22px; height: 22px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}
.flash-success { background: #d1fae5; color: #065f46; border: 1px solid #6ee7b7; }
.flash-success .flash-icon { background: #10b981; color: white; }
.flash-error { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.flash-error .flash-icon { background: #ef4444; color: white; }
.flash-warning { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; }
.flash-info { background: #dbeafe; color: #1e40af; border: 1px solid #93c5fd; }

/* ===== DIVIDER ===== */
.divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--light-gray), transparent);
  margin: 48px 0;
}

/* ===== PAGE HERO ===== */
.page-hero {
  background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy) 60%, var(--navy-mid) 100%);
  padding: 80px 0 60px;
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute; inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.page-hero-content { position: relative; z-index: 1; text-align: center; color: var(--white); }
.page-hero-content h1 { font-family: var(--font-display); font-size: clamp(32px,5vw,52px); color: var(--white); margin-bottom: 14px; }
.page-hero-content p { font-size: 17px; color: rgba(255,255,255,.8); max-width: 560px; margin: 0 auto; }
.breadcrumb { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 20px; font-size: 13px; color: rgba(255,255,255,.6); }
.breadcrumb a { color: var(--orange); }
.breadcrumb span { color: rgba(255,255,255,.4); }

/* ===== HEADER NAV ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100%;
}

.header-topbar {
  background: var(--navy-dark);
  padding: 8px 0;
}
.header-topbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.topbar-left, .topbar-right {
  display: flex;
  align-items: center;
  gap: 20px;
}
.topbar-left a, .topbar-right a {
  display: flex; align-items: center; gap: 6px;
  font-size: 12.5px; color: rgba(255,255,255,.8);
  transition: color var(--dur-fast) var(--ease);
}
.topbar-left a:hover, .topbar-right a:hover { color: var(--orange); }
.topbar-left a svg, .topbar-right a svg { width: 13px; height: 13px; }
.topbar-badge {
  display: flex; align-items: center; gap: 5px;
  font-size: 11.5px; font-weight: 600; color: var(--orange-light);
  font-family: var(--font-label); letter-spacing: .05em;
}
.topbar-badge svg { width: 13px; height: 13px; }
.whatsapp-btn-top {
  background: #25d366;
  color: white !important;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 12px !important;
  font-weight: 600 !important;
}
.whatsapp-btn-top svg { width: 13px; height: 13px; }
.admin-link-top {
  padding: 5px 14px;
  border: 1px solid rgba(255,255,255,.25);
  border-radius: var(--radius-full);
  font-size: 12px !important;
  font-weight: 600 !important;
  color: rgba(255,255,255,.8) !important;
  transition: all var(--dur-fast) var(--ease) !important;
}
.admin-link-top:hover {
  border-color: var(--orange) !important;
  color: var(--orange) !important;
}

.main-nav {
  background: var(--white);
  box-shadow: 0 2px 20px rgba(0,51,102,.1);
  transition: all var(--dur) var(--ease);
}
.main-nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 32px;
}

.nav-logo {
  display: flex; align-items: center; gap: 12px; flex-shrink: 0;
}
.logo-icon svg { width: 44px; height: 44px; }
.logo-text { display: flex; flex-direction: column; }
.logo-brand { font-family: var(--font-display); font-size: 20px; font-weight: 700; color: var(--navy); line-height: 1.1; }
.logo-sub { font-size: 10.5px; font-weight: 500; color: var(--text-muted); letter-spacing: .04em; line-height: 1.2; }

.nav-links {
  display: flex; align-items: center; gap: 4px; margin-left: auto;
}
.nav-links > li { position: relative; }
.nav-links > li > a {
  display: flex; align-items: center; gap: 4px;
  padding: 10px 14px;
  font-size: 14px; font-weight: 600; color: var(--text-primary);
  border-radius: var(--radius-sm);
  transition: all var(--dur-fast) var(--ease);
  white-space: nowrap;
}
.nav-links > li > a:hover,
.nav-links > li > a.active {
  color: var(--navy); background: var(--gray-soft);
}
.nav-links > li > a.active { color: var(--orange); }

.dropdown-arrow { width: 14px; height: 14px; transition: transform var(--dur-fast) var(--ease); }
.has-dropdown:hover .dropdown-arrow { transform: rotate(180deg); }

.dropdown-menu {
  position: absolute; top: calc(100% + 4px); left: 0;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(0,51,102,.08);
  min-width: 210px;
  padding: 8px;
  opacity: 0; visibility: hidden; pointer-events: none;
  transform: translateY(-8px);
  transition: all var(--dur) var(--ease);
  z-index: 100;
}
.has-dropdown:hover .dropdown-menu {
  opacity: 1; visibility: visible; pointer-events: all; transform: translateY(0);
}
.dropdown-menu li a {
  display: block; padding: 9px 14px;
  font-size: 14px; font-weight: 500; color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: all var(--dur-fast) var(--ease);
}
.dropdown-menu li a:hover { background: var(--gray-soft); color: var(--navy); padding-left: 20px; }

.nav-cta {
  background: var(--orange) !important;
  color: var(--white) !important;
  padding: 10px 20px !important;
  border-radius: var(--radius-full) !important;
}
.nav-cta:hover { background: var(--orange-dark) !important; }

.hamburger {
  display: none;
  flex-direction: column; gap: 5px; padding: 8px;
  background: none; border: none; cursor: pointer;
  z-index: 200;
}
.hamburger span {
  display: block; width: 24px; height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: all var(--dur) var(--ease);
  transform-origin: center;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== FOOTER ===== */
.site-footer { background: var(--navy-dark); color: rgba(255,255,255,.8); }
.footer-top { padding: 72px 0 48px; }
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 48px;
}
.footer-logo {
  display: flex; align-items: center; gap: 12px; margin-bottom: 16px;
}
.footer-logo-name { display: block; font-family: var(--font-display); font-size: 20px; font-weight: 700; color: var(--white); }
.footer-logo-sub { display: block; font-size: 11px; color: var(--orange-light); letter-spacing: .06em; }
.footer-about-text { font-size: 14px; line-height: 1.7; color: rgba(255,255,255,.65); margin-bottom: 20px; }
.footer-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.f-badge {
  padding: 4px 12px; border: 1px solid rgba(255,130,0,.4);
  color: var(--orange-light); border-radius: var(--radius-full);
  font-size: 11px; font-weight: 600; font-family: var(--font-label); letter-spacing: .05em;
}
.footer-heading {
  font-family: var(--font-label); font-size: 13px; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--white); margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,.1);
}
.footer-links li { margin-bottom: 10px; }
.footer-links a {
  font-size: 14px; color: rgba(255,255,255,.65);
  transition: all var(--dur-fast) var(--ease);
  display: flex; align-items: center; gap: 6px;
}
.footer-links a:hover { color: var(--orange-light); padding-left: 4px; }
.footer-contact-list li {
  display: flex; align-items: flex-start; gap: 12px;
  margin-bottom: 14px; font-size: 14px; color: rgba(255,255,255,.65);
}
.footer-contact-list svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; color: var(--orange); }
.footer-contact-list a { color: rgba(255,255,255,.65); transition: color var(--dur-fast) var(--ease); }
.footer-contact-list a:hover { color: var(--orange-light); }
.whatsapp-footer-btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: #25d366; color: white;
  padding: 10px 20px; border-radius: var(--radius-full);
  font-size: 13px; font-weight: 600;
  margin-top: 12px; transition: all var(--dur-fast) var(--ease);
}
.whatsapp-footer-btn svg { width: 16px; height: 16px; }
.whatsapp-footer-btn:hover { background: #1ebe59; transform: translateY(-1px); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 24px 0; text-align: center;
}
.footer-copy { font-size: 13px; color: rgba(255,255,255,.5); margin-bottom: 8px; }
.footer-disc { font-size: 11px; color: rgba(255,255,255,.3); max-width: 700px; margin: 0 auto; line-height: 1.6; }

/* ===== FLOATING ELEMENTS ===== */
.floating-whatsapp {
  position: fixed; bottom: 24px; right: 24px; z-index: 900;
  width: 56px; height: 56px;
  background: #25d366; color: white;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.4);
  transition: all var(--dur) var(--ease-bounce);
}
.floating-whatsapp svg { width: 28px; height: 28px; }
.floating-whatsapp:hover { transform: scale(1.12); box-shadow: 0 8px 32px rgba(37,211,102,.5); }
.wa-pulse {
  position: absolute; inset: -4px;
  border: 2px solid #25d366; border-radius: 50%;
  animation: waPulse 2s ease-out infinite;
  pointer-events: none;
}
@keyframes waPulse {
  0%   { opacity: 1; transform: scale(1); }
  70%  { opacity: 0; transform: scale(1.4); }
  100% { opacity: 0; transform: scale(1.4); }
}

.back-to-top {
  position: fixed; bottom: 90px; right: 24px; z-index: 900;
  width: 44px; height: 44px;
  background: var(--navy);
  color: white; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-md);
  opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: all var(--dur) var(--ease);
}
.back-to-top.visible { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top svg { width: 18px; height: 18px; }
.back-to-top:hover { background: var(--orange); transform: translateY(-2px); }

/* ===== RESPONSIVE NAV ===== */
@media (max-width: 1024px) {
  .nav-links > li > a { padding: 10px 10px; font-size: 13.5px; }
}

@media (max-width: 900px) {
  .hamburger { display: flex; }
  .nav-links {
    position: fixed; top: 0; right: -100%; bottom: 0; width: min(340px, 90vw);
    flex-direction: column; align-items: stretch;
    background: var(--white);
    box-shadow: -8px 0 40px rgba(0,51,102,.2);
    padding: 96px 24px 40px;
    gap: 4px;
    transition: right var(--dur) var(--ease);
    z-index: 150;
    overflow-y: auto;
  }
  .nav-links.open { right: 0; }
  .nav-links > li > a { border-radius: var(--radius); padding: 14px 16px; font-size: 15px; }
  .dropdown-menu {
    position: static; opacity: 1; visibility: visible; pointer-events: all;
    transform: none; box-shadow: none; border: none;
    background: var(--gray-soft); margin: 4px 0 8px; padding: 4px;
    display: none;
  }
  .has-dropdown.open .dropdown-menu { display: block; }
  .has-dropdown:hover .dropdown-menu { opacity: 1; }
  .nav-cta { margin-top: 8px; justify-content: center; }
  .topbar-left, .header-topbar .topbar-right { gap: 10px; }
  .topbar-left a span, .header-topbar .topbar-right a span { display: none; }
}

@media (max-width: 768px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 480px) {
  .footer-grid { grid-template-columns: 1fr; }
  .footer-brand { grid-column: auto; }
  .container { padding: 0 16px; }
  .header-topbar { display: none; }
}
