/*
 * Peepz – webbplatsen (A50). HTML och CSS, inga typsnitt eller bilder från andra
 * webbplatser. Det enda skriptet är frågan om kakor (consent.js, A77). Färgerna följer
 * appen: varumärkesrött och familjemedlemmarnas färger (utvecklingsplanen §4.3).
 */

:root {
    color-scheme: light dark;

    --bg: #fffaf5;
    --bg-tint: #fff2ea;
    --surface: #ffffff;
    --surface-2: #f6f1ec;
    --ink: #1f1b18;
    --muted: #6b605a;
    --line: rgba(31, 27, 24, .09);

    --brand: #fc2913;
    --accent: #e0240e;          /* knappar – vit text klarar kontrastkravet */
    --accent-ink: #c41f0b;      /* röd text på ljus botten */
    --accent-soft: #ffe6df;

    --anna: #ff2d55;
    --robin: #007aff;
    --ella: #ff9500;
    --leo: #34c759;
    --purple: #af52de;
    --green-soft: #dcf5e1;
    --green-ink: #1c7a33;
    --purple-soft: #f4e4fb;
    --purple-ink: #8a2fb3;

    /* Appens eget utseende i mockupperna */
    --ios-bg: #f2f2f7;
    --ios-card: #ffffff;
    --ios-label: #000000;
    --ios-secondary: rgba(60, 60, 67, .62);
    --ios-separator: rgba(60, 60, 67, .14);

    --map-land: #f1ede4;
    --map-park: #cfe8c4;
    --map-water: #bcdcf2;
    --map-road: #ffffff;
    --map-road-edge: #e2dccf;

    --shadow-sm: 0 1px 2px rgba(31, 27, 24, .06);
    --shadow: 0 1px 2px rgba(31, 27, 24, .05), 0 18px 40px -18px rgba(31, 27, 24, .28);
    --shadow-lg: 0 2px 6px rgba(31, 27, 24, .06), 0 40px 80px -30px rgba(31, 27, 24, .4);

    --radius: 28px;
    --radius-sm: 18px;
    --max: 1180px;
    --gutter: clamp(16px, 4vw, 32px);

    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-round: ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #141110;
        --bg-tint: #1d1714;
        --surface: #201b18;
        --surface-2: #2a2420;
        --ink: #f8f3ef;
        --muted: #b7aca5;
        --line: rgba(255, 255, 255, .1);

        --accent: #f0321b;
        --accent-ink: #ff7b67;
        --accent-soft: rgba(252, 41, 19, .18);

        --green-soft: rgba(52, 199, 89, .18);
        --green-ink: #6bd98a;
        --purple-soft: rgba(175, 82, 222, .22);
        --purple-ink: #d89cf2;

        --ios-bg: #000000;
        --ios-card: #1c1c1e;
        --ios-label: #ffffff;
        --ios-secondary: rgba(235, 235, 245, .6);
        --ios-separator: rgba(84, 84, 88, .55);

        --map-land: #2b2a27;
        --map-park: #2f4a2c;
        --map-water: #1f3b52;
        --map-road: #45423d;
        --map-road-edge: #3a3834;

        --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
        --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 18px 40px -18px rgba(0, 0, 0, .7);
        --shadow-lg: 0 2px 6px rgba(0, 0, 0, .3), 0 40px 80px -30px rgba(0, 0, 0, .8);
    }
}

