/* Wellbeing Tips — shared styles for inner pages (about, privacy, terms, accessibility).
   The home page (index.html) keeps its CSS inline because it has many bespoke sections;
   this file holds everything the other pages need. */

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
img { max-width: 100%; display: block; }

:root {
  --cream:        #EDE6DA;
  --cream-warm:   #F2EBDC;
  --cream-soft:   #F6F0E3;
  --surface:      #F5EFE3;
  --hairline:     #D6CDBC;
  --hairline-soft:#E4DCCB;

  --ink:          #2A2520;
  --ink-soft:     #615A4F;
  --ink-faint:    #8F877C;
  --ink-whisper:  #B6AE9F;

  --clay:         #B07A4E;
  --clay-deep:    #8A5B36;
  --clay-soft:    #E8C9A8;

  --rose:         #C58F73;
  --sage:         #8FA288;
  --sage-soft:    #C5D1C0;

  --serif: 'Fraunces', 'Iowan Old Style', 'Palatino', Georgia, serif;
  --sans:  'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Helvetica Neue', Arial, sans-serif;

  --radius-sm: 14px;
  --radius:    22px;
  --radius-lg: 32px;

  --shadow-sm: 0 1px 0 rgba(42,37,32,0.04), 0 2px 6px rgba(42,37,32,0.04);
  --shadow:    0 1px 0 rgba(42,37,32,0.04), 0 12px 32px -8px rgba(42,37,32,0.10), 0 4px 12px -4px rgba(42,37,32,0.06);
  --shadow-lg: 0 1px 0 rgba(42,37,32,0.04), 0 30px 60px -20px rgba(42,37,32,0.18), 0 12px 24px -10px rgba(42,37,32,0.08);

  --ease: cubic-bezier(.2,.7,.2,1);
  --ease-soft: cubic-bezier(.4,0,.2,1);

  --gutter: clamp(20px, 5vw, 48px);
  --section: clamp(80px, 11vw, 140px);
  --maxw: 1180px;
  --readw: 680px;
}

body {
  font-family: var(--sans);
  font-weight: 400;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  opacity: 0;
  transition: opacity 0.7s var(--ease);
}
body.loaded { opacity: 1; }

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.17 0 0 0 0 0.15 0 0 0 0 0.13 0 0 0 0.06 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  opacity: 0.55;
  mix-blend-mode: multiply;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
  position: relative;
  z-index: 2;
}

/* Scroll progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0;
  background: linear-gradient(to right, var(--clay), var(--rose), var(--sage));
  z-index: 100;
  pointer-events: none;
  transition: width .12s linear, opacity .35s var(--ease);
  opacity: 0;
}
.scroll-progress.visible { opacity: 1; }

/* Nav */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  background: color-mix(in srgb, var(--cream) 76%, transparent);
  border-bottom: 1px solid transparent;
  transition: border-color .35s var(--ease), background .35s var(--ease);
}
.nav.scrolled { border-bottom-color: var(--hairline-soft); }
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
  font-family: var(--serif);
  font-weight: 450;
  font-size: 20px;
  letter-spacing: -0.018em;
  font-variation-settings: "opsz" 24, "SOFT" 40, "WONK" 0;
}
.brand-mark { display: inline-flex; align-items: center; gap: 5px; }
.brand-mark .d {
  width: 7px; height: 7px;
  border-radius: 50%;
  display: inline-block;
  transition: transform .6s var(--ease);
}
.brand-mark .d1 { background: var(--clay); }
.brand-mark .d2 { background: var(--rose); }
.brand-mark .d3 { background: var(--sage); }
.brand:hover .brand-mark .d1 { transform: translateY(-2px); transition-delay: 0ms; }
.brand:hover .brand-mark .d2 { transform: translateY(-2px); transition-delay: 80ms; }
.brand:hover .brand-mark .d3 { transform: translateY(-2px); transition-delay: 160ms; }
.brand-name { letter-spacing: -0.018em; }

.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a {
  text-decoration: none;
  color: var(--ink-soft);
  font-size: 14px;
  letter-spacing: 0.01em;
  transition: color .2s var(--ease);
}
.nav-links a:hover { color: var(--ink); }
.nav-links .pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  background: var(--ink);
  color: var(--cream);
  border-radius: 999px;
  font-weight: 500;
  transition: transform .25s var(--ease), background .25s var(--ease);
}
.nav-links .pill:hover { background: var(--clay-deep); color: var(--cream); transform: translateY(-1px); }
.nav-links .pill svg { width: 12px; height: 12px; }
@media (max-width: 720px) {
  .nav-links .text-link { display: none; }
}

/* Eyebrow */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 11.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 28px;
  font-weight: 500;
}
.eyebrow .line { display: inline-block; width: 28px; height: 1px; background: var(--hairline); }

/* Article layout */
.article {
  max-width: var(--readw);
  margin: 0 auto;
  padding: clamp(80px, 12vw, 140px) var(--gutter) clamp(64px, 9vw, 120px);
  position: relative;
  z-index: 2;
}

