/* DATAP Laravel layer – Onepage bundles live in /public/assets */
:root {
    --datap-brand: #0079de;
}

.skip-to-content:focus {
    outline: 2px solid var(--datap-brand);
}

/* Mobile responsive – desktop (769px+) unchanged */
@media (max-width: 768px) {
    html,
    body {
        overflow-x: clip;
        max-width: 100%;
    }

    .con-kit-site,
    .con-kit-page,
    main {
        max-width: 100%;
        overflow-x: clip;
    }

    /* Compact header bar (logo + burger) */
    .con-kit-molecule-header-v2__atoms {
        display: flex !important;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        gap: 12px;
    }

    .con-kit-molecule-header-v2 [data-atom="logo"] {
        flex: 1 1 auto;
        width: auto !important;
        min-width: 0;
        --a-width: auto !important;
    }

    .con-kit-molecule-header-v2 [data-atom="menu-v2"],
    .con-kit-molecule-header-v2 [data-atom="link-group"] {
        display: none !important;
    }

    .datap-mobile-burger {
        display: flex;
        flex-shrink: 0;
        margin-left: auto;
    }

    /* Contain animated marquees */
    .con-kit-component-marquee,
    .con-kit-component-marquee-gallery,
    .con-kit-atom-gallery,
    .con-kit-component-grid-list {
        max-width: 100%;
        overflow: hidden;
    }

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

    .con-kit-fade-box,
    .con-kit-component-image,
    .con-kit-component-logo {
        max-width: 100%;
    }

    /* Slightly tighter card padding on small screens */
    .con-kit-molecule-textBlock[data-kit-frame="solid"] {
        --one-kit-padding: 24px;
    }

    section.quiz .con-kit-molecule-textBlock {
        --one-kit-padding: 24px !important;
    }

    .con-kit-component-select-item {
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

    .con-kit-atom-quiz .con-kit-component-input[aria-invalid="true"] {
        outline: 2px solid #d93025;
        outline-offset: 1px;
    }

    .con-kit-atom-quiz .con-kit-component-quiz-legal-document[data-invalid="true"] {
        outline: 2px solid #d93025;
        outline-offset: 4px;
        border-radius: 6px;
    }

    .con-kit-organism,
    .con-kit-organism .con-kit-container {
        --grid-container__width: calc(100vw - var(--one-kit-outside-padding) * 2);
    }

    .con-kit-layer {
        --one-kit-outside-padding: 16px;
    }

    /* Footer columns stack */
    section[class*="fußzeile"] .con-kit-layout,
    .con-kit-section--type-footer .con-kit-layout {
        flex-direction: column;
    }

    section[class*="fußzeile"] .con-kit-col,
    .con-kit-section--type-footer .con-kit-col {
        width: 100% !important;
        max-width: 100% !important;
        flex: 1 1 100% !important;
    }

    /* Burger trigger – matches original grey icon button */
    .datap-mobile-burger__button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 56px;
        height: 56px;
        padding: 0;
        border: 0;
        border-radius: 4px;
        background: rgba(20, 20, 20, 0.05);
        color: rgb(20, 20, 20);
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }

    .datap-mobile-burger__button:focus-visible {
        outline: 2px solid var(--datap-brand);
        outline-offset: 2px;
    }

    .datap-mobile-burger__icon {
        display: block;
        width: 22px;
        height: 16px;
    }

    /* Mobile nav panel content */
    .datap-mobile-nav-list {
        display: flex;
        flex-direction: column;
        gap: 0;
        width: 100%;
        margin: 0;
        padding: 0;
        list-style: none;
    }

    .datap-mobile-nav-list > li,
    .datap-mobile-nav-list > .datap-mobile-nav-item {
        width: 100%;
    }

    .datap-mobile-nav-link,
    .datap-mobile-nav-toggle {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 16px 0;
        border: 0;
        border-bottom: 1px solid rgba(20, 20, 20, 0.08);
        background: transparent;
        color: rgb(20, 20, 20);
        font-family: var(--font-kit-header-font, "Work Sans", sans-serif);
        font-size: 18px;
        font-weight: 500;
        line-height: 1.3;
        text-align: left;
        text-decoration: none;
        cursor: pointer;
    }

    .datap-mobile-nav-link:visited {
        color: rgb(20, 20, 20);
    }

    .datap-mobile-nav-sub {
        display: none;
        flex-direction: column;
        padding: 0 0 8px 12px;
    }

    .datap-mobile-nav-sub--open {
        display: flex;
    }

    .datap-mobile-nav-sub a {
        display: block;
        padding: 10px 0;
        color: rgb(20, 20, 20);
        font-family: var(--font-kit-text-font, Roboto, sans-serif);
        font-size: 15px;
        line-height: 1.4;
        text-decoration: none;
    }

    .datap-mobile-nav-sub a:visited {
        color: rgb(20, 20, 20);
    }

    .datap-mobile-nav-actions {
        display: flex;
        flex-direction: column;
        gap: 12px;
        margin-top: 24px;
        width: 100%;
    }

    .datap-mobile-nav-actions a {
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 48px;
        padding: 12px 20px;
        border-radius: 8px;
        font-family: var(--font-kit-text-font, Roboto, sans-serif);
        font-size: 15px;
        font-weight: 500;
        text-decoration: none;
    }

    .datap-mobile-nav-actions .datap-mobile-nav-login {
        border: 1px solid rgb(0, 121, 222);
        color: rgb(0, 121, 222);
        background: transparent;
    }

    .datap-mobile-nav-actions .datap-mobile-nav-cta {
        background: rgb(0, 121, 222);
        color: #fff;
    }

    body.datap-mobile-nav-open {
        overflow: hidden;
    }

    /* Stack multi-column grid lists to a single column on mobile. The original
       React app swapped the --columns-N class per breakpoint; that JS was
       stripped, so columns stayed at 3/4 and squeezed text into narrow
       slivers. Force full-width items and a sane gap on small screens. */
    .con-kit-component-grid-list {
        --one-kit-component-grid-list-horizontal-space: 24px !important;
        --one-kit-component-grid-list-vertical-space: 32px !important;
    }

    .con-kit-component-grid-list--columns-2 > .con-kit-component-grid-list-item,
    .con-kit-component-grid-list--columns-3 > .con-kit-component-grid-list-item,
    .con-kit-component-grid-list--columns-4 > .con-kit-component-grid-list-item,
    .con-kit-component-grid-list--columns-5 > .con-kit-component-grid-list-item {
        width: 100% !important;
    }

    /* Multi-column sliders (e.g. testimonials) were driven by a React carousel
       that paged through slides. With that JS stripped the items stayed pinned
       at 1/3 width and the text collapsed into narrow slivers. On mobile, stack
       every slide full-width and disable the carousel transform so all cards are
       readable. */
    .con-kit-component-slider--columns-2 .con-kit-component-slider__items,
    .con-kit-component-slider--columns-3 .con-kit-component-slider__items,
    .con-kit-component-slider--columns-4 .con-kit-component-slider__items,
    .con-kit-component-slider--columns-5 .con-kit-component-slider__items {
        flex-direction: column !important;
        transform: none !important;
        width: 100% !important;
        gap: 24px;
    }

    .con-kit-component-slider--columns-2 .con-kit-component-slider__content,
    .con-kit-component-slider--columns-3 .con-kit-component-slider__content,
    .con-kit-component-slider--columns-4 .con-kit-component-slider__content,
    .con-kit-component-slider--columns-5 .con-kit-component-slider__content {
        overflow: visible !important;
    }

    .con-kit-component-slider--columns-2 .con-kit-component-slider-item,
    .con-kit-component-slider--columns-3 .con-kit-component-slider-item,
    .con-kit-component-slider--columns-4 .con-kit-component-slider-item,
    .con-kit-component-slider--columns-5 .con-kit-component-slider-item {
        width: 100% !important;
        min-width: 100% !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    /* Mobile burger overlay panel: solid full-screen so page content does not
       show through (original site renders an opaque white overlay). */
    .datap-mobile-burger-menu {
        position: fixed;
        inset: 0;
        width: 100%;
        height: 100%;
        background: #fff;
        z-index: 10000;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        display: none;
    }

    .datap-mobile-burger-menu.con-kit-component-burger-menu--mounted,
    .datap-mobile-burger-menu[aria-hidden="false"] {
        display: block;
    }

    .datap-mobile-burger-menu .con-kit-component-burger-menu__container {
        box-sizing: border-box;
        min-height: 100%;
        padding: 16px 24px 40px;
    }

    .datap-mobile-burger-menu .con-kit-component-burger-menu__header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 16px;
    }

    .datap-mobile-burger-menu .datap-mobile-nav-logo img {
        display: block;
        height: 28px;
        width: auto;
    }

    .datap-mobile-burger-menu .con-kit-component-burger-menu__close {
        margin-left: auto;
    }
}

@media (min-width: 769px) {
    .datap-mobile-burger,
    .datap-mobile-burger-menu {
        display: none !important;
    }
}

/* Desktop megamenu dropdown (rebuilt: original React handler was stripped).
   Link nodes are cloned from the original markup, so they keep Onepage's
   Roboto fonts, sizes, colours and spacing. */
.datap-megamenu-pop {
    position: fixed;
    display: none;
    flex-direction: column;
    box-sizing: border-box;
    padding: 12px;
    background: #fff;
    border-radius: 4px;
    box-shadow:
        0px 8px 56px rgba(17, 17, 26, 0.1),
        0px 32px 140px rgba(17, 17, 26, 0.1);
    pointer-events: auto;
}

.datap-megamenu-pop--open {
    display: flex;
}

.datap-megamenu-pop .con-kit-atom-menu-v2-item-inside {
    display: block;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.15s ease;
}

.datap-megamenu-pop .con-kit-atom-menu-v2-item-inside:hover {
    background: rgba(0, 121, 222, 0.06);
}

@media (max-width: 768px) {
    .datap-megamenu-pop {
        display: none !important;
    }
}
