/* ============================================================================
   XarpeonPrivLive — Design System v2
   Premium dark UI · katmanlı yüzeyler · gradient vurgular · mikro etkileşimler
   ============================================================================ */

:root {
  /* ---- renk ---- */
  --bg: #04060d;
  --bg-2: #070b16;
  --surface-1: #0c1220;
  --surface-2: #111829;
  --surface-3: #16203a;
  --surface-4: #1c2745;

  --glass: rgba(15, 21, 38, 0.66);
  --glass-strong: rgba(11, 16, 30, 0.86);

  --line: rgba(255, 255, 255, 0.055);
  --line-2: rgba(255, 255, 255, 0.09);
  --line-3: rgba(255, 255, 255, 0.15);
  --highlight: rgba(255, 255, 255, 0.045);

  --text: #eef2fb;
  --text-2: #a8b3ce;
  --text-3: #74809e;
  --text-4: #4e5878;

  --indigo: #6366f1;
  --indigo-2: #818cf8;
  --cyan: #22d3ee;
  --violet: #a855f7;
  --green: #22c55e;
  --amber: #f59e0b;
  --rose: #f43f5e;
  --sky: #38bdf8;

  --grad: linear-gradient(135deg, #6366f1 0%, #22d3ee 100%);
  --grad-2: linear-gradient(135deg, #a855f7 0%, #6366f1 100%);
  --grad-text: linear-gradient(100deg, #c7d2fe 0%, #67e8f9 55%, #c4b5fd 100%);
  --grad-surface: linear-gradient(160deg, rgba(99, 102, 241, 0.16), rgba(34, 211, 238, 0.06) 45%, transparent 75%);

  --tint-indigo: rgba(99, 102, 241, 0.13);
  --tint-green: rgba(34, 197, 94, 0.12);
  --tint-amber: rgba(245, 158, 11, 0.12);
  --tint-rose: rgba(244, 63, 94, 0.12);
  --tint-sky: rgba(56, 189, 248, 0.12);

  /* ---- ölçü ---- */
  --r-xs: 8px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 18px;
  --r-xl: 24px;
  --r-full: 999px;

  --sp-1: 4px;  --sp-2: 8px;  --sp-3: 12px; --sp-4: 16px;
  --sp-5: 20px; --sp-6: 24px; --sp-8: 32px; --sp-10: 40px;

  --sidebar: 264px;
  --topbar: 68px;

  /* ---- gölge ---- */
  --sh-1: 0 1px 2px rgba(0, 0, 0, 0.4);
  --sh-2: 0 8px 24px rgba(0, 0, 0, 0.36);
  --sh-3: 0 22px 60px rgba(0, 0, 0, 0.5);
  --sh-glow: 0 14px 40px rgba(99, 102, 241, 0.3);
  --sh-inset: inset 0 1px 0 rgba(255, 255, 255, 0.05);

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --fast: 140ms var(--ease);
  --base: 200ms var(--ease);

  --font: "Inter", "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", "Cascadia Mono", ui-monospace, Consolas, monospace;
}

* { box-sizing: border-box; }
*::selection { background: rgba(99, 102, 241, 0.4); }

html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14.5px;
  line-height: 1.6;
  letter-spacing: -0.006em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "cv11", "ss01";
}

/* atmosfer: mesh gradient + ince ızgara */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(1100px 620px at 8% -12%, rgba(99, 102, 241, 0.2), transparent 60%),
    radial-gradient(900px 520px at 96% 2%, rgba(34, 211, 238, 0.14), transparent 58%),
    radial-gradient(820px 620px at 62% 112%, rgba(168, 85, 247, 0.13), transparent 60%);
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.016) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.016) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(120% 90% at 50% 0%, #000 20%, transparent 78%);
}

h1, h2, h3, h4, h5 { margin: 0; font-weight: 640; letter-spacing: -0.024em; color: #fff; }
h1 { font-size: 30px; line-height: 1.15; }
h2 { font-size: 19px; }
h3 { font-size: 16px; }
h4 { font-size: 15px; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; }

::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.085);
  border-radius: var(--r-full);
  border: 3px solid transparent;
  background-clip: content-box;
}
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.18); background-clip: content-box; }

:focus-visible {
  outline: 2px solid rgba(129, 140, 248, 0.85);
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------- yardımcılar ---------- */
.muted { color: var(--text-2); }
.faint { color: var(--text-3); }
.dim { color: var(--text-4); }
.small { font-size: 12.5px; }
.tiny { font-size: 11.5px; }
.mono { font-family: var(--mono); font-size: 12.5px; letter-spacing: -0.01em; }
.nowrap { white-space: nowrap; }
.center { text-align: center; }
.right { text-align: right; }
.hidden { display: none !important; }
.grow { flex: 1; }
.row { display: flex; gap: var(--sp-3); align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.row.end { justify-content: flex-end; }
.row.tight { gap: var(--sp-2); }
.col { display: flex; flex-direction: column; gap: var(--sp-3); }
.grad-text { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; }
.mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; }
.divider { height: 1px; background: var(--line); margin: var(--sp-4) 0; }
.divider-v { width: 1px; align-self: stretch; background: var(--line); }

/* ============================== AUTH ============================== */

.auth-shell { position: relative; z-index: 1; min-height: 100vh; display: grid; grid-template-columns: 1.08fr 0.92fr; }

.auth-brand {
  position: relative;
  padding: 56px 60px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--sp-8);
  border-right: 1px solid var(--line);
  overflow: hidden;
}
.auth-brand::before {
  content: "";
  position: absolute;
  width: 620px; height: 620px;
  right: -220px; top: -160px;
  background: radial-gradient(circle at 30% 30%, rgba(99, 102, 241, 0.5), transparent 62%);
  filter: blur(30px);
  animation: float 16s ease-in-out infinite;
}