.article-title {
  font-family: var(--serif);
  font-weight: 340;
  font-size: clamp(40px, 6.4vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.028em;
  margin: 0 0 28px;
  font-variation-settings: "opsz" 96, "SOFT" 60;
}
.article-title em {
  font-style: italic;
  color: var(--clay-deep);
  font-variation-settings: "opsz" 96, "SOFT" 90, "WONK" 1;
}

.article-lede {
  font-family: var(--serif);
  font-weight: 340;
  font-size: clamp(20px, 2.2vw, 26px);
  line-height: 1.45;
  letter-spacing: -0.012em;
  color: var(--ink-soft);
  margin: 0 0 56px;
  font-variation-settings: "opsz" 72, "SOFT" 60;
}
.article-lede em { font-style: italic; color: var(--clay-deep); }

.article-body {
  font-size: 17px;
  line-height: 1.72;
  color: var(--ink);
}
.article-body > * + * { margin-top: 1.15em; }
.article-body p { margin: 0; }
.article-body h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(22px, 2.4vw, 28px);
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 2.4em 0 0.4em;
  font-variation-settings: "opsz" 48, "SOFT" 50;
}
.article-body h2:first-child { margin-top: 0; }
.article-body h2 em { font-style: italic; color: var(--clay-deep); }
.article-body h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 19px;
  line-height: 1.3;
  letter-spacing: -0.008em;
  margin: 1.6em 0 0.4em;
  color: var(--ink);
}
.article-body ul, .article-body ol {
  margin: 0;
  padding-left: 1.3em;
}
.article-body ul { list-style: none; padding-left: 0; }
.article-body ul li {
  position: relative;
  padding-left: 1.3em;
  margin: 0 0 0.5em;
}
.article-body ul li::before {
  content: "·";
  position: absolute;
  left: 0.4em;
  top: -0.05em;
  color: var(--clay);
  font-size: 1.5em;
  line-height: 1;
}
.article-body ol { padding-left: 1.4em; }
.article-body ol li { margin: 0 0 0.5em; padding-left: 0.4em; }

.article-body a {
  color: var(--clay-deep);
  text-decoration: none;
  border-bottom: 1px solid var(--clay-soft);
  padding-bottom: 1px;
  transition: color .2s var(--ease), border-color .2s var(--ease);
}
.article-body a:hover { color: var(--ink); border-color: var(--clay); }

.article-body blockquote {
  margin: 1.6em 0;
  padding-left: 1.5em;
  border-left: 2px solid var(--clay-soft);
  font-family: var(--serif);
  font-style: italic;
  font-size: 19px;
  color: var(--ink-soft);
  letter-spacing: -0.005em;
  font-variation-settings: "opsz" 48, "SOFT" 90, "WONK" 1;
}

.article-body hr {
  margin: 2.4em 0;
  border: 0;
  height: 1px;
  background: var(--hairline-soft);
}

.article-body strong { font-weight: 500; color: var(--ink); }
.article-body em { font-style: italic; }

.article-body small,
.article-body .meta {
  display: block;
  color: var(--ink-faint);
  font-size: 13.5px;
}

.article-foot {
  margin-top: clamp(56px, 8vw, 96px);
  padding-top: 32px;
  border-top: 1px solid var(--hairline-soft);
  font-family: var(--serif);
  font-style: italic;
  font-weight: 340;
  font-size: 16px;
  color: var(--ink-soft);
  font-variation-settings: "opsz" 24, "SOFT" 90, "WONK" 1;
}
.article-foot em { color: var(--clay-deep); }

/* Footer */
footer {
  border-top: 1px solid var(--hairline-soft);
  padding: 64px 0 48px;
  position: relative;
  z-index: 2;
}
.foot-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr));
  gap: 40px;
}
@media (max-width: 820px) { .foot-grid { grid-template-columns: 1fr 1fr; gap: 28px; } }
@media (max-width: 480px) { .foot-grid { grid-template-columns: 1fr; } }
.foot-tag {
  font-family: var(--serif);
  font-weight: 340;
  font-size: 22px;
  color: var(--ink);
  line-height: 1.35;
  margin: 18px 0 0;
  max-width: 28ch;
  letter-spacing: -0.012em;
}
.foot-tag em { font-style: italic; color: var(--clay-deep); }
.foot-col h4 {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 11.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin: 0 0 18px;
}
.foot-col ul { list-style: none; margin: 0; padding: 0; }
.foot-col li { margin: 0 0 10px; }
.foot-col a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 14.5px;
  transition: color .2s var(--ease);
}
.foot-col a:hover { color: var(--ink); }
.foot-ps {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--hairline-soft);
  font-family: var(--serif);
  font-style: italic;
  font-weight: 340;
  font-size: 16px;
  color: var(--ink-soft);
  text-align: center;
  letter-spacing: -0.005em;
  font-variation-settings: "opsz" 24, "SOFT" 90, "WONK" 1;
}
.foot-ps em { color: var(--clay-deep); font-style: italic; }
.foot-base {
  margin-top: 28px;
  color: var(--ink-faint);
  font-size: 12.5px;
  text-align: center;
}
.foot-base a { color: var(--ink-faint); text-decoration: none; transition: color .2s var(--ease); }
.foot-base a:hover { color: var(--ink); }

/* Reveal */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .9s var(--ease), transform .9s var(--ease);
}
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* Focus */
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--clay-deep);
  outline-offset: 3px;
  border-radius: 6px;
}
::selection { background: var(--clay-soft); color: var(--ink); }

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
