/* ==========================================================================
   SMA Global Darussalam Academy - Modern Master Stylesheet
   Theme: Luxury Dark Navy Blue (#0d2444 / #1a3d6e) & Champagne Gold (#c89d38)
   ========================================================================== */

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

:root {
    /* Core Brand Colors */
    --gda-navy: #0d2444;            /* Deepest Navy */
    --gda-primary: #1a3d6e;         /* Signature Navy Blue */
    --gda-primary-light: #2d62b0;   /* Vibrant Indigo Navy */
    --gda-primary-soft: #edf4fc;    /* Light Ice Blue Background */
    
    --gda-gold: #c89d38;            /* Refined Gold */
    --gda-gold-light: #f5ecd5;      /* Champagne Gold Soft */
    --gda-gold-dark: #9e7a25;       /* Deep Gold */
    
    /* Neutral & Surfaces */
    --gda-dark: #0f172a;
    --gda-body: #334155;
    --gda-muted: #64748b;
    --gda-light: #f8fafc;
    --gda-card-bg: #ffffff;
    --gda-border: #e2e8f0;
    --gda-border-light: rgba(226, 232, 240, 0.8);
    
    /* Legacy Class Support */
    --gda-emerald: #1a3d6e;
    --gda-emerald-dark: #0d2444;
    --gda-emerald-light: #2d62b0;
    --gda-emerald-soft: #edf4fc;
    
    /* Typography */
    --gda-font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --gda-font-heading: 'Playfair Display', Georgia, serif;
    
    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(13, 36, 68, 0.04);
    --shadow-md: 0 6px 20px rgba(13, 36, 68, 0.07);
    --shadow-lg: 0 14px 35px rgba(13, 36, 68, 0.10);
    --shadow-hover: 0 16px 40px -5px rgba(13, 36, 68, 0.15);
    
    /* Transitions */
    --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.15s ease;
}

/* Base Reset & Typography */
html { scroll-behavior: smooth; }

body {
    font-family: var(--gda-font-main);
    color: var(--gda-body);
    background-color: var(--gda-light);
    line-height: 1.65;
    letter-spacing: -0.01em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--gda-dark);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.3;
}

/* Force pure white on dark backgrounds & text-white containers, excluding nested white/light cards */
.text-white > h1, .text-white > h2, .text-white > h3, .text-white > h4, .text-white > h5, .text-white > h6,
.text-white .page-title,
.bg-dark > h1, .bg-dark > h2, .bg-dark > h3, .bg-dark > h4, .bg-dark > h5, .bg-dark > h6,
.bg-navy-dark > h1, .bg-navy-dark > h2, .bg-navy-dark > h3, .bg-navy-dark > h4, .bg-navy-dark > h5, .bg-navy-dark > h6,
.bg-emerald > h1, .bg-emerald > h2, .bg-emerald > h3, .bg-emerald > h4, .bg-emerald > h5, .bg-emerald > h6,
.card.text-white h1, .card.text-white h2, .card.text-white h3, .card.text-white h4, .card.text-white h5, .card.text-white h6 {
    color: #ffffff !important;
}

/* Ticket Header Text Color Protection */
.ticket-header-gradient,
.ticket-header-gradient h1, .ticket-header-gradient h2, .ticket-header-gradient h3, .ticket-header-gradient h4, .ticket-header-gradient h5, .ticket-header-gradient h6, .ticket-header-gradient p, .ticket-header-gradient span,
.ticket-top-header,
.ticket-top-header h1, .ticket-top-header h2, .ticket-top-header h3, .ticket-top-header h4, .ticket-top-header h5, .ticket-top-header h6, .ticket-top-header p, .ticket-top-header span,
.card-custom .ticket-top-header h4,
.card-custom .ticket-top-header h3 {
    color: #ffffff !important;
}