/* ---------- Grund ---------- */

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font: 17px/1.55 var(--font);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
[hidden] { display: none !important; }
a { color: var(--accent-ink); text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3 { font-family: var(--font-round); letter-spacing: -.02em; line-height: 1.1; margin: 0; }
h1 { font-size: clamp(2.5rem, 6.4vw, 4.6rem); font-weight: 800; letter-spacing: -.035em; }
h2 { font-size: clamp(2rem, 4.4vw, 3.2rem); font-weight: 800; letter-spacing: -.03em; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
section[id] { scroll-margin-top: 76px; }

.skip {
    position: absolute; left: 16px; top: -60px; z-index: 100;
    background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 12px; text-decoration: none;
}
.skip:focus { top: 12px; }

.visually-hidden {
    position: absolute !important; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* ---------- Sidhuvud ---------- */

.site-header {
    position: sticky; top: 0; z-index: 50;
    background: color-mix(in srgb, var(--bg) 78%, transparent);
    -webkit-backdrop-filter: saturate(1.6) blur(18px);
    backdrop-filter: saturate(1.6) blur(18px);
    border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; gap: 24px; height: 68px; }

.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.logo svg { width: 34px; height: 34px; flex: none; }
.logo span { font-family: var(--font-round); font-weight: 800; font-size: 1.45rem; letter-spacing: -.03em; }

.site-nav { display: flex; gap: 4px; margin-left: 8px; }
.site-nav a {
    color: var(--muted); text-decoration: none; font-weight: 600; font-size: .95rem;
    padding: 8px 12px; border-radius: 999px;
}
.site-nav a:hover { color: var(--ink); background: var(--surface-2); }

.header-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.lang {
    color: var(--muted); font-weight: 700; font-size: .85rem; text-decoration: none;
    border: 1px solid var(--line); padding: 7px 12px; border-radius: 999px;
}
.lang:hover { color: var(--ink); border-color: var(--muted); }

.button {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 48px; padding: 0 22px; border-radius: 999px;
    background: var(--accent); color: #fff; font-weight: 700; text-decoration: none;
    box-shadow: 0 8px 20px -10px rgba(224, 36, 14, .8);
    transition: transform .15s ease, box-shadow .15s ease;
}
.button:hover { transform: translateY(-1px); box-shadow: 0 12px 26px -10px rgba(224, 36, 14, .9); }
.button.small { min-height: 38px; padding: 0 16px; font-size: .92rem; }
.button.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.button.ghost:hover { box-shadow: inset 0 0 0 1.5px var(--muted); }

button.button { border: 0; font: inherit; font-weight: 700; cursor: pointer; }

.button, .lang { white-space: nowrap; }

/* Tills appen finns i App Store: en upplysning i stället för knappen "Hämta appen" */
.soon {
    display: inline-flex; align-items: center; gap: 8px;
    min-height: 38px; padding: 0 14px; border-radius: 999px;
    background: var(--accent-soft); color: var(--accent-ink);
    font-weight: 700; font-size: .92rem; white-space: nowrap;
}
.soon::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--brand); }

@media (max-width: 1000px) {
    .site-nav { display: none; }
}
@media (max-width: 420px) {
    .eyebrow .dots { display: none; }
    .eyebrow { padding: 6px 14px; }
    .site-header .wrap { gap: 12px; }
    .logo span { font-size: 1.3rem; }
    .lang { padding: 6px 10px; }
    .button.small { padding: 0 13px; }
    .soon { padding: 0 12px; font-size: .85rem; }
    .soon::before { display: none; }
}
/* Under 360 px får loggan, språket och "Kommer snart" inte plats – hjältens App Store-märke säger detsamma */
@media (max-width: 359px) {
    .soon { display: none; }
}

/* ---------- App Store-knappen ---------- */

.store-badge {
    display: inline-flex; align-items: center; gap: 10px;
    min-height: 56px; padding: 0 22px 0 18px; border-radius: 14px;
    background: #000; color: #fff; text-decoration: none;
    box-shadow: 0 10px 24px -12px rgba(0, 0, 0, .7);
    transition: transform .15s ease;
}
a.store-badge:hover { transform: translateY(-1px); }
.store-badge svg { width: 26px; height: 26px; flex: none; }
.store-badge span { display: flex; flex-direction: column; line-height: 1.05; }
.store-badge small { font-size: .72rem; font-weight: 500; letter-spacing: .01em; }
.store-badge strong { font-size: 1.35rem; font-weight: 600; letter-spacing: -.01em; }
@media (prefers-color-scheme: dark) {
    .store-badge { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .35); }
}

/* ---------- Hero ---------- */

.hero { position: relative; padding: clamp(48px, 8vw, 96px) 0 0; text-align: center; overflow: hidden; }
.hero::before {
    content: ""; position: absolute; inset: -20% -10% auto; height: 80%; z-index: -1;
    background:
        radial-gradient(40% 55% at 18% 30%, color-mix(in srgb, var(--ella) 22%, transparent), transparent 70%),
        radial-gradient(35% 50% at 82% 20%, color-mix(in srgb, var(--anna) 18%, transparent), transparent 70%),
        radial-gradient(30% 45% at 60% 70%, color-mix(in srgb, var(--brand) 12%, transparent), transparent 70%);
    filter: blur(10px);
}

.eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 6px 14px 6px 8px; border-radius: 999px;
    background: var(--surface); box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
    font-size: .9rem; font-weight: 600; color: var(--muted);
}
.dots { display: inline-flex; }
.dots i { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--surface); margin-left: -6px; }
.dots i:first-child { margin-left: 0; }

.hero h1 { margin: 22px auto 0; max-width: 14ch; }
.hero h1 em { font-style: normal; color: var(--brand); white-space: nowrap; }
.hero .lead { margin: 22px auto 0; max-width: 40rem; font-size: clamp(1.08rem, 1.8vw, 1.28rem); color: var(--muted); }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px; margin-top: 32px; }
.promise {
    display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px;
    margin: 26px 0 0; padding: 0; list-style: none; color: var(--muted); font-size: .95rem; font-weight: 600;
}
.promise li { display: inline-flex; align-items: center; gap: 7px; }
.promise svg { width: 18px; height: 18px; color: var(--green-ink); }

.hero-media { position: relative; margin: clamp(40px, 6vw, 64px) auto 0; max-width: 1240px; padding: 0 var(--gutter); }
.hero-photo {
    width: 100%; aspect-ratio: 1672 / 941; object-fit: cover; object-position: 50% 45%;
    border-radius: clamp(24px, 3vw, 40px); box-shadow: var(--shadow-lg);
    background: var(--surface-2);
}
@media (max-width: 640px) {
    .hero-photo { aspect-ratio: 4 / 5; object-position: 54% 50%; }
}

