/* ============================================
   ORIUS - Ana Stil Dosyası
   ============================================ */

/* ============================================
   CSS Değişkenleri
   ============================================ */
:root {
    --primary-50: #eff6ff;
    --primary-100: #dbeafe;
    --primary-200: #bfdbfe;
    --primary-300: #93c5fd;
    --primary-400: #60a5fa;
    --primary-500: #3b82f6;
    --primary-600: #2563eb;
    --primary-700: #1d4ed8;
    --primary-800: #1e40af;
    --primary-900: #1e3a8a;
    
    --surface-50: #f8fafc;
    --surface-100: #f1f5f9;
    --surface-200: #e2e8f0;
    --surface-300: #cbd5e1;
    --surface-400: #94a3b8;
    --surface-500: #64748b;
    --surface-600: #475569;
    --surface-700: #334155;
    --surface-800: #1e293b;
    --surface-900: #0f172a;
    --surface-950: #020617;
}

/* ============================================
   Alpine.js Cloak
   ============================================ */
[x-cloak] { 
    display: none !important; 
}

/* ============================================
   Scrollbar
   ============================================ */
::-webkit-scrollbar { 
    width: 6px; 
    height: 6px; 
}
::-webkit-scrollbar-track { 
    background: transparent; 
}
::-webkit-scrollbar-thumb { 
    background: #cbd5e1; 
    border-radius: 3px; 
}
.dark ::-webkit-scrollbar-thumb { 
    background: #475569; 
}
::-webkit-scrollbar-thumb:hover { 
    background: #94a3b8; 
}

/* ============================================
   Dark Mode
   ============================================ */
html.dark { 
    color-scheme: dark; 
}

/* ============================================
   Glass Effect
   ============================================ */
.glass {
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

/* ============================================
   Navigation
   ============================================ */
.nav-item { 
    position: relative;
    letter-spacing: 0.05em;
}
.nav-item::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: #3b82f6;
    transform: scaleX(0);
    transition: transform 0.2s ease;
}
.nav-item:hover::after,
.nav-item.active::after { 
    transform: scaleX(1); 
}
.nav-item.active { 
    color: #3b82f6; 
}
.dark .nav-item.active { 
    color: #60a5fa; 
}

/* ============================================
   Cards
   ============================================ */
.card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    transition: all 0.2s ease;
}
.dark .card {
    background: #1e293b;
    border-color: #334155;
}
.card:hover {
    border-color: #cbd5e1;
}
.dark .card:hover {
    border-color: #475569;
}

/* Card Variants */
.card-primary {
    background: #3b82f6;
    border-color: #3b82f6;
}

.card-warning {
    background: #fef3c7;
    border-color: #fcd34d;
}
.dark .card-warning {
    background: rgba(245, 158, 11, 0.2);
    border-color: rgba(245, 158, 11, 0.3);
}

/* ============================================
   Buttons
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 600;
    padding: 0.875rem 1.75rem;
    border-radius: 10px;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    text-decoration: none;
}

.btn-sm {
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
}

.btn-primary {
    background: #3b82f6;
    color: white;
}
.btn-primary:hover {
    background: #2563eb;
}

.btn-secondary {
    background: #f1f5f9;
    color: #334155;
    border: 1px solid #e2e8f0;
}
.dark .btn-secondary {
    background: #334155;
    color: #e2e8f0;
    border-color: #475569;
}
.btn-secondary:hover {
    background: #e2e8f0;
}
.dark .btn-secondary:hover {
    background: #475569;
}

.btn-danger {
    background: #ef4444;
    color: white;
}
.btn-danger:hover {
    background: #dc2626;
}

.btn-success {
    background: #10b981;
    color: white;
}
.btn-success:hover {
    background: #059669;
}

.btn-warning {
    background: #f59e0b;
    color: white;
}
.btn-warning:hover {
    background: #d97706;
}

.btn-info {
    background: #0ea5e9;
    color: white;
}
.btn-info:hover {
    background: #0284c7;
}

.btn-outline {
    background: transparent;
    border: 1px solid #e2e8f0;
    color: #475569;
}
.dark .btn-outline {
    border-color: #475569;
    color: #94a3b8;
}
.btn-outline:hover {
    background: #f1f5f9;
}
.dark .btn-outline:hover {
    background: #334155;
}

/* ============================================
   Form Elements
   ============================================ */