.brand-logo { display: flex; align-items: center; gap: 13px; position: relative; z-index: 1; }
.brand-mark {
  position: relative;
  width: 46px; height: 46px;
  border-radius: var(--r-md);
  background: var(--grad);
  display: grid; place-items: center;
  font-weight: 800; font-size: 20px; color: #fff;
  box-shadow: var(--sh-glow), var(--sh-inset);
}
.brand-mark::after {
  content: "";
  position: absolute; inset: 1px;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.28), transparent 55%);
  pointer-events: none;
}

/* Marka logosu gorsel olarak kullanildiginda */
.brand-mark.has-img {
  overflow: hidden;
  padding: 0;
  background: #0b1119 !important;
  box-shadow: 0 8px 24px -12px rgba(52, 211, 153, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.brand-mark.has-img::after { display: none; }
.brand-mark img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brand-name { font-size: 20px; font-weight: 680; letter-spacing: -0.03em; }
.brand-sub { font-size: 11px; color: var(--text-3); letter-spacing: 0.18em; text-transform: uppercase; margin-top: 1px; }

.auth-hero { position: relative; z-index: 1; max-width: 540px; }
.auth-hero .eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 13px; margin-bottom: 22px;
  border-radius: var(--r-full);
  background: rgba(99, 102, 241, 0.12);
  border: 1px solid rgba(99, 102, 241, 0.28);
  color: #c7d2fe; font-size: 12.5px; font-weight: 600;
}
.auth-hero h1 { font-size: 44px; line-height: 1.1; font-weight: 700; margin-bottom: 18px; }
.auth-hero p { color: var(--text-2); font-size: 16px; max-width: 480px; }

.hero-features { display: grid; gap: 14px; margin-top: 34px; position: relative; z-index: 1; }
.hero-feature { display: flex; gap: 13px; align-items: flex-start; font-size: 14.5px; color: var(--text-2); }
.hero-feature b { color: var(--text); font-weight: 620; }
.hero-feature .tick {
  flex: 0 0 24px; height: 24px; border-radius: var(--r-xs);
  background: var(--tint-green); color: #7ee0a1;
  display: grid; place-items: center; font-size: 12px; font-weight: 800;
  border: 1px solid rgba(34, 197, 94, 0.26);
  box-shadow: var(--sh-inset);
}

.auth-stats { display: flex; gap: 40px; position: relative; z-index: 1; flex-wrap: wrap; }
.auth-stat b { display: block; font-size: 26px; font-weight: 700; letter-spacing: -0.03em; }
.auth-stat span { font-size: 11px; color: var(--text-3); text-transform: uppercase; letter-spacing: 0.14em; }

.auth-panel { display: grid; place-items: center; padding: 44px 30px; }

.auth-card {
  position: relative;
  width: 100%; max-width: 432px;
  padding: 34px;
  border-radius: var(--r-xl);
  background: var(--glass-strong);
  border: 1px solid var(--line-2);
  backdrop-filter: blur(24px) saturate(140%);
  box-shadow: var(--sh-3), var(--sh-inset);
  animation: fadeUp 0.55s var(--ease) both;
}

.auth-tabs {
  display: flex; gap: 5px; padding: 5px; margin-bottom: 28px;
  background: rgba(4, 7, 15, 0.7);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}
.auth-tabs button {
  flex: 1; padding: 10px; border: 0; border-radius: var(--r-sm);
  background: transparent; color: var(--text-3);
  font-size: 13.5px; font-weight: 620; cursor: pointer;
  transition: var(--fast);
}
.auth-tabs button:hover { color: var(--text-2); }
.auth-tabs button.active { background: var(--grad); color: #fff; box-shadow: var(--sh-glow); }

.auth-foot { display: flex; gap: 14px; justify-content: center; margin-top: 26px; }
.auth-foot .tiny { color: var(--text-4); }

/* ============================== FORM ============================== */

.field { margin-bottom: 17px; }
.field > label {
  display: block; margin-bottom: 7px;
  font-size: 12.5px; font-weight: 600; color: var(--text-2); letter-spacing: 0.005em;
}
.field .hint { margin-top: 6px; font-size: 12px; color: var(--text-4); }
.field-group { position: relative; }
.field-icon {
  position: absolute; left: 13px; top: 50%; transform: translateY(-50%);
  color: var(--text-4); font-size: 14px; pointer-events: none;
}
.field-group input { padding-left: 38px; }
.field-action {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  border: 0; background: transparent; color: var(--text-3); cursor: pointer;
  padding: 6px 8px; border-radius: var(--r-xs); font-size: 13px; transition: var(--fast);
}
.field-action:hover { color: var(--text); background: var(--surface-3); }

input, select, textarea {
  width: 100%;
  padding: 12px 14px;
  background: rgba(4, 7, 15, 0.72);
  border: 1px solid var(--line-2);
  border-radius: var(--r-sm);
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  transition: border-color var(--fast), box-shadow var(--fast), background var(--fast);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.3);
}
textarea { resize: vertical; min-height: 92px; line-height: 1.6; }
input::placeholder, textarea::placeholder { color: var(--text-4); }
input:hover, select:hover, textarea:hover { border-color: var(--line-3); }
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: rgba(129, 140, 248, 0.75);
  background: rgba(4, 7, 15, 0.92);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.16);
}
input:disabled, select:disabled { color: var(--text-3); background: rgba(255, 255, 255, 0.02); cursor: not-allowed; }
select {
  appearance: none; padding-right: 38px; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-3) 50%), linear-gradient(135deg, var(--text-3) 50%, transparent 50%);
  background-position: calc(100% - 20px) 51%, calc(100% - 15px) 51%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
