/* Wise Renewable website: shared tokens, header, footer and building blocks for every page.
   Calm Scandinavian layout: white space and surface changes instead of frames, one teal for actions. */
@font-face { font-family: 'Inter'; src: url('fonts/Inter-latin.woff2') format('woff2'); font-weight: 400 700; font-display: swap; }
@font-face { font-family: 'Plus Jakarta Sans'; src: url('fonts/PlusJakartaSans-latin.woff2') format('woff2'); font-weight: 600 800; font-display: swap; }

:root {
    --bg-page: #FFFFFF;
    --bg-subtle: #F5F6F8;
    --bg-editorial-dark: #161B22;
    --ink-primary: #111827;
    --ink-secondary: #374151;
    --ink-on-dark: #E5E7EB;
    --brand-teal: #0F766E;
    --brand-teal-hover: #115E59;
    --tier-cheap: #15803D;
    --tier-mid: #B45309;
    --tier-high: #B91C1C;
    --line: #E5E7EB;
    --line-strong: #D1D5DB;
    --bg-field: #FFFFFF;
    --on-brand: #FFFFFF;
    --font-head: 'Plus Jakarta Sans', -apple-system, 'Segoe UI', sans-serif;
    --font-body: 'Inter', -apple-system, 'Segoe UI', sans-serif;
    --max: 1160px;
    --gutter: 24px;
    color-scheme: light;
}
/* Dark theme: chosen by the visitor or by the system setting (site.js sets data-theme). */
:root[data-theme=dark] {
    --bg-page: #0F141A;
    --bg-subtle: #171E26;
    --bg-editorial-dark: #090C10;
    --ink-primary: #F3F4F6;
    --ink-secondary: #C3CAD3;
    --brand-teal: #2DD4BF;
    --brand-teal-hover: #5EEAD4;
    --tier-cheap: #4ADE80;
    --tier-mid: #FBBF24;
    --tier-high: #F87171;
    --line: #2A323C;
    --line-strong: #3B4552;
    --bg-field: #0F141A;
    --on-brand: #042F2E;
    color-scheme: dark;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--font-body); color: var(--ink-primary); background: var(--bg-page); line-height: 1.6; font-size: 1rem; }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }
a { color: var(--brand-teal); }
a:hover { color: var(--brand-teal-hover); }
:focus-visible { outline: 2px solid var(--brand-teal); outline-offset: 2px; }

h1, h2, h3 { font-family: var(--font-head); font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; color: var(--ink-primary); text-wrap: balance; }
h1 { font-size: clamp(2rem, 4.5vw, 3.1rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
h3 { font-size: 1.2rem; }
p { color: var(--ink-secondary); max-width: 68ch; }
.lede { font-size: 1.15rem; }
.num { font-variant-numeric: tabular-nums; }

/* Layout: full-width sections, centred 12-column grid inside. */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: 80px 0; }
.section.subtle { background: var(--bg-subtle); }
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gutter); align-items: center; }
.grid.top { align-items: start; }
.nowrap { white-space: nowrap; }
.span-4 { grid-column: span 4; } .span-5 { grid-column: span 5; } .span-6 { grid-column: span 6; } .span-7 { grid-column: span 7; }
.stack { display: grid; gap: 16px; align-content: start; }
.stack-lg { display: grid; gap: 28px; align-content: start; }
@media (max-width: 860px) {
    .section { padding: 56px 0; }
    .grid { grid-template-columns: 1fr; }
    .span-4, .span-5, .span-6, .span-7 { grid-column: auto; }
}
@media (max-width: 480px) { :root { --gutter: 16px; } }

/* Header */
.site-header { height: 64px; background: var(--bg-page); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
.site-header .wrap { height: 100%; display: flex; align-items: center; gap: 24px; }
.brand { font-family: var(--font-head); font-weight: 700; font-size: 1.1rem; color: var(--ink-primary); text-decoration: none; letter-spacing: -0.02em; white-space: nowrap; }
.nav { display: flex; gap: 22px; margin: 0 auto; }
.nav a { color: var(--ink-secondary); text-decoration: none; font-size: 0.95rem; font-weight: 500; white-space: nowrap; }
.nav a:hover, .nav a[aria-current=page] { color: var(--ink-primary); }
.nav a[aria-current=page] { box-shadow: inset 0 -2px 0 var(--brand-teal); padding-bottom: 2px; }
.site-tools { display: flex; align-items: center; gap: 4px; }
.site-tools a, .site-tools button { color: var(--ink-secondary); background: none; border: 0; font: 600 0.9rem var(--font-body); text-decoration: none; padding: 8px; border-radius: 8px; cursor: pointer; line-height: 1; }
.site-tools a:hover, .site-tools button:hover { color: var(--ink-primary); background: var(--bg-subtle); }
.menu-toggle { display: none; background: none; border: 0; font: inherit; font-weight: 600; color: var(--ink-primary); padding: 8px; cursor: pointer; }
@media (max-width: 1100px) {
    .menu-toggle { display: block; }
    .site-tools { margin-left: auto; }
    .site-header .wrap { gap: 8px; }
    .site-header .btn { display: none; }
    .nav { display: none; position: absolute; top: 64px; left: 0; right: 0; background: var(--bg-page); flex-direction: column; gap: 0; padding: 8px var(--gutter) 16px; border-bottom: 1px solid var(--line); }
    .nav.open { display: flex; }
    .nav a { padding: 12px 0; }
    .nav a[aria-current=page] { box-shadow: none; color: var(--brand-teal); }
}

/* Buttons and links */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--brand-teal); color: var(--on-brand); font: 600 0.95rem var(--font-body); border: 0; border-radius: 9999px; padding: 12px 22px; text-decoration: none; cursor: pointer; transition: background-color .15s; white-space: nowrap; }
.btn:hover { background: var(--brand-teal-hover); color: var(--on-brand); }
.btn:disabled { opacity: .5; cursor: default; }
.text-link { font-weight: 600; text-decoration: none; }
.text-link:hover { text-decoration: underline; }
.link-button { background: none; border: 0; font: 600 1rem var(--font-body); color: var(--brand-teal); cursor: pointer; padding: 0; }
.link-button:hover { text-decoration: underline; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }

