/* =================================================================
   Goedkoopste Whey - hoofd stylesheet
   Light is de standaard, dark via <html data-theme="dark">
   ================================================================= */

:root {
    /* deze zes worden door de beheeromgeving overschreven */
    --ink-900:   #0b1a1f;
    --ink-700:   #10504f;
    --brand-500: #0ea885;
    --brand-400: #2dd4a7;
    --pill:      #ccff33;
    --pill-text: #0b1a1f;

    --bg:          #ffffff;
    --bg-soft:     #f4f7f6;
    --surface:     #ffffff;
    --surface-2:   #fbfcfc;
    --border:      #e3eae8;
    --border-soft: #eef3f1;

    --text:       #0f1b1f;
    --text-soft:  #4e6169;
    --text-muted: #7b8d93;

    --accent:      var(--brand-500);
    --accent-soft: color-mix(in srgb, var(--brand-500) 12%, transparent);
    --link:        #1257c4;

    --topbar-bg:   #ffffff;
    --topbar-text: #0f1b1f;

    --gold:   #d9a441;
    --silver: #9aa7ad;
    --bronze: #bd7a4a;

    --shadow-sm: 0 1px 2px rgba(11, 26, 31, .06), 0 2px 8px rgba(11, 26, 31, .05);
    --shadow-md: 0 4px 12px rgba(11, 26, 31, .07), 0 14px 34px rgba(11, 26, 31, .07);
    --shadow-lg: 0 20px 56px rgba(11, 26, 31, .16);

    --radius:    16px;
    --radius-lg: 24px;
    --wrap:      1200px;
}

html[data-theme="dark"] {
    --bg:          #0b1114;
    --bg-soft:     #101a1d;
    --surface:     #141f23;
    --surface-2:   #18262a;
    --border:      #26363b;
    --border-soft: #1d2b2f;

    --text:       #e6f2ef;
    --text-soft:  #a3b8b8;
    --text-muted: #7f9496;

    --accent:      var(--brand-400);
    --accent-soft: color-mix(in srgb, var(--brand-400) 16%, transparent);
    --link:        #7fc7ff;

    --topbar-bg:   #0c1518;
    --topbar-text: #e6f2ef;

    --gold:   #e8bd6a;
    --silver: #b6c2c7;
    --bronze: #d0906033;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .45);
    --shadow-md: 0 6px 22px rgba(0, 0, 0, .5);
    --shadow-lg: 0 22px 64px rgba(0, 0, 0, .62);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 88px; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    transition: background .25s ease, color .25s ease;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 { line-height: 1.12; margin: 0 0 .5em; font-weight: 800; letter-spacing: -.025em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.7rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); }
h3 { font-size: 1.2rem; }
p  { margin: 0 0 1em; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }

/* Let op: alles wat samen met .wrap gebruikt wordt zet alleen padding-top en
   padding-bottom. De verkorte notatie zou de zijmarge van .wrap op nul zetten
   en dan plakt de tekst tegen de schermrand. */
.section { padding-top: 82px; padding-bottom: 82px; }
.section-soft { background: var(--bg-soft); }
.section-head { max-width: 680px; margin-bottom: 40px; }
.section-head .kicker,
.kicker {
    display: inline-block; font-size: .74rem; font-weight: 800; letter-spacing: .16em;
    text-transform: uppercase; color: var(--accent); margin-bottom: 10px;
}
.section-head p { color: var(--text-soft); font-size: 1.05rem; margin-bottom: 0; }

.empty-note {
    padding: 30px; border: 1px dashed var(--border); border-radius: var(--radius);
    color: var(--text-muted); text-align: center; background: var(--surface);
}
.empty-note a { color: var(--accent); font-weight: 700; }

