/* PayRabbit - African-Inspired AI Financial Platform */

/* CSS Custom Properties */
:root {
    /* African-inspired color palette */
    --sunset-orange: #ff6b35;
    --golden-yellow: #f7931e;
    --earth-brown: #8b4513;
    --safari-green: #228b22;
    --ocean-blue: #0066cc;
    --sunrise-pink: #ff69b4;
    --desert-sand: #f4e4bc;
    --baobab-bark: #654321;
    --savanna-gold: #daa520;
    --kente-red: #dc143c;
    --kente-yellow: #ffd700;
    --kente-green: #32cd32;
    --kente-blue: #4169e1;
    --kente-purple: #8a2be2;
    
    /* Modern tech colors */
    --tech-cyan: #00ffff;
    --tech-magenta: #ff00ff;
    --tech-lime: #00ff00;
    --tech-orange: #ff8c00;
    --tech-purple: #9370db;
    
    /* Light theme colors */
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --border-light: #e2e8f0;
    --border-medium: #cbd5e1;
    --shadow-light: rgba(0, 0, 0, 0.1);
    --shadow-medium: rgba(0, 0, 0, 0.15);
    
    /* Background gradients */
    --african-sunset: linear-gradient(135deg, #ff6b35, #f7931e, #ffd700);
    --savanna-dawn: linear-gradient(135deg, #ff69b4, #ff6b35, #f7931e);
    --ocean-horizon: linear-gradient(135deg, #0066cc, #00ffff, #32cd32);
    --kente-pride: linear-gradient(135deg, #dc143c, #ffd700, #32cd32, #4169e1);
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-heading: 'Inter', sans-serif;
    
    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;
    
    /* Border radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* Base Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 25%, #0f3460 50%, #533483 75%, #e94560 100%);
    background-attachment: fixed;
    color: #f8f9fa;
    min-height: 100vh;
    position: relative;
    line-height: 1.6;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(255, 107, 53, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(247, 147, 30, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(0, 102, 204, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: var(--spacing-md);
}

h1 { font-size: 3rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 2rem; }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1.125rem; }

p {
    margin-bottom: var(--spacing-md);
    line-height: 1.7;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-sm) var(--spacing-lg);
    border-radius: var(--radius-full);
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition-normal);
    cursor: pointer;
    border: none;
    font-size: 1rem;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--african-sunset);
    color: white;
    box-shadow: var(--shadow-lg);
}

.btn-primary:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: var(--shadow-2xl);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px) scale(1.05);
    box-shadow: var(--shadow-xl);
}

.btn-profile {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15), 0 0 20px rgba(251, 146, 60, 0.1);
    position: relative;
}

.btn-profile::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 1rem;
    padding: 2px;
    background: linear-gradient(135deg, rgba(251, 146, 60, 0.4), rgba(245, 158, 11, 0.4), rgba(251, 146, 60, 0.4));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s;
}

.btn-profile:hover {
    background: linear-gradient(135deg, rgba(251, 146, 60, 0.15), rgba(245, 158, 11, 0.15));
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(251, 146, 60, 0.25), 0 0 40px rgba(245, 158, 11, 0.2);
    border-color: rgba(251, 146, 60, 0.4);
}

.btn-profile:hover::before {
    opacity: 1;
}

.btn-success {
    background: linear-gradient(135deg, var(--kente-green), var(--safari-green));
    color: white;
}

.btn-warning {
    background: linear-gradient(135deg, var(--kente-yellow), var(--golden-yellow));
    color: white;
}

.btn-danger {
    background: linear-gradient(135deg, var(--kente-red), var(--sunset-orange));
    color: white;
}

.btn-info {
    background: linear-gradient(135deg, var(--kente-blue), var(--ocean-blue));
    color: white;
}

/* Cards */
.card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-2xl);
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-xl);
    transition: all var(--transition-normal);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-2xl);
    border-color: var(--kente-yellow);
}

.card-header {
    margin-bottom: var(--spacing-lg);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: var(--spacing-sm);
}

.card-subtitle {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
}

.card-body {
    margin-bottom: var(--spacing-lg);
}

.card-footer {
    padding-top: var(--spacing-md);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Forms */
.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-label {
    display: block;
    margin-bottom: var(--spacing-sm);
    font-weight: 600;
    color: white;
}

.form-control {
    width: 100%;
    padding: var(--spacing-md);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    color: white;
    font-size: 1rem;
    transition: all var(--transition-normal);
}

.form-control:focus {
    outline: none;
    border-color: var(--kente-yellow);
    box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.1);
    background: rgba(255, 255, 255, 0.15);
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

/* Navigation */
.navbar {
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 107, 53, 0.3);
    position: sticky;
    top: 0;
    z-index: 50;
    box-shadow: var(--shadow-lg);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 800;
    color: white;
    text-decoration: none;
    background: var(--african-sunset);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-link {
    color: #f8f9fa;
    text-decoration: none;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-lg);
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 107, 53, 0.2), transparent);
    transition: left 0.5s;
}