input[type="checkbox"] { width: auto; accent-color: var(--indigo); box-shadow: none; cursor: pointer; }

/* ============================== BUTONLAR ============================== */

.btn {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line-2);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015));
  color: var(--text);
  font-size: 13.5px; font-weight: 600; cursor: pointer;
  transition: transform var(--fast), box-shadow var(--fast), border-color var(--fast), background var(--fast), color var(--fast);
  white-space: nowrap; overflow: hidden;
  box-shadow: var(--sh-inset);
}
.btn:hover:not(:disabled) { border-color: var(--line-3); transform: translateY(-1px); box-shadow: var(--sh-2), var(--sh-inset); }
.btn:active:not(:disabled) { transform: translateY(0); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }

.btn.primary {
  background: var(--grad);
  border-color: transparent;
  color: #fff;
  box-shadow: var(--sh-glow), var(--sh-inset);
}
.btn.primary::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.22), transparent 52%);
  opacity: 0.9; pointer-events: none;
}
.btn.primary:hover:not(:disabled) { box-shadow: 0 20px 52px rgba(99, 102, 241, 0.42), var(--sh-inset); }

.btn.ghost { background: transparent; border-color: transparent; color: var(--text-2); box-shadow: none; }
.btn.ghost:hover:not(:disabled) { background: rgba(255, 255, 255, 0.05); color: var(--text); border-color: var(--line); }

.btn.danger { background: var(--tint-rose); border-color: rgba(244, 63, 94, 0.3); color: #ffb3c1; }
.btn.danger:hover:not(:disabled) { border-color: rgba(244, 63, 94, 0.55); box-shadow: 0 10px 26px rgba(244, 63, 94, 0.18); }
.btn.success { background: var(--tint-green); border-color: rgba(34, 197, 94, 0.3); color: #a7f3c4; }
.btn.success:hover:not(:disabled) { border-color: rgba(34, 197, 94, 0.55); }

.btn.sm { padding: 7px 12px; font-size: 12.5px; border-radius: var(--r-xs); }
.btn.lg { padding: 14px 24px; font-size: 15px; border-radius: var(--r-md); }
.btn.block { width: 100%; }
.btn.icon { padding: 9px; width: 36px; height: 36px; }
.btn.loading { pointer-events: none; opacity: 0.8; }
.btn .spinner {
  width: 14px; height: 14px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.3); border-top-color: #fff;
  animation: spin 0.65s linear infinite;
}

.iconbtn {
  display: inline-grid; place-items: center;
  width: 36px; height: 36px;
  border-radius: var(--r-sm);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
  color: var(--text-2); cursor: pointer; font-size: 15px;
  transition: var(--fast); position: relative;
}
.iconbtn:hover { color: var(--text); border-color: var(--line-3); background: rgba(255, 255, 255, 0.055); }
.iconbtn .badge-count {
  position: absolute; top: -5px; right: -5px;
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: var(--r-full);
  background: var(--rose); color: #fff;
  font-size: 10.5px; font-weight: 700;
  display: grid; place-items: center;
  border: 2px solid var(--bg);
}

/* ============================== UYGULAMA KABUĞU ============================== */

.app { position: relative; z-index: 1; min-height: 100vh; }

.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--sidebar);
  display: flex; flex-direction: column;
  padding: 20px 14px 14px;
  background: linear-gradient(180deg, rgba(9, 13, 25, 0.96), rgba(6, 9, 18, 0.92));
  border-right: 1px solid var(--line);
  backdrop-filter: blur(20px);
  z-index: 40;
  transition: transform 0.26s var(--ease);
}
.sidebar .brand-logo { padding: 2px 10px 22px; }
.sidebar .brand-mark { width: 38px; height: 38px; border-radius: var(--r-sm); font-size: 16px; }
.sidebar .brand-name { font-size: 15.5px; }
.sidebar .brand-sub { font-size: 9.5px; letter-spacing: 0.16em; }

