/* ==========================================================================
   Responsive — per breakpoint, van breed naar smal.
   Daarna de bereiken (min + max) en tot slot prefers-reduced-motion.
   ========================================================================== */

@media (max-width: 1023px) {
    .hero .details {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-m);
        padding-top: 0;
        border-top: 0;
    }

    .offer {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 960px) {
    .section-columns {
        grid-template-columns: 1fr;
    }

    .problems ul {
        margin-block: 0;
    }

    .posts .wrapper {
        padding-inline: var(--space-inline);
        gap: var(--space-xl);
    }

    .posts .post-content {
        padding: var(--space-xl);
    }

    .projects .section-columns:nth-child(n) {
        flex-direction: column;
    }

    .projects .section-columns > * {
        flex: 0 0 auto;
    }

    .project-content {
        justify-content: flex-start;
    }

    .project-footer {
        margin-top: 0;
    }

    .faq .wrapper {
        padding-inline: var(--space-3xl);
    }

    .cta {
        --cta-avatar: 120px;
        --cta-avatar-offset: 40px;
    }

    .cta-card {
        padding-bottom: var(--space-3xl);
    }

    .contact-grid {
        gap: var(--space-2xl);
    }

    .card {
        --card-padding-block: var(--space-xl);
        --card-padding-inline: var(--space-l);
    }

    .card .card-badge {
        left: 32px;
    }

    .card-large {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }

    .pricings .cards {
        grid-template-columns: 1fr;
        gap: var(--space-l);
    }

    /* Stappen in de grote kaarten: inklapbaar, zelfde plusje als de kaarten en FAQ.
       De ruimte zit in het label zelf, zodat de hele dichte kaart klikbaar is. */
    .card-large-plan {
        padding: 0;
    }

    .card-large-plan .card-label {
        margin-bottom: 0;
        padding: var(--plan-padding-block) var(--plan-padding-inline);
    }

    .card-large-plan[open] .card-label {
        padding-bottom: var(--space-xl);
    }

    .card-large-steps {
        margin: 0 var(--plan-padding-inline) var(--plan-padding-block);
    }

    .card-large-plan summary {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: var(--space-m);
        cursor: pointer;
        pointer-events: auto;
    }

    .card-large-plan summary::after {
        content: "+";
        font-size: var(--font-size-h5);
        line-height: 1;
        color: var(--color-brand);
        transition: var(--transition);
    }

    .card-large-plan[open] summary::after {
        transform: rotate(45deg);
    }

    /* Zonder vaste kaarthoogte verdelen de stappen zich niet vanzelf: vaste ruimte ertussen. */
    .card-large-steps {
        gap: var(--space-l);
    }

    .addons-secondary {
        grid-template-columns: 1fr;
    }

    .newsletter .section-columns {
        flex-direction: column;
        gap: var(--space-m);
    }

    .section-columns,
    .projects .section-columns:nth-child(odd),
    .projects .section-columns:nth-child(even) {
        flex-direction: column;
        gap: var(--space-2xl);
    }

    .section-columns > *,
    .project-figure,
    .project-content {
        min-width: 0;
        width: 100%;
    }

    .project-content {
        padding-block: 0;
        gap: var(--space-xl);
    }

    .project-figure,
    .problems .wrapper .figure {
        max-height: 680px;
    }

    .problems {
        padding-bottom: clamp(72px, 12vw, 130px);
    }

    .contact-side {
        grid-template-columns: 1fr;
        gap: var(--space-m);
    }

    .contact-block {
        min-width: 0;
    }

    .story-figure {
        position: relative;
        top: auto;
        flex: 1;
        width: 100%;
        height: auto;
        margin-inline-end: 0;
    }

    .story-content .story-lead {
        margin-top: 0;
    }
}

@media (max-width: 800px) {
    .privacy-layout {
        grid-template-columns: 1fr;
        gap: var(--space-l);
    }

    .privacy-toc {
        position: static;
        display: none;
    }

    .privacy-item {
        gap: var(--space-xs);
        grid-template-columns: 28px 1fr;
    }

    .privacy-page {
        padding-top: 0;
    }
}

