/* =====================================================================
   SmartWaste MCD - BWG Operations Portal
   Learn & Participate Section (video explainers)
   Dark section on purpose - visually separates from the light
   features section above it. Uses --font-body / --accent-lime tokens.
   Cards scroll horizontally instead of growing the grid, so this
   stays usable at 50+ videos.
   ===================================================================== */

.learn-section {
    background: #103D20;
    padding: 90px 40px;
    position: relative;
}

.learn-inner {
    max-width: 1200px;
    margin: 0 auto;
}

/* .learn-eyebrow {
    display: block;
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent-lime);
    margin-bottom: 16px;
} */
.learn-eyebrow {
    display: inline-block;
    font-family: var(--font-body);
    font-size: 12.5px;
    font-weight: 700;
    color: var(--accent-lime-dark);
    background: var(--accent-lime);
    padding: 6px 16px;
    border-radius: 30px;
    margin-bottom: 18px;
}


.learn-heading {
    font-family: var(--font-body);
    font-size: 38px;
    line-height: 1.2;
    font-weight: 800;
    color: #FFFFFF;
    margin: 0 0 14px;
}

.learn-heading .highlight {
    color: var(--accent-lime);
}

.learn-description {
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.65);
    max-width: 560px;
    margin: 0 0 28px;
}

/* ---------- Scroll controls ---------- */
.learn-scroll-controls {
    display: flex;
    gap: 10px;
    margin-bottom: 24px;
}

.learn-scroll-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #FFFFFF;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.learn-scroll-btn:hover {
    background: var(--accent-lime);
    color: var(--accent-lime-dark);
}

/* ---------- Horizontal scrolling grid ---------- */
.learn-grid {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 12px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.25) transparent;
}

.learn-grid::-webkit-scrollbar {
    height: 6px;
}

.learn-grid::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.25);
    border-radius: 10px;
}

.learn-card {
    flex: 0 0 320px;
    scroll-snap-align: start;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 14px;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease;
}

.learn-card:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.08);
}

.learn-thumb {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    aspect-ratio: 16 / 10;
    background: rgba(0, 0, 0, 0.3);
    margin-bottom: 16px;
}

.learn-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0.85;
}

.learn-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #FFFFFF;
    color: #141414;
    font-family: var(--font-body);
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 5px 10px;
    border-radius: 30px;
}

.learn-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--accent-lime);
    color: var(--accent-lime-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
}

.learn-card-title {
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 700;
    color: #FFFFFF;
    margin: 0 0 8px;
}

.learn-card-text {
    font-family: var(--font-body);
    font-size: 13px;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.55);
    margin: 0;
}

/* ---------- Modal ---------- */
.learn-modal {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: none;
    align-items: center;
    justify-content: center;
}

.learn-modal.is-open {
    display: flex;
}

.learn-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
}

.learn-modal-box {
    position: relative;
    width: min(880px, 92vw);
    aspect-ratio: 16 / 9;
    z-index: 1;
}

.learn-modal-frame,
.learn-modal-frame iframe {
    width: 100%;
    height: 100%;
    border-radius: 10px;
}

.learn-modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: #FFFFFF;
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .learn-heading {
        font-size: 30px;
    }
}

@media (max-width: 640px) {
    .learn-section {
        padding: 60px 20px;
    }

    .learn-card {
        flex-basis: 260px;
    }
}