/* Depo Raporu - responsive, framework'suz */
:root {
    --bg: #f1f4f9;
    --surface: #ffffff;
    --primary: #1e3a5f;
    --primary-light: #2d5487;
    --accent: #2f80ed;
    --text: #1c2733;
    --muted: #6b7a8c;
    --border: #dde4ee;
    --ok: #1e9e5a;
    --warn: #d98a00;
    --info: #2f80ed;
    --danger: #d93025;
    --radius: 12px;
    --shadow: 0 1px 3px rgba(16, 34, 59, .08), 0 4px 14px rgba(16, 34, 59, .06);
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    font-size: 15px;
    -webkit-font-smoothing: antialiased;
}

/* ---------- Topbar ---------- */
.topbar {
    background: var(--primary);
    color: #fff;
    position: sticky;
    top: 0;
    z-index: 20;
    box-shadow: var(--shadow);
}
.topbar-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.brand { font-weight: 700; font-size: 17px; letter-spacing: .2px; }
.logout {
    color: #cfe0f5;
    text-decoration: none;
    font-size: 14px;
    padding: 6px 12px;
    border: 1px solid rgba(255,255,255,.25);
    border-radius: 8px;
}
.logout:hover { background: rgba(255,255,255,.1); }

/* ---------- Layout ---------- */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 16px;
}
section { margin-bottom: 28px; }
h2 {
    font-size: 16px;
    margin: 0 0 12px;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: .5px;
}
.count { color: var(--muted); font-weight: 400; text-transform: none; }

/* ---------- Filtreler ---------- */
.filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-end;
    background: var(--surface);
    padding: 14px 16px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 24px;
}
.filter-field { display: flex; flex-direction: column; gap: 4px; flex: 1; min-width: 130px; }
.filter-field label { font-size: 12px; color: var(--muted); font-weight: 600; }
input[type="date"], input[type="text"], input[type="password"] {
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    background: #fff;
    color: var(--text);
    width: 100%;
}
input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }

.btn {
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 11px 24px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}
.btn:hover { filter: brightness(1.08); }
.btn-block { width: 100%; margin-top: 16px; }

/* ---------- Kartlar ---------- */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
}
.card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 16px;
    text-align: center;
    box-shadow: var(--shadow);
}
.card-value { font-size: 26px; font-weight: 700; color: var(--primary); }
.card-label { font-size: 12px; color: var(--muted); margin-top: 4px; }

/* ---------- Tablolar ---------- */
.table-wrap {
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.table-scroll { max-height: 420px; overflow-y: auto; }
table { border-collapse: collapse; width: 100%; min-width: 560px; }
th, td { padding: 10px 12px; text-align: left; white-space: nowrap; }
thead th {
    background: #f7f9fc;
    color: var(--muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .4px;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
}
tbody tr { border-bottom: 1px solid var(--border); }
tbody tr:last-child { border-bottom: none; }
tbody tr:hover { background: #f4f8fd; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.empty { text-align: center; color: var(--muted); padding: 24px; }
.dim { color: #c3ccd8; }

/* Matris */
.matrix .sticky-col {
    position: sticky;
    left: 0;
    background: var(--surface);
    border-right: 1px solid var(--border);
    z-index: 5;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
}
.matrix thead .sticky-col { background: #f7f9fc; z-index: 6; }
.total-col { font-weight: 700; background: #f7f9fc; }
.total-row td { font-weight: 700; background: #f0f4fa; }
.total-row .sticky-col { background: #f0f4fa; }

/* ---------- Filtre cipleri ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.chip {
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--muted);
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}
.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ---------- Rozetler ---------- */
.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}
.badge-ok    { background: #e3f6ec; color: var(--ok); }
.badge-warn  { background: #fdf3e0; color: var(--warn); }
.badge-info  { background: #e7f0fd; color: var(--info); }
.badge-muted { background: #eef1f5; color: var(--muted); }

/* ---------- Uyari ---------- */
.alert {
    background: #fdecea;
    color: var(--danger);
    padding: 12px 14px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
}

/* ---------- Login ---------- */
.login-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: linear-gradient(160deg, var(--primary) 0%, var(--primary-light) 60%, #3d6ba8 100%);
    padding: 16px;
}
.login-card {
    background: var(--surface);
    border-radius: 16px;
    padding: 32px 28px;
    width: 100%;
    max-width: 380px;
    box-shadow: 0 12px 40px rgba(0,0,0,.25);
    text-align: center;
}
.login-logo { font-size: 40px; }
.login-card h1 { margin: 8px 0 4px; font-size: 22px; color: var(--primary); }
.login-sub { color: var(--muted); font-size: 14px; margin: 0 0 20px; }
.login-card form { text-align: left; }
.login-card label { font-size: 13px; color: var(--muted); font-weight: 600; display: block; margin: 12px 0 4px; }

.page-footer {
    text-align: center;
    color: var(--muted);
    font-size: 13px;
    padding: 8px 0 24px;
}

/* ---------- Mobil ---------- */
@media (max-width: 600px) {
    body { font-size: 14px; }
    .container { padding: 12px; }
    .cards { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .card-value { font-size: 22px; }
    .filters { padding: 12px; }
    .btn { width: 100%; }
    th, td { padding: 8px 10px; }
}