@media (max-width: 768px) {
    .newsletter .newsletter-frame {
        grid-template-columns: 1fr;
    }

    .header {
        z-index: 200;
    }

    .header > .wrapper {
        position: relative;
        z-index: 2;
    }

    .header .logo {
        position: relative;
        z-index: 2;
        min-width: 0;
    }

    /* Mobiel: alleen de sterren, zodat er meer ruimte in de header is. */
    .logo-text {
        display: none;
    }

    .logo-stars {
        width: var(--icon-regular);
    }

    .header-nav {
        display: none;
    }

    .header-mobile-actions {
        display: flex;
        align-items: center;
        gap: var(--space-s);
    }

    .header-contact {
        white-space: nowrap;
    }

    .button.header-rating {
        gap: var(--space-3xs);
        padding-inline: var(--space-s);
    }

    /* Even hoog als de Contact-knop ernaast (regelhoogte + padding van de kleine button). */
    .menu-toggle {
        display: flex;
        flex-shrink: 0;
        width: calc(var(--font-size-small) * 1.3 + 20px);
        height: calc(var(--font-size-small) * 1.3 + 20px);
        padding: 0;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: var(--space-3xs);
        background: var(--color-white-01);
        border-radius: 50%;
        color: var(--color-white);
        position: relative;
        z-index: 2;
    }

    .menu-toggle span {
        display: block;
        width: 21px;
        height: 1px;
        background: currentColor;
        border-radius: var(--radius-3xs);
        transition: transform var(--transition);
    }

    .header.menu-open .menu-toggle span:first-child {
        transform: translateY(3px) rotate(45deg);
    }

    .header.menu-open .menu-toggle span:last-child {
        transform: translateY(-3px) rotate(-45deg);
    }

    /* Het menu hangt onder de aankondigingsbalk en vouwt van boven naar beneden open.
    Dicht gaat het omgekeerd: eerst de items weg, dan klapt het menu omhoog. */
    .mobile-menu {
        display: flex;
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 75vh;
        height: 75dvh;
        min-height: 300px;
        align-items: center;
        justify-content: center;
        background: var(--color-black);
        box-shadow: 0 25px 60px rgba(0, 0, 0, 0.25);
        clip-path: inset(0 0 100% 0);
        visibility: hidden;
        pointer-events: none;
        transition: clip-path var(--duration-s) var(--ease-in-out) var(--delay), visibility 0s calc(var(--duration-s) + var(--delay));
        overflow-y: auto;
        max-height: 100dvh;
    }

    .header.menu-open .mobile-menu {
        clip-path: inset(0 0 -100px 0);
        visibility: visible;
        pointer-events: auto;
        transition: clip-path var(--duration-m) var(--ease-in-out), visibility 0s;
    }

    .mobile-menu li {
        opacity: 0;
        transform: translateY(16px);
        transition: opacity var(--transition), transform var(--transition);
    }

    /* Sluiten: van onder naar boven. */
    .mobile-menu li:nth-child(1) {
        transition-delay: calc(var(--stagger) * 3);
    }

    .mobile-menu li:nth-child(2) {
        transition-delay: calc(var(--stagger) * 2);
    }

    .mobile-menu li:nth-child(3) {
        transition-delay: var(--stagger);
    }

    .header.menu-open .mobile-menu li {
        opacity: 1;
        transform: none;
        transition: opacity var(--duration-m) var(--ease) calc(var(--delay) * 2), transform var(--duration-l) var(--ease-out) calc(var(--delay) * 2);
    }

    .header.menu-open .mobile-menu li:nth-child(2) {
        transition-delay: calc(var(--delay) * 2 + var(--stagger));
    }

    .header.menu-open .mobile-menu li:nth-child(3) {
        transition-delay: calc(var(--delay) * 2 + var(--stagger) * 2);
    }

    .header.menu-open .mobile-menu li:nth-child(4) {
        transition-delay: calc(var(--delay) * 2 + var(--stagger) * 3);
    }

    .mobile-menu ul {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: var(--space-2xl);
        padding: var(--space-2xl) var(--space-l) var(--space-xl);
        text-align: center;
    }

    .mobile-menu a {
        display: inline-block;
        font-size: var(--font-size-h3);
        line-height: 1.2;
        letter-spacing: -0.035em;
        color: var(--color-white);
        transition: color var(--transition), transform var(--transition);
    }

    .mobile-menu a:hover,
    .mobile-menu a:focus-visible {
        color: var(--color-brand-soft);
        transform: translateY(-2px);
    }

    :root {
        --font-size-h1: clamp(38px, calc(9.5 * var(--fluid)), 60px);
        --font-size-h2: clamp(32px, calc(8 * var(--fluid)), 48px);
        --font-size-h3: clamp(28px, calc(7 * var(--fluid)), 42px);
        --font-size-body: 15px;
        --font-size-medium: 14px;
        --font-size-small: 13px;
    }

    .header {
        padding: var(--space-m) 0;
    }

    .header > .wrapper {
        gap: var(--space-s);
    }

    .hero-content h1,
    .page-hero-01 h1,
    .page-hero-02 h1 {
        overflow-wrap: break-word;
    }

    .page-hero-01 h1 br {
        display: none;
    }

    .modal-body > h2 br {
        display: none;
    }

    .hero-content p {
        max-width: 650px;
    }

    .hero .details {
        align-items: stretch;
    }

    .buttons {
        flex-wrap: wrap;
        flex-direction: column;
    }

    .buttons .button {
        width: 100%;
        padding: var(--space-m) var(--space-m);
    }

    .hero .details .proof {
        align-self: flex-start;
    }

    .contact-block {
        padding: var(--space-2xl);
    }

    .contact-person {
        min-width: 0;
    }

    .contact-person > div:last-child {
        min-width: 0;
        overflow-wrap: anywhere;
    }

    .contact-person a {
        overflow-wrap: anywhere;
    }

    .problems ul {
        margin-block: var(--space-s);
        gap: var(--space-l);
    }

    .problems span {
        padding: var(--space-l);
    }

    .newsletter .newsletter-frame {
        min-width: 0;
    }

    .newsletter .form {
        min-width: 0;
    }

    .newsletter .form input[type="email"],
    .newsletter .form input[type="tel"] {
        min-width: 0;
        max-width: 100%;
    }

    .hero {
        position: relative;
        inset: auto;
        height: auto;
        min-height: 100svh;
        min-height: 100dvh;
        display: flex;
        align-items: flex-end;
    }

    /* Met de aankondigingsbalk erboven past de hero precies in het scherm. */
    .announce ~ .hero {
        min-height: calc(100svh - var(--announce-height));
        min-height: calc(100dvh - var(--announce-height));
    }

    .hero > figure {
        position: absolute;
        inset: 0;
    }

    /* Op mobiel alleen een verloop onder de tekst; de bovenkant van de foto blijft helder. */
    .hero > figure::after {
        background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.7) 40%, rgba(0, 0, 0, 0.45) 60%, transparent 80%);
    }

    .hero .wrapper::before {
        content: none;
    }

    .hero-content {
        position: relative;
        bottom: auto;
        padding-top: var(--space-3xl);
        padding-bottom: var(--space-3xl);
    }
}

