* { margin: 0; padding: 0; box-sizing: border-box; }

        :root {
            --bg-dark: #0f172a;
            --bg-card: #1e293b;
            --bg-table: #1e293b;
            --bg-row: #1e293b;
            --bg-row-alt: #182233;
            --bg-hover: #243447;
            --bg-modal: #1e293b;
            --bg-modal-body: #1a2332;
            --bg-info-card: #252d3d;
            --bg-green-row: #1a3a2e;
            --bg-loading: rgba(15,23,42,0.9);
            --text-primary: #e2e8f0;
            --text-secondary: #94a3b8;
            --text-muted: #64748b;
            --accent-blue: #3b82f6;
            --accent-green: #10b981;
            --accent-red: #ef4444;
            --accent-orange: #f97316;
            --border: #334155;
            --nsb-blue: #2563eb;
            --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
            --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
            --shadow-lg: 0 8px 24px rgba(0,0,0,0.5);
        }

        body {
            font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
            background: var(--bg-dark);
            color: var(--text-primary);
            min-height: 100vh;
            transition: background 0.3s, color 0.3s;
        }

        /* ===== LOADING OVERLAY ===== */
        .loading-overlay {
            position: fixed; top: 0; left: 0; right: 0; bottom: 0;
            background: var(--bg-loading); z-index: 9999;
            display: none; align-items: center; justify-content: center;
            flex-direction: column; gap: 16px;
        }
        .loading-overlay.active { display: flex; }
        .spinner {
            width: 48px; height: 48px;
            border: 3px solid var(--border);
            border-top-color: var(--accent-blue);
            border-radius: 50%;
            animation: spin 0.8s linear infinite;
        }
        @keyframes spin { to { transform: rotate(360deg); } }
        .loading-text { color: var(--text-secondary); font-size: 14px; }

        /* ===== TOAST NOTIFICATIONS ===== */
        .toast-container {
            position: fixed; top: 20px; right: 20px;
            z-index: 10000; display: flex; flex-direction: column; gap: 8px;
        }
        .toast {
            background: var(--bg-card); border: 1px solid var(--border);
            border-radius: 10px; padding: 14px 18px;
            display: flex; align-items: center; gap: 10px;
            box-shadow: var(--shadow-lg); min-width: 280px;
            animation: slideIn 0.3s ease; font-size: 13px;
        }
        @keyframes slideIn {
            from { transform: translateX(100%); opacity: 0; }
            to { transform: translateX(0); opacity: 1; }
        }
        .toast.success { border-left: 3px solid var(--accent-green); }
        .toast.error { border-left: 3px solid var(--accent-red); }
        .toast.info { border-left: 3px solid var(--accent-blue); }
        .toast-icon { font-size: 18px; }

        /* ÜST NSB BAR */
        .nsb-topbar {
            background: var(--nsb-blue); color: white;
            padding: 8px 20px; text-align: center;
            font-size: 13px; font-weight: 500;
        }
        .nsb-topbar a { color: #ffd700; text-decoration: none; font-weight: 700; }
        .nsb-topbar a[hidden] { display: none; }
        .nsb-topbar a:hover { text-decoration: underline; }

        /* HEADER */
        .main-header {
            background: var(--bg-dark); padding: 16px 24px;
            display: flex; align-items: center; justify-content: space-between;
            border-bottom: 1px solid var(--border);
        }
        .logo-section { display: flex; align-items: center; gap: 12px; }
        .logo-box {
            width: 62px; height: 62px;
            background: linear-gradient(135deg, #3b82f6 0%, #10b981 100%);
            border-radius: 16px;
            display: flex; align-items: center; justify-content: center;
            font-weight: 800; font-size: 14px; line-height: 1.2;
            text-align: center; color: white; text-decoration: none;
            box-shadow: 0 4px 12px rgba(59,130,246,0.3);
        }
        .logo-text h1 { font-size: 20px; font-weight: 700; color: var(--text-primary); letter-spacing: 1px; }
        .logo-text span { font-size: 12px; color: var(--text-secondary); }
        .header-actions { display: flex; align-items: center; gap: 12px; }
        .header-actions [hidden] { display: none; }
        .btn-export {
            background: var(--nsb-blue); color: white; border: none;
            padding: 8px 16px; border-radius: 8px; font-size: 13px;
            font-weight: 600; cursor: pointer; display: flex;
            align-items: center; gap: 6px; transition: all 0.2s;
        }
        .btn-export:hover { opacity: 0.9; transform: translateY(-1px); }
        .theme-toggle {
            width: 36px; height: 36px; border-radius: 8px;
            border: 1px solid var(--border); background: var(--bg-card);
            color: var(--text-secondary); cursor: pointer;
            display: flex; align-items: center; justify-content: center;
            font-size: 16px; transition: all 0.2s;
        }
        .theme-toggle:hover { background: var(--bg-hover); color: var(--text-primary); }

        /* REKLAM ALANI */
        .ad-section {
            padding: 16px 24px; display: flex; gap: 16px; align-items: stretch;
        }
        .nsb-ad-card {
            flex: 1; background: var(--bg-card); border: 1px solid var(--border);
            border-radius: 12px; padding: 16px 20px;
            display: flex; align-items: center; justify-content: space-between; gap: 16px;
            min-height: 90px;
        }
        .nsb-ad-info { display: flex; align-items: center; gap: 14px; }
        .nsb-icon {
            width: 44px; height: 44px; background: #1e3a5f;
            border-radius: 10px; display: flex;
            align-items: center; justify-content: center; font-size: 20px;
        }
        .nsb-ad-text h3 { font-size: 14px; font-weight: 600; color: var(--text-primary); margin-bottom: 2px; }
        .nsb-ad-text p { font-size: 12px; color: var(--text-secondary); }
        .btn-visit {
            background: var(--nsb-blue); color: white; border: none;
            padding: 8px 16px; border-radius: 8px; font-size: 12px;
            font-weight: 600; cursor: pointer; display: flex;
            align-items: center; gap: 4px; white-space: nowrap;
        }
        .btn-visit:hover { opacity: 0.9; }
        .btn-visit[hidden] { display: none; }
        .ad-placeholder {
            flex: 1; background: var(--bg-card); border: 2px dashed var(--border);
            border-radius: 12px; display: flex; flex-direction: column;
            align-items: center; justify-content: center; padding: 20px; min-height: 90px;
        }
        .ad-placeholder .ad-label {
            font-size: 10px; color: var(--text-muted);
            background: var(--bg-dark); padding: 2px 8px;
            border-radius: 4px; margin-bottom: 6px;
        }
        .ad-placeholder p { font-size: 12px; color: var(--text-muted); }

        /* ARAMA */
        .search-section { padding: 0 24px 16px; }
        .search-box {
            background: var(--bg-card); border: 1px solid var(--border);
            border-radius: 12px; padding: 16px 20px;
            display: flex; align-items: center; gap: 12px;
        }
        .search-icon { color: var(--text-muted); font-size: 18px; }
        .search-input {
            flex: 1; background: transparent; border: none;
            color: var(--text-primary); font-size: 15px; outline: none;
        }
        .search-input::placeholder { color: var(--text-muted); }
        .page-size-select {
            background: var(--bg-dark); border: 1px solid var(--border);
            color: var(--text-primary); padding: 6px 10px;
            border-radius: 6px; font-size: 13px; cursor: pointer; outline: none;
        }
        .page-size-label { font-size: 13px; color: var(--text-secondary); white-space: nowrap; }

        /* TABLO */
        .table-container { padding: 0 24px 24px; }
        .table-header-bar {
            background: var(--bg-card); border: 1px solid var(--border);
            border-bottom: none; border-radius: 12px 12px 0 0;
            padding: 14px 20px; display: flex;
            align-items: center; justify-content: space-between;
        }
        .table-title {
            font-size: 15px; font-weight: 600; color: var(--text-primary);
            display: flex; align-items: center; gap: 8px;
        }
        .result-count {
            background: var(--bg-dark); color: var(--text-secondary);
            padding: 3px 10px; border-radius: 12px;
            font-size: 12px; font-weight: 500;
        }
        .pagination-info {
            display: flex; align-items: center; gap: 8px;
            font-size: 13px; color: var(--text-secondary);
        }
        .page-btn {
            width: 28px; height: 28px; border-radius: 6px;
            border: 1px solid var(--border); background: var(--bg-dark);
            color: var(--text-secondary); cursor: pointer;
            display: flex; align-items: center; justify-content: center;
            font-size: 14px; transition: all 0.2s;
        }
        .page-btn:hover:not(:disabled) { background: var(--bg-hover); color: var(--text-primary); }
        .page-btn:disabled { opacity: 0.3; cursor: not-allowed; }

        table { width: 100%; border-collapse: collapse; background: var(--bg-table); border: 1px solid var(--border); border-radius: 0 0 12px 12px; overflow: hidden; }
        thead th {
            background: var(--bg-card); color: var(--text-secondary);
            font-size: 12px; font-weight: 600; text-transform: uppercase;
            letter-spacing: 0.5px; padding: 12px 16px; text-align: left;
            border-bottom: 1px solid var(--border); cursor: pointer; user-select: none; white-space: nowrap;
            transition: color 0.2s;
        }
        thead th:hover { color: var(--text-primary); }
        thead th .sort-icon { margin-left: 4px; font-size: 10px; opacity: 0.5; }
        tbody tr { border-bottom: 1px solid var(--border); transition: background 0.15s; }
        tbody tr:nth-child(even) { background: var(--bg-row-alt); }
        tbody tr:hover { background: var(--bg-hover); }
        tbody td { padding: 14px 16px; font-size: 14px; color: var(--text-primary); vertical-align: middle; }
        .poz-no { color: var(--text-secondary); font-family: monospace; font-size: 13px; }
        .poz-tanim { color: var(--text-primary); max-width: 400px; }
        .poz-birim { color: var(--text-secondary); text-align: center; font-size: 13px; }
        .price-green { color: var(--accent-green); font-weight: 600; }
        .price-red { color: var(--accent-red); font-weight: 600; }
        .price-orange { color: var(--accent-orange); font-weight: 600; }
        .kaynak-tag { color: var(--text-secondary); font-size: 12px; }
        .btn-detail {
            width: 32px; height: 32px; border-radius: 8px;
            border: 1px solid var(--border); background: var(--bg-dark);
            color: var(--accent-blue); cursor: pointer;
            display: flex; align-items: center; justify-content: center;
            font-size: 16px; font-weight: 700; transition: all 0.2s;
        }
        .btn-detail:hover { background: var(--accent-blue); color: white; border-color: var(--accent-blue); }
        .btn-detail.btn-selected {
            background: var(--accent-green); color: white; border-color: var(--accent-green);
        }
        .empty-state {
            text-align: center; padding: 60px 20px; color: var(--text-muted);
        }
        .empty-state-icon { font-size: 48px; margin-bottom: 16px; }
        .empty-state h3 { font-size: 16px; color: var(--text-secondary); margin-bottom: 8px; }
        .empty-state p { font-size: 14px; }

        /* MODAL */
        .modal-overlay {
            position: fixed; top: 0; left: 0; right: 0; bottom: 0;
            background: rgba(0,0,0,0.75); display: none;
            align-items: center; justify-content: center;
            z-index: 1000; padding: 20px;
        }
        .modal-overlay.active { display: flex; }
        .modal {
            background: var(--bg-modal); border: 1px solid var(--border);
            border-radius: 16px; width: 100%; max-width: 700px;
            max-height: 85vh; overflow: hidden;
            display: flex; flex-direction: column;
            animation: modalIn 0.3s ease;
        }
        @keyframes modalIn {
            from { transform: scale(0.95); opacity: 0; }
            to { transform: scale(1); opacity: 1; }
        }
        .modal-header {
            padding: 18px 24px; border-bottom: 1px solid var(--border);
            display: flex; align-items: center; justify-content: space-between;
        }
        .modal-header h2 { font-size: 16px; font-weight: 600; color: var(--text-primary); }
        .modal-close {
            width: 32px; height: 32px; border-radius: 8px;
            border: 1px solid var(--border); background: var(--bg-dark);
            color: var(--text-secondary); cursor: pointer;
            display: flex; align-items: center; justify-content: center;
            font-size: 18px; transition: all 0.2s;
        }
        .modal-close:hover { background: var(--accent-red); color: white; border-color: var(--accent-red); }

        .modal-body { padding: 20px 24px; overflow-y: auto; background: var(--bg-modal-body); }

        .detail-poz-card {
            background: var(--bg-info-card); border: 1px solid var(--border);
            border-radius: 12px; padding: 16px 20px;
            display: flex; align-items: center; gap: 14px; margin-bottom: 16px;
        }
        .detail-poz-icon {
            width: 44px; height: 44px; background: linear-gradient(135deg, #3b82f6, #06b6d4);
            border-radius: 10px; display: flex; align-items: center; justify-content: center;
            font-size: 20px; color: white;
        }
        .detail-poz-info { flex: 1; }
        .detail-poz-label { font-size: 12px; color: var(--text-secondary); margin-bottom: 2px; }
        .detail-poz-value { font-size: 18px; font-weight: 700; color: var(--text-primary); font-family: monospace; }

        .detail-tanim-card {
            background: var(--bg-info-card); border: 1px solid var(--border);
            border-radius: 12px; padding: 16px 20px;
            display: flex; align-items: flex-start; gap: 14px; margin-bottom: 16px;
        }
        .detail-tanim-icon {
            width: 36px; height: 36px; background: var(--bg-dark);
            border-radius: 8px; display: flex; align-items: center; justify-content: center;
            font-size: 16px; color: var(--accent-green); flex-shrink: 0; margin-top: 2px;
        }
        .detail-tanim-info { flex: 1; }
        .detail-tanim-label { font-size: 12px; color: var(--text-secondary); margin-bottom: 4px; }
        .detail-tanim-value { font-size: 14px; color: var(--text-primary); line-height: 1.5; }

        .detail-info-grid {
            display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 20px;
        }
        .detail-info-card {
            background: var(--bg-info-card); border: 1px solid var(--border);
            border-radius: 12px; padding: 16px 20px;
        }
        .detail-info-label { font-size: 12px; color: var(--text-secondary); margin-bottom: 4px; }
        .detail-info-value { font-size: 16px; font-weight: 700; color: var(--text-primary); }

        .detail-history-title {
            font-size: 15px; font-weight: 600; color: var(--text-primary);
            margin-bottom: 12px; display: flex; align-items: center; gap: 8px;
        }
        .detail-history-title .history-icon { font-size: 18px; color: var(--accent-blue); }

        .detail-history-table {
            width: 100%; border-collapse: collapse;
            border: 1px solid var(--border); border-radius: 12px; overflow: hidden;
        }
        .detail-history-table thead th {
            background: var(--bg-card); color: var(--text-secondary);
            font-size: 11px; font-weight: 600; text-transform: uppercase;
            letter-spacing: 0.5px; padding: 10px 14px; text-align: left;
            border-bottom: 1px solid var(--border);
        }
        .detail-history-table thead th:last-child { text-align: right; }
        .detail-history-table tbody tr { border-bottom: 1px solid var(--border); }
        .detail-history-table tbody tr:last-child { border-bottom: none; }
        .detail-history-table tbody tr.current-row { background: var(--bg-green-row); }
        .detail-history-table tbody td {
            padding: 12px 14px; font-size: 13px; color: var(--text-primary); vertical-align: middle;
        }
        .detail-history-table tbody td:last-child { text-align: right; }

        .status-badge {
            display: inline-flex; align-items: center; gap: 6px;
            padding: 4px 10px; border-radius: 20px; font-size: 11px; font-weight: 600;
        }
        .status-badge.current {
            background: rgba(16,185,129,0.15); color: var(--accent-green); border: 1px solid rgba(16,185,129,0.3);
        }
        .status-badge.old {
            background: rgba(100,116,139,0.15); color: var(--text-secondary); border: 1px solid rgba(100,116,139,0.3);
        }
        .status-dot { width: 6px; height: 6px; border-radius: 50%; }
        .status-dot.current { background: var(--accent-green); }
        .status-dot.old { background: var(--text-muted); }

        .detail-price-cell { font-weight: 600; }
        .detail-montaj-cell { font-weight: 600; color: var(--accent-blue); }

        /* FOOTER */
        .main-footer {
            background: var(--bg-dark); border-top: 1px solid var(--border);
            padding: 24px; text-align: center; margin-top: auto;
        }
        .footer-content {
            display: flex; justify-content: center; align-items: center;
            gap: 40px; flex-wrap: wrap; color: var(--text-secondary); font-size: 13px;
        }
        .footer-item { display: flex; align-items: center; gap: 8px; }
        .footer-item svg { width: 16px; height: 16px; color: var(--accent-blue); }

        /* AYDLIK TEMA */
        body.light-mode {
            --bg-dark: #f8fafc;
            --bg-card: #ffffff;
            --bg-table: #ffffff;
            --bg-row: #ffffff;
            --bg-row-alt: #f1f5f9;
            --bg-hover: #e2e8f0;
            --bg-modal: #ffffff;
            --bg-modal-body: #f8fafc;
            --bg-info-card: #f1f5f9;
            --bg-green-row: #ecfdf5;
            --bg-loading: rgba(248,250,252,0.9);
            --text-primary: #1e293b;
            --text-secondary: #64748b;
            --text-muted: #94a3b8;
            --border: #e2e8f0;
            --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
            --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
            --shadow-lg: 0 8px 24px rgba(0,0,0,0.1);
        }
        body.light-mode .nsb-topbar { background: #3b82f6; }
        body.light-mode .btn-export { background: #3b82f6; }
        body.light-mode .btn-visit { background: #3b82f6; }
        body.light-mode .main-header { background: #f8fafc; border-bottom: 1px solid #e2e8f0; }
        body.light-mode .logo-text h1 { color: #1e293b; }
        body.light-mode .theme-toggle { background: #ffffff; border-color: #e2e8f0; color: #64748b; }
        body.light-mode .search-box { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode .search-input { color: #1e293b; }
        body.light-mode .page-size-select { background: #f1f5f9; border-color: #e2e8f0; color: #1e293b; }
        body.light-mode .table-header-bar { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode table { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode thead th { background: #f8fafc; color: #64748b; border-color: #e2e8f0; }
        body.light-mode tbody tr { border-color: #e2e8f0; }
        body.light-mode tbody tr:nth-child(even) { background: #f8fafc; }
        body.light-mode tbody tr:hover { background: #e2e8f0; }
        body.light-mode tbody td { color: #1e293b; }
        body.light-mode .poz-no { color: #64748b; }
        body.light-mode .poz-tanim { color: #1e293b; }
        body.light-mode .poz-birim { color: #64748b; }
        body.light-mode .kaynak-tag { color: #64748b; }
        body.light-mode .btn-detail { background: #f1f5f9; border-color: #e2e8f0; color: #3b82f6; }
        body.light-mode .btn-detail:hover { background: #3b82f6; color: white; border-color: #3b82f6; }
        body.light-mode .btn-detail.btn-selected { background: #10b981; color: white; border-color: #10b981; }
        body.light-mode .nsb-ad-card { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode .nsb-ad-text h3 { color: #1e293b; }
        body.light-mode .nsb-ad-text p { color: #64748b; }
        body.light-mode .ad-placeholder { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode .ad-placeholder .ad-label { background: #f1f5f9; color: #94a3b8; }
        body.light-mode .ad-placeholder p { color: #94a3b8; }
        body.light-mode .main-footer { background: #f8fafc; border-color: #e2e8f0; }
        body.light-mode .footer-content { color: #64748b; }
        body.light-mode .modal { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode .modal-header { border-color: #e2e8f0; }
        body.light-mode .modal-header h2 { color: #1e293b; }
        body.light-mode .modal-body { background: #f8fafc; }
        body.light-mode .modal-close { background: #f1f5f9; border-color: #e2e8f0; color: #64748b; }
        body.light-mode .detail-poz-card { background: #f1f5f9; border-color: #e2e8f0; }
        body.light-mode .detail-poz-label { color: #64748b; }
        body.light-mode .detail-poz-value { color: #1e293b; }
        body.light-mode .detail-tanim-card { background: #f1f5f9; border-color: #e2e8f0; }
        body.light-mode .detail-tanim-label { color: #64748b; }
        body.light-mode .detail-tanim-value { color: #1e293b; }
        body.light-mode .detail-info-card { background: #f1f5f9; border-color: #e2e8f0; }
        body.light-mode .detail-info-label { color: #64748b; }
        body.light-mode .detail-info-value { color: #1e293b; }
        body.light-mode .detail-history-title { color: #1e293b; }
        body.light-mode .detail-history-table { border-color: #e2e8f0; }
        body.light-mode .detail-history-table thead th { background: #f8fafc; color: #64748b; border-color: #e2e8f0; }
        body.light-mode .detail-history-table tbody tr { border-color: #e2e8f0; }
        body.light-mode .status-badge.old { background: rgba(148,163,184,0.15); color: #64748b; border-color: rgba(148,163,184,0.3); }
        body.light-mode .empty-state { color: #94a3b8; }
        body.light-mode .empty-state h3 { color: #64748b; }
        body.light-mode .loading-overlay { background: rgba(248,250,252,0.9); }
        body.light-mode .loading-text { color: #64748b; }
        body.light-mode .toast { background: #ffffff; border-color: #e2e8f0; }

        @media (max-width: 768px) {
            .ad-section { flex-direction: column; }
            .ad-placeholder { width: 100%; }
            .main-header { flex-wrap: wrap; gap: 12px; }
            tbody td { padding: 10px 12px; font-size: 13px; }
            .poz-tanim { max-width: 200px; }
            .detail-info-grid { grid-template-columns: 1fr; }
            .toast-container { left: 20px; right: 20px; }
            .toast { min-width: auto; }
        }
    
        /* ===== LEGAL MODALS - Gizlilik & Sözleşme ===== */
        .legal-modal-overlay {
            position: fixed; top: 0; left: 0; right: 0; bottom: 0;
            background: rgba(0,0,0,0.85); display: none;
            align-items: center; justify-content: center;
            z-index: 2000; padding: 20px;
            backdrop-filter: blur(4px);
        }
        .legal-modal-overlay.active { display: flex; }
        .legal-modal {
            background: var(--bg-modal); border: 1px solid var(--border);
            border-radius: 16px; width: 100%; max-width: 900px;
            max-height: 90vh; overflow: hidden;
            display: flex; flex-direction: column;
            animation: modalIn 0.3s ease;
        }
        .legal-modal-header {
            padding: 18px 24px; border-bottom: 1px solid var(--border);
            display: flex; align-items: center; justify-content: space-between;
            background: var(--bg-card);
        }
        .legal-modal-header h2 { 
            font-size: 18px; font-weight: 700; color: var(--text-primary);
            display: flex; align-items: center; gap: 10px;
        }
        .legal-modal-body { 
            padding: 24px 28px; overflow-y: auto; background: var(--bg-modal-body);
            line-height: 1.7; font-size: 14px; color: var(--text-primary);
        }
        .legal-modal-body h3 {
            font-size: 16px; font-weight: 700; color: var(--accent-blue);
            margin: 24px 0 12px 0; padding-bottom: 8px;
            border-bottom: 2px solid var(--border);
        }
        .legal-modal-body h3:first-child { margin-top: 0; }
        .legal-modal-body h4 {
            font-size: 14px; font-weight: 600; color: var(--text-primary);
            margin: 16px 0 8px 0;
        }
        .legal-modal-body p { margin-bottom: 12px; color: var(--text-secondary); }
        .legal-modal-body ul, .legal-modal-body ol { 
            margin: 0 0 16px 20px; color: var(--text-secondary); 
        }
        .legal-modal-body li { margin-bottom: 6px; }
        .legal-modal-body table {
            width: 100%; border-collapse: collapse; margin: 16px 0;
            background: var(--bg-card); border-radius: 8px; overflow: hidden;
        }
        .legal-modal-body th, .legal-modal-body td {
            padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--border);
            font-size: 13px;
        }
        .legal-modal-body th {
            background: var(--bg-dark); font-weight: 600; color: var(--text-primary);
        }
        .legal-modal-body td { color: var(--text-secondary); }
        .legal-modal-body .legal-meta {
            display: flex; gap: 24px; margin-top: 24px; padding-top: 16px;
            border-top: 1px solid var(--border); font-size: 12px;
            color: var(--text-muted); flex-wrap: wrap;
        }
        .legal-modal-body .legal-meta span { display: flex; align-items: center; gap: 6px; }
        .legal-modal-close {
            width: 36px; height: 36px; border-radius: 10px;
            border: 1px solid var(--border); background: var(--bg-dark);
            color: var(--text-secondary); cursor: pointer;
            display: flex; align-items: center; justify-content: center;
            font-size: 20px; transition: all 0.2s;
        }
        .legal-modal-close:hover { background: var(--accent-red); color: white; border-color: var(--accent-red); }

        /* Footer legal links */
        .footer-legal {
            display: flex; gap: 24px; margin-top: 16px;
            padding-top: 16px; border-top: 1px solid var(--border);
            justify-content: center; flex-wrap: wrap;
        }
        .footer-legal a {
            color: var(--text-secondary); text-decoration: none;
            font-size: 13px; display: flex; align-items: center; gap: 6px;
            transition: color 0.2s; cursor: pointer;
        }
        .footer-legal a:hover { color: var(--accent-blue); }

        /* Light mode adjustments */
        body.light-mode .legal-modal { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode .legal-modal-header { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode .legal-modal-header h2 { color: #1e293b; }
        body.light-mode .legal-modal-body { background: #f8fafc; color: #1e293b; }
        body.light-mode .legal-modal-body h3 { color: #3b82f6; border-color: #e2e8f0; }
        body.light-mode .legal-modal-body h4 { color: #1e293b; }
        body.light-mode .legal-modal-body p { color: #64748b; }
        body.light-mode .legal-modal-body ul, 
        body.light-mode .legal-modal-body ol { color: #64748b; }
        body.light-mode .legal-modal-body th { background: #f1f5f9; color: #1e293b; }
        body.light-mode .legal-modal-body td { color: #64748b; }
        body.light-mode .legal-modal-body table { background: #ffffff; }
        body.light-mode .legal-modal-close { background: #f1f5f9; border-color: #e2e8f0; color: #64748b; }
        body.light-mode .footer-legal { border-color: #e2e8f0; }
        body.light-mode .footer-legal a { color: #64748b; }
        body.light-mode .footer-legal a:hover { color: #3b82f6; }

        @media (max-width: 768px) {
            .legal-modal { max-height: 95vh; border-radius: 12px; }
            .legal-modal-body { padding: 16px 20px; font-size: 13px; }
            .legal-modal-header { padding: 14px 18px; }
            .legal-modal-header h2 { font-size: 15px; }
        }

        .btn-clear {
            background: var(--bg-card); color: var(--text-secondary); border: 1px solid var(--border);
            padding: 8px 16px; border-radius: 8px; font-size: 13px;
            font-weight: 600; cursor: pointer; display: flex;
            align-items: center; gap: 6px; transition: all 0.2s;
        }
        .btn-clear:hover { 
            background: var(--accent-red); color: white; border-color: var(--accent-red);
            transform: translateY(-1px);
        }
        .btn-clear:disabled {
            opacity: 0.4; cursor: not-allowed; transform: none;
            background: var(--bg-card); color: var(--text-muted); border-color: var(--border);
        }
        body.light-mode .btn-clear { background: #ffffff; border-color: #e2e8f0; color: #64748b; }
        body.light-mode .btn-clear:hover { background: #ef4444; color: white; border-color: #ef4444; }
        body.light-mode .btn-clear:disabled { background: #f1f5f9; color: #94a3b8; border-color: #e2e8f0; }

        /* ===== MOBILE CARD VIEW ===== */
        .mobile-cards-view {
            display: none;
            padding: 0 16px 24px;
            gap: 12px;
            flex-direction: column;
        }
        .poz-card {
            background: var(--bg-card);
            border: 1px solid var(--border);
            border-radius: 14px;
            padding: 16px;
            transition: all 0.2s;
            position: relative;
            overflow: hidden;
        }
        .poz-card:hover {
            border-color: var(--accent-blue);
            transform: translateY(-2px);
            box-shadow: var(--shadow-md);
        }
        .poz-card.selected {
            border-color: var(--accent-green);
            background: var(--bg-green-row);
        }
        .poz-card-header {
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            margin-bottom: 12px;
        }
        .poz-card-no {
            font-family: monospace;
            font-size: 15px;
            font-weight: 700;
            color: var(--accent-blue);
            background: var(--bg-dark);
            padding: 4px 10px;
            border-radius: 8px;
        }
        .poz-card-actions {
            display: flex;
            gap: 6px;
        }
        .poz-card-tanim {
            font-size: 14px;
            color: var(--text-primary);
            line-height: 1.5;
            margin-bottom: 14px;
            display: -webkit-box;
            -webkit-line-clamp: 3;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }
        .poz-card-details {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            margin-bottom: 14px;
        }
        .poz-card-detail {
            background: var(--bg-dark);
            padding: 10px 12px;
            border-radius: 10px;
            text-align: center;
        }
        .poz-card-detail-label {
            font-size: 11px;
            color: var(--text-muted);
            text-transform: uppercase;
            letter-spacing: 0.5px;
            margin-bottom: 4px;
        }
        .poz-card-detail-value {
            font-size: 15px;
            font-weight: 700;
            color: var(--text-primary);
        }
        .poz-card-detail-value.price-green { color: var(--accent-green); }
        .poz-card-detail-value.price-red { color: var(--accent-red); }
        .poz-card-detail-value.price-orange { color: var(--accent-orange); }
        .poz-card-footer {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding-top: 12px;
            border-top: 1px solid var(--border);
        }
        .poz-card-kaynak {
            font-size: 12px;
            color: var(--text-secondary);
            display: flex;
            align-items: center;
            gap: 6px;
        }
        .poz-card-kaynak .kaynak-badge {
            background: var(--bg-info-card);
            padding: 3px 8px;
            border-radius: 6px;
            font-weight: 600;
            font-size: 11px;
        }
        .poz-card-btns {
            display: flex;
            gap: 6px;
        }
        .btn-card-action {
            width: 36px; height: 36px;
            border-radius: 10px;
            border: 1px solid var(--border);
            background: var(--bg-dark);
            color: var(--text-secondary);
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 16px;
            transition: all 0.2s;
        }
        .btn-card-action:hover {
            background: var(--accent-blue);
            color: white;
            border-color: var(--accent-blue);
        }
        .btn-card-action.selected {
            background: var(--accent-green);
            color: white;
            border-color: var(--accent-green);
        }

        /* View Toggle Buttons */
        .view-toggle {
            display: none;
            align-items: center;
            gap: 8px;
            margin-left: auto;
            margin-right: 16px;
        }
        .view-toggle-btn {
            width: 32px; height: 32px;
            border-radius: 8px;
            border: 1px solid var(--border);
            background: var(--bg-dark);
            color: var(--text-secondary);
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 14px;
            transition: all 0.2s;
        }
        .view-toggle-btn:hover { background: var(--bg-hover); color: var(--text-primary); }
        .view-toggle-btn.active {
            background: var(--accent-blue);
            color: white;
            border-color: var(--accent-blue);
        }

        /* Mobile responsive */
        @media (max-width: 768px) {
            .table-container table { display: none; }
            .mobile-cards-view { display: flex; }
            .view-toggle { display: flex; }
            .table-header-bar {
                border-radius: 12px;
                border-bottom: 1px solid var(--border);
            }
            .main-header {
                padding: 12px 16px;
            }
            .logo-box {
                width: 48px; height: 48px;
                font-size: 11px;
            }
            .logo-text h1 { font-size: 16px; }
            .ad-section { padding: 12px 16px; }
            .search-section { padding: 0 16px 12px; }
            .table-container { padding: 0 0 16px; }
        }

        /* Light mode for cards */
        body.light-mode .poz-card { background: #ffffff; border-color: #e2e8f0; }
        body.light-mode .poz-card:hover { border-color: #3b82f6; }
        body.light-mode .poz-card.selected { border-color: #10b981; background: #ecfdf5; }
        body.light-mode .poz-card-no { background: #f1f5f9; color: #3b82f6; }
        body.light-mode .poz-card-detail { background: #f8fafc; }
        body.light-mode .poz-card-detail-label { color: #94a3b8; }
        body.light-mode .poz-card-detail-value { color: #1e293b; }
        body.light-mode .poz-card-footer { border-color: #e2e8f0; }
        body.light-mode .poz-card-kaynak { color: #64748b; }
        body.light-mode .poz-card-kaynak .kaynak-badge { background: #f1f5f9; }
        body.light-mode .btn-card-action { background: #f1f5f9; border-color: #e2e8f0; color: #64748b; }
        body.light-mode .btn-card-action:hover { background: #3b82f6; color: white; border-color: #3b82f6; }
        body.light-mode .btn-card-action.selected { background: #10b981; color: white; border-color: #10b981; }
        body.light-mode .view-toggle-btn { background: #f1f5f9; border-color: #e2e8f0; color: #64748b; }
        body.light-mode .view-toggle-btn.active { background: #3b82f6; color: white; }

a.btn-visit { text-decoration: none; }
.giris-ekran {
    position: fixed; inset: 0; z-index: 12000;
    background: var(--bg-dark);
    display: flex; align-items: center; justify-content: center;
    padding: 24px;
}
.giris-ekran[hidden] { display: none; }
.giris-kutu {
    width: min(420px, 100%);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 28px 24px;
    display: flex; flex-direction: column; gap: 12px;
}
.giris-kutu h1 { font-size: 22px; margin: 8px 0 0; }
.giris-kutu p { color: var(--text-secondary); font-size: 14px; margin: 0; }
.giris-kutu label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--text-secondary); }
.giris-kutu input {
    background: var(--bg-dark); color: var(--text-primary);
    border: 1px solid var(--border); border-radius: 8px;
    padding: 10px 12px; font: inherit;
}
.uye-adi { color: var(--text-secondary); font-size: 13px; }
.uye-fiyat {
    background: #f5b942; color: #1f2937; border: 0; border-radius: 8px;
    padding: 4px 12px; font: inherit; font-size: 12px; font-weight: 700; cursor: pointer;
}
.giris-kutu form { display: flex; flex-direction: column; gap: 12px; }
.giris-kutu form[hidden] { display: none; }
.giris-kutu form button {
    width: 100%; margin-top: 8px; background: var(--nsb-blue); color: white; border: 0;
    border-radius: 8px; padding: 10px 16px; font: inherit; font-weight: 600; cursor: pointer;
}
.giris-sekme { display: flex; gap: 8px; }
.giris-sekme button {
    flex: 1; margin-top: 0; background: var(--bg-dark); color: var(--text-secondary);
    border: 1px solid var(--border); border-radius: 8px; padding: 8px 12px;
    font: inherit; font-weight: 600; cursor: pointer;
}
.giris-sekme button.aktif { background: var(--nsb-blue); color: white; border-color: var(--nsb-blue); }
.giris-hata { color: var(--accent-red); }
.th-center { text-align: center; }
.th-right { text-align: right; }
.ad-note { font-size: 11px; }
.mail-link { color: inherit; text-decoration: none; }
.islemler { display: flex; gap: 4px; justify-content: center; }
td.sayi { text-align: right; }

.yonetim { max-width: 1100px; margin: 0 auto; padding: 28px 16px 48px; }
.yonetim h1 { font-size: 24px; margin-bottom: 16px; }
.yonetim-sekme { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.yonetim-sekme button, .yonetim button, .yonetim-kutu input {
    font: inherit;
}
.yonetim-sekme button {
    background: var(--bg-card); color: var(--text-secondary); border: 1px solid var(--border);
    border-radius: 8px; padding: 8px 14px; cursor: pointer;
}
.yonetim-sekme button.aktif { background: var(--nsb-blue); color: white; border-color: var(--nsb-blue); }
.yonetim-kutu {
    background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px; padding: 16px;
    display: flex; flex-direction: column; gap: 12px;
}
.yonetim-kutu label { display: flex; flex-direction: column; gap: 6px; color: var(--text-secondary); font-size: 13px; }
.yonetim-kutu input {
    background: var(--bg-dark); color: var(--text-primary); border: 1px solid var(--border);
    border-radius: 8px; padding: 10px 12px;
}
.yonetim-kutu button, .yonetim .kucuk {
    background: var(--nsb-blue); color: white; border: 0; border-radius: 8px;
    padding: 8px 14px; font-weight: 600; cursor: pointer;
}
.yonetim .tehlike { background: var(--accent-red); }
.yonetim-arama { display: flex; gap: 8px; }
.yonetim-arama input { flex: 1; }
.yonetim table { width: 100%; border-collapse: collapse; }
.yonetim th, .yonetim td { text-align: left; padding: 8px; border-bottom: 1px solid var(--border); font-size: 13px; }
.yonetim-sayac { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }
.yonetim-kart { background: var(--bg-dark); border-radius: 10px; padding: 14px; }
.yonetim-kart span { display: block; color: var(--text-secondary); font-size: 12px; }
.yonetim-kart strong { font-size: 22px; }
.yonetim-hata { color: var(--accent-red); min-height: 1.2em; }
.yonetim [hidden] { display: none; }
