/* Nina HR Bot - Modern Minimalist Design System */

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

:root {
    /* Color Palette - Dark Mode by Default */
    --bg-primary: #0f0f14;
    --bg-dark: #0f0f14;
    --bg-secondary: #16161d;
    --bg-card: #1c1c26;
    --bg-elevated: #242430;

    /* Accent Colors */
    --primary: #6366f1;
    --primary-rgb: 99, 102, 241;
    --secondary: #8b5cf6;
    --secondary-rgb: 139, 92, 246;

    --accent-primary: var(--primary);
    --accent-primary-hover: #818cf8;
    --accent-secondary: var(--secondary);
    --accent-success: #10b981;
    --accent-warning: #f59e0b;
    --accent-danger: #ef4444;
    --accent-info: #3b82f6;

    /* Text Colors */
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;

    /* Border & Shadow */
    --border-color: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 40px rgba(99, 102, 241, 0.15);

    /* Spacing */
    --space-xs: 2px;
    --space-sm: 6px;
    --space-md: 12px;
    --space-lg: 16px;
    --space-xl: 24px;
    --space-2xl: 32px;

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* Light Mode */
[data-theme="light"] {
    --bg-primary: #fafafa;
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --bg-elevated: #f4f4f5;
    --text-primary: #18181b;
    --text-secondary: #52525b;
    --text-muted: #a1a1aa;
    --border-color: rgba(0, 0, 0, 0.08);
    --border-hover: rgba(0, 0, 0, 0.15);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.15);
}

/* Global Reset */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 600;
    line-height: 1.3;
    color: var(--text-primary);
}

h1 {
    font-size: 2.25rem;
}

h2 {
    font-size: 1.875rem;
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.25rem;
}

h5 {
    font-size: 1.125rem;
}

h6 {
    font-size: 1rem;
}

p {
    color: var(--text-secondary);
}

a {
    color: var(--accent-primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--accent-primary-hover);
}

/* Layout Container */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 240px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 16px;
    left: 16px;
    bottom: 16px;
    z-index: 100;
    transition: transform var(--transition-base);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    height: calc(100vh - 32px);
}

.sidebar-logo {
    display: none;
}

.sidebar-nav {
    flex: 1;
    padding: var(--space-md);
    overflow-y: auto;
}

.nav-section {
    margin-bottom: var(--space-lg);
}

.nav-section-title {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    padding: var(--space-sm) var(--space-md);
    margin-bottom: var(--space-xs);
}

.nav-item {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-weight: 500;
    transition: all var(--transition-fast);
    cursor: pointer;
    margin-bottom: var(--space-xs);
}

.nav-item:hover {
    background: var(--bg-elevated);
    color: var(--text-primary);
}

.nav-item.active {
    background: rgba(99, 102, 241, 0.15);
    color: var(--accent-primary);
}

.nav-item i {
    width: 20px;
    text-align: center;
    font-size: 1.125rem;
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 272px;
    /* 240px + 16px + 16px gap */
    padding: var(--space-lg);
    min-height: 100vh;
}

/* Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-xl);
}

.page-title {
    font-size: 1.875rem;
    font-weight: 700;
}

.page-subtitle {
    color: var(--text-secondary);
    margin-top: var(--space-xs);
}

/* Cards */
.card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: all var(--transition-base);
}

.card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-md);
}

.card-header {
    padding: var(--space-lg);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-title {
    font-size: 1.125rem;
    font-weight: 600;
}

.card-body {
    padding: var(--space-lg);
}

.card-footer {
    padding: var(--space-lg);
    border-top: 1px solid var(--border-color);
    background: var(--bg-elevated);
}

/* Stats Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: var(--space-lg);
    margin-bottom: var(--space-xl);
}

.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    margin-bottom: var(--space-md);
}

.stat-icon.primary {
    background: rgba(99, 102, 241, 0.15);
    color: var(--accent-primary);
}

.stat-icon.success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent-success);
}

.stat-icon.warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--accent-warning);
}

.stat-icon.danger {
    background: rgba(239, 68, 68, 0.15);
    color: var(--accent-danger);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-xs);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.stat-change {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    font-size: 0.75rem;
    margin-top: var(--space-sm);
    padding: var(--space-xs) var(--space-sm);
    border-radius: var(--radius-full);
}

.stat-change.positive {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent-success);
}

.stat-change.negative {
    background: rgba(239, 68, 68, 0.15);
    color: var(--accent-danger);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-lg);
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    text-decoration: none;
}

.btn-primary {
    background: var(--accent-primary);
    color: white;
    box-shadow: none;
}

.btn-primary:hover {
    transform: translateY(-1px);
    background: var(--accent-primary-hover);
    color: white !important;
    box-shadow: 0 4px 12px rgba(var(--primary-rgb), 0.25);
}

.btn-primary:hover i,
.btn-primary:hover span,
.btn-primary:hover a {
    color: white !important;
}

.btn-secondary {
    background: var(--bg-elevated);
    color: var(--accent-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-card);
    border-color: var(--border-hover);
    color: var(--accent-primary) !important;
}

.btn-ghost {
    background: transparent;
    color: var(--accent-primary);
    border: 1px solid var(--border-color);
}

.btn-ghost:hover {
    background: var(--bg-elevated);
    color: var(--text-primary) !important;
}

.btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: var(--radius-md);
}

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

.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: var(--space-sm);
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: var(--space-md);
    font-size: 0.875rem;
    color: var(--text-primary);
    background: var(--bg-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
    outline: none;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.form-input::placeholder {
    color: var(--text-muted);
}

/* ==================== */
/* SETUP WIZARD STYLES */
/* ==================== */

.wizard-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--bg-primary) 0%, #1a1a2e 100%);
    padding: var(--space-xl);
}

