/**
 * User Panel - Ortak Stil Dosyası
 * Tüm kullanıcı paneli sayfalarında kullanılır — Yeniden tasarım
 */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap');

:root {
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-muted: rgba(37, 99, 235, 0.12);
    --sidebar-width: 280px;
    --sidebar-bg: #0c1222;
    --sidebar-surface: rgba(255, 255, 255, 0.04);
    --sidebar-border: rgba(255, 255, 255, 0.06);
    --sidebar-text: rgba(255, 255, 255, 0.88);
    --sidebar-text-muted: rgba(255, 255, 255, 0.55);
    --sidebar-accent: #3b82f6;
    --sidebar-accent-hover: #60a5fa;
    --sidebar-active-bg: rgba(59, 130, 246, 0.18);
    --sidebar-active-border: #3b82f6;
    --sidebar-logout-bg: rgba(239, 68, 68, 0.15);
    --sidebar-logout-hover: #ef4444;
    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --bg-page: #f1f5f9;
    --bg-card: #ffffff;
    --border: #e2e8f0;
    --radius: 16px;
    --radius-sm: 12px;
    --shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 4px 20px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.1);
    --success-bg: #ecfdf5;
    --success-text: #065f46;
    --success-border: #a7f3d0;
    --error-bg: #fef2f2;
    --error-text: #991b1b;
    --error-border: #fecaca;
    --warning-bg: #fffbeb;
    --warning-border: #fde68a;
    --auth-box-shadow: 0 24px 48px rgba(15, 23, 42, 0.12);
}

/* Eski değişkenler uyumluluk */
:root {
    --primary-blue: var(--primary-hover);
    --primary-blue-light: var(--primary);
    --primary-blue-dark: #1e40af;
    --card-shadow: var(--shadow-md);
    --card-shadow-hover: var(--shadow-lg);
    --logout-red: #ef4444;
}

/* ========== BASE ========== */
body {
    margin: 0;
    background: var(--bg-page);
    font-family: 'Plus Jakarta Sans', 'Segoe UI', system-ui, sans-serif;
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* ========== AUTH PAGES (Login, Register, Forgot, Reset) ========== */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-box {
    background: var(--bg-card);
    width: 100%;
    max-width: 420px;
    padding: 40px 44px;
    border-radius: var(--radius);
    box-shadow: var(--auth-box-shadow);
    border: 1px solid var(--border);
    animation: authFadeIn 0.4s ease;
}

@keyframes authFadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.auth-box h2 {
    text-align: center;
    margin: 0 0 28px 0;
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.auth-box .auth-logo {
    display: block;
    text-align: center;
    margin-bottom: 24px;
}

.auth-box .auth-logo img {
    max-height: 48px;
}

/* Auth Form Inputs */
.auth-input {
    width: 100%;
    padding: 14px 18px;
    font-size: 15px;
    margin-bottom: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-sizing: border-box;
    background: #f8fafc;
    transition: all 0.2s ease;
}

.auth-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-muted);
    outline: none;
    background: #fff;
}

.auth-input::placeholder {
    color: #94a3b8;
}

/* Auth Button */
.auth-btn {
    width: 100%;
    padding: 14px 20px;
    background: var(--primary);
    font-family: inherit;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.auth-btn:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.auth-btn:active {
    transform: translateY(0);
}

/* Auth Messages */
.auth-msg {
    padding: 14px 18px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
}

.auth-msg.error {
    background: var(--error-bg);
    color: var(--error-text);
    border: 1px solid var(--error-border);
}

.auth-msg.success {
    background: var(--success-bg);
    color: var(--success-text);
    border: 1px solid var(--success-border);
}

.auth-msg.info {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    color: #1e40af;
    border: 1px solid #93c5fd;
}

.auth-msg a {
    color: inherit;
    font-weight: 600;
    text-decoration: underline;
}

/* Auth Links */
.auth-links {
    text-align: center;
    margin-top: 20px;
}

.auth-links a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-links a:hover {
    text-decoration: underline;
}

.auth-links .divider {
    color: var(--text-secondary);
    margin: 0 8px;
}

/* Auth Checkboxes */
.auth-checkbox {
    display: flex;
    gap: 12px;
    font-size: 14px;
    line-height: 1.5;
    align-items: flex-start;
    margin-bottom: 14px;
}

.auth-checkbox input {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    accent-color: var(--primary);
}

/* Password wrapper (show/hide) */
.auth-password-wrap {
    position: relative;
    margin-bottom: 16px;
}

.auth-password-wrap .auth-input {
    margin-bottom: 0;
    padding-right: 50px;
}

.auth-pw-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: all 0.2s;
}