.form-label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: #334155;
}
.dark .form-label {
    color: #e2e8f0;
}

.form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: white;
    color: #0f172a;
    font-size: 1rem;
    transition: all 0.2s ease;
}
.dark .form-input {
    background: #1e293b;
    border-color: #475569;
    color: #f1f5f9;
}
.form-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}
.dark .form-input:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}
.form-input::placeholder {
    color: #94a3b8;
}
.dark .form-input::placeholder {
    color: #64748b;
}

.form-input-error {
    border-color: #ef4444;
}
.form-input-error:focus {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 0.75rem center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
}

.form-checkbox {
    width: 1.25rem;
    height: 1.25rem;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    background: white;
    cursor: pointer;
    transition: all 0.2s ease;
}
.dark .form-checkbox {
    background: #1e293b;
    border-color: #475569;
}
.form-checkbox:checked {
    background: #3b82f6;
    border-color: #3b82f6;
}

.form-error {
    color: #ef4444;
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

/* ============================================
   Badges
   ============================================ */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 8px;
}

.badge-success {
    background: #d1fae5;
    color: #065f46;
}
.dark .badge-success {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}
.dark .badge-warning {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
}

.badge-danger {
    background: #fee2e2;
    color: #991b1b;
}
.dark .badge-danger {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.badge-info {
    background: #dbeafe;
    color: #1e40af;
}
.dark .badge-info {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.badge-neutral {
    background: #f1f5f9;
    color: #475569;
}
.dark .badge-neutral {
    background: #334155;
    color: #94a3b8;
}

/* ============================================
   Tables
   ============================================ */
.table {
    width: 100%;
    border-collapse: collapse;
}
.table th {
    padding: 1rem 1.5rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
    border-bottom: 1px solid #e2e8f0;
}
.dark .table th {
    color: #94a3b8;
    border-color: #334155;
}
.table td {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid #f1f5f9;
}
.dark .table td {
    border-color: #1e293b;
}
.table tbody tr:hover {
    background: #f8fafc;
}
.dark .table tbody tr:hover {
    background: rgba(30, 41, 59, 0.5);
}
.table tbody tr:last-child td {
    border-bottom: none;
}

/* ============================================
   Alerts
   ============================================ */
.alert {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    border-radius: 12px;
    border: 1px solid;
}

.alert-success {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #065f46;
}
.dark .alert-success {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
    color: #34d399;
}

.alert-warning {
    background: #fffbeb;
    border-color: #fcd34d;
    color: #92400e;
}
.dark .alert-warning {
    background: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.3);
    color: #fbbf24;
}

.alert-danger {
    background: #fef2f2;
    border-color: #fecaca;
    color: #991b1b;
}
.dark .alert-danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #f87171;
}

.alert-info {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #1e40af;
}
.dark .alert-info {
    background: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.3);
    color: #60a5fa;
}

/* ============================================
   Tabs
   ============================================ */
.tabs {
    display: flex;
    gap: 0.5rem;
    border-bottom: 1px solid #e2e8f0;
}
.dark .tabs {
    border-color: #334155;
}
.tab {
    padding: 1rem 1.5rem;
    font-weight: 500;
    color: #64748b;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: all 0.2s ease;
    cursor: pointer;
}
.tab:hover {
    color: #334155;
}
.dark .tab:hover {
    color: #e2e8f0;
}
.tab.active {
    color: #3b82f6;
    border-color: #3b82f6;
}
.dark .tab.active {
    color: #60a5fa;
    border-color: #60a5fa;
}

/* ============================================
   Empty State
   ============================================ */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}
