/* Clausianism Insurance — Mexlife-inspired theme */
:root {
  --teal: #00A99D;
  --teal-dark: #008F84;
  --teal-light: #E6F7F5;
  --charcoal: #1A1A1B;
  --charcoal-soft: #2B2B2C;
  --gray-bg: #F8F9FA;
  --gray-text: #6B7280;
  --white: #ffffff;
  --shadow: 0 10px 40px rgba(26, 26, 27, 0.08);
  --radius: 4px;
  --font: "Poppins", system-ui, -apple-system, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--charcoal);
  background: var(--white);
  line-height: 1.7;
  font-size: 15px;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--teal);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--teal-dark);
}

.container {
  width: min(1170px, 92%);
  margin: 0 auto;
}

.section {
  padding: 80px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 48px;
}

.section-title .subtitle {
  color: var(--teal);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-size: 14px;
  display: block;
  margin-bottom: 8px;
}

.section-title h2 {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  margin: 0 0 12px;
  font-weight: 700;
  line-height: 1.25;
}

.section-title p {
  color: var(--gray-text);
  max-width: 640px;
  margin: 0 auto;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 14px 28px;
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: none;
  cursor: pointer;
  border-radius: var(--radius);
  transition: background 0.2s, transform 0.15s;
  font-family: inherit;
}

.btn-primary {
  background: var(--teal);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--teal-dark);
  color: var(--white);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--teal);
  color: var(--teal);
}

.btn-outline:hover {
  background: var(--teal);
  color: var(--white);
}

.btn-dark {
  background: var(--charcoal);
  color: var(--white);
}

.btn-dark:hover {
  background: var(--charcoal-soft);
  color: var(--white);
}

/* Header */
.site-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 18px 0;
}

.site-header.scrolled,
.site-header.inner-header {
  position: fixed;
  background: var(--white);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06);
  padding: 12px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  flex-shrink: 0;
}

.logo-mark {
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  display: block;
}

.logo-wordmark {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.logo-wordmark strong {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--charcoal);
  letter-spacing: -0.02em;
}

.logo-wordmark em {
  font-style: normal;
  font-size: 0.62rem;
  font-weight: 600;
  color: var(--teal);
  letter-spacing: 0.22em;
}

.site-header:not(.scrolled):not(.inner-header) .logo-wordmark strong {
  color: var(--white);
}

.site-header:not(.scrolled):not(.inner-header) .logo-wordmark em {
  color: #4dd4ca;
}

.site-header.scrolled .logo-wordmark strong,
.site-header.inner-header .logo-wordmark strong {
  color: var(--charcoal);
}

.site-header.scrolled .logo-wordmark em,
.site-header.inner-header .logo-wordmark em {
  color: var(--teal);
}

.footer-brand .logo {
  justify-content: center;
  margin-bottom: 8px;
}

.footer-brand .logo-wordmark strong {
  color: var(--white);
}

.footer-brand .logo-wordmark em {
  color: #4dd4ca;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  width: 26px;
  height: 2px;
  background: var(--charcoal);
  transition: 0.2s;
}

.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 22px;
  justify-content: center;
}

.main-nav a {
  color: var(--charcoal);
  font-weight: 500;
  font-size: 14px;
}

.site-header:not(.scrolled):not(.inner-header) .main-nav a {
  color: var(--white);
}

.site-header:not(.scrolled):not(.inner-header) .nav-toggle span {
  background: var(--white);
}

.main-nav a.active,
.main-nav a:hover {
  color: var(--teal);
}

.site-header:not(.scrolled):not(.inner-header) .main-nav a:hover,
.site-header:not(.scrolled):not(.inner-header) .main-nav a.active {
  color: var(--teal-light);
}

.header-cta .btn {
  padding: 12px 22px;
  font-size: 13px;
}

/* Page banner */
.page-banner {
  background: linear-gradient(135deg, var(--charcoal) 55%, var(--charcoal-soft));
  padding: 140px 0 70px;
  color: var(--white);
  text-align: center;
}

.page-banner h1 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 5vw, 2.75rem);
}

.breadcrumb {
  color: rgba(255, 255, 255, 0.75);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--teal-light);
}

/* Hero home */
.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 92vh;
  align-items: stretch;
}

.hero-content {
  background: var(--charcoal);
  color: var(--white);
  padding: 140px 8% 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-content .subtitle {
  color: var(--teal);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 13px;
  margin-bottom: 16px;
}

.hero-content h1 {
  font-size: clamp(1.85rem, 4vw, 2.75rem);
  line-height: 1.2;
  margin: 0 0 20px;
}

.hero-content p {
  color: rgba(255, 255, 255, 0.82);
  max-width: 480px;
  margin-bottom: 28px;
}

.hero-image {
  position: relative;
  min-height: 400px;
}

.hero-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Feature cards */
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-top: -60px;
  position: relative;
  z-index: 2;
  padding-bottom: 20px;
}

