/* ═══════════════════════════════════
   Hair By Trac — Blog stylesheet
   Reuses the exact design tokens & components from index.html
   (the main site keeps its styles inline; the blog shares this file)
   ═══════════════════════════════════ */

/* ---- Tokens (copied verbatim from index.html :root) ---- */
:root {
  --color-dark: #36302A;
  --color-dark-warm: #574C3F;
  --color-accent: #B9A590;
  --color-accent-light: #cbb9a5;
  --color-cream: #ECE4DA;
  --color-cream-light: #F6F3EC;
  --color-white-warm: #FAF9F5;
  --color-text: #36302A;
  --color-text-muted: #7a6e62;

  --font-serif: 'Libre Baskerville', Georgia, serif;
  --font-sans: 'DM Sans', 'Almarai', sans-serif;

  --ease-smooth: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background: var(--color-cream);
  line-height: 1.65;
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s var(--ease-smooth);
}

/* ---- Typography ---- */
h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.2;
}
h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.8rem); }
p { font-size: 1rem; line-height: 1.75; color: var(--color-text-muted); }

.italic-accent {
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--color-accent);
}

/* ---- Buttons (copied verbatim) ---- */
.btn {
  display: inline-block;
  padding: 16px 36px;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  border-radius: 40px;
  border: none;
  cursor: pointer;
  transition: all 0.4s var(--ease-smooth);
  text-decoration: none;
}
.btn-primary { background: var(--color-dark); color: var(--color-cream-light); }
.btn-primary:hover {
  background: var(--color-dark-warm);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(54,48,42,0.2);
}
.btn-outline { background: transparent; color: var(--color-dark); border: 1px solid var(--color-accent); }
.btn-outline:hover { background: var(--color-accent); color: var(--color-dark); }
.btn-light { background: var(--color-cream-light); color: var(--color-dark); }
.btn-light:hover { background: #fff; transform: translateY(-2px); box-shadow: 0 8px 24px rgba(54,48,42,0.15); }

/* ---- Navigation (copied verbatim) ---- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(87, 76, 63, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 0 clamp(1.5rem, 4vw, 3rem);
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.4s var(--ease-smooth);
}
.nav.scrolled {
  height: 60px;
  background: rgba(54, 48, 42, 0.97);
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}
.nav-logo {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  color: var(--color-accent);
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.nav-links { display: flex; gap: 2rem; list-style: none; align-items: center; }
.nav-links a {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 400;
  color: var(--color-cream);
  letter-spacing: 0.03em;
  position: relative;
  padding: 4px 0;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 1px;
  background: var(--color-accent);
  transition: width 0.3s var(--ease-smooth);
}
.nav-links a:hover::after { width: 100%; }
.nav-links a:hover { color: var(--color-accent-light); }
.nav-cta {
  padding: 10px 24px !important;
  background: var(--color-accent) !important;
  color: var(--color-dark) !important;
  border-radius: 30px;
  font-weight: 500 !important;
  font-size: 0.82rem !important;
  transition: all 0.3s var(--ease-smooth) !important;
}
.nav-cta::after { display: none !important; }
.nav-cta:hover { background: var(--color-cream-light) !important; transform: translateY(-1px); }

/* Mobile hamburger */
.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: 8px; z-index: 1001; }
.hamburger span { width: 24px; height: 1.5px; background: var(--color-cream); transition: all 0.3s var(--ease-smooth); }
.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* Mobile overlay (copied verbatim) */
.mobile-menu {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(54, 48, 42, 0.98);
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s var(--ease-smooth);
}
.mobile-menu.open { opacity: 1; pointer-events: all; }
.mobile-menu a { font-family: var(--font-serif); font-size: 1.6rem; color: var(--color-cream); }
.mobile-menu a:hover { color: var(--color-accent); }

/* ═══════════════════════════════════
   BLOG-SPECIFIC LAYOUT
   ═══════════════════════════════════ */

/* Article column */
.article {
  background: var(--color-cream);
  padding: calc(72px + clamp(2rem, 6vw, 4rem)) clamp(1.5rem, 6vw, 6rem) clamp(3rem, 6vw, 5rem);
}
.article-inner { max-width: 740px; margin: 0 auto; }

/* Breadcrumb */
.breadcrumb {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
}
.breadcrumb a { color: var(--color-text-muted); }
.breadcrumb a:hover { color: var(--color-dark); }
.breadcrumb span { color: var(--color-accent); margin: 0 0.4rem; }

.eyebrow {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 1.25rem;
  display: block;
}

.article h1 { color: var(--color-dark); margin-bottom: 1rem; line-height: 1.15; }

/* Byline / E-E-A-T */
.byline {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin-bottom: 0.4rem;
}
.byline strong { color: var(--color-dark); font-weight: 500; }
.updated {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  color: var(--color-accent);
  margin-bottom: 2rem;
  display: block;
}

