/* ===================================================================
   TechnoThorium Mail (TechMail) - Modern Glassmorphism Styling
   =================================================================== */

:root {
    --bg-dark: #090d16;
    --bg-surface: #111827;
    --bg-card: rgba(17, 24, 39, 0.85);
    --bg-sidebar: #070a12;
    --bg-hover: rgba(255, 255, 255, 0.06);
    --border-color: rgba(255, 255, 255, 0.08);
    
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --primary-glow: rgba(99, 102, 241, 0.3);
    
    --accent: #06b6d4;
    --accent-glow: rgba(6, 182, 212, 0.25);
    
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --danger-bg: rgba(239, 68, 68, 0.12);

    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --shadow-soft: 0 15px 40px rgba(0, 0, 0, 0.5);
    --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: var(--font-sans);
    background-color: var(--bg-dark);
    color: var(--text-primary);
    overflow: hidden;
    height: 100vh;
    width: 100vw;
}

/* ===================================================================
   1. AÇILIŞ / PORTAL SAYFASI (TechnoThorium Mail Karşılama)
   =================================================================== */
.portal-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    width: 100vw;
    background-color: #0b1120;
    background-image: linear-gradient(135deg, rgba(11, 17, 32, 0.85), rgba(15, 23, 42, 0.85)), url('3.png'), url('../3.png');
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    padding: 24px;
    position: relative;
    overflow-y: auto;
}

.portal-card {
    position: relative;
    background: rgba(15, 23, 42, 0.78);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-xl);
    padding: 44px 42px;
    max-width: 520px;
    width: 100%;
    min-height: 520px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.65);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    animation: portalFade 0.4s ease-out;
}

