/* ==========================================================================
   THE BEAUTY THESAURUS — BASE STYLESHEET
   Shared design tokens, typography, header/nav, footer, buttons & components.
   Loaded on every page. Page-specific styles live in their own files.
   ========================================================================== */

/* ---- Fonts ---- */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,400;0,9..144,500;0,9..144,600;0,9..144,700;1,9..144,500&family=Manrope:wght@400;500;600;700;800&family=Mrs+Saint+Delafield&display=swap');

/* ---- Design tokens ---- */
:root{
  /* brand palette — sampled directly from THE BEAUTY THESAURUS logo */
  --rose-50:  #fdf5f6;
  --rose-100: #f9e6e8;
  --rose-200: #f0c9cd;
  --rose-300: #e2a6ac;
  --rose-400: #d18a92;
  --rose-500: #c46c74;   /* primary brand rose (ring / wordmark) */
  --rose-600: #a8555d;
  --rose-700: #874349;
  --rose-800: #633136;
  --rose-900: #402024;

  --gold-300: #c7ad83;
  --gold-400: #a68a5f;
  --gold-500: #8a6b45;   /* THESAURUS wordmark bronze */
  --gold-600: #6f5537;

  --peach-300: #f6d9c2;
  --peach-500: #e4a884;  /* illustration skin-tone accent, used sparingly */

  --cream:  #fdf8f3;
  --blush:  #f8e8e2;
  --paper:  #fffcfa;
  --white:  #ffffff;

  --ink:      #2c2129;
  --ink-soft: #5d4c53;
  --ink-faint:#8f7c82;
  --line:     #ecdcd6;

  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-script:  'Mrs Saint Delafield', cursive;
  --font-body:    'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --container: 1280px;
  --pad: clamp(1.25rem, 4.5vw, 3rem);

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 32px;
  --radius-pill: 999px;

  --shadow-soft: 0 10px 30px -12px rgba(64, 32, 36, 0.18);
  --shadow-lift: 0 20px 45px -15px rgba(64, 32, 36, 0.28);

  --ease: cubic-bezier(.22,.61,.36,1);
  --dur: .5s;

  --header-h: 84px;
}

