/* base.css — C2Jam Global Reset & Base Styles */

/* ── Reset ── */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ── Body ── */
body {
    font-family: var(--font-primary);
    background-color: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.4s ease, color 0.4s ease;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Dark mode body: subtle top glow from cyan */
:root.dark body {
    background-color: var(--bg-main);
    background-image:
        radial-gradient(ellipse 80% 40% at 50% -10%, rgba(0, 229, 255, 0.07) 0%, transparent 70%);
}

/* Light mode body: warm off-white with very subtle cyan warmth */
body:not(:root.dark body) {
    background-color: var(--bg-main);
    background-image:
        radial-gradient(ellipse 80% 40% at 50% -10%, rgba(0, 153, 187, 0.05) 0%, transparent 70%);
}

/* ── Typography ── */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    letter-spacing: -0.01em;
}

h1 {
    font-size: 2.5rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

h2 {
    font-size: 1.9rem;
}

h3 {
    font-size: 1.4rem;
}

p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

a {
    color: var(--accent-primary);
    text-decoration: none;
    transition: var(--transition-smooth);
}

a:hover {
    color: var(--accent-interactive);
    opacity: 0.9;
}

/* ── Container ── */
.container {
    max-width: 1800px;
    width: 95%;
    margin: 0 auto;
    padding: 0 15px;
}

.container-fluid {
    width: 100%;
    margin: 0;
    padding: 0;
}

/* ── Cards ── */
:root.dark .card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    box-shadow: var(--shadow-card);
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

:root.dark .card:hover {
    border-color: var(--border-accent);
    box-shadow: var(--shadow-card), var(--shadow-glow-cyan);
}

/* ── Scrollbar (light) ── */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-main);
}

::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.12);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 153, 187, 0.4);
}

/* ── Scrollbar (dark override) ── */
:root.dark ::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
}

:root.dark ::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 229, 255, 0.3);
}

/* ── Glass ── */
.glass {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
}

/* ── Overlays ── */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.75);
    z-index: 1000;
    display: none;
    animation: fadeIn 0.25s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* ── Helpers ── */
.text-center {
    text-align: center;
}

.text-muted {
    color: var(--text-muted);
}

.text-primary {
    color: var(--text-primary);
}

.mt-4 {
    margin-top: 1.5rem;
}

.mb-4 {
    margin-bottom: 1.5rem;
}

/* ── Glow utilities ── */
.glow-cyan {
    text-shadow: 0 0 12px rgba(0, 229, 255, 0.6);
}

.glow-gold {
    text-shadow: 0 0 12px rgba(240, 192, 64, 0.6);
}

/* ── Bounce hover ── */
.animate-bounce-hover {
    transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.animate-bounce-hover:hover {
    transform: translateY(-5px);
}

/* ── Hide scrollbar ── */
.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.hide-scrollbar::-webkit-scrollbar {
    display: none;
}

/* ── Accent Bar (top border highlight) ── */
:root.dark .card[style*="border-top"] {
    border-top-color: var(--accent-highlight) !important;
}

/* ── Navbar dark override ── */
:root.dark header {
    background: rgba(13, 17, 23, 0.88) !important;
    backdrop-filter: blur(18px) !important;
    border-bottom: 1px solid var(--border-color) !important;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04) !important;
}

:root.dark header a {
    color: var(--text-secondary);
}

:root.dark header a:hover {
    color: var(--accent-primary);
}

/* ── Navbar light ── */
header {
    background: rgba(255, 255, 255, 0.82) !important;
    backdrop-filter: blur(16px) !important;
    border-bottom: 1px solid var(--border-color) !important;
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.06) !important;
}

header a {
    color: var(--text-secondary);
}

header a:hover {
    color: var(--accent-primary);
}

/* ── Accent line separator ── */
.accent-line {
    height: 1px;
    background: linear-gradient(90deg,
            transparent 0%,
            var(--accent-primary) 30%,
            var(--accent-primary) 70%,
            transparent 100%);
    opacity: 0.35;
    margin: 24px 0;
}

/* ── Nav Dropdown ── */
.nav-dropdown-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font-primary);
    font-size: inherit;
    font-weight: bold;
    text-transform: uppercase;
    color: var(--text-secondary);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 0;
    transition: color 0.2s;
}

.nav-dropdown-btn:hover {
    color: var(--accent-primary);
}

header .nav-dropdown-btn {
    color: var(--text-secondary);
}

.nav-dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    padding: 6px;
    min-width: 200px;
    box-shadow: var(--shadow-default);
    z-index: 200;
}

.nav-dropdown-wrap.open .nav-dropdown-menu {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.nav-dropdown-wrap.open .nav-dropdown-btn {
    color: var(--accent-primary);
}

.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 7px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: none;
    letter-spacing: 0;
    transition: background 0.2s, color 0.2s;
}

.nav-dropdown-item:hover {
    background: rgba(0, 229, 255, 0.08);
    color: var(--accent-primary);
}

.nav-dropdown-item i {
    width: 16px;
    text-align: center;
    color: var(--accent-primary);
}