/* ==========================================================================
   Söndaghelaveckan Podcast – startsidan
   Samma utseende som www.sondaghelaveckan.se: mörk header, Arial, vita kort med skugga, blå knappar
   (#0087db → #0068a0) och blå sidfot. Mörkt läge via färgvariabler: följer systemets inställning och kan
   överstyras med knappen i headern (data-theme på <html>, se js/app.js).
   ========================================================================== */

:root {
    color-scheme: light;
    --bg: #f9f9f9;
    --text: #333;
    --heading: #000;
    --muted: #707070;
    --link: #0068a0;
    --border: #ccc;
    --card: #fff;
    --card-shadow: 0 4px 4px rgba(0, 0, 0, .2);
    --header-bg: rgba(51, 51, 51, .92);
    --box-bg: #eeeded;
    --input-bg: #fff;
    --input-border: #c9c9c9;
    --input-text: #333;
    --btn-from: #0087db;
    --btn-to: #0068a0;
    --footer-bg: #0068a0;
    --error-bg: #fde8e8;
    --error-text: #922;
    --accent-soft: #e2f1fb;
    --ok: #1e8449;
}
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        color-scheme: dark;
        --bg: #15171a;
        --text: #d3d7dc;
        --heading: #f3f5f7;
        --muted: #9aa1a9;
        --link: #62b6ee;
        --border: #30353b;
        --card: #1e2125;
        --card-shadow: 0 4px 10px rgba(0, 0, 0, .45);
        --header-bg: rgba(10, 11, 13, .92);
        --box-bg: #23272c;
        --input-bg: #15171a;
        --input-border: #3a4047;
        --input-text: #e3e6e9;
        --btn-from: #0a8ee0;
        --btn-to: #005f93;
        --footer-bg: #0b3b58;
        --error-bg: #3a1d1d;
        --error-text: #f2b8b5;
        --accent-soft: #14303f;
        --ok: #58c98a;
    }
}
:root[data-theme="dark"] {
    color-scheme: dark;
    --bg: #15171a;
    --text: #d3d7dc;
    --heading: #f3f5f7;
    --muted: #9aa1a9;
    --link: #62b6ee;
    --border: #30353b;
    --card: #1e2125;
    --card-shadow: 0 4px 10px rgba(0, 0, 0, .45);
    --header-bg: rgba(10, 11, 13, .92);
    --box-bg: #23272c;
    --input-bg: #15171a;
    --input-border: #3a4047;
    --input-text: #e3e6e9;
    --btn-from: #0a8ee0;
    --btn-to: #005f93;
    --footer-bg: #0b3b58;
    --error-bg: #3a1d1d;
    --error-text: #f2b8b5;
    --accent-soft: #14303f;
    --ok: #58c98a;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 100px; }
body, h1, h2, h3, p, form, ul { margin: 0; padding: 0; }
body {
    background: var(--bg);
    color: var(--text);
    font-family: Arial, Verdana, sans-serif;
    font-size: 100%;
    line-height: 1.5;
}
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { max-width: 100%; }

h1, h2, h3 { color: var(--heading); font-weight: bold; line-height: 1.2; }
h1 { font-size: 2.1em; margin-bottom: 16px; }
h2 { font-size: 1.5em; margin-bottom: 12px; }
h3 { font-size: 1.25em; margin-bottom: 8px; }
p { margin-bottom: 14px; }
.lead { font-size: 1.15em; }

/* Header: loggan på vit platta, så att den syns tydligt mot den mörka bakgrunden
   ========================================================================== */
#top {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 20px;
    background: #333;
    background-color: var(--header-bg);
}
#top .brand { display: flex; align-items: center; gap: 14px; margin-right: auto; color: #fff; text-decoration: none; }
#top .brand img { display: block; width: 56px; height: 56px; border-radius: 6px; background: #fff; }
#top .brand-text { display: flex; flex-direction: column; line-height: 1.2; }
#top .site-title { color: #fff; font-size: 1.5em; font-weight: bold; }
#top .site-sub { color: #fff; font-size: .875em; font-weight: bold; }