.auth-pw-toggle:hover {
    background: #e2e8f0;
    color: var(--text-primary);
}

/* Auth row (2 columns) */
.auth-row {
    display: flex;
    gap: 12px;
}

.auth-row .auth-input {
    flex: 1;
}

/* Success popup */
.auth-popup {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.auth-popup.show {
    display: flex;
}

.auth-popup-box {
    background: #fff;
    padding: 32px 40px;
    border-radius: 16px;
    color: var(--text-primary);
    font-size: 18px;
    font-weight: 500;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.auth-popup-box.success {
    border-left: 4px solid #22c55e;
}

/* ========== SIDEBAR (Panel Layout) — Sıfırdan tasarım ========== */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: var(--sidebar-bg);
    z-index: 9999;
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.32s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 8px 0 40px rgba(0, 0, 0, 0.35);
}

.sidebar::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 1px;
    height: 100%;
    background: linear-gradient(180deg, rgba(255,255,255,0.08) 0%, transparent 50%, rgba(255,255,255,0.04) 100%);
    pointer-events: none;
}

.sidebar-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow-y: auto;
    padding: 20px 0 16px;
}

/* Header: logo + kapat */
.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px 20px;
    margin-bottom: 12px;
    border-bottom: 1px solid var(--sidebar-border);
    flex-shrink: 0;
}

.sidebar-brand {
    display: block;
    transition: opacity 0.2s ease;
}

.sidebar-brand:hover { opacity: 0.9; }

.sidebar-brand img {
    width: 100px;
    height: auto;
    display: block;
}

.sidebar-close {
    display: none;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border: none;
    background: var(--sidebar-surface);
    color: var(--sidebar-text);
    border-radius: 10px;
    cursor: pointer;
    font-size: 18px;
    transition: background 0.2s, color 0.2s;
}

.sidebar-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* Bakiye kartı */
.sidebar-balance {
    flex-shrink: 0;
    padding: 0 16px 20px;
}

.sidebar-balance__link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.22) 0%, rgba(59, 130, 246, 0.1) 100%);
    border: 1px solid rgba(59, 130, 246, 0.25);
    border-radius: 14px;
    text-decoration: none;
    color: #fff;
    transition: all 0.25s ease;
}

.sidebar-balance__link:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.35) 0%, rgba(59, 130, 246, 0.18) 100%);
    border-color: rgba(59, 130, 246, 0.45);
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.2);
    transform: translateY(-1px);
}

.sidebar-balance__link:focus-visible {
    outline: 2px solid var(--sidebar-accent);
    outline-offset: 2px;
}

.sidebar-balance__icon {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    font-size: 18px;
    color: var(--sidebar-accent-hover);
}

.sidebar-balance__body {
    flex: 1;
    min-width: 0;
}

.sidebar-balance__label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 2px;
}

.sidebar-balance__amount {
    font-variant-numeric: tabular-nums;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #fff;
}

.sidebar-balance__currency {
    font-size: 13px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    margin-left: 2px;
}

.sidebar-balance__arrow {
    font-size: 12px;
    opacity: 0.6;
    transition: transform 0.2s ease;
}

.sidebar-balance__link:hover .sidebar-balance__arrow {
    transform: translateX(4px);
    opacity: 1;
}

/* Navigasyon */
.sidebar-nav {
    flex: 1;
    padding: 0 12px;
    min-height: 0;
}

.sidebar-nav__group {
    display: block;
    padding: 16px 12px 8px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--sidebar-text-muted);
}

.sidebar-nav__list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-nav__list + .sidebar-nav__group { padding-top: 8px; }

.sidebar-nav__link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    margin-bottom: 4px;
    color: var(--sidebar-text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    border-radius: 12px;
    transition: background 0.2s ease, color 0.2s ease;
    border: 1px solid transparent;
}

.sidebar-nav__link i {
    width: 22px;
    text-align: center;
    font-size: 16px;
    opacity: 0.85;
    flex-shrink: 0;
}

