/**
 * ============================================================================
 * CBMI (Cakrabuana Muda Indonesia) - Official Educational & Martial Arts Theme
 * Production Version 4.0
 * 
 * Palette:
 * - Merah Marun Kehormatan (#7A0C0C / #5B0808 / #9E1313)
 * - Putih Gading & Mutiara (#FFFFFF / #FDFBF7 / #F8F5EE)
 * - List Emas Kerajaan (#D4AF37 / #F7D774 / #B8860B)
 * - Hijau Zamrud Pembinaan (#15803D / #166534 / #DCFCE7)
 * ============================================================================
 */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700;800&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    --font-heading: 'Cinzel', Georgia, serif;
    --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

    /* Maroon Shades */
    --cbmi-maroon-deep: #1A0303;
    --cbmi-maroon-dark: #3F0606;
    --cbmi-maroon: #7A0C0C;
    --cbmi-maroon-rich: #9E1313;
    --cbmi-maroon-light: #FEE2E2;

    /* Gold Shades */
    --cbmi-gold: #D4AF37;
    --cbmi-gold-light: #F7D774;
    --cbmi-gold-dark: #A17C18;
    --cbmi-gold-border: 1px solid rgba(212, 175, 55, 0.45);
    --cbmi-gold-gradient: linear-gradient(135deg, #F7D774 0%, #D4AF37 50%, #996515 100%);
    --cbmi-gold-glow: 0 0 25px rgba(212, 175, 55, 0.35);

    /* Neutral & Background */
    --cbmi-white: #FFFFFF;
    --cbmi-ivory: #FDFBF7;
    --cbmi-stone: #F7F3ED;
    --cbmi-text-dark: #1F1512;
    --cbmi-text-muted: #6B5B53;

    /* Emerald */
    --cbmi-emerald: #15803D;
    --cbmi-emerald-dark: #166534;
    --cbmi-emerald-subtle: #F0FDF4;

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(31, 21, 18, 0.05);
    --shadow-md: 0 8px 24px rgba(31, 21, 18, 0.08);
    --shadow-lg: 0 16px 40px rgba(122, 12, 12, 0.12);
    --shadow-card-hover: 0 16px 36px rgba(122, 12, 12, 0.15), 0 0 0 1.5px var(--cbmi-gold);

    /* Bootstrap Overrides */
    --bs-primary: #7A0C0C !important;
    --bs-secondary: #D4AF37 !important;
    --bs-success: #15803D !important;
}

/* ─────────────────────────────────────────────────────────────
   GLOBAL RESETS & TYPOGRAPHY
   ───────────────────────────────────────────────────────────── */
html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans) !important;
    background-color: var(--cbmi-ivory) !important;
    color: var(--cbmi-text-dark) !important;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

h1, h2, h3 {
    letter-spacing: -0.015em;
    color: var(--cbmi-maroon-dark);
}

h4, h5, h6 {
    letter-spacing: -0.01em;
    color: var(--cbmi-maroon-dark);
}

a {
    color: var(--cbmi-maroon);
    transition: color 0.2s ease, transform 0.2s ease;
}
a:hover {
    color: var(--cbmi-maroon-rich);
}

::selection {
    background: var(--cbmi-maroon);
    color: var(--cbmi-gold-light);
}

/* ─────────────────────────────────────────────────────────────
   TOPBAR
   ───────────────────────────────────────────────────────────── */
.academy-topbar {
    background: linear-gradient(90deg, #240303 0%, #4A0606 50%, #240303 100%);
    border-bottom: 1.5px solid var(--cbmi-gold);
    color: #FEE2E2;
    padding: 7px 0;
    font-size: 12.5px;
    font-weight: 500;
}

.academy-topbar a {
    color: var(--cbmi-gold-light) !important;
    text-decoration: none;
    font-size: 12.5px;
}
.academy-topbar a:hover {
    color: #FFFFFF !important;
}

/* ─────────────────────────────────────────────────────────────
   NAVBAR & MOBILE DROPDOWN
   ───────────────────────────────────────────────────────────── */
.academy-navbar {
    background: #FFFFFF !important;
    border-bottom: 2px solid var(--cbmi-gold);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 1040;
}

.academy-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    min-width: 0;
}

