/* Fitsemble blog: long reading on the site's dark ground, in the app's colours. Built into public/blog/blog.css. */

:root {
  --read: #ece6df;
  --measure: 70ch;
  --wide: 1080px;
}

/* ———— Blog index ———— */
.blog-head { position: relative; display: flex; flex-direction: column; gap: 22px; padding: 14px var(--gutter) clamp(36px, 6vw, 72px); background: radial-gradient(48% 70% at 80% 30%, rgba(116, 80, 111, 0.3), transparent 70%); }
.blog-title { margin-top: clamp(40px, 8vw, 120px); font-size: clamp(46px, 9vw, 150px); }
.blog-dek { max-width: 52ch; margin: 0; color: var(--cream-dim); font-size: clamp(17px, 1.6vw, 20px); }

.post-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.post-card { border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); }
.post-card a { display: flex; flex-direction: column; gap: 10px; height: 100%; padding: 22px var(--gutter) 30px; text-decoration: none; }
.post-card-art { display: block; padding: 18px 10px 0; border-radius: 4px; background: radial-gradient(70% 90% at 50% 40%, rgba(116, 80, 111, 0.28), transparent 75%), var(--bg-raise); }
.post-card-art svg { display: block; width: 100%; height: 190px; }
.post-card-meta { margin-top: 8px; color: var(--gold); }
.post-card-title { font-size: clamp(21px, 2vw, 25px); font-weight: 650; line-height: 1.15; letter-spacing: -0.015em; }
.post-card-dek { color: var(--cream-dim); font-size: 15.5px; }
.post-card a:hover .post-card-title { color: var(--gold); }

