/* ===== WRAG - White Rabbit Advisory Group ===== */
/* Color Palette: Navy #1a2744, Gold #c9a84c, Dark Gold #a68a3e, Light BG #f8f6f1, White #fff */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --navy: #1a2744;
  --navy-light: #243456;
  --gold: #c9a84c;
  --gold-dark: #a68a3e;
  --gold-light: #e0cc8a;
  --bg-light: #f8f6f1;
  --bg-white: #ffffff;
  --text-dark: #222;
  --text-muted: #555;
  --text-light: #888;
  --border: #e0dcd4;
  --shadow: 0 2px 12px rgba(26,39,68,0.08);
  --shadow-lg: 0 8px 32px rgba(26,39,68,0.12);
  --radius: 8px;
  --transition: 0.3s ease;
  --max-width: 1140px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  color: var(--text-dark);
  background: var(--bg-white);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold-dark); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--navy); }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }

/* --- Typography --- */
h1, h2, h3, h4 { font-weight: 700; line-height: 1.25; color: var(--navy); }
h1 { font-size: 2.75rem; }
h2 { font-size: 2rem; margin-bottom: 16px; }
h3 { font-size: 1.35rem; margin-bottom: 10px; }
p { margin-bottom: 16px; }

.section-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 640px;
  margin: 0 auto 48px;
  text-align: center;
}

/* --- Header / Nav --- */
.site-header {
  background: var(--bg-white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--navy);
}

.nav-logo img { width: 48px; height: 48px; border-radius: 50%; }

.nav-links { display: flex; gap: 28px; list-style: none; }
.nav-links a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-dark);
  padding: 4px 0;
  border-bottom: 2px solid transparent;
  transition: border-color var(--transition), color var(--transition);
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--navy);
  border-bottom-color: var(--gold);
}

/* Mobile hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: var(--transition);
}

/* --- Hero --- */
.hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
  color: #fff;
  padding: 100px 0 90px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 60px;
  background: var(--bg-white);
  clip-path: ellipse(55% 100% at 50% 100%);
}

.hero h1 { color: #fff; margin-bottom: 20px; }
.hero-logo {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  margin: 0 auto 28px;
  display: block;
  border: 3px solid rgba(201, 168, 76, 0.4);
  box-shadow: 0 4px 24px rgba(0,0,0,0.2);
}
.hero .tagline {
  font-size: 1.3rem;
  color: var(--gold-light);
  font-weight: 500;
  margin-bottom: 28px;
}
.hero p {
  max-width: 620px;
  margin: 0 auto 36px;
  font-size: 1.1rem;
  color: rgba(255,255,255,0.85);
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: background var(--transition), transform 0.15s;
  border: none;
}
.btn:hover { transform: translateY(-1px); }

.btn-gold {
  background: var(--gold);
  color: var(--navy);
}
.btn-gold:hover { background: var(--gold-dark); color: var(--navy); }

.btn-outline {
  background: transparent;
  border: 2px solid var(--gold);
  color: var(--gold);
}
.btn-outline:hover { background: var(--gold); color: var(--navy); }

.btn-white {
  background: #fff;
  color: var(--navy);
}
.btn-white:hover { background: var(--bg-light); color: var(--navy); }

/* --- Sections --- */
.section { padding: 80px 0; }
.section-alt { background: var(--bg-light); }
.section-header { text-align: center; margin-bottom: 48px; }

/* --- Cards --- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
}

.card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 28px;
  transition: box-shadow var(--transition), transform 0.15s;
}
.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.card-icon {
  width: 52px;
  height: 52px;
  background: var(--bg-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  font-size: 1.5rem;
}

/* --- Case Study --- */
.case-study-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 800px;
  margin: 0 auto;
  box-shadow: var(--shadow);
}

.case-study-card .cs-header {
  background: var(--navy);
  color: #fff;
  padding: 32px 36px;
}

.case-study-card .cs-header h3 { color: var(--gold-light); font-size: 1.5rem; }
.case-study-card .cs-header p { color: rgba(255,255,255,0.8); margin-bottom: 0; }

.case-study-card .cs-body { padding: 36px; }

.cs-stats {
  display: flex;
  gap: 36px;
  margin: 24px 0;
  flex-wrap: wrap;
}
.cs-stat {
  text-align: center;
  flex: 1;
  min-width: 120px;
}
.cs-stat .num {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  color: var(--gold-dark);
}
.cs-stat .label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* --- Blog listing --- */
.blog-list { max-width: 860px; margin: 0 auto; }

.blog-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0;
  overflow: hidden;
  transition: box-shadow var(--transition), transform 0.15s;
  margin-bottom: 28px;
}
.blog-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.blog-card-accent {
  height: 5px;
  background: linear-gradient(90deg, var(--gold) 0%, var(--gold-dark) 100%);
}

.blog-card-body {
  padding: 32px 36px 28px;
}

.blog-card .meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--text-light);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
}
.blog-card .meta .tag {
  background: var(--bg-light);
  color: var(--gold-dark);
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
}

.blog-card h3 {
  font-size: 1.5rem;
  margin-bottom: 12px;
  line-height: 1.35;
}
.blog-card h3 a { color: var(--navy); }
.blog-card h3 a:hover { color: var(--gold-dark); }