.sidebar-nav__link:hover {
    background: var(--sidebar-surface);
    color: #fff;
}

.sidebar-nav__link.is-active {
    background: var(--sidebar-active-bg);
    color: #fff;
    border-color: rgba(59, 130, 246, 0.3);
    box-shadow: inset 3px 0 0 var(--sidebar-active-border);
}

.sidebar-nav__link.is-active i { opacity: 1; }

/* Footer: çıkış */
.sidebar-footer {
    flex-shrink: 0;
    padding: 16px 16px 0;
    margin-top: auto;
    border-top: 1px solid var(--sidebar-border);
}

.sidebar-logout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--sidebar-logout-bg);
    color: #fca5a5;
    text-decoration: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    border: 1px solid rgba(239, 68, 68, 0.25);
    transition: all 0.2s ease;
}

.sidebar-logout:hover {
    background: var(--sidebar-logout-hover);
    color: #fff;
    border-color: var(--sidebar-logout-hover);
}

/* Mobile menu toggle */
.menu-toggle {
    display: none;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 9000;
    width: 44px;
    height: 44px;
    font-size: 22px;
    padding: 0;
    border-radius: var(--radius-sm);
    background: var(--primary);
    color: #fff;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
    align-items: center;
    justify-content: center;
}

/* Page content */
.page-content {
    margin-left: var(--sidebar-width);
    padding: 28px 28px 56px;
    min-height: 100vh;
}

/* Sayfa sarmalayıcı */
.user-page {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 0 48px;
}

/* Sayfa başlığı — yeniden tasarım */
.page-header {
    margin-bottom: 32px;
    padding: 28px 32px;
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--primary) 0%, #3b82f6 100%);
    border-radius: 4px 0 0 4px;
}

.page-header h1 {
    margin: 0 0 6px 0;
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 12px;
}

.page-header h1 i {
    color: var(--primary);
    font-size: 22px;
    opacity: 0.95;
}

.page-header p {
    margin: 0;
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Cards */
.card {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    padding: 28px 32px;
    margin-bottom: 24px;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.card:hover {
    box-shadow: var(--shadow-md);
    border-color: #cbd5e1;
}

.card h2 {
    margin: 0 0 20px 0;
    font-size: 17px;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

/* ========== DASHBOARD ========== */
.dashboard-hero {
    margin-bottom: 32px;
    padding: 32px 36px;
    background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 50%, #3b82f6 100%);
    border-radius: var(--radius);
    color: #fff;
    box-shadow: 0 8px 32px rgba(37, 99, 235, 0.25);
}

.dashboard-hero h1 {
    margin: 0 0 8px 0;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.dashboard-hero p {
    margin: 0;
    font-size: 15px;
    opacity: 0.92;
}

.quick-actions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.quick-action-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 140px;
    padding: 28px 20px;
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.25s ease;
}

.quick-action-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
    color: var(--primary);
}

.quick-action-card i {
    font-size: 32px;
    margin-bottom: 14px;
    color: var(--primary);
    transition: color 0.2s;
}

.quick-action-card:hover i {
    color: var(--primary-hover);
}

.quick-action-card span {
    font-size: 15px;
    font-weight: 600;
    text-align: center;
}

@media (max-width: 768px) {
    .quick-actions { grid-template-columns: repeat(2, 1fr); gap: 16px; }
    .dashboard-hero { padding: 24px 24px; }
}

@media (max-width: 480px) {
    .quick-actions { grid-template-columns: 1fr; }
}

/* Tablolar */
.user-page .table-wrapper {
    overflow-x: auto;
    border-radius: var(--radius-sm);
    margin-top: 0;
    border: 1px solid var(--border);
    background: var(--bg-card);
}

.user-page table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.user-page thead th {
    background: #f8fafc;
    padding: 14px 20px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-secondary);
    text-align: left;
    border-bottom: 2px solid var(--border);
    white-space: nowrap;
}

.user-page tbody tr {
    transition: background 0.15s ease;
}

.user-page tbody tr:hover {
    background: #f8fafc;
}

.user-page tbody td {
    padding: 16px 20px;
    color: var(--text-primary);
    border-bottom: 1px solid #f1f5f9;
}

.user-page tbody tr:last-child td {
    border-bottom: none;
}

/* Overlay (mobile) */
.sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    z-index: 9998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

/* Form elemanları */
.label {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
    color: var(--text-primary);
}

.select, .input {
    width: 100%;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    font-size: 15px;
    margin-bottom: 0;
    background: #fff;
    transition: all 0.2s ease;
    color: var(--text-primary);
    box-sizing: border-box;
    font-family: inherit;
}

.select:hover, .input:hover {
    border-color: #cbd5e1;
}

.select:focus, .input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-muted);
}