.theme-toggle {
    flex: none;
    width: 34px; height: 34px;
    border: 1px solid rgba(255, 255, 255, .25);
    border-radius: 50%;
    background: transparent;
    color: #fff;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    opacity: .75;
}
.theme-toggle:hover, .theme-toggle:focus-visible { opacity: 1; border-color: rgba(255, 255, 255, .6); }
.theme-toggle .icon-dark { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-light { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-dark { display: inline; }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .theme-toggle .icon-light { display: none; }
    :root:not([data-theme="light"]) .theme-toggle .icon-dark { display: inline; }
}

/* Knappar och formulär
   ========================================================================== */
input[type="submit"], .button {
    display: inline-block;
    padding: 8px 16px;
    border: none;
    border-radius: 5px;
    color: #fff;
    font: inherit;
    font-size: .8125em;
    font-weight: bold;
    line-height: 1.4;
    text-shadow: 0 -1px 0 rgba(0, 0, 0, .25);
    background: var(--btn-from) linear-gradient(to bottom, var(--btn-from) 0%, var(--btn-to) 100%);
    cursor: pointer;
}
input[type="submit"]:hover, .button:hover { background: var(--btn-to); text-decoration: none; }
.button.big, #contentForm input[type="submit"] { padding: 12px 24px; font-size: .9375em; }
a:focus-visible, button:focus-visible, input[type="submit"]:focus-visible { outline: 3px solid var(--btn-from); outline-offset: 2px; }

#contentForm label { display: block; margin-top: 16px; font-size: .9375em; font-weight: bold; }
#contentForm input[type="text"], #contentForm input[type="email"] {
    display: block;
    width: 100%;
    max-width: 500px;
    height: 44px;
    margin-top: 6px;
    padding: 0 12px;
    font: inherit;
    font-weight: normal;
    color: var(--input-text);
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: 5px;
}
#contentForm input[type="text"]:focus, #contentForm input[type="email"]:focus { outline: none; box-shadow: 0 0 0 2px var(--btn-from); }
#contentForm input[type="submit"] { margin-top: 22px; }
#contentForm .hp { position: absolute; left: -9999px; }
#contentForm .captcha { margin-top: 20px; }
.form-errors { background: var(--error-bg); border-left: 4px solid #c0392b; padding: 10px 15px; margin-bottom: 8px; }
.form-errors p { margin: 4px 0; color: var(--error-text); }
.privacy { margin: 22px 0 0; font-size: .8125em; color: var(--muted); max-width: 500px; }

/* Layout
   ========================================================================== */
#wrapper { width: 92%; max-width: 980px; margin: 0 auto; padding: 32px 0 0; }
.card { background: var(--card); padding: 32px; margin-bottom: 32px; box-shadow: var(--card-shadow); }
.card > :last-child { margin-bottom: 0; }

.hero { display: flex; align-items: center; gap: 40px; }
.hero-logo { flex: none; width: 260px; height: 260px; border-radius: 8px; background: #fff; border: 1px solid var(--border); }
.hero-text > :last-child { margin-bottom: 0; }
.kicker { margin-bottom: 8px; color: var(--link); font-size: .8125em; font-weight: bold; letter-spacing: .08em; text-transform: uppercase; }

.section-title { margin: 44px 0 20px; text-align: center; font-size: 1.6875em; }

.step { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; margin-bottom: 36px; }
.step:nth-of-type(odd) .step-text { order: 2; }
.step-text > :last-child { margin-bottom: 0; }
.step-no {
    display: inline-block;
    width: 40px; height: 40px;
    margin-bottom: 12px;
    border-radius: 50%;
    background: var(--btn-to);
    color: #fff;
    font-size: 1.25em;
    font-weight: bold;
    line-height: 40px;
    text-align: center;
}

.facts h2:not(:first-child) { margin-top: 28px; }
.ticks { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 32px; }
.ticks li { position: relative; padding-left: 28px; }
.ticks li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--ok); font-weight: bold; }

.signup { border-top: 4px solid var(--btn-to); }
.notice { text-align: center; padding: 48px 32px; }

/* Skisserna av gränssnittet
   ========================================================================== */
