/* ============================================
   Cnains.com — Insurance Agency
   Design: Professional, warm, trustworthy
   Fonts: DM Serif Display + DM Sans
   Palette: Navy #1a2744, Gold #c8943e, Off-white #faf8f5
   ============================================ */

:root {
  --navy: #1a2744;
  --navy-light: #2a3d5e;
  --navy-dark: #0f1a2e;
  --gold: #c8943e;
  --gold-light: #d4a85c;
  --gold-dark: #a87a2f;
  --cream: #faf8f5;
  --cream-dark: #f0ece6;
  --text: #2c2c2c;
  --text-muted: #6b6b6b;
  --text-light: #999;
  --white: #ffffff;
  --border: #e5e0d8;
  --shadow-sm: 0 1px 3px rgba(26, 39, 68, 0.06);
  --shadow-md: 0 4px 16px rgba(26, 39, 68, 0.08);
  --shadow-lg: 0 8px 32px rgba(26, 39, 68, 0.12);
  --radius: 6px;
  --radius-lg: 12px;
  --transition: 0.25s ease;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--cream);
}

h1, h2, h3 {
  font-family: 'DM Serif Display', serif;
  font-weight: 400;
  line-height: 1.15;
  color: var(--navy);
}

h4 {
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

a {
  color: var(--gold-dark);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--gold); }

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

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================
   Buttons
   ============================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 500;
  padding: 14px 32px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  letter-spacing: 0.01em;
}

.btn-primary {
  background: var(--navy);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--navy-light);
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

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

.btn-full { width: 100%; }

/* ============================================
   Header
   ============================================ */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(250, 248, 245, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(26, 39, 68, 0.06);
  transition: background var(--transition);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.logo-img {
  height: 40px;
  width: auto;
  border-radius: 6px;
  object-fit: contain;
}

.logo-text {
  font-family: 'DM Serif Display', serif;
  font-size: 1.2rem;
  color: var(--navy);
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-link {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition);
}
.nav-link:hover { color: var(--navy); }

.cta-link {
  background: var(--navy);
  color: var(--white) !important;
  padding: 10px 24px;
  border-radius: var(--radius);
}
.cta-link:hover {
  background: var(--navy-light);
  color: var(--white) !important;
}

/* Mobile menu */
.mobile-menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.mobile-menu-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--navy);
  transition: all var(--transition);
}

.mobile-nav {
  display: none;
  flex-direction: column;
  padding: 0 24px 20px;
  gap: 4px;
}
.mobile-nav.open { display: flex; }

.mobile-nav-link {
  display: block;
  padding: 12px 0;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text);
  border-bottom: 1px solid var(--border);
}

@media (max-width: 768px) {
  .header-nav { display: none; }
  .mobile-menu-btn { display: flex; }
}

/* ============================================
   Hero
   ============================================ */

.hero {
  padding: 160px 0 100px;
  background: var(--cream);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -200px;
  right: -200px;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(200, 148, 62, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  max-width: 640px;
}

.hero-eyebrow {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold-dark);
  margin-bottom: 20px;
}

.hero-title {
  font-size: clamp(2.5rem, 5.5vw, 3.75rem);
  line-height: 1.08;
  margin-bottom: 24px;
  color: var(--navy);
}

.hero-sub {
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--text-muted);
  margin-bottom: 36px;
  max-width: 520px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  margin-bottom: 60px;
  flex-wrap: wrap;
}

.hero-trust {
  display: flex;
  align-items: center;
  gap: 28px;
}

.trust-item {
  display: flex;
  flex-direction: column;
}

.trust-number {
  font-family: 'DM Serif Display', serif;
  font-size: 1.5rem;
  color: var(--navy);
  line-height: 1;
}

.trust-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 500;
}

.trust-divider {
  width: 1px;
  height: 36px;
  background: var(--border);
}

/* ============================================
   About Section
   ============================================ */

.about-section {
  padding: 100px 0;
  background: var(--white);
}

.section-eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold-dark);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(2rem, 4vw, 2.75rem);
  margin-bottom: 20px;
  color: var(--navy);
}