/* Photos and mascots */
.photo { border-radius: 20px; width: 100%; height: auto; object-fit: cover; }
.owl { width: 132px; height: auto; }

/* Forms */
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 20px; }
@media (max-width: 600px) { .form-grid { grid-template-columns: 1fr; } }
label { display: grid; gap: 6px; font-size: 0.92rem; font-weight: 500; color: var(--ink-primary); }
label.check { display: flex; align-items: center; gap: 10px; font-weight: 400; }
input, select { font: 400 1rem var(--font-body); color: var(--ink-primary); background: var(--bg-field); border: 1px solid var(--line-strong); border-radius: 10px; padding: 11px 12px; width: 100%; font-variant-numeric: tabular-nums; }
input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--brand-teal); }
input:focus, select:focus { outline: 2px solid var(--brand-teal); outline-offset: 0; border-color: transparent; }
input[readonly] { background: var(--bg-subtle); }
.hint { font-size: 0.88rem; color: var(--ink-secondary); }
.status { font-size: 0.95rem; color: var(--ink-secondary); min-height: 1.5em; }

/* Segmented control (Heute / Morgen) */
.segment { display: inline-flex; background: var(--bg-field); border-radius: 10px; padding: 4px; gap: 4px; }
.segment button { font: 600 0.95rem var(--font-body); color: var(--ink-secondary); background: transparent; border: 0; border-radius: 8px; padding: 8px 18px; cursor: pointer; }
.segment button[aria-pressed=true] { background: var(--brand-teal); color: var(--on-brand); }

/* Tables */
.table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.table th, .table td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--line); vertical-align: top; hyphens: auto; }
.table th { font-weight: 600; color: var(--ink-primary); font-size: 0.92rem; }
.table td { color: var(--ink-secondary); }
.table .r { text-align: right; white-space: nowrap; }
.table tfoot td, .table tfoot th { color: var(--ink-primary); font-weight: 700; border-bottom: 0; }
.scroll-x { overflow-x: auto; }

/* Price tiers */
.tier-cheap { color: var(--tier-cheap); } .tier-mid { color: var(--tier-mid); } .tier-high { color: var(--tier-high); }

/* FAQ */
details { border-bottom: 1px solid var(--line); padding: 16px 0; }
details summary { cursor: pointer; font-weight: 600; color: var(--ink-primary); list-style: none; display: flex; justify-content: space-between; gap: 16px; }
details summary::-webkit-details-marker { display: none; }
details summary::after { content: '+'; color: var(--brand-teal); font-weight: 700; }
details[open] summary::after { content: '−'; }
details p { margin-top: 10px; }

/* Reading pages (legal, blog, guide) */
.reading { max-width: 720px; margin: 0 auto; padding: 56px var(--gutter) 80px; }
.reading h1 { margin-bottom: 12px; }
.reading h2 { font-size: 1.35rem; margin: 36px 0 10px; }
.reading h3 { margin: 24px 0 8px; }
.reading p, .reading ul, .reading ol { margin-bottom: 14px; color: var(--ink-secondary); }
.reading ul, .reading ol { padding-left: 22px; }
.reading li { margin-bottom: 6px; }
.meta { display: block; margin-bottom: 20px; font-size: 0.9rem; color: var(--ink-secondary); }
.back { display: inline-block; margin-bottom: 20px; text-decoration: none; font-weight: 500; }