.feature-card {
  background: var(--white);
  padding: 32px 24px;
  box-shadow: var(--shadow);
  border-top: 4px solid var(--teal);
  transition: transform 0.2s;
}

.feature-card:hover {
  transform: translateY(-4px);
}

.feature-card .icon {
  width: 52px;
  height: 52px;
  background: var(--teal-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--teal);
  font-size: 22px;
  margin-bottom: 18px;
}

.feature-card h3 {
  margin: 0 0 10px;
  font-size: 1.1rem;
}

.feature-card p {
  margin: 0;
  color: var(--gray-text);
  font-size: 14px;
}

/* Two column blocks */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.split img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.split .subtitle {
  color: var(--teal);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-size: 13px;
}

.split h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin: 8px 0 16px;
}

.bg-light {
  background: var(--gray-bg);
}

/* Stats */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
  padding: 48px 0;
  border-top: 1px solid #e5e7eb;
}

.stat-item h3 {
  color: var(--teal);
  font-size: 2rem;
  margin: 0 0 6px;
}

.stat-item p {
  margin: 0;
  color: var(--gray-text);
  font-size: 14px;
}

/* Testimonials */
.testimonial-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.testimonial-card {
  background: var(--white);
  padding: 28px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  position: relative;
}

.testimonial-card::before {
  content: "\201C";
  font-size: 48px;
  color: var(--teal-light);
  line-height: 1;
  position: absolute;
  top: 12px;
  left: 20px;
}

.stars {
  color: #f59e0b;
  margin-bottom: 12px;
}

/* Gallery row */
.gallery-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}

.gallery-row img {
  width: 100%;
  height: 280px;
  object-fit: cover;
}

/* Dark CTA section */
.dark-section {
  background: var(--charcoal);
  color: var(--white);
}

.dark-section .split ul {
  padding-left: 20px;
}

.dark-section .split li {
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.85);
}

.teal-overlay-box {
  background: var(--teal);
  padding: 24px;
  margin-top: -40px;
  margin-left: 20%;
  position: relative;
  z-index: 2;
  font-weight: 600;
}

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.pricing-card {
  background: var(--white);
  padding: 40px 32px;
  text-align: center;
  box-shadow: var(--shadow);
  border-radius: var(--radius);
}

.pricing-card.featured {
  border-top: 4px solid var(--teal);
  transform: scale(1.03);
}

.pricing-card .price {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--teal);
  margin: 16px 0;
}

.pricing-card .price span {
  font-size: 14px;
  color: var(--gray-text);
  font-weight: 400;
}

.pricing-card ul {
  list-style: none;
  padding: 0;
  margin: 24px 0;
  text-align: left;
}

.pricing-card li {
  padding: 8px 0 8px 28px;
  position: relative;
  font-size: 14px;
  border-bottom: 1px solid #f0f0f0;
}

.pricing-card li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  color: var(--teal);
  font-weight: 700;
}

/* Forms */
.form-wrap {
  background: var(--white);
  padding: 40px;
  box-shadow: var(--shadow);
  border-radius: var(--radius);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 500;
  margin-bottom: 8px;
  font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #d1d5db;
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 15px;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--teal);
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.form-group.error input,
.form-group.error textarea,
.form-group.error select {
  border-color: #dc2626;
}

.field-error {
  color: #dc2626;
  font-size: 13px;
  margin-top: 6px;
  display: none;
}

.form-group.error .field-error {
  display: block;
}