.mock { background: var(--card); border: 1px solid var(--border); border-radius: 8px; box-shadow: var(--card-shadow); overflow: hidden; font-size: .875em; }
.mock-bar { display: flex; align-items: center; gap: 6px; padding: 9px 12px; background: var(--box-bg); border-bottom: 1px solid var(--border); }
.mock-bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--border); }
.mock-bar span { margin-left: 8px; font-weight: bold; color: var(--heading); }
.mock-bar b { margin-left: auto; font-size: .75em; font-weight: normal; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.mock-body { padding: 18px; }
.m-muted { color: var(--muted); }
.m-small { font-size: .875em; }

.m-drop { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 22px 12px; border: 2px dashed var(--border); border-radius: 8px; color: var(--muted); }
.m-drop-icon { font-size: 1.5em; color: var(--link); }
.m-file { display: flex; justify-content: space-between; gap: 12px; margin: 16px 0 8px; }
.m-progress { height: 8px; margin-bottom: 6px; border-radius: 4px; background: var(--box-bg); overflow: hidden; }
.m-progress span { display: block; width: 68%; height: 100%; background: var(--btn-from); }

.wave { display: block; width: 100%; height: 84px; }
.wave-sel { fill: var(--accent-soft); }
.wave-on { fill: var(--btn-from); }
.wave-off { fill: var(--border); }
.wave-handle { fill: var(--btn-to); }
.m-times { display: flex; justify-content: space-between; margin: 8px 0 12px; padding: 0 21% 0 34%; font-size: .875em; color: var(--muted); white-space: nowrap; }
.m-buttons { display: flex; justify-content: center; gap: 8px; }
.m-btn { padding: 5px 12px; border: 1px solid var(--border); border-radius: 5px; color: var(--text); }
.m-btn-main { border-color: var(--btn-to); background: var(--btn-to); color: #fff; }

.m-label { margin: 12px 0 4px; font-size: .875em; font-weight: bold; color: var(--heading); }
.m-label:first-child { margin-top: 0; }
.m-ai { margin-left: 6px; padding: 1px 7px; border-radius: 10px; background: var(--accent-soft); color: var(--link); font-size: .8125em; font-weight: normal; }
.m-input { padding: 8px 10px; border: 1px solid var(--input-border); border-radius: 5px; background: var(--input-bg); color: var(--input-text); }
.m-lines i { display: block; height: 8px; margin: 5px 0; border-radius: 4px; background: var(--box-bg); }
.m-lines i.short { width: 60%; }

.m-published { font-weight: bold; color: var(--heading); }
.m-check { display: inline-block; width: 22px; height: 22px; margin-right: 6px; border-radius: 50%; background: var(--ok); color: #fff; line-height: 22px; text-align: center; }
.m-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 4px; }
.m-chips span { padding: 3px 10px; border-radius: 12px; background: var(--box-bg); font-size: .875em; }
.chart { display: block; width: 100%; height: auto; }
.chart-bar { fill: var(--btn-from); }
.chart-label { fill: var(--muted); font-size: 10px; font-family: Arial, sans-serif; }

/* Sidfot
   ========================================================================== */
#footer { margin-top: 50px; padding: 30px 16px; background: var(--footer-bg); text-align: center; }
#footer p, #footer a { color: #fff; }
#footer p { font-size: .75em; font-weight: bold; margin: 0; }
#footer a { text-decoration: underline; }

/* Responsivt
   ========================================================================== */
@media (max-width: 760px) {
    h1 { font-size: 1.6em; }
    .card { padding: 22px 18px; }
    .hero { flex-direction: column; gap: 20px; text-align: center; }
    .hero-logo { width: 200px; height: 200px; }
    .step { grid-template-columns: 1fr; gap: 16px; }
    .step:nth-of-type(odd) .step-text { order: 0; }
    .ticks { grid-template-columns: 1fr; }
    .section-title { margin-top: 32px; font-size: 1.4em; }
}
@media (max-width: 560px) {
    #top { padding: 8px 12px; gap: 10px; }
    #top .brand { gap: 10px; }
    #top .brand img { width: 44px; height: 44px; }
    #top .site-title { font-size: 1.05em; }
    #top .site-sub { display: none; }
    #top .top-cta { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
}