/* Mesaj kutuları */
.msg-success, .flash.success {
    background: var(--success-bg);
    padding: 16px 20px;
    color: var(--success-text);
    border-radius: var(--radius-sm);
    margin-bottom: 24px;
    border: 1px solid var(--success-border);
    font-weight: 500;
}

.msg-error {
    background: var(--error-bg);
    padding: 16px 20px;
    color: var(--error-text);
    border-radius: var(--radius-sm);
    margin-bottom: 24px;
    border: 1px solid var(--error-border);
    font-weight: 500;
}

/* Submit butonu */
.btn-submit {
    width: 100%;
    padding: 14px 24px;
    border: none;
    background: var(--primary);
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.btn-submit:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.btn-submit:active {
    transform: translateY(0);
}

/* Footer */
.user-footer {
    text-align: center;
    color: var(--text-secondary);
    padding: 20px 0;
    font-size: 13px;
}

/* Durum etiketleri */
.user-page .status,
.user-page .tag {
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    display: inline-block;
}

.user-page .pending { background: #fef3c7; color: #92400e; }
.user-page .approved,
.user-page .income { background: #d1fae5; color: #065f46; }
.user-page .rejected,
.user-page .expense { background: #fee2e2; color: #991b1b; }

/* Boş tablo hücresi */
.user-page td.empty-cell,
.user-page .empty-cell {
    text-align: center;
    color: #64748b;
    padding: 48px 24px !important;
    font-size: 15px;
    font-weight: 500;
}

/* Filtre kutusu */
.user-page .filter-box {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    align-items: center;
}

.user-page .filter-box input,
.user-page .filter-box select {
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    font-size: 14px;
    background: #fff;
    transition: all 0.2s ease;
    font-family: inherit;
}

.user-page .filter-box input:focus,
.user-page .filter-box select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-muted);
}

.user-page .filter-box button {
    padding: 12px 20px;
    border: none;
    background: var(--primary);
    color: #fff;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.2s ease;
}

.user-page .filter-box button:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}

/* Excel butonu */
.user-page .excel-btn {
    padding: 12px 20px;
    background: #16a34a;
    color: #fff !important;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.user-page .excel-btn:hover {
    background: #15803d;
    transform: translateY(-1px);
}

/* Sayfalama */
.user-page .pagination {
    margin-top: 24px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.user-page .page-btn {
    padding: 10px 16px;
    background: #f1f5f9;
    border-radius: var(--radius-sm);
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
}

.user-page .page-btn:hover {
    background: #e2e8f0;
    color: var(--text-primary);
}

.user-page .page-btn.active {
    background: var(--primary);
    color: #fff;
}

/* Bakiye kutusu (para çek) */
.user-page .balance-box {
    background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 50%, #3b82f6 100%);
    padding: 24px 28px;
    color: #fff;
    border-radius: var(--radius);
    text-align: center;
    margin-bottom: 0;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.25);
}

.user-page .balance-box div {
    font-size: 13px;
    opacity: 0.9;
    letter-spacing: 0.02em;
}

.user-page .balance-box p {
    margin: 6px 0 0;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Hata / uyarı kutusu */
.user-page .error {
    background: var(--error-bg);
    padding: 16px 20px;
    border-radius: var(--radius-sm);
    color: var(--error-text);
    margin-bottom: 24px;
    border: 1px solid var(--error-border);
    font-weight: 500;
}

/* Modal */
.modal-bg {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    backdrop-filter: blur(4px);
}

.modal-bg.show { display: flex; }

.modal-box {
    background: var(--bg-card);
    padding: 28px 32px;
    border-radius: var(--radius);
    width: 400px;
    max-width: 90vw;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border);
}

.modal-box h3 {
    margin: 0 0 12px 0;
    font-size: 18px;
    color: var(--text-primary);
}

.modal-close {
    background: var(--primary);
    color: #fff;
    border: none;
    margin-top: 20px;
    padding: 12px 20px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    width: 100%;
    font-family: inherit;
    transition: all 0.2s;
}

.modal-close:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}

