/* ============================================
   HICKAM AAFES BX — Custom Styles
   Premium Dark Luxury Theme
   ============================================ */

/* ---- Reset & Base ---- */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    overflow-x: hidden;
}

::selection {
    background: rgba(201, 168, 76, 0.3);
    color: #f0e6c8;
}

/* ---- Scrollbar ---- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #050d1a;
}
::-webkit-scrollbar-thumb {
    background: rgba(201, 168, 76, 0.3);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(201, 168, 76, 0.5);
}

/* ---- Scroll Reveal Animations ---- */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal[data-delay="1"] { transition-delay: 0.1s; }
.reveal[data-delay="2"] { transition-delay: 0.2s; }
.reveal[data-delay="3"] { transition-delay: 0.3s; }
.reveal[data-delay="4"] { transition-delay: 0.4s; }

/* Initial state for scroll-reveal elements (progressive enhancement via JS) */
.js-enabled .reveal-hidden {
    opacity: 0;
    transform: translateY(30px);
}

/* Respect reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
    .reveal,
    .reveal-hidden {
        opacity: 1;
        transform: none;
        transition: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* ---- Navbar ---- */
#navbar {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, backdrop-filter 0.4s ease;
}

#navbar.scrolled {
    background: rgba(5, 13, 26, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(201, 168, 76, 0.1);
}

/* ---- Mobile Menu ---- */
#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

#mobile-menu.open .mobile-link {
    animation: fadeDown 0.4s ease forwards;
    opacity: 0;
}

#mobile-menu.open .mobile-link:nth-child(1) { animation-delay: 0.05s; }
#mobile-menu.open .mobile-link:nth-child(2) { animation-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(3) { animation-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(4) { animation-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(5) { animation-delay: 0.25s; }

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

/* ---- Mobile Menu Toggle ---- */
.menu-toggle-active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}
.menu-toggle-active .menu-line:nth-child(2) {
    opacity: 0;
}
.menu-toggle-active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 1.5rem;
}

/* ---- Department Cards ---- */
.department-card {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
}

.department-card img {
    transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.department-card:hover img {
    transform: scale(1.1);
}

/* ---- Gold Accent Line ---- */
.gold-line {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(201, 168, 76, 0.4), transparent);
}

/* ---- Form Elements ---- */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: rgba(201, 168, 76, 0.5) !important;
    box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.08);
}

/* ---- Button Hover Glow ---- */
.btn-gold:hover {
    box-shadow: 0 0 30px rgba(201, 168, 76, 0.25);
}

/* ---- Image Aspect Ratios ---- */
.aspect-portrait {
    aspect-ratio: 4 / 5;
}

.aspect-landscape {
    aspect-ratio: 4 / 3;
}

/* ---- Utility ---- */
.text-balance {
    text-wrap: balance;
}

/* ---- Print Styles ---- */
@media print {
    #navbar,
    #mobile-menu,
    .reveal {
        display: none !important;
    }
    body {
        background: white;
        color: black;
    }
}
