/* ==================== VARIABLES ==================== */
    :root {
        --primary-color: #1a5f3a;
        --primary-dark: #0f3d22;
        --primary-light: #2d8659;
        --secondary-color: #f39c12;
        --secondary-light: #f5b041;
        --text-dark: #2c3e50;
        --text-light: #7f8c8d;
        --text-muted: #95a5a6;
        --border-color: #ecf0f1;
        --light-bg: #f8f9fa;
        --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
        --shadow-md: 0 8px 16px rgba(0, 0, 0, 0.12);
        --shadow-lg: 0 12px 24px rgba(0, 0, 0, 0.15);
        --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }

    /* ==================== HERO SECTION ==================== */
    .ekstra-hero {
        background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 50%, var(--primary-light) 100%);
        color: white;
        padding: clamp(60px, 10vw, 100px) 20px;
        text-align: center;
        position: relative;
        overflow: hidden;
        min-height: 60vh;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .ekstra-hero::before {
        content: '';
        position: absolute;
        top: -50%;
        right: -10%;
        width: 600px;
        height: 600px;
        background: rgba(255, 255, 255, 0.08);
        border-radius: 50%;
        animation: float 8s ease-in-out infinite;
    }

    .ekstra-hero::after {
        content: '';
        position: absolute;
        bottom: -30%;
        left: -5%;
        width: 400px;
        height: 400px;
        background: rgba(255, 255, 255, 0.05);
        border-radius: 50%;
        animation: float 10s ease-in-out infinite reverse;
    }

    @keyframes float {
        0%, 100% { transform: translateY(0) translateX(0); }
        50% { transform: translateY(-30px) translateX(20px); }
    }

    .ekstra-hero-content {
        position: relative;
    z-index: 2;
    animation: slideInUp 0.8s ease-out;
    max-width: 900px;
    margin: 0 auto;
    }

    @keyframes slideInUp {
        from {
            opacity: 0;
            transform: translateY(40px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .ekstra-hero h1 {
        font-size: clamp(32px, 6vw, 56px);
        font-weight: 700;
        margin-bottom: 20px;
        line-height: 1.2;
        letter-spacing: -0.5px;
    }

    .ekstra-hero p {
        font-size: clamp(14px, 2vw, 18px);
        opacity: 0.95;
        line-height: 1.8;
        margin-bottom: 0;
    }

    .breadcrumb-ekstra {
        background: rgba(255, 255, 255, 0.15);
        padding: clamp(8px, 2vw, 12px) clamp(15px, 3vw, 25px);
        border-radius: 50px;
        display: inline-flex;
        gap: 12px;
        backdrop-filter: blur(10px);
        border: 1px solid rgba(255, 255, 255, 0.2);
        font-size: clamp(12px, 1.5vw, 14px);
        transition: var(--transition);
        margin-top: 20px;
    }

    .breadcrumb-ekstra a {
        color: white;
        text-decoration: none;
        transition: var(--transition);
    }

    .breadcrumb-ekstra a:hover {
        opacity: 0.8;
    }

    /* ==================== CONTENT SECTION ==================== */
    .ekstra-content-section {
        padding: clamp(60px, 10vw, 100px) 20px;
        background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
    }

    /* ==================== SECTION HEADER ==================== */
    .ekstra-section-header {
        text-align: center;
        max-width: 800px;
        margin: 0 auto clamp(40px, 8vw, 60px);
        animation: fadeInDown 0.8s ease-out;
    }

    @keyframes fadeInDown {
        from {
            opacity: 0;
            transform: translateY(-20px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .ekstra-section-header h2 {
        font-size: clamp(24px, 4vw, 40px);
        font-weight: 700;
        color: var(--primary-color);
        margin-bottom: 20px;
        position: relative;
        display: inline-block;
    }

    .ekstra-section-header h2::after {
        content: '';
        position: absolute;
        bottom: -12px;
        left: 50%;
        transform: translateX(-50%);
        width: 80px;
        height: 4px;
        background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
        border-radius: 2px;
    }

    .ekstra-section-header p {
        font-size: clamp(14px, 2vw, 18px);
        color: var(--text-light);
        line-height: 1.8;
        margin-top: 30px;
    }

    /* ==================== EKSTRAKURIKULER GRID - IMPROVED ==================== */
.ekstrakurikuler-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
    gap: clamp(24px, 3vw, 32px);
    margin-bottom: clamp(40px, 8vw, 60px);
    align-items: stretch;
}

/* ==================== EKSTRAKURIKULER CARD - ENHANCED ==================== */
.ekstra-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid rgba(0, 0, 0, 0.06);
    animation: fadeInUp 0.6s ease-out backwards;
}

.ekstra-card:nth-child(1) { animation-delay: 0.1s; }
.ekstra-card:nth-child(2) { animation-delay: 0.15s; }
.ekstra-card:nth-child(3) { animation-delay: 0.2s; }
.ekstra-card:nth-child(4) { animation-delay: 0.25s; }
.ekstra-card:nth-child(5) { animation-delay: 0.3s; }
.ekstra-card:nth-child(6) { animation-delay: 0.35s; }
.ekstra-card:nth-child(7) { animation-delay: 0.4s; }
.ekstra-card:nth-child(8) { animation-delay: 0.45s; }
.ekstra-card:nth-child(9) { animation-delay: 0.5s; }
.ekstra-card:nth-child(10) { animation-delay: 0.55s; }
.ekstra-card:nth-child(11) { animation-delay: 0.6s; }
.ekstra-card:nth-child(12) { animation-delay: 0.65s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.ekstra-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 16px 40px rgba(26, 95, 58, 0.15);
    border-color: var(--primary-light);
}

.ekstra-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color), var(--primary-color));
    opacity: 0;
    transition: opacity 0.4s ease;
}

.ekstra-card:hover::before {
    opacity: 1;
}

/* ==================== EKSTRA CARD HEADER - FIXED HEIGHT ==================== */
.ekstra-card-header {
    padding: clamp(30px, 5vw, 40px) clamp(20px, 4vw, 30px);
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 200px;
    max-height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    color: white;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
}

.ekstra-card-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.15), transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.ekstra-card:hover .ekstra-card-header::before {
    opacity: 1;
}

