/* ============================================
   INTIWASI POI PARENT GUIDE - CUSTOM STYLES
   ============================================ */

/* Smooth scroll */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

/* Selection color */
::selection {
    background: rgba(237, 121, 35, 0.2);
    color: #003366;
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #ed7923;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ========== HERO ========== */
.hero-bg {
    background: linear-gradient(160deg, #003366 0%, #1a5276 30%, #ed7923 75%, #f5a623 100%);
}

.hero-gradient {
    background: linear-gradient(160deg, rgba(0,51,102,0.8) 0%, rgba(26,82,118,0.6) 30%, rgba(237,121,35,0.35) 75%, rgba(245,166,35,0.2) 100%);
}

/* Playful floating shapes */
.hero-float {
    position: absolute;
    border-radius: 50%;
    animation: floatBounce 6s ease-in-out infinite;
    pointer-events: none;
}

.hero-float:nth-child(2) { animation-delay: -1s; animation-duration: 7s; }
.hero-float:nth-child(3) { animation-delay: -3s; animation-duration: 5s; }
.hero-float:nth-child(4) { animation-delay: -2s; animation-duration: 8s; }

@keyframes floatBounce {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-12px) rotate(3deg); }
}

/* ========== FADE ANIMATIONS ========== */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade-up {
    animation: fadeUp 0.7s ease-out forwards;
}

.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.opacity-0-init { opacity: 0; }

/* ========== SCROLL ANIMATIONS ========== */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: none;
}

/* Staggered children animation */
.animate-on-scroll.visible:nth-child(2) { transition-delay: 0.08s; }
.animate-on-scroll.visible:nth-child(3) { transition-delay: 0.16s; }
.animate-on-scroll.visible:nth-child(4) { transition-delay: 0.24s; }
.animate-on-scroll.visible:nth-child(5) { transition-delay: 0.32s; }
.animate-on-scroll.visible:nth-child(6) { transition-delay: 0.40s; }

/* ========== TIMELINE STEPS ========== */
.timeline-step .step-dot {
    position: relative;
    z-index: 2;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}

.timeline-step:hover .step-dot {
    transform: scale(1.15) rotate(-5deg);
    box-shadow: 0 8px 24px rgba(237, 121, 35, 0.3);
}

/* ========== GRADE TABS ========== */
.grade-tab {
    padding: 0.5rem 1.25rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    background: rgba(0, 51, 102, 0.08);
    color: #003366;
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.grade-tab:hover {
    background: rgba(0, 51, 102, 0.15);
}

.grade-tab.active {
    background: #003366;
    color: white;
    border-color: #003366;
    box-shadow: 0 4px 12px rgba(0, 51, 102, 0.3);
}

/* ========== GRADE PANELS ========== */
.grade-panel {
    display: none;
    animation: panelFadeIn 0.4s ease-out forwards;
}

.grade-panel.active {
    display: block;
}

@keyframes panelFadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== UNIT CARDS ========== */
.unit-card {
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    border-radius: 1.25rem;
}

.unit-card:hover {
    transform: translateY(-4px) scale(1.01);
    box-shadow: 0 12px 32px rgba(237, 121, 35, 0.12);
}

/* ========== TAGS ========== */
.tag {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 9999px;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: capitalize;
    background: #FEF8E0;
    color: #003366;
    border: 1px solid rgba(0, 51, 102, 0.1);
}

/* ========== THEME CARDS ========== */
.theme-card {
    position: relative;
    overflow: hidden;
    border-radius: 1.5rem;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.theme-card:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.15);
}

.theme-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ed7923, #003366);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.theme-card:hover::after {
    transform: scaleX(1);
}

/* ========== CONCEPT CARDS ========== */
.concept-card {
    position: relative;
    overflow: hidden;
    border-radius: 1.25rem;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.concept-card:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 32px rgba(237, 121, 35, 0.1);
}

.concept-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: #ed7923;
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease;
}

.concept-card:hover::before {
    transform: scaleY(1);
}

/* ========== FAQ ACCORDION ========== */
.faq-item {
    transition: background 0.3s ease;
    border-radius: 0.75rem;
}

.faq-item:hover {
    background: rgba(237, 121, 35, 0.05);
}

.faq-question {
    cursor: pointer;
}

.faq-chevron {
    transition: transform 0.3s ease;
}

.faq-item.open .faq-chevron {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                padding 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    padding-top: 0;
    padding-bottom: 0;
}

.faq-item.open .faq-answer {
    display: block;
    max-height: 300px;
    padding-bottom: 1.5rem;
}

/* ========== HEADER SCROLL STATE ========== */
#site-header.scrolled {
    background: rgba(254, 248, 224, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 12px rgba(0, 0, 0, 0.06);
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

#site-header.scrolled .nav-link {
    color: rgba(0, 51, 102, 0.7);
}

#site-header.scrolled .nav-link:hover {
    color: #ed7923;
}

#site-header.scrolled .nav-brand {
    color: #003366;
}

#site-header.scrolled #lang-toggle,
#site-header.scrolled #lang-toggle-mobile {
    background: rgba(0, 51, 102, 0.08);
    border-color: rgba(0, 51, 102, 0.15);
    color: #003366;
}

#site-header.scrolled #lang-toggle:hover,
#site-header.scrolled #lang-toggle-mobile:hover {
    background: rgba(0, 51, 102, 0.15);
}

#site-header.scrolled #mobile-toggle {
    color: #003366;
}

/* ========== MOBILE MENU ========== */
#mobile-menu {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

#mobile-menu.hidden {
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
}

#mobile-menu:not(.hidden) {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

/* ========== HIDE SCROLLBAR ========== */
.hide-scrollbar::-webkit-scrollbar { display: none; }
.hide-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* ========== PLAYFUL CTA BUTTON ========== */
.hero-cta {
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hero-cta:hover {
    transform: translateY(-3px) scale(1.05);
}

.hero-cta:active {
    transform: translateY(0) scale(0.98);
}

/* ========== GRADE TAB PLAYFUL ========== */
.grade-tab {
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.grade-tab:hover {
    transform: translateY(-2px);
}

.grade-tab.active {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0, 51, 102, 0.35);
}

/* ========== RESPONSIVE ADJUSTMENTS ========== */
@media (max-width: 640px) {
    .theme-card::after {
        display: none;
    }

    .concept-card::before {
        display: none;
    }

    .grade-tab {
        font-size: 0.7rem;
        padding: 0.4rem 0.9rem;
    }
}
