/* Arcade Cloud - Custom Styles */

/* ============================================
   CUSTOM PROPERTIES (CSS Variables)
   ============================================ */
:root {
    /* Brand Colors */
    --color-sky: #38BDF8;
    --color-indigo: #6366F1;
    --color-violet: #A78BFA;

    /* Dark Mode Surfaces */
    --color-bg: #06060B;
    --color-surface: #0D0D16;
    --color-surface-2: #13131F;
    --color-surface-3: #1A1A2A;
    --color-border: #2A2A3D;

    /* Text Colors */
    --color-text-primary: #EEEEF5;
    --color-text-muted: #7B7B9E;

    /* Spacing Scale (Base 4px) */
    --space-1: 0.25rem;  /* 4px */
    --space-2: 0.5rem;   /* 8px */
    --space-3: 0.75rem;  /* 12px */
    --space-4: 1rem;     /* 16px */
    --space-5: 1.25rem;  /* 20px */
    --space-6: 1.5rem;   /* 24px */
    --space-8: 2rem;     /* 32px */
    --space-10: 2.5rem;  /* 40px */
    --space-12: 3rem;    /* 48px */
    --space-16: 4rem;    /* 64px */
    --space-20: 5rem;    /* 80px */
    --space-24: 6rem;    /* 96px */
}

/* ============================================
   BASE STYLES
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'DM Sans', system-ui, -apple-system, sans-serif;
    background-color: var(--color-bg);
    color: var(--color-text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    font-weight: 700;
    line-height: 1.2;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #6366F1 0%, #38BDF8 50%, #A78BFA 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Gradient Border */
.gradient-border {
    position: relative;
    background: var(--color-surface-2);
    border-radius: 1rem;
}

.gradient-border::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 2px;
    background: linear-gradient(135deg, #6366F1, #38BDF8, #A78BFA);
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

/* Smooth Scroll */
html {
    scroll-behavior: smooth;
}

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

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

::-webkit-scrollbar-thumb {
    background: var(--color-surface-3);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-sky);
}

/* ============================================
   ANIMATIONS
   ============================================ */

/* Fade In Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* Pulse Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Float Animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* ============================================
   NAVBAR STYLES
   ============================================ */
.navbar {
    transition: all 0.3s ease;
}

.navbar.scrolled {
    background-color: rgba(6, 6, 11, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Mobile Menu */
.mobile-menu {
    display: none;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.mobile-menu.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   BUTTON STYLES
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 2rem;
    font-weight: 600;
    font-size: 0.875rem;
    border-radius: 9999px;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    text-decoration: none;
}

.btn-primary {
    background-color: var(--color-sky);
    color: var(--color-bg);
}

.btn-primary:hover {
    filter: brightness(1.1);
    box-shadow: 0 10px 25px -5px rgba(56, 189, 248, 0.3);
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid var(--color-border);
    color: var(--color-text-primary);
}

.btn-secondary:hover {
    background-color: var(--color-surface-3);
    border-color: var(--color-sky);
}

.btn-ghost {
    background-color: transparent;
    color: var(--color-sky);
    padding: 0;
}

.btn-ghost:hover {
    text-decoration: underline;
}

/* ============================================
   CARD STYLES
   ============================================ */
.card {
    background-color: var(--color-surface-2);
    border: 1px solid var(--color-border);
    border-radius: 1rem;
    padding: 2rem;
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1),
                0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.card-featured {
    border-color: var(--color-sky);
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.1);
}

/* ============================================
   ICON STYLES
   ============================================ */
.icon-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    background: linear-gradient(135deg, var(--color-indigo), var(--color-sky));
}

/* ============================================
   BACKGROUND EFFECTS
   ============================================ */
.gradient-blur {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
    pointer-events: none;
}

.gradient-blur-1 {
    width: 400px;
    height: 400px;
    background: var(--color-indigo);
    top: 0;
    left: 25%;
}

.gradient-blur-2 {
    width: 400px;
    height: 400px;
    background: var(--color-sky);
    top: 160px;
    right: 25%;
}

/* ============================================
   RESPONSIVE UTILITIES
   ============================================ */
@media (max-width: 768px) {
    .mobile-hidden {
        display: none !important;
    }

    .mobile-menu-button {
        display: block;
    }
}

@media (min-width: 769px) {
    .mobile-menu-button {
        display: none;
    }

    .desktop-hidden {
        display: none !important;
    }
}

/* ============================================
   TYPOGRAPHY SCALE
   ============================================ */
.text-display {
    font-size: 3rem;      /* 48px */
    font-weight: 800;
}

.text-h1 {
    font-size: 2.25rem;   /* 36px */
    font-weight: 700;
}

.text-h2 {
    font-size: 1.75rem;   /* 28px */
    font-weight: 700;
}

.text-h3 {
    font-size: 1.375rem;  /* 22px */
    font-weight: 600;
}

.text-h4 {
    font-size: 1.125rem;  /* 18px */
    font-weight: 600;
}

.text-body-lg {
    font-size: 1rem;      /* 16px */
    font-weight: 400;
}

.text-body {
    font-size: 0.875rem;  /* 14px */
    font-weight: 400;
}

.text-caption {
    font-size: 0.75rem;   /* 12px */
    font-weight: 400;
}

/* ============================================
   SECTION SPACING
   ============================================ */
.section {
    padding-top: var(--space-20);
    padding-bottom: var(--space-20);
}

@media (min-width: 1024px) {
    .section {
        padding-top: var(--space-24);
        padding-bottom: var(--space-24);
    }
}

/* ============================================
   CONTAINER
   ============================================ */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding-left: var(--space-6);
    padding-right: var(--space-6);
}

@media (min-width: 640px) {
    .container {
        padding-left: var(--space-8);
        padding-right: var(--space-8);
    }
}

@media (min-width: 1024px) {
    .container {
        padding-left: var(--space-16);
        padding-right: var(--space-16);
    }
}

/* ============================================
   LOADING STATES
   ============================================ */
.skeleton {
    background: linear-gradient(
        90deg,
        var(--color-surface-2) 25%,
        var(--color-surface-3) 50%,
        var(--color-surface-2) 75%
    );
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* ============================================
   FOCUS STYLES (Accessibility)
   ============================================ */
*:focus-visible {
    outline: 2px solid var(--color-sky);
    outline-offset: 2px;
}

button:focus-visible,
a:focus-visible {
    outline: 2px solid var(--color-sky);
    outline-offset: 2px;
}