.method-grid { display: grid; grid-template-columns: 1fr 2fr; gap: 24px 48px; padding: clamp(24px, 4vw, 48px) var(--gutter) clamp(48px, 7vw, 96px); }
.method-grid h2 { margin: 0; font-size: clamp(28px, 3.2vw, 44px); font-weight: 650; line-height: 1.05; letter-spacing: -0.025em; }
.method-list { display: grid; gap: 18px; margin: 0; padding: 0; list-style: none; }
.method-list li { display: grid; grid-template-columns: 170px 1fr; align-items: start; gap: 14px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.method-list p { margin: 0; color: var(--cream-dim); }
.method-list .ev { justify-self: start; }

/* ———— A post ———— */
.post-head { display: flex; flex-direction: column; gap: 18px; padding: 14px var(--gutter) 0; }
.post-head .meta-row a { text-decoration: none; }
.post-head .meta-row a:hover { color: var(--gold); }
.post-title { max-width: 20ch; margin: clamp(28px, 6vw, 80px) 0 0; font-size: clamp(36px, 5.6vw, 76px); font-weight: 650; line-height: 1; letter-spacing: -0.035em; }
.post-dek { max-width: 56ch; margin: 0; color: var(--cream-dim); font-size: clamp(18px, 1.7vw, 21px); line-height: 1.45; }
.post-by { margin: 0; color: var(--cream-dim); font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; }

.post-cover { margin-top: clamp(28px, 4vw, 48px); padding: clamp(20px, 3vw, 36px) var(--gutter) 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: radial-gradient(46% 80% at 50% 45%, rgba(116, 80, 111, 0.3), transparent 72%); }
.post-cover svg { display: block; width: 100%; max-width: 760px; height: clamp(220px, 34vw, 380px); margin: 0 auto; }

.post-body { max-width: var(--measure); margin: 0 auto; padding: clamp(32px, 5vw, 64px) var(--gutter) 8px; color: var(--read); font-size: 18px; line-height: 1.65; }
.post-body > * { margin-top: 0; }
.post-body p { margin: 0 0 1.05em; }
.post-body a { color: var(--cream); text-decoration-color: var(--gold); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.post-body a:hover { color: var(--gold); }
.post-body h2 { margin: 2.1em 0 0.6em; color: var(--cream); font-size: clamp(25px, 2.6vw, 32px); font-weight: 650; line-height: 1.12; letter-spacing: -0.02em; }
.post-body h3 { margin: 1.6em 0 0.5em; color: var(--cream); font-size: 20px; font-weight: 650; line-height: 1.25; letter-spacing: -0.01em; }
.post-body em { font-style: italic; }
.post-body b, .post-body strong { color: var(--cream); font-weight: 650; }
.lead { color: var(--cream); font-size: clamp(19px, 1.8vw, 22px); line-height: 1.5; }

.cite { margin-left: 1px; font-size: 0.66em; font-weight: 650; line-height: 0; }
.cite a { color: var(--gold) !important; text-decoration: none !important; padding: 0 1px; }
.cite a:hover { text-decoration: underline !important; }

/* Evidence labels and verdicts */
.ev, .verdict {
  display: inline-block;
  padding: 3px 8px 2px;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  vertical-align: 0.15em;
  white-space: nowrap;
}
.ev-tested, .verdict-holds { background: rgba(131, 165, 139, 0.2); color: #b5d4bc; }
.ev-mixed, .verdict-partly { background: rgba(234, 203, 122, 0.17); color: var(--gold); }
.ev-habit { background: rgba(233, 221, 232, 0.12); color: #d9c9d7; }
.verdict-myth { background: rgba(214, 120, 120, 0.17); color: #f0b0a8; }
h3 .ev { margin-left: 6px; }

/* Figures */
.fig { margin: 30px 0 34px; }
.fig svg { display: block; width: 100%; height: auto; }
.fig figcaption, .fig-note { margin-top: 12px; color: var(--cream-dim); font-size: 14.5px; line-height: 1.5; }
.fig-narrow svg { max-width: 460px; margin: 0 auto; }
.fig-wide { margin-left: calc(50% - min(50vw, var(--wide) / 2) + var(--gutter) * 0); margin-right: calc(50% - min(50vw, var(--wide) / 2)); }
.fig-wide svg { max-width: 900px; margin: 0 auto; }
.fig-wide figcaption { max-width: var(--measure); margin-left: auto; margin-right: auto; padding: 0 var(--gutter); }
.art-row { max-height: 420px; }
.fig .art-measure { max-height: 560px; }
.art .art-label { fill: var(--cream); font-family: var(--sans); font-size: 15px; font-weight: 650; letter-spacing: 0.01em; }
.art .art-note { fill: var(--cream-dim); font-family: var(--sans); font-size: 12.5px; }

.fig-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 26px 18px; margin: 26px 0 30px; padding: 0; list-style: none; }
.fig-grid.shapes, .fig-grid.glossary { margin-left: calc(50% - min(50vw, var(--wide) / 2)); margin-right: calc(50% - min(50vw, var(--wide) / 2)); padding: 0 var(--gutter); }
.fig-grid li { display: flex; flex-direction: column; gap: 6px; }
.fig-grid svg { display: block; width: 100%; height: 250px; margin-bottom: 8px; padding: 12px 0 0; border-radius: 4px; background: radial-gradient(70% 70% at 50% 45%, rgba(116, 80, 111, 0.22), transparent 75%), var(--bg-raise); }
.fig-grid b { color: var(--cream); font-size: 17px; font-weight: 650; }
.fig-grid span { color: var(--cream-dim); font-size: 14.5px; line-height: 1.45; }
.fig-grid.glossary { grid-template-columns: repeat(4, 1fr); }
.fig-grid.glossary svg { height: 240px; }
.fig-grid.trio { grid-template-columns: repeat(3, 1fr); }
.fig-grid.trio svg { height: 280px; }

/* Bar charts: one series, value at the tip */
.chart { padding: 20px 22px 18px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg-raise); }
.chart-title { margin: 0 0 16px !important; color: var(--cream) !important; font-size: 15.5px !important; font-weight: 600; }
.chart-foot { margin: 14px 0 0 !important; color: var(--cream-dim); font-size: 13.5px; line-height: 1.5; }
.bars { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.bars li { display: grid; grid-template-columns: minmax(110px, 150px) 1fr 3.4em; grid-template-areas: 'label track value' '. note .'; align-items: center; column-gap: 12px; }
.bar-label { grid-area: label; color: var(--cream); font-size: 15px; }
.bar-track { grid-area: track; display: block; height: 16px; border-radius: 0 4px 4px 0; background: rgba(250, 248, 244, 0.06); }
.bar { display: block; height: 100%; border-radius: 0 4px 4px 0; background: var(--gold); }
.bar-value { grid-area: value; color: var(--cream); font-size: 15px; font-weight: 650; font-variant-numeric: tabular-nums; text-align: right; }
.bar-note { grid-area: note; color: var(--cream-dim); font-size: 13px; }

/* Tables */
.table-wrap { margin: 26px 0 32px; overflow-x: auto; border-top: 1px solid var(--line); }
.table-wrap table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 15.5px; line-height: 1.5; }
.table-wrap th, .table-wrap td { padding: 13px 14px 13px 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.table-wrap thead th { color: var(--cream-dim); font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; }
.table-wrap tbody th { color: var(--cream); font-weight: 650; }
.table-wrap td { color: var(--read); }
.beliefs tbody th { font-weight: 550; font-style: italic; }
.beliefs td:last-child { white-space: nowrap; }

/* Shape cards */
.shape-card { display: grid; grid-template-columns: minmax(220px, 0.9fr) 1.1fr; gap: 26px; margin: 26px 0; padding: 24px 0 8px; border-top: 1px solid var(--line); }
.shape-pics { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-self: start; }
.shape-pics svg { display: block; width: 100%; height: 240px; padding-top: 10px; border-radius: 4px; background: radial-gradient(70% 70% at 50% 45%, rgba(116, 80, 111, 0.22), transparent 75%), var(--bg-raise); }
.shape-text h3 { margin: 0 0 4px !important; font-size: 24px !important; }
.shape-sub { color: var(--cream-dim); font-size: 15.5px; }
.shape-text dl { margin: 14px 0 0; }
.shape-text dt { margin-top: 12px; color: var(--gold); font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; }
.shape-text dd { margin: 3px 0 0; font-size: 16px; line-height: 1.55; }
.shape-note { margin-top: 14px !important; padding-top: 12px; border-top: 1px dashed var(--line); color: var(--cream-dim); font-size: 15px; }

/* Lists */
.steps-list, .method { margin: 0 0 1.2em; padding-left: 1.1em; }
.steps-list li, .method li { margin-bottom: 0.55em; padding-left: 0.3em; }
.steps-list li::marker { color: var(--gold); }
.method li::marker { color: var(--gold); font-family: var(--mono); font-size: 0.85em; }

.takeaways { margin: 40px 0 28px; padding: 18px 22px 8px; border-left: 2px solid var(--gold); background: var(--bg-raise); }
.takeaways .mono { margin: 0 0 8px !important; color: var(--gold); }
.takeaways ul { margin: 0; padding-left: 1.05em; }
.takeaways li { margin-bottom: 0.6em; }

/* "In Fitsemble": a card in the app's light UI */
.app-note { margin: 34px 0; padding: 22px 24px 8px; border-radius: 20px; background: var(--cream); color: var(--ink); }
.app-note .app-note-top { display: flex; align-items: center; gap: 10px; margin: 0 0 10px !important; color: var(--muted); font-family: var(--mono); font-size: 10.5px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.app-note-mark { box-sizing: content-box; width: 9px; height: 13px; padding: 5px 6.5px; border-radius: 6px; background: var(--bg); fill: var(--gold); }
.app-note h3 { margin: 0 0 8px !important; color: var(--ink) !important; font-size: 21px !important; letter-spacing: -0.015em; }
.app-note p { color: var(--ink); font-size: 16.5px; }
.post-body .app-note b, .post-body .app-note strong, .post-body .app-note a { color: var(--ink); }
.app-card-pair + .fig-note { margin: 12px 0 0; }

.app-card-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 26px 0 0; }
.app-card { display: flex; flex-direction: column; gap: 8px; padding: 18px 18px 16px; border-radius: 20px; background: var(--cream); color: var(--ink); font-size: 14px; line-height: 1.4; }
.app-card p { margin: 0 !important; }
.ac-kicker { color: var(--muted); font-size: 10.5px; font-weight: 650; letter-spacing: 0.08em; text-transform: uppercase; }
.ac-verdict { color: var(--sage-dark); font-size: 28px; font-weight: 750; line-height: 1.05; letter-spacing: -0.03em; }
.ac-sub { color: var(--muted); font-size: 13.5px; }
.ac-area { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--paper-line); border-radius: 14px; background: #fff; }
.ac-area span { color: var(--muted); }
.app-card .ac-area b { min-width: 2ch; color: var(--ink); font-size: 17px; text-align: center; }
.ac-area em { color: var(--sage-dark); font-size: 12.5px; font-style: normal; font-weight: 600; }
.ac-area em.loose { color: var(--gold-dark); }

.next-up { margin-top: 34px !important; padding-top: 16px; border-top: 1px solid var(--line); color: var(--cream-dim); }

/* Sources */
.refs { max-width: var(--measure); margin: 0 auto; padding: 8px var(--gutter) clamp(36px, 5vw, 56px); }
.refs h2 { margin: 0 0 12px; padding-top: 22px; border-top: 1px solid var(--line); color: var(--cream-dim); font-family: var(--mono); font-size: 11px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; }
.refs ol { margin: 0; padding-left: 1.6em; color: var(--cream-dim); font-size: 14px; line-height: 1.55; }
.refs li { margin-bottom: 10px; padding-left: 4px; }
.refs li::marker { color: var(--gold); font-family: var(--mono); font-size: 12px; }
.refs li:target { color: var(--cream); }
.refs a { color: var(--cream); text-decoration-color: var(--gold); text-underline-offset: 3px; overflow-wrap: anywhere; }
.refs a:hover { color: var(--gold); }
.ref-note { font-style: italic; }

/* Previous and next */
.post-nav { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); }
.post-nav a { display: flex; flex-direction: column; gap: 8px; padding: 22px var(--gutter) 28px; font-size: 18px; font-weight: 650; line-height: 1.25; text-decoration: none; }
.post-nav a .mono { color: var(--gold); }
.post-nav a:hover { color: var(--gold); }
.post-next { border-left: 1px solid var(--line); text-align: right; align-items: flex-end; }

.nav a[aria-current='page'] { color: var(--gold); }

@media (max-width: 900px) {
  .method-grid { grid-template-columns: 1fr; }
  .shape-card { grid-template-columns: 1fr; }
  .shape-pics svg { height: 230px; }
}

@media (max-width: 600px) {
  .post-body { font-size: 17px; }
  .fig-grid { grid-template-columns: 1fr 1fr; gap: 22px 12px; }
  .fig-grid svg { height: 210px; }
  .fig-grid.glossary svg { height: 190px; }
  .fig-grid.trio { grid-template-columns: repeat(3, 1fr); gap: 16px 8px; }
  .fig-grid.trio svg { height: 190px; }
  .fig-grid.trio span { font-size: 13px; }
  .method-list li { grid-template-columns: 1fr; gap: 8px; }
  .app-card-pair { grid-template-columns: 1fr; }
  .post-nav { grid-template-columns: 1fr; }
  .post-next { border-left: 0; border-top: 1px solid var(--line); }
  .bars li { grid-template-columns: minmax(92px, 118px) 1fr 3em; column-gap: 10px; }
  .chart { padding: 16px 14px 14px; }
  .post-card-art svg { height: 160px; }
}

/* Bar lengths for bars() in art.mjs */
.bw-0{width:0%}.bw-1{width:1%}.bw-2{width:2%}.bw-3{width:3%}.bw-4{width:4%}.bw-5{width:5%}.bw-6{width:6%}.bw-7{width:7%}.bw-8{width:8%}.bw-9{width:9%}.bw-10{width:10%}.bw-11{width:11%}.bw-12{width:12%}.bw-13{width:13%}.bw-14{width:14%}.bw-15{width:15%}.bw-16{width:16%}.bw-17{width:17%}.bw-18{width:18%}.bw-19{width:19%}.bw-20{width:20%}.bw-21{width:21%}.bw-22{width:22%}.bw-23{width:23%}.bw-24{width:24%}.bw-25{width:25%}.bw-26{width:26%}.bw-27{width:27%}.bw-28{width:28%}.bw-29{width:29%}.bw-30{width:30%}.bw-31{width:31%}.bw-32{width:32%}.bw-33{width:33%}.bw-34{width:34%}.bw-35{width:35%}.bw-36{width:36%}.bw-37{width:37%}.bw-38{width:38%}.bw-39{width:39%}.bw-40{width:40%}.bw-41{width:41%}.bw-42{width:42%}.bw-43{width:43%}.bw-44{width:44%}.bw-45{width:45%}.bw-46{width:46%}.bw-47{width:47%}.bw-48{width:48%}.bw-49{width:49%}.bw-50{width:50%}.bw-51{width:51%}.bw-52{width:52%}.bw-53{width:53%}.bw-54{width:54%}.bw-55{width:55%}.bw-56{width:56%}.bw-57{width:57%}.bw-58{width:58%}.bw-59{width:59%}.bw-60{width:60%}.bw-61{width:61%}.bw-62{width:62%}.bw-63{width:63%}.bw-64{width:64%}.bw-65{width:65%}.bw-66{width:66%}.bw-67{width:67%}.bw-68{width:68%}.bw-69{width:69%}.bw-70{width:70%}.bw-71{width:71%}.bw-72{width:72%}.bw-73{width:73%}.bw-74{width:74%}.bw-75{width:75%}.bw-76{width:76%}.bw-77{width:77%}.bw-78{width:78%}.bw-79{width:79%}.bw-80{width:80%}.bw-81{width:81%}.bw-82{width:82%}.bw-83{width:83%}.bw-84{width:84%}.bw-85{width:85%}.bw-86{width:86%}.bw-87{width:87%}.bw-88{width:88%}.bw-89{width:89%}.bw-90{width:90%}.bw-91{width:91%}.bw-92{width:92%}.bw-93{width:93%}.bw-94{width:94%}.bw-95{width:95%}.bw-96{width:96%}.bw-97{width:97%}.bw-98{width:98%}.bw-99{width:99%}.bw-100{width:100%}
