/* ukwomensfitness.co.uk — global.css
   Editorial magazine design system. See SKILL.md. */

@import url('https://fonts.googleapis.com/css2?family=Libre+Bodoni:ital,wght@0,400;0,500;0,600;0,700;1,400&family=Public+Sans:wght@300;400;500;600;700&display=swap');

:root {
  --paper:    oklch(0.985 0.006 75);
  --paper-2:  oklch(0.97 0.008 70);
  --ink:      oklch(0.21 0.015 40);
  --accent:   oklch(0.52 0.12 23);
  --accent-2: oklch(0.63 0.10 33);
  --muted:    oklch(0.47 0.015 45);
  --line:     oklch(0.89 0.008 60);
  --tint:     oklch(0.955 0.02 30);

  --serif: 'Libre Bodoni', Georgia, serif;
  --sans: 'Public Sans', system-ui, -apple-system, sans-serif;

  --maxw: 1180px;
  --read: 680px;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--accent); color: var(--paper); }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 clamp(1.25rem, 4vw, 3rem); }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Kicker ---------- */
.kicker {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
}

/* ---------- Masthead ---------- */
.masthead {
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 30;
  background: color-mix(in oklch, var(--paper) 88%, transparent);
  backdrop-filter: saturate(1.1) blur(8px);
}
.masthead .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; padding-top: 1.1rem; padding-bottom: 1.1rem;
}
.wordmark {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.4rem;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.wordmark:hover { text-decoration: none; }
.wordmark .dot { color: var(--accent); }
.nav { display: flex; gap: 1.6rem; align-items: center; }
.nav a {
  font-size: 0.86rem; font-weight: 500; color: var(--muted);
  letter-spacing: 0.01em; transition: color .2s ease;
}
.nav a:hover { color: var(--ink); text-decoration: none; }
.nav-toggle { display: none; }

/* ---------- Hero ---------- */
.hero { padding: clamp(3.5rem, 8vw, 7rem) 0 clamp(2.5rem, 5vw, 4.5rem); }
.hero-grid { display: grid; grid-template-columns: 1.55fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: end; }
.hero h1 {
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(2.6rem, 6.5vw, 5rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin: 1rem 0 1.4rem;
  text-wrap: balance;
}
.hero h1 em { font-style: italic; color: var(--accent); }
.hero .standfirst {
  font-size: 1.18rem; color: var(--muted); max-width: 34ch; line-height: 1.6;
}
.hero .cta {
  display: inline-flex; align-items: center; gap: 0.5rem;
  margin-top: 1.8rem; font-weight: 600; color: var(--ink);
  border-bottom: 2px solid var(--accent); padding-bottom: 3px;
  transition: gap .2s ease;
}
.hero .cta:hover { text-decoration: none; gap: 0.85rem; }
.hero .cta svg { width: 18px; height: 18px; }

/* hero side motif */
.hero-aside {
  border-left: 1px solid var(--line); padding-left: clamp(1.5rem, 3vw, 2.5rem);
}
.hero-aside .label { font-size: 0.72rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.hero-aside .featured {
  font-family: var(--serif); font-size: 1.35rem; line-height: 1.25;
  margin-top: 0.6rem; color: var(--ink); display: block;
}
.hero-aside .featured:hover { color: var(--accent); text-decoration: none; }
.hero-aside .meta { font-size: 0.82rem; color: var(--muted); margin-top: 0.7rem; }

/* ---------- Section heads ---------- */
.section { padding: clamp(3rem, 6vw, 5rem) 0; border-top: 1px solid var(--line); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 2.5rem; }
.section-head h2 {
  font-family: var(--serif); font-weight: 600;
  font-size: clamp(1.6rem, 3.5vw, 2.3rem); letter-spacing: -0.01em;
}
.section-head .more { font-size: 0.85rem; font-weight: 600; }

/* ---------- Pillar grid ---------- */
.pillars { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border: 1px solid var(--line); }
.pillar {
  padding: 1.8rem 1.5rem 2rem; border-right: 1px solid var(--line);
  display: flex; flex-direction: column; min-height: 220px;
  transition: background .25s ease;
}
.pillar:last-child { border-right: none; }
.pillar:hover { background: var(--tint); }
.pillar:hover .p-title { color: var(--accent); }
.pillar .p-num {
  font-family: var(--serif); font-size: 0.95rem; color: var(--accent); font-weight: 600;
}
.pillar .p-title {
  font-family: var(--serif); font-size: 1.4rem; line-height: 1.15; margin: auto 0 0.6rem;
  color: var(--ink); transition: color .2s ease;
}
.pillar .p-desc { font-size: 0.92rem; color: var(--muted); line-height: 1.55; }

/* ---------- Article list ---------- */
.articles { max-width: 860px; }
.article-row {
  display: grid; grid-template-columns: 150px 1fr; gap: 1.5rem;
  padding: 1.5rem 0; border-bottom: 1px solid var(--line); align-items: baseline;
}
.article-row:first-child { border-top: 1px solid var(--line); }
.article-row .a-meta { font-size: 0.78rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }
.article-row .a-meta .cat { color: var(--accent); font-weight: 600; display: block; margin-bottom: 0.2rem; }
.article-row h3 { font-family: var(--serif); font-weight: 500; font-size: 1.3rem; line-height: 1.25; }
.article-row h3 a { color: var(--ink); }
.article-row h3 a:hover { color: var(--accent); text-decoration: none; }
.article-row p { font-size: 0.92rem; color: var(--muted); margin-top: 0.35rem; }

/* ---------- Author strip ---------- */
.author { background: var(--paper-2); border-top: 1px solid var(--line); }
.author .wrap { display: grid; grid-template-columns: 1fr 1.4fr; gap: clamp(2rem,5vw,4rem); padding: clamp(3rem,6vw,4.5rem) 0; align-items: center; }
.author h2 { font-family: var(--serif); font-size: clamp(1.5rem,3vw,2rem); line-height: 1.15; }
.author p { color: var(--muted); margin-top: 1rem; max-width: 52ch; }
.author .cta { display: inline-block; margin-top: 1.4rem; font-weight: 600; color: var(--ink); border-bottom: 2px solid var(--accent); padding-bottom: 2px; }
.author .cta:hover { text-decoration: none; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 2.5rem 0; }
.site-footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; }
.site-footer .colophon { font-size: 0.82rem; color: var(--muted); }
.made-by {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-size: 0.82rem; color: var(--muted);
  border: 1px solid var(--line); border-radius: 999px; padding: 0.45rem 0.9rem;
  transition: border-color .2s ease, color .2s ease;
}
.made-by:hover { border-color: var(--accent); color: var(--ink); text-decoration: none; }
.made-by strong { color: var(--ink); font-weight: 600; }
.made-by .mark { width: 16px; height: 16px; color: var(--accent); }

/* ---------- Pillar hub body ---------- */
.pillar-body { max-width: var(--read); margin: 0 auto; }
.pillar-body h2 { font-family: var(--serif); font-weight: 600; font-size: 1.6rem; margin: 2.2rem 0 1rem; }
.pillar-body p { margin-bottom: 1.3rem; }
.pillar-body ul { margin: 1rem 0 1.4rem 1.4rem; }
.pillar-body li { margin-bottom: 0.5rem; }
.pillar-body a { border-bottom: 1px solid color-mix(in oklch, var(--accent) 35%, transparent); }
.pillar-body a:hover { text-decoration: none; border-bottom-color: var(--accent); }

/* ---------- Authority components (tables, charts, stats, sources) ---------- */
.key {
  font-size: 1.14rem; line-height: 1.5; font-weight: 600; color: var(--ink);
  border-left: 3px solid var(--accent); padding: 0.2rem 0 0.2rem 1.2rem; margin: 2rem 0;
  text-wrap: pretty;
}

.stat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); margin: 2.2rem 0; }
.stat { background: var(--paper); padding: 1.25rem 1.1rem; }
.stat .n { font-family: var(--serif); font-size: 1.75rem; font-weight: 700; color: var(--accent); line-height: 1; }
.stat .l { font-size: 0.82rem; color: var(--muted); margin-top: 0.5rem; line-height: 1.4; }