.float {
    position: absolute; text-align: left;
    background: color-mix(in srgb, var(--surface) 90%, transparent);
    -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
    border-radius: 22px; box-shadow: var(--shadow); padding: 14px 16px;
    animation: bob 6s ease-in-out infinite;
}
.float.notice { left: calc(var(--gutter) + 3%); top: 9%; display: flex; gap: 12px; align-items: center; width: min(310px, 60%); }
.float.poll { right: calc(var(--gutter) + 3%); bottom: 10%; width: min(270px, 60%); animation-delay: -3s; }
.float .app-icon { width: 40px; height: 40px; flex: none; }
.float .meta { font-size: .78rem; color: var(--muted); font-weight: 600; }
.float strong { display: block; font-size: .98rem; }
.float p { font-size: .88rem; color: var(--muted); }
@keyframes bob { 50% { transform: translateY(-8px); } }
@media (max-width: 640px) {
    .float.notice { top: auto; bottom: 5%; left: calc(var(--gutter) + 12px); width: auto; right: calc(var(--gutter) + 12px); }
    .float.poll { display: none; }
}

/* ---------- Fem frågor ---------- */

.questions { padding: clamp(64px, 9vw, 112px) 0 0; }
.questions header { text-align: center; max-width: 44rem; margin: 0 auto; }
.questions header p { margin-top: 14px; color: var(--muted); font-size: 1.1rem; }
.q-list {
    display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px;
    margin: 40px 0 0; padding: 0; list-style: none; counter-reset: q;
}
.q-list li {
    background: var(--surface); border-radius: var(--radius-sm); padding: 20px 18px;
    box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
    font-family: var(--font-round); font-weight: 700; font-size: 1.08rem; line-height: 1.25;
}
.q-list li::before {
    counter-increment: q; content: counter(q);
    display: grid; place-items: center; width: 30px; height: 30px; margin-bottom: 14px;
    border-radius: 50%; background: var(--c, var(--brand)); color: #fff; font-size: .9rem;
}
.q-list li:nth-child(1) { --c: var(--brand); }
.q-list li:nth-child(2) { --c: var(--robin); }
.q-list li:nth-child(3) { --c: var(--leo); }
.q-list li:nth-child(4) { --c: var(--ella); }
.q-list li:nth-child(5) { --c: var(--purple); }
@media (max-width: 900px) { .q-list { grid-template-columns: repeat(2, 1fr); } .q-list li:last-child { grid-column: span 2; } }
@media (max-width: 420px) { .q-list { grid-template-columns: 1fr; } .q-list li:last-child { grid-column: auto; } }

/* ---------- Funktionsavsnitt ---------- */

.feature { padding: clamp(72px, 10vw, 128px) 0 0; }
.feature .wrap { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(32px, 6vw, 88px); align-items: center; }
.feature.flip .copy { order: 2; }
@media (max-width: 900px) {
    .feature .wrap { grid-template-columns: minmax(0, 1fr); }
    .feature.flip .copy { order: 0; }
}

.kicker {
    display: inline-block; margin-bottom: 14px; padding: 5px 12px; border-radius: 999px;
    font-size: .8rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
    background: color-mix(in srgb, var(--k, var(--brand)) 14%, transparent);
    color: color-mix(in srgb, var(--k, var(--brand)) 70%, var(--ink));
}
.copy .intro { margin-top: 18px; font-size: 1.13rem; color: var(--muted); }
.points { margin: 28px 0 0; padding: 0; list-style: none; display: grid; gap: 18px; }
.points li { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start; }
.points .ico {
    width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center;
    background: color-mix(in srgb, var(--k, var(--brand)) 14%, transparent);
    color: color-mix(in srgb, var(--k, var(--brand)) 80%, var(--ink));
}
.points .ico svg { width: 22px; height: 22px; }
.points h3 { font-size: 1.06rem; margin-top: 2px; }
.points p { color: var(--muted); font-size: .98rem; margin-top: 3px; }

.note {
    margin-top: 22px; padding: 12px 16px; border-radius: 14px;
    background: var(--surface-2); color: var(--muted); font-size: .92rem;
}

/* Märket på det som ingår i Peepz Premium – som i appen – och på det som alltid är gratis */
.badge {
    display: inline-flex; align-items: center; gap: 4px; vertical-align: 2px; margin-left: 6px;
    padding: 2px 8px 2px 6px; border-radius: 999px;
    font-family: var(--font); font-size: .7rem; font-weight: 800; letter-spacing: .01em; line-height: 1.5;
    background: var(--accent-soft); color: var(--accent-ink); white-space: nowrap;
}
.badge svg { width: 12px; height: 12px; flex: none; }
.badge.free { background: var(--green-soft); color: var(--green-ink); padding-left: 8px; }
.kicker + .badge { vertical-align: 1px; margin-bottom: 14px; }

/* ---------- Scen med mockupper ---------- */

.stage {
    position: relative; border-radius: calc(var(--radius) + 8px);
    padding: clamp(20px, 3vw, 36px);
    background: linear-gradient(160deg, color-mix(in srgb, var(--k, var(--brand)) 16%, var(--bg-tint)), var(--bg-tint));
    display: grid; gap: 16px;
}

.card {
    background: var(--ios-card); color: var(--ios-label);
    border-radius: 20px; box-shadow: var(--shadow);
    padding: 14px 16px; font-size: .92rem;
}
.card .title { font-weight: 700; font-size: 1rem; }
.card .sub { color: var(--ios-secondary); font-size: .8rem; }
.section-label {
    font-size: .72rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
    color: var(--ios-secondary); margin: 0 0 8px;
}