/* Explicit text dark for cards inside dark sections */
.card.bg-white h1, .card.bg-white h2, .card.bg-white h3, .card.bg-white h4, .card.bg-white h5, .card.bg-white h6,
.card.bg-light h1, .card.bg-light h2, .card.bg-light h3, .card.bg-light h4, .card.bg-light h5, .card.bg-light h6,
.card.text-dark h1, .card.text-dark h2, .card.text-dark h3, .card.text-dark h4, .card.text-dark h5, .card.text-dark h6,
.card:not(.text-white):not(.bg-dark):not(.bg-navy-dark):not(.bg-emerald) h1,
.card:not(.text-white):not(.bg-dark):not(.bg-navy-dark):not(.bg-emerald) h2,
.card:not(.text-white):not(.bg-dark):not(.bg-navy-dark):not(.bg-emerald) h3,
.card:not(.text-white):not(.bg-dark):not(.bg-navy-dark):not(.bg-emerald) h4,
.card:not(.text-white):not(.bg-dark):not(.bg-navy-dark):not(.bg-emerald) h5,
.card:not(.text-white):not(.bg-dark):not(.bg-navy-dark):not(.bg-emerald) h6,
.home-hero-menu-section .card h5 {
    color: #0b2240 !important;
}

.font-serif { font-family: var(--gda-font-heading); }

/* Utility Classes */
.text-emerald, .text-navy-primary { color: var(--gda-primary) !important; }
.text-dark-emerald, .text-navy-dark { color: var(--gda-navy) !important; }
.text-gold { color: var(--gda-gold) !important; }
.bg-emerald, .bg-navy-primary { background-color: var(--gda-primary) !important; }
.bg-emerald-dark, .bg-navy-dark { background-color: var(--gda-navy) !important; }
.bg-emerald-soft, .bg-navy-soft { background-color: var(--gda-primary-soft) !important; }
.bg-gold { background-color: var(--gda-gold) !important; }
.bg-gold-subtle { background-color: var(--gda-gold-light) !important; }
.border-emerald { border-color: var(--gda-primary) !important; }
.border-gold { border-color: var(--gda-gold) !important; }
.smaller { font-size: 0.82rem; }
.letter-spacing-1 { letter-spacing: 1px; }

/* ==========================================================================
   TOPBAR
   ========================================================================== */