.fig-title { font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); font-weight: 600; margin: 2.2rem 0 0.7rem; }
.fig-title + .table-wrap, .fig-title + .chart { margin-top: 0; }
.table-wrap { overflow-x: auto; margin: 2rem 0; border: 1px solid var(--ink); border-radius: 4px; }
.data-table { width: 100%; border-collapse: collapse; font-size: 0.94rem; }
.data-table caption { text-align: left; font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); font-weight: 600; margin: 0 0 0.7rem; padding: 0; caption-side: top; }
.data-table th, .data-table td { text-align: left; padding: 0.72rem 1rem; border: 1px solid var(--line); vertical-align: top; }
.data-table thead th { font-size: 0.76rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink); background: var(--tint); border-bottom: 1.5px solid var(--ink); white-space: nowrap; }
.data-table tbody td:first-child { font-weight: 600; color: var(--ink); }
.data-table .num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.data-table tbody tr:nth-child(even) { background: color-mix(in oklch, var(--paper-2) 55%, transparent); }
.data-table tbody tr:hover { background: var(--tint); }

.chart { margin: 2.2rem 0; }
.chart .c-title { font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); font-weight: 600; margin-bottom: 1.1rem; }
.chart .c-note { font-size: 0.8rem; color: var(--muted); margin-top: 0.6rem; }
.bar { display: grid; grid-template-columns: 160px 1fr 64px; align-items: center; gap: 0.8rem; margin-bottom: 0.65rem; font-size: 0.9rem; }
.bar .b-label { color: var(--ink); }
.bar .b-track { background: var(--paper-2); border-radius: 3px; height: 20px; }
.bar .b-fill { height: 100%; background: var(--accent); border-radius: 3px; min-width: 2px; }
.bar .b-fill.alt { background: color-mix(in oklch, var(--accent) 40%, var(--paper-2)); }
.bar .b-val { font-variant-numeric: tabular-nums; color: var(--muted); text-align: right; }

