/* SteFi static site overrides */

html {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after {
    font-family: inherit;
}

/* Sticky header — desktop stays above page content */
.stefi-site-header {
    position: sticky;
    top: 0;
    background: #f1efed;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.12);
}

@media (min-width: 960px) {
    .stefi-site-header {
        z-index: 10000;
    }

    .stefi-site-header .tm-header {
        position: relative;
        z-index: 10000;
    }
}

.stefi-site-header .uk-navbar-container {
    background: #f1efed !important;
}

.stefi-site-content {
    position: relative;
}

/* Mobile: sticky navbar above content; offcanvas lives outside header wrapper */
@media (max-width: 959px) {
    .stefi-site-header {
        position: relative;
        z-index: auto;
    }

    .tm-header-mobile .uk-navbar-container {
        position: sticky;
        top: 0;
        z-index: 1020;
        background: #f1efed;
        min-height: 50px;
    }

    .tm-header-mobile .uk-navbar {
        position: relative;
        z-index: 1021;
    }

    .tm-header-mobile .uk-navbar-toggle {
        position: relative;
        z-index: 1022;
        pointer-events: auto;
    }

    .stefi-site-content {
        z-index: auto;
        padding-top: 0;
    }

    /* Horizontal inset for text — keep hero, thumbnav, and map iframes full bleed */
    .stefi-site-content .stefi-text-block,
    .stefi-site-content .stefi-intro-block {
        padding-left: 1.25rem;
        padding-right: 1.25rem;
    }

    .stefi-site-content .uk-container:not(.stefi-thumbnav) {
        padding-left: 1.25rem;
        padding-right: 1.25rem;
    }

    /* Page content stays below the menu layer on mobile */
    .tm-page-container {
        position: relative;
        z-index: 1;
    }

    /* Hero / slider — low z-index so it never paints over the menu */
    .stefi-hero-wrap,
    .stefi-hero-wrap .uk-slider,
    .stefi-hero-wrap .uk-slider-container,
    .stefi-hero-wrap .uk-slider-items,
    .stefi-hero-wrap .stefi-slide,
    .stefi-thumbnav {
        position: relative;
        z-index: 0 !important;
        margin-top: 0;
    }

    .stefi-slider-arrow,
    .stefi-slide-caption {
        z-index: 1 !important;
    }

    /* Mobile menu — always on top */
    #tm-mobile {
        position: fixed !important;
        inset: 0 !important;
        z-index: 99999 !important;
    }

    #tm-mobile.uk-offcanvas-overlay::before {
        position: fixed !important;
        inset: 0 !important;
        z-index: 0 !important;
        background: rgba(0, 0, 0, 0.55) !important;
        opacity: 1 !important;
    }

    #tm-mobile .uk-offcanvas-bar {
        position: fixed !important;
        top: 0 !important;
        bottom: 0 !important;
        left: 0 !important;
        z-index: 1 !important;
        background: #29201a !important;
    }

    /* When menu is open: hide page content (iOS ignores z-index on transformed sliders) */
    html.stefi-menu-open .tm-page-container,
    html.uk-offcanvas-page .tm-page-container {
        visibility: hidden !important;
        pointer-events: none !important;
    }

    .stefi-site-header .tm-header-mobile .uk-logo img {
        max-height: 50px;
        width: auto;
        max-width: calc(100vw - 70px);
    }

    html {
        scroll-padding-top: 60px;
    }
}

/* Prevent parallax/fixed backgrounds from painting over the nav */
.uk-background-fixed {
    background-attachment: scroll !important;
}

.stefi-hero-wrap {
    margin-top: -10px;
    margin-bottom: 2.5rem;
}

.stefi-hero-wrap .uk-slider {
    position: relative;
}

.stefi-slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    color: rgba(255, 255, 255, 0.92) !important;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.55));
    transition: color 0.2s ease, transform 0.2s ease, opacity 0.2s ease;
    opacity: 0.85;
}

.stefi-slider-arrow:hover {
    background: transparent;
    color: #fff !important;
    opacity: 1;
    transform: translateY(-50%) scale(1.08);
}

.stefi-slider-arrow svg {
    width: 32px;
    height: 32px;
}

.stefi-slider-arrow--prev {
    left: 16px;
}

.stefi-slider-arrow--next {
    right: 16px;
}

.stefi-slide {
    position: relative;
    height: 470px;
    background-size: cover;
    background-position: center;
}

