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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #f3f4f6;
    color: #1f2937;
    min-height: 100vh;
}

/* Login */
.login-page {
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #059669 0%, #047857 50%, #065f46 100%);
    min-height: 100vh;
}
.login-container { width: 100%; max-width: 420px; padding: 20px; }
.login-box {
    background: #fff; border-radius: 20px; padding: 40px 32px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
}
.login-box h1 { text-align: center; color: #059669; font-size: 28px; font-weight: 800; margin-bottom: 4px; }
.login-box .subtitle { text-align: center; color: #6b7280; margin-bottom: 28px; font-size: 14px; }

/* Navbar */
.navbar {
    background: #fff; padding: 0 24px; display: flex;
    align-items: center; justify-content: space-between;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    position: sticky; top: 0; z-index: 100;
    height: 64px;
}
.brand { font-size: 20px; font-weight: 800; color: #059669; text-decoration: none; letter-spacing: -0.5px; }
.nav-center { display: flex; gap: 2px; }
.nav-link {
    padding: 20px 16px; color: #6b7280; text-decoration: none;
    font-size: 14px; font-weight: 500; transition: all 0.2s;
    border-bottom: 2px solid transparent;
}
.nav-link:hover { color: #059669; background: #f0fdf4; border-bottom-color: #059669; }
.nav-right { display: flex; align-items: center; gap: 16px; }
.user-info { font-size: 13px; color: #6b7280; font-weight: 500; }

/* Container */
.container { max-width: 1200px; margin: 0 auto; padding: 24px 20px; }
.container h2 { font-size: 24px; font-weight: 700; color: #111827; margin-bottom: 20px; }

/* Cards */
.card {
    background: #fff; border-radius: 16px; box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    margin-bottom: 20px; overflow: hidden; border: 1px solid #e5e7eb;
}
.card-header { padding: 16px 20px; border-bottom: 1px solid #f3f4f6; }
.card-header h3 { font-size: 15px; font-weight: 600; color: #111827; }
.card-body { padding: 20px; }

/* Stats Grid */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 28px; }
.stat-card {
    background: #fff; border-radius: 16px; padding: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    text-align: center;
    border: 1px solid #e5e7eb;
    position: relative; overflow: hidden;
}
.stat-card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0;
    height: 4px;
}
.stat-card.blue::before { background: #3b82f6; }
.stat-card.green::before { background: #10b981; }
.stat-card.orange::before { background: #f59e0b; }
.stat-card.red::before { background: #ef4444; }
.stat-card.purple::before { background: #8b5cf6; }
.stat-number { display: block; font-size: 28px; font-weight: 800; color: #111827; }
.stat-label { display: block; font-size: 13px; color: #6b7280; margin-top: 4px; font-weight: 500; }

/* Forms */
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; color: #374151; margin-bottom: 6px; }
.form-control, .form-group input, .form-group select, .form-group textarea {
    width: 100%; padding: 10px 14px; border: 1px solid #d1d5db;
    border-radius: 10px; font-size: 14px; transition: all 0.2s;
    background: #fff;
}
.form-control:focus, .form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none; border-color: #10b981; box-shadow: 0 0 0 3px rgba(16,185,129,0.15);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* Buttons */
.btn {
    padding: 10px 20px; border: none; border-radius: 10px;
    font-size: 14px; font-weight: 600; cursor: pointer;
    text-decoration: none; display: inline-flex; align-items: center; gap: 6px;
    transition: all 0.2s;
}
.btn-primary { background: #059669; color: #fff; }
.btn-primary:hover { background: #047857; }
.btn-success { background: #10b981; color: #fff; }
.btn-success:hover { background: #059669; }
.btn-danger { background: #ef4444; color: #fff; }
.btn-danger:hover { background: #dc2626; }
.btn-warning { background: #f59e0b; color: #fff; }
.btn-warning:hover { background: #d97706; }
.btn-info { background: #3b82f6; color: #fff; }
.btn-info:hover { background: #2563eb; }
.btn-sm { padding: 6px 12px; font-size: 12px; border-radius: 8px; }
.btn-block { width: 100%; justify-content: center; }
.btn-outline { background: transparent; border: 1px solid #d1d5db; color: #374151; }
.btn-outline:hover { background: #f9fafb; }

/* Table */
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid #f3f4f6; font-size: 14px; }
.table th { background: #f9fafb; font-weight: 600; color: #6b7280; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; }
.table tr:hover { background: #f9fafb; }

/* Badges */
.badge {
    display: inline-flex; padding: 4px 10px; border-radius: 20px;
    font-size: 11px; font-weight: 600; align-items: center; gap: 4px;
}
.badge-activo { background: #d1fae5; color: #065f46; }
.badge-pagado { background: #dbeafe; color: #1e40af; }
.badge-atrasado { background: #fee2e2; color: #991b1b; }
.badge-cancelado { background: #f3f4f6; color: #4b5563; }

/* Alerts */
.alert { padding: 14px 18px; border-radius: 12px; margin-bottom: 16px; font-size: 14px; font-weight: 500; }
.alert-success { background: #d1fae5; color: #065f46; border: 1px solid #a7f3d0; }
.alert-danger { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }
.alert-info { background: #dbeafe; color: #1e40af; border: 1px solid #bfdbfe; }

/* Actions */
.header-actions { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; gap: 12px; }
.search-box { display: flex; gap: 10px; margin-bottom: 16px; }
.search-box input { flex: 1; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }

/* Ticket */
.ticket-card {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    max-width: 380px;
    margin: 0 auto;
    border: 2px dashed #10b981;
    font-size: 13px;
}
.ticket-header { text-align: center; border-bottom: 2px dashed #e5e7eb; padding-bottom: 16px; margin-bottom: 16px; }
.ticket-header h3 { font-size: 18px; color: #059669; font-weight: 800; }
.ticket-header p { color: #6b7280; font-size: 12px; }
.ticket-row { display: flex; justify-content: space-between; padding: 6px 0; }
.ticket-label { color: #6b7280; font-weight: 500; }
.ticket-value { font-weight: 700; color: #111827; }
.ticket-total { border-top: 2px solid #e5e7eb; margin-top: 12px; padding-top: 12px; font-size: 16px; }
.ticket-total .ticket-value { color: #059669; font-size: 20px; }
.ticket-footer { text-align: center; margin-top: 16px; padding-top: 16px; border-top: 2px dashed #e5e7eb; color: #9ca3af; font-size: 11px; }

@media (max-width: 768px) {
    .navbar { flex-direction: column; height: auto; padding: 12px; gap: 8px; }
    .nav-center { flex-wrap: wrap; justify-content: center; }
    .nav-link { padding: 10px 12px; }
    .form-row { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
}
