:root {
  --primary: #4f46e5;
  --primary-dark: #4338ca;
  --primary-soft: #eef2ff;
  --bg: #f1f5f9;
  --card: #ffffff;
  --text: #0f172a;
  --muted: #64748b;
  --border: #e2e8f0;
  --sidebar-bg: #0f172a;
  --sidebar-hover: #1e293b;
  --success: #16a34a;
  --success-soft: #dcfce7;
  --danger: #dc2626;
  --danger-soft: #fee2e2;
  --warning: #d97706;
  --warning-soft: #fef3c7;
  --info: #0284c7;
  --info-soft: #e0f2fe;
  --dark-soft: #e2e8f0;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(15, 23, 42, .08), 0 1px 2px rgba(15, 23, 42, .04);
  --shadow-lg: 0 12px 32px rgba(15, 23, 42, .14);
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  font-family: "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.55;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: none; }

h1, h2, h3, h4 { margin: 0 0 8px; font-weight: 700; }

/* ---------- Public ---------- */
body.public {
  background: linear-gradient(160deg, #eef2ff 0%, #f8fafc 40%, #f1f5f9 100%);
  min-height: 100vh;
}

.container { max-width: 1120px; margin: 0 auto; padding: 0 20px; }

.public-nav {
  background: rgba(255, 255, 255, .85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 20;
}

.nav-inner { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; }

.public-nav nav { display: flex; align-items: center; gap: 10px; }
.public-nav nav a[href^="planlar"] { font-weight: 500; color: var(--text); margin-right: 4px; }

.brand { font-size: 19px; font-weight: 800; color: var(--text); display: flex; align-items: center; gap: 9px; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px; background: linear-gradient(135deg, var(--primary), #8b5cf6);
  color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 17px;
}

.hero { text-align: center; padding: 84px 20px 40px; }
.hero h1 { font-size: 42px; line-height: 1.15; letter-spacing: -.5px; }
.hero p { color: var(--muted); font-size: 17px; max-width: 640px; margin: 16px auto 30px; }
.hero .badge { font-size: 13px; padding: 8px 14px; }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin: 30px 0 20px; }
.feature-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.feature-card h4 { margin-bottom: 6px; }
.feature-card p { margin: 0; color: var(--muted); font-size: 13px; }

.auth-wrap { max-width: 420px; margin: 60px auto 80px; }
.auth-card { background: var(--card); border: 1px solid var(--border); border-radius: 16px; padding: 32px; box-shadow: var(--shadow-lg); }
.auth-card h1 { font-size: 22px; }

/* ---------- Shell / Dashboard ---------- */
body.shell { background: var(--bg); }

.sidebar {
  position: fixed; inset: 0 auto 0 0; width: 240px; background: var(--sidebar-bg);
  color: var(--sidebar-text, #cbd5e1); display: flex; flex-direction: column; z-index: 30;
}
.sidebar-brand { padding: 20px 18px; color: #fff; font-weight: 800; font-size: 17px; display: flex; gap: 9px; align-items: center; border-bottom: 1px solid rgba(255,255,255,.08); }
.sidebar-nav { flex: 1; padding: 14px 10px; display: flex; flex-direction: column; gap: 4px; }
.sidebar-nav a {
  display: block; padding: 11px 14px; border-radius: 9px; color: #cbd5e1; font-weight: 500;
  transition: background .15s, color .15s;
}
.sidebar-nav a:hover { background: var(--sidebar-hover); color: #fff; }
.sidebar-nav a.active { background: var(--primary); color: #fff; }
.sidebar-foot { padding: 14px 10px; border-top: 1px solid rgba(255,255,255,.08); display: flex; flex-direction: column; gap: 4px; }
.sidebar-link { color: #94a3b8; padding: 9px 14px; border-radius: 9px; font-weight: 500; }
.sidebar-link:hover { background: var(--sidebar-hover); color: #fff; }

.shell-main { margin-left: 240px; min-height: 100vh; display: flex; flex-direction: column; }

.topbar {
  background: var(--card); border-bottom: 1px solid var(--border); padding: 14px 28px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; position: sticky; top: 0; z-index: 20;
}
.topbar-title { font-size: 17px; font-weight: 700; }
.topbar-user { display: flex; align-items: center; gap: 10px; }
.user-chip { background: var(--primary-soft); color: var(--primary-dark); font-weight: 600; padding: 6px 12px; border-radius: 999px; }

.content { padding: 24px 28px 60px; flex: 1; }

/* ---------- Components ---------- */
.card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 22px;
}
.card + .card { margin-top: 18px; }
.card-title { font-size: 16px; font-weight: 700; margin-bottom: 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 18px; }
.stat {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px 20px; box-shadow: var(--shadow); border-left: 4px solid var(--primary);
  display: block; text-decoration: none; color: inherit; transition: transform .15s ease, box-shadow .15s ease;
}
.stat:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0,0,0,.10); }
.stat.alt { border-left-color: var(--success); }
.stat.sari { border-left-color: var(--warning); }
.stat.kirmizi { border-left-color: var(--danger); }
.stat.beyaz { border-left-color: var(--muted); }
.stat .val { font-size: 26px; font-weight: 800; line-height: 1.1; }
.stat .lbl { color: var(--muted); font-size: 13px; margin-top: 4px; }

.plan-callout {
  display: flex; align-items: center; gap: 16px;
  background: linear-gradient(135deg, #16a34a, #15803d); color: #fff;
  border-radius: var(--radius); padding: 18px 20px; margin-bottom: 18px;
  box-shadow: var(--shadow);
}
.plan-callout-warn { background: linear-gradient(135deg, #d97706, #b45309); }
.plan-callout-icon { font-size: 30px; line-height: 1; }
.plan-callout-body { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.plan-callout-body strong { font-size: 16px; }
.plan-callout-body span { font-size: 13px; opacity: .95; }
.plan-callout .btn { white-space: nowrap; background: #fff; color: #15803d; }
.plan-callout-warn .btn { color: #b45309; }

.test-strip {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  background: linear-gradient(135deg, #b45309, #d97706); color: #fff;
  border-radius: var(--radius); padding: 12px 16px; margin-bottom: 18px;
  box-shadow: var(--shadow);
}
.test-strip strong { font-size: 14px; letter-spacing: .5px; }
.test-strip span { font-size: 13px; opacity: .95; }
.test-strip .btn { white-space: nowrap; background: #fff; color: #b45309; }
.test-strip .btn:hover { color: #b45309; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
th, td { text-align: left; padding: 11px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
th { color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .4px; background: #f8fafc; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: #f8fafc; }

.badge {
  display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap;
}
.badge-success { background: var(--success-soft); color: var(--success); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }
.badge-warning { background: var(--warning-soft); color: var(--warning); }
.badge-info { background: var(--info-soft); color: var(--info); }
.badge-primary { background: var(--primary-soft); color: var(--primary-dark); }
.badge-secondary { background: var(--dark-soft); color: var(--muted); }
.badge-dark { background: #334155; color: #e2e8f0; }
.badge-muted { background: var(--dark-soft); color: var(--muted); }

.plan-status-ok {
  background: var(--success-soft); border: 1px dashed var(--success); color: var(--success);
  border-radius: 9px; padding: 10px 12px; text-align: center; margin-top: 2px;
}
.plan-status-ok strong { display: block; font-size: 13px; }
.plan-status-ok small { display: block; margin-top: 3px; font-size: 12px; color: var(--muted); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid transparent; border-radius: 9px; padding: 9px 16px; font-size: 13.5px;
  font-weight: 600; cursor: pointer; transition: all .15s; text-decoration: none; line-height: 1.3;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; }
.btn-success { background: var(--success); color: #fff; }
.btn-success:hover { background: #15803d; color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; color: #fff; }
.btn-warning { background: var(--warning); color: #fff; }
.btn-warning:hover { background: #b45309; color: #fff; }
.btn-info { background: var(--info); color: #fff; }
.btn-info:hover { background: #0369a1; color: #fff; }
.btn-outline { background: #fff; border-color: var(--border); color: var(--text); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }
.btn-sm { padding: 6px 11px; font-size: 12.5px; border-radius: 8px; }
.btn-block { width: 100%; }

.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-weight: 600; font-size: 13px; margin-bottom: 6px; color: var(--text); }
.form-group .hint { font-size: 12px; color: var(--muted); font-weight: 400; margin-top: 4px; display: block; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=url], select, textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 9px;
  font-size: 14px; font-family: inherit; background: #fff; color: var(--text); transition: border .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
textarea { resize: vertical; min-height: 84px; }

.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; }

.alert {
  padding: 13px 16px; border-radius: 10px; font-weight: 600; margin-bottom: 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px; color: #fff;
}
.bg-success { background: var(--success); }
.bg-danger { background: var(--danger); }
.bg-warning { background: var(--warning); }
.bg-info { background: var(--info); }
.alert-close { background: none; border: none; color: #fff; font-size: 20px; cursor: pointer; line-height: 1; }

.filter-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }

.plan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; margin: 26px auto; }
.plan-card {
  background: var(--card); border: 1px solid var(--border); border-radius: 16px; padding: 28px;
  box-shadow: var(--shadow); display: flex; flex-direction: column; position: relative;
}
.plan-card.popular { border: 2px solid var(--primary); box-shadow: var(--shadow-lg); }
.plan-price { font-size: 34px; font-weight: 800; margin: 10px 0 2px; }
.plan-price small { font-size: 14px; color: var(--muted); font-weight: 400; }
.plan-tag { position: absolute; top: 16px; right: 16px; }
.plan-desc { color: var(--muted); font-size: 13.5px; flex: 1; }
.plan-period { font-size: 13px; margin-bottom: 12px; color: var(--muted); font-weight: 500; }

.modal { position: fixed; inset: 0; display: none; align-items: flex-start; justify-content: center; padding: 40px 16px; background: rgba(15,23,42,.55); z-index: 100; overflow-y: auto; }
.modal.open { display: flex; }
.modal-box { background: #fff; border-radius: 16px; max-width: 560px; width: 100%; padding: 26px; box-shadow: var(--shadow-lg); }
.modal-box h3 { margin-top: 0; }
.modal-close { float: right; background: none; border: none; font-size: 22px; cursor: pointer; color: var(--muted); line-height: 1; }

.empty-box { text-align: center; color: var(--muted); padding: 30px 10px; font-weight: 500; }

.footer-muted { color: var(--muted); font-size: 13px; text-align: center; padding: 30px 20px 40px; }

.pr { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.pr .grow { flex: 1; }

@media (max-width: 900px) {
  .sidebar { width: 200px; }
  .shell-main { margin-left: 200px; }
}
@media (max-width: 720px) {
  .sidebar { position: static; width: 100%; height: auto; }
  .shell-main { margin-left: 0; }
  .container, .content { padding-left: 14px; padding-right: 14px; }
  .hero h1 { font-size: 30px; }
}

/* ---------- Landing sayfası (yeni/görsel) ---------- */
.landing-hero {
  position: relative;
  text-align: center;
  padding: 92px 20px 0;
  overflow: hidden;
}
.landing-hero::before {
  content: "";
  position: absolute;
  left: -15%;
  right: -15%;
  bottom: -60px;
  height: 380px;
  background:
    radial-gradient(closest-side, rgba(99, 102, 241, .20), transparent 70%),
    radial-gradient(closest-side, rgba(217, 70, 239, .15), transparent 70%),
    radial-gradient(closest-side, rgba(59, 130, 246, .14), transparent 70%);
  background-position: 20% 100%, 75% 100%, 50% 100%;
  background-repeat: no-repeat;
  filter: blur(6px);
  z-index: 0;
}
.hero-inner { position: relative; z-index: 1; max-width: 800px; margin: 0 auto; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--primary-soft); color: var(--primary-dark);
  font-weight: 700; padding: 8px 18px; border-radius: 999px; font-size: 13px;
  margin-bottom: 22px;
}
.landing-hero h1 { font-size: 50px; line-height: 1.12; letter-spacing: -1px; margin-bottom: 18px; }
.gradient-text {
  background: linear-gradient(90deg, #4f46e5, #8b5cf6, #d946ef);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-sub { color: var(--muted); font-size: 17px; max-width: 620px; margin: 0 auto 30px; }
.hero-ctas { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero-ctas .btn { padding: 12px 24px; font-size: 15px; }
.hero-trust { margin-top: 30px; display: flex; gap: 26px; justify-content: center; flex-wrap: wrap; color: var(--muted); font-size: 13px; }
.hero-trust b { color: var(--text); }

.app-preview {
  max-width: 880px; margin: 58px auto 0;
  border-radius: 18px; border: 1px solid var(--border); background: #fff;
  box-shadow: var(--shadow-lg); overflow: hidden; text-align: left; position: relative; z-index: 1;
}
.preview-bar { display: flex; align-items: center; gap: 8px; padding: 13px 18px; background: #f8fafc; border-bottom: 1px solid var(--border); }
.preview-dot { width: 11px; height: 11px; border-radius: 50%; }
.preview-dot.r { background: #ef4444; } .preview-dot.y { background: #f59e0b; } .preview-dot.g { background: #22c55e; }
.preview-url { margin-left: 12px; font-size: 12px; color: var(--muted); background: #fff; border: 1px solid var(--border); border-radius: 6px; padding: 4px 12px; flex: 1; max-width: 320px; }
.preview-body { display: grid; grid-template-columns: 220px 1fr; min-height: 300px; }
.preview-side { background: var(--sidebar-bg); padding: 18px 12px; display: flex; flex-direction: column; gap: 9px; }
.preview-side i { display: block; height: 11px; border-radius: 6px; background: rgba(255, 255, 255, .10); }
.preview-side .on { background: var(--primary); }
.preview-side i.w60 { width: 60%; }
.preview-main { padding: 22px; display: flex; flex-direction: column; gap: 14px; }
.preview-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; }
.preview-stat { border: 1px solid var(--border); border-radius: 12px; padding: 14px; background: #fff; }
.preview-stat b { font-size: 21px; display: block; }
.preview-stat span { font-size: 11.5px; color: var(--muted); }
.preview-row { height: 10px; border-radius: 6px; background: var(--border); }
.preview-list { display: flex; flex-direction: column; gap: 10px; }
.preview-list .row { background: var(--bg); border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; display: flex; align-items: center; gap: 12px; }
.preview-list .pill { margin-left: auto; padding: 4px 12px; border-radius: 999px; font-size: 11px; font-weight: 700; }
.pill.g { background: var(--success-soft); color: var(--success); }
.pill.o { background: var(--warning-soft); color: var(--warning); }
.pill.p { background: var(--primary-soft); color: var(--primary-dark); }

.stats-strip {
  margin-top: 80px; padding: 40px 20px;
  background: var(--card); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  display: flex; justify-content: center; gap: 60px; flex-wrap: wrap; text-align: center;
}
.stats-strip .v { font-size: 30px; font-weight: 800; color: var(--primary); }
.stats-strip .l { color: var(--muted); font-size: 13px; margin-top: 2px; }

.l-section { max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.features-section { margin-top: 78px; }
.section-head { text-align: center; margin-bottom: 36px; }
.section-head h2 { font-size: 32px; letter-spacing: -.5px; }
.section-head p { color: var(--muted); max-width: 580px; margin: 10px auto 0; }
.feature-icon {
  width: 46px; height: 46px; border-radius: 13px;
  background: var(--primary-soft); color: var(--primary);
  display: flex; align-items: center; justify-content: center; margin-bottom: 15px;
}
.feature-icon svg { width: 23px; height: 23px; }
.feature-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); transition: all .18s; }

.steps-section { margin-top: 80px; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; }
.step {
  background: var(--card); border: 1px solid var(--border); border-radius: 16px;
  padding: 26px 22px; text-align: center;
}
.step-num {
  width: 40px; height: 40px; border-radius: 50%; background: var(--primary); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; font-weight: 800; margin-bottom: 14px;
}
.step h4 { margin-bottom: 6px; }
.step p { margin: 0; color: var(--muted); font-size: 13px; }

.plans-section { margin-top: 80px; }
.plans-mini { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; max-width: 720px; margin: 0 auto; }
.plans-mini .plan-card { text-align: center; }

.landing-footer { margin-top: 88px; background: var(--sidebar-bg); color: #94a3b8; padding: 36px 20px; }
.landing-footer .brand { color: #fff; justify-content: center; margin-bottom: 10px; }
.landing-footer .fnav { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; }
.landing-footer a { color: #cbd5e1; }
.landing-footer small { display: block; margin-top: 14px; font-size: 12px; }

@media (max-width: 720px) {
  .landing-hero h1 { font-size: 34px; }
  .preview-body { grid-template-columns: 1fr; }
  .preview-side { display: none; }
  .stats-strip { gap: 30px; }
}