/* =========================================================
   ARBITRAGE AI V2
   Approved design board foundations
   ========================================================= */

:root {
    /* Core colours */
    --aa-bg: #0B1220;
    --aa-panel: #111827;
    --aa-card: #1F2937;
    --aa-card-hover: #263244;
    --aa-border: #374151;

    --aa-primary: #16A34A;
    --aa-primary-hover: #22C55E;
    --aa-primary-active: #15803D;
    --aa-primary-soft: rgba(22, 163, 74, 0.14);
    --aa-primary-border: rgba(34, 197, 94, 0.52);

    --aa-blue: #2563EB;
    --aa-blue-soft: rgba(37, 99, 235, 0.16);

    --aa-text: #F9FAFB;
    --aa-muted: #9CA3AF;
    --aa-muted-strong: #D1D5DB;
    --aa-muted-dark: #6B7280;

    --aa-danger: #EF4444;
    --aa-danger-soft: rgba(239, 68, 68, 0.14);

    --aa-warning: #F59E0B;
    --aa-warning-soft: rgba(245, 158, 11, 0.14);

    --aa-purple: #7C3AED;
    --aa-purple-soft: rgba(124, 58, 237, 0.15);

    --aa-success: #22C55E;

    /* Marketplace colours */
    --aa-facebook: #1877F2;
    --aa-ebay-red: #E53238;
    --aa-telegram: #229ED9;
    --aa-shpock: #25C765;
    --aa-gumtree: #72BF44;

    /* Typography */
    --aa-font:
        Inter,
        ui-sans-serif,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Helvetica,
        Arial,
        sans-serif;

    --aa-h1-size: 32px;
    --aa-h2-size: 24px;
    --aa-h3-size: 18px;
    --aa-body-size: 14px;
    --aa-small-size: 12px;
    --aa-micro-size: 11px;

    --aa-h1-weight: 700;
    --aa-h2-weight: 600;
    --aa-h3-weight: 600;
    --aa-body-weight: 400;

    /* Radius */
    --aa-radius-xs: 5px;
    --aa-radius-sm: 7px;
    --aa-radius-md: 9px;
    --aa-radius-lg: 12px;
    --aa-radius-xl: 16px;

    /* Spacing */
    --aa-space-1: 4px;
    --aa-space-2: 8px;
    --aa-space-3: 12px;
    --aa-space-4: 16px;
    --aa-space-5: 20px;
    --aa-space-6: 24px;
    --aa-space-7: 28px;
    --aa-space-8: 32px;
    --aa-space-10: 40px;
    --aa-space-12: 48px;

    /* Shadows */
    --aa-shadow-sm:
        0 1px 2px rgba(0, 0, 0, 0.22);

    --aa-shadow-card:
        0 12px 32px rgba(0, 0, 0, 0.20);

    --aa-shadow-panel:
        0 22px 60px rgba(0, 0, 0, 0.34);

    --aa-shadow-green:
        0 8px 24px rgba(22, 163, 74, 0.20);

    /* Motion */
    --aa-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
    --aa-fast: 140ms;
    --aa-normal: 220ms;
    --aa-slow: 420ms;

    /* Layout */
    --aa-sidebar-width: 220px;
    --aa-topbar-height: 64px;
    --aa-content-max: 1440px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    margin: 0;
    color: var(--aa-text);
    background:
        radial-gradient(
            circle at 50% -10%,
            rgba(22, 163, 74, 0.055),
            transparent 34%
        ),
        var(--aa-bg);
    font-family: var(--aa-font);
    font-size: var(--aa-body-size);
    font-weight: var(--aa-body-weight);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

a {
    color: inherit;
    text-decoration: none;
}

img,
svg {
    display: block;
    max-width: 100%;
}

::selection {
    color: var(--aa-text);
    background: rgba(22, 163, 74, 0.42);
}

.aa-h1,
h1.aa-heading {
    margin: 0;
    color: var(--aa-text);
    font-size: var(--aa-h1-size);
    font-weight: var(--aa-h1-weight);
    line-height: 1.2;
    letter-spacing: -0.025em;
}

.aa-h2 {
    margin: 0;
    color: var(--aa-text);
    font-size: var(--aa-h2-size);
    font-weight: var(--aa-h2-weight);
    line-height: 1.3;
    letter-spacing: -0.018em;
}

.aa-h3 {
    margin: 0;
    color: var(--aa-text);
    font-size: var(--aa-h3-size);
    font-weight: var(--aa-h3-weight);
    line-height: 1.35;
}

.aa-body {
    color: var(--aa-text);
    font-size: var(--aa-body-size);
}

.aa-small {
    color: var(--aa-muted);
    font-size: var(--aa-small-size);
}

.aa-muted {
    color: var(--aa-muted);
}

.aa-success-text {
    color: var(--aa-success);
}

.aa-danger-text {
    color: var(--aa-danger);
}

.aa-divider {
    width: 100%;
    height: 1px;
    border: 0;
    background: var(--aa-border);
}

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

.aa-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    white-space: nowrap;
    border: 0;
    clip: rect(0, 0, 0, 0);
}

@keyframes aa-fade-up {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes aa-pulse {
    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.62;
        transform: scale(0.88);
    }
}

@keyframes aa-spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes aa-shimmer {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

.aa-animate-in {
    animation: aa-fade-up var(--aa-slow) var(--aa-ease) both;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