.nav { display: flex; flex-direction: column; gap: 2px; overflow-y: auto; flex: 1; padding-right: 2px; }
.nav::-webkit-scrollbar { width: 6px; }
.nav-label {
  padding: 18px 12px 8px;
  font-size: 10px; font-weight: 700;
  letter-spacing: 0.17em; text-transform: uppercase;
  color: var(--text-4);
}
.nav-item {
  position: relative;
  display: flex; align-items: center; gap: 11px;
  padding: 10px 12px;
  border-radius: var(--r-sm);
  color: var(--text-2); font-size: 13.5px; font-weight: 550;
  border: 1px solid transparent;
  cursor: pointer; transition: var(--fast);
}
.nav-item:hover { background: rgba(255, 255, 255, 0.035); color: var(--text); }
.nav-item .ico {
  display: grid; place-items: center;
  width: 26px; height: 26px; border-radius: var(--r-xs);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  font-size: 12.5px; transition: var(--fast);
  flex: 0 0 auto;
}
.nav-item:hover .ico { border-color: var(--line-3); }
.nav-item.active {
  background: linear-gradient(100deg, rgba(99, 102, 241, 0.22), rgba(34, 211, 238, 0.07));
  border-color: rgba(99, 102, 241, 0.34);
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.nav-item.active .ico { background: var(--grad); border-color: transparent; color: #fff; box-shadow: var(--sh-glow); }
.nav-item.active::before {
  content: "";
  position: absolute; left: -14px; top: 50%; transform: translateY(-50%);
  width: 3px; height: 22px; border-radius: 0 3px 3px 0;
  background: var(--grad);
  box-shadow: 0 0 14px rgba(99, 102, 241, 0.9);
}
.nav-item .badge-dot { margin-left: auto; }

.sidebar-foot { border-top: 1px solid var(--line); padding-top: 12px; margin-top: 10px; }

.plan-card {
  margin-bottom: 10px;
  padding: 13px;
  border-radius: var(--r-md);
  background: var(--grad-surface);
  border: 1px solid rgba(99, 102, 241, 0.24);
}
.plan-card .k { font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); }
.plan-card .v { font-size: 17px; font-weight: 680; letter-spacing: -0.02em; }

.user-chip {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 10px; border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  transition: var(--fast);
}
.user-chip:hover { border-color: var(--line-3); }
.avatar {
  flex: 0 0 auto;
  width: 36px; height: 36px; border-radius: var(--r-sm);
  background: var(--grad); color: #fff;
  display: grid; place-items: center;
  font-size: 13.5px; font-weight: 700;
  box-shadow: var(--sh-inset);
}
.avatar.lg { width: 44px; height: 44px; font-size: 16px; border-radius: var(--r-md); }
.user-chip .name { font-size: 13.5px; font-weight: 620; line-height: 1.25; }
.user-chip .role { font-size: 11px; color: var(--text-4); }

.main { margin-left: var(--sidebar); min-height: 100vh; display: flex; flex-direction: column; }

.topbar {
  position: sticky; top: 0; z-index: 30;
  height: var(--topbar);
  display: flex; align-items: center; gap: var(--sp-3);
  padding: 0 26px;
  background: rgba(5, 8, 16, 0.78);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(22px) saturate(150%);
}
.topbar-title { display: flex; flex-direction: column; justify-content: center; }
.topbar h2 { font-size: 17px; letter-spacing: -0.02em; }
.topbar .sub { font-size: 12.5px; color: var(--text-4); }
.topbar .spacer { flex: 1; }
.topbar-status { display: flex; align-items: center; gap: 8px; padding-right: 4px; }
.hamburger { display: none; }

.content { padding: 26px; max-width: 1480px; width: 100%; margin: 0 auto; flex: 1; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--sp-4); margin-bottom: 20px; flex-wrap: wrap; }
.page-head .kicker { font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-4); }

/* ============================== MENÜ / DROPDOWN ============================== */

