/*
 * Culture Hacking: opmaak van de onepager.
 *
 * Kleuren, lettergroottes en afstanden komen één op één uit het ontwerp
 * (docs/ontwerp/Main.dc.html) en de briefing. Het ontwerp bestaat alleen voor
 * desktop: de schaal tussen telefoon en desktop (clamp), het blok "Kleiner
 * scherm" en de hover- en focusstanden zijn eigen invulling, met alleen
 * kleuren die al in het ontwerp staan.
 */

@font-face {
    font-family: 'Fira Sans';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/fira-sans-400.woff2') format('woff2');
}

@font-face {
    font-family: 'Fira Sans';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/fira-sans-500.woff2') format('woff2');
}

@font-face {
    font-family: 'Fira Sans';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/fira-sans-600.woff2') format('woff2');
}

@font-face {
    font-family: 'Fira Sans Extra Condensed';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/fira-sans-extra-condensed-500.woff2') format('woff2');
}

@font-face {
    font-family: 'Fira Sans Extra Condensed';
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url('../fonts/fira-sans-extra-condensed-600.woff2') format('woff2');
}

:root {
    --grond: #FAF7EE;
    --wit: #FFFFFF;
    --blauw: #005BAA;
    --blauw-donker: #00427C;
    --geel: #FFDD00;
    --tekst: #1C2B3A;
    --tekst-zacht: #4A5868;
    --lijn: #E4DFD2;
    --lijn-lijst: #D5CFBF;
    --vlak: #E9E4D6;
    --lijn-op-blauw: rgba(255, 255, 255, 0.35);

    --kopletter: 'Fira Sans Extra Condensed', sans-serif;
    --leesletter: 'Fira Sans', sans-serif;

    --breedte: 1200px;
    --rand: 32px;
    --sectie: 96px;
    --tussenruimte: 64px;
    --kopbalk: 85px;
}

/* Basis */

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--kopbalk);
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--grond);
    color: var(--tekst);
    font-family: var(--leesletter);
    font-size: 18px;
    line-height: 1.6;
}

p,
h1,
h2,
h3,
blockquote,
figure,
ul,
ol {
    margin: 0;
}

/* Op een korte pagina blijft de voettekst onderaan het scherm. */
main {
    flex: 1;
}

img {
    max-width: 100%;
    height: auto;
}

strong {
    font-weight: 600;
}

a {
    color: var(--blauw);
}

a[href]:hover {
    color: var(--blauw-donker);
}

:focus-visible {
    outline: 2px solid var(--blauw);
    outline-offset: 3px;
}

.band--blauw :focus-visible,
.voettekst :focus-visible {
    outline-color: var(--geel);
}

.mk {
    background: var(--geel);
    padding: 0 6px;
    -webkit-box-decoration-break: clone;
    box-decoration-break: clone;
}

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

.spring {
    position: absolute;
    top: -100px;
    left: 8px;
    z-index: 200;
    background: var(--blauw);
    color: var(--wit);
    padding: 12px 16px;
    border-radius: 4px;
}

.spring:focus {
    top: 8px;
    color: var(--wit);
}

/* Bouwstenen */

.binnen {
    max-width: calc(var(--breedte) + 2 * var(--rand));
    margin: 0 auto;
    padding: var(--sectie) var(--rand);
}

.binnen--smal {
    max-width: calc(1000px + 2 * var(--rand));
}

.binnen--tekst {
    max-width: calc(820px + 2 * var(--rand));
}

.band--wit {
    background: var(--wit);
    border-top: 1px solid var(--lijn);
    border-bottom: 1px solid var(--lijn);
}

.band--blauw {
    background: var(--blauw);
    color: var(--wit);
}

.label {
    font-family: var(--kopletter);
    font-size: 20px;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--blauw);
}

.label--geel {
    color: var(--geel);
}

.kop {
    font-family: var(--kopletter);
    font-size: clamp(36px, 4.67vw, 56px);
    line-height: 1.05;
    font-weight: 600;
    color: var(--blauw);
}

.tussenkop {
    font-family: var(--kopletter);
    font-size: 30px;
    font-weight: 600;
    color: var(--blauw);
}

