
.hero-classic-section {
    position: relative;
    width: 100%;
    background: var(--color-bg-primary);
    padding: 0 var(--wrap);
    box-sizing: border-box;
    overflow: hidden;
}

@media (max-width: 1200px ) {
    .hero-classic-section {
        padding: 0 !important;
        margin:0;
    }
}

.hero-classic-container {
    position: relative;
    width: 100%;
    height: 90svh;
    min-height: 35rem;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.hero-classic-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 120%;
    object-fit: cover;
    object-position: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
    pointer-events: none;
    backface-visibility: hidden;
    transform: translateZ(0);
}

/* Promoting the image to its own layer only pays off where the parallax
   actually runs; below 900px hero-classic.js leaves the image still. */
@media (min-width: 900px) {
    .hero-classic-bg {
        will-change: transform;
    }
}

.hero-classic-container::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(10, 19, 45, 0.85) 0%, rgba(var(--color-blue-200--rgb), 0.45) 50%, rgba(var(--color-blue-200--rgb), 0.05) 100%);
    z-index: 1;
}

.hero-classic-content {
    position: relative;
    z-index: 2;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
    padding: 0 6%;

}

.hero-classic-title {
    font-family: "Roboto", sans-serif;
    color: var(--color-white);
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 600;
    line-height: 1.05;
    letter-spacing: 0;
    margin: 0;
}

.hero-classic-title strong {
    font-weight: 700;
}

.hero-classic-subtitle {
    font-family: "Roboto", sans-serif;
    color: rgba(255, 255, 255, 0.95);
    font-size: clamp(0.95rem, 3vw, 1.2rem);
    font-weight: 400;
    letter-spacing: 0.02em; 
    margin: 20px 0 0 0;
}

.hero-classic-nav {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 3;
    display: grid; 
    grid-template-columns: var(--widget-w, 70px) repeat(var(--blocks-count, 4), 1fr) var(--widget-w, 70px);
    transition: grid-template-columns 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border-top: 1px solid transparent;
    padding: 0 var(--wrap);
}

/* The nav spans the section's side padding too, so a real border ran past
   the photo onto the page background, where the dark theme shows it as a
   grey stub. The line is drawn over the photo only; the transparent border
   keeps the 1px that hero-classic.js counts in the nav height. */