.menu-wrap { position: relative; }
.menu {
  position: absolute; right: 0; top: calc(100% + 10px);
  min-width: 240px;
  padding: 7px;
  border-radius: var(--r-md);
  background: var(--glass-strong);
  border: 1px solid var(--line-2);
  box-shadow: var(--sh-3), var(--sh-inset);
  backdrop-filter: blur(22px);
  z-index: 60;
  animation: popIn 0.16s var(--ease) both;
}
.menu.hidden { display: none; }
.menu-head { padding: 10px 12px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.menu-head .name { font-size: 13.5px; font-weight: 640; }
.menu-head .role { font-size: 11.5px; color: var(--text-4); }
.menu-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: var(--r-xs);
  color: var(--text-2); font-size: 13.5px; cursor: pointer;
  transition: var(--fast); border: 0; background: transparent; width: 100%; text-align: left;
}
.menu-item:hover { background: rgba(255, 255, 255, 0.05); color: var(--text); }
.menu-item.danger { color: #ffb3c1; }
.menu-item.danger:hover { background: var(--tint-rose); }
.menu-sep { height: 1px; background: var(--line); margin: 6px 0; }
.menu-empty { padding: 16px 12px; color: var(--text-4); font-size: 12.5px; text-align: center; }
.menu-item .meta { margin-left: auto; font-size: 11.5px; color: var(--text-4); }

/* ============================== KARTLAR ============================== */

.card {
  position: relative;
  padding: 22px;
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, rgba(17, 24, 41, 0.72), rgba(10, 15, 28, 0.72));
  border: 1px solid var(--line-2);
  box-shadow: var(--sh-2), var(--sh-inset);
  backdrop-filter: blur(16px);
}
.card.flat { background: var(--surface-1); }
.card.pad-0 { padding: 0; overflow: hidden; }
.card.tint { background: var(--grad-surface), linear-gradient(180deg, rgba(17, 24, 41, 0.7), rgba(10, 15, 28, 0.7)); }

.card-head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.card-head h3 { font-size: 15.5px; }
.card-head .spacer { flex: 1; }
.card-head .ico-chip {
  width: 32px; height: 32px; border-radius: var(--r-sm);
  display: grid; place-items: center; font-size: 14px;
  background: var(--tint-indigo); border: 1px solid rgba(99, 102, 241, 0.26); color: #c7d2fe;
  box-shadow: var(--sh-inset);
}
.card-head .sub { font-size: 12.5px; color: var(--text-4); }

.grid { display: grid; gap: 18px; }
.grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.split { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: start; }
.grid.packages { grid-template-columns: repeat(auto-fit, minmax(272px, 1fr)); }
.grid + .grid, .grid + .card, .card + .grid, .card + .card { margin-top: 18px; }