.empty-state-icon {
    width: 5rem;
    height: 5rem;
    margin: 0 auto 1.5rem;
    background: #f1f5f9;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.dark .empty-state-icon {
    background: #334155;
}
.empty-state-icon svg {
    width: 2.5rem;
    height: 2.5rem;
    color: #94a3b8;
}
.empty-state-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 0.5rem;
}
.dark .empty-state-title {
    color: #f1f5f9;
}
.empty-state-text {
    color: #64748b;
    margin-bottom: 1.5rem;
}

/* ============================================
   Divider
   ============================================ */
.divider {
    height: 1px;
    background: #e2e8f0;
    margin: 1.5rem 0;
}
.dark .divider {
    background: #334155;
}

/* ============================================
   Section Header
   ============================================ */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
}
.dark .section-header {
    border-color: #334155;
}
.section-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: #0f172a;
}
.dark .section-title {
    color: #f1f5f9;
}
.section-subtitle {
    font-size: 0.875rem;
    color: #64748b;
    margin-top: 0.25rem;
}

/* ============================================
   Icon Box
   ============================================ */
.icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}
.icon-box-sm {
    width: 2.5rem;
    height: 2.5rem;
}
.icon-box-md {
    width: 3rem;
    height: 3rem;
}
.icon-box-lg {
    width: 4rem;
    height: 4rem;
}
.icon-box-primary {
    background: #3b82f6;
    color: white;
}
.icon-box-success {
    background: #10b981;
    color: white;
}
.icon-box-warning {
    background: #f59e0b;
    color: white;
}
.icon-box-danger {
    background: #ef4444;
    color: white;
}
.icon-box-neutral {
    background: #64748b;
    color: white;
}

/* ============================================
   Stat Card
   ============================================ */
.stat-card {
    text-align: center;
}
.stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1;
}
.stat-label {
    font-size: 0.875rem;
    color: #64748b;
    margin-top: 0.5rem;
}

/* ============================================
   List Items
   ============================================ */
.list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    transition: background 0.2s ease;
}
.list-item:hover {
    background: #f8fafc;
}
.dark .list-item:hover {
    background: rgba(30, 41, 59, 0.5);
}
.list-item + .list-item {
    border-top: 1px solid #f1f5f9;
}
.dark .list-item + .list-item {
    border-color: #1e293b;
}

/* ============================================
   Avatar
   ============================================ */
.avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #3b82f6;
    color: white;
    font-weight: 600;
    border-radius: 12px;
}
.avatar-sm {
    width: 2rem;
    height: 2rem;
    font-size: 0.75rem;
}
.avatar-md {
    width: 2.5rem;
    height: 2.5rem;
    font-size: 0.875rem;
}
.avatar-lg {
    width: 3rem;
    height: 3rem;
    font-size: 1rem;
}
.avatar-xl {
    width: 5rem;
    height: 5rem;
    font-size: 2rem;
    border-radius: 1rem;
}

/* ============================================
   Modal
   ============================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    z-index: 100;
}
.modal {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 32rem;
    max-height: 90vh;
    overflow: auto;
}
.dark .modal {
    background: #1e293b;
}
.modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
}
.dark .modal-header {
    border-color: #334155;
}
.modal-body {
    padding: 1.5rem;
}
.modal-footer {
    padding: 1.5rem;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}
.dark .modal-footer {
    border-color: #334155;
}

/* ============================================
   Dropdown
   ============================================ */
.dropdown {
    position: relative;
}
.dropdown-menu {
    position: absolute;
    right: 0;
    margin-top: 0.5rem;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.2);
    padding: 0.5rem;
    min-width: 12rem;
    z-index: 50;
}
.dark .dropdown-menu {
    background: #1e293b;
    border-color: #334155;
}
.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    color: #334155;
    transition: background 0.2s ease;
    cursor: pointer;
}
.dark .dropdown-item {
    color: #e2e8f0;
}
.dropdown-item:hover {
    background: #f1f5f9;
}
.dark .dropdown-item:hover {
    background: #334155;
}
.dropdown-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 0.5rem 0;
}
.dark .dropdown-divider {
    background: #334155;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
    .btn {
        padding: 0.75rem 1.25rem;
    }
    .card {
        border-radius: 12px;
    }
    .stat-value {
        font-size: 2rem;
    }
}