.hero-classic-nav::before {
    content: '';
    position: absolute;
    top: -1px;
    left: var(--wrap);
    right: var(--wrap);
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.hero-classic-nav.is-scrolled {
    --widget-w: 0px;
}

.hero-classic-nav-item {
    position: relative;
    color: var(--color-white);
    text-decoration: none;
    padding: 1.1rem 20px;
    font-size: 1.1rem;
    font-weight: 500;
    line-height: 1.4;
    
    background: linear-gradient(to bottom, var(--color-blue-200, #16295b) 0%, var(--color-blue-200, #16295b) 50%, rgba(10, 19, 45, 0.5) 50%, rgba(10, 19, 45, 0.8) 100%);
    background-size: 100% 200%;
    background-position: bottom;
    transition: color 0.4s ease, background-position 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-classic-nav-item:not(:last-child)::before {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 40%;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
}

@media (hover: hover) {
    .hero-classic-nav-item:hover {
        color: var(--color-white);
        background-position: top;
    }
}

@media (max-width: 1200px) {
    .hero-classic-nav {
        position: relative;
        bottom: auto;
        left: auto;
        grid-template-columns: repeat(2, 1fr);
        padding: 0;
    }
    .hero-classic-nav::before {
        display: none;
    }
    .hero-classic-nav-item {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    .hero-classic-nav-item:nth-child(even)::before {
        display: none;
    }
    .hero-classic-nav-widget-placeholder {
        display: none !important;
    }
}

@media (max-width: 1200px) {

    .hero-classic-section.front-section {
        margin-top: 0 !important;
        padding-top: 0 !important;
    }

    .hero-classic-container {
        height: auto;
        min-height: 50svh;
        justify-content: center;
        padding: var(--header-height-1px, 70px) 0 30px;
        box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    }
    .hero-classic-content {
        flex-grow: 1;
        justify-content: center;
        padding: 0 var(--wrap-1);
        text-align: center;
        align-items: center;
    }
    .hero-classic-title {
        font-size: clamp(1.7rem, 5vw, 2.75rem);
        line-height: 1.15;
        letter-spacing: -0.01em;
        text-wrap: balance;
    }
    .hero-classic-subtitle {
        font-size: 1rem;
        line-height: 1.4;
        margin-top: 15px;
    }
    .hero-classic-nav {
        position: relative;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        background: rgba(var(--color-ink--rgb), 0.08);
        border-top: 1px solid rgba(var(--color-ink--rgb), 0.08);
        border-bottom: 1px solid rgba(var(--color-ink--rgb), 0.08);
        box-shadow: none;
        gap: 1px;
        padding: 0;
        width: 100%;
        margin-top: 0;
        height: auto;
    }
    .hero-classic-nav-item {
        padding: 18px 10px;
        font-size: 0.9rem;
        font-weight: 500;
        text-transform: none;
        line-height: 1.25;
        color: var(--color-text-heading);
        background: var(--color-bg-primary);
        border: none;
        border-radius: 0;
        text-align: center;
        display: flex;
        align-items: center;
        justify-content: center;
        text-shadow: none;
        transition: background 0.2s ease;
    }
    .hero-classic-nav-item:active {
        background: rgba(var(--color-ink--rgb), 0.15);
    }

    @media (hover: hover) {
        .hero-classic-nav-item:hover {
            color: var(--color-text-heading);
        }
    }

    .hero-classic-nav-item::before {
        display: none;
    }
}

.hero-classic-nav-widget-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    opacity: 1;
    transition: opacity 0.3s ease;
}
.hero-classic-nav.is-scrolled .hero-classic-nav-widget-placeholder {
    opacity: 0;
}
.hero-classic-nav-widget-placeholder.left-widget {
    border-right: 1px solid rgba(255, 255, 255, 0.2);
}
.hero-classic-nav-widget-placeholder.right-widget {
    border-left: 1px solid rgba(255, 255, 255, 0.2);
}

/* Base transitions for flying OUT of nav (return to bottom) */
/* Moves horizontally first (left/right 0s delay), then vertically (bottom 0.3s delay) */
.calendar-widget-btn, .cw-widget-wrapper {
    transition: left 0.3s ease 0s, right 0.3s ease 0s, bottom 0.3s ease 0.3s, width 0.3s, height 0.3s, background-color 0.3s, border-radius 0.3s !important;
}

.cw-widget-wrapper .cw-floating-btn {
    transition: width 0.3s ease, height 0.3s ease, border-radius 0.3s ease, background-color 0.3s ease !important;
}

.calendar-widget-btn .calendar-widget-btn__icon {
    transition: opacity 0.3s ease, transform 0.3s ease !important;
}

.cw-widget-wrapper .cw-floating-btn svg,
.calendar-widget-btn svg {
    transition: transform 0.3s ease, opacity 0.3s ease !important;
}


.calendar-widget-btn.in-nav {
    position: fixed !important;
    right: var(--nav-widget-right) !important;
    bottom: var(--nav-widget-bottom) !important;
    width: var(--nav-widget-width) !important;
    height: var(--nav-widget-height) !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    margin: 0 !important;
    display: flex !important;
    align-items: center !important;
    z-index: 9999 !important;
    border: none !important;
    box-sizing: border-box !important;
    
    background-color: transparent !important;
    color: var(--color-white) !important;
    
    transition: left 0.3s ease 0.3s, right 0.3s ease 0.3s, bottom 0.3s ease 0s, width 0.3s 0s, height 0.3s 0s !important;
}


.calendar-widget-btn.in-nav::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 40%;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
}

.calendar-widget-btn.in-nav .calendar-widget-btn__icon {
    width: 70px !important;
}

.calendar-widget-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, var(--color-blue-200, #16295b) 0%, var(--color-blue-200, #16295b) 50%, rgba(10, 19, 45, 0.5) 50%, rgba(10, 19, 45, 0.8) 100%);
    background-size: 100% 200%;
    background-position: bottom;
    opacity: 0;
    transition: opacity 0.3s ease, background-position 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
    z-index: 1;
}

.calendar-widget-btn.in-nav::after {
    opacity: 1 !important;
}

.calendar-widget-btn.in-nav:hover::after {
    background-position: top !important;
}

.calendar-widget-btn__icon,
.calendar-widget-btn__text {
    position: relative;
    z-index: 2;
}

.calendar-widget-btn.in-nav:hover {
    width: var(--in-nav-width, 70px) !important;
}
.calendar-widget-btn.in-nav .calendar-widget-btn__text {
    display: none !important;
}

.calendar-widget-btn.in-nav svg {
    width: 24px !important;
    height: 24px !important;
}

.calendar-widget-btn .calendar-widget-btn__counter {
    transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.32, 0.72, 0, 1), right 0.3s ease, border-color 0.3s ease !important;
}

.calendar-widget-btn.in-nav .calendar-widget-btn__counter {
    right: 13px !important;
    border-color: #0b142d !important;
}

.calendar-widget-btn.in-nav:hover .calendar-widget-btn__counter {
    border-color: var(--color-blue-200, #16295b) !important;
}



.cw-widget-wrapper.in-nav {
    position: fixed !important;
    left: var(--nav-widget-left) !important;
    bottom: var(--nav-widget-bottom) !important;
    width: var(--nav-widget-width) !important;
    height: var(--nav-widget-height) !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    margin: 0 !important;
    display: flex !important;
    align-items: stretch !important;
    justify-content: stretch !important;
    z-index: 9999 !important;
    background: transparent !important;
    border: none !important;
    box-sizing: border-box !important;
    transition: left 0.3s ease 0.3s, right 0.3s ease 0.3s, bottom 0.3s ease 0s, width 0.3s 0s, height 0.3s 0s !important;
}

.cw-widget-wrapper.in-nav .cw-floating-btn {
    width: 100% !important;
    height: 100% !important;
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    color: var(--color-white) !important;
    box-sizing: border-box !important;
    padding: 0 !important;
    margin: 0 !important;
    transition: none !important;
}

.cw-widget-wrapper.in-nav .cw-floating-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, var(--color-blue-200, #16295b) 0%, var(--color-blue-200, #16295b) 50%, rgba(10, 19, 45, 0.5) 50%, rgba(10, 19, 45, 0.8) 100%);
    background-size: 100% 200%;
    background-position: bottom;
    opacity: 1;
    transition: background-position 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
    z-index: 1;
}

.cw-widget-wrapper.in-nav .cw-floating-btn:hover::before {
    background-position: top;
}

.cw-widget-wrapper.in-nav .cw-floating-btn:hover {
    width: 100% !important;
}

.cw-widget-wrapper.in-nav .cw-floating-btn svg {
    left: 50% !important;
    margin-left: -13px !important;
    width: 26px !important;
    height: 26px !important;
    transition: left 0.3s ease, margin 0.3s ease, width 0.3s ease, height 0.3s ease !important;
    z-index: 2;
}

.cw-widget-wrapper.in-nav .cw-btn-text {
    display: none !important;
}

.cw-widget-wrapper.in-nav .cw-floating-btn::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 40%;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    z-index: 2;
}

@media (max-width: 1200px) {
    .hero-classic-nav-widget-placeholder {
        display: none;
    }
    .hero-classic-nav {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}