/* Base CSS with Theme Variables */
:root {
    /* Light Theme (Default) - Modern Color Palette */
    --bg-primary: #ffffff;
    --bg-secondary: #f4f7fa;
    --bg-tertiary: #e9ecef;
    --bg-tertiary-rgb: 233, 236, 239;
    --text-primary: #2d3748;
    --text-secondary: #718096;
    --accent-primary: #4f46e5;
    --accent-primary-rgb: 79, 70, 229;
    --accent-secondary: #7c3aed;
    --accent-secondary-rgb: 124, 58, 237;
    --accent-gradient: linear-gradient(135deg, #4f46e5, #7c3aed);
    --border-color: #e2e8f0;
    --border-color-rgb: 226, 232, 240;
    --shadow-color: rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #3b82f6;
    --card-radius: 12px;
    --btn-radius: 8px;
    --input-radius: 8px;
    --transition-ease: cubic-bezier(0.16, 1, 0.3, 1);
    --header-height: 64px;
}

/* Dark Theme - Refined Dark Mode */
[data-theme="dark"] {
    --bg-primary: #111827;
    --bg-secondary: #1f2937;
    --bg-tertiary: #374151;
    --bg-tertiary-rgb: 55, 65, 81;
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --accent-primary: #818cf8;
    --accent-primary-rgb: 129, 140, 248;
    --accent-secondary: #a78bfa;
    --accent-secondary-rgb: 167, 139, 250;
    --accent-gradient: linear-gradient(135deg, #818cf8, #a78bfa);
    --border-color: #374151;
    --border-color-rgb: 55, 65, 81;
    --shadow-color: rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.3), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
}

/* Ocean Theme - Light Mode */
[data-theme="ocean-light"] {
    --bg-primary: #f8fffe;
    --bg-secondary: #e6fffa;
    --bg-tertiary: #b3f5eb;
    --bg-tertiary-rgb: 179, 245, 235;
    --text-primary: #0f766e;
    --text-secondary: #0d9488;
    --accent-primary: #0891b2;
    --accent-primary-rgb: 8, 145, 178;
    --accent-secondary: #0e7490;
    --accent-secondary-rgb: 14, 116, 144;
    --accent-gradient: linear-gradient(135deg, #0891b2, #0e7490);
    --border-color: #a7f3d0;
    --border-color-rgb: 167, 243, 208;
    --shadow-color: rgba(6, 182, 212, 0.08);
    --shadow-lg: 0 10px 25px -5px rgba(6, 182, 212, 0.1), 0 10px 10px -5px rgba(6, 182, 212, 0.04);
    --success-color: #059669;
    --warning-color: #d97706;
    --danger-color: #dc2626;
    --info-color: #0284c7;
}

/* Ocean Theme - Dark Mode */
[data-theme="ocean-dark"] {
    --bg-primary: #0f1419;
    --bg-secondary: #164e63;
    --bg-tertiary: #155e75;
    --bg-tertiary-rgb: 21, 94, 117;
    --text-primary: #ecfdf5;
    --text-secondary: #a7f3d0;
    --accent-primary: #22d3ee;
    --accent-primary-rgb: 34, 211, 238;
    --accent-secondary: #0891b2;
    --accent-secondary-rgb: 8, 145, 178;
    --accent-gradient: linear-gradient(135deg, #22d3ee, #0891b2);
    --border-color: #155e75;
    --border-color-rgb: 21, 94, 117;
    --shadow-color: rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.3);
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #0ea5e9;
}

/* Sunset Theme - Light Mode */
[data-theme="sunset-light"] {
    --bg-primary: #fffbf7;
    --bg-secondary: #fef3e2;
    --bg-tertiary: #fed7aa;
    --bg-tertiary-rgb: 254, 215, 170;
    --text-primary: #9a3412;
    --text-secondary: #ea580c;
    --accent-primary: #ea580c;
    --accent-primary-rgb: 234, 88, 12;
    --accent-secondary: #dc2626;
    --accent-secondary-rgb: 220, 38, 38;
    --accent-gradient: linear-gradient(135deg, #ea580c, #dc2626);
    --border-color: #fed7aa;
    --border-color-rgb: 254, 215, 170;
    --shadow-color: rgba(249, 115, 22, 0.08);
    --shadow-lg: 0 10px 25px -5px rgba(249, 115, 22, 0.1), 0 10px 10px -5px rgba(249, 115, 22, 0.04);
    --success-color: #059669;
    --warning-color: #d97706;
    --danger-color: #dc2626;
    --info-color: #0284c7;
}

/* Sunset Theme - Dark Mode */
[data-theme="sunset-dark"] {
    --bg-primary: #1a0f0a;
    --bg-secondary: #431407;
    --bg-tertiary: #9a3412;
    --bg-tertiary-rgb: 154, 52, 18;
    --text-primary: #fed7aa;
    --text-secondary: #fdba74;
    --accent-primary: #fb923c;
    --accent-primary-rgb: 251, 146, 60;
    --accent-secondary: #f97316;
    --accent-secondary-rgb: 249, 115, 22;
    --accent-gradient: linear-gradient(135deg, #fb923c, #f97316);
    --border-color: #9a3412;
    --border-color-rgb: 154, 52, 18;
    --shadow-color: rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.3);
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #0ea5e9;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
}

body {
    font-family: 'Inter', 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s var(--transition-ease), color 0.3s var(--transition-ease);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
}

h1 {
    font-size: 2rem;
    letter-spacing: -0.025em;
}

h2 {
    font-size: 1.5rem;
    letter-spacing: -0.025em;
}

h3 {
    font-size: 1.25rem;
}

p {
    margin-bottom: 1rem;
}

a {
    color: var(--accent-primary);
    text-decoration: none;
    transition: color 0.2s var(--transition-ease), transform 0.2s var(--transition-ease);
    position: relative;
}

a:hover {
    color: var(--accent-secondary);
}

a.underline-link:after {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    bottom: -2px;
    left: 0;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s var(--transition-ease);
}

a.underline-link:hover:after {
    transform: scaleX(1);
    transform-origin: left;
}

button, .btn {
    cursor: pointer;
    border: none;
    border-radius: var(--btn-radius);
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s var(--transition-ease);
    position: relative;
    overflow: hidden;
}

button:hover, .btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 7px 14px rgba(50, 50, 93, 0.1), 0 3px 6px rgba(0, 0, 0, 0.08);
}

button:active, .btn:active {
    transform: translateY(1px);
}

.btn-primary {
    background: var(--accent-gradient);
    color: white;
}

.btn-primary:hover {
    background-size: 150%;
    box-shadow: 0 0 20px rgba(79, 70, 229, 0.4);
}

.btn-secondary {
    background-color: var(--bg-tertiary);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background-color: var(--border-color);
}

.btn-icon {
    background: transparent;
    border: none;
    font-size: 1.2rem;
    color: var(--text-secondary);
    padding: 8px;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s var(--transition-ease);
}

.btn-icon:hover {
    color: var(--text-primary);
    background-color: var(--bg-tertiary);
    transform: translateY(0);
}

.btn-with-icon {
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-with-icon i, 
.btn-with-icon svg,
.btn-with-icon span:first-child {
    margin-right: 8px;
}

input, select, textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--input-radius);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.2s var(--transition-ease);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

[data-theme="dark"] input,
[data-theme="dark"] select,
[data-theme="dark"] textarea {
    background-color: var(--bg-secondary);
    border-color: var(--border-color);
}

/* Cards */
.card {
    background-color: var(--bg-primary);
    border-radius: var(--card-radius);
    box-shadow: var(--shadow-lg);
    padding: 24px;
    transition: transform 0.2s var(--transition-ease), box-shadow 0.2s var(--transition-ease);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Utility Classes */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-gradient {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-4 { gap: 1rem; }
.gap-8 { gap: 2rem; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.p-4 { padding: 1rem; }
.p-8 { padding: 2rem; }

.w-full { width: 100%; }
.h-full { height: 100%; }

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.animate-fade-in {
    animation: fadeIn 0.3s ease-out forwards;
}

.animate-slide-up {
    animation: slideUp 0.4s var(--transition-ease) forwards;
}

/* Theme Toggle Button */
.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
}

#theme-toggle-btn {
    background-color: var(--bg-tertiary);
    border-radius: 50%;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    padding: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s var(--transition-ease);
}

#theme-toggle-btn:hover {
    transform: rotate(30deg);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .dark-icon {
    display: none;
}

[data-theme="dark"] .light-icon {
    display: none;
} 