.nav-link:hover::before {
    left: 100%;
}

.nav-link:hover {
    color: var(--sunset-orange);
    background: rgba(255, 107, 53, 0.1);
    transform: translateY(-2px);
}

/* Tables */
.table {
    width: 100%;
    border-collapse: collapse;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

.table th,
.table td {
    padding: var(--spacing-md);
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.table th {
    background: rgba(255, 107, 53, 0.1);
    color: white;
    font-weight: 600;
}

.table tbody tr:hover {
    background: rgba(255, 107, 53, 0.05);
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-success {
    background: rgba(50, 205, 50, 0.2);
    color: var(--kente-green);
    border: 1px solid var(--kente-green);
}

.badge-warning {
    background: rgba(255, 215, 0, 0.2);
    color: var(--kente-yellow);
    border: 1px solid var(--kente-yellow);
}

.badge-danger {
    background: rgba(220, 20, 60, 0.2);
    color: var(--kente-red);
    border: 1px solid var(--kente-red);
}

.badge-info {
    background: rgba(65, 105, 225, 0.2);
    color: var(--kente-blue);
    border: 1px solid var(--kente-blue);
}

.badge-primary {
    background: rgba(255, 107, 53, 0.2);
    color: var(--sunset-orange);
    border: 1px solid var(--sunset-orange);
}

/* Alerts */
.alert {
    padding: var(--spacing-md) var(--spacing-lg);
    border-radius: var(--radius-lg);
    margin-bottom: var(--spacing-lg);
    border: 1px solid;
    backdrop-filter: blur(20px);
}

.alert-success {
    background: rgba(50, 205, 50, 0.1);
    border-color: var(--kente-green);
    color: var(--kente-green);
}

.alert-warning {
    background: rgba(255, 215, 0, 0.1);
    border-color: var(--kente-yellow);
    color: var(--kente-yellow);
}

.alert-danger {
    background: rgba(220, 20, 60, 0.1);
    border-color: var(--kente-red);
    color: var(--kente-red);
}

.alert-info {
    background: rgba(65, 105, 225, 0.1);
    border-color: var(--kente-blue);
    color: var(--kente-blue);
}

/* Progress Bars */
.progress {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--african-sunset);
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

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

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-50px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes gradient-x {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.animate-fadeIn { animation: fadeIn 0.8s ease-out; }
.animate-slideInLeft { animation: slideInLeft 0.8s ease-out; }
.animate-slideInRight { animation: slideInRight 0.8s ease-out; }
.animate-scaleIn { animation: scaleIn 0.8s ease-out; }
.animate-float { animation: float 6s ease-in-out infinite; }
.animate-pulse { animation: pulse 2s ease-in-out infinite; }
.animate-gradient-x { 
    background-size: 200% 200%;
    animation: gradient-x 3s ease infinite;
}

/* Utility Classes */
.text-gradient {
    background: var(--african-sunset);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient-african {
    background: var(--african-sunset);
}

.bg-gradient-savanna {
    background: var(--savanna-dawn);
}

.bg-gradient-ocean {
    background: var(--ocean-horizon);
}

.bg-gradient-kente {
    background: var(--kente-pride);
}

.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.glass-strong {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 var(--spacing-sm);
    }
    
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.5rem; }
    
    .btn {
        padding: var(--spacing-sm) var(--spacing-md);
        font-size: 0.875rem;
    }
    
    .card {
        padding: var(--spacing-md);
    }
}

@media (max-width: 480px) {
    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }
    
    .btn {
        padding: var(--spacing-xs) var(--spacing-sm);
        font-size: 0.8rem;
    }
}

/* Print Styles */
@media print {
    body {
        background: white;
        color: black;
    }
    
    .navbar,
    .btn,
    .card {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --sunset-orange: #ff4500;
        --kente-yellow: #ffff00;
        --kente-green: #00ff00;
        --kente-blue: #0000ff;
        --kente-red: #ff0000;
    }
}

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