/* ---------------------------------------------------------------
   Knoppen
   --------------------------------------------------------------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 22px; border-radius: 999px; border: 1px solid transparent;
    font-size: .95rem; font-weight: 700; cursor: pointer; white-space: nowrap;
    transition: transform .15s ease, background .2s ease, box-shadow .2s ease, color .2s ease, border-color .2s ease;
    font-family: inherit;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--pill); color: var(--pill-text); box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: color-mix(in srgb, var(--pill) 86%, #000); }

.btn-dark { background: var(--ink-900); color: #fff; }
html[data-theme="dark"] .btn-dark { background: color-mix(in srgb, var(--ink-900) 60%, #fff 14%); }
.btn-dark:hover { background: var(--ink-700); }

.btn-outline { background: transparent; border-color: var(--border); color: var(--text); }
.btn-outline:hover { border-color: var(--text-muted); background: var(--bg-soft); }

.btn-ghost { background: transparent; color: var(--text-soft); border-color: var(--border); }
.btn-ghost:hover { color: var(--text); }
.topbar .btn-ghost {
    color: color-mix(in srgb, var(--topbar-text) 72%, transparent);
    border-color: color-mix(in srgb, var(--topbar-text) 22%, transparent);
}
.topbar .btn-ghost:hover { color: var(--topbar-text); }

.btn-block { width: 100%; }
.btn-lg { padding: 15px 30px; font-size: 1.03rem; }
.btn-sm { padding: 8px 14px; font-size: .85rem; }

/* ---------------------------------------------------------------
   Topbar
   --------------------------------------------------------------- */
.topbar {
    position: sticky; top: 0; z-index: 60;
    background: var(--topbar-bg);
    color: var(--topbar-text);
    border-bottom: 1px solid color-mix(in srgb, var(--topbar-text) 13%, transparent);
}
.topbar-inner { display: flex; align-items: center; gap: 20px; height: 70px; }

.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; letter-spacing: -.02em; }
.brand-mark {
    width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center;
    background: var(--ink-900); color: var(--pill); flex: none;
}
html[data-theme="dark"] .brand-mark { background: var(--pill); color: var(--ink-900); }
.brand-name { font-size: 1.02rem; }
.topbar .brand { color: var(--topbar-text); }

.topnav { display: flex; gap: 24px; margin-left: auto; }
.topnav a { color: color-mix(in srgb, var(--topbar-text) 70%, transparent); font-size: .93rem; font-weight: 600; }
.topnav a:hover { color: var(--topbar-text); }

.topbar-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.topnav + .topbar-actions { margin-left: 0; }

.icon-btn {
    width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
    background: color-mix(in srgb, var(--topbar-text) 8%, transparent);
    border: 1px solid color-mix(in srgb, var(--topbar-text) 17%, transparent);
    color: var(--topbar-text);
    cursor: pointer; transition: background .2s ease, transform .2s ease;
}
.icon-btn:hover { background: color-mix(in srgb, var(--topbar-text) 15%, transparent); transform: rotate(12deg); }
.icon-moon { display: none; }
html[data-theme="dark"] .icon-sun { display: none; }
html[data-theme="dark"] .icon-moon { display: block; }