/* ---------- KPI ---------- */
.stat {
  position: relative;
  padding: 20px;
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, rgba(17, 24, 41, 0.78), rgba(10, 15, 28, 0.78));
  border: 1px solid var(--line-2);
  box-shadow: var(--sh-2), var(--sh-inset);
  overflow: hidden;
  animation: fadeUp 0.5s var(--ease) both;
  transition: transform var(--base), border-color var(--base);
}
.stat:hover { transform: translateY(-2px); border-color: var(--line-3); }
.stat::before {
  content: "";
  position: absolute; inset: 0 0 auto 0; height: 2px;
  background: var(--grad); opacity: 0.85;
}
.stat.c2::before { background: linear-gradient(90deg, #a855f7, #6366f1); }
.stat.c3::before { background: linear-gradient(90deg, #22c55e, #22d3ee); }
.stat.c4::before { background: linear-gradient(90deg, #f59e0b, #f43f5e); }
.stat .top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.stat .ico {
  width: 40px; height: 40px; border-radius: var(--r-sm);
  display: grid; place-items: center; font-size: 17px;
  background: var(--tint-indigo); border: 1px solid rgba(99, 102, 241, 0.24); color: #c7d2fe;
  box-shadow: var(--sh-inset);
}
.stat .k { margin-top: 14px; font-size: 11px; font-weight: 650; letter-spacing: 0.13em; text-transform: uppercase; color: var(--text-4); }
.stat .v { font-size: 28px; font-weight: 700; letter-spacing: -0.035em; line-height: 1.15; margin-top: 2px; }
.stat .d { font-size: 12.5px; color: var(--text-3); margin-top: 2px; }
.stat .spark { margin-top: 10px; height: 34px; }

.trend {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 9px; border-radius: var(--r-full);
  font-size: 11.5px; font-weight: 650;
  background: var(--tint-green); color: #8ce8ad; border: 1px solid rgba(34, 197, 94, 0.24);
}
.trend.down { background: var(--tint-rose); color: #ffb3c1; border-color: rgba(244, 63, 94, 0.24); }
.trend.flat { background: rgba(255, 255, 255, 0.05); color: var(--text-2); border-color: var(--line-2); }

/* ---------- grafik ---------- */
.chart { position: relative; }
.chart svg { display: block; width: 100%; height: 190px; overflow: visible; }
.chart-legend { display: flex; gap: 16px; margin-top: 12px; flex-wrap: wrap; }
.chart-legend span { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--text-3); }
.chart-legend i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }
.chart-grid line { stroke: rgba(255, 255, 255, 0.055); stroke-width: 1; }
.chart-axis text { fill: var(--text-4); font-size: 10.5px; font-family: var(--font); }
.spark path.area { fill: url(#sparkFill); }
.spark path.line { fill: none; stroke: url(#sparkStroke); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }

/* ============================== PAKETLER ============================== */

.pkg {
  position: relative;
  display: flex; flex-direction: column; gap: 16px;
  padding: 26px 24px;
  border-radius: var(--r-xl);
  background: linear-gradient(180deg, rgba(23, 31, 54, 0.9), rgba(11, 16, 30, 0.9));
  border: 1px solid var(--line-2);
  transition: transform var(--base), box-shadow var(--base), border-color var(--base);
  animation: fadeUp 0.5s var(--ease) both;
  overflow: hidden;
}
.pkg::after {
  content: "";
  position: absolute; inset: -1px -1px auto -1px; height: 130px;
  background: radial-gradient(90% 100% at 50% 0%, rgba(99, 102, 241, 0.16), transparent 70%);
  pointer-events: none;
}
.pkg:hover { transform: translateY(-5px); border-color: rgba(99, 102, 241, 0.45); box-shadow: var(--sh-3); }
.pkg.popular { border-color: rgba(99, 102, 241, 0.55); box-shadow: var(--sh-glow), var(--sh-2); }
.pkg.popular::before {
  content: "EN ÇOK TERCİH EDİLEN";
  position: absolute; top: 16px; right: -42px;
  transform: rotate(38deg);
  padding: 5px 46px;
  background: var(--grad); color: #fff;
  font-size: 9.5px; font-weight: 800; letter-spacing: 0.12em;
  box-shadow: var(--sh-2);
}
.pkg > * { position: relative; z-index: 1; }
.pkg h4 { font-size: 19px; letter-spacing: -0.02em; }
.pkg .tagline { font-size: 13px; color: var(--text-3); min-height: 20px; }
.pkg .price { font-size: 36px; font-weight: 750; letter-spacing: -0.04em; line-height: 1; }
.pkg .price small { font-size: 15px; font-weight: 600; color: var(--text-3); margin-left: 3px; }
.pkg .hits {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 13px; border-radius: var(--r-full);
  background: var(--tint-green); color: #9df0b8;
  border: 1px solid rgba(34, 197, 94, 0.28);
  font-size: 13px; font-weight: 650;
}
.pkg .bonus { font-size: 12.5px; font-weight: 650; color: #fcd9a0; }
.pkg ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.pkg li { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; color: var(--text-2); }
.pkg li::before { content: "✓"; color: var(--green); font-weight: 800; font-size: 12px; margin-top: 2px; }
.pkg .foot { margin-top: auto; }

/* ============================== TABLO ============================== */

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: separate; border-spacing: 0; }
thead th {
  position: sticky; top: 0; z-index: 2;
  padding: 11px 16px;
  background: rgba(8, 12, 23, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line-2);
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--text-3); text-align: left; white-space: nowrap;
}
tbody td { padding: 14px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tbody tr { transition: background var(--fast); }
tbody tr:hover { background: rgba(255, 255, 255, 0.022); }
tbody tr:last-child td { border-bottom: 0; }
td .cell-main { font-weight: 600; color: var(--text); }
td .cell-sub { font-size: 12px; color: var(--text-3); }
td.num { font-variant-numeric: tabular-nums; }

/* ============================== ETİKET ============================== */

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: var(--r-full);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line-2);
  color: var(--text-2);
  font-size: 12px; font-weight: 620; white-space: nowrap;
}
.badge.success { background: var(--tint-green); color: #9df0b8; border-color: rgba(34, 197, 94, 0.26); }
.badge.warning { background: var(--tint-amber); color: #fcd9a0; border-color: rgba(245, 158, 11, 0.26); }
.badge.danger { background: var(--tint-rose); color: #ffb3c1; border-color: rgba(244, 63, 94, 0.26); }
.badge.info { background: var(--tint-sky); color: #bae6fd; border-color: rgba(56, 189, 248, 0.26); }
.badge.primary { background: var(--tint-indigo); color: #c7d2fe; border-color: rgba(99, 102, 241, 0.3); }
.badge.plain { background: transparent; }

.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--text-4); display: inline-block; }
.dot.on { background: var(--green); box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.16); animation: pulse 2.4s var(--ease) infinite; }
.dot.off { background: var(--rose); box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.16); }
.dot.warn { background: var(--amber); box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.16); }

.tag { display: inline-flex; align-items: center; padding: 3px 8px; border-radius: var(--r-xs); background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); font-size: 11.5px; color: var(--text-3); }

/* ============================== KONSOL ============================== */

.console {
  display: flex; flex-direction: column;
  background: #04070e;
  border: 1px solid var(--line-2);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-2), var(--sh-inset);
}
.console-head {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 14px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--line);
}
.console-head .title { font-size: 12.5px; font-weight: 650; color: var(--text-2); letter-spacing: 0.02em; }
.console-head .spacer { flex: 1; }
.console-filters { display: flex; gap: 4px; padding: 3px; background: rgba(0, 0, 0, 0.35); border: 1px solid var(--line); border-radius: var(--r-xs); }
.console-filters button {
  border: 0; background: transparent; color: var(--text-4);
  font-size: 11px; font-weight: 650; padding: 4px 9px; border-radius: 6px; cursor: pointer; transition: var(--fast);
}
.console-filters button:hover { color: var(--text-2); }
.console-filters button.active { background: rgba(255, 255, 255, 0.09); color: var(--text); }

.console-body {
  height: 304px; overflow-y: auto;
  padding: 12px 14px;
  font-family: var(--mono); font-size: 12.2px; line-height: 1.7;
}
.console-body .line {
  display: flex; gap: 11px;
  padding: 1px 6px; margin: 0 -6px;
  border-radius: 5px;
  white-space: pre-wrap; word-break: break-word;
  transition: background var(--fast);
}
.console-body .line:hover { background: rgba(255, 255, 255, 0.035); }
.console-body .line.hidden-line { display: none; }
.console-body .t { color: #46527a; flex: 0 0 auto; font-variant-numeric: tabular-nums; }
.console-body .lv { flex: 0 0 44px; font-size: 10px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; padding-top: 3px; }
.console-body .lv.info { color: var(--sky); }
.console-body .lv.warn { color: var(--amber); }
.console-body .lv.error { color: var(--rose); }
.console-body .lv.debug { color: #4d5880; }
.console-body .msg { color: #becbe4; }
.console-body .line.error .msg { color: #ffb3c1; }
.console-body .line.warn .msg { color: #fcd9a0; }
.console-body .line.bas .msg { color: #8ce8f5; }
.console-empty { padding: 34px 10px; text-align: center; color: var(--text-4); font-family: var(--font); font-size: 13px; }

/* ============================== METRE / KV ============================== */

.meter { height: 7px; border-radius: var(--r-full); background: rgba(255, 255, 255, 0.06); overflow: hidden; }
.meter > i { display: block; height: 100%; border-radius: var(--r-full); background: var(--grad); transition: width 0.5s var(--ease); }
.meter.success > i { background: linear-gradient(90deg, #22c55e, #4ade80); }
.meter.warning > i { background: linear-gradient(90deg, #f59e0b, #fbbf24); }
.meter.danger > i { background: linear-gradient(90deg, #f43f5e, #fb7185); }

.kv { display: grid; grid-template-columns: auto 1fr; gap: 10px 18px; font-size: 13.5px; }
.kv > span:nth-child(odd) { color: var(--text-3); }
.kv > span:nth-child(even) { text-align: right; font-weight: 550; }

/* ============================== TOAST / MODAL ============================== */

.toasts { position: fixed; top: 18px; right: 18px; z-index: 90; display: flex; flex-direction: column; gap: 10px; max-width: 384px; }
.toast {
  position: relative; overflow: hidden;
  display: flex; gap: 12px; align-items: flex-start;
  padding: 15px 17px;
  border-radius: var(--r-md);
  background: var(--glass-strong);
  border: 1px solid var(--line-2);
  box-shadow: var(--sh-3), var(--sh-inset);
  backdrop-filter: blur(20px);
  animation: slideIn 0.26s var(--ease) both;
}
.toast::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 100%;
  background: var(--grad);
  animation: shrink 5.1s linear forwards;
}
.toast.success::after { background: linear-gradient(90deg, #22c55e, #4ade80); }
.toast.error::after { background: linear-gradient(90deg, #f43f5e, #fb7185); }
.toast.warning::after { background: linear-gradient(90deg, #f59e0b, #fbbf24); }
.toast .ico { font-size: 16px; line-height: 1.3; }
.toast .title { font-size: 13.5px; font-weight: 650; }
.toast .text { font-size: 13px; color: var(--text-2); }

.modal-backdrop {
  position: fixed; inset: 0; z-index: 80;
  display: grid; place-items: center; padding: 20px;
  background: rgba(2, 4, 10, 0.74);
  backdrop-filter: blur(7px);
  animation: fade 0.18s var(--ease) both;
}
.modal {
  width: 100%; max-width: 492px; max-height: 88vh; overflow-y: auto;
  padding: 26px;
  border-radius: var(--r-xl);
  background: linear-gradient(180deg, #131a2d, #0c1220);
  border: 1px solid var(--line-3);
  box-shadow: var(--sh-3), var(--sh-inset);
  animation: popIn 0.22s var(--ease) both;
}
.modal h3 { font-size: 18px; margin-bottom: 6px; }
.modal .modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 24px; }

/* ============================== DİĞER ============================== */

.empty { padding: 52px 20px; text-align: center; color: var(--text-3); }
.empty .ico { font-size: 36px; opacity: 0.5; margin-bottom: 12px; }
.empty .t { font-size: 14px; color: var(--text-2); font-weight: 620; }
.empty .s { font-size: 12.5px; margin-top: 4px; color: var(--text-4); }

.skeleton {
  height: 14px; border-radius: 7px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.085), rgba(255, 255, 255, 0.035));
  background-size: 200% 100%;
  animation: shimmer 1.35s infinite;
}

.alert { display: flex; gap: 12px; padding: 14px 16px; border-radius: var(--r-md); border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.03); font-size: 13.5px; box-shadow: var(--sh-inset); }
.alert.warning { background: var(--tint-amber); border-color: rgba(245, 158, 11, 0.28); color: #fcd9a0; }
.alert.danger { background: var(--tint-rose); border-color: rgba(244, 63, 94, 0.28); color: #ffb3c1; }
.alert.success { background: var(--tint-green); border-color: rgba(34, 197, 94, 0.28); color: #a7f3c4; }
.alert strong { color: #fff; }

.steps { display: flex; gap: 10px; flex-wrap: wrap; }
.step { display: flex; align-items: center; gap: 8px; padding: 8px 13px; border-radius: var(--r-full); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--line); font-size: 12.5px; color: var(--text-3); }
.step b { color: var(--text); font-weight: 620; }

.bars { display: flex; align-items: flex-end; gap: 8px; height: 96px; }
.bars .bar { flex: 1; border-radius: 7px 7px 3px 3px; background: var(--grad-surface); border: 1px solid rgba(99, 102, 241, 0.22); position: relative; min-height: 5px; transition: 0.3s var(--ease); }
.bars .bar:hover { border-color: rgba(99, 102, 241, 0.55); transform: translateY(-2px); }
.bars .bar > span { position: absolute; bottom: -21px; left: 0; right: 0; text-align: center; font-size: 10.5px; color: var(--text-4); }

.scrim { display: none; }
.footer-bar { padding: 20px 26px 26px; text-align: center; color: var(--text-4); font-size: 12px; }

.kbd {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 6px; border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line-2);
  font-family: var(--mono); font-size: 11px; color: var(--text-3);
}

/* ---------- bar chart (HTML) ---------- */
.chart-bars { position: relative; padding-top: 6px; }
.cb-grid {
  position: absolute; left: 0; right: 0; top: 6px; bottom: 30px;
  display: flex; flex-direction: column; justify-content: space-between;
  pointer-events: none;
}
.cb-grid span { height: 1px; background: rgba(255, 255, 255, 0.055); }
.cb-inner { display: flex; align-items: flex-end; gap: 10px; height: 168px; padding-bottom: 30px; }
.cb-col {
  flex: 1; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 7px;
}
.cb-val { font-size: 11px; font-weight: 700; color: #c7d2fe; min-height: 14px; }
.cb-bar {
  width: 64%; max-width: 46px; min-height: 4px;
  border-radius: 8px 8px 4px 4px;
  background: linear-gradient(180deg, rgba(34, 211, 238, 0.85), rgba(99, 102, 241, 0.45));
  border: 1px solid rgba(99, 102, 241, 0.32);
  box-shadow: 0 -6px 22px rgba(99, 102, 241, 0.22);
  transition: height 0.55s var(--ease), transform var(--fast), border-color var(--fast);
}
.cb-col:hover .cb-bar { transform: translateY(-3px); border-color: rgba(99, 102, 241, 0.7); }
.cb-col.empty .cb-bar { background: rgba(255, 255, 255, 0.05); border-color: var(--line); box-shadow: none; }
.cb-labels { position: absolute; left: 0; right: 0; bottom: 0; display: flex; gap: 10px; }
.cb-labels span { flex: 1; text-align: center; font-size: 11px; color: var(--text-4); }
.cb-labels span.today { color: var(--text-2); font-weight: 650; }

/* ---------- donut ---------- */
.donut { display: block; }
.donut .track { stroke: rgba(255, 255, 255, 0.07); }
.donut text { font-family: var(--font); }

/* ---------- mini bars ---------- */
.mini-bars { display: flex; align-items: flex-end; gap: 4px; height: 34px; }
.mini-bars i {
  flex: 1; border-radius: 3px; min-height: 3px;
  background: linear-gradient(180deg, rgba(34, 211, 238, 0.8), rgba(99, 102, 241, 0.4));
}
.mini-bars i.zero { background: rgba(255, 255, 255, 0.06); }

/* ============================== ANİMASYON ============================== */

@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes popIn { from { opacity: 0; transform: scale(0.97) translateY(-4px); } to { opacity: 1; transform: none; } }
@keyframes slideIn { from { opacity: 0; transform: translateX(22px); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.42; } }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@keyframes shrink { from { width: 100%; } to { width: 0; } }
@keyframes float { 0%, 100% { transform: translate(0, 0) scale(1); } 50% { transform: translate(-24px, 26px) scale(1.06); } }
@keyframes draw { from { stroke-dashoffset: 1200; } to { stroke-dashoffset: 0; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

/* ============================== RESPONSIVE ============================== */

@media (max-width: 1240px) {
  .grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid.split { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 1024px) {
  .auth-shell { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .sidebar { transform: translateX(-102%); box-shadow: var(--sh-3); }
  body.nav-open .sidebar { transform: none; }
  body.nav-open .scrim { display: block; position: fixed; inset: 0; z-index: 35; background: rgba(2, 4, 10, 0.6); backdrop-filter: blur(3px); }
  .main { margin-left: 0; }
  .hamburger { display: inline-grid; }
  .grid.cols-3, .grid.cols-2 { grid-template-columns: minmax(0, 1fr); }
  .content { padding: 18px; }
  .topbar { padding: 0 16px; }
}

@media (max-width: 640px) {
  .grid.cols-4 { grid-template-columns: minmax(0, 1fr); }
  .topbar-status .badge.optional { display: none; }
  .auth-panel { padding: 26px 16px; }
  .auth-card { padding: 26px; }
  .auth-hero h1 { font-size: 34px; }
  .page-head h1 { font-size: 24px; }
}