@media (max-width: 700px) {
    .modal {
        padding: 0;
    }

    .modal-title {
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
    }

    .modal-title .label::before {
        display: none;
    }

    .modal-dialog {
        width: 100%;
        height: 100vh;
        height: 100dvh;
        max-height: none;
        border: 0;
        border-radius: 0;
    }
}

@media (max-width: 600px) {
    .insight-article-cover {
        aspect-ratio: 4 / 3;
        border-radius: var(--radius-m);
    }

    .insight-article-body {
        padding-inline: var(--space-3xs);
    }

    .newsletter .form input[type="email"],
    .newsletter .form input[type="tel"] {
        flex: 0 0 64px;
        height: 64px;
        min-height: 64px;
        padding-inline: var(--space-xl);
    }

    .newsletter .newsletter-frame .form {
        flex-direction: column;
    }

    .newsletter .newsletter-frame .form input[type="email"],
    .newsletter .newsletter-frame .form input[type="tel"] {
        width: 100%;
        min-height: 64px;
    }

    .newsletter .newsletter-frame .form button.button {
        width: 100%;
    }

    .bs-think__box {
        height: 56px;
    }

    .bs-think__drop {
        padding: var(--space-l) var(--space-3xs) var(--space-3xs);
    }

    .bs-think__row {
        padding: var(--space-xs);
        gap: var(--space-s);
    }

    .bs-think__row--top {
        height: 84px;
    }

    .bs-think__logo {
        width: 34px;
        height: 34px;
    }

    .bs-think__sub {
        white-space: normal;
        line-height: 1.35;
    }

    .bs-think.is-on .bs-think__sub {
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .bs-think.is-on .bs-think__badge {
        display: none;
    }

    .faq .wrapper {
        padding-inline: var(--space-2xl);
    }

    .cta-card {
        padding-inline: var(--space-3xl);
    }

    .newsletter .form input[type="submit"] {
        width: 100%;
    }

    .contact-person img {
        width: 64px;
        height: 64px;
    }

    .contact-form {
        gap: var(--space-2xl);
    }

    .contact-option {
        flex-wrap: wrap;
        padding: var(--space-m);
    }

    .contact-option small {
        margin-left: var(--space-2xl);
    }

    .check-lead .check-button {
        width: 100%;
    }

    .check-chain {
        gap: 6px;
    }

    .check-progress-track {
        margin-bottom: 38px;
    }

    .check-answer {
        min-height: 68px;
        padding: 14px 16px;
    }

    .check-result-summary {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .check-score {
        flex-direction: row;
        align-items: baseline;
        gap: 16px;
    }

    .check-meeting-inline {
        flex-direction: column;
        align-items: flex-start;
        gap: 18px;
    }

    .card {
        --card-padding-block: var(--space-2xl);
        --card-padding-inline: var(--space-xl);
    }

    .card-large-plan {
        --plan-padding-block: var(--space-2xl);
        --plan-padding-inline: var(--space-xl);
    }

    .offer {
        padding: var(--space-2xl) var(--space-xl);
    }

    .card .card-badge {
        left: 24px;
    }

    .contact-groeiplan .cta-card {
        padding-inline: var(--space-xl);
    }

    .newsletter .newsletter-frame {
        padding: var(--space-2xl) var(--space-xl);
    }

    .newsletter .form {
        flex-direction: column;
    }

    .newsletter .form button.button {
        width: 100%;
    }

    .newsletter .form input[type="email"],
    .newsletter .form input[type="tel"] {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .privacy-page {
        padding-top: 0;
        padding-bottom: var(--space-3xl);
    }

    .cookie-toggle {
        width: 42px;
        height: 42px;
    }

    .header-mobile-actions {
        gap: var(--space-2xs);
        flex-shrink: 0;
    }

    .hero-content h1 {
        line-height: 1.12;
    }

    .hero-content p {
        line-height: 1.5;
    }

    .hero-content .wrapper {
        gap: var(--space-m);
    }

    .hero .details {
        gap: var(--space-m);
    }

    .hero .details .buttons {
        flex-direction: column;
    }

    .hero .details .buttons .button {
        width: 100%;
        flex: 0 0 auto;
        min-height: 56px;
    }

    .contact-person {
        gap: var(--space-m);
    }

    .contact-person img {
        width: 64px;
        height: 64px;
    }

    .contact-block .button {
        max-width: 100%;
    }

    .project-figure,
    .problems .wrapper .figure {
        aspect-ratio: 4 / 5;
    }

    .newsletter .newsletter-frame {
        padding: var(--space-xl) var(--space-l);
    }

    /* Enige vaste maat: iOS zoomt in op invoervelden onder 16px. */
    .newsletter .newsletter-frame .form input[type="email"],
    .newsletter .newsletter-frame .form input[type="tel"] {
        font-size: 16px;
    }
}

@media (max-width: 401px) {
    .hero-content p br,
    .page-hero-02 h1 br {
        display: none;
    }
}

@media (max-width: 360px) {
    /* Smalste telefoons: klokblokjes iets compacter, zodat balktekst en klok naast elkaar passen. */
    .announce-timer > span {
        padding-inline: var(--space-3xs);
    }

    .header-contact {
        padding-inline: var(--space-xs);
    }
}

@media (min-width: 390px) and (max-width: 768px) {
    .hero .details .buttons {
        flex-direction: row;
    }

    .hero .details .buttons .button {
        flex: 1 1 0;
        width: auto;
        min-width: 0;
        white-space: nowrap;
    }
}

@media (min-width: 390px) and (max-width: 639px) {
    .hero .buttons .button-full,
    .hero .buttons .button-label {
        display: none;
    }

    .hero .buttons .button-short {
        display: inline;
    }
}

@media (prefers-reduced-motion: reduce) {
    .card-large-end span::after {
        animation: none;
    }

    .privacy-toc a {
        transition: none;
    }

    .bs-think * {
        animation: none !important;
        transition: none !important;
    }

    .modal,
    .modal *,
    .mobile-menu,
    .mobile-menu li,
    .mobile-menu a,
    .menu-toggle span {
        transition: none !important;
    }
}