.topbar {
    background: linear-gradient(90deg, #091a32 0%, #0d2444 60%, #1a3d6e 100%);
    font-size: 0.82rem;
    font-weight: 500;
    border-bottom: 1px solid rgba(200, 157, 56, 0.25);
    padding: 6px 0;
}

.topbar span { display: inline-flex; align-items: center; }

.topbar-wa-btn {
    background: #25d366;
    color: #ffffff !important;
    text-decoration: none;
    padding: 4px 14px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.78rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 6px rgba(37, 211, 102, 0.3);
    transition: var(--transition-smooth);
}

.topbar-wa-btn:hover {
    background: #20ba59;
    transform: translateY(-1px);
}

.hover-white:hover { color: #ffffff !important; }
.hover-gold:hover { color: var(--gda-gold) !important; }

/* ==========================================================================
   MAIN NAVBAR
   ========================================================================== */
.main-navbar {
    background: #ffffff;
    box-shadow: 0 2px 15px rgba(13, 36, 68, 0.05);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    padding-top: 10px;
    padding-bottom: 10px;
    transition: var(--transition-smooth);
}

.navbar-logo {
    height: 46px;
    width: auto;
    object-fit: contain;
}

.brand-text { line-height: 1.15; }

.brand-title {
    font-weight: 800;
    font-size: 0.98rem;
    color: var(--gda-navy);
    letter-spacing: -0.03em;
    line-height: 1.15;
}

.brand-subtitle {
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--gda-gold);
    letter-spacing: 0.6px;
    text-transform: uppercase;
    margin-top: 1px;
    line-height: 1.1;
}

@media (max-width: 575.98px) {
    .navbar-logo {
        height: 38px;
    }
    .brand-title {
        font-size: 0.78rem;
        letter-spacing: -0.02em;
    }
    .brand-subtitle {
        font-size: 0.55rem;
        letter-spacing: 0.2px;
    }
    .main-navbar .container {
        padding-left: 10px;
        padding-right: 10px;
    }
}

/* Unified Nav Links - NO ICONS, HIGHLIGHT BIRU TUA WHEN ACTIVE */
.main-navbar .nav-link {
    font-weight: 600;
    color: #334155;
    font-size: 0.9rem;
    padding: 8px 14px !important;
    border-radius: 8px;
    transition: var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.main-navbar .nav-link:hover {
    color: var(--gda-primary);
    background-color: var(--gda-primary-soft);
}

.main-navbar .nav-link.active {
    color: #ffffff !important;
    background-color: var(--gda-primary) !important;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(26, 61, 110, 0.25);
}

/* ==========================================================================
   PAGE HERO (Consistent across all sub-menus)
   ========================================================================== */
.page-hero {
    background: linear-gradient(135deg, #091a32 0%, #0d2444 50%, #1a3d6e 100%);
    padding: 48px 0 40px 0;
    color: #ffffff;
    text-align: center;
    position: relative;
    border-bottom: 3px solid var(--gda-gold);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.page-hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(circle at 50% 30%, rgba(200, 157, 56, 0.12) 0%, transparent 70%);
    pointer-events: none;
}

.page-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #f5ecd5 0%, #e2d2aa 100%);
    color: #0d2444;
    font-weight: 800;
    font-size: 0.78rem;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    padding: 6px 16px;
    border-radius: 30px;
    margin-bottom: 12px;
    border: 1px solid rgba(200, 157, 56, 0.4);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.page-title {
    font-family: var(--gda-font-main);
    font-size: 2.1rem;
    font-weight: 800;
    margin-bottom: 8px;
    letter-spacing: -0.025em;
    color: #ffffff !important;
}

.page-subtitle {
    max-width: 720px;
    font-size: 0.95rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85) !important;
    margin: 0 auto;
}

/* ==========================================================================
   BUTTONS & CARDS
   ========================================================================== */
.btn-gda-primary {
    background: linear-gradient(135deg, var(--gda-gold) 0%, var(--gda-gold-dark) 100%);
    color: #ffffff !important;
    font-weight: 700;
    padding: 12px 26px;
    border-radius: 30px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    box-shadow: 0 4px 14px rgba(200, 157, 56, 0.35);
    transition: var(--transition-smooth);
    font-size: 0.92rem;
}

.btn-gda-primary:hover {
    background: linear-gradient(135deg, #d4af37 0%, var(--gda-gold) 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(200, 157, 56, 0.5);
}

.btn-gda-outline {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff !important;
    font-weight: 600;
    padding: 12px 24px;
    border-radius: 30px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1.5px solid rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
    transition: var(--transition-smooth);
    font-size: 0.92rem;
}

.btn-gda-outline:hover {
    background: #ffffff;
    color: var(--gda-primary) !important;
    border-color: #ffffff;
    transform: translateY(-2px);
}

/* Card Customization */
.card-custom {
    background: var(--gda-card-bg);
    border: 1px solid var(--gda-border-light);
    border-radius: 16px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
}

.card-custom:hover {
    box-shadow: var(--shadow-md);
}

.transition-hover {
    transition: var(--transition-smooth);
}

.transition-hover:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover) !important;
}

/* Feature Icon Box */
.feature-icon-wrapper {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    background: var(--gda-primary-soft);
    color: var(--gda-primary);
}

/* Section Title & Tag */
.section-tag {
    display: inline-block;
    background: var(--gda-primary-soft);
    color: var(--gda-primary);
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 10px;
}

.section-title {
    font-family: var(--gda-font-heading);
    color: var(--gda-dark);
    font-size: 2.1rem;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

/* Form Styles */
.form-label {
    font-weight: 600;
    font-size: 0.86rem;
    color: #1e293b;
    margin-bottom: 6px;
}

.form-label.required::after {
    content: " *";
    color: #ef4444;
    font-weight: bold;
}

.form-control, .form-select {
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    padding: 10px 14px;
    font-size: 0.9rem;
    color: #1e293b;
    transition: var(--transition-smooth);
    background-color: #ffffff;
}

.form-control:focus, .form-select:focus {
    border-color: var(--gda-primary);
    box-shadow: 0 0 0 4px rgba(26, 61, 110, 0.12);
    outline: none;
}

.form-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--gda-primary);
    border-bottom: 2px solid var(--gda-primary-soft);
    padding-bottom: 8px;
    margin-bottom: 16px;
}

/* ==========================================================================
   CAMPUS VISIT - CALENDAR & SESSIONS
   ========================================================================== */
.visit-calendar-card {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid var(--gda-border);
    box-shadow: var(--shadow-sm);
    padding: 18px;
}

.calendar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f1f5f9;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
}

.calendar-day-head {
    text-align: center;
    font-size: 0.78rem;
    font-weight: 700;
    color: #64748b;
    padding: 4px 0;
    text-transform: uppercase;
}

.calendar-day-cell {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-fast);
    border: 1px solid #f1f5f9;
    color: #1e293b;
    background-color: #ffffff;
    position: relative;
    user-select: none;
}