.ekstra-card-header i {
    font-size: clamp(44px, 6vw, 56px);
    color: white;
    position: relative;
    z-index: 2;
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.ekstra-card:hover .ekstra-card-header i {
    transform: scale(1.15) rotate(-5deg);
}

.ekstra-card-header h3 {
    color: white;
    font-size: clamp(18px, 3vw, 22px);
    font-weight: 700;
    margin: 0;
    position: relative;
    z-index: 2;
    line-height: 1.3;
    letter-spacing: -0.3px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

/* ==================== EKSTRA CARD BODY - EQUAL HEIGHT ==================== */
.ekstra-card-body {
    padding: clamp(24px, 4vw, 32px);
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    background: white;
}

.ekstra-info {
    display: flex;
    flex-direction: column;
    gap: 18px;
    flex-grow: 1;
}

.ekstra-info-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-radius: 10px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.ekstra-info-item:hover {
    background: white;
    border-color: var(--primary-light);
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(26, 95, 58, 0.08);
}

.ekstra-info-item i {
    color: var(--secondary-color);
    font-size: 20px;
    min-width: 24px;
    margin-top: 2px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.ekstra-info-item:hover i {
    transform: scale(1.2);
    color: var(--primary-color);
}

.ekstra-info-item div {
    flex: 1;
    min-width: 0;
}

.ekstra-info-item h4 {
    font-size: clamp(13px, 1.8vw, 15px);
    font-weight: 700;
    color: var(--primary-color);
    margin: 0 0 4px 0;
    letter-spacing: 0.3px;
}

.ekstra-info-item p {
    font-size: clamp(12px, 1.5vw, 14px);
    color: var(--text-light);
    margin: 0;
    line-height: 1.5;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* ==================== RESPONSIVE GRID ==================== */
@media (min-width: 1400px) {
    .ekstrakurikuler-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 1024px) and (max-width: 1399px) {
    .ekstrakurikuler-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .ekstrakurikuler-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
    
    .ekstra-card-header {
        min-height: 180px;
        max-height: 180px;
    }
}

@media (max-width: 767px) {
    .ekstrakurikuler-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .ekstra-card {
        max-width: 500px;
        margin-inline: auto;
    }
    
    .ekstra-card-header {
        min-height: 170px;
        max-height: 170px;
        padding: 25px 20px;
    }
    
    .ekstra-card-body {
        padding: 20px;
    }
    
    .ekstra-info {
        gap: 14px;
    }
    
    .ekstra-info-item {
        padding: 12px;
    }
}

@media (max-width: 480px) {
    .ekstrakurikuler-grid {
        gap: 16px;
    }
    
    .ekstra-card-header {
        min-height: 160px;
        max-height: 160px;
        padding: 20px 16px;
    }
    
    .ekstra-card-header i {
        font-size: 40px;
    }
    
    .ekstra-card-header h3 {
        font-size: 17px;
    }
    
    .ekstra-card-body {
        padding: 16px;
    }
    
    .ekstra-info {
        gap: 12px;
    }
    
    .ekstra-info-item {
        padding: 10px;
    }
    
    .ekstra-info-item i {
        font-size: 18px;
        min-width: 20px;
    }
}

/* ==================== ACCESSIBILITY & PERFORMANCE ==================== */
@media (prefers-reduced-motion: reduce) {
    .ekstra-card,
    .ekstra-card *,
    .ekstra-info-item {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ==================== LOADING STATE ==================== */
.ekstra-card.loading {
    pointer-events: none;
    opacity: 0.6;
}

.ekstra-card.loading::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}
    
    /* ==================== BENEFITS SECTION ==================== */
    .benefits-section {
        background: white;
        padding: clamp(40px, 6vw, 60px);
        border-radius: 20px;
        box-shadow: var(--shadow-lg);
        animation: fadeInUp 0.8s ease-out 0.5s both;
        border: 1px solid var(--border-color);
    }

    .benefits-header {
        text-align: center;
        margin-bottom: clamp(40px, 8vw, 60px);
    }

    .benefits-header h3 {
        font-size: clamp(22px, 4vw, 36px);
        font-weight: 700;
        color: var(--primary-color);
        margin-bottom: 15px;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
    }

    .benefits-header h3 i {
        color: var(--secondary-color);
        font-size: clamp(24px, 4vw, 32px);
    }

    .benefits-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: clamp(20px, 3vw, 30px);
    }

    .benefit-item {
        text-align: center;
        padding: clamp(20px, 3vw, 30px);
        background: linear-gradient(135deg, #f8f9fa, #ffffff);
        border-radius: 15px;
        border: 1px solid var(--border-color);
        transition: var(--transition);
        animation: fadeInUp 0.6s ease-out backwards;
    }

    .benefit-item:nth-child(1) { animation-delay: 0.1s; }
    .benefit-item:nth-child(2) { animation-delay: 0.2s; }
    .benefit-item:nth-child(3) { animation-delay: 0.3s; }
    .benefit-item:nth-child(4) { animation-delay: 0.4s; }
    .benefit-item:nth-child(5) { animation-delay: 0.5s; }
    .benefit-item:nth-child(6) { animation-delay: 0.6s; }

    .benefit-item:hover {
        transform: translateY(-10px);
        box-shadow: var(--shadow-md);
        background: white;
    }

    .benefit-icon {
        width: clamp(60px, 8vw, 80px);
        height: clamp(60px, 8vw, 80px);
        background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
        border-radius: 15px;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0 auto clamp(15px, 3vw, 20px);
        color: white;
        font-size: clamp(28px, 4vw, 40px);
        box-shadow: 0 8px 20px rgba(26, 95, 58, 0.2);
        transition: var(--transition);
    }

    .benefit-item:hover .benefit-icon {
        transform: scale(1.1) rotate(5deg);
        box-shadow: 0 12px 30px rgba(26, 95, 58, 0.3);
    }

    .benefit-item h4 {
        font-size: clamp(16px, 2vw, 20px);
        font-weight: 700;
        color: var(--primary-color);
        margin-bottom: 10px;
    }

    .benefit-item p {
        color: var(--text-light);
        font-size: clamp(13px, 1.5vw, 15px);
        line-height: 1.6;
        margin: 0;
    }

    /* ==================== STATS ==================== */
    .stats-ekstra {
        background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
        color: white;
        padding: clamp(30px, 5vw, 50px);
        border-radius: 15px;
        margin: clamp(40px, 8vw, 60px) 0;
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: clamp(20px, 3vw, 30px);
        text-align: center;
        animation: fadeInUp 0.8s ease-out 0.4s both;
    }

    .stat-ekstra-item {
        animation: scaleIn 0.6s ease-out backwards;
    }

    .stat-ekstra-item:nth-child(1) { animation-delay: 0.1s; }
    .stat-ekstra-item:nth-child(2) { animation-delay: 0.2s; }
    .stat-ekstra-item:nth-child(3) { animation-delay: 0.3s; }
    .stat-ekstra-item:nth-child(4) { animation-delay: 0.4s; }

    @keyframes scaleIn {
        from {
            opacity: 0;
            transform: scale(0.8);
        }
        to {
            opacity: 1;
            transform: scale(1);
        }
    }

    .stat-ekstra-number {
        font-size: clamp(28px, 4vw, 42px);
        font-weight: 700;
        margin-bottom: 8px;
    }

    .stat-ekstra-label {
        font-size: clamp(12px, 1.5vw, 14px);
        opacity: 0.9;
    }

    /* ==================== RESPONSIVE ==================== */
    @media (max-width: 1024px) {
        .ekstrakurikuler-grid {
            grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        }

        .benefits-section {
            padding: 40px 30px;
        }
    }

    @media (max-width: 768px) {
        .ekstra-hero {
            min-height: 50vh;
            padding: 50px 20px;
        }

        .ekstrakurikuler-grid {
            grid-template-columns: 1fr;
            gap: 20px;
        }

        .ekstra-card-header {
            min-height: 180px;
            padding: 25px 20px;
        }

        .benefits-section {
            padding: 30px 20px;
        }

        .benefits-grid {
            grid-template-columns: 1fr;
            gap: 15px;
        }

        .achievements-grid {
            grid-template-columns: 1fr;
            gap: 15px;
        }

        .stats-ekstra {
            grid-template-columns: repeat(2, 1fr);
            gap: 15px;
        }
    }

    @media (max-width: 480px) {
        .ekstra-hero {
            min-height: 45vh;
            padding: 40px 15px;
        }

        .ekstra-content-section {
            padding: 40px 15px;
        }

        .ekstrakurikuler-grid {
            gap: 15px;
        }

        .ekstra-card {
            border-radius: 12px;
        }

        .ekstra-card-header {
            padding: 20px 15px;
            min-height: 170px;
        }

        .ekstra-card-body {
            padding: 15px;
        }

        .ekstra-info {
            font-size: 12px;
            margin-bottom: 12px;
        }

        .prestasi-box {
            padding: 10px;
            margin: 12px 0;
        }

        .prestasi-box p {
            font-size: 12px;
        }

        .daftar-btn {
            padding: 10px 15px;
            font-size: 12px;
        }

        .benefits-header h3 {
            font-size: 20px;
        }

        .benefit-item {
            padding: 15px;
        }

        .benefit-icon {
            width: 60px;
            height: 60px;
            font-size: 28px;
            margin-bottom: 12px;
        }

        .achievements-header h3 {
            font-size: 20px;
        }

        .achievement-card {
            padding: 15px;
        }

        .achievement-title h4 {
            font-size: 15px;
        }

        .achievement-text {
            font-size: 12px;
        }

        .stats-ekstra {
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            padding: 20px;
        }

        .stat-ekstra-number {
            font-size: 24px;
        }

        .stat-ekstra-label {
            font-size: 11px;
        }

        .breadcrumb-ekstra {
            font-size: 11px;
            padding: 6px 10px;
            gap: 6px;
        }
    }

    @media (max-width: 360px) {
        .ekstra-hero h1 {
            font-size: 22px;
        }

        .ekstra-card-header h3 {
            font-size: 16px;
        }

        .stats-ekstra {
            grid-template-columns: 1fr;
        }
    }

    /* ==================== ANIMATIONS ==================== */
    @keyframes expandWidth {
        from {
            transform: scaleX(0);
            transform-origin: left;
        }
        to {
            transform: scaleX(1);
            transform-origin: left;
        }
    }

    .divider {
        height: 2px;
        background: linear-gradient(90deg, transparent, var(--secondary-color), transparent);
        margin: 40px 0;
        animation: expandWidth 1s ease-out;
    }

    /* ==================== ACCESSIBILITY ==================== */
    @media (prefers-reduced-motion: reduce) {
        *,
        *::before,
        *::after {
            animation-duration: 0.01ms !important;
            animation-iteration-count: 1 !important;
            transition-duration: 0.01ms !important;
        }
    }

/* ==================== UI POLISH (NO COLOR/CONTENT CHANGES) ==================== */
:where(.ekstra-hero .container, .ekstra-content-section .container, .ekstra-detail .container) {
    width: min(1200px, 100%);
    margin-inline: auto;
    padding-inline: clamp(15px, 3vw, 24px);
}

.reveal {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.6s ease, transform 0.6s ease;
    will-change: opacity, transform;
}
.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.ekstra-hero-content { text-align: center; }
.breadcrumb-ekstra { justify-content: center; flex-wrap: wrap; }

.ekstra-card,
.benefits-section,
.achievement-card,
.benefit-item {
    border: 1px solid var(--border-color);
}

.ekstra-card:focus-within,
.achievement-card:focus-within,
.benefit-item:focus-within {
    box-shadow: var(--shadow-lg);
}

.daftar-btn:focus-visible {
    outline: 3px solid rgba(243, 156, 18, 0.55);
    outline-offset: 3px;
}
.daftar-btn:active { transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
    .reveal,
    .reveal.is-visible {
        transition: none !important;
        transform: none !important;
        opacity: 1 !important;
    }
}

/* ==================== PRESTASI LIST STYLING ==================== */
.prestasi-list {
    font-size: clamp(12px, 1.5vw, 14px);
    color: var(--text-light);
    line-height: 1.8;
    margin: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Styling untuk setiap baris prestasi */
.prestasi-list br + * {
    display: block;
    margin-top: 8px;
}

/* Optional: Tambahkan bullet point otomatis jika mau */
.prestasi-list-bullets {
    font-size: clamp(12px, 1.5vw, 14px);
    color: var(--text-light);
    line-height: 1.8;
    margin: 0;
    padding-left: 0;
    list-style: none;
}

.prestasi-list-bullets li {
    position: relative;
    padding-left: 24px;
    margin-bottom: 8px;
}

.prestasi-list-bullets li::before {
    content: '🏆';
    position: absolute;
    left: 0;
    top: 0;
    font-size: 14px;
}

/* Alternative dengan icon FontAwesome */
.prestasi-list-bullets.fa-style li::before {
    content: '\f091'; /* fa-trophy */
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    color: var(--secondary-color);
}

/* Tambahkan padding pada prestasi info item agar tidak terlalu rapat */
.ekstra-info-item .prestasi-list {
    padding-top: 4px;
}

/* Styling untuk text muted (jika belum ada prestasi) */
.ekstra-info-item .text-muted {
    font-size: clamp(12px, 1.5vw, 14px);
    font-style: italic;
    opacity: 0.7;
}