.btn-edit { background: var(--ink-900); color: var(--pill); padding: 10px 16px; }
html[data-theme="dark"] .btn-edit { background: var(--pill); color: var(--ink-900); }
body.editing .btn-edit { background: var(--brand-500); color: #fff; }

/* ---------------------------------------------------------------
   Hero
   --------------------------------------------------------------- */
.hero {
    position: relative; overflow: hidden;
    background: linear-gradient(155deg, var(--ink-900) 0%, var(--ink-700) 62%, var(--ink-900) 100%);
    color: #fff;
    padding-top: 86px; padding-bottom: 78px;
}
/* zachte lichtvlek, geeft de vlakke gradient wat diepte */
.hero-glow {
    position: absolute; inset: -30% -10% auto -10%; height: 130%;
    background:
        radial-gradient(circle at 18% 22%, color-mix(in srgb, var(--pill) 26%, transparent), transparent 42%),
        radial-gradient(circle at 82% 38%, color-mix(in srgb, var(--brand-400) 34%, transparent), transparent 46%);
    pointer-events: none;
}
.hero-inner { position: relative; z-index: 2; max-width: 820px; }
.hero .kicker {
    color: var(--pill);
    padding: 7px 15px; border-radius: 999px;
    background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .2);
    margin-bottom: 22px; letter-spacing: .15em;
}
.hero h1 { color: #fff; margin-bottom: .35em; }
.hero-sub {
    font-size: clamp(1rem, 1.5vw, 1.16rem); color: rgba(255, 255, 255, .84);
    max-width: 660px; margin: 0 0 34px;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-actions .btn-outline { border-color: rgba(255, 255, 255, .42); color: #fff; }
.hero-actions .btn-outline:hover { background: rgba(255, 255, 255, .12); border-color: #fff; }

.hero-stats {
    display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px;
    margin-top: 52px; max-width: 700px;
}
.hero-stat {
    padding: 18px 20px; border-radius: 16px;
    background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .14);
    backdrop-filter: blur(6px);
}
.hero-stat b {
    display: block; font-size: clamp(1.3rem, 2.6vw, 1.9rem); font-weight: 800;
    letter-spacing: -.03em; color: var(--pill); line-height: 1.1;
}
.hero-stat span {
    display: block; margin-top: 4px; font-size: .76rem; text-transform: uppercase;
    letter-spacing: .1em; color: rgba(255, 255, 255, .66); font-weight: 700;
}

/* ---------------------------------------------------------------
   Podium
   --------------------------------------------------------------- */
.podium-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); gap: 34px; }
.podium-heading {
    font-size: .82rem; text-transform: uppercase; letter-spacing: .13em;
    color: var(--text-muted); margin-bottom: 16px; font-weight: 800;
}
.podium-row { display: flex; align-items: flex-end; gap: 12px; }
/* Op een breed scherm staat de winnaar in het midden, zoals op een echt podium.
   Alleen als er ook echt een derde plek is: met twee kaarten hoort nummer 1
   gewoon links te staan. */
.podium-row:has(.place-3) .place-1 { order: 1; }
.podium-row:has(.place-3) .place-2 { order: 0; }
.podium-row:has(.place-3) .place-3 { order: 2; }

.podium-card {
    flex: 1; min-width: 0; position: relative;
    display: flex; flex-direction: column; gap: 2px;
    padding: 22px 18px 20px; border-radius: 18px;
    background: var(--surface); border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: transform .2s ease, box-shadow .2s ease;
}
.podium-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }

/* plek 1 steekt boven de andere twee uit */
.podium-card.place-1 {
    padding-top: 30px; padding-bottom: 26px;
    border-color: color-mix(in srgb, var(--gold) 55%, transparent);
    box-shadow: var(--shadow-md);
}
.podium-card.place-1::before {
    content: ''; position: absolute; inset: 0 0 auto; height: 4px;
    border-radius: 18px 18px 0 0; background: var(--gold);
}
.podium-card.place-2::before,
.podium-card.place-3::before {
    content: ''; position: absolute; inset: 0 0 auto; height: 3px; border-radius: 18px 18px 0 0;
}
.podium-card.place-2::before { background: var(--silver); }
.podium-card.place-3::before { background: var(--bronze); }