.section-sub {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 560px;
  margin-bottom: 48px;
  line-height: 1.7;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.about-body {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.75;
}

.about-cards {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.about-card {
  padding: 28px;
  background: var(--cream);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  transition: all var(--transition);
}
.about-card:hover {
  border-color: var(--gold-light);
  box-shadow: var(--shadow-sm);
}

.about-card-icon {
  width: 44px;
  height: 44px;
  background: var(--navy);
  color: var(--gold);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.about-card h3 {
  font-size: 1.15rem;
  margin-bottom: 8px;
}

.about-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

@media (max-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* ============================================
   Insurance / Tabs Section
   ============================================ */

.insurance-section {
  padding: 100px 0;
  background: var(--cream);
}

.tabs {
  margin-top: 48px;
}

.tab-nav {
  display: flex;
  gap: 4px;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 5px;
  border: 1px solid var(--border);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.tab-btn {
  font-family: 'DM Sans', sans-serif;
  font-size: 0.88rem;
  font-weight: 500;
  padding: 12px 20px;
  border: none;
  background: none;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: 8px;
  transition: all var(--transition);
  white-space: nowrap;
  flex-shrink: 0;
}
.tab-btn:hover { color: var(--navy); background: var(--cream); }

.tab-btn.active {
  background: var(--navy);
  color: var(--white);
}

.tab-panels {
  margin-top: 24px;
}

.tab-panel {
  display: none;
  animation: fadeIn 0.3s ease;
}
.tab-panel.active { display: block; }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.tab-content {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  padding: 48px;
}

.tab-info h3 {
  font-size: 1.75rem;
  margin-bottom: 12px;
}

.tab-lead {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 32px;
  line-height: 1.7;
  max-width: 680px;
}

.tab-info h4 {
  margin-top: 28px;
  margin-bottom: 12px;
  font-size: 0.8rem;
}

.tab-info ul {
  list-style: none;
  padding: 0;
  margin-bottom: 8px;
}

.tab-info ul li {
  position: relative;
  padding: 10px 0 10px 24px;
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.65;
  border-bottom: 1px solid rgba(0,0,0,0.04);
}
.tab-info ul li:last-child { border-bottom: none; }

.tab-info ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 18px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
}

.tab-info p {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text);
  margin-bottom: 8px;
}

.tab-cta {
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}

@media (max-width: 768px) {
  .tab-content { padding: 28px 20px; }
  .tab-nav { gap: 2px; padding: 4px; }
  .tab-btn { padding: 10px 14px; font-size: 0.82rem; }
}

/* ============================================
   Contact Section
   ============================================ */

.contact-section {
  padding: 100px 0;
  background: var(--white);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 72px;
  align-items: start;
}

.contact-body {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 36px;
  line-height: 1.7;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.contact-detail {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.contact-icon {
  width: 40px;
  height: 40px;
  background: var(--cream);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy);
  flex-shrink: 0;
}

.contact-detail strong {
  display: block;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.contact-detail a,
.contact-detail span {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.5;
}

/* Form */
.contact-form-wrap {
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: 40px;
  border: 1px solid var(--border);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 6px;
}

.req { color: var(--gold-dark); }

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  padding: 12px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--text);
  transition: all var(--transition);
  outline: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-light);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(26, 39, 68, 0.08);
}

.form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%236b6b6b' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-note {
  font-size: 0.8rem;
  color: var(--text-light);
  text-align: center;
  margin-top: -8px;
}

/* Success state */
.form-success {
  text-align: center;
  padding: 48px 24px;
}

.success-icon {
  color: var(--gold);
  margin-bottom: 20px;
}

.form-success h3 {
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.form-success p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

@media (max-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .form-row { grid-template-columns: 1fr; }
  .contact-form-wrap { padding: 28px 20px; }
}

/* ============================================
   Footer
   ============================================ */

.site-footer {
  background: var(--navy-dark);
  color: rgba(255, 255, 255, 0.7);
  padding: 64px 0 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.footer-logo-img {
  height: 36px;
}

.footer-logo .logo-text {
  color: var(--white);
}

.footer-tagline {
  font-size: 0.9rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.5);
  max-width: 280px;
}

.footer-links h4,
.footer-contact h4 {
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 16px;
}

.footer-links a {
  display: block;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
  padding: 5px 0;
  transition: color var(--transition);
}
.footer-links a:hover { color: var(--gold); }

.footer-contact p {
  font-size: 0.9rem;
  margin-bottom: 8px;
  line-height: 1.5;
}

.footer-contact a {
  color: rgba(255, 255, 255, 0.7);
}
.footer-contact a:hover { color: var(--gold); }

.footer-bottom {
  padding-top: 24px;
  text-align: center;
}

.footer-bottom p {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.3);
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

/* ============================================
   Scroll offset for fixed header
   ============================================ */

[id] {
  scroll-margin-top: 80px;
}

/* ============================================
   Selection color
   ============================================ */

::selection {
  background: rgba(200, 148, 62, 0.2);
  color: var(--navy);
}

/* ============================================
   Loading animation for page
   ============================================ */

.hero-content,
.about-section,
.insurance-section,
.contact-section {
  opacity: 0;
  transform: translateY(20px);
  animation: slideUp 0.6s ease forwards;
}

.about-section { animation-delay: 0.1s; }
.insurance-section { animation-delay: 0.15s; }
.contact-section { animation-delay: 0.2s; }

@keyframes slideUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