/* Footer */
.site-footer { background: var(--bg-editorial-dark); color: var(--ink-on-dark); padding: 56px 0 32px; }
.site-footer .cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gutter); }
@media (max-width: 860px) { .site-footer .cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .site-footer .cols { grid-template-columns: 1fr; } }
.site-footer h4 { font: 600 0.95rem var(--font-body); color: #fff; margin-bottom: 12px; }
.site-footer p, .site-footer li { color: var(--ink-on-dark); font-size: 0.9rem; }
.site-footer ul { list-style: none; display: grid; gap: 8px; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.site-footer .fine { margin-top: 40px; font-size: 0.82rem; color: #C9CDD3; max-width: none; }

/* Home page */
.hero h1 { margin-bottom: 18px; }
.hero .actions { margin-top: 28px; }
.principles h3 { margin-bottom: 8px; }
.owl-stage { display: grid; justify-items: center; gap: 18px; text-align: center; }
.owl-stage img { width: min(340px, 90%); height: auto; }
.owl-stage .state-text { font-weight: 600; }
.owl-stage .live { font-size: 0.95rem; }
.features { list-style: none; display: grid; gap: 14px; }
.features strong { color: var(--ink-primary); }
.tool h3 { margin-bottom: 8px; }
.tool .text-link { display: inline-block; margin-top: 14px; }
.plain-list { padding-left: 20px; display: grid; gap: 6px; color: var(--ink-secondary); }

/* Price page */
.page { max-width: 960px; margin: 0 auto; padding: 48px var(--gutter) 0; }
.page > header { margin-bottom: 28px; }
.page > header p { margin-top: 12px; }
.chart-card { background: var(--bg-subtle); border-radius: 20px; padding: 28px; }
.chart-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.now { display: flex; align-items: center; gap: 14px; text-align: right; }
.now img { width: 128px; height: auto; margin: -12px -8px -12px 0; }
.now .label { font-size: 0.9rem; color: var(--ink-secondary); }
.now .price { font: 700 2.4rem/1.05 var(--font-head); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.now .price small { font: 500 1rem var(--font-body); color: var(--ink-secondary); margin-left: 4px; }
.detail { margin-top: 18px; font-size: 0.95rem; color: var(--ink-secondary); min-height: 1.6em; font-variant-numeric: tabular-nums; }
.bars { display: flex; align-items: flex-end; gap: 1px; height: 180px; margin-top: 10px; touch-action: none; }
.bars div { flex: 1; min-width: 0; border-radius: 2px 2px 0 0; background: var(--tier-mid); cursor: pointer; transition: opacity .1s; }
.bars .cheap { background: var(--tier-cheap); } .bars .high { background: var(--tier-high); }
.bars .past { opacity: .35; }
.bars .sel { outline: 2px solid var(--ink-primary); outline-offset: 1px; }
.axis { display: flex; justify-content: space-between; font-size: 0.8rem; color: var(--ink-secondary); margin-top: 6px; }
.chart-foot { margin-top: 18px; display: grid; gap: 6px; }
.chart-foot strong { color: var(--ink-primary); }
.empty { display: grid; justify-items: center; text-align: center; gap: 12px; padding: 24px 0 8px; }
.empty img { width: 180px; height: auto; }
.explain { padding: 64px 0; }
.legend { list-style: none; display: grid; gap: 10px; }
.legend li { display: flex; gap: 10px; align-items: baseline; color: var(--ink-secondary); }
.legend .sw { width: 12px; height: 12px; border-radius: 3px; flex: none; transform: translateY(1px); }
.tariff { padding: 0 0 64px; }
.tariff .actions { margin-top: 20px; }
.sources { font-size: 0.88rem; padding-bottom: 64px; }
@media (max-width: 600px) { .chart-card { padding: 20px 16px; } .bars { height: 140px; } .now .price { font-size: 2rem; } }

/* Calculator page */
.intro { margin-bottom: 32px; }
.intro p { margin-top: 12px; }
.intro .photo { margin-top: 28px; aspect-ratio: 16 / 9; }
/* A labelled diagram is shown whole, never cropped to the photo frame. */
.intro .photo.diagram { aspect-ratio: auto; }
.calc { background: var(--bg-subtle); border-radius: 20px; padding: 32px; display: grid; gap: 32px; }
.calc h2 { font-size: 1.25rem; margin-bottom: 14px; }
.calc .hint { margin-top: 10px; max-width: none; }
.calc .actions { gap: 16px; }
.working-owl { width: 96px; height: auto; margin: -16px 0; }
.result { padding: 48px 0 16px; scroll-margin-top: 72px; }
.verdict { font: 700 1.4rem/1.3 var(--font-head); letter-spacing: -0.02em; margin: 10px 0 20px; }
.methods { background: var(--bg-subtle); padding: 64px 0; margin-top: 48px; }
.methods .inner { max-width: 960px; margin: 0 auto; padding: 0 var(--gutter); }
.methods ul { padding-left: 20px; display: grid; gap: 8px; color: var(--ink-secondary); }
@media (max-width: 600px) { .calc { padding: 20px 16px; } }

/* Blog */
.quote-box { border-left: 3px solid var(--brand-teal); padding-left: 18px; margin: 24px 0; }
.quote-box p { font-style: italic; color: var(--ink-primary); }