/* ========== REDEEM CODE ========== */
.redeem-grid {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 32px;
    align-items: start;
}

@media (max-width: 920px) {
    .redeem-grid { grid-template-columns: 1fr; gap: 24px; }
    .summary-column { position: static !important; }
}

.form-box {
    background: var(--bg-card);
    padding: 32px 36px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.form-section { margin-bottom: 24px; }
.form-section:last-of-type { margin-bottom: 0; }

.codes-section { margin-top: 20px; }

.codes-scroll {
    max-height: 280px;
    overflow-y: auto;
    padding-right: 8px;
    margin-top: 12px;
}

.codes-scroll::-webkit-scrollbar { width: 6px; }
.codes-scroll::-webkit-scrollbar-track { background: #f1f5f9; border-radius: 3px; }
.codes-scroll::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }

.code-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.code-index {
    flex-shrink: 0;
    width: 36px;
    height: 42px;
    background: #f1f5f9;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--text-secondary);
    font-size: 14px;
}

.code-input {
    flex: 1;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: #fff;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.2s ease;
}

.code-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-muted);
}

.summary-column { position: relative; min-height: 200px; }

.summary-card {
    position: sticky;
    top: 96px;
    background: var(--bg-card);
    padding: 28px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.summary-card.hidden { display: none !important; }

.summary-card h3 {
    margin: 0 0 24px 0;
    font-size: 17px;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.summary-card h3::before {
    content: "";
    width: 4px;
    height: 22px;
    background: var(--primary);
    border-radius: 2px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid #f1f5f9;
    font-size: 14px;
}

.summary-row:last-child { border-bottom: none; padding-bottom: 0; }

.summary-row .label { margin: 0; font-weight: 500; color: var(--text-secondary); }
.summary-row .value { font-weight: 600; color: var(--primary); text-align: right; }

.summary-row.highlight {
    margin-top: 8px;
    padding: 18px 0 0;
    border-top: 2px solid var(--border);
}

.summary-row.highlight .value-wrapper { display: flex; flex-direction: column; align-items: flex-end; }
.summary-row.highlight .value { font-size: 20px; font-weight: 700; color: var(--primary-hover); }
.summary-row.highlight .gain-formula { display: block; font-size: 13px; color: var(--text-secondary); margin-top: 4px; }

.summary-placeholder {
    text-align: center;
    padding: 48px 24px;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.6;
}

.summary-placeholder i { font-size: 36px !important; margin-bottom: 16px !important; opacity: 0.4 !important; }

.user-page .success {
    background: var(--success-bg);
    padding: 16px 20px;
    color: var(--success-text);
    border-radius: var(--radius-sm);
    margin-bottom: 24px;
    border: 1px solid var(--success-border);
    font-weight: 500;
}

/* ========== WITHDRAWAL ========== */
.user-page .withdraw-grid {
    display: grid;
    gap: 32px;
}

@media (min-width: 900px) {
    .user-page .withdraw-grid {
        grid-template-columns: 340px 1fr;
        gap: 48px;
        align-items: start;
    }
    .user-page .withdraw-form-wrap { max-width: 420px; }
}

.user-page .withdraw-side {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.user-page .withdraw-info,
.user-page .withdraw-rules {
    border-radius: var(--radius-sm);
    padding: 18px 20px;
    border: 1px solid var(--border);
    background: #f8fafc;
}

.user-page .withdraw-info {
    background: #eff6ff;
    border-color: #bfdbfe;
}

.user-page .withdraw-info .withdraw-info-inner { display: flex; align-items: flex-start; gap: 14px; }
.user-page .withdraw-info .withdraw-info-inner i { color: var(--primary); font-size: 18px; flex-shrink: 0; }
.user-page .withdraw-info p { margin: 0; font-size: 14px; color: var(--text-primary); line-height: 1.55; }

.user-page .withdraw-rules .rules-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-page .withdraw-rules .rules-title i { color: var(--primary); font-size: 16px; }
.user-page .withdraw-rules .rules-row { font-size: 14px; color: var(--text-secondary); margin-bottom: 8px; line-height: 1.5; }
.user-page .withdraw-rules .rules-row:last-child { margin-bottom: 0; }
.user-page .withdraw-rules .rules-row strong { color: var(--text-primary); }

.user-page .withdraw-form .form-group { margin-bottom: 22px; }
.user-page .withdraw-form label { display: block; font-size: 14px; font-weight: 600; color: var(--text-primary); margin-bottom: 10px; }
.user-page .withdraw-form input[type="text"] {
    width: 100%;
    box-sizing: border-box;
    padding: 14px 18px;
    font-size: 15px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: #fff;
    color: var(--text-primary);
    font-family: inherit;
    transition: all 0.2s;
}

.user-page .withdraw-form input::placeholder { color: var(--text-muted); }
.user-page .withdraw-form input:hover { border-color: #cbd5e1; }
.user-page .withdraw-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-muted);
}

.user-page .withdraw-summary {
    background: var(--warning-bg);
    border: 1px solid var(--warning-border);
    border-radius: var(--radius-sm);
    padding: 18px 20px;
    margin-top: 24px;
    display: none;
}

.user-page .withdraw-summary.show { display: block; }
.user-page .withdraw-summary .summary-title { font-size: 13px; font-weight: 700; color: #92400e; margin: 0 0 12px; }
.user-page .withdraw-summary .summary-row { display: flex; justify-content: space-between; font-size: 14px; color: var(--text-secondary); margin-bottom: 8px; }
.user-page .withdraw-summary .summary-final {
    display: flex;
    justify-content: space-between;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 2px solid #fcd34d;
    font-size: 15px;
    font-weight: 700;
    color: var(--primary-hover);
}

.user-page .withdraw-error {
    background: var(--error-bg);
    padding: 18px 22px;
    border-radius: var(--radius-sm);
    color: var(--error-text);
    margin-bottom: 24px;
    border: 1px solid var(--error-border);
    font-weight: 500;
    font-size: 14px;
}

.user-page .withdraw-submit {
    width: 100%;
    margin-top: 28px;
    padding: 16px 24px;
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    background: var(--primary);
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-family: inherit;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
    transition: all 0.2s;
}

.user-page .withdraw-submit:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.user-page .withdraw-submit:active { transform: translateY(0); }

/* Profile form */
.profile-form .auth-input { margin-bottom: 16px; }
.profile-form .auth-row { display: flex; gap: 12px; margin-bottom: 0; }
.profile-form .auth-row .auth-input { flex: 1; }

.profile-form .profile-btn {
    padding: 14px 28px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: inherit;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.profile-form .profile-btn:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}

.profile-msg { padding: 16px 20px; border-radius: var(--radius-sm); margin-bottom: 20px; font-weight: 500; }
.profile-msg.success { background: var(--success-bg); border: 1px solid var(--success-border); color: var(--success-text); }
.profile-msg.error { background: var(--error-bg); border: 1px solid var(--error-border); color: var(--error-text); }
.profile-meta { margin-top: 24px; font-size: 13px; color: var(--text-secondary); }

/* Tablo mobil responsive */
@media (max-width: 768px) {
    .user-page table thead { display: none; }
    .user-page table tr {
        display: block;
        margin-bottom: 16px;
        background: #fff;
        border-radius: 12px;
        padding: 16px;
        box-shadow: 0 2px 12px rgba(30, 64, 175, 0.08);
        border: 1px solid rgba(30, 64, 175, 0.06);
    }
    .user-page table td {
        display: flex;
        justify-content: space-between;
        padding: 12px 8px;
        border-bottom: 1px solid #f1f5f9;
    }
    .user-page table td:last-child { border-bottom: none; }
    .user-page table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: #64748b;
        margin-right: 12px;
    }
}

/* Mobile */
@media (max-width: 800px) {
    .menu-toggle {
        display: flex;
    }
    .page-content {
        margin-left: 0 !important;
        padding-top: 72px;
    }
    .sidebar {
        width: var(--sidebar-width);
        transform: translateX(-100%);
    }
    .sidebar.show {
        transform: translateX(0);
    }
    .sidebar-close {
        display: flex;
    }
    .sidebar-header {
        padding: 0 16px 16px;
    }
    .auth-row {
        flex-direction: column;
    }
}
