﻿/* =============== Theme Tokens (shared) =============== */
:root {
    /* Core palette */
    --primary: #0b0c0a;
    --secondary: #12130f;
    --surface: #171914;
    --surface-2: #20241b;
    --surface-strong: #1d2119;
    --accent: #d8b365;
    --accent-2: #7a9b76;
    --highlight: #e7c876;
    --success: #78b07a;
    --warning: #d69a46;
    --danger: #d35d55;
    --text: #f3f0e7;
    --muted: #a8a293;

    /* Effects */
    --glass: rgba(238, 229, 207, 0.055);
    --glass-bd: rgba(216, 179, 101, 0.16);
    --glow: 0 18px 42px rgba(216, 179, 101, 0.18);
    --shadow-1: 0 14px 36px rgba(0, 0, 0, 0.26);
    --shadow-2: 0 30px 90px rgba(0, 0, 0, 0.42);

    /* Layout */
    --radius-lg: 8px;
    --radius-md: 8px;
    --radius-sm: 6px;
    --gap: 16px;
    --pad: 16px;
    --header-h: 64px;

    /* Typography */
    --font: Inter, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial,
    "Apple Color Emoji", "Segoe UI Emoji";
    --h1: 1.5rem;
    --h2: 1.25rem;
    --body: 0.95rem;
    --label: 0.8rem;

    /* Motion */
    --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --dur: 0.28s;
}

@media (min-width: 768px) {
    :root {
        --gap: 20px;
        --pad: 20px;
        --header-h: 76px;
        --h1: 2rem;
        --h2: 1.35rem;
        --body: 1rem;
    }
}
@media (min-width: 1200px) {
    :root {
        --gap: 24px;
        --pad: 24px;
        --header-h: 84px;
        --h1: 2.2rem;
        --h2: 1.5rem;
    }
}

/* =============== Base =============== */
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
    margin: 0;
    font-family: var(--font);
    color: var(--text);
    background:
            linear-gradient(rgba(216, 179, 101, 0.03) 1px, transparent 1px),
            linear-gradient(90deg, rgba(122, 155, 118, 0.025) 1px, transparent 1px),
            linear-gradient(180deg, #15170f 0%, #0b0c0a 48%, #070806 100%);
    background-size: 44px 44px, 44px 44px, auto;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
[hidden] { display: none !important; }

/* =============== Background & Particles =============== */
.bg-animation,
.bg-particles {
    position: fixed; inset: 0; pointer-events: none; z-index: -1;
}
.bg-particles { display: none; }
.bg-animation {
    background:
            radial-gradient(circle at 78% 12%, rgba(216, 179, 101, 0.12), transparent 32%),
            linear-gradient(90deg, rgba(122, 155, 118, 0.11), transparent 42%);
}
.particle {
    position: absolute;
    width: 4px; height: 4px; border-radius: 50%;
    background: var(--highlight); opacity: 0.28;
    animation: float 6s var(--ease) infinite;
    will-change: transform, opacity;
    backface-visibility: hidden;
}
@keyframes float {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-16px) scale(1.15); }
}
@media (max-width: 480px) { .particle { display: none; } }

/* =============== Shared Buttons =============== */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    padding: 11px 14px; border-radius: var(--radius-sm); border: 1px solid transparent; cursor: pointer;
    transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), background var(--dur) var(--ease);
    font-weight: 700;
}
.btn:active { transform: translateY(1px); }
.btn.is-loading {
    pointer-events: none;
    opacity: 0.85;
    position: relative;
}
.btn.is-loading::after {
    content: '';
    width: 16px; height: 16px; border-radius: 50%;
    border: 2px solid rgba(255,255,255,.5);
    border-top-color: #fff;
    animation: spin .8s linear infinite;
    display: inline-block; margin-left: 8px; vertical-align: middle;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* =============== Reduced Motion =============== */
@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; }
}
