:root {
  --primary: #0052cc;
  --primary-dark: #0747a6;
  --primary-light: #deebff;
  --accent: #ff5630;
  --accent-hover: #de350b;
  --dark: #172b4d;
  --light-bg: #f4f5f7;
  --surface: #ffffff;
  --border: #dfe1e6;
  --text: #344563;
  --text-muted: #6b778c;
  --success: #36b37e;
  --radius: 10px;
  --shadow-sm: 0 1px 3px rgba(9, 30, 66, 0.08);
  --shadow-md: 0 4px 14px rgba(9, 30, 66, 0.1);
  --shadow-lg: 0 12px 28px rgba(9, 30, 66, 0.12);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

body {
  background-color: var(--light-bg);
  color: var(--text);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header & Navigation */
header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--primary);
  text-decoration: none;
  letter-spacing: -0.5px;
}

.brand span {
  color: var(--accent);
}

nav ul {
  display: flex;
  list-style: none;
  gap: 1.75rem;
  align-items: center;
}

nav a {
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
  font-size: 0.95rem;
  transition: color 0.2s;
}

nav a:hover, nav a.active {
  color: var(--primary);
}

/* Button UI */
.btn {
  padding: 0.65rem 1.25rem;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  border: none;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, transform 0.1s;
}

.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-hover); }
.btn-outline {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
}
.btn-outline:hover { background: #ebecf0; }

/* Global Container */
main {
  flex: 1;
  max-width: 1240px;
  width: 100%;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
}

/* Sections & Cards */
.hero {
  background: linear-gradient(135deg, #ebf3ff 0%, #ffffff 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 3.5rem 2rem;
  text-align: center;
  margin-bottom: 3rem;
}

.hero h1 {
  font-size: 2.6rem;
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 1rem;
}

.hero p {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 650px;
  margin: 0 auto 2rem auto;
}

.section-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 0.5rem;
}

.section-subtitle {
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3.5rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.card-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
  display: inline-block;
}

.feature-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 0.5rem;
}

.feature-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Comparison View Elements */
.compare-container {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2rem;
  align-items: start;
}

.filter-sidebar {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.filter-group {
  margin-bottom: 1.5rem;
}

.filter-group label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--dark);
  display: block;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-group select, .filter-group input {
  width: 100%;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  font-size: 0.9rem;
}

.quote-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: 1.5rem;
  align-items: center;
  margin-bottom: 1rem;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s;
}

.quote-card:hover {
  border-color: var(--primary);
}

.insurer-details h4 {
  font-size: 1.15rem;
  color: var(--dark);
}

.badge {
  display: inline-block;
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 4px;
  font-weight: 600;
  margin-top: 0.35rem;
}

.metric span {
  font-size: 0.8rem;
  color: var(--text-muted);
  display: block;
}

.metric strong {
  font-size: 1rem;
  color: var(--dark);
}

.pricing {
  text-align: right;
}

.pricing .amount {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--dark);
}

.pricing .frequency {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Forms & Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.data-table th, .data-table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.data-table th {
  background: #fafbfc;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--dark);
}

/* Footer */
footer {
  background: var(--dark);
  color: #97a0af;
  padding: 3.5rem 1.5rem 1.5rem;
  margin-top: auto;
}

.footer-container {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

.footer-brand {
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 0.75rem;
}

.footer-col h5 {
  color: #fff;
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 0.6rem;
}

.footer-col a {
  color: #97a0af;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.footer-col a:hover {
  color: #fff;
}

.footer-bottom {
  max-width: 1240px;
  margin: 0 auto;
  padding-top: 1.5rem;
  border-top: 1px solid #253858;
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  flex-wrap: wrap;
  gap: 1rem;
}

@media (max-width: 900px) {
  .compare-container {
    grid-template-columns: 1fr;
  }
  .quote-card {
    grid-template-columns: 1fr;
    text-align: left;
  }
  .pricing {
    text-align: left;
  }
  .footer-container {
    grid-template-columns: 1fr;
  }
}