.opmaak {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.tekstlink {
    align-self: flex-start;
    font-weight: 600;
    text-decoration: underline;
}

.knoppen {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.knop {
    display: inline-block;
    background: var(--blauw);
    color: var(--wit);
    padding: 16px 28px;
    border-radius: 4px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.15s, color 0.15s;
}

.knop[href]:hover {
    background: var(--blauw-donker);
    color: var(--wit);
}

.knop--lijn {
    background: transparent;
    color: var(--blauw);
    border: 2px solid var(--blauw);
    padding: 14px 26px;
}

.knop--lijn[href]:hover {
    background: var(--blauw);
    color: var(--wit);
}

.knop--kop {
    padding: 11px 20px;
    font-weight: 500;
    white-space: nowrap;
}

.knop--geel {
    background: var(--geel);
    color: var(--blauw);
    padding: 14px 22px;
}

.knop--geel[href]:hover {
    background: var(--wit);
    color: var(--blauw);
}

.knop--wit {
    background: transparent;
    color: var(--wit);
    border: 2px solid var(--wit);
    padding: 12px 20px;
}

.knop--wit[href]:hover {
    background: var(--wit);
    color: var(--blauw);
}

.lijst {
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
}

.lijst li {
    border-top: 1px solid var(--lijn-lijst);
    padding: 14px 0;
}

.lijst li:last-child {
    border-bottom: 1px solid var(--lijn-lijst);
}

.lijst a {
    font-weight: 500;
    text-decoration: underline;
}

/* Kopbalk */

.kopbalk {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--grond);
    border-bottom: 1px solid var(--lijn);
}

.kopbalk__binnen {
    max-width: calc(var(--breedte) + 2 * var(--rand));
    margin: 0 auto;
    padding: 18px var(--rand);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.woordmerk {
    font-family: var(--kopletter);
    font-weight: 600;
    font-size: 28px;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
    color: var(--blauw);
}

.kopbalk__rechts {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 28px;
    font-size: 16px;
    font-weight: 500;
}

.hoofdmenu__lijst {
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 28px;
}

.hoofdmenu__lijst a {
    color: var(--tekst);
    text-decoration: none;
}

.hoofdmenu__lijst a:hover {
    color: var(--blauw);
}

.menuknop {
    display: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--blauw);
    cursor: pointer;
}

.menuknop__strepen,
.menuknop__strepen::before,
.menuknop__strepen::after {
    display: block;
    width: 24px;
    height: 2px;
    background: currentColor;
}

.menuknop__strepen {
    position: relative;
}

.menuknop__strepen::before,
.menuknop__strepen::after {
    content: '';
    position: absolute;
    left: 0;
}

.menuknop__strepen::before {
    top: -7px;
}

.menuknop__strepen::after {
    top: 7px;
}

.kopbalk[data-open] .menuknop__strepen {
    background: transparent;
}

.kopbalk[data-open] .menuknop__strepen::before {
    top: 0;
    transform: rotate(45deg);
}

.kopbalk[data-open] .menuknop__strepen::after {
    top: 0;
    transform: rotate(-45deg);
}

.admin-bar .kopbalk {
    top: 32px;
}

/* Opening */

.opening {
    max-width: calc(var(--breedte) + 2 * var(--rand));
    margin: 0 auto;
    padding: 88px var(--rand) var(--sectie);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--tussenruimte);
}