.calendar-day-cell:hover:not(.disabled):not(.empty) {
    background-color: var(--gda-primary-soft);
    border-color: var(--gda-primary);
    color: var(--gda-primary);
}

.calendar-day-cell.selected {
    background-color: var(--gda-primary) !important;
    color: #ffffff !important;
    border-color: var(--gda-primary) !important;
    box-shadow: 0 4px 10px rgba(26, 61, 110, 0.3);
}

.calendar-day-cell.selected .slot-dot {
    background: #ffffff !important;
}

.calendar-day-cell.disabled {
    color: #cbd5e1;
    cursor: not-allowed;
    background-color: #f8fafc;
    border-color: transparent;
}

.calendar-day-cell.today {
    border-color: var(--gda-gold);
    font-weight: 800;
}

.calendar-day-cell.empty {
    border-color: transparent;
    cursor: default;
}

.slot-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    margin-top: 3px;
    flex-shrink: 0;
}

.slot-dot.available { background: #22c55e; }
.slot-dot.full { background: #ef4444; }
.slot-dot.closed { background: #94a3b8; }
.slot-dot.loading { background: #f59e0b; }

.session-card {
    border: 1.5px solid var(--gda-border);
    border-radius: 12px;
    padding: 12px 16px;
    cursor: pointer;
    transition: var(--transition-smooth);
    background: #ffffff;
    margin-bottom: 8px;
}

.session-card:hover:not(.opacity-50) {
    border-color: var(--gda-primary);
    background: var(--gda-primary-soft);
}

.session-card.selected {
    border-color: var(--gda-primary);
    background: var(--gda-primary-soft);
    box-shadow: 0 0 0 1px var(--gda-primary);
}

/* ==========================================================================
   VIRTUAL TOUR 360°
   ========================================================================== */
#panorama-container {
    width: 100%;
    height: 520px;
    min-height: 420px;
    border-radius: 14px;
    overflow: hidden;
    background-color: #0d2444;
    position: relative;
    box-shadow: var(--shadow-md);
}

.tour-scene-thumb {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid var(--gda-border);
    background: #ffffff;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.tour-scene-thumb:hover {
    border-color: var(--gda-primary);
    background: var(--gda-primary-soft);
    transform: translateX(4px);
}

.tour-scene-thumb.active {
    border-color: var(--gda-primary);
    background: var(--gda-primary-soft);
    box-shadow: 0 2px 8px rgba(26, 61, 110, 0.15);
}

/* ==========================================================================
   BROCHURE FLIPBOOK
   ========================================================================== */
.flipbook-container {
    background: #091a32;
    border-radius: 18px;
    padding: 30px 20px;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
    min-height: 520px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.flipbook-stage {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

#flipbook {
    margin: 0 auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.flipbook-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 8px 18px;
    border-radius: 30px;
    margin-top: 20px;
    z-index: 10;
}

.flip-btn {
    background: transparent;
    border: none;
    color: #ffffff;
    font-size: 1rem;
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.flip-btn:hover {
    color: var(--gda-gold);
    background: rgba(255, 255, 255, 0.1);
}

.page {
    background-color: #ffffff;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.page-content {
    width: 100%;
    height: 100%;
    padding: 30px;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

/* ==========================================================================
   FOOTER & FLOATING WA
   ========================================================================== */
.main-footer {
    background: linear-gradient(180deg, #091a32 0%, #061122 100%);
    color: #cbd5e1;
    border-top: 3px solid var(--gda-gold);
    font-size: 0.9rem;
}

.footer-heading {
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.01em;
}

.footer-menu li { margin-bottom: 8px; }
.footer-menu a {
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition-fast);
    font-size: 0.86rem;
}
.footer-menu a:hover { color: var(--gda-gold-light); }

.service-badge-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    text-decoration: none;
    transition: var(--transition-fast);
}

.service-badge-link:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.floating-wa-btn {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: #25d366;
    color: #ffffff !important;
    border-radius: 30px;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 18px rgba(37, 211, 102, 0.4);
    z-index: 999;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: var(--transition-smooth);
}

.floating-wa-btn:hover {
    background: #20ba59;
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 24px rgba(37, 211, 102, 0.5);
}

@media print {
    .floating-wa-btn,
    .floating-wa,
    .floating-whatsapp,
    #btnFloatingWA,
    a[href*="wa.me"],
    a[href*="whatsapp.com"] {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
    }
}
