/* ============================================================
   AYZA GRUP - Genel Stil Dosyası
   ============================================================ */

:root {
    --primary: #1e3a5f;
    --primary-dark: #142a45;
    --primary-light: #2f5a8f;
    --accent: #d4a017;
    --success: #1e8e5a;
    --success-bg: #e8f7f0;
    --danger: #c0392b;
    --danger-bg: #fdecea;
    --text-main: #1f2937;
    --text-muted: #6b7280;
    --border: #e5e7eb;
    --bg-body: #f4f6f9;
    --bg-card: #ffffff;
    --radius: 10px;
    --shadow: 0 2px 8px rgba(16, 24, 40, 0.06);
    --shadow-lg: 0 10px 30px rgba(16, 24, 40, 0.12);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-body);
    color: var(--text-main);
    line-height: 1.5;
}

.hidden { display: none !important; }

/* ============================================================
   GİRİŞ SAYFASI
   ============================================================ */
.login-body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 55%, var(--primary-light) 100%);
    padding: 20px;
}

.login-wrapper { width: 100%; max-width: 420px; }

.login-brand { text-align: center; color: #fff; margin-bottom: 28px; }
.login-brand .brand-icon {
    width: 64px; height: 64px; border-radius: 16px;
    background: rgba(255,255,255,0.12);
    display: flex; align-items: center; justify-content: center;
    font-size: 28px; margin: 0 auto 14px; color: var(--accent);
}
.login-brand h1 { font-size: 26px; font-weight: 800; letter-spacing: 1px; }
.login-brand p { font-size: 14px; opacity: 0.85; margin-top: 4px; }

.login-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 32px 28px;
    box-shadow: var(--shadow-lg);
}
.login-card h2 { font-size: 20px; font-weight: 700; margin-bottom: 4px; }
.login-subtitle { color: var(--text-muted); font-size: 13.5px; margin-bottom: 20px; }

.login-footer { text-align: center; color: rgba(255,255,255,0.7); font-size: 12.5px; margin-top: 22px; }

/* ============================================================
   FORM ELEMANLARI
   ============================================================ */
.form-group { margin-bottom: 16px; }
.form-group label {
    display: flex; align-items: center; gap: 6px;
    font-size: 13px; font-weight: 600; color: var(--text-main);
    margin-bottom: 6px;
}
.form-group label i { color: var(--primary-light); width: 14px; }