.academy-brand-logo {
    height: 44px;
    width: auto;
    border-radius: 8px;
    border: 1.5px solid var(--cbmi-gold);
    padding: 2px;
    background: #FFFFFF;
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
}

.academy-brand-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.academy-brand-title {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--cbmi-maroon);
    line-height: 1.1;
    letter-spacing: 0.5px;
}

.academy-brand-sub {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--cbmi-gold-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.academy-nav-menu {
    display: flex;
    align-items: center;
    gap: 22px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.academy-nav-link {
    color: #3C2A24 !important;
    font-weight: 600;
    font-size: 14.5px;
    text-decoration: none;
    position: relative;
    padding: 8px 4px;
    transition: all 0.2s ease;
}

.academy-nav-link:hover,
.academy-nav-link.active {
    color: var(--cbmi-maroon) !important;
}

.academy-nav-link::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2.5px;
    background: var(--cbmi-gold-gradient);
    transition: width 0.25s ease;
    border-radius: 2px;
}

.academy-nav-link:hover::after,
.academy-nav-link.active::after {
    width: 100%;
}

/* Primary Button */
.btn-academy-primary {
    background: linear-gradient(135deg, #7A0C0C 0%, #9E1313 100%) !important;
    color: #FFFFFF !important;
    border: 1.5px solid var(--cbmi-gold) !important;
    font-weight: 700 !important;
    font-size: 13.5px !important;
    padding: 9px 20px !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 12px rgba(122, 12, 12, 0.25) !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    transition: all 0.25s ease !important;
    white-space: nowrap;
}

.btn-academy-primary:hover {
    background: linear-gradient(135deg, #D4AF37 0%, #F7D774 100%) !important;
    color: #3A0505 !important;
    border-color: #7A0C0C !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(212, 175, 55, 0.4) !important;
}

/* Outline Button */
.btn-academy-outline {
    background: transparent !important;
    color: var(--cbmi-maroon) !important;
    border: 1.5px solid var(--cbmi-gold) !important;
    font-weight: 700 !important;
    font-size: 13.5px !important;
    padding: 9px 20px !important;
    border-radius: 8px !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    transition: all 0.25s ease !important;
}

.btn-academy-outline:hover {
    background: var(--cbmi-gold) !important;
    color: #240303 !important;
    border-color: var(--cbmi-gold) !important;
    transform: translateY(-2px);
}

/* Mobile Dropdown Menu (Clean & Neat) */
.academy-mobile-menu {
    display: none;
    background: #250404;
    border-top: 2px solid var(--cbmi-gold);
    border-bottom: 2px solid var(--cbmi-gold);
    padding: 14px 20px 18px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
}

.academy-mobile-menu.show {
    display: block;
    animation: fadeInMenu 0.25s ease;
}

@keyframes fadeInMenu {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

.academy-mobile-menu a {
    display: block;
    color: #FFFFFF !important;
    font-weight: 600;
    font-size: 14.5px;
    padding: 10px 4px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    text-decoration: none;
    transition: all 0.2s ease;
}

.academy-mobile-menu a:hover,
.academy-mobile-menu a.active {
    color: var(--cbmi-gold-light) !important;
    padding-left: 6px;
}

/* ─────────────────────────────────────────────────────────────
   HERO PANGGUNG SINEMATIK KEHORMATAN
   ───────────────────────────────────────────────────────────── */
.academy-hero {
    background: radial-gradient(circle at 65% 30%, #5B0808 0%, #2A0404 65%, #140101 100%);
    color: #FFFFFF;
    position: relative;
    padding: clamp(60px, 8vw, 100px) 0;
    border-bottom: 3px solid var(--cbmi-gold);
    overflow: hidden;
}

.academy-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(circle at 15% 75%, rgba(212, 175, 55, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 85% 15%, rgba(21, 128, 61, 0.12) 0%, transparent 40%);
    pointer-events: none;
}

.academy-badge-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 16px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--cbmi-gold);
    border-radius: 50px;
    color: var(--cbmi-gold-light);
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    margin-bottom: 18px;
}

.academy-hero-title {
    font-family: var(--font-heading) !important;
    font-size: clamp(2.2rem, 4.5vw, 3.8rem);
    font-weight: 800;
    color: #FFFFFF;
    line-height: 1.18;
    margin-bottom: 18px;
    text-shadow: 0 4px 18px rgba(0, 0, 0, 0.5);
}

.academy-hero-title span.gold-text {
    background: var(--cbmi-gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.academy-hero-desc {
    font-size: clamp(1rem, 1.5vw, 1.15rem);
    color: #FEE2E2;
    line-height: 1.7;
    margin-bottom: 28px;
    max-width: 600px;
    opacity: 0.92;
}

.academy-hero-frame {
    border: 2.5px solid var(--cbmi-gold);
    border-radius: 18px;
    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.5), var(--cbmi-gold-glow);
    overflow: hidden;
    position: relative;
    background: #140101;
    aspect-ratio: 16 / 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.academy-hero-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ─────────────────────────────────────────────────────────────
   SECTION COMMONS
   ───────────────────────────────────────────────────────────── */
.academy-section {
    padding: clamp(60px, 8vw, 90px) 0;
}

.academy-section-header {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 50px;
}

.academy-section-tag {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--cbmi-maroon);
    margin-bottom: 8px;
    display: block;
}

.academy-section-title {
    font-size: clamp(1.85rem, 3.2vw, 2.5rem);
    font-weight: 800;
    color: var(--cbmi-maroon-dark);
    margin-bottom: 12px;
    line-height: 1.25;
}

.academy-section-desc {
    font-size: 15.5px;
    color: var(--cbmi-text-muted);
    line-height: 1.65;
    margin: 0 auto;
}

/* ─────────────────────────────────────────────────────────────
   COURSE CARDS (4 Cabang Unggulan)
   ───────────────────────────────────────────────────────────── */
.academy-course-card {
    background: #FFFFFF;
    border-radius: 16px;
    border: 1px solid rgba(212, 175, 55, 0.35);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.academy-course-card:hover {
    transform: translateY(-6px);
    border-color: var(--cbmi-gold);
    box-shadow: var(--shadow-card-hover);
}

.academy-course-head {
    height: 185px;
    background: #200404;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.academy-course-head img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}

.academy-course-card:hover .academy-course-head img {
    transform: scale(1.06);
}

.academy-course-ribbon {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--cbmi-maroon);
    color: #FFFFFF;
    border: 1px solid var(--cbmi-gold);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    padding: 3px 9px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    z-index: 2;
}

.academy-course-body {
    padding: 22px 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.academy-course-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--cbmi-maroon-dark);
    margin-bottom: 8px;
    line-height: 1.35;
}

.academy-course-desc {
    font-size: 13px;
    color: var(--cbmi-text-muted);
    line-height: 1.6;
    margin-bottom: 0;
    display: block;
    word-break: normal;
    overflow-wrap: break-word;
}

.academy-course-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 12px;
    border-top: 1px solid #F1ECE6;
    font-size: 12.5px;
    font-weight: 600;
}

/* 5-Column Grid Support (Hingga 5 Cabang Unggulan pada Desktop) */
@media (min-width: 1200px) {
    .row-cols-xl-5 > * {
        flex: 0 0 20% !important;
        max-width: 20% !important;
    }
}

/* ─────────────────────────────────────────────────────────────
   BELT PROGRESSION ROADMAP (7 Tingkat Sabuk)
   ───────────────────────────────────────────────────────────── */
.academy-belt-section {
    background: linear-gradient(135deg, #240404 0%, #120101 100%);
    color: #FFFFFF;
    border-top: 2.5px solid var(--cbmi-gold);
    border-bottom: 2.5px solid var(--cbmi-gold);
    padding: clamp(65px, 8vw, 95px) 0;
    position: relative;
}

.academy-belt-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(212, 175, 55, 0.45);
    border-radius: 14px;
    padding: 22px 14px;
    text-align: center;
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
}

.academy-belt-card:hover {
    background: rgba(255, 255, 255, 0.09);
    border-color: var(--cbmi-gold);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.25);
}

.academy-belt-swatch {
    width: 72px;
    height: 16px;
    border-radius: 4px;
    margin-bottom: 12px;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.45);
    position: relative;
    overflow: hidden;
}

.academy-belt-swatch .academy-belt-strip {
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 36%;
    box-shadow: 0 0 2px rgba(0, 0, 0, 0.35);
}

.academy-belt-name {
    font-size: 16px;
    font-weight: 700;
    color: #FFFFFF;
    margin-bottom: 4px;
}

.academy-belt-level {
    font-size: 11px;
    font-weight: 800;
    color: var(--cbmi-gold-light);
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* ─────────────────────────────────────────────────────────────
   3 PILAR BUDI PEKERTI
   ───────────────────────────────────────────────────────────── */
.academy-pillar-box {
    background: #FFFFFF;
    border-radius: 16px;
    border: 1.5px solid rgba(212, 175, 55, 0.4);
    padding: 34px 26px;
    box-shadow: var(--shadow-sm);
    height: 100%;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.academy-pillar-box:hover {
    transform: translateY(-5px);
    border-color: var(--cbmi-gold);
    box-shadow: var(--shadow-card-hover);
}

.academy-pillar-num {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    color: var(--cbmi-gold);
    margin-bottom: 10px;
    display: block;
    line-height: 1;
}

.academy-pillar-title {
    font-size: 20px;
    font-weight: 800;
    color: var(--cbmi-maroon);
    margin-bottom: 10px;
}

.academy-pillar-text {
    font-size: 14px;
    color: var(--cbmi-text-muted);
    line-height: 1.65;
    margin-bottom: 14px;
}

/* ─────────────────────────────────────────────────────────────
   STATS BAR (Papan Prestasi & Counter)
   ───────────────────────────────────────────────────────────── */
.academy-stats-bar {
    background: linear-gradient(90deg, #4A0606 0%, #6E0A0A 50%, #4A0606 100%);
    border-top: 2px solid var(--cbmi-gold);
    border-bottom: 2px solid var(--cbmi-gold);
    padding: 50px 0;
    color: #FFFFFF;
}

.academy-stat-num {
    font-family: var(--font-heading);
    font-size: clamp(2.4rem, 3.8vw, 3.4rem);
    font-weight: 800;
    color: var(--cbmi-gold-light);
    text-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
    line-height: 1;
    margin-bottom: 8px;
}

.academy-stat-label {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: #FEE2E2;
}

/* ─────────────────────────────────────────────────────────────
   FOOTER KEHORMATAN
   ───────────────────────────────────────────────────────────── */
.academy-footer {
    background: #180303;
    border-top: 3px solid var(--cbmi-gold);
    color: #E5DDD7;
    padding: 65px 0 25px;
    position: relative;
}

.academy-footer h5 {
    font-family: var(--font-heading);
    color: var(--cbmi-gold-light);
    font-size: 15.5px;
    font-weight: 700;
    letter-spacing: 0.8px;
    margin-bottom: 18px;
    padding-bottom: 8px;
    border-bottom: 1.5px solid rgba(212, 175, 55, 0.3);
}

.academy-footer a {
    color: #D1C4BC !important;
    text-decoration: none;
    transition: all 0.2s ease;
}

.academy-footer a:hover {
    color: var(--cbmi-gold-light) !important;
    padding-left: 4px;
}

.academy-footer-bottom {
    margin-top: 45px;
    padding-top: 20px;
    border-top: 1px solid rgba(212, 175, 55, 0.2);
    font-size: 12.5px;
    color: #9C8E84;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

/* ─────────────────────────────────────────────────────────────
   RESPONSIVE ADJUSTMENTS (NAVBAR & HERO ONLY)
   ───────────────────────────────────────────────────────────── */
@media (max-width: 991.98px) {
    .academy-navbar {
        padding: 10px 0;
    }
    .academy-hero-frame {
        max-width: 480px;
        margin: 0 auto;
    }
}

@media (max-width: 575.98px) {
    .academy-brand-sub {
        display: none !important;
    }
    .academy-brand-title {
        font-size: 1.25rem;
    }
}

/* Breadcrumb Banner */
.bg-breadcrumb {
    background: radial-gradient(circle at 50% 30%, #5B0808 0%, #2A0404 65%, #140101 100%) !important;
    border-bottom: 2.5px solid var(--cbmi-gold) !important;
    padding: clamp(70px, 8vw, 100px) 0 50px !important;
}
