/*
 * Cashoria V3.0 - Professional & Polished CSS Theme
 * Developed by Gemini
 * Date: 03-10-2025
 */

/* 1. SETUP & VARIABLES
-------------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
    --primary-color: #367BF5; /* A slightly more vibrant blue */
    --primary-hover-color: #2a6dd9;
    --secondary-color: #6c757d; /* Gray */
    --success-color: #198754; /* Green */
    --danger-color: #dc3545; /* Red */
    --warning-color: #ffc107; /* Yellow */
    --info-color: #0dcaf0;   /* Cyan */
    
    --background-light: #F4F7FC; /* A very light, cool gray */
    --card-background-color: #ffffff;
    --text-color-dark: #212529;
    --text-color-light: #5a6a85;
    
    --border-color-light: #e3e8f0;
    --default-border-radius: 0.8rem; /* 12.8px for a softer look */
    --shadow-soft: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-strong: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);

    --font-family-sans-serif: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* 2. GLOBAL STYLES & RESETS
-------------------------------------------------- */
body, html {
    height: 100%;
}

body {
    background-color: var(--background-light);
    font-family: var(--font-family-sans-serif);
    color: var(--text-color-dark);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body:not(.admin-body) {
    display: flex;
    flex-direction: column;
}
main.container {
    flex: 1;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.2s ease-in-out;
}

a:hover {
    color: var(--primary-hover-color);
    text-decoration: none;
}

h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--text-color-dark);
}

.text-muted {
    color: var(--text-color-light) !important;
}

/* 3. LAYOUT & STRUCTURE
-------------------------------------------------- */
.main-wrapper { 
    display: flex; 
    min-height: 100vh; 
}
.content-wrapper { 
    flex-grow: 1; 
    padding: 2rem; 
    width: calc(100% - 260px); 
}

/* 4. COMPONENTS
-------------------------------------------------- */
/* Navbar */
.navbar-dark {
    background-color: #1e293b; /* A darker, professional blue-gray */
}
.navbar { 
    box-shadow: 0 2px 4px rgba(0,0,0,0.05); 
}

/* Cards */
.card {
    border: 1px solid var(--border-color-light);
    border-radius: var(--default-border-radius);
    box-shadow: var(--shadow-soft);
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}
.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-strong);
}
.card-header {
    background-color: var(--card-background-color);
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color-light);
    font-size: 1.1rem;
}
.card-body { padding: 1.5rem; }

/* Buttons */
.btn {
    border-radius: 0.5rem;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border: none;
    transition: all 0.2s ease-in-out;
}
.btn-primary {
    background: linear-gradient(45deg, var(--primary-color), #5a95f8);
    color: #fff;
    box-shadow: 0 4px 12px rgba(54, 123, 245, 0.3);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(54, 123, 245, 0.4);
    color: #fff;
}
.btn:hover {
    transform: translateY(-2px);
}

/* Forms */
.form-control, .form-select {
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color-light);
    background-color: var(--background-light);
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(54, 123, 245, 0.25);
    background-color: #fff;
}
.form-label { font-weight: 500; }

/* Badges */
.badge {
    padding: 0.4em 0.8em;
    font-weight: 600;
    font-size: 0.8rem;
}

/* 5. PAGE-SPECIFIC STYLES
-------------------------------------------------- */
/* Homepage */
.hero-section {
    background: linear-gradient(45deg, #1e293b, #334155);
    padding: 6rem 0;
}
.how-it-works-section .step-icon {
    width: 70px; height: 70px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 2rem;
    background: linear-gradient(45deg, var(--primary-color), #5a95f8);
    box-shadow: 0 4px 12px rgba(54, 123, 245, 0.4);
}
.features-section { background-color: #fff; }
.cta-section { background-color: var(--background-light); }

/* User Dashboard */
.stat-card {
    background-color: var(--card-background-color);
    border-radius: var(--default-border-radius);
    padding: 1.5rem;
}
.stat-card .stat-icon {
    font-size: 1.75rem;
    width: 50px; height: 50px;
    line-height: 50px;
    text-align: center;
    border-radius: 0.5rem;
    margin-right: 1rem;
}
.stat-card .stat-info h5 { font-size: 0.8rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.5px; }
.stat-card .stat-info p { font-size: 1.75rem; font-weight: 700; }

/* Offer Wall */
.offer-card:hover {
    border: 1px solid var(--primary-color);
}
.offer-card .reward-badge {
    background-color: rgba(25, 135, 84, 0.1);
    color: var(--success-color);
    padding: 0.5rem 1rem;
    border-radius: 50rem;
    font-weight: 700;
    font-size: 0.9rem;
}

/* 6. ADMIN PANEL
-------------------------------------------------- */
.admin-sidebar {
    width: 260px;
    flex-shrink: 0;
    background-color: #111827; /* Darker blue-gray */
    border-right: 1px solid var(--border-color-light);
}
.admin-sidebar .sidebar-heading {
    padding: 0.75rem 1.5rem;
    font-size: 0.7rem;
    text-transform: uppercase;
    color: var(--text-color-light);
    font-weight: 700;
}
.admin-sidebar .nav-link {
    color: #9ca3af;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    border-left: 3px solid transparent;
    margin: 0.1rem 0;
}
.admin-sidebar .nav-link:hover {
    color: #fff;
    background-color: rgba(255,255,255,0.05);
}
.admin-sidebar .nav-link.active {
    color: #fff;
    background-color: var(--primary-color);
    border-left-color: #fff;
}
.admin-sidebar .fa-fw {
    width: 1.25em;
    text-align: center;
    margin-right: 0.75rem;
}

/* 7. ANIMATIONS & UTILITIES
-------------------------------------------------- */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

/* 8. RESPONSIVE DESIGN
-------------------------------------------------- */
@media (max-width: 768px) {
    .content-wrapper { padding: 1rem; }
    .hero-section { padding: 4rem 1rem; }
    .hero-section h1 { font-size: 2.5rem; }
    .admin-sidebar { margin-left: -260px; } /* for JS toggling */
}
/* Fix for Hero Section Title Color */
.hero-section h1 {
    color: #ffffff;
}
