/* SaveBite – CSS Custom Properties, Base Reset & Global Animations */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    /* Color Palette */
    --primary:        #10b981;
    --primary-glow:   rgba(16, 185, 129, 0.15);
    --primary-hover:  #059669;
    --secondary:      #f97316;
    --secondary-glow: rgba(249, 115, 22, 0.15);
    --secondary-hover: #ea580c;
    --accent:   #3b82f6;
    --danger:   #ef4444;
    --warning:  #f59e0b;

    /* Theme Colors (Dark Mode) */
    --bg-dark:        #0b0f19;
    --bg-card:        rgba(30, 41, 59, 0.5);
    --bg-card-hover:  rgba(30, 41, 59, 0.85);
    --border-color:   rgba(255, 255, 255, 0.08);
    --border-glow:    rgba(16, 185, 129, 0.3);
    --text-main:  #f8fafc;
    --text-muted: #94a3b8;
    --glass-blur: blur(16px);
    --surface:     #151d30;
    --surface-alt: #1a2540;

    /* Layout & Shadow */
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 24px;
    --shadow-sm: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -2px rgba(0,0,0,0.1);
    --shadow-md: 0 10px 15px -3px rgba(0,0,0,0.3), 0 4px 6px -4px rgba(0,0,0,0.3);
    --shadow-lg: 0 20px 25px -5px rgba(0,0,0,0.5), 0 8px 10px -6px rgba(0,0,0,0.5);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base Reset */
* {
    margin: 0; padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.2) transparent;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
    background-image:
        radial-gradient(at 10% 10%, rgba(16,185,129,0.08) 0px, transparent 50%),
        radial-gradient(at 90% 80%, rgba(249,115,22,0.08) 0px, transparent 50%);
    background-attachment: fixed;
}

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.3); }

/* Utility */
.glow-effect  { box-shadow: 0 0 15px var(--primary-glow); }
.text-gradient {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Keyframe Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes slideInRight {
    from { transform: translateX(100%); }
    to   { transform: translateX(0); }
}
@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50%       { transform: scale(1.05); opacity: 0.9; }
}
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-8px); }
}
@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ── Landing page animations (reference design) ── */
@keyframes heroMask {
    from { transform: translateY(115%); }
    to   { transform: translateY(0); }
}
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(22px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes auroraA {
    0%,100% { transform: translate(0,0) scale(1); }
    50%     { transform: translate(7%,-6%) scale(1.18); }
}
@keyframes auroraB {
    0%,100% { transform: translate(0,0) scale(1.12); }
    50%     { transform: translate(-9%,7%) scale(1); }
}
@keyframes auroraC {
    0%,100% { transform: translate(0,0) scale(1); }
    50%     { transform: translate(6%,9%) scale(1.1); }
}
@keyframes floaty {
    0%,100% { transform: translateY(0); }
    50%     { transform: translateY(-16px); }
}
@keyframes floatyB {
    0%,100% { transform: translate(0,0) rotate(0deg); }
    50%     { transform: translate(0,-22px) rotate(10deg); }
}
@keyframes dotFloat {
    0%,100% { transform: translate(0,0) rotate(0deg); }
    33%     { transform: translate(18px,-42px) rotate(12deg); }
    66%     { transform: translate(-10px,-65px) rotate(-8deg); }
}
@keyframes dotFloatB {
    0%,100% { transform: translate(0,0) rotate(0deg); }
    40%     { transform: translate(-24px,-45px) rotate(-16deg); }
    75%     { transform: translate(14px,-68px) rotate(10deg); }
}
@keyframes dotFloatC {
    0%,100% { transform: translate(0,0) rotate(0deg); }
    30%     { transform: translate(30px,-28px) rotate(20deg); }
    60%     { transform: translate(-16px,-58px) rotate(-12deg); }
    85%     { transform: translate(12px,-42px) rotate(6deg); }
}
@keyframes dotFloatD {
    0%,100% { transform: translate(0,0) rotate(0deg); }
    25%     { transform: translate(-32px,-36px) rotate(-20deg); }
    55%     { transform: translate(22px,-62px) rotate(16deg); }
    80%     { transform: translate(-10px,-32px) rotate(-5deg); }
}
@keyframes landingMarquee {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

/* ── Light Theme Overrides ── */
[data-theme="light"] {
    --bg-dark:        #FAF9F6;
    --bg-card:        rgba(255, 255, 255, 0.82);
    --bg-card-hover:  rgba(255, 255, 255, 0.97);
    --border-color:   rgba(14, 14, 16, 0.1);
    --border-glow:    rgba(16, 185, 129, 0.3);
    --text-main:      #0E0E10;
    --text-muted:     #6B6B72;
    --surface:        #ffffff;
    --surface-alt:    #F0EDE8;
    --shadow-sm: 0 4px 6px -1px rgba(0,0,0,0.06), 0 2px 4px -2px rgba(0,0,0,0.04);
    --shadow-md: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.06);
    --shadow-lg: 0 20px 25px -5px rgba(0,0,0,0.12), 0 8px 10px -6px rgba(0,0,0,0.08);
}

[data-theme="light"] body {
    background-image:
        radial-gradient(at 10% 10%, rgba(16,185,129,0.06) 0px, transparent 50%),
        radial-gradient(at 90% 80%, rgba(249,115,22,0.05) 0px, transparent 50%);
}

[data-theme="light"] { scrollbar-color: rgba(0,0,0,0.2) transparent; }
[data-theme="light"] ::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.15); }
[data-theme="light"] ::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.25); }
