/* About Us CSS */

/* --- Container & Row Basics --- */
.abt-container { width: 100%; overflow-x: hidden; background-color: #fff; }
.abt-container p { font-size: 1.25rem; line-height: 1.6; margin-bottom: 25px; }

.abt-row, .abt-c2a-row {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    width: 100%;
}

/* --- Column Widths (62% Visual / 38% Text) --- */
.abt-visual-col { 
    width: 62%; 
    position: relative; 
    overflow: hidden; 
    display: flex; 
    align-items: center; 
}

.abt-text-col { 
    width: 38%; 
    display: flex; 
    flex-direction: column; 
    justify-content: space-between; 
    padding: 60px; 
    box-sizing: border-box; 
    min-height: 100%;
    position: relative; /* Anchor for Overbar */
}

/* --- Row Alternation & Zebra Backgrounds --- */
.abt-alt-row { flex-direction: row-reverse; }

/* Strict Zebra Logic */
.abt-row:nth-child(odd)  { background-color: #fff; color: #333; } 
.abt-row:nth-child(even) { background-color: #333; color: #fff; }
.abt-c2a-row { background-color: #fff; color: #333; }

/* --- Hero & Overbar Fix --- */
.abt-hero-row { position: relative; }

.Title-1-overbar {
    position: absolute;
    top: 15%;
    right: 0;
    width: 65%; /* 65% width of the text column */
    background-color: rgba(52,52,52,0.75);
    color: #FFF;
    padding: 1.5rem 2rem;
    text-align: left;
    z-index: 30;
    margin: 0;
    white-space: nowrap;
    font-weight: bold;
}

/* Give the Hero <p> room for the overbar on Desktop only */
@media (min-width: 974px) {
    .abt-hero-row .abt-text-col p { margin-top: 120px; }
}

/* Mobile Landscape Hero Overbar tweaks */
@media (max-width: 973px) and (max-height: 480px){
    .Title-1-overbar {
        width: 75%;
        top: 15%;
    }
    .abt-hero-row .abt-text-col p
    {
        margin-top: 100px;
        font-size: 1.25em;
    }

}

/* Mobile Device Portrait Hero Overbar Tweaks */
@media (max-width: 973px) and (min-height: 481px){
    .Title-1-overbar {
        width: 80%;
        font-size: 18px;
        transform: scale(1.3);
    transform-origin: left top;
        white-space: normal;
        font-weight: 800 ;
    }
    
}

/* --- Slideshow & Images --- */
.abt-slideshow-container { 
    position: relative; 
    width: 100%; 
    aspect-ratio: 16/9; 
    cursor: pointer;
    overflow: hidden; /* Ensures layers don't spill out */
    background-color: #000;
}

/* New A-B Layer Rules */
.abt-slide-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: auto;
    will-change: opacity;
    transition: opacity 0.5s ease; /* Matches JS cross-fade timing */
}

/* Fallback/Static Image styling */
.abt-visual-col img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    display: block; 
}

/* --- Transition & Layout --- */
/* Note: active-slide is now replaced by abt-slide-layer in JS Block 2 */
.active-text-target {
    transition: opacity 0.4s ease-in-out;
    display: flex;
    flex-direction: column;
    flex-grow: 1; 
}

.abt-counter {
    position: absolute;
    bottom: 15px;
    right: 20px;
    color: #fff;
    background: rgba(0, 0, 0, 0.4);
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    z-index: 15;
    pointer-events: none;
}

/* --- Slideshow Navigation UI --- */
.KMM-image-nav-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    pointer-events: none;
    z-index: 10;
}

.KMM-nav-zone {
    height: 100%;
    width: 20%;
    display: flex;
    align-items: center;
    position: absolute;
    top: 0;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: auto;
}

.KMM-nav-zone-left { left: 0; justify-content: flex-start; padding-left: 1.5rem; }
.KMM-nav-zone-right { right: 0; justify-content: flex-end; padding-right: 1.5rem; }
.KMM-nav-zone:hover { opacity: 1; }

.KMM-nav-arrow { background: transparent; border: none; padding: 0; cursor: pointer; }
.KMM-nav-arrow svg { width: 4.5rem; height: 4.5rem; stroke: #eee; fill: none; stroke-width: 2; }

/* --- JS-Injected Action Buttons --- */
.abt-btn-container {
    margin-top: auto; 
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.abt-btn-row {
    display: flex;
    align-items: center;
}

.abt-btn-pause, 
.abt-btn-reset, 
.abt-btn-fullscreen {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    cursor: pointer;
    display: flex;
    align-items: center;
    color: inherit;
    font-size: 0.95rem;
    font-family: inherit;
    transition: transform 0.1s ease, opacity 0.2s ease;
    text-decoration: none !important;
    /* Natural state: Dimmed */
    opacity: 0.5;
}

.abt-btn-icon {
    width: 32px;
    height: 32px;
    margin-right: 8px;
    pointer-events: none;
    display: block;
}

/* Hover: Rise up and go to full brightness */
.abt-btn-pause:hover, 
.abt-btn-reset:hover, 
.abt-btn-fullscreen:hover {
    transform: translateY(-2px);
    opacity: 1;
}

/* Click state */
.abt-btn-pause:active, 
.abt-btn-reset:active, 
.abt-btn-fullscreen:active {
    transform: translateY(1px);
}

/* --- Theater Mode Lightbox (Revised) --- */
.abt-lightbox-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.98);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.abt-lb-visual-stage {
    position: relative;
    flex-grow: 1;
    width: 100%;
    display: flex;
    flex-direction: column; /* Allows vertical stacking of img and info-box */
    align-items: center;
    justify-content: center;
    background: transparent;
}

/* Theater Mode Counter Positioning */
.abt-lb-visual-stage .abt-counter {
    top: 20px;
    right: 20px;
    bottom: auto; /* Overrides the grid's bottom: 15px */
}

.abt-lb-img {
    position: absolute;
    width: 90%; /* Matches the slide width for alignment */
    max-height: 85vh;
    object-fit: contain;
    transition: opacity 0.8s ease-in-out;
    left: 50%; top: 50%;
    transform: translate(-50%, -50%);
}

.abt-lb-info-box {
    width: 90%; /* Consistent 90% width logic */
    box-sizing: border-box;
    z-index: 10001;
    display: flex;
}

/* --- Theater Mode Lightbox --- */
.abt-lightbox-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.98);
    z-index: 9999;
    display: flex;
    align-items: center; 
    justify-content: center;
    overflow-y: auto;
}