/* ---- Reset ---- */
*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{ animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}
body{
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img{ max-width: 100%; display: block; }
a{ color: inherit; text-decoration: none; }
ul{ margin: 0; padding: 0; list-style: none; }
button{ font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea{ font: inherit; }
h1,h2,h3,h4,p,figure{ margin: 0; }

:focus-visible{
  outline: 2.5px solid var(--gold-500);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---- Typography ---- */
h1,h2,h3,h4{ font-family: var(--font-display); color: var(--ink); font-weight: 600; line-height: 1.08; letter-spacing: -0.01em; }
h1{ font-size: clamp(2.6rem, 2rem + 3vw, 4.6rem); }
h2{ font-size: clamp(2rem, 1.5rem + 2vw, 3.1rem); }
h3{ font-size: clamp(1.35rem, 1.15rem + .9vw, 1.85rem); }
h4{ font-size: clamp(1.1rem, 1rem + .4vw, 1.3rem); }
p{ font-size: 1.03rem; line-height: 1.75; color: var(--ink-soft); }
.container{ max-width: var(--container); margin-inline: auto; padding-inline: var(--pad); }

.eyebrow{
  display: inline-flex; align-items: center; gap: .55em;
  font-family: var(--font-body); font-weight: 700; font-size: .76rem;
  letter-spacing: .16em; text-transform: uppercase; color: var(--gold-500);
}
.eyebrow::before{ content:''; width: 22px; height: 1.5px; background: var(--gold-400); display:inline-block; }

.script{ font-family: var(--font-script); font-weight: 400; line-height: 1; color: var(--rose-500); }

/* ---- Buttons ---- */
.btn{
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  padding: .95em 1.9em; border-radius: var(--radius-pill);
  font-weight: 700; font-size: .95rem; letter-spacing: .01em;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), background-color .35s var(--ease), color .35s var(--ease);
  white-space: nowrap;
}
.btn-primary{
  background: linear-gradient(135deg, var(--rose-500), var(--rose-600));
  color: var(--white);
  box-shadow: var(--shadow-soft);
}
.btn-primary:hover{ transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.btn-ghost{
  background: transparent; color: var(--ink); border: 1.5px solid var(--rose-300);
}
.btn-ghost:hover{ background: var(--rose-500); border-color: var(--rose-500); color: var(--white); transform: translateY(-3px); }
.btn-sm{ padding: .7em 1.4em; font-size: .82rem; }

/* ---- Header / Nav ---- */
.site-header{
  position: sticky; top: 0; z-index: 200;
  background: rgba(253, 248, 243, 0.86);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid rgba(196,108,116,0.14);
  transition: box-shadow .35s var(--ease), background-color .35s var(--ease);
}
.site-header.is-scrolled{ box-shadow: 0 8px 30px -18px rgba(64,32,36,0.35); }
.header-inner{
  max-width: var(--container); margin-inline: auto; padding-inline: var(--pad);
  height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.brand{ display: flex; align-items: center; gap: .65rem; z-index: 2; }
.brand img{ height: 46px; width: 46px; border-radius: 50%; flex-shrink: 0; }
.brand-word{ font-family: var(--font-display); font-weight: 600; font-size: 1.28rem; color: var(--ink); line-height: 1; white-space: nowrap; }
.brand-word span{ display: block; font-family: var(--font-body); font-weight: 700; font-size: .58rem; letter-spacing: .22em; color: var(--gold-500); margin-top: 3px; }

.nav-desktop{ display: flex; align-items: center; gap: 2.1rem; }
.nav-desktop a{
  position: relative; font-weight: 600; font-size: .95rem; color: var(--ink-soft);
  padding: .4rem 0; transition: color .3s var(--ease);
}
.nav-desktop a::after{
  content:''; position: absolute; left:0; right:100%; bottom:-2px; height: 2px;
  background: var(--rose-500); transition: right .35s var(--ease);
}
.nav-desktop a:hover, .nav-desktop a[aria-current="page"]{ color: var(--rose-600); }
.nav-desktop a:hover::after, .nav-desktop a[aria-current="page"]::after{ right: 0; }

.header-actions{ display: flex; align-items: center; gap: .9rem; }

.nav-toggle{
  display: none; position: relative; z-index: 2;
  width: 44px; height: 44px; border-radius: 50%;
  align-items: center; justify-content: center;
  background: var(--rose-100);
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after{
  content:''; display:block; width: 19px; height: 2px; background: var(--rose-700);
  border-radius: 2px; transition: transform .3s var(--ease), opacity .3s var(--ease), top .3s var(--ease);
  position: relative;
}
.nav-toggle span::before{ position:absolute; top:-6px; left:0; }
.nav-toggle span::after{ position:absolute; top:6px; left:0; }
.nav-toggle[aria-expanded="true"] span{ background: transparent; }
.nav-toggle[aria-expanded="true"] span::before{ top:0; transform: rotate(45deg); background: var(--rose-700); }
.nav-toggle[aria-expanded="true"] span::after{ top:0; transform: rotate(-45deg); background: var(--rose-700); }

.nav-mobile{
  position: absolute; top: 100%; left: 0; right: 0;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-lift);
  display: flex; flex-direction: column; padding: .5rem var(--pad) 1.6rem;
  max-height: 0; overflow: hidden; opacity: 0;
  transition: max-height .4s var(--ease), opacity .3s var(--ease);
}
.nav-mobile.is-open{ max-height: 480px; opacity: 1; }
.nav-mobile a{
  padding: .9rem 0; font-weight: 700; font-size: 1.05rem; color: var(--ink);
  border-bottom: 1px solid var(--line);
}
.nav-mobile a:last-of-type{ border-bottom: 0; }
.nav-mobile .btn{ margin-top: 1rem; align-self: flex-start; }

@media (max-width: 860px){
  .nav-desktop{ display: none; }
  .nav-toggle{ display: inline-flex; }
  .header-actions .btn-primary{ display: none; }
}

/* ---- Footer ---- */
.site-footer{
  background: linear-gradient(180deg, var(--ink) 0%, #241a20 100%);
  color: #f1e3e6; margin-top: clamp(4rem, 8vw, 7rem); position: relative; overflow: hidden;
}
.site-footer::before{
  content:''; position:absolute; inset: -20% -10% auto -10%; height: 300px;
  background: radial-gradient(60% 100% at 50% 0%, rgba(196,108,116,.25), transparent 70%);
  pointer-events: none;
}
.footer-grid{
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.1fr; gap: 2.5rem;
  padding-block: clamp(3.5rem, 6vw, 5rem) 2.5rem;
}
.footer-brand{ display:flex; align-items:center; gap:.7rem; margin-bottom: 1.1rem; }
.footer-brand img{ height: 44px; width: 44px; border-radius: 50%; }
.footer-brand span{ font-family: var(--font-display); font-size: 1.2rem; font-weight: 600; color: var(--white); }
.footer-col h4{ color: var(--white); font-family: var(--font-body); font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 1.1rem; font-weight: 700; }
.footer-col p{ color: #d8c2c6; font-size: .92rem; line-height: 1.7; }
.footer-col ul li{ margin-bottom: .65rem; }
.footer-col a{ color: #e7d3d6; font-size: .92rem; transition: color .3s, padding-left .3s; }
.footer-col a:hover{ color: var(--rose-300); padding-left: 4px; }
.footer-social{ display:flex; gap:.7rem; margin-top: 1.2rem; }
.footer-social a{
  width: 38px; height: 38px; border-radius: 50%; display:flex; align-items:center; justify-content:center;
  background: rgba(255,255,255,.08); transition: background .3s, transform .3s;
}
.footer-social a:hover{ background: var(--rose-500); transform: translateY(-3px); }
.footer-social svg{ width: 16px; height: 16px; fill: #f1e3e6; }
.footer-bottom{
  border-top: 1px solid rgba(255,255,255,.1); padding-block: 1.5rem;
  display:flex; justify-content: space-between; align-items:center; gap: 1rem; flex-wrap: wrap;
  font-size: .82rem; color: #b89ba0; position: relative; z-index: 1;
}
.footer-bottom a{ color: #b89ba0; }
.footer-bottom a:hover{ color: var(--rose-300); }

@media (max-width: 860px){
  .footer-grid{ grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px){
  .footer-grid{ grid-template-columns: 1fr; }
}

/* ---- Shared: badges, cards, reveal, floaty decor ---- */
.tag{
  display:inline-block; padding: .35em 1em; border-radius: var(--radius-pill);
  font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  background: var(--rose-100); color: var(--rose-700);
}
.tag.gold{ background: var(--peach-300); color: var(--gold-600); }

.verdict{
  display: inline-flex; align-items: center; gap: .6rem;
  border: 1.5px dashed var(--gold-400); border-radius: var(--radius-pill);
  padding: .5rem 1.1rem .5rem .6rem; background: var(--paper);
}
.verdict .stars{ color: var(--gold-500); letter-spacing: 1px; font-size: .95rem; }
.verdict .label{ font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-faint); font-weight: 700; }

.reveal{ opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.is-visible{ opacity: 1; transform: translateY(0); }
.reveal-stagger > *{ transition-delay: calc(var(--i, 0) * 80ms); }

.floaty{ position: absolute; pointer-events: none; opacity: .55; z-index: 0; animation: floaty 9s ease-in-out infinite; }
.floaty.f2{ animation-duration: 12s; animation-delay: -3s; }
.floaty.f3{ animation-duration: 7.5s; animation-delay: -1.2s; }
@keyframes floaty{
  0%, 100%{ transform: translateY(0) rotate(0deg); }
  50%{ transform: translateY(-22px) rotate(6deg); }
}
@keyframes spin-slow{ to{ transform: rotate(360deg); } }

.skip-link{
  position: fixed; top: -60px; left: 1rem; z-index: 999;
  background: var(--rose-600); color: #fff; padding: .8rem 1.3rem; border-radius: var(--radius-sm);
  transition: top .3s var(--ease); font-weight: 700;
}
.skip-link:focus{ top: 1rem; }

.back-to-top{
  position: fixed; right: 1.5rem; bottom: 1.5rem; z-index: 150;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--rose-600); color: #fff; display:flex; align-items:center; justify-content:center;
  box-shadow: var(--shadow-lift); opacity: 0; transform: translateY(12px) scale(.85); pointer-events: none;
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.back-to-top.is-visible{ opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; }
.back-to-top:hover{ background: var(--rose-700); }

::selection{ background: var(--rose-300); color: var(--ink); }

/* ---- Shared: post card (used on home + blog listing) ---- */
.post-card{
  display:block; background: var(--paper); border-radius: var(--radius-md); overflow:hidden;
  box-shadow: var(--shadow-soft); transition: box-shadow .4s var(--ease), transform .4s var(--ease);
}
.post-card:hover{ box-shadow: var(--shadow-lift); }
.post-card-img{ aspect-ratio: 3/2; overflow:hidden; background: var(--blush); }
.post-card-img img{ width:100%; height:100%; object-fit:cover; transition: transform .6s var(--ease); }
.post-card:hover .post-card-img img{ transform: scale(1.06); }
.post-card-body{ padding: 1.4rem 1.4rem 1.6rem; }
.post-card-body h3{ font-size: 1.14rem; margin-top: .7rem; line-height:1.32; }
.post-card-body p{ font-size: .87rem; margin-top: .55rem; line-height:1.6; }
.post-card-meta{ display:flex; align-items:center; gap:.5rem; margin-top: 1rem; font-size: .76rem; color: var(--ink-faint); font-weight: 600; }
.post-card-meta .dot{ width:3px; height:3px; border-radius:50%; background: var(--ink-faint); }

.section{ padding-block: clamp(3.5rem, 7vw, 6.5rem); position: relative; }
.section-head{ max-width: 640px; margin-bottom: clamp(2.2rem, 4vw, 3.2rem); }
.section-head.center{ margin-inline: auto; text-align: center; }
.section-head h2{ margin-top: .6rem; }
.section-head p{ margin-top: 1rem; }