.podium-rank {
    position: absolute; top: -13px; left: 18px;
    width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
    font-size: .82rem; font-weight: 800; color: #fff; background: var(--text-muted);
    box-shadow: var(--shadow-sm);
}
.podium-card.place-1 .podium-rank { background: var(--gold); color: #2a1c05; width: 32px; height: 32px; top: -15px; font-size: .92rem; }
.podium-card.place-2 .podium-rank { background: var(--silver); color: #1a2226; }
.podium-card.place-3 .podium-rank { background: var(--bronze); color: #fff; }

.podium-brand { font-size: .76rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: var(--text-muted); }
.podium-name { font-size: 1.02rem; font-weight: 700; letter-spacing: -.01em; margin-bottom: 10px; }
.podium-price {
    font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 800; letter-spacing: -.035em;
    color: var(--text); line-height: 1;
}
.podium-card.place-1 .podium-price { color: var(--accent); }
.podium-unit { font-size: .76rem; font-weight: 700; text-transform: uppercase; letter-spacing: .09em; color: var(--text-muted); margin-top: 4px; }
.podium-meta { font-size: .82rem; color: var(--text-soft); margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--border-soft); }

/* eigen merk krijgt een subtiel randje, zodat je het meteen ziet staan */
.podium-card.is-own { background: linear-gradient(180deg, var(--accent-soft), transparent 55%), var(--surface); }

/* ---------------------------------------------------------------
   Vergelijkingstabel
   --------------------------------------------------------------- */
.cmp-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.cmp-tab {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 18px; border-radius: 999px; cursor: pointer;
    background: var(--surface); border: 1px solid var(--border); color: var(--text-soft);
    font-family: inherit; font-size: .92rem; font-weight: 700;
    transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.cmp-tab span {
    font-size: .74rem; padding: 2px 7px; border-radius: 999px;
    background: var(--bg-soft); color: var(--text-muted);
}
.cmp-tab:hover { border-color: var(--text-muted); color: var(--text); }
.cmp-tab.active { background: var(--ink-900); border-color: var(--ink-900); color: #fff; }
.cmp-tab.active span { background: rgba(255, 255, 255, .16); color: var(--pill); }
html[data-theme="dark"] .cmp-tab.active { background: var(--pill); border-color: var(--pill); color: var(--ink-900); }
html[data-theme="dark"] .cmp-tab.active span { background: rgba(0, 0, 0, .18); color: var(--ink-900); }

.cmp-wrap {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm);
}
table.cmp { width: 100%; border-collapse: collapse; }

table.cmp thead th {
    text-align: left; padding: 14px 16px; white-space: nowrap;
    font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
    color: var(--text-muted); background: var(--surface-2);
    border-bottom: 1px solid var(--border); cursor: pointer; user-select: none;
    transition: color .2s ease;
}
table.cmp thead th:hover { color: var(--text); }
table.cmp thead th.sorted-asc::after  { content: ' \2191'; color: var(--accent); }
table.cmp thead th.sorted-desc::after { content: ' \2193'; color: var(--accent); }

table.cmp td { padding: 15px 16px; border-bottom: 1px solid var(--border-soft); vertical-align: middle; }
table.cmp tbody tr:last-child td { border-bottom: 0; }
table.cmp tbody tr { transition: background .18s ease; }
table.cmp tbody tr:hover { background: var(--bg-soft); }
table.cmp tbody tr.is-best { background: color-mix(in srgb, var(--accent) 6%, transparent); }
table.cmp tbody tr.is-best:hover { background: color-mix(in srgb, var(--accent) 10%, transparent); }

/* het eigen merk krijgt een streepje links; alleen zichtbaar, niet luidruchtig */
table.cmp tbody tr.is-own td:first-child { box-shadow: inset 3px 0 0 var(--accent); }

.col-rank { width: 54px; }
.col-num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.col-hero { width: 190px; }
th.col-num, th.col-hero { text-align: right; }

.rank-badge {
    display: grid; place-items: center; width: 28px; height: 28px; border-radius: 9px;
    background: var(--bg-soft); color: var(--text-muted);
    font-size: .82rem; font-weight: 800;
}
.rank-badge.rank-top { color: #fff; }
.rank-badge.rank-1 { background: var(--gold); color: #2a1c05; }
.rank-badge.rank-2 { background: var(--silver); color: #1a2226; }
.rank-badge.rank-3 { background: var(--bronze); }

.prod-name { font-weight: 700; font-size: 1rem; letter-spacing: -.01em; }
a.prod-name:hover { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.prod-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }

.chip {
    display: inline-block; padding: 3px 9px; border-radius: 7px;
    font-size: .74rem; font-weight: 700; letter-spacing: .01em;
    background: var(--bg-soft); color: var(--text-muted); border: 1px solid var(--border-soft);
}
.chip-brand { color: var(--text-soft); }
.chip-own { background: var(--accent-soft); color: var(--accent); border-color: color-mix(in srgb, var(--accent) 30%, transparent); }
.chip-pct { font-variant-numeric: tabular-nums; }
.chip-best { background: var(--pill); color: var(--pill-text); border-color: var(--pill); }
.chip-cat { background: transparent; }

.hero-cell { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; }
.hero-cell b {
    font-size: 1.32rem; font-weight: 800; letter-spacing: -.035em;
    font-variant-numeric: tabular-nums; line-height: 1.1;
}
tr.is-best .hero-cell b { color: var(--accent); }
.hero-diff { font-size: .76rem; font-weight: 700; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.hero-diff.is-zero { color: var(--accent); text-transform: uppercase; letter-spacing: .08em; font-size: .68rem; }
.hero-bar { display: block; width: 100%; height: 4px; border-radius: 3px; background: var(--border-soft); overflow: hidden; margin-top: 3px; }
.hero-bar i { display: block; height: 100%; border-radius: 3px; background: var(--text-muted); transition: width .4s ease; }
tr.is-best .hero-bar i { background: var(--accent); }

.cmp-note { margin-top: 14px; font-size: .86rem; color: var(--text-muted); }

/* ---------------------------------------------------------------
   Hoe wij rekenen
   --------------------------------------------------------------- */
.method-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; margin-bottom: 34px; }
.method-card {
    position: relative; padding: 26px 24px 24px;
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}
.method-step {
    display: grid; place-items: center; width: 34px; height: 34px; border-radius: 11px;
    background: var(--ink-900); color: var(--pill); font-weight: 800; font-size: .95rem; margin-bottom: 14px;
}
html[data-theme="dark"] .method-step { background: var(--pill); color: var(--ink-900); }
.method-card h3 { margin-bottom: 8px; }
.method-card p { color: var(--text-soft); font-size: .95rem; margin: 0; }
.method-note { font-size: .88rem; color: var(--text-muted); max-width: 720px; margin-top: 26px; }

/* rekenvoorbeeld */
.calc {
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
    overflow: hidden; box-shadow: var(--shadow-sm);
}
.calc-head { padding: 24px 26px 0; }
.calc-head h3 { margin-bottom: 6px; }
.calc-head p { color: var(--text-muted); font-size: .93rem; max-width: 560px; }
.calc-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 340px); gap: 0; align-items: stretch; }
.calc-inputs { padding: 6px 26px 26px; display: grid; gap: 16px; align-content: start; }

.calc-field span {
    display: block; font-size: .78rem; font-weight: 800; letter-spacing: .09em;
    text-transform: uppercase; color: var(--text-muted); margin-bottom: 6px;
}
.calc-input {
    display: flex; align-items: center; gap: 8px;
    border: 1px solid var(--border); border-radius: 12px; background: var(--bg);
    padding: 0 14px; transition: border-color .2s ease, box-shadow .2s ease;
}
.calc-input:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.calc-input i {
    font-style: normal; font-size: .9rem; font-weight: 700; color: var(--text-muted); flex: none;
}
.calc-input input {
    flex: 1; min-width: 0; border: 0; background: none; outline: 0;
    padding: 13px 0; font-family: inherit; font-size: 1.05rem; font-weight: 700;
    color: var(--text); font-variant-numeric: tabular-nums;
}

.calc-out {
    background: var(--ink-900); color: #fff; padding: 26px;
    display: flex; flex-direction: column; justify-content: center; gap: 2px;
}
.calc-line {
    display: flex; align-items: baseline; justify-content: space-between; gap: 14px;
    padding: 11px 0; border-bottom: 1px solid rgba(255, 255, 255, .1);
}
.calc-line:last-child { border-bottom: 0; }
.calc-line span { font-size: .86rem; color: rgba(255, 255, 255, .66); }
.calc-line b { font-size: 1.1rem; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.calc-line-hero { padding: 16px 0; }
.calc-line-hero span { color: rgba(255, 255, 255, .8); font-weight: 600; }
.calc-line-hero b { font-size: 1.9rem; color: var(--pill); }
.calc-line-soft b { color: rgba(255, 255, 255, .72); font-size: .98rem; }

/* ---------------------------------------------------------------
   Blog
   --------------------------------------------------------------- */
.blog-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; margin-bottom: 34px; flex-wrap: wrap; }

.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.post-card {
    display: flex; flex-direction: column; overflow: hidden;
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.post-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--text-muted); }
.post-thumb { aspect-ratio: 16 / 10; background: var(--bg-soft); overflow: hidden; }
.post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.post-thumb-empty {
    width: 100%; height: 100%;
    background:
        radial-gradient(circle at 26% 30%, color-mix(in srgb, var(--brand-400) 34%, transparent), transparent 48%),
        linear-gradient(140deg, var(--ink-900), var(--ink-700));
}
.post-body { padding: 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.post-date { font-size: .76rem; text-transform: uppercase; letter-spacing: .1em; color: var(--accent); font-weight: 800; }
.post-card h3 { margin: 0; font-size: 1.14rem; }
.post-card p { color: var(--text-soft); font-size: .93rem; margin: 0; }
.post-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 12px; }
.tag {
    display: inline-block; padding: 3px 9px; border-radius: 7px; font-size: .74rem; font-weight: 700;
    background: var(--bg-soft); color: var(--text-muted);
}
.post-more { font-size: .87rem; font-weight: 800; color: var(--accent); }

/* ---------------------------------------------------------------
   Artikelpagina
   --------------------------------------------------------------- */
.post-hero { padding-top: 46px; padding-bottom: 30px; max-width: 900px; }
.post-hero .back { color: var(--text-muted); font-size: .9rem; font-weight: 700; }
.post-hero .back:hover { color: var(--accent); }
.post-hero h1 { margin: 18px 0 12px; font-size: clamp(1.9rem, 4.2vw, 3rem); }
.post-hero-meta { display: flex; align-items: center; gap: 12px; color: var(--text-muted); font-size: .9rem; flex-wrap: wrap; }
.avatar {
    width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
    background: var(--ink-900); color: var(--pill); font-weight: 800; font-size: .9rem;
}
.post-cover { margin: 30px 0 8px; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 16 / 9; background: var(--bg-soft); }
.post-cover img { width: 100%; height: 100%; object-fit: cover; }

.article { max-width: 760px; margin: 0 auto; font-size: 1.08rem; line-height: 1.75; color: var(--text-soft); }
.article h2 { color: var(--text); margin: 1.6em 0 .5em; font-size: 1.65rem; }
.article h3 { color: var(--text); margin: 1.4em 0 .4em; }
.article img { border-radius: 14px; margin: 1.4em 0; }
.article img.is-portrait { float: right; width: min(45%, 300px); margin: .3em 0 1.2em 1.6em; }
.article img.is-portrait.align-left { float: left; margin: .3em 1.6em 1.2em 0; }
.article::after { content: ''; display: block; clear: both; }
.article blockquote {
    border-left: 4px solid var(--accent); padding-left: 18px; margin: 1.4em 0;
    font-style: italic; color: var(--text);
}
.article ul, .article ol { padding-left: 22px; }
.article a { color: var(--link); text-decoration: underline; text-underline-offset: 2px; }
.article .video-embed { width: 100%; aspect-ratio: 16 / 9; margin: 1.4em 0; border-radius: 14px; overflow: hidden; background: #000; }
.article .video-embed iframe { width: 100%; height: 100%; border: 0; display: block; }

.post-photos { max-width: 900px; margin: 46px auto 0; }
.post-photos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.post-photos-grid figure { margin: 0; aspect-ratio: 1 / 1; border-radius: 12px; overflow: hidden; cursor: zoom-in; }
.post-photos-grid img { width: 100%; height: 100%; object-fit: cover; }

.post-nav { display: flex; justify-content: space-between; gap: 16px; margin-top: 50px; padding-top: 26px; border-top: 1px solid var(--border); }

/* lightbox */
.lightbox {
    position: fixed; inset: 0; z-index: 200; display: none;
    align-items: center; justify-content: center; padding: 30px;
    background: rgba(6, 12, 14, .92);
}
.lightbox.open { display: flex; }
.lightbox-inner { position: relative; max-width: 1100px; max-height: 90vh; }
.lightbox img { max-width: 100%; max-height: 84vh; border-radius: 12px; }
.lightbox-caption { color: rgba(255, 255, 255, .8); text-align: center; margin-top: 12px; font-size: .9rem; }
.lightbox-close {
    position: absolute; top: -14px; right: -14px; width: 38px; height: 38px; border-radius: 50%;
    background: #fff; border: 0; font-size: 1.3rem; cursor: pointer; color: #111;
}
.lightbox-arrow {
    background: rgba(255, 255, 255, .14); border: 0; color: #fff; width: 46px; height: 46px;
    border-radius: 50%; font-size: 1.2rem; cursor: pointer; flex: none;
}
.lightbox-arrow:hover { background: rgba(255, 255, 255, .28); }

/* ---------------------------------------------------------------
   Formulieren en meldingen (ook gebruikt in de beheeromgeving)
   --------------------------------------------------------------- */
.form-row { margin-bottom: 18px; }
.form-row.two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-label { display: block; font-size: .82rem; font-weight: 800; letter-spacing: .05em; margin-bottom: 6px; color: var(--text-soft); }
.input, textarea.input, select.input {
    width: 100%; padding: 12px 14px; border-radius: 11px; background: var(--bg);
    border: 1px solid var(--border); color: var(--text);
    font-family: inherit; font-size: .98rem;
}
.input:focus { outline: 0; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.help { font-size: .84rem; color: var(--text-muted); margin-top: 6px; }

.notice { padding: 14px 18px; border-radius: 12px; margin-bottom: 20px; font-size: .93rem; }
.notice-error { background: #fdecec; color: #8f2020; border: 1px solid #f4bcbc; }
.notice-ok { background: #e8f8f1; color: #10664a; border: 1px solid #a9e3ce; }
html[data-theme="dark"] .notice-error { background: #3a1c1c; color: #ffb3b3; border-color: #5a2b2b; }
html[data-theme="dark"] .notice-ok { background: #12332a; color: #8fe4c4; border-color: #1f5044; }

/* ---------------------------------------------------------------
   Footer
   --------------------------------------------------------------- */
.site-footer { background: var(--ink-900); color: rgba(255, 255, 255, .7); padding-top: 54px; }
.footer-inner { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 34px; padding-bottom: 34px; }
.site-footer .brand { color: #fff; margin-bottom: 14px; }
.site-footer .brand-mark { background: var(--pill); color: var(--ink-900); }
.footer-disclaimer { font-size: .88rem; max-width: 520px; margin: 0; color: rgba(255, 255, 255, .58); }
.footer-links { display: flex; flex-direction: column; gap: 9px; align-items: flex-start; }
.footer-links a { font-size: .92rem; font-weight: 600; color: rgba(255, 255, 255, .72); }
.footer-links a:hover { color: var(--pill); }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding-top: 18px; padding-bottom: 26px; }
.footer-text { font-size: .84rem; margin: 0; color: rgba(255, 255, 255, .45); }

/* ---------------------------------------------------------------
   Bewerkmodus
   --------------------------------------------------------------- */
.edit-bar {
    position: sticky; top: 70px; z-index: 59;
    display: flex; align-items: center; gap: 10px;
    padding: 9px 20px; font-size: .86rem; font-weight: 600;
    background: var(--ink-900); color: #fff;
}
.edit-bar-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--pill); animation: pulse 1.6s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .3; } }
.edit-status { margin-left: auto; color: var(--pill); }

body.editing .editable {
    outline: 1px dashed color-mix(in srgb, var(--accent) 60%, transparent);
    outline-offset: 3px; border-radius: 4px; cursor: text; min-height: 1em; min-width: 2ch;
}
body.editing .editable:hover { outline-style: solid; background: var(--accent-soft); }
body.editing .editable:focus { outline: 2px solid var(--accent); background: var(--accent-soft); }
.editable.saved { outline-color: var(--pill) !important; background: color-mix(in srgb, var(--pill) 28%, transparent) !important; }

.rich-toolbar {
    position: absolute; z-index: 120; display: flex; gap: 3px; padding: 6px;
    background: var(--surface); border: 1px solid var(--border); border-radius: 11px;
    box-shadow: var(--shadow-md);
}
.rich-toolbar button {
    min-width: 32px; height: 30px; padding: 0 8px; border-radius: 7px; border: 1px solid transparent;
    background: transparent; color: var(--text); cursor: pointer; font-size: .86rem; font-weight: 700;
    font-family: inherit;
}
.rich-toolbar button:hover { background: var(--bg-soft); border-color: var(--border); }

/* ---------------------------------------------------------------
   Mobiel
   --------------------------------------------------------------- */
@media (max-width: 1000px) {
    .calc-body { grid-template-columns: 1fr; }
    .podium-grid { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 860px) {
    .topnav { display: none; }
    .btn-compare-top { display: none; }
    .topbar-inner { height: 62px; }
    .edit-bar { top: 62px; }
    html { scroll-padding-top: 76px; }
    .section { padding-top: 56px; padding-bottom: 56px; }
    .hero { padding-top: 56px; padding-bottom: 54px; }
    .hero-stats { grid-template-columns: 1fr; gap: 10px; margin-top: 36px; }
    .hero-stat { display: flex; align-items: baseline; gap: 12px; padding: 14px 16px; }
    .hero-stat b { font-size: 1.35rem; }
    .hero-stat span { margin-top: 0; }
    .hero-actions .btn { flex: 1; }
    .footer-inner { grid-template-columns: 1fr; gap: 26px; }
}

/* Podium: onder elkaar, in de juiste volgorde (1, 2, 3) */
@media (max-width: 700px) {
    /* onder elkaar in de volgorde waarin ze in de code staan: 1, 2, 3 */
    .podium-row { flex-direction: column; align-items: stretch; gap: 14px; }
    .podium-row:has(.place-3) .place-1,
    .podium-row:has(.place-3) .place-2,
    .podium-row:has(.place-3) .place-3 { order: 0; }
    .podium-rank { top: -13px; }
    .podium-card.place-1 { padding-top: 24px; }
}

/* De tabel wordt een stapel kaarten. De twee getallen die ertoe doen blijven
   groot; de rest komt eronder als losse regels met een eigen label. */
@media (max-width: 760px) {
    .cmp-wrap { background: none; border: 0; box-shadow: none; border-radius: 0; overflow: visible; }
    table.cmp, table.cmp tbody, table.cmp td { display: block; width: 100%; }
    table.cmp thead { display: none; }

    /* De cellen staan in tabelvolgorde in de code. Als kaart willen we het
       kerngetal bovenaan, dus zetten we ze met flex-order op hun plek. */
    table.cmp tbody tr {
        position: relative; display: flex; flex-direction: column; width: 100%;
        background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
        margin-bottom: 12px; padding: 16px 16px 12px; box-shadow: var(--shadow-sm);
    }
    .col-product { order: 1; }
    .col-hero { order: 2; }
    .col-num, .col-cat { order: 3; }
    table.cmp tbody tr:hover { background: var(--surface); }
    table.cmp tbody tr.is-best { border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
    table.cmp tbody tr.is-own td:first-child { box-shadow: none; }
    table.cmp tbody tr.is-own { border-left: 3px solid var(--accent); }

    table.cmp td { padding: 0; border-bottom: 0; }

    /* Rangnummer rechtsboven in de kaart. De selector moet specifieker zijn dan
       "table.cmp td" hierboven, anders wint diens width:100% en rekt de cel over
       de hele kaart - het bolletje staat dan links. */
    table.cmp tbody tr td.col-rank {
        position: absolute; top: 14px; right: 14px; left: auto;
        width: 28px; padding: 0;
    }

    .col-product { padding-right: 44px !important; margin-bottom: 14px; }
    .prod-name { font-size: 1.06rem; }

    /* het kerngetal krijgt de hele breedte, met de balk eronder */
    .col-hero {
        margin-bottom: 12px; padding: 12px 14px !important;
        background: var(--bg-soft); border-radius: 12px;
    }
    .hero-cell { flex-direction: row; align-items: center; flex-wrap: wrap; gap: 8px; }
    .hero-cell b { font-size: 1.7rem; }
    .hero-cell .hero-diff { margin-left: auto; }
    .hero-bar { order: 3; margin-top: 4px; }
    .col-hero::before {
        content: attr(data-label); display: block; width: 100%;
        font-size: .68rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
        color: var(--text-muted); margin-bottom: 2px;
    }

    /* De overige cijfers als nette regels. De scheidingslijn staat bovenaan,
       zodat de laatste regel geen losse lijn onder zich krijgt. */
    .col-num, .col-cat {
        display: flex !important; align-items: center; justify-content: space-between; gap: 14px;
        padding: 8px 2px !important; text-align: right;
        border-top: 1px solid var(--border-soft);
        font-size: .93rem; font-weight: 600;
    }
    .col-num::before, .col-cat::before {
        content: attr(data-label); flex: none; text-align: left;
        font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
        color: var(--text-muted);
    }

    .cmp-tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
    .cmp-tab { flex: none; }
}

@media (max-width: 520px) {
    .calc-head, .calc-inputs { padding-left: 18px; padding-right: 18px; }
    .calc-out { padding: 20px 18px; }
    .calc-line-hero b { font-size: 1.6rem; }
    .post-grid { grid-template-columns: 1fr; }
    .hero-actions { flex-direction: column; }
    .hero-actions .btn { width: 100%; }
}

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