.opening__tekst {
    flex: 1 1 520px;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.opening__kop {
    font-family: var(--kopletter);
    font-size: clamp(44px, 6vw, 72px);
    line-height: 1.02;
    font-weight: 600;
    color: var(--blauw);
}

.opening__intro {
    font-size: 21px;
    line-height: 1.55;
    max-width: 600px;
}

.opening__meta {
    font-size: 15px;
    color: var(--tekst-zacht);
}

.opening__omslag {
    flex: 0 1 380px;
    display: flex;
    justify-content: center;
}

.opening__boek {
    width: 100%;
    max-width: 380px;
}

.opening__beeld {
    display: block;
    width: 100%;
    height: auto;
    box-shadow: 0 24px 48px rgba(28, 43, 58, 0.22);
}

/* Peiling */

.peiling {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.peiling__kop {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 820px;
}

.zinnen {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
    gap: 24px;
}

.zin {
    background: var(--grond);
    padding: 32px;
    font-family: var(--kopletter);
    font-size: clamp(28px, 2.84vw, 34px);
    line-height: 1.1;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--blauw);
}

.peiling__onder {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.peiling__onder p {
    max-width: 640px;
}

/* Het boek */

.boek {
    display: flex;
    flex-direction: column;
    gap: 56px;
}

.boek__boven {
    display: flex;
    flex-wrap: wrap;
    gap: var(--tussenruimte);
}

.boek__tekst {
    flex: 1 1 520px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.boek__stappen {
    flex: 1 1 380px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stappen {
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stap {
    display: flex;
    align-items: baseline;
    gap: 20px;
    border-top: 2px solid var(--blauw);
    padding-top: 16px;
}

.stap__nummer {
    font-family: var(--kopletter);
    font-size: 44px;
    line-height: 1;
    font-weight: 600;
    color: var(--blauw);
}

.boek__spanningen {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.spanningen {
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.spanningen li {
    border: 2px solid var(--blauw);
    color: var(--blauw);
    padding: 8px 18px;
    border-radius: 40px;
    font-weight: 500;
}

/* Uit het voorwoord */

.voorwoord,
.voorwoord__blok {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.voorwoord__citaat {
    font-family: var(--kopletter);
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.15;
    font-weight: 500;
}

.voorwoord__bron {
    font-weight: 500;
}

.reacties {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
    gap: 32px;
    margin-top: 32px;
    border-top: 1px solid var(--lijn-op-blauw);
    padding-top: 32px;
}

.reactie__naam {
    font-weight: 600;
}

/* Over Bregje */

.auteur {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--tussenruimte);
}

.auteur__beeld {
    flex: 0 1 380px;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    background: var(--vlak);
}

.auteur__beeld img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.auteur__beeld--leeg {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    text-align: center;
    font-size: 16px;
    color: var(--tekst-zacht);
}

.auteur__tekst {
    flex: 1 1 480px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Voor organisaties */

.organisaties {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.organisaties > .knop {
    align-self: flex-start;
}

.aanbod {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
    gap: 32px;
}

.aanbod__blok {
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-top: 4px solid var(--geel);
    padding-top: 20px;
}

/* Pers */

.pers {
    display: flex;
    flex-wrap: wrap;
    gap: var(--tussenruimte);
}

.pers__tekst {
    flex: 1 1 520px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.pers__contact {
    flex: 1 1 360px;
    align-self: flex-start;
    display: flex;
    flex-direction: column;
    gap: 24px;
    background: var(--wit);
    padding: 36px;
}

.contact {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.contact__kop {
    font-family: var(--kopletter);
    font-size: 18px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--blauw);
}

/* Voettekst */

.voettekst {
    background: var(--blauw);
    color: var(--wit);
}

.voettekst__binnen {
    max-width: calc(var(--breedte) + 2 * var(--rand));
    margin: 0 auto;
    padding: 80px var(--rand) 48px;
    display: flex;
    flex-direction: column;
    gap: 56px;
}

.voettekst__boven {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 48px;
}

.voettekst__bestel {
    flex: 1 1 420px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.voettekst__bestel .knoppen {
    gap: 12px;
}

.voettekst__kop {
    font-family: var(--kopletter);
    font-size: clamp(34px, 4vw, 48px);
    line-height: 1.05;
    font-weight: 600;
}

.nieuwsbrief {
    flex: 1 1 380px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.nieuwsbrief__label {
    font-weight: 600;
}

.nieuwsbrief__rij {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.nieuwsbrief__veld {
    flex: 1 1 220px;
    min-width: 0;
    font: inherit;
    padding: 13px 14px;
    border: 0;
    border-radius: 4px;
    background: var(--wit);
    color: var(--tekst);
}

.nieuwsbrief__knop {
    font: inherit;
    font-weight: 600;
    padding: 13px 22px;
    border: 2px solid var(--wit);
    border-radius: 4px;
    background: transparent;
    color: var(--wit);
    cursor: pointer;
    transition: background-color 0.15s, color 0.15s;
}

.nieuwsbrief__knop:hover {
    background: var(--wit);
    color: var(--blauw);
}

/* De bevestiging komt op de plek van het veld en heeft dezelfde vorm: het veld wordt het antwoord. */
.nieuwsbrief__gelukt {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 13px 16px;
    border-radius: 4px;
    background: var(--wit);
    color: var(--blauw);
    font-weight: 600;
    line-height: 1.45;
}

.nieuwsbrief__gelukt::before {
    content: '';
    flex: none;
    width: 22px;
    height: 22px;
    margin-top: 2px;
    background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='square'%3E%3Cpath d='M4 11.5l4.6 4.6L18 6.7'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='square'%3E%3Cpath d='M4 11.5l4.6 4.6L18 6.7'/%3E%3C/svg%3E") center / contain no-repeat;
}

.nieuwsbrief__gelukt:focus {
    outline: 0;
}

.nieuwsbrief__gelukt:focus-visible {
    outline: 2px solid var(--geel);
    outline-offset: 3px;
}

.nieuwsbrief__melding {
    font-size: 16px;
    font-weight: 500;
}

.nieuwsbrief__veld[aria-invalid='true'] {
    outline: 2px solid var(--geel);
    outline-offset: 2px;
}

.nieuwsbrief__knop:disabled {
    opacity: 0.6;
    cursor: default;
}

/* Een veld dat alleen robots invullen: zij lezen de broncode, bezoekers zien het niet. */
.nieuwsbrief__lok {
    display: none;
}

.voettekst__onder {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 16px;
    border-top: 1px solid var(--lijn-op-blauw);
    padding-top: 24px;
    font-size: 15px;
}

.voettekst__maker {
    flex-basis: 100%;
}

.voettekst__onder a,
.voettekst__onder a[href]:hover {
    color: var(--wit);
    text-decoration: underline;
}

/* Gewone pagina, zoals de privacyverklaring */

.pagina {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.pagina__inhoud > * + * {
    margin-top: 20px;
}

.pagina__inhoud h2,
.pagina__inhoud h3 {
    margin-top: 40px;
    font-family: var(--kopletter);
    font-size: 30px;
    line-height: 1.25;
    font-weight: 600;
    color: var(--blauw);
}

.pagina__inhoud ul,
.pagina__inhoud ol {
    padding-left: 1.2em;
}

/* Kleiner scherm */

/* Tablet en kleine laptop: omslag en stappen blijven naast de tekst staan. */
@media (max-width: 1100px) {
    .opening__tekst,
    .boek__tekst {
        flex-basis: 440px;
    }
}

@media (max-width: 880px) {
    :root {
        --rand: 20px;
        --sectie: 64px;
        --tussenruimte: 40px;
        --kopbalk: 73px;
    }

    .label,
    .tussenkop {
        line-height: 1.25;
    }

    .opening {
        padding-top: 48px;
    }

    .opening__boek {
        max-width: min(380px, 70vw);
    }

    .zin {
        padding: 24px;
    }

    /* Losse tekstlinks krijgen een tikvlak van 44 px zonder dat de afstanden verschuiven. */
    .tekstlink {
        padding-block: 8px;
        margin-block: -8px;
    }

    .pers__contact {
        padding: 28px;
    }

    .voettekst__binnen {
        padding-top: 56px;
        padding-bottom: 40px;
        gap: 40px;
    }

    /* Het menu klapt in achter een knop; de bestelknop blijft in beeld. */
    .js .kopbalk__binnen {
        flex-wrap: nowrap;
        padding-top: 12px;
        padding-bottom: 12px;
        gap: 12px;
    }

    .js .kopbalk__rechts {
        flex-wrap: nowrap;
        gap: 8px;
    }

    .js .menuknop {
        display: inline-flex;
    }

    .js .hoofdmenu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--grond);
        border-bottom: 1px solid var(--lijn);
        padding: 4px var(--rand) 12px;
    }

    .js .kopbalk[data-open] .hoofdmenu {
        display: block;
    }

    .js .hoofdmenu__lijst {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
    }

    .js .hoofdmenu__lijst li + li {
        border-top: 1px solid var(--lijn);
    }

    .js .hoofdmenu__lijst a {
        display: flex;
        align-items: center;
        min-height: 48px;
        font-size: 18px;
    }
}

@media (max-width: 782px) {
    .admin-bar .kopbalk {
        top: 46px;
    }
}

@media (max-width: 600px) {
    .admin-bar .kopbalk {
        top: 0;
    }
}

/*
 * Telefoon: het woordmerk komt op twee regels, zodat woordmerk, bestelknop en
 * menuknop naast elkaar passen, ook met de langere tekst "Bestel het boek".
 */
@media (max-width: 480px) {
    .woordmerk {
        width: min-content;
        white-space: normal;
        font-size: 22px;
        line-height: 1.05;
    }

    .knop--kop {
        padding: 10px 12px;
        font-size: 15px;
    }
}

@media (max-width: 340px) {
    :root {
        --rand: 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .knop,
    .nieuwsbrief__knop {
        transition: none;
    }
}