input[type="text"], input[type="email"], input[type="password"],
input[type="date"], input[type="number"], select, textarea {
    width: 100%;
    padding: 11px 13px;
    border: 1.5px solid var(--border);
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    color: var(--text-main);
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(47, 90, 143, 0.12);
}
input:disabled { background: #f3f4f6; color: var(--text-muted); }
textarea { resize: vertical; min-height: 70px; }

.form-hint { display: block; font-size: 11.5px; color: var(--text-muted); margin-top: 4px; }

.password-field { position: relative; }
.password-field input { padding-right: 40px; }
.toggle-password {
    position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
    background: none; border: none; cursor: pointer; color: var(--text-muted); font-size: 15px;
}

.hidden-input { margin-top: 8px; }

/* ============================================================
   BUTONLAR
   ============================================================ */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 18px;
    border: none; border-radius: 8px;
    font-size: 14px; font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    text-decoration: none;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-block { width: 100%; }
.btn-ghost { background: transparent; color: var(--text-main); border: 1.5px solid var(--border); }
.btn-ghost:hover { background: #f3f4f6; }
.btn-sm { padding: 7px 12px; font-size: 12.5px; }
.btn-icon {
    width: 32px; height: 32px; padding: 0; border-radius: 6px;
    display: inline-flex; align-items: center; justify-content: center;
    border: none; cursor: pointer; font-size: 13px; transition: opacity 0.15s;
}
.btn-icon.edit { background: #eaf1fb; color: var(--primary); }
.btn-icon.delete { background: var(--danger-bg); color: var(--danger); }
.btn-icon:hover { opacity: 0.75; }
.btn-icon:disabled { opacity: 0.35; cursor: not-allowed; }

/* ============================================================
   ALERT / BİLDİRİM KUTULARI
   ============================================================ */
.alert {
    display: flex; align-items: center; gap: 10px;
    padding: 12px 14px; border-radius: 8px;
    font-size: 13.5px; margin-bottom: 16px;
}
.alert-error { background: var(--danger-bg); color: var(--danger); }

/* ============================================================
   ÜST MENÜ (TOPBAR)
   ============================================================ */
.topbar {
    background: var(--primary);
    color: #fff;
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 24px;
    box-shadow: var(--shadow);
    position: sticky; top: 0; z-index: 20;
}
.topbar-brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 17px; letter-spacing: 0.5px; }
.topbar-brand i { color: var(--accent); font-size: 20px; }
.topbar-user { display: flex; align-items: center; gap: 14px; }
.user-chip { display: flex; align-items: center; gap: 8px; font-size: 13.5px; background: rgba(255,255,255,0.1); padding: 7px 12px; border-radius: 20px; cursor: pointer; transition: background 0.15s; }
.user-chip:hover { background: rgba(255,255,255,0.18); }
.user-chip .profile-gear { font-size: 11px; opacity: 0.75; margin-left: 2px; }
.user-avatar-img {
    width: 22px; height: 22px; border-radius: 50%; object-fit: cover;
    border: 1.5px solid rgba(255,255,255,0.4);
}
.topbar .btn-ghost { color: #fff; border-color: rgba(255,255,255,0.35); }
.topbar .btn-ghost:hover { background: rgba(255,255,255,0.12); }

/* ============================================================
   BİLDİRİM İKONU / DROPDOWN
   ============================================================ */
.notification-wrapper { position: relative; }
.notification-bell {
    position: relative;
    width: 38px; height: 38px; border-radius: 50%;
    background: rgba(255,255,255,0.1); border: none; cursor: pointer;
    color: #fff; font-size: 16px;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.15s;
}
.notification-bell:hover { background: rgba(255,255,255,0.2); }
.notification-badge {
    position: absolute; top: -3px; right: -3px;
    min-width: 18px; height: 18px; padding: 0 4px;
    background: var(--danger); color: #fff;
    border-radius: 999px; font-size: 10.5px; font-weight: 800;
    display: flex; align-items: center; justify-content: center;
    border: 2px solid var(--primary);
}
.notification-dropdown {
    position: absolute; top: calc(100% + 12px); right: 0;
    width: 340px; max-height: 420px;
    background: var(--bg-card); color: var(--text-main);
    border-radius: 12px; box-shadow: var(--shadow-lg);
    overflow: hidden; z-index: 50;
    display: flex; flex-direction: column;
}
.notification-dropdown-header {
    padding: 14px 16px; font-weight: 700; font-size: 14px;
    border-bottom: 1px solid var(--border); background: #f9fafb;
}
.notification-list { overflow-y: auto; max-height: 360px; }
.notification-item {
    display: flex; gap: 10px; padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    font-size: 13px;
}
.notification-item:last-child { border-bottom: none; }
.notification-item.unread { background: #eaf1fb; }
.notification-item .notif-icon {
    width: 32px; height: 32px; min-width: 32px; border-radius: 50%;
    background: #eaf1fb; color: var(--primary);
    display: flex; align-items: center; justify-content: center; font-size: 13px;
}
.notification-item.note-type .notif-icon { background: #fdf3dd; color: var(--accent); }
.notification-item .notif-text { flex: 1; }
.notification-item .notif-message { color: var(--text-main); line-height: 1.4; }
.notification-item .notif-time { color: var(--text-muted); font-size: 11px; margin-top: 3px; }
.notification-empty { padding: 30px 16px; text-align: center; color: var(--text-muted); font-size: 13px; }

/* ============================================================
   GENEL NOT / AÇIKLAMA KUTUSU (İşlem Listesi üzerinde)
   ============================================================ */
.note-box {
    background: #fbfbfc; border: 1px solid var(--border); border-radius: 10px;
    padding: 14px; margin-bottom: 18px;
}
.note-box label {
    display: flex; align-items: center; gap: 6px;
    font-size: 12.5px; font-weight: 700; color: var(--text-main); margin-bottom: 8px;
}
.note-box label i { color: var(--accent); }
.note-input-row { display: flex; gap: 10px; align-items: flex-start; }
.note-input-row textarea { flex: 1; resize: vertical; min-height: 44px; font-size: 13px; }
.note-input-row .btn { white-space: nowrap; height: 40px; margin-top: 0; }
.note-list { margin-top: 12px; display: flex; flex-direction: column; gap: 8px; max-height: 160px; overflow-y: auto; }
.note-list:empty { display: none; }
.note-item {
    background: #fff; border: 1px solid var(--border); border-radius: 8px;
    padding: 9px 12px; font-size: 12.5px;
}
.note-item .note-meta { display: flex; justify-content: space-between; margin-bottom: 3px; }
.note-item .note-author { font-weight: 700; color: var(--primary); }
.note-item .note-time { color: var(--text-muted); font-size: 11px; }
.note-item .note-text { color: var(--text-main); line-height: 1.4; word-break: break-word; }
.note-item .note-actions { display: flex; gap: 6px; justify-content: flex-end; margin-top: 6px; }
.note-item .note-actions .btn-icon { width: 26px; height: 26px; font-size: 11px; }

/* ============================================================
   SEKME MENÜSÜ
   ============================================================ */
.tab-nav { display: flex; gap: 4px; margin-bottom: 20px; border-bottom: 2px solid var(--border); }
.tab-btn {
    padding: 12px 20px; background: none; border: none; cursor: pointer;
    font-weight: 700; font-size: 14px; color: var(--text-muted);
    border-bottom: 3px solid transparent; margin-bottom: -2px;
    display: flex; align-items: center; gap: 8px; transition: color 0.15s;
}
.tab-btn:hover { color: var(--primary); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ============================================================
   PDF EXPORT BUTONU
   ============================================================ */
.pdf-export-row { display: flex; align-items: center; gap: 14px; margin-top: 16px; flex-wrap: wrap; }
.btn-pdf { background: var(--danger); }
.btn-pdf:hover { background: #a5322a; }
.pdf-export-hint { font-size: 12px; color: var(--text-muted); }

/* ============================================================
   KREDİ KARTLARI
   ============================================================ */
.cc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; margin-top: 16px; }
.cc-item {
    background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow);
    overflow: hidden; display: flex; flex-direction: column;
}
.cc-visual {
    padding: 20px; min-height: 160px; color: #fff;
    display: flex; flex-direction: column; justify-content: space-between;
}
.cc-top { display: flex; justify-content: space-between; align-items: flex-start; }
.cc-bank { font-weight: 800; font-size: 15px; letter-spacing: 0.5px; }
.cc-chip-icon { font-size: 24px; opacity: 0.85; }
.cc-number { font-size: 17px; letter-spacing: 2px; font-family: monospace; margin: 14px 0 8px; }
.cc-holder { font-size: 12px; text-transform: uppercase; opacity: 0.9; letter-spacing: 1px; font-weight: 700; }
.cc-name-tag { font-size: 11px; opacity: 0.8; margin-top: 2px; }

.cc-theme-navy { background: linear-gradient(135deg, #1e3a5f, #2f5a8f); }
.cc-theme-gold { background: linear-gradient(135deg, #8a6d1a, #d4af37); }
.cc-theme-black { background: linear-gradient(135deg, #1a1a1a, #3f3f3f); }
.cc-theme-emerald { background: linear-gradient(135deg, #0f5132, #1e8e5a); }
.cc-theme-burgundy { background: linear-gradient(135deg, #5c1a2b, #8e1e3a); }
.cc-theme-silver { background: linear-gradient(135deg, #6b7280, #9ca3af); }

.cc-details { padding: 16px; display: flex; flex-direction: column; gap: 8px; font-size: 13px; flex: 1; }
.cc-detail-row { display: flex; justify-content: space-between; gap: 8px; }
.cc-detail-row .label { color: var(--text-muted); }
.cc-detail-row .value { font-weight: 700; text-align: right; }
.cc-note {
    font-size: 12px; color: var(--text-muted); font-style: italic;
    border-top: 1px dashed var(--border); padding-top: 8px; margin-top: 4px;
}
.cc-actions { display: flex; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--border); }
.cc-actions .btn { flex: 1; }

/* ============================================================
   MODAL (Kredi Kartı Ekle/Düzenle)
   ============================================================ */
.modal-overlay {
    position: fixed; inset: 0; background: rgba(15, 23, 42, 0.55);
    display: flex; align-items: center; justify-content: center;
    z-index: 100; padding: 20px;
}
.modal-box {
    background: #fff; border-radius: 14px; max-width: 540px; width: 100%;
    max-height: 90vh; overflow-y: auto; padding: 26px; box-shadow: var(--shadow-lg);
}
.modal-box h3 { font-size: 17px; font-weight: 800; margin-bottom: 18px; display: flex; align-items: center; gap: 8px; }
.modal-box h3 i { color: var(--primary-light); }
.modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.modal-grid .full { grid-column: 1 / -1; }
.modal-actions { display: flex; gap: 10px; margin-top: 20px; }
.modal-divider { border: none; border-top: 1px solid var(--border); margin: 22px 0; }
.modal-box h4 { font-size: 14px; font-weight: 700; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.modal-box h4 i { color: var(--primary-light); }

/* ---- Avatar Yükleme ---- */
.avatar-upload-row { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.avatar-preview {
    width: 72px; height: 72px; border-radius: 50%; overflow: hidden;
    background: #f3f4f6; display: flex; align-items: center; justify-content: center;
    border: 2px solid var(--border); flex-shrink: 0;
}
.avatar-preview img { width: 100%; height: 100%; object-fit: cover; }
.avatar-preview i { font-size: 40px; color: var(--text-muted); }
.avatar-upload-actions { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }

/* ============================================================
   ANA İÇERİK / LAYOUT
   ============================================================ */
.container { max-width: 1400px; margin: 0 auto; padding: 24px; }

.summary-cards {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px; margin-bottom: 24px;
}
.summary-card {
    background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow);
    padding: 18px; display: flex; align-items: center; gap: 14px;
    border-left: 4px solid var(--border);
}
.summary-card.income { border-left-color: var(--success); }
.summary-card.expense { border-left-color: var(--danger); }
.summary-card.balance { border-left-color: var(--primary); }
.summary-card.count { border-left-color: var(--accent); }
.summary-icon {
    width: 44px; height: 44px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center; font-size: 18px;
    background: #f3f4f6; color: var(--text-muted);
}
.summary-card.income .summary-icon { background: var(--success-bg); color: var(--success); }
.summary-card.expense .summary-icon { background: var(--danger-bg); color: var(--danger); }
.summary-card.balance .summary-icon { background: #eaf1fb; color: var(--primary); }
.summary-card.count .summary-icon { background: #fdf3dd; color: var(--accent); }
.summary-label { display: block; font-size: 12px; color: var(--text-muted); font-weight: 600; }
.summary-value { display: block; font-size: 19px; font-weight: 800; margin-top: 2px; }

.panel-grid { display: grid; grid-template-columns: 340px 1fr; gap: 20px; align-items: start; }

.card {
    background: var(--bg-card); border-radius: var(--radius);
    box-shadow: var(--shadow); padding: 22px;
}
.card h2 { font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 8px; margin-bottom: 18px; }
.card h2 i { color: var(--primary-light); }

.form-card { position: sticky; top: 88px; }
.form-actions { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }

/* ============================================================
   LİSTE / FİLTRE ALANI
   ============================================================ */
.list-header { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.list-header h2 { margin-bottom: 0; }

.search-box {
    display: flex; align-items: center; gap: 8px;
    border: 1.5px solid var(--border); border-radius: 8px;
    padding: 9px 12px; min-width: 220px;
}
.search-box i { color: var(--text-muted); font-size: 13px; }
.search-box input { border: none; padding: 0; font-size: 13.5px; }
.search-box input:focus { box-shadow: none; }

.filters {
    display: flex; flex-wrap: wrap; align-items: end; gap: 12px;
    background: #f9fafb; border: 1px solid var(--border); border-radius: 8px;
    padding: 14px; margin-bottom: 18px;
}
.filter-group { display: flex; flex-direction: column; gap: 5px; min-width: 150px; }
.filter-group label { font-size: 11.5px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.4px; }
.filter-group input, .filter-group select { padding: 8px 10px; font-size: 13px; }

/* ============================================================
   TABLO
   ============================================================ */
.table-wrapper { overflow-x: auto; min-height: 160px; position: relative; }
.data-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.data-table th {
    text-align: left; padding: 11px 12px; background: #f9fafb;
    font-weight: 700; color: var(--text-muted); font-size: 11.5px;
    text-transform: uppercase; letter-spacing: 0.4px;
    border-bottom: 2px solid var(--border); white-space: nowrap;
}
.data-table td { padding: 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.data-table tbody tr:hover { background: #fafbfc; }
.text-right { text-align: right; }
.text-center { text-align: center; }

.amount-positive { color: var(--success); font-weight: 700; }
.amount-negative { color: var(--danger); font-weight: 700; }

.type-badge {
    display: inline-block; padding: 4px 10px; border-radius: 20px;
    background: #eaf1fb; color: var(--primary); font-size: 11.5px; font-weight: 700;
}

.owner-tag { font-size: 11px; color: var(--text-muted); }
.owner-tag.is-me { color: var(--primary); font-weight: 700; }

.edited-tag {
    display: block; font-size: 10.5px; color: var(--text-muted); font-style: italic;
    margin-top: 3px;
}
.edited-tag i { font-size: 9px; margin-right: 3px; }

.row-actions { display: flex; gap: 6px; justify-content: center; }

.empty-state, .loading-state {
    text-align: center; padding: 50px 20px; color: var(--text-muted);
}
.empty-state i, .loading-state i { font-size: 32px; margin-bottom: 10px; display: block; opacity: 0.5; }

/* ============================================================
   SAYFALAMA
   ============================================================ */
.pagination { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 18px; flex-wrap: wrap; }
.pagination button {
    min-width: 34px; height: 34px; border-radius: 7px;
    border: 1.5px solid var(--border); background: #fff; cursor: pointer;
    font-size: 13px; font-weight: 600; color: var(--text-main);
}
.pagination button.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.pagination button:disabled { opacity: 0.4; cursor: not-allowed; }
.pagination button:hover:not(:disabled):not(.active) { background: #f3f4f6; }

/* ============================================================
   GLOBAL ARAMA (TOPBAR)
   ============================================================ */
.global-search-wrapper { position: relative; flex: 1; max-width: 420px; margin: 0 20px; }
.global-search-box { background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,0.25); }
.global-search-box i { color: rgba(255,255,255,0.7); }
.global-search-box input { background: transparent; color: #fff; }
.global-search-box input::placeholder { color: rgba(255,255,255,0.6); }
.global-search-results {
    position: absolute; top: calc(100% + 6px); left: 0; right: 0;
    background: #fff; border-radius: 10px; box-shadow: var(--shadow-lg);
    max-height: 420px; overflow-y: auto; z-index: 50; color: var(--text-main);
}
.gsr-item {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    padding: 11px 14px; cursor: pointer; border-bottom: 1px solid var(--border); font-size: 13.5px;
}
.gsr-item:last-child { border-bottom: none; }
.gsr-item:hover { background: #f3f4f6; }
.gsr-item .gsr-title { font-weight: 600; }
.gsr-item .gsr-meta { font-size: 11.5px; color: var(--text-muted); }
.gsr-item .type-badge { flex-shrink: 0; }
.gsr-empty { padding: 16px; text-align: center; color: var(--text-muted); font-size: 13px; }
.gsr-footer {
    padding: 10px 14px; font-size: 12px; color: var(--text-muted); text-align: center;
    background: #f9fafb; border-top: 1px solid var(--border); cursor: pointer;
    position: sticky; bottom: 0;
}
.gsr-footer:hover { background: #f3f4f6; color: var(--primary); }
.gsr-footer i { margin-right: 4px; }
.gsr-footer kbd {
    font-family: inherit; font-size: 11px; font-weight: 700;
    background: #fff; border: 1px solid var(--border); border-bottom-width: 2px;
    border-radius: 4px; padding: 1px 6px; color: var(--text-main);
}

/* ============================================================
   DURUM MERKEZİ
   ============================================================ */
.status-center { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; }
.status-chip {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 9px 14px; border-radius: 20px; font-size: 13px; font-weight: 700;
    cursor: pointer; border: 1.5px solid transparent; transition: transform 0.1s;
}
.status-chip:hover { transform: translateY(-1px); }
.status-chip.kirmizi { background: var(--danger-bg); color: var(--danger); }
.status-chip.sari { background: #fdf3dd; color: #92650b; }
.status-chip.yesil { background: var(--success-bg); color: var(--success); }

/* ============================================================
   SEKME İÇİ ALT SEKMELER (Yönetim modülü)
   ============================================================ */
.sub-tab-nav { display: flex; gap: 6px; margin-bottom: 18px; flex-wrap: wrap; border-bottom: 1px solid var(--border); padding-bottom: 10px; }
.sub-tab-btn {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 8px 14px; border-radius: 8px; border: none; background: #f3f4f6;
    color: var(--text-muted); font-size: 13px; font-weight: 700; cursor: pointer; transition: all 0.15s;
}
.sub-tab-btn:hover { background: #e5e7eb; }
.sub-tab-btn.active { background: var(--primary); color: #fff; }
.sub-tab-panel { display: none; }
.sub-tab-panel.active { display: block; }

/* ============================================================
   BASİT LİSTE (Notlar / Hatırlatıcılar / Görevler)
   ============================================================ */
.simple-list { display: flex; flex-direction: column; gap: 10px; }
.simple-item {
    border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px;
    display: flex; flex-direction: column; gap: 6px; position: relative;
}
.simple-item.is-done { opacity: 0.6; }
.simple-item .si-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.simple-item .si-title { font-weight: 700; font-size: 14.5px; }
.simple-item .si-title.strike { text-decoration: line-through; }
.simple-item .si-desc { font-size: 13px; color: var(--text-muted); }
.simple-item .si-meta { display: flex; gap: 10px; flex-wrap: wrap; font-size: 11.5px; color: var(--text-muted); align-items: center; }
.simple-item .si-actions { display: flex; gap: 6px; flex-shrink: 0; }

.priority-badge { display: inline-block; padding: 3px 9px; border-radius: 20px; font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.3px; }
.priority-badge.normal { background: #eaf1fb; color: var(--primary); }
.priority-badge.onemli { background: #fdf3dd; color: #92650b; }
.priority-badge.acil { background: var(--danger-bg); color: var(--danger); }

.status-badge { display: inline-block; padding: 3px 9px; border-radius: 20px; font-size: 10.5px; font-weight: 800; }
.status-badge.bekliyor { background: #f3f4f6; color: var(--text-muted); }
.status-badge.devam { background: #eaf1fb; color: var(--primary); }
.status-badge.tamamlandi { background: var(--success-bg); color: var(--success); }
.status-badge.satilik { background: var(--success-bg); color: var(--success); }
.status-badge.rezerve { background: #fdf3dd; color: #92650b; }
.status-badge.satildi { background: #eaf1fb; color: var(--primary); }

.due-tag { font-weight: 700; }
.due-tag.overdue { color: var(--danger); }
.due-tag.upcoming { color: #92650b; }

/* ============================================================
   REHBER (Firma / Kişi Kartları)
   ============================================================ */
.contact-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.contact-card { border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; cursor: pointer; transition: box-shadow 0.15s; }
.contact-card:hover { box-shadow: var(--shadow); }
.contact-card .cc-name { font-weight: 700; font-size: 14.5px; margin-bottom: 6px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.contact-card .cc-sub { font-size: 12px; color: var(--text-muted); margin-bottom: 8px; }
.contact-card .cc-links { display: flex; gap: 8px; flex-wrap: wrap; }
.contact-card .cc-link {
    display: inline-flex; align-items: center; gap: 5px; font-size: 12px;
    padding: 5px 10px; border-radius: 6px; background: #f3f4f6; color: var(--text-main); text-decoration: none;
}
.contact-card .cc-link.whatsapp { background: #e5f9ef; color: #1e8e5a; }
.contact-card .cc-link.call { background: #eaf1fb; color: var(--primary); }
.contact-card .cc-actions { display: flex; gap: 6px; margin-top: 10px; justify-content: flex-end; }

/* ============================================================
   ŞANTİYE KARTLARI
   ============================================================ */
.project-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.project-card { border: 1px solid var(--border); border-radius: 12px; padding: 16px 18px; }
.project-card .pc-name { font-weight: 800; font-size: 15px; margin-bottom: 4px; }
.project-card .pc-address { font-size: 12.5px; color: var(--text-muted); margin-bottom: 10px; min-height: 16px; }
.project-card .pc-badges { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.project-card .pc-badge { font-size: 11px; padding: 4px 9px; border-radius: 20px; background: #f3f4f6; color: var(--text-muted); font-weight: 700; }
.project-card .pc-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.project-card .pc-actions .btn { flex: 1; min-width: 100px; }

.villa-summary { display: flex; gap: 8px; flex-wrap: wrap; }
.villa-summary .vs-chip { font-size: 12px; padding: 5px 11px; border-radius: 20px; font-weight: 700; }

/* ============================================================
   FOTOĞRAF GÜNLÜĞÜ
   ============================================================ */
.photo-group-title { font-size: 13px; font-weight: 800; color: var(--text-muted); margin: 16px 0 10px; text-transform: uppercase; letter-spacing: 0.4px; }
.photo-group-title:first-child { margin-top: 0; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.photo-thumb { position: relative; border-radius: 8px; overflow: hidden; aspect-ratio: 1/1; cursor: pointer; background: #f3f4f6; }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; }
.photo-thumb .pt-delete {
    position: absolute; top: 5px; right: 5px; width: 24px; height: 24px; border-radius: 50%;
    background: rgba(192,57,43,0.9); color: #fff; border: none; cursor: pointer; font-size: 11px;
}
.photo-viewer-box { max-width: 90vw; max-height: 90vh; text-align: center; }
.photo-viewer-box img { max-width: 100%; max-height: 75vh; border-radius: 10px; margin-bottom: 10px; }
.photo-viewer-box p { color: #fff; margin-bottom: 12px; }
.photo-viewer-box .btn { max-width: 220px; margin: 0 auto; }

/* ============================================================
   YÖNETİCİ İSTATİSTİKLERİ
   ============================================================ */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.stat-card { border: 1px solid var(--border); border-radius: 10px; padding: 16px; }
.stat-card .sc-name { font-weight: 800; font-size: 14px; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.stat-card .sc-name i { color: var(--primary-light); }
.stat-row { display: flex; justify-content: space-between; font-size: 12.5px; padding: 5px 0; border-bottom: 1px dashed var(--border); }
.stat-row:last-child { border-bottom: none; }
.stat-row .value { font-weight: 700; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px) {
    .panel-grid { grid-template-columns: 1fr; }
    .form-card { position: static; }
}

@media (max-width: 600px) {
    .container { padding: 14px; }
    .topbar { padding: 12px 16px; }
    .card { padding: 16px; }
    .filters { flex-direction: column; align-items: stretch; }
    .filter-group { min-width: unset; }
    .list-header { flex-direction: column; align-items: stretch; }
    .search-box { min-width: unset; }
    .summary-cards { grid-template-columns: 1fr 1fr; }
    .notification-dropdown { position: fixed; top: 64px; right: 10px; left: 10px; width: auto; }
    .note-input-row { flex-direction: column; }
    .note-input-row .btn { width: 100%; }
    .cc-grid { grid-template-columns: 1fr; }
    .modal-grid { grid-template-columns: 1fr; }
    .tab-nav { overflow-x: auto; }
    .pdf-export-row { flex-direction: column; align-items: stretch; }
    .topbar { flex-wrap: wrap; row-gap: 10px; }
    .global-search-wrapper { order: 3; max-width: 100%; width: 100%; margin: 0; flex-basis: 100%; }
    .sub-tab-nav { overflow-x: auto; flex-wrap: nowrap; }
    .contact-grid, .project-grid, .stats-grid { grid-template-columns: 1fr; }
    .simple-item .si-top { flex-direction: column; }
}

@media (max-width: 980px) {
    .global-search-wrapper { max-width: 260px; margin: 0 10px; }
}

/* ============================================================
   ARAMA SONUÇLARI SAYFASI (search.php)
   ============================================================ */
.topbar-brand-link { color: #fff; text-decoration: none; }

.search-page { max-width: 900px; }
.search-page-head { margin-bottom: 18px; }
.search-page-head h1 { font-size: 22px; font-weight: 800; word-break: break-word; }
.search-page-head p { color: var(--text-muted); font-size: 14px; margin-top: 4px; }

.search-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.search-chip {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 7px 14px; border-radius: 20px; cursor: pointer;
    border: 1.5px solid var(--border); background: #fff;
    font-family: inherit; font-size: 13px; font-weight: 600; color: var(--text-main);
    transition: all 0.15s;
}
.search-chip i { color: var(--primary-light); font-size: 12px; }
.search-chip:hover { background: #f3f4f6; }
.search-chip.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.search-chip.active i { color: #fff; }
.search-chip .chip-count {
    background: #eaf1fb; color: var(--primary); border-radius: 10px;
    padding: 0 7px; font-size: 11.5px; font-weight: 700;
}
.search-chip.active .chip-count { background: rgba(255,255,255,0.22); color: #fff; }

.search-group { margin-bottom: 16px; }
.search-group h2 { margin-bottom: 10px; }
.search-group-count {
    margin-left: auto; background: #eaf1fb; color: var(--primary);
    border-radius: 10px; padding: 1px 9px; font-size: 12px; font-weight: 700;
}

.search-list { display: flex; flex-direction: column; }
.search-row {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 8px; border-bottom: 1px solid var(--border);
    color: inherit; text-decoration: none; border-radius: 6px;
    transition: background 0.12s;
}
.search-row:last-child { border-bottom: none; }
.search-row:hover { background: #f3f6fb; }
.search-row-icon {
    width: 36px; height: 36px; border-radius: 9px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    background: #eaf1fb; color: var(--primary); font-size: 14px;
}
.search-row-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.search-row-title { font-weight: 600; font-size: 14px; word-break: break-word; }
.search-row mark { background: #fdf3dd; color: inherit; border-radius: 3px; padding: 0 2px; }
.search-row-meta { font-size: 12px; color: var(--text-muted); margin-top: 1px; }
.search-row-arrow { color: var(--text-muted); font-size: 12px; opacity: 0.6; }
.search-row:hover .search-row-arrow { opacity: 1; transform: translateX(2px); }
.search-limit-note { margin-top: 10px; font-size: 12px; color: var(--text-muted); text-align: center; }

@media (max-width: 720px) {
    .search-page-head h1 { font-size: 18px; }
    .topbar-user .btn-sm { padding: 7px 10px; }
}


/* ============================================================
   ARAMA SONUCU VURGUSU (tıklanan kayda gidildiğinde kısa süre yanıp söner)
   ============================================================ */
@keyframes searchFlash {
    0%, 55% { background-color: #fdf3dd; box-shadow: 0 0 0 3px var(--accent); }
    100%    { box-shadow: 0 0 0 0 rgba(212, 160, 23, 0); }
}
@keyframes searchFlashCell {
    0%, 55% { background-color: #fdf3dd; }
}
.search-highlight { animation: searchFlash 3.4s ease-out; border-radius: 8px; }
tr.search-highlight { animation: none; }
tr.search-highlight > td { animation: searchFlashCell 3.4s ease-out; }


/* ---- Kırmızı uyarılı bildirim çanı + kart ödeme uyarısı ---- */
@keyframes bellRing { 0%,100%{transform:rotate(0)} 10%,30%,50%{transform:rotate(-14deg)} 20%,40%,60%{transform:rotate(14deg)} 70%{transform:rotate(0)} }
@keyframes bellPulse { 0%{box-shadow:0 0 0 0 rgba(231,76,60,.75)} 100%{box-shadow:0 0 0 12px rgba(231,76,60,0)} }
.notification-bell.has-alert { background: #c0392b; animation: bellRing 2.4s infinite, bellPulse 1.4s infinite; }
.notification-bell.has-alert:hover { background: #a93226; }
.notification-item.alert-type { background: #fdecea; border-left: 4px solid #c0392b; }
.notification-item.alert-type .notif-icon { background: #c0392b; color: #fff; }
.cc-due-alert { color: #c0392b; margin-left: 6px; animation: bellPulse 1.4s infinite; }

/* ============================================================
   [v6] Onay durumu (kırmızı / yeşil), iptal, değişiklik kaydı
   ============================================================ */
.data-table tbody tr.row-pending { background: #fdecec; }
.data-table tbody tr.row-pending:hover { background: #fbdcdc; }
.data-table tbody tr.row-pending td:first-child { box-shadow: inset 4px 0 0 #c0392b; }
.data-table tbody tr.row-approved td:first-child { box-shadow: inset 4px 0 0 #2e9e5b; }
.data-table tbody tr.row-cancelled { background: #f4f4f4; color: #999; }
.data-table tbody tr.row-cancelled td { text-decoration: line-through; text-decoration-color: #b0b0b0; }
.data-table tbody tr.row-cancelled td:last-child,
.data-table tbody tr.row-cancelled .cancel-info { text-decoration: none; }
.status-badge { display: inline-block; margin-top: 4px; padding: 2px 7px; border-radius: 10px; font-size: 10.5px; font-weight: 700; white-space: nowrap; }
.status-badge.pending { background: #c0392b; color: #fff; }
.status-badge.approved { background: #e3f5ea; color: #1e7a45; }
.status-badge.cancelled { background: #e0e0e0; color: #666; }
.cancel-info { color: #a33 !important; }
.btn-icon.approve { background: #e3f5ea; color: #1e7a45; }
.btn-icon.history { background: #f1eefc; color: #5b4bb7; }
.pending-banner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px;
    margin: 0 0 12px; padding: 10px 14px; border-radius: 10px; background: #fdecec; border: 1px solid #f3b9b4; color: #8e231a; font-size: 13.5px; }
.pending-banner .pending-actions { display: flex; gap: 8px; }
.admin-tools { display: flex; justify-content: flex-end; margin: 0 0 10px; }
.sum-note { font-weight: 500; font-size: 10px; opacity: .7; text-transform: none; }
.log-table td, .log-table th { font-size: 12.5px; padding: 7px 8px; }
.log-table tr.log-iptal td { color: #a33; }
.log-table tr.log-onay td { color: #1e7a45; }
.log-table tr.log-kalici_sil td { color: #7a0000; font-weight: 600; }

/* ============================================================
   [v7] HAKEDİŞ
   ============================================================ */
.hk-toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
.hk-toolbar select { padding: 9px 12px; border: 1px solid var(--border); border-radius: 8px; font-size: 14px; min-width: 220px; background: #fff; }
.hk-summary { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.hk-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 14px; }
.hk-card { background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; cursor: pointer; border-left: 5px solid var(--success); transition: box-shadow .15s; }
.hk-card:hover { box-shadow: var(--shadow-lg); }
.hk-card.overpaid { border-left-color: var(--danger); background: #fffafa; }
.hk-card.cancelled { opacity: .55; border-left-color: #9ca3af; }
.hk-head { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.hk-head strong { font-size: 15px; color: var(--primary); }
.muted { color: var(--text-muted); font-size: 12.5px; }
.hk-bar { position: relative; height: 18px; background: #eef1f5; border-radius: 9px; margin: 12px 0; overflow: hidden; }
.hk-bar div { height: 100%; background: linear-gradient(90deg, var(--primary-light), var(--success)); }
.hk-bar span { position: absolute; inset: 0; font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center; color: var(--text-main); }
.hk-nums { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; font-weight: 700; font-size: 14px; }
.hk-nums small { display: block; font-weight: 600; font-size: 11px; color: var(--text-muted); }
.hk-nums.big { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); background: #f7f9fc; padding: 12px; border-radius: 8px; font-size: 15px; }
.hk-bal { color: var(--success); }
.hk-bal.neg, .hk-red { color: var(--danger); font-weight: 700; }
.hk-alert { margin-top: 10px; padding: 10px 12px; border-radius: 8px; background: var(--danger-bg); color: var(--danger); font-size: 13.5px; }
.hk-alert.soft { background: #fdf3dd; color: #92650b; }
.hk-modal { max-width: 980px !important; width: 96vw; max-height: 92vh; overflow-y: auto; }
.hk-sub { margin: 18px 0 8px; font-size: 14px; color: var(--primary); display: flex; gap: 6px; align-items: center; }
.hk-table { font-size: 13px; }
.hk-table td, .hk-table th { padding: 7px 8px; }
.hk-items input { width: 100%; padding: 6px 8px; border: 1px solid var(--border); border-radius: 6px; font-size: 13px; }
.hk-prog-form { display: grid; grid-template-columns: 2fr 1fr 1fr 2fr auto; gap: 8px; }
.hk-prog-form input, .hk-prog-form select { padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; font-size: 13px; }
.hk-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.hk-logs { margin-top: 14px; font-size: 12.5px; }
.hk-logs summary { cursor: pointer; color: var(--primary); font-weight: 700; }
.hk-link:hover { filter: brightness(.95); text-decoration: underline; }
@media (max-width: 720px) {
    .hk-list { grid-template-columns: 1fr; }
    .hk-prog-form { grid-template-columns: 1fr 1fr; }
    .hk-prog-form button { grid-column: 1 / -1; }
}
#hkPendingBanner { justify-content: flex-start; }

/* ============================================================
   [v8] SATIŞ / NAKİT AKIŞI / DEVLET / PERSONEL / PDF / BELGELER
   ============================================================ */
.tab-nav { overflow-x: auto; scrollbar-width: thin; }
.tab-btn { white-space: nowrap; padding: 12px 14px; }
.btn-pdf-lite { background: #fdecea; color: var(--danger); }
.btn-pdf-lite:hover { background: #fbd9d5; }
.btn-success { background: #25a35a; color: #fff; }
.btn-success:hover { background: #1e8e4d; }
.pk-choices { display: grid; gap: 10px; margin: 6px 0 10px; }
.pk-choices .btn { justify-content: center; font-size: 15px; padding: 12px; }
.summary-value.sm { font-size: 14px; }
.status-badge.pending-soft { background: #fdf3dd; color: #92650b; }
.status-badge.wait { background: #eef1f5; color: #555; }

.sl-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.sl-card { background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; cursor: pointer; border-top: 5px solid #9ca3af; }
.sl-card:hover { box-shadow: var(--shadow-lg); }
.sl-card.st-sale { border-top-color: var(--success); }
.sl-card.st-res { border-top-color: var(--accent); }
.sl-card.st-sold { border-top-color: var(--primary-light); }
.sl-card.late { background: #fff6f5; border-top-color: var(--danger); }
.sl-top { display: flex; justify-content: space-between; align-items: center; }
.sl-top strong { font-size: 16px; color: var(--primary); }
.sl-st { font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 10px; background: #eef1f5; }
.st-sale .sl-st { background: var(--success-bg); color: var(--success); }
.st-res .sl-st { background: #fdf3dd; color: #92650b; }
.st-sold .sl-st { background: #eaf1fb; color: var(--primary); }
.sl-st-inline { font-size: 12px; font-weight: 700; background: #eaf1fb; color: var(--primary); padding: 2px 8px; border-radius: 10px; margin-left: 6px; }
.sl-nums { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; font-weight: 700; font-size: 13px; margin-bottom: 4px; }
.sl-nums small { display: block; font-weight: 600; font-size: 11px; color: var(--text-muted); }
.sl-info { display: flex; flex-wrap: wrap; gap: 20px; margin-bottom: 10px; font-size: 14px; }
.sl-info small { display: block; color: var(--text-muted); font-size: 11px; }
.sl-gen { display: grid; grid-template-columns: repeat(4, 1fr) auto; gap: 8px; align-items: end; background: #f7f9fc; padding: 10px; border-radius: 8px; }
.sl-gen label { font-size: 12px; font-weight: 600; color: var(--text-muted); display: flex; flex-direction: column; gap: 4px; }
.sl-gen input { padding: 7px 9px; border: 1px solid var(--border); border-radius: 6px; font-size: 13px; }
.hk-items select { width: 100%; padding: 6px; border: 1px solid var(--border); border-radius: 6px; font-size: 13px; }

.nk-table tr.nk-now td { background: #f1f7ff; }
.nk-table tr.nk-past td { color: #555; }
.nk-barcell { width: 120px; }
.nk-bar { height: 10px; border-radius: 5px; background: var(--success); min-width: 2px; }
.nk-bar.neg { background: var(--danger); }
.src-badge { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 10px; white-space: nowrap; }
.src-in { background: var(--success-bg); color: var(--success); }
.src-out { background: #eaf1fb; color: var(--primary); }
.src-gov { background: #f1eefc; color: #5b4bb7; }
.src-oth { background: #f3f4f6; color: #555; }

.gv-cats { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.gv-cat { background: var(--bg-card); box-shadow: var(--shadow); border-radius: 8px; padding: 8px 12px; display: flex; flex-direction: column; min-width: 170px; }
.gv-cat span { font-weight: 800; color: var(--primary); }
.gv-cat small { color: var(--text-muted); font-size: 11px; }

.doc-upload { display: grid; grid-template-columns: 1fr 2fr auto; gap: 8px; margin-bottom: 10px; }
.doc-upload select, .doc-upload input[type=text] { padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; font-size: 13px; }
.doc-pick { cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.doc-list { display: grid; gap: 6px; }
.doc-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; background: #f7f9fc; border-radius: 8px; }
.doc-item > i { font-size: 20px; color: var(--danger); }
.doc-item .fa-file-image { color: var(--primary-light); }
.doc-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.doc-meta a { color: var(--text-main); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-meta a:hover { text-decoration: underline; }
.ps-leave { grid-template-columns: 1.3fr 1fr 1fr .6fr 1.5fr auto; }
label.chk { display: flex; align-items: center; gap: 8px; cursor: pointer; }
@media (max-width: 720px) {
    .sl-gen { grid-template-columns: 1fr 1fr; }
    .doc-upload { grid-template-columns: 1fr; }
    .ps-leave { grid-template-columns: 1fr 1fr; }
    .nk-barcell { display: none; }
}

/* ============================================================
   [v9] TARIM
   ============================================================ */
.tab-btn.tab-farm { color: #4d7c0f; }
.tab-btn.tab-farm.active { color: #3f6212; border-bottom-color: #4d7c0f; }
.farm-note { background: #f0f7e6; color: #3f6212; border: 1px solid #cfe3b0; padding: 8px 12px; border-radius: 8px; font-size: 13px; margin-bottom: 12px; }
#tab-tarim .summary-card small { display: block; font-size: 11px; }
.tm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.tm-form { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px 10px; text-align: left; }
.tm-form .tm-full { grid-column: 1 / -1; }
.tm-lab { display: flex; flex-direction: column; font-size: 12px; font-weight: 600; color: var(--text-muted); }
.tm-in { margin: 4px 0 6px !important; width: 100% !important; height: 2.4em !important; font-size: 14px !important; padding: 0 8px !important; box-sizing: border-box; }
select.tm-in { display: block !important; }
@media (max-width: 720px) { .tm-grid { grid-template-columns: 1fr; } .tm-form { grid-template-columns: 1fr 1fr; } }

/* ============================================================
   [v10] OKUNURLUK: daha büyük yazı, sade görünüm, tarım kartları
   ============================================================ */
body { font-size: 15px; }
.tab-btn { font-size: 15px; }
.tab-help { background: #eef4fb; color: #1e3a5f; border-radius: 8px; padding: 10px 14px; font-size: 14.5px; margin: 0 0 14px; line-height: 1.5; }
.tab-help.farm { background: #f0f7e6; color: #3f6212; }
.tab-help i { margin-right: 4px; }
.summary-label { font-size: 13px !important; }
.summary-value { font-size: 21px !important; }
.summary-value.sm { font-size: 15px !important; }
.hk-table { font-size: 14.5px; }
.hk-table td, .hk-table th { padding: 9px 10px; }
.data-table th { font-size: 12.5px; letter-spacing: .2px; }
.btn { font-size: 14.5px; }
.btn-sm { font-size: 13.5px; }
.hk-sub { font-size: 16px; margin-top: 22px; }
.hk-nums { font-size: 15px; }
.hk-nums small, .sl-nums small { font-size: 12px; }
.muted { font-size: 13.5px; }
.status-badge { font-size: 12px; padding: 3px 9px; }
.modal-box h3 { font-size: 19px; }
.swal2-popup { font-size: 1.05rem !important; }
.tc-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; margin-bottom: 10px; }
.tc-card { background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; border-left: 5px solid #4d7c0f; }
.tc-card.late { border-left-color: var(--danger); background: #fff6f5; }
.tc-card.cancelled { opacity: .55; }
.tc-top { display: flex; justify-content: space-between; align-items: flex-start; }
.tc-top strong { font-size: 16px; color: #3f6212; }
.tc-debt { font-size: 22px; font-weight: 800; margin: 8px 0; }
.tc-debt small { display: block; font-size: 12px; font-weight: 600; color: var(--text-muted); }
button, input, select, textarea { font-family: inherit; }

/* ================= [v11] KASA ================= */
.ks-h { font-size: 16px; margin: 18px 0 8px; color: var(--text, #222); }
.ks-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.ks-card { display: flex; gap: 12px; align-items: center; background: #fff; border: 1px solid var(--border); border-left: 6px solid var(--c); border-radius: 10px; padding: 14px; }
.ks-card > i { font-size: 26px; color: var(--c); width: 32px; text-align: center; }
.ks-card span { display: block; font-size: 13px; color: #666; }
.ks-card strong { display: block; font-size: 20px; }
.ks-card small { display: block; font-size: 12px; color: #777; }
.ks-in { color: #1e8e5a; font-weight: 600; white-space: nowrap; }
.ks-out { color: #c0392b; font-weight: 600; white-space: nowrap; }
.ks-lbl { display: block; text-align: left; width: 85%; margin: 10px auto 0; font-size: 14px; font-weight: 600; }
.ks-check { display: flex !important; gap: 8px; align-items: center; cursor: pointer; font-weight: 600; }
.ks-check input { width: 20px; height: 20px; }
.ks-pop .swal2-html-container { overflow-x: hidden; padding: 0 1.4em; }
.ks-pop .swal2-input, .ks-pop .swal2-select { display: block; width: 100%; max-width: 100%; margin: 6px 0; box-sizing: border-box; height: 2.8em; }
.ks-pop .ks-lbl { width: 100%; margin: 12px 0 0; }

/* ================= [v12] KİM ÖDEDİ / NASIL ================= */
.pay-badge { display: inline-block; margin: 4px 0 0 6px; padding: 2px 8px; border-radius: 10px; background: #eef4ff; color: #234; font-size: 12px; }
.pay-badge b { font-weight: 700; }
.pay-lbl { display: block; text-align: left; width: 85%; margin: 10px auto 0; font-size: 14px; font-weight: 600; }
.swal2-popup .pay-in { display: block; width: 85%; max-width: 85%; margin: 4px auto; box-sizing: border-box; }

/* ================= [v12] ORTAKLAR ================= */
.or-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.or-card { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 6px; }
.or-head { display: flex; gap: 8px; align-items: center; font-size: 18px; margin-bottom: 4px; }
.or-head .muted { margin-left: auto; font-size: 13px; }
.or-row { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; }
.or-row.sub { font-size: 13px; color: #666; padding-left: 8px; }
.or-result { margin: 8px 0 4px; padding: 10px; border-radius: 8px; background: #f6f7f9; text-align: center; font-size: 16px; }
.or-plus { color: #1e8e5a; }
.or-minus { color: #c0392b; }
.or-total { margin: 14px 0; font-size: 15px; }
.swal2-popup .or-in { width: 100%; margin: 2px 0; height: 2.4em; font-size: 14px; box-sizing: border-box; }

/* ===== [v15] ONAY MERKEZİ ===== */
.onay-merkezi { background:#fff4f4; border:2px solid #e05a5a; border-radius:12px; padding:14px 16px; margin:0 0 16px; }
.onay-merkezi.onay-bos { background:#f1faf4; border:1px solid #9bd3ae; color:#1e7a45; font-weight:600; padding:10px 14px; }
.onay-merkezi .onay-head { display:flex; flex-wrap:wrap; gap:10px; align-items:center; justify-content:space-between; font-size:1.05rem; }
.onay-merkezi .onay-head .fa-bell { color:#c0392b; }
.onay-merkezi .onay-head .muted { display:block; font-size:.9rem; font-weight:400; }
.onay-merkezi .onay-btns { display:flex; gap:8px; flex-wrap:wrap; }
.onay-merkezi #onayAll { font-size:1.05rem; padding:10px 18px; }
.onay-merkezi .onay-list { margin-top:12px; overflow-x:auto; }

/* ============ [v16] SİPARİŞ TAKİBİ ============ */
.sp-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 14px; margin-top: 14px; }
.sp-card { background: var(--bg-card); border: 1px solid var(--border); border-left: 5px solid #1e8e5a; border-radius: 12px; padding: 14px; cursor: pointer; transition: box-shadow .15s; }
.sp-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,.08); }
.sp-card.sp-red { border-left-color: var(--danger); }
.sp-card.sp-off { opacity: .55; }
.sp-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 8px; }
.sp-item { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: .92rem; padding: 6px 0; border-top: 1px dashed var(--border); }
.sp-item > b { flex-basis: 100%; }
.sp-got { color: #2c6fbb; }
.sp-ok { color: #1e8e5a; font-weight: 700; }
.sp-bar { height: 6px; background: var(--border); border-radius: 4px; overflow: hidden; margin: 8px 0; }
.sp-bar i { display: block; height: 100%; background: #1e8e5a; }
.sp-money { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: .88rem; }
.sp-money-big { font-size: 1rem; margin: 12px 0; padding: 10px; background: rgba(0,0,0,.03); border-radius: 8px; }
.sp-form { text-align: left; display: flex; flex-direction: column; gap: 6px; }
.sp-form label { font-weight: 600; font-size: .9rem; margin-top: 6px; }
.sp-form input, .sp-form select { padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; font: inherit; width: 100%; box-sizing: border-box; }
.sp-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.sp-ftable { width: 100%; border-collapse: collapse; }
.sp-ftable td { padding: 3px; }
.sp-ftable th { font-size: .8rem; text-align: left; }
.sp-ftotal { font-size: 1rem; margin-top: 4px; }
.sp-detail { text-align: left; }
.sp-detail h4 { margin: 16px 0 6px; }
.sp-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 12px; }
@media (max-width: 600px) { .sp-list { grid-template-columns: 1fr; } .sp-2 { grid-template-columns: 1fr; } .sp-ftable input { min-width: 60px; } }

.sp-ftable input { padding: 6px 6px !important; }
.sp-ftable .sp-i-unit { width: 78px !important; }

/* ============ [v17] FİRMA KARTI ============ */
.fk-name-link { cursor: pointer; text-decoration: underline dotted; text-underline-offset: 3px; }
.fk-name-link:hover { color: var(--primary-light); }
.fk { text-align: left; }
.fk h4 { margin: 14px 0 6px; }
.fk-sum { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; margin: 8px 0; }
.fk-sum > div { background: rgba(0,0,0,.035); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; }
.fk-sum span { font-size: .82rem; color: var(--text-muted); }
.fk-sum b { font-size: 1.15rem; }
.fk-sum .fk-due { background: var(--danger-bg); } .fk-sum .fk-due b { color: var(--danger); }
.fk-sum .fk-ok { background: var(--success-bg); } .fk-sum .fk-ok b { color: var(--success); }
.fk-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.fk-chip { border: 1px solid var(--border); background: var(--bg-card); border-radius: 20px; padding: 5px 12px; cursor: pointer; font: inherit; font-size: .85rem; }
.fk-chip:hover { border-color: var(--primary-light); }
tr.fk-link { cursor: pointer; }
.fk-card { background: var(--bg-card); border: 1px solid var(--border); border-left: 5px solid var(--primary); border-radius: 12px; padding: 14px; cursor: pointer; display: flex; flex-direction: column; gap: 4px; }
.fk-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,.08); }
.fk-name { font-size: 1.05rem; margin-bottom: 4px; }
.fk-line { display: flex; justify-content: space-between; gap: 10px; }

/* ============ [v19] FİRMA TEK SATIR + ATAÇ ============ */
.fk-table tr.fk-row { cursor: pointer; }
.fk-table tr.fk-row:hover td { background: rgba(30,58,95,.04); }
.fk-table tfoot th { border-top: 2px solid var(--border); }
.fk-det > td { background: rgba(0,0,0,.02); text-align: left; }
.fk-sec { border: 1px solid var(--border); border-radius: 10px; padding: 8px 12px; margin: 8px 0; background: var(--bg-card); }
.fk-sec > summary { cursor: pointer; font-weight: 600; }
.fk-sec[open] > summary { margin-bottom: 8px; }
.fk-src { font-size: .82rem; color: var(--text-muted); margin-top: 3px; }
.fk-clip { font-size: 1.05rem; }

/* ============ [v20] ÖN PLANLAMA ============ */
.pl-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 12px; }
.pl-chip { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 8px 12px; display: flex; flex-direction: column; min-width: 140px; }
.pl-chip span { font-size: .82rem; color: var(--text-muted); } .pl-chip small { color: var(--text-muted); }
tr.pl-grp td { background: rgba(30,58,95,.06); }

/* [v22] İşlemler: firma tek satır */
tr.tx-firm { cursor: pointer; }
tr.tx-firm td { border-top: 2px solid var(--border); }
tr.tx-firm.tx-open { background: rgba(212,160,23,.07); }
tr.tx-child td:first-child { padding-left: 22px; }
.tx-firm-sum { margin-top: 3px; }
