/* ==========================================================
   KARAKURTMEDYA — Dijital Çözümler · Tasarım sistemi
   Neon mor #7B3FE4 · Pudra pembe #E7A3C8 · Lavanta #D9B8F0
   Koyu antrasit #1C1D22 · Gece moru #2A2140 · Kırık beyaz #F4F2EF
   ========================================================== */
:root {
  --neon: #7B3FE4;
  --neon-hi: #9460F0;
  --pudra: #E7A3C8;
  --lavanta: #D9B8F0;
  --antrasit: #1C1D22;
  --gece: #2A2140;
  --kirik: #F4F2EF;
  --duman: #4A4B52;
  --kirmizi: #C8202E;

  /* Koyu tema (varsayılan) */
  --bg: #16171B;
  --surface: rgba(34, 35, 42, .72);
  --surface-solid: #212228;
  --surface-2: rgba(255, 255, 255, .025);
  --surface-3: rgba(255, 255, 255, .055);
  --text: var(--kirik);
  --text-2: #C8C4D2;
  --text-3: #8C8A98;
  --line: rgba(217, 184, 240, .09);
  --line-2: rgba(217, 184, 240, .16);
  --brand: var(--neon);
  --brand-text: var(--lavanta);
  --brand-soft: rgba(123, 63, 228, .16);
  --grad: linear-gradient(120deg, #7B3FE4 0%, #A15FE8 55%, #E7A3C8 100%);
  --grad-night: radial-gradient(120% 140% at 100% 0%, rgba(123, 63, 228, .55) 0%, rgba(42, 33, 64, .92) 45%, #1C1D22 100%);
  --ok: #5BD6A6; --ok-soft: rgba(91, 214, 166, .12);
  --warn: #F2BA5E; --warn-soft: rgba(242, 186, 94, .12);
  --bad: #EE4452; --bad-soft: rgba(200, 32, 46, .18);
  --info: var(--lavanta); --info-soft: rgba(217, 184, 240, .12);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow: 0 1px 0 rgba(255, 255, 255, .03) inset, 0 12px 40px -18px rgba(0, 0, 0, .7);
  --shadow-lg: 0 30px 80px -20px rgba(0, 0, 0, .8);
  --radius: 22px;
  --sidebar: 272px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: "Inter Tight", "Inter", sans-serif;
  --font-brand: "Barlow Condensed", "Inter Tight", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  color-scheme: dark;
}
/* Açık tema (isteğe bağlı) */
:root[data-theme="light"] {
  --bg: #F4F2EF;
  --surface: rgba(255, 255, 255, .86);
  --surface-solid: #FFFFFF;
  --surface-2: rgba(42, 33, 64, .025);
  --surface-3: rgba(42, 33, 64, .06);
  --text: #1C1D22;
  --text-2: #4A4B52;
  --text-3: #85838F;
  --line: rgba(42, 33, 64, .09);
  --line-2: rgba(42, 33, 64, .16);
  --brand-text: #6A2FD6;
  --brand-soft: rgba(123, 63, 228, .1);
  --ok: #17996B; --ok-soft: rgba(23, 153, 107, .1);
  --warn: #B87800; --warn-soft: rgba(242, 186, 94, .18);
  --bad: #C8202E; --bad-soft: rgba(200, 32, 46, .09);
  --info: #6A2FD6; --info-soft: rgba(123, 63, 228, .09);
  --shadow: 0 1px 2px rgba(28, 29, 34, .04), 0 10px 30px -14px rgba(42, 33, 64, .22);
  --shadow-lg: 0 30px 70px -20px rgba(42, 33, 64, .35);
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font: 14px/1.55 var(--font); background: var(--bg); color: var(--text);
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(900px 520px at 85% -10%, rgba(123, 63, 228, .22), transparent 60%),
    radial-gradient(700px 500px at -10% 110%, rgba(42, 33, 64, .9), transparent 65%);
  background-attachment: fixed;
}
:root[data-theme="light"] body {
  background-image: radial-gradient(900px 520px at 85% -10%, rgba(123, 63, 228, .10), transparent 60%),
                    radial-gradient(700px 500px at -10% 110%, rgba(231, 163, 200, .18), transparent 65%);
}
::selection { background: rgba(123, 63, 228, .45); color: #fff; }
a { color: var(--brand-text); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-display); letter-spacing: -.025em; }
h1 { font-size: 28px; font-weight: 800; }
h2 { font-size: 18px; font-weight: 700; }
h3 { font-size: 15px; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0; }
code { font-family: var(--font-mono); font-size: .88em; }
.hidden { display: none !important; }
.muted { color: var(--text-3); }
.small { font-size: 12.5px; }
.tnum { font-variant-numeric: tabular-nums; }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.eyebrow { font-size: 11px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--text-3); }

/* ============ Marka ============ */
.brand { display: flex; align-items: center; gap: 13px; padding: 4px 6px 24px; }
.brand-mark {
  width: 44px; height: 44px; border-radius: 50%; flex: none; overflow: hidden; display: grid; place-items: center;
  background: var(--antrasit); color: #fff; font-weight: 800; font-size: 16px;
  box-shadow: 0 0 0 2px var(--neon), 0 0 18px -2px rgba(123, 63, 228, .85);
}
.brand-mark img { width: 100%; height: 100%; object-fit: cover; }
/* Varsayılan marka görseli: içindeki yazı ve halka kırpılır, yüze odaklanır */
.brand-mark img.face, .neon-ring img.face { transform: scale(1.75); transform-origin: 50% 21%; }
.wordmark { display: flex; flex-direction: column; line-height: 1; min-width: 0; }
.wordmark .wm-top { font-family: var(--font-display); font-size: 9px; font-weight: 700; letter-spacing: .36em; color: var(--text); text-transform: uppercase; white-space: nowrap; }
.wordmark .wm-main {
  font-family: var(--font-brand); font-style: italic; font-weight: 800; font-size: 21px; letter-spacing: .01em; text-transform: uppercase; margin-top: 5px; white-space: nowrap;
  background: linear-gradient(180deg, #FFFFFF 10%, var(--lavanta) 100%); -webkit-background-clip: text; background-clip: text; color: transparent;
}
:root[data-theme="light"] .sidebar .wordmark .wm-main, :root[data-theme="light"] .auth-form .wordmark .wm-main { background: linear-gradient(180deg, #2A2140, #7B3FE4); -webkit-background-clip: text; background-clip: text; }
.wordmark .wm-line { display: block; height: 2px; width: 60%; margin-top: 6px; background: var(--neon); box-shadow: 0 0 10px var(--neon); border-radius: 2px; }
.wordmark.lg { align-items: center; }
.wordmark.lg .wm-top { font-size: 14px; letter-spacing: .55em; margin-right: -.55em; }
.wordmark.lg .wm-main { font-size: 56px; margin-top: 12px; }
.wordmark.lg .wm-line { height: 3px; width: 70%; margin-top: 14px; }

/* ============ Form öğeleri ============ */
button, input, select, textarea { font: inherit; color: inherit; }
.btn {
  display: inline-flex; align-items: center; gap: 8px; justify-content: center;
  height: 40px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line-2);
  background: var(--surface-3); font-weight: 600; font-size: 13.5px; cursor: pointer; white-space: nowrap; color: var(--text);
  transition: background .18s, border-color .18s, box-shadow .18s, transform .06s, filter .18s;
}
.btn:hover { background: rgba(217, 184, 240, .1); border-color: rgba(217, 184, 240, .28); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[disabled] { opacity: .45; pointer-events: none; }
.btn svg { width: 16px; height: 16px; }
.btn.primary {
  background: linear-gradient(180deg, var(--neon-hi), var(--neon)); color: #fff; border: 1px solid rgba(255, 255, 255, .14);
  box-shadow: 0 0 0 1px rgba(123, 63, 228, .4), 0 10px 26px -10px rgba(123, 63, 228, .95), inset 0 1px 0 rgba(255, 255, 255, .22);
}
.btn.primary:hover { filter: brightness(1.08); box-shadow: 0 0 0 1px rgba(123, 63, 228, .6), 0 12px 32px -8px rgba(123, 63, 228, 1), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn.dark { background: var(--antrasit); color: var(--kirik); border-color: var(--antrasit); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.ghost:hover { background: var(--surface-3); }
.btn.danger { color: var(--bad); }
.btn.danger:hover { background: var(--bad-soft); border-color: transparent; }
.btn.ok { background: linear-gradient(180deg, #62DDAE, #3DBF8E); color: #0E2A20; border-color: transparent; }
.btn.sm { height: 32px; padding: 0 12px; font-size: 12.5px; border-radius: 10px; }
.btn.icon { width: 40px; padding: 0; }
.btn.sm.icon { width: 32px; }

.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field > span { font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.field > small { color: var(--text-3); font-size: 12px; }
.input, .field input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=color]), .field select, .field textarea, select.input {
  width: 100%; height: 42px; padding: 0 13px; border: 1px solid var(--line-2); border-radius: 12px;
  background: rgba(0, 0, 0, .2); outline: none; transition: border-color .18s, box-shadow .18s;
}
:root[data-theme="light"] .input, :root[data-theme="light"] .field input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=color]),
:root[data-theme="light"] .field select, :root[data-theme="light"] .field textarea { background: #fff; }
.field select option, select.input option { background: var(--surface-solid); color: var(--text); }
.field textarea, textarea.input { height: auto; padding: 11px 13px; resize: vertical; min-height: 90px; line-height: 1.6; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: var(--neon); box-shadow: 0 0 0 4px rgba(123, 63, 228, .22); }
input[type=color] { width: 100%; height: 42px; border: 1px solid var(--line-2); border-radius: 12px; background: transparent; padding: 4px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.span-2 { grid-column: span 2; }
.span-all { grid-column: 1 / -1; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.spacer { flex: 1; }
.cards > *, .grid-2 > *, .grid-3 > *, .grid-4 > *, .stack > * { min-width: 0; }

.switch { display: flex; align-items: center; gap: 11px; cursor: pointer; font-weight: 550; }
.switch input { appearance: none; width: 40px; height: 23px; border-radius: 99px; background: var(--line-2); position: relative; cursor: pointer; transition: background .2s, box-shadow .2s; flex: none; margin: 0; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 17px; height: 17px; border-radius: 50%; background: var(--kirik); transition: transform .2s; box-shadow: var(--shadow-sm); }
.switch input:checked { background: var(--neon); box-shadow: 0 0 14px -2px rgba(123, 63, 228, .9); }
.switch input:checked::after { transform: translateX(17px); background: #fff; }

.seg { display: inline-flex; background: var(--surface-3); border: 1px solid var(--line); border-radius: 13px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; height: 32px; padding: 0 14px; border-radius: 10px; font-weight: 600; font-size: 13px; color: var(--text-3); cursor: pointer; transition: color .15s, background .15s; }
.seg button:hover { color: var(--text); }
.seg button.active { background: var(--neon); color: #fff; box-shadow: 0 6px 18px -8px rgba(123, 63, 228, 1); }

/* ============ Yerleşim ============ */
.layout { display: grid; grid-template-columns: var(--sidebar) 1fr; min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 3px;
  padding: 26px 16px 20px; overflow-y: auto; border-right: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(42, 33, 64, .6), rgba(28, 29, 34, .55)); backdrop-filter: blur(20px);
}
:root[data-theme="light"] .sidebar { background: rgba(255, 255, 255, .72); }
.nav-label { font-size: 10px; font-weight: 700; color: var(--text-3); text-transform: uppercase; letter-spacing: .24em; padding: 14px 12px 8px; }
.nav a {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; color: var(--text-2);
  font-weight: 550; text-decoration: none; position: relative; transition: background .18s, color .18s;
}
.nav a svg { width: 18px; height: 18px; flex: none; opacity: .8; }
.nav a:hover { background: var(--surface-3); color: var(--text); text-decoration: none; }
.nav a.active { background: linear-gradient(90deg, rgba(123, 63, 228, .28), rgba(123, 63, 228, .05)); color: var(--text); }
.nav a.active svg { color: var(--lavanta); opacity: 1; }
:root[data-theme="light"] .nav a.active svg { color: var(--neon); }
.nav a.active::before { content: ""; position: absolute; left: -16px; top: 9px; bottom: 9px; width: 3px; border-radius: 0 3px 3px 0; background: var(--neon); box-shadow: 0 0 12px var(--neon); }
.nav a .count { margin-left: auto; background: var(--pudra); color: var(--antrasit); font-size: 11px; font-weight: 800; min-width: 20px; height: 20px; border-radius: 99px; display: grid; place-items: center; padding: 0 6px; }
.sidebar-foot { margin-top: auto; padding-top: 16px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 3px; }
.main { min-width: 0; padding: 34px 40px 70px; max-width: 1380px; width: 100%; }
.topbar { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 28px; flex-wrap: wrap; }
.topbar p { color: var(--text-3); margin-top: 6px; }
.mobile-bar { display: none; }

/* ============ Kartlar (cam) ============ */
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
}
.card-pad { padding: 24px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 18px 24px; border-bottom: 1px solid var(--line); }
.card-body { padding: 20px 24px; }
.cards { display: grid; gap: 18px; }
.cols-dash { grid-template-columns: 1.6fr 1fr; align-items: start; }

.stat { padding: 22px 24px; position: relative; overflow: hidden; }
.stat .label { font-size: 12px; font-weight: 600; color: var(--text-3); letter-spacing: .02em; }
.stat .value { font-family: var(--font-display); font-size: 30px; font-weight: 800; letter-spacing: -.035em; margin-top: 10px; font-variant-numeric: tabular-nums; }
.stat .sub { font-size: 12.5px; color: var(--text-3); margin-top: 4px; }
.stat .ico { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--brand-soft); color: var(--lavanta); position: absolute; right: 20px; top: 20px; }
:root[data-theme="light"] .stat .ico { color: var(--neon); }
.stat .ico svg { width: 18px; height: 18px; }
.stat.hero { background: var(--grad-night); border: 1px solid rgba(217, 184, 240, .22); color: var(--kirik); }
.stat.hero::after { content: ""; position: absolute; left: 24px; right: 24px; bottom: 0; height: 2px; background: linear-gradient(90deg, transparent, var(--neon), var(--pudra), transparent); box-shadow: 0 0 14px var(--neon); }
.stat.hero .label, .stat.hero .sub { color: rgba(244, 242, 239, .7); }
.stat.hero .value { color: #fff; }
.stat.hero .ico { background: rgba(255, 255, 255, .1); color: var(--lavanta); }
.delta { font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 99px; }
.delta.up { color: var(--ok); background: var(--ok-soft); }
.delta.down { color: var(--bad); background: var(--bad-soft); }

/* ============ Rozetler ============ */
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 650; padding: 4px 10px; border-radius: 99px; white-space: nowrap; letter-spacing: .01em; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 8px currentColor; }
.badge.plain::before { display: none; }
.b-scheduled, .b-info { color: var(--info); background: var(--info-soft); }
.b-publishing, .b-warn, .b-review, .b-pending { color: var(--warn); background: var(--warn-soft); }
.b-published, .b-ok, .b-paid, .b-approved, .b-active { color: var(--ok); background: var(--ok-soft); }
.b-failed, .b-bad, .b-overdue, .b-changes { color: var(--bad); background: var(--bad-soft); }
.b-draft, .b-cancelled, .b-none, .b-paused, .b-ended { color: var(--text-3); background: var(--surface-3); }

/* ============ Tablo ============ */
.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: 10.5px; font-weight: 700; color: var(--text-3); text-transform: uppercase; letter-spacing: .14em; padding: 13px 18px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--surface-2); }
.table td { padding: 14px 18px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tr.click { cursor: pointer; transition: background .12s; }
.table tr.click:hover td { background: rgba(123, 63, 228, .07); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ============ Liste öğeleri ============ */
.list { display: flex; flex-direction: column; }
.list-item { display: flex; align-items: center; gap: 14px; padding: 14px 24px; border-bottom: 1px solid var(--line); }
.list-item:last-child { border-bottom: 0; }
.list-item.click { cursor: pointer; transition: background .12s; }
.list-item.click:hover { background: rgba(123, 63, 228, .07); }
.list-item .grow { flex: 1; min-width: 0; }
.list-item .title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.empty { padding: 40px 24px; text-align: center; color: var(--text-3); }
.empty svg { width: 34px; height: 34px; opacity: .6; margin-bottom: 8px; color: var(--lavanta); }

.avatar { width: 40px; height: 40px; border-radius: 50%; flex: none; display: grid; place-items: center; color: #fff; font-weight: 750; font-size: 14px; object-fit: cover; background: linear-gradient(135deg, var(--neon), var(--gece)); }
.avatar.sm { width: 28px; height: 28px; font-size: 11px; }
.avatar.lg { width: 64px; height: 64px; font-size: 22px; box-shadow: 0 0 0 2px var(--surface-solid), 0 0 0 4px var(--neon), 0 0 22px -4px var(--neon); }
.avatar.ring { padding: 2px; background: conic-gradient(from 200deg, var(--neon), var(--pudra), var(--neon)); }
.avatar.ring img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; border: 2px solid var(--surface-solid); }
.thumb { width: 48px; height: 48px; border-radius: 12px; object-fit: cover; background: var(--surface-3); flex: none; }

/* Müşteri kartları */
.client-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }
.client-card { padding: 22px; cursor: pointer; transition: transform .2s, box-shadow .2s, border-color .2s; position: relative; overflow: hidden; }
.client-card:hover { transform: translateY(-3px); border-color: rgba(123, 63, 228, .45); box-shadow: var(--shadow-lg), 0 0 30px -12px rgba(123, 63, 228, .7); text-decoration: none; }
.client-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 2px; background: var(--c, var(--neon)); box-shadow: 0 0 16px var(--c, var(--neon)); }
.client-card .meta { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--line-2); }
.client-card .meta b { display: block; font-family: var(--font-display); font-size: 16px; font-variant-numeric: tabular-nums; }
.client-card .meta span { font-size: 12px; color: var(--text-3); }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }

/* Sekmeler */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 24px; overflow-x: auto; }
.tabs button { border: 0; background: none; padding: 12px 15px; font-weight: 600; color: var(--text-3); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; transition: color .15s; }
.tabs button:hover { color: var(--text); }
.tabs button.active { color: var(--text); border-color: var(--neon); }

/* ============ Takvim ============ */
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal .dow { padding: 12px; font-size: 10.5px; font-weight: 700; color: var(--text-3); text-transform: uppercase; letter-spacing: .16em; border-bottom: 1px solid var(--line); }
.cal .day { min-height: 130px; padding: 8px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); cursor: pointer; transition: background .12s; display: flex; flex-direction: column; gap: 4px; }
.cal .day:nth-child(7n) { border-right: 0; }
.cal .day:hover { background: rgba(123, 63, 228, .06); }
.cal .day.other { background: rgba(0, 0, 0, .14); }
:root[data-theme="light"] .cal .day.other { background: var(--surface-2); }
.cal .day.other .num { opacity: .35; }
.cal .day.past { cursor: default; }
.cal .num { font-size: 12.5px; font-weight: 700; width: 27px; height: 27px; display: grid; place-items: center; border-radius: 50%; font-variant-numeric: tabular-nums; }
.cal .day.today .num { background: var(--neon); color: #fff; box-shadow: 0 0 14px -1px var(--neon); }
.ev { display: flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 600; padding: 4px 6px; border-radius: 8px; background: var(--surface-3); border-left: 2px solid var(--c, var(--neon)); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; cursor: pointer; transition: background .12s; }
.ev:hover { background: rgba(123, 63, 228, .2); }
.ev img { width: 18px; height: 18px; border-radius: 5px; object-fit: cover; flex: none; }
.ev .t { color: var(--text-3); font-variant-numeric: tabular-nums; }
.ev .st { width: 7px; height: 7px; border-radius: 50%; margin-left: auto; flex: none; }
.st-scheduled { background: var(--lavanta); box-shadow: 0 0 6px var(--lavanta); }
.st-publishing { background: var(--warn); }
.st-published { background: var(--ok); box-shadow: 0 0 6px var(--ok); }
.st-failed { background: var(--bad); box-shadow: 0 0 6px var(--bad); }

/* Gönderi kartları */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 18px; }
.post-card { overflow: hidden; display: flex; flex-direction: column; transition: transform .2s, border-color .2s; }
.post-card:hover { transform: translateY(-2px); border-color: rgba(123, 63, 228, .4); }
.post-card .media { aspect-ratio: 4/5; background: var(--surface-3); position: relative; overflow: hidden; }
.post-card .media img, .post-card .media video { width: 100%; height: 100%; object-fit: cover; display: block; }
.post-card .media::after { content: ""; position: absolute; inset: auto 0 0 0; height: 40%; background: linear-gradient(transparent, rgba(28, 29, 34, .55)); pointer-events: none; }
.post-card .media .type, .post-card .media .multi { position: absolute; top: 10px; background: rgba(28, 29, 34, .65); color: #fff; font-size: 11px; font-weight: 700; padding: 4px 9px; border-radius: 99px; backdrop-filter: blur(8px); border: 1px solid rgba(255, 255, 255, .12); z-index: 1; }
.post-card .media .type { right: 10px; }
.post-card .media .multi { left: 10px; }
.post-card .body { padding: 15px 17px; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.post-card .cap { font-size: 13px; color: var(--text-2); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-line; }
.post-card .foot { display: flex; gap: 8px; padding: 0 17px 17px; }
.post-card .foot .btn { flex: 1; }

/* ============ Modal ============ */
.modal-bg { position: fixed; inset: 0; background: rgba(12, 12, 16, .68); backdrop-filter: blur(8px); display: flex; align-items: flex-start; justify-content: center; padding: 40px 16px; overflow-y: auto; z-index: 50; animation: fade .18s; }
.modal { background: var(--surface-solid); border: 1px solid var(--line-2); border-radius: 26px; width: 100%; max-width: 660px; box-shadow: var(--shadow-lg), 0 0 60px -30px var(--neon); animation: pop .22s cubic-bezier(.2, .8, .2, 1); position: relative; }
.modal::before { content: ""; position: absolute; left: 30px; right: 30px; top: -1px; height: 1px; background: linear-gradient(90deg, transparent, var(--neon), var(--pudra), transparent); }
.modal.wide { max-width: 940px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 22px 26px; border-bottom: 1px solid var(--line); }
.modal-body { padding: 24px 26px; display: flex; flex-direction: column; gap: 18px; }
.modal-foot { display: flex; gap: 10px; justify-content: flex-end; padding: 16px 26px; border-top: 1px solid var(--line); background: var(--surface-2); border-radius: 0 0 26px 26px; flex-wrap: wrap; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(12px) scale(.985); } }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-check { display: inline-flex; align-items: center; gap: 8px; padding: 5px 13px 5px 5px; border: 1px solid var(--line-2); border-radius: 99px; cursor: pointer; font-weight: 600; font-size: 13px; transition: all .15s; user-select: none; }
.chip-check:hover { border-color: rgba(123, 63, 228, .5); }
.chip-check input { display: none; }
.chip-check:has(input:checked) { border-color: var(--neon); background: var(--brand-soft); box-shadow: 0 0 16px -6px var(--neon); }

.dropzone { border: 1.5px dashed var(--line-2); border-radius: 16px; padding: 24px; text-align: center; color: var(--text-3); cursor: pointer; transition: all .18s; }
.dropzone:hover, .dropzone.over { border-color: var(--neon); background: var(--brand-soft); color: var(--text); }
.dropzone svg { width: 26px; height: 26px; margin-bottom: 4px; color: var(--lavanta); }
.previews { display: flex; gap: 10px; flex-wrap: wrap; }
.pv { position: relative; width: 98px; height: 98px; border-radius: 14px; overflow: hidden; background: #000; border: 1px solid var(--line-2); }
.pv img, .pv video { width: 100%; height: 100%; object-fit: cover; }
.pv .x { position: absolute; top: 5px; right: 5px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .65); color: #fff; cursor: pointer; font-size: 13px; line-height: 1; }
.pv .n { position: absolute; left: 6px; bottom: 6px; background: rgba(0, 0, 0, .65); color: #fff; font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 6px; }

.alert { display: flex; gap: 11px; padding: 13px 15px; border-radius: 14px; font-size: 13.5px; align-items: flex-start; border: 1px solid transparent; }
.alert svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.alert.ok { background: var(--ok-soft); color: var(--ok); border-color: rgba(91, 214, 166, .18); }
.alert.warn { background: var(--warn-soft); color: var(--warn); border-color: rgba(242, 186, 94, .2); }
.alert.bad { background: var(--bad-soft); color: var(--bad); border-color: rgba(238, 68, 82, .22); }
.alert.info { background: var(--info-soft); color: var(--info); border-color: rgba(217, 184, 240, .18); }
.alert b { font-weight: 700; }
.alert .t { color: var(--text); }

#toasts { position: fixed; bottom: 24px; right: 24px; display: flex; flex-direction: column; gap: 10px; z-index: 100; }
.toast { background: var(--surface-solid); color: var(--text); padding: 13px 17px; border-radius: 14px; border: 1px solid rgba(123, 63, 228, .45); box-shadow: var(--shadow-lg), 0 0 24px -8px var(--neon); font-weight: 600; font-size: 13.5px; max-width: 380px; animation: pop .22s; display: flex; gap: 10px; align-items: center; }
.toast svg { color: var(--ok); }
.toast.err { border-color: rgba(238, 68, 82, .6); box-shadow: var(--shadow-lg), 0 0 24px -8px var(--bad); }
.toast.err svg { color: var(--bad); }

/* ============ Giriş ekranı ============ */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.auth-art {
  position: relative; overflow: hidden; color: var(--kirik); padding: 44px 56px; display: flex; flex-direction: column; justify-content: center; gap: 40px;
  background: radial-gradient(60% 50% at 50% 38%, rgba(123, 63, 228, .4), transparent 70%), linear-gradient(160deg, #2A2140 0%, #1C1D22 72%);
  border-right: 1px solid var(--line);
}
.auth-hero { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 40px; position: relative; }
.neon-ring {
  width: 240px; height: 240px; border-radius: 50%; overflow: hidden; position: relative;
  box-shadow: 0 0 0 2px #B98BFF, 0 0 22px 4px rgba(123, 63, 228, .9), 0 0 90px 12px rgba(123, 63, 228, .45);
  animation: breathe 5s ease-in-out infinite;
}
.neon-ring img { width: 100%; height: 100%; object-fit: cover; display: block; transform: scale(1.04); }
@keyframes breathe { 50% { box-shadow: 0 0 0 2px #C9A3FF, 0 0 30px 6px rgba(123, 63, 228, 1), 0 0 120px 18px rgba(123, 63, 228, .5); } }
@media (prefers-reduced-motion: reduce) { .neon-ring { animation: none; } }
.auth-art p { font-size: 15.5px; color: rgba(244, 242, 239, .72); max-width: 440px; line-height: 1.65; margin: 0 auto; }
.auth-art .wordmark .wm-top { color: var(--kirik); }
.auth-form { display: grid; place-items: center; padding: 40px 24px; }
.auth-form form { width: 100%; max-width: 390px; display: flex; flex-direction: column; gap: 18px; }
.auth-form .btn { height: 48px; font-size: 14.5px; }
.feature-list { display: flex; justify-content: center; gap: 24px; flex-wrap: wrap; position: relative; }
.feature-list div { display: flex; align-items: center; gap: 9px; font-weight: 600; font-size: 13px; color: rgba(244, 242, 239, .8); }
.feature-list svg { width: 16px; height: 16px; color: var(--lavanta); }

/* ============ Belge (fatura / sözleşme) — kâğıt ============ */
.doc { background: #FFFFFF; color: #1C1D22; border-radius: 20px; box-shadow: var(--shadow); max-width: 880px; margin: 0 auto; overflow: hidden; border: 1px solid rgba(42, 33, 64, .12); position: relative; }
.doc-head {
  padding: 30px 40px; display: flex; justify-content: space-between; gap: 24px; align-items: center; position: relative; color: var(--kirik);
  background: radial-gradient(80% 160% at 100% 0%, rgba(123, 63, 228, .55), transparent 60%), linear-gradient(135deg, #2A2140, #1C1D22);
}
.doc-head::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: linear-gradient(90deg, #7B3FE4, #E7A3C8); }
.doc-head h1 { color: #fff; font-size: 26px; }
.doc-head .muted { color: rgba(244, 242, 239, .62); }
.doc-head .party { color: rgba(244, 242, 239, .85); }
.doc-head .party b { color: #fff; }
.doc-head .wordmark .wm-top { color: var(--kirik); }
.doc-body { padding: 30px 40px 38px; }
.doc .brand-mark { width: 54px; height: 54px; }
.doc .muted { color: #85838F; }
.doc-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-bottom: 26px; }
.doc-meta div span { display: block; font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .14em; color: #85838F; margin-bottom: 5px; }
.doc-meta div b { font-size: 14px; }
.doc table { width: 100%; border-collapse: collapse; margin: 8px 0 18px; }
.doc th { text-align: left; font-size: 10.5px; text-transform: uppercase; letter-spacing: .14em; color: #85838F; padding: 10px 0; border-bottom: 2px solid #1C1D22; }
.doc td { padding: 14px 0; border-bottom: 1px solid #ECE8F3; }
.doc .num { text-align: right; font-variant-numeric: tabular-nums; }
.doc-totals { margin-left: auto; width: 300px; }
.doc-totals div { display: flex; justify-content: space-between; padding: 7px 0; font-variant-numeric: tabular-nums; }
.doc-totals .grand { border-top: 2px solid currentColor; margin-top: 6px; padding-top: 12px; font-family: var(--font-display); font-size: 21px; font-weight: 800; }
.pay-box { margin-top: 28px; border-radius: 16px; background: #F5EFFC; border: 1px solid #E6D9F7; padding: 20px 22px; display: grid; grid-template-columns: 1fr auto; gap: 14px; align-items: center; }
.pay-box .iban { font-family: var(--font-mono); font-size: 15.5px; font-weight: 700; letter-spacing: .03em; color: #1C1D22; }
.pay-box .btn { background: #fff; color: #1C1D22; border-color: #DCCEF0; }
.stamp { position: absolute; left: 44px; bottom: 96px; transform: rotate(-11deg); border: 3px solid #17996B; color: #17996B; font-family: var(--font-brand); font-style: italic; font-weight: 800; font-size: 26px; padding: 2px 20px; border-radius: 10px; letter-spacing: .14em; background: rgba(255, 255, 255, .9); z-index: 2; }
.stamp.bad { border-color: #C8202E; color: #C8202E; }
.party { font-size: 13.5px; line-height: 1.6; }
.party b { font-size: 14.5px; }
.contract-text { font-size: 14.5px; line-height: 1.8; color: #2E2D38; }
.contract-text h3 { font-size: 15px; margin: 28px 0 8px; color: #1C1D22; padding-left: 12px; border-left: 3px solid #7B3FE4; }
.contract-text p { margin: 0 0 10px; }

/* ============ Rapor ============ */
.report-hero { background: var(--grad-night); color: var(--kirik); border-radius: 26px; padding: 34px 36px; position: relative; overflow: hidden; border: 1px solid rgba(217, 184, 240, .2); }
.report-hero::before { content: ""; position: absolute; width: 360px; height: 360px; border-radius: 50%; right: -110px; top: -170px; box-shadow: 0 0 0 2px rgba(185, 139, 255, .6), 0 0 40px 6px rgba(123, 63, 228, .55); }
.report-hero::after { content: ""; position: absolute; left: 36px; right: 36px; bottom: 0; height: 2px; background: linear-gradient(90deg, transparent, var(--neon), var(--pudra), transparent); box-shadow: 0 0 14px var(--neon); }
.report-hero .eyebrow { color: rgba(244, 242, 239, .72); position: relative; }
.report-hero h1 {
  font-family: var(--font-brand); font-style: italic; font-weight: 800; font-size: 50px; letter-spacing: .01em; text-transform: uppercase; position: relative; line-height: 1; margin-top: 10px;
  background: linear-gradient(180deg, #FFFFFF 15%, var(--lavanta)); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.report-hero p { color: rgba(244, 242, 239, .72); position: relative; margin-top: 8px; }
.hero-stats { display: flex; gap: 36px; flex-wrap: wrap; margin-top: 28px; position: relative; }
.hero-stats .k { font-size: 12px; color: rgba(244, 242, 239, .65); }
.hero-stats .v { font-family: var(--font-display); font-size: 28px; font-weight: 800; letter-spacing: -.03em; color: #fff; font-variant-numeric: tabular-nums; }
.hero-stats .v.accent { color: var(--pudra); }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.kpi { padding: 19px 21px; }
.kpi .label { font-size: 12px; font-weight: 600; color: var(--text-3); }
.kpi .value { font-family: var(--font-display); font-size: 25px; font-weight: 800; letter-spacing: -.035em; margin: 7px 0 5px; font-variant-numeric: tabular-nums; }
.chart-box { position: relative; height: 260px; }
.prose { white-space: pre-line; line-height: 1.75; color: var(--text-2); }

/* Ödeme kartı */
.bank-card {
  border-radius: 24px; padding: 26px; color: var(--kirik); position: relative; overflow: hidden;
  background: radial-gradient(90% 120% at 100% 100%, rgba(123, 63, 228, .7), transparent 60%), linear-gradient(150deg, #2A2140 0%, #1C1D22 75%);
  border: 1px solid rgba(217, 184, 240, .22); box-shadow: var(--shadow-lg), 0 0 40px -20px var(--neon);
}
.bank-card::after { content: ""; position: absolute; right: -50px; bottom: -70px; width: 200px; height: 200px; border-radius: 50%; box-shadow: 0 0 0 2px rgba(185, 139, 255, .55), 0 0 30px 4px rgba(123, 63, 228, .5); }
.bank-card > * { position: relative; z-index: 1; }
.bank-card .iban { font-family: var(--font-mono); font-size: 16px; letter-spacing: .05em; margin: 20px 0 6px; word-break: break-all; color: #fff; }
.bank-card small { color: rgba(244, 242, 239, .62); }
.bank-card .amount { font-family: var(--font-display); font-size: 28px; font-weight: 800; letter-spacing: -.03em; margin-top: 18px; color: var(--pudra); }

.timeline { display: flex; flex-direction: column; }
.timeline .ti { display: flex; gap: 13px; padding: 10px 24px; position: relative; }
.timeline .ti::before { content: ""; position: absolute; left: 28px; top: 26px; bottom: -10px; width: 1px; background: var(--line-2); }
.timeline .ti:last-child::before { display: none; }
.timeline .dot { margin-top: 6px; width: 9px; height: 9px; background: var(--neon); box-shadow: 0 0 0 4px var(--brand-soft), 0 0 10px var(--neon); }
.timeline .dot.musteri { background: var(--pudra); box-shadow: 0 0 0 4px rgba(231, 163, 200, .15), 0 0 10px var(--pudra); }
.timeline .dot.sistem { background: var(--duman); box-shadow: 0 0 0 4px var(--surface-3); }

.loading { display: grid; place-items: center; padding: 70px; color: var(--text-3); }
.spinner { width: 28px; height: 28px; border: 3px solid var(--line-2); border-top-color: var(--neon); border-radius: 50%; animation: spin .7s linear infinite; filter: drop-shadow(0 0 6px var(--neon)); }
@keyframes spin { to { transform: rotate(360deg); } }
* { scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }

/* ============ Mobil ============ */
@media (max-width: 1100px) {
  .cols-dash { grid-template-columns: 1fr; }
  .kpis, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: fixed; inset: 0 auto 0 0; width: 280px; z-index: 40; transform: translateX(-100%); transition: transform .22s; box-shadow: var(--shadow-lg); background: var(--surface-solid); }
  body.nav-open .sidebar { transform: none; }
  body.nav-open::after { content: ""; position: fixed; inset: 0; background: rgba(0, 0, 0, .55); z-index: 30; }
  .mobile-bar { display: flex; align-items: center; gap: 12px; padding: 10px 16px; background: var(--surface-solid); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
  .mobile-bar .brand { padding: 0; }
  .mobile-bar .brand-mark { width: 34px; height: 34px; }
  .main { padding: 22px 16px 50px; }
  .auth { grid-template-columns: 1fr; }
  .auth-art { padding: 36px 22px; border-right: 0; border-bottom: 1px solid var(--line); gap: 24px; }
  .auth-hero { gap: 26px; }
  .neon-ring { width: 140px; height: 140px; }
  .wordmark.lg .wm-main { font-size: 36px; }
  .wordmark.lg .wm-top { font-size: 11px; letter-spacing: .42em; margin-right: -.42em; }
  .auth-art p, .auth-art .feature-list { display: none; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .span-2 { grid-column: auto; }
  .cal .day { min-height: 76px; padding: 4px; }
  .ev { font-size: 0; padding: 3px; gap: 0; }
  .ev img { width: 100%; height: 22px; }
  .ev .t, .ev .st { display: none; }
  .doc-head, .doc-body { padding: 24px 20px; }
  .doc-head { flex-wrap: wrap; }
  .doc-meta { grid-template-columns: 1fr 1fr; }
  .doc-totals { width: 100%; }
  .pay-box { grid-template-columns: 1fr; }
  .stamp { left: auto; bottom: 18px; right: 20px; font-size: 20px; }
  .report-hero { padding: 26px 22px; }
  .report-hero h1 { font-size: 36px; }
  .hide-sm { display: none; }
  h1 { font-size: 23px; }
}
@media (max-width: 520px) {
  .kpis, .grid-4 { grid-template-columns: 1fr 1fr; }
  .kpi .value, .stat .value { font-size: 21px; }
  .hero-stats .v { font-size: 22px; }
}

/* ============ Yazdırma ============ */
@media print {
  @page { margin: 12mm; }
  body { background: #fff !important; color: #1C1D22; }
  .sidebar, .mobile-bar, .topbar .actions, .no-print, #toasts { display: none !important; }
  .layout { display: block; }
  .main { padding: 0; max-width: none; }
  .doc, .card { box-shadow: none !important; }
  .report-hero, .stat.hero, .doc-head, .bank-card, .kpi, .card, .pay-box { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .card, .kpi { break-inside: avoid; }
  body:has(.modal-bg) .layout, body:has(.modal-bg) .mobile-bar { display: none !important; }
  .modal-bg { position: static; background: none; padding: 0; backdrop-filter: none; overflow: visible; }
  .modal { box-shadow: none; max-width: none; border: 0; border-radius: 0; background: #fff; }
  .modal::before { display: none; }
  .modal-head, .modal-foot, .modal-body > .alert, .modal-body > .row { display: none !important; }
  .modal-body { padding: 0; }
  .modal-body > div[style] { background: none !important; padding: 0 !important; }
}