.row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.row + .row { border-top: 1px solid var(--ios-separator); }
.row .grow { flex: 1; min-width: 0; }
.row .time { color: var(--accent-ink); font-weight: 700; font-variant-numeric: tabular-nums; width: 44px; }

.av {
    display: inline-grid; place-items: center; flex: none;
    width: 22px; height: 22px; border-radius: 50%;
    color: #fff; font-size: .68rem; font-weight: 700; background: var(--c, var(--muted));
}
.av.lg { width: 36px; height: 36px; font-size: .95rem; }
.av.anna { --c: var(--anna); } .av.robin { --c: var(--robin); } .av.ella { --c: var(--ella); } .av.leo { --c: var(--leo); } .av.gun { --c: var(--purple); }
.avs { display: inline-flex; }
.avs .av { border: 2px solid var(--ios-card); margin-left: -6px; }
.avs .av:first-child { margin-left: 0; }

.check {
    width: 22px; height: 22px; flex: none; border-radius: 50%;
    border: 2px solid color-mix(in srgb, var(--ios-secondary) 70%, transparent);
}
.check.done { background: var(--leo); border-color: var(--leo); position: relative; }
.check.done::after {
    content: ""; position: absolute; left: 6px; top: 2px; width: 5px; height: 10px;
    border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg);
}
.struck { text-decoration: line-through; color: var(--ios-secondary); }