.svg-chart { width: 100%; height: auto; display: block; margin: 0.5rem 0; }
.legend { display: flex; gap: 1.4rem; font-size: 0.82rem; color: var(--muted); margin-top: 0.6rem; }
.legend span { display: inline-flex; align-items: center; gap: 0.4rem; }
.legend i { width: 14px; height: 3px; border-radius: 2px; display: inline-block; }

.sources { margin: 2.4rem 0 0; padding-top: 1rem; border-top: 1px solid var(--line); font-size: 0.85rem; color: var(--muted); }
.sources strong { display: block; font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 0.5rem; }
.sources a { color: var(--muted); border-bottom: 1px solid var(--line); }
.sources a:hover { color: var(--ink); text-decoration: none; }
.sources ul { margin: 0; list-style: none; }
.sources li { margin-bottom: 0.35rem; }

details.faq-q { border-bottom: 1px solid var(--line); padding: 0.9rem 0; }
details.faq-q summary { font-family: var(--serif); font-size: 1.12rem; cursor: pointer; list-style: none; color: var(--ink); }
details.faq-q summary::-webkit-details-marker { display: none; }
details.faq-q summary::after { content: '+'; float: right; color: var(--accent); font-family: var(--sans); }
details.faq-q[open] summary::after { content: '–'; }
details.faq-q p { font-size: 0.95rem; color: var(--muted); margin: 0.7rem 0 0; }

@media (max-width: 560px) {
  .stat-row { grid-template-columns: 1fr; }
  .bar { grid-template-columns: 110px 1fr 52px; gap: 0.5rem; font-size: 0.82rem; }
}

/* ---------- Article body (blog posts) ---------- */
.post { max-width: var(--read); margin: 0 auto; padding: clamp(2.5rem,5vw,4rem) 0; }
.breadcrumb { font-size: 0.78rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); margin-bottom: 1.5rem; }
.breadcrumb a { color: var(--muted); }
.post h1 { font-family: var(--serif); font-weight: 700; font-size: clamp(2rem,4.5vw,3rem); line-height: 1.1; letter-spacing: -0.015em; margin-bottom: 1rem; }
.post .post-meta { font-size: 0.85rem; color: var(--muted); margin-bottom: 2rem; }
.post .quick-answer { background: var(--tint); border-left: 3px solid var(--accent); padding: 1.2rem 1.4rem; margin: 2rem 0; border-radius: 0 6px 6px 0; }
.post .quick-answer strong { display: block; font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); margin-bottom: 0.4rem; }
.post h2 { font-family: var(--serif); font-weight: 600; font-size: 1.6rem; margin: 2.5rem 0 1rem; }
.post h3 { font-family: var(--serif); font-weight: 500; font-size: 1.25rem; margin: 1.8rem 0 0.6rem; }
.post p { margin-bottom: 1.3rem; }
.post ul, .post ol { margin: 1rem 0 1.4rem 1.4rem; }
.post li { margin-bottom: 0.5rem; }
.post strong { font-weight: 600; }
.post a { border-bottom: 1px solid color-mix(in oklch, var(--accent) 35%, transparent); }
.post a:hover { text-decoration: none; border-bottom-color: var(--accent); }

.faq-section { margin-top: 3rem; padding-top: 2rem; border-top: 2px solid var(--ink); }
.faq-section > h2 { font-family: var(--serif); font-weight: 600; font-size: 1.6rem; margin-bottom: 1.5rem; }
.faq-item { padding: 1.3rem 0; border-bottom: 1px solid var(--line); }
.faq-item h3 { font-family: var(--serif); font-weight: 500; font-size: 1.2rem; margin-bottom: 0.5rem; color: var(--ink); }
.faq-item p { font-size: 0.96rem; color: var(--muted); margin: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .hero-aside { border-left: none; border-top: 1px solid var(--line); padding-left: 0; padding-top: 1.5rem; }
  .pillars { grid-template-columns: 1fr 1fr; }
  .pillar:nth-child(2) { border-right: none; }
  .pillar:nth-child(1), .pillar:nth-child(2) { border-bottom: 1px solid var(--line); }
  .author .wrap { grid-template-columns: 1fr; }
  .nav { display: none; }
}
@media (max-width: 560px) {
  .pillars { grid-template-columns: 1fr; }
  .pillar { border-right: none; border-bottom: 1px solid var(--line); }
  .pillar:last-child { border-bottom: none; }
  .article-row { grid-template-columns: 1fr; gap: 0.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* fade-up on scroll */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