.checkbox-group {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.checkbox-group .field-error {
  flex-basis: 100%;
  margin-left: 30px;
}

.checkbox-group input[type="checkbox"] {
  width: 18px;
  height: 18px;
  min-width: 18px;
  margin-top: 3px;
  accent-color: var(--teal);
  cursor: pointer;
  flex-shrink: 0;
}

.checkbox-group label {
  font-size: 14px;
  line-height: 1.5;
  cursor: pointer;
  margin: 0;
  flex: 1;
}

.checkbox-group.error .field-error {
  display: block;
  width: 100%;
}

.form-success {
  display: none;
  background: var(--teal-light);
  border: 1px solid var(--teal);
  color: var(--charcoal);
  padding: 20px;
  border-radius: var(--radius);
  text-align: center;
  font-weight: 600;
  margin-top: 16px;
}

.form-success.visible {
  display: block;
}

.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

/* Blog cards */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.blog-card {
  background: var(--white);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.blog-card img {
  height: 220px;
  width: 100%;
  object-fit: cover;
}

.blog-card .content {
  padding: 24px;
}

.blog-meta {
  font-size: 13px;
  color: var(--teal);
  font-weight: 600;
  margin-bottom: 8px;
}

/* Team */
.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.team-card {
  text-align: center;
  background: var(--white);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.team-card img {
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.team-card .info {
  padding: 20px;
}

.team-card h3 {
  margin: 0 0 4px;
  font-size: 1.05rem;
}

.team-card p {
  margin: 0;
  color: var(--teal);
  font-size: 13px;
  font-weight: 600;
}

/* Projects */
.project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.project-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
}

.project-card img {
  height: 260px;
  width: 100%;
  object-fit: cover;
  transition: transform 0.35s;
}

.project-card:hover img {
  transform: scale(1.05);
}

.project-card .overlay {
  position: absolute;
  inset: auto 0 0 0;
  background: linear-gradient(transparent, rgba(26, 26, 27, 0.9));
  color: var(--white);
  padding: 24px;
}

/* Services list */
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.service-box {
  background: var(--white);
  padding: 36px 28px;
  border-left: 4px solid var(--teal);
  box-shadow: var(--shadow);
}

/* Legal long content */
.legal-content {
  max-width: 900px;
  margin: 0 auto;
}

.legal-content h2 {
  font-size: 1.35rem;
  margin-top: 40px;
  color: var(--charcoal);
}

.legal-content h3 {
  font-size: 1.1rem;
  margin-top: 28px;
}

.legal-content p,
.legal-content li {
  color: #374151;
}

.legal-content ul {
  margin: 12px 0;
}

/* Footer */
.footer-cta-bar {
  background: var(--teal);
  padding: 36px 0;
  color: var(--white);
}

.footer-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-cta-inner h3 {
  margin: 0;
  font-size: 1.35rem;
}

.site-footer {
  background: var(--charcoal);
  color: rgba(255, 255, 255, 0.75);
  padding: 64px 0 24px;
  font-size: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1.3fr;
  gap: 40px;
  margin-bottom: 48px;
}

.site-footer h4 {
  color: var(--white);
  margin: 0 0 20px;
  font-size: 1rem;
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.site-footer li {
  margin-bottom: 10px;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.75);
}

.site-footer a:hover {
  color: var(--teal);
}

.footer-brand {
  text-align: center;
}

.footer-brand img {
  height: 48px;
  margin: 0 auto 16px;
}

.social-links {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 16px;
}

.social-links a {
  width: 40px;
  height: 40px;
  background: var(--teal);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-weight: 700;
  font-size: 12px;
}

.newsletter-form {
  display: flex;
  gap: 0;
}

.newsletter-form input {
  flex: 1;
  padding: 12px 14px;
  border: none;
  border-radius: var(--radius) 0 0 var(--radius);
  font-family: inherit;
}

.newsletter-form button {
  padding: 12px 18px;
  background: var(--teal);
  border: none;
  color: var(--white);
  cursor: pointer;
  border-radius: 0 var(--radius) var(--radius) 0;
  font-weight: 600;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 24px;
  text-align: center;
  font-size: 13px;
}

.footer-legal {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  justify-content: center;
}

/* Responsive */
@media (max-width: 1024px) {
  .features-grid,
  .team-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .pricing-grid,
  .service-grid,
  .project-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats-bar {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .main-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: min(300px, 85vw);
    height: 100vh;
    background: var(--white);
    padding: 80px 24px 24px;
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.1);
    transition: right 0.3s;
    z-index: 200;
  }

  .main-nav.open {
    right: 0;
  }

  .main-nav ul {
    flex-direction: column;
    gap: 16px;
  }

  .main-nav a {
    color: var(--charcoal) !important;
  }

  .header-cta {
    display: none;
  }

  .hero,
  .split {
    grid-template-columns: 1fr;
  }

  .hero-content {
    padding: 120px 6% 48px;
  }

  .features-grid {
    grid-template-columns: 1fr;
    margin-top: 0;
  }

  .gallery-row {
    grid-template-columns: 1fr;
  }

  .testimonial-grid,
  .blog-grid,
  .pricing-grid,
  .service-grid,
  .project-grid,
  .team-grid,
  .form-row-2 {
    grid-template-columns: 1fr;
  }

  .pricing-card.featured {
    transform: none;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-cta-inner {
    text-align: center;
    justify-content: center;
  }

  .form-wrap {
    padding: 28px 20px;
  }
}