.wizard-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-color);
    width: 100%;
    max-width: 640px;
    box-shadow: var(--shadow-lg), var(--shadow-glow);
    overflow: hidden;
}

.wizard-header {
    padding: var(--space-2xl);
    text-align: center;
    border-bottom: 1px solid var(--border-color);
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.05) 100%);
}

.wizard-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--space-lg);
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: white;
    box-shadow: 0 10px 40px rgba(99, 102, 241, 0.3);
}

.wizard-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: var(--space-sm);
}

.wizard-subtitle {
    color: var(--text-muted);
    font-size: 0.9375rem;
}

/* Progress Steps */
.wizard-progress {
    display: flex;
    justify-content: center;
    gap: var(--space-md);
    padding: var(--space-lg);
    background: var(--bg-elevated);
}

.progress-step {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.progress-step.active {
    color: var(--accent-primary);
}

.progress-step.completed {
    color: var(--accent-success);
}

.step-dot {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.75rem;
    transition: all var(--transition-base);
}

.progress-step.active .step-dot {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.4);
}

.progress-step.completed .step-dot {
    background: var(--accent-success);
    border-color: var(--accent-success);
    color: white;
}

.progress-line {
    width: 40px;
    height: 2px;
    background: var(--border-color);
}

.progress-line.completed {
    background: var(--accent-success);
}

/* Wizard Body */
.wizard-body {
    padding: var(--space-2xl);
}

.wizard-step {
    display: none;
    animation: fadeSlideIn 0.4s ease;
}

.wizard-step.active {
    display: block;
}

@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.wizard-step-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--space-sm);
}

.wizard-step-description {
    color: var(--text-muted);
    margin-bottom: var(--space-xl);
    font-size: 0.9375rem;
}

/* Wizard Footer */
.wizard-footer {
    padding: var(--space-lg) var(--space-2xl);
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    background: var(--bg-elevated);
}

/* Feature Cards for Wizard */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-md);
    margin-top: var(--space-lg);
}

.feature-item {
    padding: var(--space-lg);
    background: var(--bg-elevated);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    text-align: center;
    transition: all var(--transition-fast);
    cursor: pointer;
}

.feature-item:hover {
    border-color: var(--accent-primary);
    transform: translateY(-2px);
}

.feature-item.selected {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.1);
}

.feature-icon {
    font-size: 2rem;
    margin-bottom: var(--space-md);
}

.feature-title {
    font-weight: 600;
    margin-bottom: var(--space-xs);
}

.feature-desc {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* Success State */
.wizard-success {
    text-align: center;
    padding: var(--space-xl);
}

.success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--space-lg);
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--accent-success);
    animation: scaleIn 0.5s ease;
}

@keyframes scaleIn {
    0% {
        transform: scale(0);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

/* Tables */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: var(--space-md);
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.data-table th {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    background: var(--bg-elevated);
}

.data-table tbody tr {
    transition: background var(--transition-fast);
}

.data-table tbody tr:hover {
    background: var(--bg-elevated);
}

/* Status Badges */
.badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-xs) var(--space-sm);
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: var(--radius-full);
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--accent-success);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--accent-warning);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.15);
    color: var(--accent-danger);
}

.badge-info {
    background: rgba(59, 130, 246, 0.15);
    color: var(--accent-info);
}

.badge-default {
    background: var(--bg-elevated);
    color: var(--text-secondary);
}

.badge-outline {
    background: transparent !important;
    border: 1px solid currentColor;
}

/* Avatar */
.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
}

.avatar-sm {
    width: 32px;
    height: 32px;
    font-size: 0.75rem;
}

.avatar-lg {
    width: 56px;
    height: 56px;
    font-size: 1.125rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: var(--space-2xl);
    color: var(--text-muted);
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: var(--space-lg);
    opacity: 0.5;
}

/* Responsive */
@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }
}

@media (max-width: 640px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }

    .wizard-card {
        margin: var(--space-md);
    }

    .wizard-header,
    .wizard-body,
    .wizard-footer {
        padding: var(--space-lg);
    }
}