/* ============================================================
   flyttaut.se – stilmall
   ============================================================ */

:root {
    --color-bg: #f6f8fc;
    --color-surface: #ffffff;
    --color-text: #1f2733;
    --color-muted: #5b6573;
    --color-primary: #2b6cff;
    --color-primary-dark: #1c4fcc;
    --color-accent: #ff7a59;
    --color-border: #e4e8f0;
    --color-success: #1c6b3a;
    --color-success-bg: #e6f6ec;
    --radius: 14px;
    --shadow: 0 8px 30px rgba(20, 30, 60, 0.07);
    --maxw: 1080px;
    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font);
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.6;
}

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

a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.25; color: #14203a; }
h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
h2 { font-size: clamp(1.3rem, 2.5vw, 1.7rem); margin-top: 1.8em; }

.skip-link {
    position: absolute;
    left: -999px;
    background: #fff;
    padding: 8px 14px;
    border-radius: 8px;
}
.skip-link:focus { left: 12px; top: 12px; z-index: 100; }

/* ---------- Header / Nav ---------- */
.site-header {
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    z-index: 50;
}
.site-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 66px;
}
.site-logo { display: flex; align-items: center; gap: 10px; font-weight: 800; color: #14203a; }
.site-logo:hover { text-decoration: none; }
.site-logo__mark { font-size: 1.5rem; }
.site-logo__text { font-size: 1.15rem; }

.site-nav { display: flex; gap: 4px; flex-wrap: wrap; }
.site-nav a {
    color: var(--color-muted);
    font-weight: 600;
    padding: 8px 12px;
    border-radius: 9px;
    font-size: 0.95rem;
}
.site-nav a:hover { background: #eef2fb; text-decoration: none; color: var(--color-primary); }
.site-nav a.is-active { background: #e7eeff; color: var(--color-primary-dark); }

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: 0;
    cursor: pointer;
    padding: 8px;
}
.nav-toggle span { width: 24px; height: 2px; background: #14203a; border-radius: 2px; }

/* ---------- Hero ---------- */
.hero {
    background: linear-gradient(135deg, #2b6cff 0%, #5d34d6 100%);
    color: #fff;
    padding: 64px 0 72px;
}
.hero h1 { color: #fff; margin: 0 0 12px; }
.hero p { font-size: 1.15rem; max-width: 620px; opacity: 0.95; margin: 0 0 24px; }
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-block;
    padding: 12px 22px;
    border-radius: 10px;
    font-weight: 700;
    border: 2px solid transparent;
    cursor: pointer;
    font-size: 1rem;
}
.btn-primary { background: var(--color-primary); color: #fff; }
.btn-primary:hover { background: var(--color-primary-dark); text-decoration: none; }
.btn-ghost { background: rgba(255,255,255,0.15); color: #fff; border-color: rgba(255,255,255,0.5); }
.btn-ghost:hover { background: rgba(255,255,255,0.25); text-decoration: none; }
.btn-outline { background: #fff; color: var(--color-primary); border-color: var(--color-primary); }
.btn-outline:hover { background: #eef2fb; text-decoration: none; }

/* ---------- Main layout ---------- */
.site-main { padding: 0 0 56px; }

.section { padding: 40px 0; }

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}
.card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    transition: transform 0.15s ease;
}
.card:hover { transform: translateY(-3px); }
.card h3 { margin: 0 0 8px; }
.card p { color: var(--color-muted); margin: 0 0 12px; }
.card__icon { font-size: 1.8rem; }

/* ---------- Article / page content ---------- */
.page-header {
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    padding: 40px 0;
}
.page-header h1 { margin: 0; }
.page-header .lead { color: var(--color-muted); font-size: 1.1rem; margin: 8px 0 0; }

.prose {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
    margin-top: 28px;
}
.prose ul { padding-left: 22px; }
.prose li { margin: 6px 0; }
.prose .callout {
    background: #fff7ed;
    border-left: 4px solid var(--color-accent);
    padding: 14px 18px;
    border-radius: 8px;
    margin: 22px 0 0;
}

.layout-2col { display: grid; grid-template-columns: 1fr; gap: 28px; }
@media (min-width: 960px) {
    .layout-2col { grid-template-columns: 1fr 300px; align-items: start; }
}
.sidebar { position: sticky; top: 84px; display: grid; gap: 20px; }

/* ---------- Checklist ---------- */
.checklist-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}
.checklist-progress {
    font-weight: 700;
    color: var(--color-primary-dark);
}
.checklist-group {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 8px 24px 16px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}
.checklist-group h2 { font-size: 1.2rem; }
.checklist-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px dashed var(--color-border);
}
.checklist-item:last-child { border-bottom: 0; }
.checklist-item input[type="checkbox"] {
    width: 22px; height: 22px; margin-top: 2px; cursor: pointer; flex: none;
    accent-color: var(--color-primary);
}
.checklist-item label { cursor: pointer; }
.checklist-item.is-done label { text-decoration: line-through; color: var(--color-muted); }

/* ---------- Links page ---------- */
.link-group {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    margin-bottom: 22px;
}
.link-group h2 { margin-top: 0; }
.link-list { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 12px; }
.link-list li {
    border: 1px solid var(--color-border);
    border-radius: 10px;
    padding: 14px 16px;
}
.link-list a { font-weight: 700; }
.link-list p { margin: 4px 0 0; color: var(--color-muted); font-size: 0.95rem; }

/* ---------- Forms ---------- */
.form-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    max-width: 620px;
}
.form-field { margin-bottom: 16px; }
.form-field label { display: block; font-weight: 700; margin-bottom: 6px; }
.form-field input,
.form-field textarea {
    width: 100%;
    padding: 11px 13px;
    border: 1px solid #ccd2e0;
    border-radius: 9px;
    font: inherit;
}
.form-field textarea { min-height: 140px; resize: vertical; }
.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.alert { padding: 14px 16px; border-radius: 10px; margin-bottom: 18px; }
.alert-success { background: var(--color-success-bg); color: var(--color-success); }
.alert-error { background: #fdecea; color: #8b1f1f; }

/* ---------- Ad slots ---------- */
.ad-slot {
    margin: 28px 0;
    text-align: center;
    min-height: 90px;
}
.ad-slot--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px dashed #cfd6e4;
    border-radius: 12px;
    color: #9aa3b4;
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: repeating-linear-gradient(45deg, #fafbfe, #fafbfe 10px, #f1f4fa 10px, #f1f4fa 20px);
}

/* ---------- Footer ---------- */
.site-footer {
    background: #111a2e;
    color: #c9d2e3;
    margin-top: 40px;
    padding: 40px 0 24px;
}
.site-footer__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}
@media (min-width: 720px) {
    .site-footer__inner { grid-template-columns: 1.5fr 1fr; }
}
.site-footer strong { color: #fff; font-size: 1.1rem; }
.site-footer p { color: #9aa6bd; margin: 8px 0 0; }
.site-footer__nav { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: flex-start; }
.site-footer__nav a { color: #c9d2e3; }
.site-footer__legal { margin-top: 24px; border-top: 1px solid #25324d; padding-top: 16px; color: #8593ad; }

/* ---------- Responsive nav ---------- */
@media (max-width: 820px) {
    .nav-toggle { display: flex; }
    .site-nav {
        display: none;
        position: absolute;
        top: 66px;
        left: 0;
        right: 0;
        flex-direction: column;
        background: var(--color-surface);
        border-bottom: 1px solid var(--color-border);
        padding: 12px 20px 18px;
        box-shadow: var(--shadow);
    }
    .site-nav.is-open { display: flex; }
}

/* ---------- Scenario-section (startsidan) ---------- */
.scenario-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
}
.scenario-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow);
    display: block;
    transition: transform 0.15s ease;
}
.scenario-card:hover { transform: translateY(-3px); text-decoration: none; }
.scenario-card__icon { font-size: 2rem; margin-bottom: 8px; }
.scenario-card h3 { margin: 0 0 6px; font-size: 1.05rem; }
.scenario-card p { color: var(--color-muted); margin: 0; font-size: 0.9rem; }

/* ---------- Tools section (startsidan) ---------- */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}
.tool-highlight {
    background: linear-gradient(135deg, #f0f5ff 0%, #e8f0ff 100%);
    border: 1px solid #c5d5ff;
    border-radius: var(--radius);
    padding: 26px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.tool-highlight h3 { margin: 0; color: var(--color-primary-dark); }
.tool-highlight p { margin: 0; color: #4a5c80; }
.tool-highlight .btn { align-self: flex-start; margin-top: 4px; }

/* ---------- Interactive tools (shared) ---------- */
.tool-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    margin-top: 28px;
}
.tool-input-row {
    display: flex;
    gap: 16px;
    align-items: flex-end;
    flex-wrap: wrap;
    margin-bottom: 8px;
}
.tool-label { display: block; font-weight: 700; margin-bottom: 6px; }
.tool-input-date {
    padding: 10px 13px;
    border: 1px solid #ccd2e0;
    border-radius: 9px;
    font: inherit;
    font-size: 1.05rem;
}
.tool-hint { color: var(--color-muted); font-size: 0.9rem; margin: 0 0 20px; }
.tool-section-title { margin-top: 0; font-size: 1.25rem; }

/* ---------- Tidslinje ---------- */
.timeline { margin-top: 32px; }
.tl-track { position: relative; padding-left: 36px; }
.tl-track::before {
    content: '';
    position: absolute;
    left: 14px;
    top: 10px;
    bottom: 10px;
    width: 2px;
    background: var(--color-border);
}
.tl-item {
    position: relative;
    margin-bottom: 28px;
}
.tl-dot {
    position: absolute;
    left: -36px;
    top: 4px;
    width: 28px;
    height: 28px;
    background: var(--color-surface);
    border: 2px solid var(--color-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
}
.tl-item--past .tl-dot { background: #f1f3f8; border-color: #ccd2e0; }
.tl-item--today .tl-dot { border-color: var(--color-primary); background: #e7eeff; }
.tl-content {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 16px 20px;
    box-shadow: 0 2px 8px rgba(20,30,60,.04);
}
.tl-item--past .tl-content { opacity: 0.6; }
.tl-item--today .tl-content { border-color: var(--color-primary); box-shadow: 0 0 0 3px rgba(43,108,255,.12); }
.tl-date { font-size: 0.85rem; color: var(--color-muted); margin-bottom: 4px; }
.tl-countdown {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 999px;
    background: #e7eeff;
    color: var(--color-primary-dark);
    font-size: 0.78rem;
    font-weight: 700;
    margin-left: 6px;
}
.tl-countdown--now { background: #fff7ed; color: var(--color-accent); }
.tl-countdown--past { background: #f1f3f8; color: #9aa3b4; }
.tl-label { margin: 0 0 10px; font-size: 1.05rem; }
.tl-tasks { padding-left: 18px; margin: 0; }
.tl-tasks li { margin: 5px 0; font-size: 0.95rem; }

/* ---------- Volymkalkylator ---------- */
.vol-category { margin-bottom: 20px; }
.vol-category h3 { font-size: 1rem; margin: 0 0 8px; border-bottom: 1px solid var(--color-border); padding-bottom: 6px; }
.vol-items { display: grid; gap: 6px; }
.vol-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: background 0.1s;
}
.vol-item:hover { background: #f4f6fb; }
.vol-item input[type="checkbox"] { width: 18px; height: 18px; flex: none; accent-color: var(--color-primary); }
.vol-badge {
    flex: none;
    font-size: 0.75rem;
    color: var(--color-muted);
    background: #f1f3f8;
    padding: 2px 8px;
    border-radius: 999px;
    white-space: nowrap;
}
.vol-item:has(input:checked) { background: #e7eeff; border-color: #b5caff; }
.vol-item:has(input:checked) .vol-badge { background: #c5d5ff; color: var(--color-primary-dark); }

.vol-result {
    background: var(--color-surface);
    border: 2px solid var(--color-primary);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow);
    position: sticky;
    top: 84px;
}
.vol-result__num {
    font-size: 2.4rem;
    font-weight: 800;
    color: var(--color-primary-dark);
    line-height: 1;
}
.vol-result__label { color: var(--color-muted); margin: 4px 0 12px; }
.vol-result__rec { text-align: left; font-size: 0.95rem; }
.vol-rec-icon { font-size: 2rem; margin-bottom: 6px; }
.vol-selected-list { padding-left: 18px; margin: 6px 0 0; font-size: 0.85rem; color: var(--color-muted); }

/* ---------- Print ---------- */
@media print {
    .site-header,
    .site-footer,
    .ad-slot,
    .checklist-toolbar .btn,
    .nav-toggle,
    .skip-link { display: none !important; }

    body { background: #fff; color: #000; }
    .prose, .checklist-group, .card { box-shadow: none; border: 1px solid #ccc; }
    .checklist-item input[type="checkbox"] { -webkit-appearance: checkbox; appearance: checkbox; }
    a { color: #000; text-decoration: none; }
    .checklist-print-title { display: block !important; }
    .tool-input-row, #timeline-btn, #vol-reset, .vol-result { display: none !important; }
    .tl-item--past { opacity: 1 !important; }
    .tl-content { box-shadow: none; border: 1px solid #ccc; }
    .tl-track::before { background: #bbb; }
}
.checklist-print-title { display: none; }