/* Cover image */
.article-cover {
  width: 100%;
  border-radius: 8px;
  margin: 0 0 2.5rem;
  background: var(--color-dark-warm);
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

/* Direct-answer block — the snippet LLMs lift */
.direct-answer {
  background: var(--color-white-warm);
  border-left: 3px solid var(--color-accent);
  border-radius: 0 8px 8px 0;
  padding: 1.5rem 1.75rem;
  margin: 0 0 2.5rem;
}
.direct-answer p { color: var(--color-dark); font-size: 1.08rem; line-height: 1.7; margin: 0; }

/* Body copy */
.article-body h2 {
  color: var(--color-dark);
  margin: 2.5rem 0 1rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
}
.article-body h3 { color: var(--color-dark); margin: 1.75rem 0 0.75rem; }
.article-body p { margin-bottom: 1.25rem; }
.article-body ul, .article-body ol { margin: 0 0 1.5rem 1.25rem; color: var(--color-text-muted); }
.article-body li { margin-bottom: 0.6rem; line-height: 1.7; }
.article-body a { color: var(--color-dark); text-decoration: underline; text-decoration-color: var(--color-accent); text-underline-offset: 3px; }
.article-body a:hover { color: var(--color-accent); }
.article-body strong { color: var(--color-dark); font-weight: 500; }

/* FAQ */
.faq { margin-top: 3rem; }
.faq h2 { color: var(--color-dark); margin-bottom: 1.5rem; }
.faq-q { margin-bottom: 1.5rem; }
.faq-q h3 { font-size: 1.15rem; color: var(--color-dark); margin-bottom: 0.5rem; }
.faq-q p { margin: 0; }

/* CTA block */
.cta-block {
  background: var(--color-dark);
  border-radius: 10px;
  padding: clamp(2rem, 5vw, 3rem);
  margin: 3rem 0 0;
  text-align: center;
}
.cta-block h2 { color: var(--color-cream-light); margin-bottom: 1rem; }
.cta-block p { color: var(--color-accent-light); opacity: 0.85; max-width: 480px; margin: 0 auto 1.75rem; }

/* ═══════════════════════════════════
   BLOG INDEX
   ═══════════════════════════════════ */
.blog-hero {
  background: var(--color-dark-warm);
  padding: calc(72px + clamp(3rem, 8vw, 6rem)) clamp(1.5rem, 6vw, 6rem) clamp(3rem, 6vw, 5rem);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.blog-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 80%, rgba(185,165,144,0.08) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(87,76,63,0.3) 0%, transparent 50%);
  pointer-events: none;
}
.blog-hero .inner { max-width: 640px; margin: 0 auto; position: relative; z-index: 2; }
.blog-hero h1 { color: var(--color-cream-light); margin-bottom: 1rem; }
.blog-hero p { color: var(--color-accent-light); opacity: 0.9; font-size: 1.05rem; }

.blog-grid-section { padding: clamp(3rem, 6vw, 5rem) clamp(1.5rem, 6vw, 6rem); }
.blog-grid {
  max-width: 1080px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
}
.blog-card {
  background: var(--color-cream-light);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.4s var(--ease-smooth), box-shadow 0.4s var(--ease-smooth);
}
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(54,48,42,0.12); }
.blog-card-image { aspect-ratio: 16 / 10; background: var(--color-dark-warm); }
.blog-card-image img { width: 100%; height: 100%; object-fit: cover; }
.blog-card-body { padding: 1.75rem; display: flex; flex-direction: column; flex: 1; }
.blog-card .eyebrow { margin-bottom: 0.75rem; }
.blog-card h2 { font-size: 1.4rem; color: var(--color-dark); margin-bottom: 0.75rem; line-height: 1.25; }
.blog-card p { font-size: 0.95rem; margin-bottom: 1.5rem; flex: 1; }
.blog-card a.card-link { font-family: var(--font-sans); font-size: 0.85rem; font-weight: 500; letter-spacing: 0.04em; color: var(--color-dark); text-transform: uppercase; }
.blog-card a.card-link:hover { color: var(--color-accent); }
.blog-card.coming-soon { opacity: 0.75; }
.blog-card.coming-soon .eyebrow { color: var(--color-text-muted); }

/* ---- Footer (copied verbatim) ---- */
.footer { background: var(--color-dark); padding: clamp(3rem, 6vw, 5rem) clamp(1.5rem, 6vw, 6rem); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 3rem; max-width: 1200px; margin: 0 auto; }
.footer-brand .nav-logo { font-size: 1.5rem; margin-bottom: 1rem; display: block; }
.footer-brand p { color: var(--color-accent-light); font-size: 0.88rem; opacity: 0.7; max-width: 280px; }
.footer-col h4 {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 1.25rem;
}
.footer-col a, .footer-col p {
  display: block;
  font-size: 0.88rem;
  color: var(--color-accent-light);
  opacity: 0.65;
  margin-bottom: 0.6rem;
  transition: opacity 0.3s;
}
.footer-col a:hover { opacity: 1; }
.footer-bottom {
  max-width: 1200px;
  margin: 3rem auto 0;
  padding-top: 2rem;
  border-top: 1px solid rgba(185,165,144,0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer-bottom p { font-size: 0.78rem; color: var(--color-accent-light); opacity: 0.4; }
.footer-social { display: flex; gap: 1rem; }
.footer-social a {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(185,165,144,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent-light);
  font-size: 0.8rem;
  transition: all 0.3s var(--ease-smooth);
}
.footer-social a:hover { background: var(--color-accent); color: var(--color-dark); border-color: var(--color-accent); }

/* ---- Responsive (matches index.html breakpoints) ---- */
@media (max-width: 992px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
}