.stefi-slide-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.15);
}

.stefi-slide-caption {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 900px;
    color: #fff;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
    z-index: 2;
}

.stefi-slide-title {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 2.25rem;
    font-weight: 600;
    margin: 0 0 0.5rem;
    color: #fff;
}

.stefi-slide-sub {
    display: inline-block;
    max-width: min(92vw, 540px);
    margin: 0.5rem auto 0;
    padding: 0.6rem 1.25rem;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 1.125rem;
    font-weight: 400;
    line-height: 1.45;
    color: #333;
    text-align: center;
    background: rgba(255, 255, 255, 0.92);
    border-radius: 8px;
    box-shadow: 0 2px 14px rgba(0, 0, 0, 0.18);
    box-sizing: border-box;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

.stefi-slide-sub--single {
    border-radius: 999px;
    padding: 0.5rem 1.4rem;
}

.stefi-slide-sub-line {
    display: block;
}

.stefi-slide-sub-line + .stefi-slide-sub-line {
    margin-top: 0.2rem;
}

.stefi-intro-block,
.stefi-text-block {
    background: none !important;
    padding: 1.5rem 0;
}

.stefi-contact-section {
    background: none !important;
    padding: 3rem 1.5rem;
}

.stefi-contact-text {
    padding: 2rem 1.5rem;
    max-width: 48rem;
    margin: 0 auto;
}

.stefi-contact-text p {
    text-align: center;
    line-height: 1.65;
    margin: 0;
}

.stefi-contact-text p:first-child {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.stefi-contact-text p:not(:first-child) {
    font-size: 2rem;
    margin-top: 1.25rem;
}

.stefi-contact-text strong {
    font-weight: 700;
}

.stefi-thumbnav {
    background: rgba(164, 166, 166, 0.59);
    padding: 0.5rem 0.75rem;
    box-shadow: 5px 5px 0 0 #ced3d5;
    border: 2px solid rgba(0, 0, 0, 0.51);
    box-sizing: border-box;
}

.stefi-thumbnav.uk-container {
    max-width: none;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

.stefi-thumbnav .uk-thumbnav {
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-between;
    align-items: stretch;
    width: 100%;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.stefi-thumbnav .uk-thumbnav > * {
    padding-left: 0;
    margin: 0;
    flex: 0 0 auto;
}

.stefi-thumbnav a {
    display: block;
    width: 192px;
    height: 150px;
    overflow: hidden;
    line-height: 0;
}

.stefi-thumbnav img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    opacity: 0.55;
    transition: opacity 0.3s;
}

.stefi-thumbnav li.uk-active img,
.stefi-thumbnav a:hover img {
    opacity: 1;
}

@media (max-width: 1199px) {
    .stefi-hero-wrap {
        margin-bottom: 1.5rem;
    }

    .stefi-slide {
        height: 250px;
    }

    .stefi-slide-title {
        font-size: 1.5rem;
    }

    .stefi-slide-sub {
        font-size: 1rem;
        padding: 0.5rem 1rem;
        max-width: 92vw;
    }

    .stefi-slide-sub--single {
        padding: 0.45rem 1.1rem;
    }

    .stefi-slider-arrow {
        width: 44px;
        height: 44px;
        opacity: 1;
    }

    .stefi-slider-arrow svg {
        width: 28px;
        height: 28px;
    }

    .stefi-slider-arrow--prev {
        left: 8px;
    }

    .stefi-slider-arrow--next {
        right: 8px;
    }

    .stefi-thumbnav {
        padding: 0.4rem 0.5rem;
    }

    .stefi-thumbnav .uk-thumbnav {
        flex-wrap: nowrap;
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        gap: 4px;
        padding-bottom: 2px;
    }

    .stefi-thumbnav a {
        width: 100px;
        height: 78px;
    }
}

@media (max-width: 700px) {
    .stefi-slide {
        height: 200px;
    }

    .stefi-slide-title {
        font-size: 1.25rem;
    }

    .stefi-slide-sub {
        font-size: 0.95rem;
        padding: 0.45rem 0.9rem;
        max-width: 95vw;
    }

    .stefi-slide-sub--single {
        padding: 0.4rem 1rem;
    }

    .stefi-thumbnav a {
        width: 80px;
        height: 62px;
    }

    .stefi-slider-arrow {
        width: 48px;
        height: 48px;
    }

    .stefi-slider-arrow svg {
        width: 26px;
        height: 26px;
    }
}