@keyframes portalFade {
    from { opacity: 0; transform: translateY(15px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.portal-glow {
    position: absolute;
    width: 280px;
    height: 280px;
    background: var(--primary);
    filter: blur(140px);
    opacity: 0.22;
    top: -80px;
    left: 50%;
    transform: translateX(-50%);
    pointer-events: none;
}

.portal-header {
    text-align: center;
    margin-bottom: 24px;
}

.portal-logo {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #fff;
    margin: 0 auto 16px auto;
    box-shadow: 0 0 35px var(--primary-glow);
}

.brand-title {
    font-size: 1.75rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, #ffffff 40%, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-subtitle {
    font-size: 0.88rem;
    color: var(--text-secondary);
    margin-top: 6px;
}

.auth-form-view {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-height: 230px;
    justify-content: center;
}

/* Giriş & Kayıt Sekmeleri */
.auth-tabs {
    display: flex;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 4px;
    margin-bottom: 22px;
}

.auth-tab-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 10px;
    font-size: 0.88rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.auth-tab-btn.active {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 2px 10px var(--primary-glow);
}

.auth-form-view {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.input-prefix-box {
    display: flex;
    align-items: center;
    gap: 6px;
}

.input-prefix-box input {
    flex: 1.2;
}

.prefix-at {
    color: var(--text-muted);
    font-weight: 700;
    font-size: 1.1rem;
}

.input-prefix-box select {
    flex: 1;
}

.portal-footer {
    text-align: center;
    margin-top: 26px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.admin-link-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
}

.admin-link-trigger:hover {
    color: var(--accent);
    background: rgba(6, 182, 212, 0.08);
}

/* ===================================================================
   2. ANA UYGULAMA (APP LAYOUT & SIDEBAR)
   =================================================================== */
.app-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    height: 100vh;
    background: var(--bg-dark);
}

.sidebar {
    background: var(--bg-sidebar);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    padding: 24px 16px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.brand-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #fff;
}

.brand-info {
    display: flex;
    flex-direction: column;
}

.brand-name {
    font-weight: 800;
    font-size: 1.1rem;
}

.brand-badge {
    font-size: 0.7rem;
    color: var(--accent);
    font-weight: 700;
    letter-spacing: 1px;
}

.session-card {
    margin-top: 16px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: 10px;
}

.session-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.session-details {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.session-title {
    font-size: 0.8rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.session-status {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.compose-wrapper {
    margin: 18px 0;
}

.btn-compose {
    width: 100%;
    padding: 12px;
    border-radius: var(--radius-md);
    font-weight: 600;
    box-shadow: 0 4px 15px var(--primary-glow);
}

.nav-menu {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
}

.nav-section-title {
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 1.2px;
    padding: 14px 10px 6px 10px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    font-size: 0.88rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
}

.nav-item:hover {
    color: #fff;
    background: var(--bg-hover);
}

.nav-item.active {
    background: rgba(99, 102, 241, 0.15);
    color: #fff;
    font-weight: 600;
    border-left: 3px solid var(--primary);
}

.counter {
    margin-left: auto;
    background: var(--primary);
    color: #fff;
    font-size: 0.7rem;
    padding: 2px 7px;
    border-radius: 10px;
    font-weight: 700;
}

.counter-ghost {
    margin-left: auto;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    font-size: 0.7rem;
    padding: 2px 7px;
    border-radius: 10px;
}

.sidebar-footer {
    padding-top: 14px;
    border-top: 1px solid var(--border-color);
}

/* ===================================================================
   3. ANA İÇERİK & TOPBAR
   =================================================================== */
.main-content {
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
}

.topbar {
    height: 64px;
    border-bottom: 1px solid var(--border-color);
    padding: 0 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(17, 24, 39, 0.4);
    backdrop-filter: blur(12px);
}

.topbar-search {
    position: relative;
    width: 360px;
}

.topbar-search i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.topbar-search input {
    width: 100%;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    padding: 9px 14px 9px 40px;
    border-radius: var(--radius-md);
    color: #fff;
    font-size: 0.88rem;
    outline: none;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-topbar-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: rgba(6, 182, 212, 0.1);
    border: 1px solid rgba(6, 182, 212, 0.3);
    border-radius: 20px;
    color: var(--accent);
    font-size: 0.75rem;
    font-weight: 700;
}

.action-btn {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

/* Sekmeler */
.tab-page {
    display: none;
    flex: 1;
    overflow-y: auto;
    padding: 28px;
}

.tab-page.active {
    display: flex;
    flex-direction: column;
}

/* ===================================================================
   4. WEBMAIL GELEN KUTUSU & OKUMA
   =================================================================== */
#view-inbox {
    padding: 0;
    overflow: hidden;
}

.mail-client-container {
    display: grid;
    grid-template-columns: 360px 1fr;
    height: 100%;
    overflow: hidden;
}

.mail-list-pane {
    background: rgba(17, 24, 39, 0.3);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

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

.mail-list {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mail-item {
    padding: 12px 14px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--transition);
}

.mail-item:hover {
    background: var(--bg-hover);
    border-color: var(--border-color);
}

.mail-item.unread .mail-item-title {
    font-weight: 700;
    color: #fff;
}

.mail-item-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    margin-bottom: 4px;
}

.mail-sender {
    font-weight: 600;
    color: var(--text-primary);
}

.mail-time {
    color: var(--text-muted);
}

.mail-item-title {
    font-size: 0.82rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mail-read-pane {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: var(--bg-dark);
}

.empty-read-view {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    gap: 12px;
}

.mail-details-view {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.mail-detail-header-card {
    padding: 24px 32px;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.mail-header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.mail-sender-block {
    display: flex;
    align-items: center;
    gap: 14px;
}

.sender-text-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.sender-from-line {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sender-name-bold {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
}

.sender-email-dim {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.sender-recipient-line {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: flex;
    gap: 6px;
}

.meta-label {
    color: var(--text-muted);
}

.mail-date-badge {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    white-space: nowrap;
}

.mail-subject-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-top: 8px;
    border-top: 1px dashed rgba(255, 255, 255, 0.07);
}

.subject-tag {
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    color: var(--primary);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 3px 8px;
    border-radius: 6px;
    letter-spacing: 0.5px;
}

.mail-subject {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
}

.mail-read-footer {
    padding: 12px 32px;
    background: rgba(11, 15, 25, 0.95);
    border-top: 1px solid var(--border-color);
    text-align: right;
}

.mail-read-footer span {
    font-size: 0.72rem;
    color: var(--text-muted);
    font-weight: 600;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    font-family: var(--font-mono);
}

.logo-spin {
    display: inline-block;
    animation: atomSpin 12s linear infinite;
}

@keyframes atomSpin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.mail-header-actions-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Okunmamış / Yeni Posta Rozeti */
.unread-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #3b82f6;
    border-radius: 50%;
    margin-right: 6px;
    box-shadow: 0 0 8px #3b82f6;
}

.mail-item.unread {
    background: rgba(59, 130, 246, 0.06);
    border-color: rgba(59, 130, 246, 0.25);
}

.mail-item.unread .mail-sender {
    color: #fff;
    font-weight: 700;
}

.mail-item.active-item {
    background: rgba(99, 102, 241, 0.12);
    border-color: var(--primary);
}

/* Ekler Bölümü & Kartları */
.mail-attachments-section {
    padding: 16px 32px;
    background: rgba(15, 23, 42, 0.5);
    border-bottom: 1px solid var(--border-color);
}

.attachments-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.attachments-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
}

.attachment-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: var(--transition);
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.attachment-card:hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.attachment-icon {
    font-size: 22px;
    color: var(--accent);
    flex-shrink: 0;
}

.attachment-img-preview {
    width: 36px;
    height: 36px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.attachment-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    flex: 1;
}

.attachment-name {
    font-size: 0.82rem;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.attachment-size {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.attachment-action-btn {
    color: var(--text-muted);
    font-size: 0.85rem;
    transition: var(--transition);
}

.attachment-card:hover .attachment-action-btn {
    color: var(--accent);
}

.mail-body-container {
    flex: 1;
    background: var(--bg-dark);
    overflow-y: auto;
    padding: 32px 36px;
    border-top: 1px solid var(--border-color);
}

.mail-content-display {
    color: #f1f5f9 !important;
    font-size: 1.05rem;
    line-height: 1.8;
    word-break: break-word;
    font-family: var(--font-sans);
}

.mail-content-display * {
    color: #f1f5f9 !important;
    background-color: transparent !important;
}

.mail-content-display a {
    color: var(--accent) !important;
    text-decoration: underline;
}

.mail-content-display pre, 
.mail-content-display code {
    background: rgba(255, 255, 255, 0.06) !important;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
}

.mail-content-display img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    margin: 12px 0;
}

/* ===================================================================
   5. KAYIT ONAYLARI TABLOSU (ADMIN)
   =================================================================== */
.approvals-table-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-top: 18px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

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

.data-table th {
    background: rgba(255, 255, 255, 0.02);
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.78rem;
    text-transform: uppercase;
}

.status-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.72rem;
    font-weight: 700;
}

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

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

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

/* ===================================================================
   6. CPANEL HESAP KARTLARI & FORMLAR
   =================================================================== */
.section-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.section-top h2 {
    font-size: 1.35rem;
    font-weight: 700;
}

.section-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

.accounts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.account-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.account-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.acc-icon {
    width: 38px;
    height: 38px;
    border-radius: var(--radius-md);
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.acc-meta {
    flex: 1;
    min-width: 0;
}

.acc-email {
    font-weight: 700;
    font-size: 0.92rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.acc-domain {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.acc-quota-bar {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.quota-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.72rem;
    color: var(--text-secondary);
}

.progress-track {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--accent));
}

.view-mode-toggle {
    display: inline-flex;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 2px;
    gap: 2px;
}

.view-mode-toggle .btn {
    border: none !important;
    background: transparent;
    color: var(--text-secondary);
    padding: 6px 12px;
}

.view-mode-toggle .btn.active {
    background: var(--primary) !important;
    color: #fff !important;
}

/* Form Kartları */
.form-container-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 30px;
    max-width: 760px;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border-color);
}

.card-icon-header {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 16px;
}

.form-group label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.form-group input,
.form-group select,
.form-group textarea,
.edit-card-sub input {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 11px 14px;
    color: #fff;
    font-size: 0.88rem;
    font-family: var(--font-sans);
    outline: none;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-with-icon i {
    position: absolute;
    left: 14px;
    color: var(--text-muted);
}

.input-with-icon input,
.input-with-icon select {
    padding-left: 38px !important;
    width: 100%;
}

.form-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-row-3 {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 16px;
}

.section-divider {
    height: 1px;
    background: var(--border-color);
    margin: 22px 0;
}

.sub-heading {
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 14px;
}

.form-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 20px;
}

.btn-inline {
    position: absolute;
    right: 8px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    font-size: 0.72rem;
    font-weight: 600;
    cursor: pointer;
}

.btn-inline:hover {
    background: var(--primary);
    color: #fff;
}

.edit-card-sub {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px;
}

.edit-card-sub h4 {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.input-with-inline-action {
    display: flex;
    gap: 8px;
}

.input-with-inline-action input {
    flex: 1;
}

/* ===================================================================
   7. BUTONLAR & MODALLAR
   =================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 18px;
    font-family: var(--font-sans);
    font-size: 0.88rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    cursor: pointer;
    border: 1px solid transparent;
    transition: var(--transition);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), #4f46e5);
    color: #fff;
    box-shadow: 0 4px 15px var(--primary-glow);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px var(--primary-glow);
}

.btn-outline {
    background: transparent;
    border-color: var(--border-color);
    color: var(--text-secondary);
}

.btn-outline:hover {
    background: var(--bg-hover);
    color: #fff;
}

.btn-outline-danger {
    background: transparent;
    border-color: rgba(239, 68, 68, 0.3);
    color: var(--danger);
}

.btn-outline-danger:hover {
    background: var(--danger);
    color: #fff;
}

.btn-block { width: 100%; }
.btn-lg { padding: 12px 24px; font-size: 0.95rem; }
.btn-sm { padding: 6px 12px; font-size: 0.78rem; }

.modal-backdrop {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-dialog {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    width: 580px;
    max-width: 90vw;
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
}

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

.modal-title {
    font-size: 1.05rem;
    font-weight: 700;
}

.modal-close-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 18px;
    cursor: pointer;
}

.modal-body {
    padding: 22px;
}

.modal-footer {
    padding: 14px 22px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.input-readonly {
    background: rgba(255, 255, 255, 0.02) !important;
    color: var(--text-muted) !important;
    cursor: not-allowed;
}

.toast-container {
    position: fixed;
    bottom: 24px; right: 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 9999;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: #fff;
    font-size: 0.85rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.toast-success { border-left: 4px solid var(--success); }
.toast-error { border-left: 4px solid var(--danger); }
.toast-info { border-left: 4px solid var(--accent); }

.empty-state, .loading-state {
    padding: 40px;
    text-align: center;
    color: var(--text-muted);
}