.blog-card p {
  color: var(--text-muted);
  margin-bottom: 20px;
  font-size: 1.02rem;
  line-height: 1.65;
}

.read-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--gold-dark);
  padding: 8px 18px;
  border: 2px solid var(--gold);
  border-radius: var(--radius);
  transition: background var(--transition), color var(--transition);
}
.read-more:hover {
  background: var(--gold);
  color: var(--navy);
}

/* Featured blog card */
.blog-card.featured {
  border: none;
  box-shadow: var(--shadow);
}
.blog-card.featured .blog-card-accent {
  height: 6px;
}
.blog-card.featured .blog-card-body {
  padding: 36px 40px 32px;
}
.blog-card.featured h3 {
  font-size: 1.65rem;
}

/* Blog empty state */
.blog-empty {
  text-align: center;
  padding: 48px 24px;
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  margin-top: 20px;
}
.blog-empty p {
  color: var(--text-light);
  margin-bottom: 0;
}

/* Legacy blog-item support */
.blog-item {
  padding: 28px 0;
  border-bottom: 1px solid var(--border);
}
.blog-item:last-child { border-bottom: none; }
.blog-item .meta {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-bottom: 6px;
}
.blog-item h3 a { color: var(--navy); }
.blog-item h3 a:hover { color: var(--gold-dark); }
.blog-item p { color: var(--text-muted); margin-bottom: 8px; }

/* --- Contact --- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.contact-info h3 { margin-bottom: 16px; }
.contact-info p { color: var(--text-muted); }

.contact-detail {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 1rem;
}
.contact-detail .icon {
  width: 40px;
  height: 40px;
  background: var(--bg-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.form-group { margin-bottom: 20px; }
.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  font-size: 0.9rem;
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 1rem;
  font-family: inherit;
  background: var(--bg-white);
  transition: border-color var(--transition);
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--gold);
}
.form-group textarea { min-height: 130px; resize: vertical; }

/* --- CTA Banner --- */
.cta-banner {
  background: var(--navy);
  color: #fff;
  text-align: center;
  padding: 64px 24px;
}
.cta-banner h2 { color: #fff; margin-bottom: 12px; }
.cta-banner p { color: rgba(255,255,255,0.8); margin-bottom: 28px; max-width: 520px; margin-left: auto; margin-right: auto; }

/* --- Footer --- */
.site-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.7);
  padding: 48px 0 24px;
  font-size: 0.9rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 36px;
}
.footer-brand img { width: 48px; border-radius: 50%; margin-bottom: 12px; }
.footer-brand p { max-width: 300px; }

.site-footer h4 {
  color: var(--gold-light);
  font-size: 0.95rem;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.site-footer ul { list-style: none; }
.site-footer ul li { margin-bottom: 8px; }
.site-footer ul a { color: rgba(255,255,255,0.7); }
.site-footer ul a:hover { color: var(--gold-light); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 20px;
  text-align: center;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.5);
}

/* --- Blog Post --- */
.blog-post-hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
  color: #fff;
  padding: 72px 0 60px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.blog-post-hero::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 50px;
  background: var(--bg-light);
  clip-path: ellipse(55% 100% at 50% 100%);
}
.blog-post-hero h1 {
  color: #fff;
  font-size: 2.2rem;
  max-width: 740px;
  margin: 0 auto 16px;
  line-height: 1.3;
}
.blog-post-hero .meta {
  color: rgba(255,255,255,0.6);
  font-size: 0.9rem;
  margin-bottom: 0;
}

.blog-post {
  max-width: 740px;
  margin: 0 auto;
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 48px 48px 40px;
  box-shadow: var(--shadow);
  position: relative;
  top: -24px;
}
.blog-post h1 { font-size: 2.2rem; margin-bottom: 12px; }
.blog-post .meta { color: var(--text-light); margin-bottom: 32px; font-size: 0.9rem; }
.blog-post h2 {
  font-size: 1.4rem;
  margin: 40px 0 12px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.blog-post h2:first-of-type {
  border-top: none;
  padding-top: 0;
}
.blog-post p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.75;
}
.blog-post ul, .blog-post ol { margin: 0 0 16px 24px; color: var(--text-muted); }
.blog-post li { margin-bottom: 6px; }

.blog-post-nav {
  max-width: 740px;
  margin: 0 auto;
  text-align: center;
  padding: 24px 0 0;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }

  .nav-toggle { display: flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--bg-white);
    flex-direction: column;
    padding: 16px 24px;
    gap: 0;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
  .nav-links li { padding: 10px 0; }

  .hero { padding: 64px 0 60px; }
  .hero-logo { width: 110px; height: 110px; margin-bottom: 20px; }
  .hero .tagline { font-size: 1.1rem; }

  .section { padding: 52px 0; }

  .contact-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }

  .cs-stats { gap: 16px; }
}

@media (max-width: 480px) {
  h1 { font-size: 1.7rem; }
  .hero { padding: 48px 0 44px; }
  .hero-logo { width: 90px; height: 90px; margin-bottom: 16px; }
  .card-grid { grid-template-columns: 1fr; }
}