:root {
    --yellow: #facc15;
    --yellow-soft: #fde047;
    --blue: #3b82f6;
    --blue-soft: #60a5fa;
    --ink: #060a17;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--ink);
    color: #e2e8f0;
    position: relative;
    overflow-x: hidden;
}

.font-display {
    font-family: 'Space Grotesk', sans-serif;
}

/* ===== Global fixed background: animated glow + grid, one continuous scene ===== */
.bg-scene {
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(650px circle at 15% 15%, rgba(250, 204, 21, 0.18), transparent 60%),
        radial-gradient(750px circle at 88% 78%, rgba(59, 130, 246, 0.24), transparent 60%),
        radial-gradient(900px circle at 50% 105%, rgba(250, 204, 21, 0.1), transparent 70%),
        var(--ink);
    background-repeat: no-repeat;
    animation: drift 20s ease-in-out infinite alternate;
}

.bg-grid {
    position: fixed;
    inset: 0;
    z-index: -1;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse 85% 65% at 50% 0%, black 40%, transparent 100%);
    mask-image: radial-gradient(ellipse 85% 65% at 50% 0%, black 40%, transparent 100%);
}

@keyframes drift {
    0% {
        background-position: 0% 0%, 0% 0%, 0% 0%, 0 0;
    }
    100% {
        background-position: 4% 5%, -5% -4%, 2% -3%, 0 0;
    }
}

/* Same grid pattern as .bg-grid, but positioned relative to its own
   container instead of the viewport — safe to reuse inside cards. */
.bg-grid-local {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(6, 10, 23, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(6, 10, 23, 0.06) 1px, transparent 1px);
    background-size: 40px 40px;
}

/* ===== Gradient text ===== */
.text-gradient {
    background-image: linear-gradient(90deg, var(--yellow-soft), var(--blue-soft));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* ===== Glass surfaces ===== */
.glass {
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.glass-card {
    position: relative;
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    transition: border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-6px);
    border-color: rgba(250, 204, 21, 0.4);
    box-shadow: 0 22px 60px -18px rgba(59, 130, 246, 0.45);
}

.card-index {
    position: absolute;
    top: 0.25rem;
    right: 1.25rem;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 3.25rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.06);
    line-height: 1;
    pointer-events: none;
}

/* ===== Gradient-border wrapper (hero visual, about image) ===== */
.glow-border {
    position: relative;
    border-radius: 1.75rem;
    background: linear-gradient(135deg, rgba(250, 204, 21, 0.7), rgba(59, 130, 246, 0.7));
    padding: 1.5px;
}

.glow-border > * {
    border-radius: calc(1.75rem - 1.5px);
}

/* ===== Buttons ===== */
.btn-glow {
    box-shadow: 0 10px 30px -10px rgba(250, 204, 21, 0.65);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.btn-glow:hover {
    box-shadow: 0 14px 40px -8px rgba(59, 130, 246, 0.65);
    transform: translateY(-2px);
}

/* ===== Navbar ===== */
#navbar {
    background: transparent;
    border-bottom: 1px solid transparent;
    transition: background 0.3s ease, border-color 0.3s ease;
}

#navbar.scrolled {
    background: rgba(6, 10, 23, 0.75);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* ===== Marquee logos ===== */
.marquee-mask {
    -webkit-mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
    mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
}

.marquee-track {
    display: flex;
    width: max-content;
    animation: marquee 26s linear infinite;
}

@keyframes marquee {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

/* ===== Scroll reveal ===== */
.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in-view {
    opacity: 1;
    transform: translateY(0);
}

/* ===== Skill / capability bars ===== */
.bar-track {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    overflow: hidden;
    height: 8px;
}

.bar-fill {
    height: 100%;
    border-radius: 999px;
    width: 0;
    background: linear-gradient(90deg, var(--yellow), var(--blue));
    transition: width 1.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ===== Cursor glow (desktop only) ===== */
#cursorGlow {
    position: fixed;
    top: 0;
    left: 0;
    width: 440px;
    height: 440px;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.14), transparent 70%);
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 0;
    will-change: transform;
}

/* ===== Pulsing badge dot ===== */
.pulse-dot {
    position: relative;
}

.pulse-dot::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 999px;
    background: inherit;
    opacity: 0.6;
    animation: pulseRing 2s ease-out infinite;
}

@keyframes pulseRing {
    0% {
        transform: scale(1);
        opacity: 0.6;
    }
    100% {
        transform: scale(2.6);
        opacity: 0;
    }
}

/* ===== Custom scrollbar ===== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--ink);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(var(--yellow), var(--blue));
    border-radius: 999px;
}

/* ===== Shop: category chips, wishlist ===== */
.chip {
    padding: 0.5rem 1rem;
    border-radius: 999px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #cbd5e1;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.chip:hover {
    color: #fde047;
    border-color: rgba(250, 204, 21, 0.4);
}

.chip-active,
.chip-active:hover {
    color: var(--ink);
    background: linear-gradient(90deg, var(--yellow), var(--blue));
    border-color: transparent;
}

.wish[aria-pressed="true"] {
    color: #fb7185;
}

.wish[aria-pressed="true"] svg {
    fill: currentColor;
}

/* Tailwind display utilities (flex, grid) would otherwise override the hidden attribute */
[hidden] {
    display: none !important;
}
