/* ============================================
   KORTZEN MINIMALIST DESIGN SYSTEM
   Ultra-Clean Sobrio y Elegante
   ============================================ */

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

:root {
    /* Sophisticated Colors */
    --primary-gold: #C9A96E;
    --gold-dark: #B89A5F;
    --gold-light: #D4B77D;

    /* Dark Theme */
    --bg-dark: #1A1A1A;
    --bg-darker: #0F0F0F;
    --bg-sidebar: #111111;
    --bg-main: #1E1E1E;

    /* Blue Accent for Sidebar */
    --blue-gradient-start: rgba(0, 102, 204, 0.15);
    --blue-gradient-end: rgba(0, 51, 102, 0.05);

    /* Text */
    --text-primary: #FFFFFF;
    --text-secondary: #A0A0A0;
    --text-muted: #707070;

    /* Inputs */
    --input-bg: #F5F5F5;
    --input-text: #2A2A2A;
    --input-border: #E0E0E0;

    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;

    /* Typography */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   LOGIN PAGE
   ============================================ */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1A1A1A 0%, #0F0F0F 100%);
    padding: 20px;
}

.login-box {
    width: 100%;
    max-width: 450px;
    text-align: center;
}

.login-logo {
    font-family: var(--font-heading);
    font-size: 48px;
    font-weight: 400;
    letter-spacing: 8px;
    color: var(--primary-gold);
    margin-bottom: 12px;
}

.login-subtitle {
    font-size: 14px;
    font-weight: 400;
    letter-spacing: 2px;
    color: var(--text-secondary);
    margin-bottom: 50px;
    text-transform: uppercase;
}

.login-form {
    width: 100%;
}

.form-group {
    margin-bottom: 24px;
    text-align: left;
}

.form-label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 1px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    text-transform: uppercase;
}

.form-input {
    width: 100%;
    padding: 16px 20px;
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: 4px;
    font-size: 15px;
    color: var(--input-text);
    font-family: var(--font-body);
    transition: all 0.3s ease;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-gold);
    box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.1);
}

.btn-login {
    width: 100%;
    padding: 18px;
    background: var(--primary-gold);
    border: none;
    border-radius: 4px;
    color: #1A1A1A;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 32px;
    font-family: var(--font-body);
}

.btn-login:hover {
    background: var(--gold-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(201, 169, 110, 0.3);
}

.back-link {
    display: inline-block;
    margin-top: 28px;
    font-size: 14px;
    color: var(--primary-gold);
    text-decoration: none;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: var(--gold-light);
}

/* ============================================
   DASHBOARD LAYOUT WITH SIDEBAR
   ============================================ */
.dashboard-container {
    display: flex;
    min-height: 100vh;
    background: var(--bg-main);
}

/* Sidebar */
.sidebar {
    width: 260px;
    background: linear-gradient(180deg,
            var(--bg-sidebar) 0%,
            var(--bg-darker) 100%);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 1000;
}

/* Removed blue gradient overlay - now solid dark sidebar
.sidebar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
            var(--blue-gradient-start) 0%,
            var(--blue-gradient-end) 50%,
            transparent 100%);
    pointer-events: none;
}
*/

.sidebar-logo {
    padding: 32px 24px;
    font-family: var(--font-heading);
    font-size: 24px;
    font-weight: 500;
    letter-spacing: 6px;
    color: var(--text-primary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    z-index: 2;
}

.sidebar-nav {
    flex: 1;
    padding: 16px 0;
    overflow-y: auto;
    position: relative;
    z-index: 2;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 24px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    transition: all 0.3s ease;
    position: relative;
}

.nav-item::before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--primary-gold);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav-item:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
}

.nav-item.active {
    color: var(--primary-gold);
    background: rgba(201, 169, 110, 0.08);
}

.nav-item.active::before {
    opacity: 1;
}

.nav-icon {
    width: 20px;
    height: 20px;
    stroke-width: 1.5px;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    z-index: 2;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
    color: #1A1A1A;
}

.user-info {
    flex: 1;
}

.user-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.user-role {
    font-size: 12px;
    color: var(--text-muted);
}

.btn-logout {
    width: 100%;
    padding: 12px;
    background: transparent;
    border: 1px solid var(--primary-gold);
    border-radius: 4px;
    color: var(--primary-gold);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-body);
}

.btn-logout:hover {
    background: var(--primary-gold);
    color: #1A1A1A;
}

/* Main Content Area */
.main-content {
    margin-left: 260px;
    flex: 1;
    padding: 40px;
    min-height: 100vh;
}

.page-header {
    margin-bottom: 32px;
}

.page-title {
    font-family: var(--font-heading);
    font-size: 32px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.page-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Cards */
.card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 24px;
}

.card-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 24px;
    transition: all 0.3s ease;
}

.stat-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(201, 169, 110, 0.2);
    transform: translateY(-2px);
}

.stat-value {
    font-size: 36px;
    font-weight: 700;
    color: var(--primary-gold);
    margin-bottom: 8px;
}

.stat-label {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Tables */
.table-container {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    overflow: hidden;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table thead {
    background: rgba(0, 0, 0, 0.3);
}

.table th {
    padding: 14px 20px;
    text-align: left;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.table td {
    padding: 16px 20px;
    font-size: 14px;
    color: var(--text-secondary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.table tbody tr {
    transition: background 0.2s ease;
}

.table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

.table tbody tr:last-child td {
    border-bottom: none;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-body);
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: var(--primary-gold);
    color: #1A1A1A;
}

.btn-primary:hover {
    background: var(--gold-dark);
    transform: translateY(-1px);
}

.btn-secondary {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.btn-sm {
    padding: 6px 14px;
    font-size: 12px;
}

/* Alerts */
.alert {
    padding: 14px 18px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
}

.alert-success {
    background: rgba(46, 204, 113, 0.1);
    border: 1px solid rgba(46, 204, 113, 0.3);
    color: #2ECC71;
}

.alert-danger {
    background: rgba(231, 76, 60, 0.1);
    border: 1px solid rgba(231, 76, 60, 0.3);
    color: #E74C3C;
}

/* Responsive */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

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

    .main-content {
        margin-left: 0;
        padding: 20px;
    }

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