/* Labsit Switzerland — site overrides */

/* Theme sets header .navbar-brand img { max-height: 21px } — override it */
header .navbar-brand img,
header .navbar-brand .default-logo,
header .navbar-brand .alt-logo,
header .navbar-brand .mobile-logo {
    max-height: 46px !important;
    height: auto !important;
}

.footer-logo img,
.hamburger-logo img {
    max-height: 56px;
    width: auto;
}

/* Hero image: square crop like original demo (865x850) */
.hero-square-image {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
}

.hero-square-image img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Secondary hero link: own line, top space only, left edge flush with the button above.
   The theme pulls .btn-text left by 13px for the hover animation — override that. */
a.btn.hero-secondary-cta.btn-hover-animation-switch {
    display: flex;
    width: fit-content;
    margin-top: 25px;
    margin-left: 0;
    padding: 0;
}

a.btn.hero-secondary-cta.btn-hover-animation-switch .btn-text {
    margin-left: 0 !important;
}

a.btn.hero-secondary-cta.btn-hover-animation-switch .btn-icon + .btn-icon {
    position: absolute;
    width: 0;
    overflow: hidden;
    margin: 0;
}

/* Keep secondary text CTAs on-brand (white), not theme blue */
.btn.btn-link {
    color: var(--white);
}
.btn.btn-link:hover,
.btn.btn-link:focus {
    color: #ffffff;
}

/* Slightly calmer accent usage across feature cards */
.icon-with-text-style-07 .bottom-line {
    background-color: var(--base-color) !important;
}

/* Legal / long-form text readability */
.legal-content p,
.legal-content li {
    color: rgba(217, 217, 217, 0.85);
    max-width: 52rem;
}

.legal-content h2 {
    margin-top: 2.5rem;
    margin-bottom: 1rem;
}

/* Contact form select styling to match dark theme */
.contact-form-style-07 select.form-control {
    appearance: none;
    -webkit-appearance: none;
    color: var(--white);
    background-color: transparent;
    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 0;
    padding-left: 0;
    height: auto;
    min-height: 48px;
}

.contact-form-style-07 select.form-control option {
    color: #121212;
}

/* Hide translated pages until German or French copy is in place */
html.i18n-pending body {
    visibility: hidden;
}

/* Navbar language switch — sits where the center line used to be */
.header-lang {
    display: flex;
    align-items: center;
    justify-content: center;
}

.lang-switch {
    display: inline-flex;
    align-items: center;
    pointer-events: auto;
}

.lang-switch__btn {
    appearance: none;
    background: transparent;
    border: 0;
    color: rgba(255, 255, 255, 0.45);
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.14em;
    line-height: 1;
    padding: 8px 11px;
}

.lang-switch__btn + .lang-switch__btn {
    box-shadow: inset 1px 0 0 rgba(255, 255, 255, 0.28);
}

.lang-switch__btn.is-active,
.lang-switch__btn:hover,
.lang-switch__btn:focus-visible {
    color: #ffffff;
}

.lang-switch__btn:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 3px;
}

/* Theme zeroes .menu-item margins, so this needs equal or higher specificity. */
.hamburger-nav .menu-item-list .menu-item.lang-switch-item {
    margin-top: 40px;
}

/* Desktop list wrapper is sized for the links only, so grow it with the extra gap. */
@media (min-width: 992px) {
    .hamburger-nav .menu-item-list .menu-item.lang-switch-item {
        margin-top: 48px;
    }

    .hamburger-menu-simple .menu-list-wrapper {
        height: calc(55vh - 90px);
    }
}

.lang-switch-item .lang-switch {
    justify-content: center;
}

@media (max-width: 991px) {
    header .push-button-text {
        display: none;
    }

    .lang-switch__btn {
        font-size: 12px;
        letter-spacing: 0.08em;
        padding: 8px 8px;
    }
}

/* Navbar: Partner Portal sits where the country label was, clear of the Menu control */
a.header-portal-link {
    align-items: center;
    margin-right: 70px;
    padding: 8px 14px;
    border: 1px solid rgba(255, 255, 255, 0.55);
    color: #ffffff;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.2;
    letter-spacing: 0.01em;
    white-space: nowrap;
    text-decoration: none;
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

a.header-portal-link:hover,
a.header-portal-link:focus,
a.header-portal-link.is-current {
    background-color: #ffffff;
    border-color: #ffffff;
    color: #2d2c2b;
}

a.header-portal-link:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 3px;
}

@media (min-width: 992px) {
    header .navbar > .container-fluid {
        position: relative;
    }

    header .navbar > .container-fluid > .header-lang {
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -50%);
        justify-content: center;
        text-align: center;
        z-index: 3;
    }

    header .navbar > .container-fluid > .text-end {
        position: relative;
        z-index: 2;
        width: auto !important;
        max-width: none !important;
        flex: 0 0 auto !important;
    }
}

/* Partner Portal sign-in (preview) */
.portal-auth {
    padding-bottom: 80px;
}

.portal-auth-panel {
    border: 1px solid rgba(255, 255, 255, 0.16);
    padding: 48px 40px 40px;
}

.portal-auth label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    letter-spacing: 0.02em;
}

.portal-auth .form-control {
    color: #ffffff;
    background-color: transparent;
    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 0;
    padding: 10px 0 12px;
    margin-bottom: 22px;
    box-shadow: none;
}

.portal-auth .form-control:focus {
    color: #ffffff;
    background-color: transparent;
    border-bottom-color: #ffffff;
    box-shadow: none;
}

.portal-auth .form-control::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.portal-login-note {
    margin: 18px 0 0;
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    font-size: 14px;
    line-height: 1.5;
}