.pill {
    display: inline-flex; align-items: center; padding: 3px 9px; border-radius: 999px;
    font-size: .72rem; font-weight: 700; white-space: nowrap;
}
.pill.red { background: var(--accent-soft); color: var(--accent-ink); }
.pill.green { background: var(--green-soft); color: var(--green-ink); }
.pill.purple { background: var(--purple-soft); color: var(--purple-ink); }
.pill.gray { background: color-mix(in srgb, var(--ios-secondary) 16%, transparent); color: var(--ios-secondary); }
.dim { color: var(--ios-secondary); font-size: .78rem; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chip {
    padding: 6px 11px; border-radius: 999px; font-size: .78rem; font-weight: 600;
    background: color-mix(in srgb, var(--ios-secondary) 12%, transparent);
}
.chip.on { background: var(--accent); color: #fff; }

.poll-opt {
    position: relative; overflow: hidden; display: flex; justify-content: space-between; align-items: center;
    padding: 9px 12px; border-radius: 12px; margin-top: 8px; font-weight: 600;
    background: color-mix(in srgb, var(--ios-secondary) 10%, transparent);
}
.poll-opt::before {
    content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w, 0%);
    background: color-mix(in srgb, var(--brand) 16%, transparent);
}
.poll-opt.mine { box-shadow: inset 0 0 0 2px var(--brand); }
.poll-opt > * { position: relative; }
.poll-opt .right { display: inline-flex; align-items: center; gap: 8px; color: var(--ios-secondary); font-size: .82rem; }

.progress { height: 8px; border-radius: 999px; background: color-mix(in srgb, var(--ios-secondary) 16%, transparent); overflow: hidden; margin-top: 10px; }
.progress i { display: block; height: 100%; width: var(--p, 40%); border-radius: inherit; background: var(--ella); }

/* Planera: tre kort som överlappar */
.stage.plan { grid-template-columns: 1fr 1fr; align-items: start; }
.stage.plan .cal { grid-column: 1 / -1; }
@media (max-width: 520px) { .stage.plan { grid-template-columns: 1fr; } }

/* Måltider: veckan överst, dagen och ingredienserna under */
.stage.meals { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; }
.stage.meals .week { grid-column: 1 / -1; }
@media (max-width: 1100px) and (min-width: 901px), (max-width: 560px) { .stage.meals { grid-template-columns: minmax(0, 1fr); } }
.week-head { display: flex; align-items: center; gap: 8px; padding-bottom: 6px; }
.week-head .title { flex: 1; min-width: 0; }
.week-head .arrows { color: var(--accent-ink); font-weight: 800; font-size: 1.1rem; letter-spacing: 10px; }
.week .row { padding: 8px 0; align-items: flex-start; }
.week .day { width: 34px; flex: none; line-height: 1.1; }
.week .day small { display: block; font-size: .68rem; font-weight: 600; }
.week .day b { font-size: 1.05rem; font-variant-numeric: tabular-nums; }
.week .today .day { color: var(--accent-ink); }
.week .cook { display: flex; align-items: center; gap: 6px; margin-top: 2px; }
.week .cook .av { width: 16px; height: 16px; font-size: .55rem; }
.week .open-poll { color: var(--accent-ink); font-size: .74rem; font-weight: 700; margin-top: 2px; }
.week .row .pill { margin-top: 2px; }
.receipt { display: flex; align-items: center; gap: 6px; margin-top: 10px; color: var(--green-ink); font-weight: 700; font-size: .8rem; }
.receipt svg { width: 16px; height: 16px; flex: none; }

/* ---------- Telefon ---------- */

.phone {
    position: relative; width: min(300px, 100%); margin: 0 auto;
    aspect-ratio: 300 / 620; border-radius: 48px; padding: 10px;
    background: #1b1b1d; box-shadow: var(--shadow-lg), inset 0 0 0 2px #3a3a3c;
}
.phone .screen {
    position: relative; height: 100%; border-radius: 39px; overflow: hidden;
    background: var(--ios-bg); color: var(--ios-label); font-size: .8rem;
    display: flex; flex-direction: column;
}
.phone .island {
    position: absolute; top: 10px; left: 50%; transform: translateX(-50%);
    width: 90px; height: 26px; border-radius: 20px; background: #000; z-index: 3;
}
.phone .status { display: flex; justify-content: space-between; padding: 14px 26px 0; font-weight: 700; font-size: .78rem; }
.phone .status span:last-child { letter-spacing: 2px; }
.phone .body { padding: 18px 14px 14px; display: grid; gap: 10px; }
.phone .big { font-family: var(--font); font-size: 1.7rem; font-weight: 800; letter-spacing: -.02em; }

.map { border-radius: 18px; overflow: hidden; box-shadow: var(--shadow-sm); }
.map svg { width: 100%; height: auto; }
.map .land { fill: var(--map-land); }
.map .park { fill: var(--map-park); }
.map .water { fill: var(--map-water); }
.map .road { stroke: var(--map-road); fill: none; stroke-linecap: round; }
.map .road-edge { stroke: var(--map-road-edge); fill: none; stroke-linecap: round; }
.map .route { stroke: var(--ella); fill: none; stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; }
.map .pin-ring { fill: color-mix(in srgb, var(--ella) 25%, transparent); animation: pulse 2.4s ease-out infinite; transform-origin: center; transform-box: fill-box; }
.map text { font: 700 11px var(--font); fill: #fff; }
.map .label { font: 700 9px var(--font); fill: var(--ios-label); }
@keyframes pulse { from { transform: scale(.6); opacity: 1; } to { transform: scale(1.6); opacity: 0; } }

.safety-stage { grid-template-columns: auto minmax(0, 1fr); align-items: center; }
.safety-stage .phone { width: 260px; }
.safety-cards { display: grid; gap: 16px; margin-left: -48px; position: relative; z-index: 2; }
.safety-stage .sos { background: #e5261a; color: #fff; box-shadow: 0 20px 40px -18px rgba(229, 38, 26, .9); }
.safety-stage .sos .sub { color: rgba(255, 255, 255, .85); }
@media (max-width: 1100px) and (min-width: 901px), (max-width: 560px) {
    .safety-stage { grid-template-columns: 1fr; }
    .safety-cards { margin: -120px 0 0; padding: 0 8px; }
    .safety-stage .phone { width: min(280px, 100%); }
}
.sos .head { display: flex; gap: 10px; align-items: center; }
.sos svg { width: 22px; height: 22px; flex: none; }

.toggle {
    width: 44px; height: 26px; border-radius: 999px; background: var(--leo); position: relative; flex: none;
}
.toggle::after { content: ""; position: absolute; right: 2px; top: 2px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); }

/* Familj */
.stage.fam { grid-template-columns: 1fr 1fr; align-items: start; }
.stage.fam .members { grid-column: 1 / -1; }
@media (max-width: 560px) { .stage.fam { grid-template-columns: 1fr; } }

.weeks { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; margin-top: 12px; }
.weeks i { height: 10px; border-radius: 3px; background: var(--c); opacity: .85; }
.weeks .a { --c: var(--anna); } .weeks .b { --c: var(--robin); }
.legend { display: flex; gap: 14px; margin-top: 10px; font-size: .75rem; color: var(--ios-secondary); }
.legend span::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; background: var(--c); }

.invite-link {
    display: flex; align-items: center; gap: 8px; margin-top: 10px; padding: 9px 12px; border-radius: 12px;
    background: color-mix(in srgb, var(--ios-secondary) 10%, transparent); font-size: .8rem; font-weight: 600;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* Överallt: låsskärm, widgetar och klocka */
.everywhere { grid-template-columns: minmax(0, 1fr); }

.lock {
    border-radius: 34px; padding: 22px 16px 18px; color: #fff;
    background:
        radial-gradient(80% 60% at 20% 0%, #ff8a5c, transparent 60%),
        radial-gradient(70% 60% at 100% 30%, #c2185b, transparent 60%),
        linear-gradient(180deg, #5b2a86, #231942);
    box-shadow: var(--shadow-lg);
}
.lock .clock { text-align: center; font-family: var(--font-round); font-weight: 600; font-size: 3.2rem; line-height: 1; letter-spacing: -.02em; }
.lock .date { text-align: center; font-weight: 600; font-size: .9rem; opacity: .9; margin-bottom: 16px; }
.glass {
    background: rgba(255, 255, 255, .16); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
    border-radius: 20px; padding: 12px 14px; font-size: .82rem;
}
.glass + .glass { margin-top: 10px; }
.glass .dim { color: rgba(255, 255, 255, .75); }
.live { display: flex; align-items: center; gap: 12px; }
.live > div:not(.eta) { flex: 1; min-width: 0; }
.live b, .live .dim { display: block; }
.live .eta { margin-left: auto; text-align: right; font-weight: 700; font-size: 1.1rem; font-variant-numeric: tabular-nums; }
.live .progress { background: rgba(255, 255, 255, .25); }
.live-btn { display: inline-block; margin-top: 10px; padding: 6px 12px; border-radius: 999px; background: rgba(255, 255, 255, .9); color: #111; font-weight: 700; font-size: .75rem; }
.widgets { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; margin-top: 10px; }
.widgets .glass { margin: 0; }
.widgets .glass + .glass { margin: 0; }
.widgets b { display: block; font-size: .95rem; }
.widgets span { display: block; }

/* Apple Watch: boetten är 39 × 46 mm. Listan klipps nedtill, som på klockan där man scrollar. */
.watch {
    position: relative; width: 190px; aspect-ratio: 39 / 46; margin: 0 auto; padding: 9px;
    border-radius: 50px / 54px; background: #1b1b1d;
    box-shadow: var(--shadow-lg), inset 0 0 0 2px #3a3a3c;
}
.watch::before { content: ""; position: absolute; right: -6px; top: 26%; width: 8px; height: 17%; border-radius: 4px; background: #48484a; }
.watch::after { content: ""; position: absolute; right: -3px; top: 52%; width: 4px; height: 22%; border-radius: 2px; background: #3a3a3c; }
.watch .face {
    height: 100%; overflow: hidden; border-radius: 42px / 46px; background: #000; color: #fff;
    padding: 16px 12px 0; font-size: .66rem; line-height: 1.3;
}
.watch .face .t { display: flex; justify-content: space-between; padding: 0 4px; font-weight: 700; color: var(--brand); font-size: .74rem; }
.watch .face .t span:last-child { color: #fff; }
.watch .w-row { background: #1c1c1e; border-radius: 12px; padding: 6px 9px; margin-top: 6px; }
.watch .w-row b { display: block; font-size: .72rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.watch .w-row span { color: rgba(235, 235, 245, .6); }
.everywhere .side { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 24px; align-items: center; }
@media (max-width: 440px) { .everywhere .side { grid-template-columns: 1fr; justify-items: center; } }
.siri { display: grid; gap: 8px; width: 100%; justify-items: start; }
.siri .chip { background: var(--ios-card); color: var(--ios-label); box-shadow: var(--shadow-sm); padding: 9px 14px; font-size: .82rem; }

/* ---------- Alla funktioner ---------- */

.all { padding: clamp(80px, 11vw, 140px) 0 0; }
.all header { max-width: 44rem; }
.all header p { margin-top: 14px; color: var(--muted); font-size: 1.1rem; }
.grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px;
    margin: 40px 0 0; padding: 0; list-style: none;
}
.grid li {
    background: var(--surface); border-radius: var(--radius-sm); padding: 20px;
    box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
}
.grid .ico {
    width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 14px;
    background: color-mix(in srgb, var(--k, var(--brand)) 14%, transparent);
    color: color-mix(in srgb, var(--k, var(--brand)) 80%, var(--ink));
}
.grid .ico svg { width: 21px; height: 21px; }
.grid h3 { font-size: 1.02rem; }
.grid p { color: var(--muted); font-size: .94rem; margin-top: 4px; }

/* ---------- Peepz Premium: gratis mot Premium, priserna och köpet ---------- */

.premium { padding: clamp(80px, 11vw, 140px) 0 0; }
.premium header { max-width: 46rem; }
.premium header p { margin-top: 14px; color: var(--muted); font-size: 1.1rem; }
.premium-body {
    display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px;
    margin-top: 40px; align-items: start;
}
@media (max-width: 960px) { .premium-body { grid-template-columns: minmax(0, 1fr); } }

.compare-card {
    background: var(--surface); border-radius: var(--radius-sm); overflow: hidden;
    box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
}
.compare { width: 100%; border-collapse: collapse; font-size: .95rem; }
.compare th, .compare td { padding: 13px 14px; border-bottom: 1px solid var(--line); text-align: center; vertical-align: middle; }
.compare tbody tr:last-child > * { border-bottom: 0; }
.compare thead th { font-family: var(--font-round); font-size: 1.02rem; font-weight: 800; padding-top: 18px; padding-bottom: 14px; white-space: nowrap; }
.compare thead th:first-child { text-align: left; font-family: var(--font); font-size: .78rem; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.compare th[scope="row"] { text-align: left; font-weight: 700; }
.compare th[scope="row"] span { display: block; margin-top: 2px; font-weight: 400; font-size: .85rem; color: var(--muted); }
.compare .col-free { width: 22%; }
.compare .col-premium { width: 22%; background: color-mix(in srgb, var(--brand) 6%, transparent); }
.compare thead .col-premium { color: var(--accent-ink); }
.compare thead .col-premium svg { display: inline-block; width: 16px; height: 16px; vertical-align: -2px; margin-right: 4px; }
.compare td svg { width: 20px; height: 20px; margin: 0 auto; }
.compare .yes { color: var(--green-ink); }
.compare .no { color: color-mix(in srgb, var(--muted) 55%, transparent); }
.compare td small { display: block; font-size: .82rem; line-height: 1.3; color: var(--muted); }
.compare .col-premium small { color: var(--ink); font-weight: 600; }
@media (max-width: 560px) {
    .compare { font-size: .9rem; }
    .compare th, .compare td { padding: 12px 8px; }
    .compare th:first-child { padding-left: 14px; }
    .compare thead th { font-size: .95rem; }
    .compare thead .col-premium svg { display: none; }
    .compare th[scope="row"] span { font-size: .8rem; }
    .compare .col-free, .compare .col-premium { width: 25%; }
}

.pricing {
    background: var(--surface); border-radius: var(--radius-sm); padding: 22px;
    box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
}
.pricing h3 { font-size: 1.15rem; }
.pricing > p { margin-top: 6px; color: var(--muted); font-size: .95rem; }
.trial {
    display: inline-flex; align-items: center; gap: 6px; margin-top: 14px; padding: 6px 12px; border-radius: 999px;
    background: var(--green-soft); color: var(--green-ink); font-weight: 800; font-size: .85rem;
}
.trial svg { width: 16px; height: 16px; }
.plans { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 10px; }
.plans li {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    padding: 14px 16px; border-radius: 16px; background: var(--bg);
    box-shadow: inset 0 0 0 1px var(--line);
}
.plans li.best { background: color-mix(in srgb, var(--brand) 6%, var(--surface)); box-shadow: inset 0 0 0 2px var(--accent); }
.plans .period { font-family: var(--font-round); font-weight: 800; font-size: 1.08rem; }
.plans .period .pill { margin-left: 6px; vertical-align: 2px; background: var(--accent); color: #fff; }
.plans .per-month { display: block; color: var(--muted); font-size: .85rem; }
.plans .price { text-align: right; font-family: var(--font-round); font-weight: 800; font-size: 1.45rem; line-height: 1.1; white-space: nowrap; }
.plans .price small { display: block; font-family: var(--font); font-weight: 600; font-size: .78rem; color: var(--muted); }
.pricing .fine { margin-top: 14px; color: var(--muted); font-size: .85rem; }

.how { margin-top: 20px; }
.how h3 { font-size: 1.3rem; }
.steps {
    display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px;
    margin: 20px 0 0; padding: 0; list-style: none; counter-reset: step;
}
.steps li {
    background: var(--surface); border-radius: var(--radius-sm); padding: 20px 18px;
    box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
}
.steps li::before {
    counter-increment: step; content: counter(step);
    display: grid; place-items: center; width: 30px; height: 30px; margin-bottom: 14px;
    border-radius: 50%; background: var(--accent); color: #fff; font-weight: 800; font-size: .9rem;
}
.steps strong { display: block; font-family: var(--font-round); font-size: 1.05rem; line-height: 1.25; }
.steps span { display: block; margin-top: 6px; color: var(--muted); font-size: .94rem; }
@media (max-width: 960px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .steps { grid-template-columns: minmax(0, 1fr); } }
.how .note { margin-top: 14px; }

/* ---------- Integritet ---------- */

.privacy-band { padding: clamp(80px, 11vw, 140px) 0 0; }
.privacy-band .panel {
    position: relative; overflow: hidden; border-radius: calc(var(--radius) + 12px);
    padding: clamp(32px, 6vw, 72px); color: #fff;
    background:
        radial-gradient(60% 80% at 100% 0%, rgba(255, 149, 0, .45), transparent 60%),
        radial-gradient(50% 70% at 0% 100%, rgba(255, 45, 85, .4), transparent 60%),
        linear-gradient(135deg, #e0240e, #b3170a);
}
.privacy-band .panel > p { margin-top: 16px; max-width: 40rem; font-size: 1.13rem; color: rgba(255, 255, 255, .88); }
.privacy-band h2 { max-width: 16ch; }
.vows { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 36px 0 0; padding: 0; list-style: none; }
.vows li { background: rgba(255, 255, 255, .12); border-radius: 20px; padding: 18px; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); }
.vows svg { width: 24px; height: 24px; margin-bottom: 10px; }
.vows strong { display: block; font-size: 1.02rem; }
.vows span { display: block; margin-top: 4px; color: rgba(255, 255, 255, .82); font-size: .93rem; }
.privacy-band .button { margin-top: 32px; background: #fff; color: #b3170a; box-shadow: none; }
@media (max-width: 900px) { .vows { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .vows { grid-template-columns: 1fr; } }

/* ---------- Frågor ---------- */

.faq { padding: clamp(80px, 11vw, 140px) 0 0; }
.faq .wrap { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(28px, 6vw, 80px); align-items: start; }
.faq header p { margin-top: 14px; color: var(--muted); font-size: 1.05rem; }
@media (max-width: 860px) { .faq .wrap { grid-template-columns: minmax(0, 1fr); } }
.faq details {
    background: var(--surface); border-radius: var(--radius-sm); padding: 0 20px;
    box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
}
.faq details + details { margin-top: 10px; }
.faq summary {
    list-style: none; cursor: pointer; padding: 18px 32px 18px 0; position: relative;
    font-family: var(--font-round); font-weight: 700; font-size: 1.05rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
    content: ""; position: absolute; right: 4px; top: 50%; width: 10px; height: 10px; margin-top: -7px;
    border: solid var(--muted); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); transition: transform .2s ease;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq details p { padding: 0 0 18px; color: var(--muted); }

/* ---------- Avslutning ---------- */

.final { padding: clamp(80px, 11vw, 140px) 0; text-align: center; }
.final .app-icon { width: 88px; height: 88px; margin: 0 auto 24px; border-radius: 22.5%; box-shadow: 0 16px 30px -12px rgba(224, 36, 14, .55); }
.final p { margin: 16px auto 0; max-width: 34rem; color: var(--muted); font-size: 1.12rem; }
.final .cta-row { margin-top: 28px; }
.final .fine { margin-top: 16px; color: var(--muted); font-size: .88rem; }

/* ---------- Sidfot ---------- */

.site-footer { border-top: 1px solid var(--line); padding: 40px 0 48px; color: var(--muted); font-size: .92rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 20px 40px; align-items: center; justify-content: space-between; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.site-footer a { color: var(--muted); text-decoration: none; font-weight: 600; }
.site-footer a:hover { color: var(--ink); }
.site-footer button { padding: 0; border: 0; background: none; color: var(--muted); font: inherit; font-weight: 600; cursor: pointer; }
.site-footer button:hover { color: var(--ink); }
.site-footer .logo svg { width: 28px; height: 28px; }
.site-footer .logo span { font-size: 1.2rem; }
.site-footer .made { display: flex; align-items: center; gap: 14px; }

/* ---------- Integritetspolicyn ---------- */

.doc { padding: clamp(40px, 7vw, 80px) 0 clamp(64px, 9vw, 112px); }
.doc .wrap { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
@media (max-width: 900px) { .doc .wrap { grid-template-columns: minmax(0, 1fr); } .toc { position: static !important; } }

.toc { position: sticky; top: 92px; font-size: .92rem; }
.toc p { font-weight: 800; font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.toc ol { margin: 0; padding: 0; list-style: none; counter-reset: toc; display: grid; gap: 2px; }
.toc li { counter-increment: toc; }
.toc a { display: flex; gap: 10px; color: var(--muted); text-decoration: none; padding: 6px 10px; border-radius: 10px; font-weight: 600; }
.toc a::before { content: counter(toc); color: color-mix(in srgb, var(--muted) 60%, transparent); font-variant-numeric: tabular-nums; min-width: 1.2em; }
.toc a:hover { background: var(--surface-2); color: var(--ink); }

.doc article { max-width: 46rem; }
.doc h1 { font-size: clamp(2.3rem, 5vw, 3.4rem); }
.doc .updated { margin-top: 12px; color: var(--muted); font-weight: 600; }
.doc .intro { margin-top: 22px; font-size: 1.15rem; color: var(--muted); }
.doc section { scroll-margin-top: 92px; padding-top: 44px; }
.doc h2 { font-size: clamp(1.5rem, 3vw, 1.9rem); letter-spacing: -.02em; }
.doc h3 { margin-top: 24px; font-size: 1.1rem; }
.doc section > p, .doc section > ul, .doc h3 + p, .doc h3 + ul { margin-top: 12px; }
.doc p + p { margin-top: 12px; }
.doc ul { padding-left: 1.25em; }
.doc li + li { margin-top: 6px; }
.doc li::marker { color: var(--brand); }

.summary {
    margin-top: 32px; padding: 24px 26px; border-radius: var(--radius-sm);
    background: var(--bg-tint); box-shadow: inset 0 0 0 1px var(--line);
}
.summary h2 { font-size: 1.2rem; }
.summary ul { margin: 14px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.summary li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; margin: 0 !important; }
.summary svg { width: 20px; height: 20px; margin-top: 3px; color: var(--green-ink); }

.table-wrap { margin-top: 16px; overflow-x: auto; border-radius: 16px; box-shadow: inset 0 0 0 1px var(--line); }
.doc table { width: 100%; border-collapse: collapse; font-size: .94rem; min-width: 520px; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.doc th { background: var(--surface-2); font-size: .8rem; letter-spacing: .03em; text-transform: uppercase; color: var(--muted); }
.doc tr:last-child td { border-bottom: 0; }
.doc td:first-child { font-weight: 600; }

.contact-card {
    margin-top: 16px; padding: 20px 22px; border-radius: var(--radius-sm);
    background: var(--surface); box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
}
.contact-card strong { display: block; font-size: 1.05rem; }

/* ---------- Frågan om kakor (A77) ---------- */

.consent {
    position: fixed; z-index: 60; left: 16px; right: 16px; bottom: 16px;
    max-width: 32rem; margin: 0 auto; padding: 20px 22px;
    border-radius: var(--radius-sm); background: var(--surface);
    box-shadow: var(--shadow-lg), inset 0 0 0 1px var(--line);
    font-size: .95rem; line-height: 1.5;
}
.consent-title { font-family: var(--font-round); font-weight: 800; font-size: 1.15rem; letter-spacing: -.02em; }
.consent p + p { margin-top: 6px; color: var(--muted); }
.consent-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
/* Ja och nej ser likadana ut – ett nej ska vara lika lätt som ett ja */
.consent-actions button {
    flex: 1 1 9rem; min-height: 44px; padding: 0 18px; border: 0; border-radius: 999px;
    background: var(--ink); color: var(--bg); font: inherit; font-weight: 700; white-space: nowrap; cursor: pointer;
}
.consent-actions button:hover { background: color-mix(in srgb, var(--ink) 82%, var(--bg)); }