.abt-lb-content-wrapper {
    position: relative;
    width: 90%;
    display: flex;
    flex-direction: column;
}

.abt-lb-visual-stage {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9; 
    overflow: hidden;
}

.abt-lb-img {
    position: absolute;
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: opacity 0.8s ease-in-out;
}

.abt-lb-info-box {
    width: 100%;
    box-sizing: border-box;
    z-index: 10001;
}

/* Controls - Fixed to Viewport */
.abt-lb-close { 
    position: fixed; top: 20px; right: 30px; 
    color: #fff; font-size: 3rem; cursor: pointer; 
    z-index: 10010; line-height: 1;
}
.abt-lb-nav { 
    position: fixed; top: 40%; color: #fff; 
    font-size: 4rem; cursor: pointer; padding: 20px; 
    z-index: 10010; opacity: 0.2;
}
.abt-lb-prev { left: 10px; }
.abt-lb-next { right: 10px; }


/* --- Desktop Specific Theater Mode --- */
@media (min-width: 974px) {
    .abt-lb-content-wrapper {
        max-width: 1613px; 
        max-height: 85vh;
    }
     
    .abt-lb-info-box {
        position: absolute; 
        bottom: 0; left: 0;
        background: rgba(0, 0, 0, 0.75);
        color: #fff;
        padding: 30px 60px;
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-end;
        opacity: 50%;
    }
    .abt-lb-text-content { width: 65%; }
    .abt-lb-info-box .abt-btn-container { width: 30%; text-align: right; }
}

/* --- Mobile Landscape Theater Mode --- */
@media (max-width: 973px) and (max-height: 480px) {
    .abt-lb-content-wrapper {
        max-width: 1613px; 
        max-height: 85vh;
    }
     
    .abt-lb-info-box {
        position: absolute; 
        bottom: 0; left: 0;
        background: rgba(0, 0, 0, 0.55);
        color: #fff;
        padding: 20px 100px;
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-end;
        opacity: 70%;
    }
    .abt-lb-text-content { width: 65%; }
    .abt-lb-info-box .abt-btn-container { width: 30%; text-align: right; }
}

/* --- Consolidated Mobile Styles --- */
@media (max-width: 973px) and (min-height: 481px) {
    /* 1. Global Row Stacking */
    .abt-row, .abt-alt-row, .abt-c2a-row { 
        flex-direction: column !important; 
    }
    .abt-visual-col, .abt-text-col { 
        width: 100% !important; 
    }

    /* 2. Lightbox Mobile Overrides */
    .abt-lb-content-wrapper {
        width: 95%;
        aspect-ratio: auto;
    }
    .abt-lb-info-box {
        position: relative; 
        background: #333; 
        color: #fff;
        padding: 30px;
        margin-top: 20px; 
        display: flex;
        flex-direction: column;
    }
    .abt-lb-info-box .abt-btn-container {
        margin-top: 20px;
        padding-top: 20px;
        border-top: 1px solid rgba(255,255,255,0.1);
    }

    /* 3. Row 5 (CTA) Specific Mobile Override */
    .abt-c2a-row {
        padding: 20px !important; 
        box-sizing: border-box;
    }
    .abt-c2a-row .abt-visual-col img {
        padding: 0;
        width: 100%;
        height: auto;
    }
} 

/* --- Desktop Row 5 (CTA) Fix --- */
@media (min-width: 974px) {
    .abt-c2a-row .abt-visual-col, 
    .abt-c2a-row .abt-text-col { 
        width: 50% !important; 
    }
    
    .abt-c2a-row .abt-visual-col img { 
        padding: 20px; /* Restored the heavy padding you wanted */
        box-sizing: border-box; 
        object-fit: contain; /* Keeps the CTA image from stretching weirdly */
    }
}

/* End About Us Special CSS */