.portal-login-note[hidden] {
    display: none !important;
}

@media (max-width: 575px) {
    .portal-auth-panel {
        padding: 32px 22px 28px;
    }
}

/* Mobile UX refinements. Kept in the final override file so desktop stays unchanged. */
@media (max-width: 767px) {
    /* Keep a comfortable, consistent reading gutter across every page. */
    main section > .container-fluid,
    footer > .container-fluid {
        padding-left: 20px;
        padding-right: 20px;
    }

    section {
        padding-top: 44px;
        padding-bottom: 44px;
    }

    /* Compact the header while preserving 44px touch targets. */
    header .navbar-brand {
        display: inline-flex;
        align-items: center;
        min-height: 44px;
        padding-top: 17px;
        padding-bottom: 17px;
    }

    header .navbar > .container-fluid {
        flex-wrap: nowrap;
    }

    header .navbar > .container-fluid > .header-lang,
    header .navbar > .container-fluid > .text-end {
        flex: 0 0 auto;
        width: auto;
        padding-left: 0;
        padding-right: 0;
    }

    header .navbar-brand img,
    header .navbar-brand .default-logo,
    header .navbar-brand .alt-logo,
    header .navbar-brand .mobile-logo {
        max-height: 40px !important;
    }

    .lang-switch__btn {
        min-width: 44px;
        min-height: 44px;
        padding: 8px 7px;
    }

    header .header-push-button.icon {
        align-items: center;
        justify-content: center;
        min-width: 44px;
        min-height: 44px;
        padding: 0;
    }

    header .push-menu .close-menu {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        top: 16px;
        right: 16px;
    }

    .push-menu {
        min-height: 100svh;
    }

    .hamburger-nav .menu-item-list .nav-link {
        display: inline-flex;
        align-items: center;
        min-height: 48px;
        padding-top: 8px;
        padding-bottom: 8px;
    }

    /* Prevent display type from overwhelming narrow screens. */
    .page-title-big-typography h1 {
        font-size: clamp(44px, 14vw, 58px) !important;
        line-height: 1;
        letter-spacing: -1.5px;
        overflow-wrap: anywhere;
    }

    .page-title-big-typography {
        padding-bottom: 28px !important;
    }

    .text-reveal-animation {
        font-size: clamp(34px, 10vw, 44px) !important;
        line-height: 1.12;
    }

    main .w-70,
    main .w-80,
    main .w-85,
    main .w-90 {
        width: 100% !important;
        max-width: 36rem;
    }

    .fs-325,
    .fs-200,
    .fs-160 {
        font-size: clamp(48px, 15vw, 64px) !important;
        line-height: 1;
        white-space: normal !important;
    }

    /* Reduce long mobile cards without making their content feel crowded. */
    .icon-with-text-style-07 .feature-box,
    .p-30px,
    .p-35px {
        padding: 24px !important;
    }

    .icon-with-text-style-07 .feature-box-icon {
        margin-bottom: 14px !important;
    }

    .icon-with-text-style-07 .feature-box-content {
        margin-top: 12px !important;
    }

    .row > .col.mb-30px {
        margin-bottom: 20px !important;
    }

    .stack-item .border-bottom {
        flex-wrap: wrap;
        gap: 8px 16px;
        padding-top: 20px !important;
        padding-bottom: 20px !important;
        margin-bottom: 24px !important;
    }

    .stack-item .border-bottom .flex-shrink-0 {
        margin-left: 0 !important;
    }

    /* Shorter editorial images keep key content within reach. */
    .one-third-screen {
        height: 280px !important;
    }

    /* Make primary actions easy to hit one-handed. */
    main .btn:not(.btn-link),
    .portal-auth .btn {
        display: flex;
        justify-content: center;
        width: 100%;
        min-height: 50px;
    }

    a.btn.hero-secondary-cta.btn-hover-animation-switch {
        min-height: 44px;
        align-items: center;
    }

    /* Avoid iOS input zoom and give form fields a clear touch area. */
    .contact-form-style-07 .form-label {
        margin-bottom: 8px !important;
    }

    .contact-form-style-07 .form-group {
        margin-bottom: 22px !important;
    }

    .contact-form-style-07 .form-control,
    .portal-auth .form-control {
        min-height: 48px;
        font-size: 16px;
    }

    .contact-form-style-07 textarea.form-control {
        min-height: 132px;
    }

    .contact-form-style-07 .opacity-4 {
        opacity: 0.68 !important;
        line-height: 1.5;
    }

    /* Footer links remain compact visually but have accessible hit areas. */
    .footer-dark li a {
        display: inline-flex;
        align-items: center;
        min-height: 44px;
    }

    .footer-dark .hover-arrow-swipe,
    .footer-dark div > a[href^="mailto:"] {
        display: inline-flex;
        align-items: center;
        min-height: 44px;
    }

    .footer-dark a[href^="mailto:"] {
        overflow-wrap: anywhere;
    }

    .footer-dark .fs-100 {
        font-size: clamp(26px, 8vw, 34px) !important;
        line-height: 1.1;
        white-space: normal !important;
    }
}

@media (max-width: 374px) {
    main section > .container-fluid,
    footer > .container-fluid {
        padding-left: 16px;
        padding-right: 16px;
    }

    .lang-switch__btn {
        min-width: 38px;
        padding-left: 5px;
        padding-right: 5px;
    }

    .icon-with-text-style-01 .feature-box-left-icon-middle {
        flex-direction: column;
        align-items: flex-start;
    }

    .icon-with-text-style-01 .feature-box-icon {
        margin-right: 0 !important;
        margin-bottom: 14px;
    }

    .icon-with-text-style-01 .feature-box-content {
        width: 100%;
    }
}
