/* ═══ BETEBET Rich Admin v3 ═══ */
:root {
  --rp-bg: #07090f;
  --rp-surface: #0f131c;
  --rp-surface-2: #161c28;
  --rp-border: rgba(148, 163, 184, 0.1);
  --rp-text: #eef2f8;
  --rp-muted: #8fa3bf;
  --rp-accent: #22d3ee;
  --rp-accent-2: #34d399;
  --rp-gold: #fbbf24;
  --rp-danger: #fb7185;
  --rp-radius: 14px;
  --rp-sidebar: 268px;
  --rp-font: 'Plus Jakarta Sans', system-ui, sans-serif;
  --rp-glow: rgba(34, 211, 238, 0.15);
}

*, *::before, *::after { box-sizing: border-box; }

html, body.rich-admin-body {
  margin: 0;
  min-height: 100%;
  font-family: var(--rp-font);
  background: var(--rp-bg);
  color: var(--rp-text);
  -webkit-font-smoothing: antialiased;
}

body.rich-admin-body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 0% 0%, rgba(34, 211, 238, 0.1), transparent 55%),
    radial-gradient(ellipse 50% 40% at 100% 100%, rgba(52, 211, 153, 0.08), transparent 50%),
    var(--rp-bg);
  pointer-events: none;
  z-index: 0;
}

.rich-shell {
  display: flex;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* ─── Sidebar ─── */
.rich-sidebar {
  width: var(--rp-sidebar);
  flex-shrink: 0;
  background: rgba(8, 10, 16, 0.95);
  border-right: 1px solid var(--rp-border);
  display: flex;
  flex-direction: column;
  padding: 1.25rem 0.85rem;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 200;
  transition: transform 0.25s ease;
}

.rich-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0.25rem 0.65rem 1.25rem;
  border-bottom: 1px solid var(--rp-border);
  margin-bottom: 1rem;
}

.rich-brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.1rem;
  color: #fff;
  background: linear-gradient(135deg, #0891b2, #10b981);
  box-shadow: 0 8px 24px var(--rp-glow);
}

.rich-brand strong {
  display: block;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
}

.rich-brand span {
  font-size: 0.6875rem;
  color: var(--rp-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.rich-nav {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow-y: auto;
}

.rich-nav-link {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 0.72rem 0.85rem;
  border-radius: 11px;
  color: var(--rp-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid transparent;
  transition: all 0.18s ease;
  position: relative;
}

.rich-nav-link i { width: 18px; text-align: center; opacity: 0.9; }

.rich-nav-link:hover {
  background: rgba(148, 163, 184, 0.08);
  color: var(--rp-text);
}

.rich-nav-link.active {
  background: rgba(34, 211, 238, 0.1);
  border-color: rgba(34, 211, 238, 0.22);
  color: var(--rp-accent);
  box-shadow: inset 3px 0 0 var(--rp-accent);
}

.rich-nav-badge {
  margin-left: auto;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--rp-accent-2);
  color: #042f1a;
  font-size: 0.6875rem;
  font-weight: 700;
  font-style: normal;
  display: grid;
  place-items: center;
}

.rich-nav-badge:empty, .rich-nav-badge[hidden] { display: none; }

.rich-nav-logout { color: var(--rp-danger) !important; margin-top: 0.5rem; }
.rich-nav-logout:hover { background: rgba(251, 113, 133, 0.1) !important; }

.rich-sidebar-foot {
  border-top: 1px solid var(--rp-border);
  padding-top: 0.85rem;
  margin-top: 0.5rem;
}

.rich-sidebar-ver {
  margin: 0.65rem 0 0;
  text-align: center;
  font-size: 0.625rem;
  color: var(--rp-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.rich-sidebar-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 150;
}

/* ─── Main ─── */
.rich-main {
  flex: 1;
  margin-left: var(--rp-sidebar);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.rich-topbar {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--rp-border);
  background: rgba(12, 15, 22, 0.85);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 50;
}

.rich-menu-btn {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--rp-border);
  background: var(--rp-surface-2);
  color: var(--rp-accent);
  cursor: pointer;
}

.rich-topbar-title { flex: 1; min-width: 0; }
.rich-topbar-title h1 {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.rich-topbar-title p {
  margin: 0.15rem 0 0;
  font-size: 0.75rem;
  color: var(--rp-muted);
  font-variant-numeric: tabular-nums;
}

.rich-topbar-pills {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.rich-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  font-size: 0.6875rem;
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.2);
  color: var(--rp-accent);
  white-space: nowrap;
}

.rich-pill-gold {
  background: rgba(251, 191, 36, 0.1);
  border-color: rgba(251, 191, 36, 0.25);
  color: var(--rp-gold);
}

.rich-pill b { font-weight: 700; }

.rich-user {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8125rem;
  color: var(--rp-muted);
}

.rich-avatar {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 2px solid rgba(34, 211, 238, 0.35);
  object-fit: cover;
}

.rich-page,
.rich-content {
  padding: 1.5rem;
  flex: 1;
}

.rich-card-title {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  font-weight: 700;
}

.rich-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.rich-table th,
.rich-table td {
  padding: 0.65rem 0.75rem;
  border-bottom: 1px solid var(--rp-border);
  text-align: left;
}

.rich-table th {
  color: var(--rp-muted);
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ─── Cards & sections ─── */
.rich-card,
.form-container,
.analytics-container,
.stat-card {
  background: var(--rp-surface) !important;
  border: 1px solid var(--rp-border) !important;
  border-radius: var(--rp-radius) !important;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25) !important;
  color: var(--rp-text) !important;
}

.rich-fade-in {
  animation: richFadeUp 0.45s ease both;
}

@keyframes richFadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.section-title,
.form-title {
  color: var(--rp-text) !important;
  font-size: 1.125rem !important;
  font-weight: 700 !important;
  margin-bottom: 1.25rem !important;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title i { color: var(--rp-accent); }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat-card {
  padding: 1.25rem !important;
  text-align: center;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-3px);
  border-color: rgba(34, 211, 238, 0.3) !important;
}

.stat-card i {
  font-size: 1.75rem !important;
  color: var(--rp-accent) !important;
  margin-bottom: 0.75rem !important;
}

.stat-card h3 {
  font-size: 0.8125rem !important;
  color: var(--rp-muted) !important;
  font-weight: 500 !important;
}

.stat-card p {
  font-size: 1.5rem !important;
  font-weight: 800 !important;
  color: var(--rp-accent-2) !important;
  margin-top: 0.35rem !important;
}

.analytics-container { padding: 1.5rem !important; }

/* ─── Tables ─── */
.table-responsive {
  border-radius: var(--rp-radius);
  overflow: hidden;
  border: 1px solid var(--rp-border);
  background: var(--rp-surface);
}

.table {
  width: 100%;
  border-collapse: collapse;
  color: var(--rp-text);
}

.table th,
.table-header {
  background: var(--rp-surface-2) !important;
  color: var(--rp-muted) !important;
  font-size: 0.6875rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
  padding: 0.75rem 1rem !important;
  border-bottom: 1px solid var(--rp-border) !important;
}

.table td {
  padding: 0.65rem 1rem !important;
  border-bottom: 1px solid var(--rp-border) !important;
  font-size: 0.8125rem !important;
  background: transparent !important;
}

.table tbody tr:hover,
tr.main-row:hover {
  background: rgba(34, 211, 238, 0.05) !important;
}

/* ─── Forms & search ─── */
.search-container {
  margin-bottom: 1rem;
  display: flex;
  justify-content: flex-end;
}

#search-input,
.form-input,
input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
select,
textarea {
  background: var(--rp-surface-2) !important;
  border: 1px solid var(--rp-border) !important;
  color: var(--rp-text) !important;
  border-radius: 10px !important;
  padding: 0.65rem 1rem !important;
  font-family: inherit !important;
}

#search-input:focus,
input:focus,
select:focus {
  outline: none !important;
  border-color: rgba(34, 211, 238, 0.45) !important;
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.12) !important;
}

/* ─── Buttons ─── */
.edit-btn, button.edit-btn, .table .edit-btn {
  background: rgba(52, 211, 153, 0.12) !important;
  color: var(--rp-accent-2) !important;
  border: 1px solid rgba(52, 211, 153, 0.25) !important;
  border-radius: 8px !important;
  padding: 0.35rem 0.7rem !important;
  font-size: 0.75rem !important;
  cursor: pointer;
}

.delete-btn, button.delete-btn, .table .delete-btn {
  background: rgba(251, 113, 133, 0.1) !important;
  color: var(--rp-danger) !important;
  border: 1px solid rgba(251, 113, 133, 0.22) !important;
  border-radius: 8px !important;
  padding: 0.35rem 0.7rem !important;
  font-size: 0.75rem !important;
  cursor: pointer;
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 1.25rem;
}

.pagination a {
  padding: 0.45rem 0.85rem;
  border-radius: 8px;
  text-decoration: none;
  background: var(--rp-surface-2);
  border: 1px solid var(--rp-border);
  color: var(--rp-muted);
  font-size: 0.8125rem;
}

.pagination a:hover {
  background: rgba(34, 211, 238, 0.1);
  color: var(--rp-accent);
  border-color: rgba(34, 211, 238, 0.3);
}

.pagination .disabled {
  opacity: 0.35;
  pointer-events: none;
}

/* ─── Toast ─── */
.rich-toast-stack {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.rich-toast {
  padding: 0.75rem 1rem;
  border-radius: 10px;
  background: var(--rp-surface-2);
  border: 1px solid var(--rp-border);
  color: var(--rp-text);
  font-size: 0.8125rem;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  animation: richFadeUp 0.3s ease;
}

.rich-toast.out { opacity: 0; transform: translateY(6px); transition: 0.3s ease; }

/* ─── Login ─── */
body.login-rich {
  min-height: 100vh;
  margin: 0;
  font-family: var(--rp-font);
  color: var(--rp-text);
  background: #05070d;
  overflow-x: hidden;
}

.login-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 60% at 20% 10%, rgba(34, 211, 238, 0.14), transparent 55%),
    radial-gradient(ellipse 70% 50% at 85% 85%, rgba(52, 211, 153, 0.1), transparent 50%),
    linear-gradient(165deg, #05070d 0%, #0a1018 45%, #060910 100%);
}

.login-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0, 201, 167, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 201, 167, 0.07) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 40%, #000 20%, transparent 75%);
}

.login-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  animation: loginFloat 14s ease-in-out infinite;
}

.login-orb-1 {
  width: 420px;
  height: 420px;
  top: -120px;
  left: -80px;
  background: rgba(8, 145, 178, 0.35);
}

.login-orb-2 {
  width: 360px;
  height: 360px;
  bottom: -100px;
  right: 10%;
  background: rgba(16, 185, 129, 0.28);
  animation-delay: -4s;
}

.login-orb-3 {
  width: 240px;
  height: 240px;
  top: 40%;
  right: -60px;
  background: rgba(34, 211, 238, 0.2);
  animation-delay: -8s;
}

@keyframes loginFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(18px, -22px) scale(1.05); }
}

.login-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.login-shell-centered {
  max-width: none;
}

.login-showcase {
  display: flex;
  align-items: center;
  padding: 1rem 2rem;
}

.login-showcase-inner {
  animation: loginSlideIn 0.7s ease both;
}

.login-mark-xl {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: #fff;
  background: linear-gradient(135deg, #0891b2 0%, #10b981 100%);
  box-shadow:
    0 20px 50px rgba(34, 211, 238, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  margin-bottom: 1.75rem;
}

.login-showcase h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.login-showcase h1 span {
  background: linear-gradient(135deg, #22d3ee, #34d399);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.login-showcase p {
  margin: 0 0 1.75rem;
  max-width: 380px;
  color: var(--rp-muted);
  font-size: 0.9375rem;
  line-height: 1.65;
}

.login-site-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.login-site-list li {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.875rem;
  color: #c5d3e8;
}

.login-site-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, #22d3ee, #34d399);
  box-shadow: 0 0 12px rgba(52, 211, 153, 0.6);
  flex-shrink: 0;
}

.login-panel {
  display: flex;
  justify-content: center;
  align-items: center;
}

.login-rich-box {
  position: relative;
  width: min(420px, 100%);
  padding: 2.25rem 2rem 1.75rem;
  background: rgba(12, 16, 24, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 24px;
  backdrop-filter: blur(20px);
  box-shadow:
    0 32px 80px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  animation: loginSlideIn 0.7s ease 0.1s both;
}

.login-rich-box::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(145deg, rgba(34, 211, 238, 0.35), transparent 40%, rgba(52, 211, 153, 0.25));
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
  pointer-events: none;
}

.login-rich-brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.75rem;
  text-align: left;
}

.login-mark {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #0891b2, #10b981);
  box-shadow: 0 12px 32px rgba(34, 211, 238, 0.22);
  flex-shrink: 0;
}

.login-mark span {
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  letter-spacing: -0.03em;
}

.login-rich-brand strong {
  display: block;
  font-size: 1.125rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  background: linear-gradient(135deg, #e0f7ff, #34d399);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.login-rich-brand span {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.6875rem;
  color: var(--rp-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.login-alert {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  border-radius: 12px;
  background: rgba(251, 113, 133, 0.1);
  border: 1px solid rgba(251, 113, 133, 0.25);
  color: #fecdd3;
  font-size: 0.8125rem;
  animation: loginShake 0.45s ease;
}

@keyframes loginShake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-4px); }
  40%, 80% { transform: translateX(4px); }
}

.login-form .login-field { margin-bottom: 1.15rem; }

.login-form label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--rp-muted);
  margin-bottom: 0.45rem;
}

.login-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.login-input-wrap > i:first-child {
  position: absolute;
  left: 1rem;
  z-index: 1;
  color: rgba(143, 163, 191, 0.7);
  font-size: 0.875rem;
  pointer-events: none;
  transition: color 0.2s ease;
}

body.login-rich .login-form input.login-input {
  box-sizing: border-box;
  width: 100%;
  padding: 0.85rem 1rem 0.85rem 2.75rem;
  background: rgba(8, 12, 20, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 14px;
  color: var(--rp-text);
  font-family: inherit;
  font-size: 0.9375rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

body.login-rich .login-form input.login-input-pass {
  padding-right: 2.85rem;
}

body.login-rich .login-form input.login-input::placeholder {
  color: rgba(143, 163, 191, 0.45);
}

.login-input-wrap:focus-within > i:first-child {
  color: var(--rp-accent);
}

body.login-rich .login-form input.login-input:focus {
  outline: none;
  background: rgba(10, 16, 26, 0.95);
  border-color: rgba(34, 211, 238, 0.45);
  box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.1);
}

.login-toggle-pass {
  position: absolute;
  right: 0.65rem;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: var(--rp-muted);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: color 0.2s ease, background 0.2s ease;
}

.login-toggle-pass:hover {
  color: var(--rp-accent);
  background: rgba(34, 211, 238, 0.08);
}

.login-rich-btn {
  width: 100%;
  margin-top: 0.35rem;
  padding: 0.95rem 1.25rem;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #0891b2 0%, #0d9488 45%, #10b981 100%);
  color: #fff;
  font-weight: 700;
  font-size: 0.9375rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  box-shadow:
    0 14px 36px rgba(16, 185, 129, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.login-rich-btn i {
  font-size: 0.875rem;
  transition: transform 0.18s ease;
}

.login-rich-btn:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
  box-shadow: 0 18px 44px rgba(16, 185, 129, 0.35);
}

.login-rich-btn:hover i {
  transform: translateX(3px);
}

.login-rich-btn:active {
  transform: translateY(0);
}

.login-foot {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(148, 163, 184, 0.08);
  text-align: center;
}

.login-badges {
  display: flex;
  justify-content: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.login-badge {
  display: inline-grid;
  place-items: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.5rem;
  border-radius: 8px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--rp-accent);
  background: rgba(34, 211, 238, 0.08);
  border: 1px solid rgba(34, 211, 238, 0.18);
}

.login-foot p {
  margin: 0;
  color: rgba(143, 163, 191, 0.75);
  font-size: 0.75rem;
  letter-spacing: 0.02em;
}

@keyframes loginSlideIn {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.login-rich-error {
  color: var(--rp-danger);
  font-size: 0.8125rem;
  text-align: center;
  min-height: 1.25rem;
  margin-top: 0.75rem;
}

@media (max-width: 900px) {
  .login-shell {
    padding: 1.25rem;
  }

  .login-rich-box {
    padding: 2rem 1.5rem 1.5rem;
  }
}

@media (max-width: 420px) {
  .login-rich-brand {
    flex-direction: column;
    text-align: center;
  }
}

/* ─── Pattern / password login modes ─── */
.login-mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
  padding: 0.3rem;
  margin-bottom: 1.35rem;
  border-radius: 14px;
  background: rgba(8, 12, 20, 0.75);
  border: 1px solid rgba(148, 163, 184, 0.1);
}

.login-mode-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.7rem 0.75rem;
  border: none;
  border-radius: 11px;
  background: transparent;
  color: var(--rp-muted);
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.login-mode-tab i {
  font-size: 0.75rem;
  opacity: 0.85;
}

.login-mode-tab:hover {
  color: #d7e6f7;
  background: rgba(34, 211, 238, 0.06);
}

.login-mode-tab.is-active {
  color: #fff;
  background: linear-gradient(135deg, rgba(8, 145, 178, 0.55), rgba(16, 185, 129, 0.45));
  box-shadow: 0 8px 22px rgba(16, 185, 129, 0.18);
}

.login-pattern-form,
.login-password-form {
  display: none;
}

.login-pattern-form.is-active,
.login-password-form.is-active {
  display: block;
  animation: loginSlideIn 0.35s ease both;
}

.login-pattern-hint {
  margin: 0 0 1rem;
  text-align: center;
  font-size: 0.8125rem;
  color: var(--rp-muted);
  letter-spacing: 0.04em;
}

.pattern-lock {
  position: relative;
  width: min(260px, 100%);
  aspect-ratio: 1;
  margin: 0 auto 0.85rem;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

.pattern-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: visible;
}

.pattern-seg {
  stroke: url(#patternGrad);
  stroke: #22d3ee;
  stroke-width: 3.5;
  stroke-linecap: round;
  filter: drop-shadow(0 0 6px rgba(34, 211, 238, 0.55));
}

.pattern-seg-cursor {
  stroke: rgba(52, 211, 153, 0.65);
  stroke-width: 2.5;
  stroke-dasharray: 5 6;
}

.pattern-dots {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  place-items: center;
  padding: 8%;
  gap: 0;
}

.pattern-dot {
  width: clamp(18px, 8vw, 22px);
  height: clamp(18px, 8vw, 22px);
  border-radius: 50%;
  border: 2px solid rgba(148, 163, 184, 0.35);
  background: rgba(8, 12, 20, 0.9);
  padding: 0;
  cursor: pointer;
  position: relative;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  transition:
    border-color 0.15s ease,
    background 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
}

.pattern-dot::after {
  content: '';
  position: absolute;
  inset: -18px;
}

.pattern-dot.is-active {
  border-color: #22d3ee;
  background: radial-gradient(circle at 40% 35%, #67e8f9, #0891b2 70%);
  box-shadow:
    0 0 0 6px rgba(34, 211, 238, 0.12),
    0 0 18px rgba(34, 211, 238, 0.45);
  transform: scale(1.12);
}

.pattern-dot.is-error {
  border-color: #fb7185;
  background: radial-gradient(circle at 40% 35%, #fda4af, #e11d48 70%);
  box-shadow:
    0 0 0 6px rgba(251, 113, 133, 0.14),
    0 0 16px rgba(251, 113, 133, 0.4);
  animation: loginShake 0.4s ease;
}

.pattern-actions {
  display: flex;
  justify-content: center;
  margin-bottom: 0.25rem;
}

.pattern-reset {
  border: none;
  background: transparent;
  color: var(--rp-muted);
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  transition: color 0.15s ease, background 0.15s ease;
}

.pattern-reset:hover {
  color: var(--rp-accent);
  background: rgba(34, 211, 238, 0.08);
}

.ayar-pattern-hint {
  margin: 0.35rem 0 0;
  font-size: 0.75rem;
  color: var(--rp-muted);
  line-height: 1.45;
}

.ayar-pattern-preview {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.5rem;
  padding: 0.35rem 0.65rem;
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--rp-accent);
  background: rgba(34, 211, 238, 0.08);
  border: 1px solid rgba(34, 211, 238, 0.16);
}

/* Hide old layout remnants */
.admin-panel, .sidebar:not(.rich-sidebar), .main-content:not(.rich-main),
.header:not(.rich-topbar), .logo, .nav-menu { display: none !important; }

/* ─── Mobile ─── */
@media (max-width: 960px) {
  .rich-main { margin-left: 0; }
  .rich-menu-btn { display: grid; place-items: center; }
  .rich-sidebar { transform: translateX(-100%); }
  .rich-sidebar.open { transform: translateX(0); }
  .rich-topbar-pills { display: none; }
  .rich-page { padding: 1rem; }
}

@media (max-width: 640px) {
  .rich-user span { display: none; }
}

/* ─── v4: Kasa, Ayarlar, Badges ─── */
.form-button {
  padding: 0.65rem 1.25rem;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #0891b2, #10b981);
  color: #fff;
  font-weight: 600;
  font-size: 0.8125rem;
  cursor: pointer;
  font-family: inherit;
}
.form-button:hover { filter: brightness(1.06); }
.rich-btn-secondary { background: var(--rp-surface-2); border: 1px solid var(--rp-border); color: var(--rp-text); }

.rich-badge {
  display: inline-block;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.rich-badge-ok { background: rgba(52,211,153,0.15); color: #34d399; border: 1px solid rgba(52,211,153,0.3); }
.rich-badge-no { background: rgba(251,113,133,0.12); color: #fb7185; border: 1px solid rgba(251,113,133,0.25); }
.rich-badge-wait { background: rgba(251,191,36,0.12); color: #fbbf24; border: 1px solid rgba(251,191,36,0.25); }

.rich-btn-ok, .rich-btn-no {
  padding: 0.3rem 0.65rem;
  border-radius: 8px;
  border: none;
  font-size: 0.6875rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  margin-right: 4px;
}
.rich-btn-ok { background: rgba(52,211,153,0.15); color: #34d399; }
.rich-btn-no { background: rgba(251,113,133,0.12); color: #fb7185; }
.rich-muted { color: var(--rp-muted); font-size: 0.75rem; }

.rich-tabs { display: flex; gap: 0.5rem; margin-bottom: 1rem; flex-wrap: wrap; }
.rich-tab {
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.8125rem;
  color: var(--rp-muted);
  border: 1px solid var(--rp-border);
  background: var(--rp-surface);
}
.rich-tab.active, .rich-tab:hover { color: var(--rp-accent); border-color: rgba(34,211,238,0.35); background: rgba(34,211,238,0.08); }

.rich-hint { color: var(--rp-muted); font-size: 0.8125rem; margin: 0 0 1rem; line-height: 1.5; }
.webhook-box label { display: block; font-size: 0.6875rem; color: var(--rp-muted); margin-bottom: 0.35rem; text-transform: uppercase; letter-spacing: 0.06em; }

.rich-alert {
  padding: 0.75rem 1rem;
  border-radius: 10px;
  margin-bottom: 1rem;
  font-size: 0.8125rem;
}
.rich-alert-ok { background: rgba(52,211,153,0.1); border: 1px solid rgba(52,211,153,0.25); color: #34d399; }
.rich-alert-error { background: rgba(251,113,133,0.1); border: 1px solid rgba(251,113,133,0.25); color: #fb7185; }

.dashboard-quick { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 1.5rem; }
.rich-quick-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0.65rem 1rem;
  border-radius: 10px;
  text-decoration: none;
  background: var(--rp-surface-2);
  border: 1px solid var(--rp-border);
  color: var(--rp-text);
  font-size: 0.8125rem;
  font-weight: 500;
}
.rich-quick-btn:hover { border-color: rgba(34,211,238,0.35); color: var(--rp-accent); }

.rich-toast-ok { border-color: rgba(52,211,153,0.35) !important; }
.rich-toast-warn { border-color: rgba(251,191,36,0.35) !important; }
.rich-toast-error { border-color: rgba(251,113,133,0.35) !important; }

.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-size: 0.6875rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--rp-muted); margin-bottom: 0.4rem; }

.kasa-stats { margin-bottom: 1.25rem; }
.kasa-actions { white-space: nowrap; }

/* ─── v7: balanced settings rows ─── */
.settings-grid {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}


.settings-row-single { grid-template-columns: 1fr; max-width: 100%; }
.settings-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  align-items: stretch;
}

.settings-row .settings-card {
  height: 100%;
}

.settings-card {
  display: flex;
  flex-direction: column;
  padding: 1.35rem 1.5rem 1.5rem;
}

.settings-card-head { flex-shrink: 0; }
.settings-card-head .section-title { margin-bottom: 0.35rem !important; }

.settings-card-form {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.settings-card-form .form-input,
.settings-card-form textarea.form-input { width: 100%; }

.settings-card-actions {
  margin-top: auto;
  padding-top: 0.75rem;
}

.settings-card-actions .form-button,
.webhook-form .form-button { width: 100%; }

.settings-tall .rich-code {
  height: 120px;
  min-height: 120px;
  max-height: 120px;
  resize: none;
  overflow: auto;
}

.webhook-box {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid var(--rp-border);
}

.webhook-form { margin-top: 0.75rem; }

.komisyon-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1rem;
}

@media (max-width: 960px) {
  .settings-row { grid-template-columns: 1fr; }
  .komisyon-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 520px) {
  .komisyon-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .settings-card { padding: 1.15rem; }
}

/* ─── Kasa Ultra ─── */
.kasa-hero {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 1.25rem;
  padding: 1.5rem 1.65rem;
  margin-bottom: 1.25rem;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background:
    linear-gradient(135deg, rgba(34, 211, 238, 0.08) 0%, transparent 45%),
    linear-gradient(225deg, rgba(52, 211, 153, 0.06) 0%, transparent 40%),
    rgba(12, 16, 24, 0.88);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.kasa-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.22);
  color: var(--rp-accent);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.kasa-hero-title {
  margin: 0.85rem 0 0.45rem;
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.kasa-hero-quote {
  margin: 1rem 0 0;
  padding: 0;
  border: none;
  max-width: 380px;
}

.kasa-hero-quote p {
  margin: 0;
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  font-weight: 600;
  line-height: 1.55;
  letter-spacing: -0.02em;
  color: rgba(226, 232, 240, 0.92);
}

.kasa-hero-quote p::before {
  content: '';
  display: block;
  width: 36px;
  height: 3px;
  margin-bottom: 0.85rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--rp-accent), rgba(52, 211, 153, 0.7));
}

.kasa-hero-sub {
  margin: 0;
  max-width: 420px;
  color: var(--rp-muted);
  font-size: 0.875rem;
  line-height: 1.65;
}

.kasa-hero-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.kasa-kpi {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  padding: 1rem 1.05rem;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(8, 12, 20, 0.72);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.kasa-kpi:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.25);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28);
}

.kasa-kpi-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.kasa-kpi-label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--rp-muted);
  margin-bottom: 0.25rem;
}

.kasa-kpi-value {
  display: block;
  font-size: 1.125rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.kasa-kpi small {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.6875rem;
  color: rgba(143, 163, 191, 0.85);
}

.kpi-approved .kasa-kpi-icon { background: rgba(52, 211, 153, 0.15); color: #34d399; }
.kpi-approved .kasa-kpi-value { color: #6ee7b7; }
.kpi-pending .kasa-kpi-icon { background: rgba(251, 191, 36, 0.15); color: #fbbf24; }
.kpi-pending .kasa-kpi-value { color: #fcd34d; }
.kpi-rejected .kasa-kpi-icon { background: rgba(251, 113, 133, 0.15); color: #fb7185; }
.kpi-rejected .kasa-kpi-value { color: #fda4af; }
.kpi-today .kasa-kpi-icon { background: rgba(34, 211, 238, 0.15); color: #22d3ee; }
.kpi-today .kasa-kpi-value { color: #67e8f9; }
.kpi-await .kasa-kpi-icon { background: rgba(96, 165, 250, 0.15); color: #60a5fa; }
.kpi-await .kasa-kpi-value { color: #93c5fd; }

.kasa-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.kasa-section-head h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.kasa-section-head h3 i { color: var(--rp-accent); }

.kasa-section-meta {
  font-size: 0.75rem;
  color: var(--rp-muted);
}

.kasa-sites,
.kasa-ledger,
.kasa-active-site {
  margin-bottom: 1.25rem;
}

.kasa-site-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 0.85rem;
}

.kasa-site-card {
  display: block;
  text-decoration: none;
  color: inherit;
  padding: 1.1rem 1.15rem;
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 19, 28, 0.82);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.kasa-site-card:hover {
  transform: translateY(-3px);
  border-color: rgba(34, 211, 238, 0.28);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
}

.kasa-site-card.active {
  border-color: rgba(34, 211, 238, 0.45);
  box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.15), 0 16px 40px rgba(34, 211, 238, 0.08);
}

.kasa-site-card.disabled { opacity: 0.65; pointer-events: none; }

.kasa-site-top {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.kasa-site-mark {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 0.8125rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #fff;
  background: linear-gradient(135deg, #0891b2, #10b981);
  box-shadow: 0 10px 24px rgba(34, 211, 238, 0.2);
}

.kasa-site-top strong {
  display: block;
  font-size: 0.9375rem;
  font-weight: 700;
}

.kasa-site-top span {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.6875rem;
  color: var(--rp-muted);
  word-break: break-all;
}

.kasa-site-error {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--rp-danger);
}

.kasa-site-amounts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
  margin-bottom: 0.75rem;
}

.kasa-site-amounts div {
  padding: 0.55rem 0.5rem;
  border-radius: 10px;
  background: rgba(8, 12, 20, 0.65);
  border: 1px solid rgba(148, 163, 184, 0.06);
}

.kasa-site-amounts em {
  display: block;
  font-style: normal;
  font-size: 0.625rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--rp-muted);
  margin-bottom: 0.2rem;
}

.kasa-site-amounts strong {
  display: block;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--rp-text);
}

.kasa-site-amounts small {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.625rem;
  color: rgba(143, 163, 191, 0.8);
}

.kasa-site-bar {
  display: flex;
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(148, 163, 184, 0.08);
  margin-bottom: 0.65rem;
}

.kasa-site-bar span { display: block; height: 100%; min-width: 0; }
.bar-approved { background: linear-gradient(90deg, #10b981, #34d399); }
.bar-pending { background: linear-gradient(90deg, #d97706, #fbbf24); }
.bar-rejected { background: linear-gradient(90deg, #e11d48, #fb7185); }

.kasa-site-foot {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.6875rem;
  color: var(--rp-muted);
}

.kasa-ledger {
  padding: 1.25rem 1.35rem;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(12, 16, 24, 0.78);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.28);
}

.kasa-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.kasa-filters {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.kasa-filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(8, 12, 20, 0.65);
  color: var(--rp-muted);
  text-decoration: none;
  font-size: 0.8125rem;
  font-weight: 600;
  transition: all 0.18s ease;
}

.kasa-filter-pill:hover,
.kasa-filter-pill.active {
  color: var(--rp-text);
  border-color: rgba(34, 211, 238, 0.35);
  background: rgba(34, 211, 238, 0.1);
}

.kasa-toolbar-right {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.kasa-select {
  min-width: 180px;
  padding: 0.55rem 0.75rem !important;
  font-size: 0.8125rem !important;
}

.kasa-clear {
  font-size: 0.75rem;
  color: var(--rp-accent);
  text-decoration: none;
  white-space: nowrap;
}

.kasa-clear:hover { text-decoration: underline; }

.kasa-table-wrap {
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.08);
  overflow: auto;
  background: rgba(8, 12, 20, 0.55);
}

.kasa-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
  min-width: 880px;
}

.kasa-table th,
.kasa-table td {
  padding: 0.8rem 0.9rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.07);
  text-align: left;
  vertical-align: middle;
}

.kasa-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: rgba(12, 16, 24, 0.98);
  color: var(--rp-muted);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.kasa-table tbody tr {
  transition: background 0.15s ease;
}

.kasa-table tbody tr:hover {
  background: rgba(34, 211, 238, 0.04);
}

.kasa-table-mark {
  display: inline-grid;
  place-items: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.4rem;
  margin-right: 0.45rem;
  border-radius: 8px;
  font-size: 0.6875rem;
  font-weight: 800;
  color: var(--rp-accent);
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.18);
  vertical-align: middle;
}

.kasa-table-site {
  font-size: 0.6875rem;
  color: var(--rp-muted);
}

.kasa-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.75rem;
  color: var(--rp-muted);
}

.kasa-amount {
  font-weight: 800;
  color: #6ee7b7;
  white-space: nowrap;
}

.kasa-method {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-size: 0.6875rem;
  font-weight: 600;
  background: rgba(148, 163, 184, 0.08);
  color: var(--rp-muted);
}

.kasa-status {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  font-size: 0.6875rem;
  font-weight: 700;
  white-space: nowrap;
}

.kasa-status-pending { background: rgba(251, 191, 36, 0.12); color: #fcd34d; border: 1px solid rgba(251, 191, 36, 0.22); }
.kasa-status-approved { background: rgba(52, 211, 153, 0.12); color: #6ee7b7; border: 1px solid rgba(52, 211, 153, 0.22); }
.kasa-status-rejected { background: rgba(251, 113, 133, 0.12); color: #fda4af; border: 1px solid rgba(251, 113, 133, 0.22); }
.kasa-status-unknown { background: rgba(148, 163, 184, 0.1); color: var(--rp-muted); border: 1px solid rgba(148, 163, 184, 0.15); }

.kasa-date {
  font-size: 0.75rem;
  color: var(--rp-muted);
  white-space: nowrap;
}

.kasa-empty {
  padding: 3rem 1.5rem;
  text-align: center;
  color: var(--rp-muted);
}

.kasa-empty i {
  font-size: 2rem;
  margin-bottom: 0.75rem;
  opacity: 0.45;
}

.kasa-empty p { margin: 0; }

.kasa-mini-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.kasa-mini-card {
  padding: 0.9rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.08);
  background: rgba(15, 19, 28, 0.75);
}

.kasa-mini-card span {
  display: block;
  font-size: 0.6875rem;
  color: var(--rp-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.35rem;
}

.kasa-mini-card strong {
  font-size: 1rem;
  font-weight: 800;
  color: var(--rp-accent-2);
}

@media (max-width: 1100px) {
  .kasa-hero { grid-template-columns: 1fr; }
  .kasa-mini-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  .kasa-hero-metrics { grid-template-columns: 1fr; }
  .kasa-site-amounts { grid-template-columns: 1fr; }
  .kasa-mini-grid { grid-template-columns: 1fr; }
  .kasa-toolbar { flex-direction: column; align-items: stretch; }
}

/* ─── Dashboard (Aktif Sitelerim) ─── */
.dash-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.35rem;
  flex-wrap: wrap;
}

.dash-eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--rp-accent);
}

.dash-lead {
  margin: 0;
  max-width: 34rem;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--rp-muted);
}

.dash-add-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.62rem 1rem;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.95), rgba(52, 211, 153, 0.9));
  color: #041018;
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(34, 211, 238, 0.22);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.dash-add-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(34, 211, 238, 0.28);
}

.dash-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.site-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 1rem 1rem 0.9rem;
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background:
    linear-gradient(165deg, rgba(22, 28, 40, 0.92), rgba(11, 14, 22, 0.88));
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.site-card:hover {
  border-color: rgba(34, 211, 238, 0.22);
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.24);
}

.site-card.is-pending {
  opacity: 0.88;
}

.site-card-top {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.site-avatar {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #041018;
  background: linear-gradient(135deg, #22d3ee, #34d399);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
}

.site-card-meta {
  flex: 1;
  min-width: 0;
}

.site-card-meta h3 {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.25;
}

.site-domain {
  margin: 0.2rem 0 0;
  font-size: 0.76rem;
  color: var(--rp-muted);
  word-break: break-all;
  line-height: 1.35;
}

.site-delete {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: rgba(148, 163, 184, 0.55);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: color 0.18s ease, background 0.18s ease;
}

.site-delete:hover {
  color: #fda4af;
  background: rgba(251, 113, 133, 0.1);
}

.site-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
}

.site-metric {
  padding: 0.55rem 0.6rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.08);
}

.site-metric-label {
  display: block;
  font-size: 0.68rem;
  color: var(--rp-muted);
  margin-bottom: 0.15rem;
}

.site-metric strong {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--rp-text);
  line-height: 1.2;
}

.site-metric strong small {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--rp-muted);
  margin-left: 0.1rem;
}

.site-tags {
  display: flex;
  gap: 0.4rem;
}

.site-tag {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.72rem;
  color: rgba(148, 163, 184, 0.45);
  background: rgba(148, 163, 184, 0.08);
  border: 1px solid rgba(148, 163, 184, 0.1);
}

.site-tag.on {
  color: var(--rp-accent);
  background: rgba(34, 211, 238, 0.12);
  border-color: rgba(34, 211, 238, 0.25);
}

.site-status {
  padding: 0.45rem 0.65rem;
  border-radius: 10px;
  font-size: 0.78rem;
  font-weight: 600;
}

.site-status-warn {
  color: #fde68a;
  background: rgba(251, 191, 36, 0.12);
  border: 1px solid rgba(251, 191, 36, 0.2);
}

.site-status-err {
  color: #fecdd3;
  background: rgba(251, 113, 133, 0.12);
  border: 1px solid rgba(251, 113, 133, 0.2);
}

.site-status-note {
  margin: -0.35rem 0 0;
  font-size: 0.74rem;
  color: var(--rp-muted);
  line-height: 1.4;
}

.site-manage {
  width: 100%;
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.62rem 0.85rem;
  border-radius: 12px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  background: rgba(34, 211, 238, 0.06);
  color: var(--rp-text);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.site-manage:hover {
  background: rgba(34, 211, 238, 0.14);
  border-color: rgba(34, 211, 238, 0.38);
  color: #ecfeff;
}

.site-manage i {
  font-size: 0.72rem;
  opacity: 0.75;
  transition: transform 0.18s ease;
}

.site-manage:hover i {
  transform: translateX(2px);
  opacity: 1;
}

.dash-empty {
  margin-top: 2rem;
  text-align: center;
  padding: 2.5rem 1.5rem;
  border-radius: 18px;
  border: 1px dashed rgba(148, 163, 184, 0.18);
  background: rgba(15, 19, 28, 0.45);
}

.dash-empty-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 0.85rem;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  color: var(--rp-accent);
  background: rgba(34, 211, 238, 0.1);
}

.dash-empty h3 {
  margin: 0 0 0.35rem;
  font-size: 1rem;
}

.dash-empty p {
  margin: 0 0 1rem;
  color: var(--rp-muted);
  font-size: 0.875rem;
}

@media (max-width: 640px) {
  .dash-head { flex-direction: column; align-items: stretch; }
  .dash-add-btn { justify-content: center; }
  .site-metrics { grid-template-columns: 1fr; }
}

/* ─── Dashboard modals ─── */
.dash-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.dash-toolbar-title {
  margin: 0 0 0.25rem;
  font-size: 1.125rem;
  font-weight: 800;
}

.dash-toolbar-sub {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--rp-muted);
}

.dash-add-btn {
  width: auto !important;
  margin: 0 !important;
  display: inline-flex !important;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.1rem !important;
  font-size: 0.875rem !important;
}

.dash-site-card { position: relative; }

.dash-card-actions {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
}

.dash-icon-btn {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(251, 113, 133, 0.2);
  border-radius: 10px;
  background: rgba(251, 113, 133, 0.08);
  color: #fda4af;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.dash-icon-btn:hover {
  background: rgba(251, 113, 133, 0.16);
  border-color: rgba(251, 113, 133, 0.35);
}

body.panel-modal-open { overflow: hidden; }

.panel-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 1.25rem;
}

.panel-modal[hidden] { display: none !important; }

.panel-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 14, 0.72);
  backdrop-filter: blur(6px);
}

.panel-modal-dialog {
  position: relative;
  z-index: 1;
  width: min(720px, 100%);
  max-height: min(92vh, 820px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  background:
    linear-gradient(180deg, rgba(18, 24, 36, 0.98) 0%, rgba(10, 14, 22, 0.98) 100%);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  animation: modalIn 0.28s ease both;
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: none; }
}

.panel-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.35rem 0.75rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.panel-modal-eyebrow {
  display: block;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--rp-accent);
  margin-bottom: 0.25rem;
}

.panel-modal-header h3 {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 800;
}

.panel-modal-close {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 10px;
  background: rgba(148, 163, 184, 0.08);
  color: var(--rp-muted);
  cursor: pointer;
}

.panel-modal-close:hover { color: var(--rp-text); background: rgba(148, 163, 184, 0.14); }

.panel-modal-body {
  padding: 1rem 1.35rem 1.25rem;
  overflow-y: auto;
  flex: 1;
  min-height: 0;
}

.panel-modal-intro {
  margin: 0 0 1rem;
  font-size: 0.8125rem;
  color: var(--rp-muted);
  line-height: 1.5;
}

.manage-section {
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.manage-section:last-of-type { border-bottom: none; }

.manage-section-title {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--rp-muted);
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.manage-section-title i { color: #22d3ee; }

.manage-check-wrap {
  display: flex;
  align-items: flex-end;
  padding-bottom: 0.35rem;
}

.manage-tawk-area {
  min-height: 72px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.78rem;
}

.manage-advanced {
  margin-top: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: 12px;
  border: 1px dashed rgba(148, 163, 184, 0.18);
  background: rgba(15, 23, 42, 0.35);
}

.manage-advanced summary {
  cursor: pointer;
  font-size: 0.8125rem;
  color: var(--rp-muted);
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.manage-advanced summary::-webkit-details-marker { display: none; }

.panel-modal-tabs {
  display: flex;
  gap: 0.45rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.panel-tab {
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(8, 12, 20, 0.65);
  color: var(--rp-muted);
  border-radius: 999px;
  padding: 0.45rem 0.85rem;
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
}

.panel-tab.active,
.panel-tab:hover {
  color: var(--rp-text);
  border-color: rgba(34, 211, 238, 0.35);
  background: rgba(34, 211, 238, 0.1);
}

.panel-tab-panel { display: none; }
.panel-tab-panel.active { display: block; }

.panel-link-btn {
  margin-top: 0.75rem;
  border: none;
  background: none;
  color: var(--rp-accent);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0;
}

.panel-link-btn:hover { text-decoration: underline; }

.panel-check {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 0.85rem;
  font-size: 0.8125rem;
  color: var(--rp-muted);
  cursor: pointer;
}

.panel-check input { accent-color: var(--rp-accent); }

.panel-modal-note {
  margin: 0.75rem 0 0;
  font-size: 0.75rem;
  color: var(--rp-muted);
}

.panel-modal-alert {
  margin-top: 0.85rem;
  padding: 0.7rem 0.85rem;
  border-radius: 10px;
  font-size: 0.8125rem;
}

.panel-modal-alert.ok {
  background: rgba(52, 211, 153, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.25);
  color: #bbf7d0;
}

.panel-modal-alert.err {
  background: rgba(251, 113, 133, 0.12);
  border: 1px solid rgba(251, 113, 133, 0.25);
  color: #fecdd3;
}

.panel-modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 0.65rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(148, 163, 184, 0.08);
}

.panel-btn-ghost {
  border: 1px solid rgba(148, 163, 184, 0.14);
  background: transparent;
  color: var(--rp-muted);
  border-radius: 12px;
  padding: 0.65rem 1rem;
  font: inherit;
  font-size: 0.875rem;
  cursor: pointer;
}

.panel-btn-ghost:hover { color: var(--rp-text); border-color: rgba(148, 163, 184, 0.28); }

.panel-btn-save {
  width: auto !important;
  margin: 0 !important;
  display: inline-flex !important;
  align-items: center;
  gap: 0.45rem;
  padding: 0.7rem 1.1rem !important;
  font-size: 0.875rem !important;
}

.panel-modal-dialog-wide { max-width: 680px; }

.form-group-full { grid-column: 1 / -1; }

textarea.form-input {
  min-height: 88px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.78rem;
  line-height: 1.45;
}

.deploy-wizard-steps {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.15rem;
}

.deploy-step {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  color: var(--rp-muted);
  font-size: 0.78rem;
}

.deploy-step span {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(148, 163, 184, 0.12);
  font-size: 0.72rem;
  font-weight: 700;
}

.deploy-step.active {
  color: var(--rp-text);
  border-color: rgba(34, 211, 238, 0.35);
  background: rgba(34, 211, 238, 0.08);
}

.deploy-step.active span,
.deploy-step.done span {
  background: linear-gradient(135deg, var(--rp-accent), var(--rp-accent-2));
  color: #041018;
}

.deploy-step.done { opacity: 0.85; }

.deploy-panel { display: none; }
.deploy-panel.active { display: block; }

.deploy-panel-hint {
  margin: 0 0 1rem;
  color: var(--rp-muted);
  font-size: 0.875rem;
  line-height: 1.5;
}

.deploy-check-result {
  margin-top: 0.85rem;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  font-size: 0.84rem;
}

.deploy-check-result.ok {
  background: rgba(52, 211, 153, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.25);
  color: #bbf7d0;
}

.deploy-progress {
  height: 8px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.12);
  overflow: hidden;
  margin-bottom: 0.85rem;
}

.deploy-progress-bar {
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--rp-accent), var(--rp-accent-2));
  transition: width 0.35s ease;
}

.deploy-log {
  max-height: 220px;
  overflow: auto;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 12px;
  padding: 0.75rem;
  background: rgba(0, 0, 0, 0.22);
}

.deploy-log-line {
  font-size: 0.78rem;
  color: var(--rp-muted);
  padding: 0.18rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.06);
}

.deploy-log-line.ok { color: #86efac; }
.deploy-log-line.err { color: #fecdd3; }

.brand-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.brand-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.25rem;
  padding: 0.9rem;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  background: var(--rp-surface-2);
  color: var(--rp-text);
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.brand-card strong { font-size: 0.95rem; }
.brand-card span { font-size: 0.75rem; color: var(--rp-muted); }

.brand-card:hover,
.brand-card.selected {
  border-color: rgba(34, 211, 238, 0.45);
  box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.15);
}

@media (max-width: 720px) {
  .brand-grid { grid-template-columns: 1fr; }
  .deploy-wizard-steps { flex-direction: column; }
}

/* ─── Entegrasyon ─── */
.integ-hero {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 1.25rem;
  padding: 1.5rem 1.65rem;
  margin-bottom: 1.25rem;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background:
    linear-gradient(135deg, rgba(34, 211, 238, 0.07) 0%, transparent 50%),
    rgba(12, 16, 24, 0.9);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.28);
}

.integ-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.22);
  color: var(--rp-accent);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.integ-quote {
  margin: 1rem 0 0;
  padding: 0;
  border: none;
  max-width: 420px;
}

.integ-quote p {
  margin: 0;
  font-size: clamp(1rem, 2vw, 1.25rem);
  font-weight: 600;
  line-height: 1.55;
  color: rgba(226, 232, 240, 0.92);
}

.integ-section-icon.crypto { background: rgba(251, 191, 36, 0.12); color: #fbbf24; }

.integ-crypto-grid {
  display: grid;
  gap: 0.85rem;
}

.integ-crypto-grid code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.72rem;
  color: rgba(148, 163, 184, 0.95);
}

.integ-hero-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem;
}

.integ-stat {
  padding: 0.85rem 0.95rem;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 19, 28, 0.75);
}

.integ-stat-label {
  display: block;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--rp-muted);
  margin-bottom: 0.3rem;
}

.integ-stat-value {
  display: block;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--rp-text);
}

.integ-stat small {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.6875rem;
  color: rgba(143, 163, 191, 0.85);
  word-break: break-all;
}

.integ-form {
  margin-bottom: 0.85rem;
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(12, 16, 24, 0.55);
  overflow: hidden;
}

.integ-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.85rem;
  padding: 0.85rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(12, 16, 24, 0.88);
}

.integ-toolbar-left,
.integ-toolbar-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.integ-accordion {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 0.85rem;
}

.integ-acc-item {
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 16px;
  background: rgba(10, 14, 22, 0.92);
  overflow: hidden;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.integ-acc-item[open],
.integ-acc-item.is-open {
  border-color: rgba(34, 211, 238, 0.22);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
}

.integ-acc-sync {
  margin-top: 0.55rem;
  margin-bottom: 1rem;
}

.integ-acc-summary {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.95rem 1.1rem;
  cursor: pointer;
  user-select: none;
}

.integ-acc-summary::-webkit-details-marker,
.integ-acc-summary::marker {
  display: none;
  content: '';
}

.integ-acc-summary-sm {
  padding: 0.75rem 0.95rem;
  background: rgba(148, 163, 184, 0.04);
}

.integ-acc-title {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
  flex: 1;
}

.integ-acc-title strong {
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--rp-text);
}

.integ-acc-title small {
  font-size: 0.75rem;
  color: var(--rp-muted);
  line-height: 1.4;
}

.integ-acc-chevron {
  flex-shrink: 0;
  margin-left: 0.35rem;
  color: var(--rp-muted);
  font-size: 0.75rem;
  transition: transform 0.2s ease, color 0.2s ease;
}

.integ-acc-item[open] > .integ-acc-summary .integ-acc-chevron,
.integ-acc-item.is-open > .integ-acc-summary .integ-acc-chevron {
  transform: rotate(180deg);
  color: var(--rp-accent);
}

.integ-acc-body {
  padding: 0 1.1rem 1.1rem;
}

.integ-acc-body-flush {
  padding: 0 0 0.85rem;
}

.integ-acc-nested {
  margin-top: 0.55rem;
  border-radius: 12px;
  background: rgba(8, 11, 18, 0.55);
}

.integ-acc-nested:first-child {
  margin-top: 0;
}

.integ-section-icon.sync { background: rgba(167, 139, 250, 0.12); color: #a78bfa; }

.integ-sync-toolbar {
  display: flex;
  justify-content: flex-end;
  padding: 0 1.1rem 0.65rem;
}

.integ-section {
  padding: 1.35rem 1.5rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.integ-section:last-of-type {
  border-bottom: none;
}

.integ-section-head {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  margin-bottom: 1.15rem;
}

.integ-section-head h2 {
  margin: 0 0 0.25rem;
  font-size: 1.05rem;
  font-weight: 700;
}

.integ-section-head p {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--rp-muted);
  line-height: 1.5;
}

.integ-section-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  font-size: 1.1rem;
}

.integ-section-icon.tg { background: rgba(34, 211, 238, 0.12); color: #22d3ee; }
.integ-section-icon.iban { background: rgba(52, 211, 153, 0.12); color: #34d399; }
.integ-section-icon.tawk { background: rgba(96, 165, 250, 0.12); color: #60a5fa; }

.integ-subblock {
  padding: 1rem 0 0;
}

.integ-subblock + .integ-subblock {
  margin-top: 1.15rem;
  padding-top: 1.15rem;
  border-top: 1px dashed rgba(148, 163, 184, 0.14);
}

.integ-subblock-title {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0 0 0.85rem;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--rp-text);
}

.integ-subblock-title span {
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.1);
  color: var(--rp-muted);
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.integ-subblock-site .integ-site-tawk-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.15rem;
}

.integ-subblock-site .integ-btn-primary {
  margin-left: 0;
}

.integ-field-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.integ-field {
  margin-bottom: 1rem;
}

.integ-field-full {
  margin-bottom: 0;
}

.integ-field label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--rp-muted);
  margin-bottom: 0.45rem;
}

.integ-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0 1rem 0 0.95rem;
  background: rgba(8, 11, 18, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 14px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.integ-input-wrap:focus-within {
  border-color: rgba(34, 211, 238, 0.45);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.12);
}

.integ-input-icon {
  flex-shrink: 0;
  width: 1rem;
  text-align: center;
  color: rgba(148, 163, 184, 0.65);
  font-size: 0.875rem;
  line-height: 1;
  pointer-events: none;
}

.integ-input,
.integ-textarea {
  width: 100%;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  color: var(--rp-text) !important;
  border-radius: 0 !important;
  padding: 0.95rem 0 !important;
  font-size: 0.9375rem !important;
  line-height: 1.45 !important;
  transition: none;
}

.integ-input-wrap .integ-input,
.integ-input-wrap select.integ-input {
  flex: 1;
  min-width: 0;
}

.integ-input-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace !important;
  font-size: 0.875rem !important;
  letter-spacing: 0.01em;
}

.integ-input-iban {
  font-size: 1rem !important;
  letter-spacing: 0.06em;
}

.integ-input-wrap:has(.integ-input-actions) {
  padding-right: 0.45rem;
}

.integ-input:focus,
.integ-textarea:focus {
  outline: none !important;
  border-color: transparent !important;
  box-shadow: none !important;
}

.integ-textarea {
  min-height: 120px;
  resize: vertical;
  padding: 1rem 1.1rem !important;
  background: rgba(8, 11, 18, 0.85) !important;
  border: 1px solid rgba(148, 163, 184, 0.16) !important;
  border-radius: 14px !important;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace !important;
  font-size: 0.8125rem !important;
  line-height: 1.55 !important;
}

.integ-textarea:focus {
  border-color: rgba(34, 211, 238, 0.45) !important;
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.12) !important;
}

.integ-input-actions {
  position: static;
  transform: none;
  flex-shrink: 0;
  display: flex;
  gap: 0.25rem;
  margin-left: 0.15rem;
}

.integ-icon-btn {
  width: 34px;
  height: 34px;
  border: none;
  border-radius: 10px;
  background: rgba(148, 163, 184, 0.08);
  color: var(--rp-muted);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: color 0.15s ease, background 0.15s ease;
}

.integ-icon-btn:hover {
  color: var(--rp-accent);
  background: rgba(34, 211, 238, 0.12);
}

.integ-icon-btn.copied {
  color: #34d399;
  background: rgba(52, 211, 153, 0.12);
}

.integ-hint {
  display: block;
  margin-top: 0.45rem;
  font-size: 0.75rem;
  color: rgba(143, 163, 191, 0.8);
  line-height: 1.45;
}

.integ-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  padding: 1.15rem 1.5rem 1.35rem;
  background: rgba(8, 11, 18, 0.45);
  border-top: 1px solid rgba(148, 163, 184, 0.08);
}

.integ-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.75rem 1.1rem;
  border-radius: 12px;
  border: 1px solid transparent;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.integ-btn-sm {
  padding: 0.45rem 0.7rem;
  font-size: 0.8125rem;
}

.integ-btn-primary {
  margin-left: auto;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.95), rgba(52, 211, 153, 0.85));
  color: #041016;
  box-shadow: 0 8px 24px rgba(34, 211, 238, 0.22);
}

.integ-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(34, 211, 238, 0.28);
}

.integ-btn-ghost {
  background: rgba(148, 163, 184, 0.06);
  border-color: rgba(148, 163, 184, 0.14);
  color: var(--rp-text);
}

.integ-btn-ghost:hover {
  border-color: rgba(34, 211, 238, 0.28);
  color: var(--rp-accent);
}

.integ-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.integ-alert {
  margin: 0 0.85rem 0.85rem;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  font-size: 0.8125rem;
}

.integ-alert.ok {
  background: rgba(52, 211, 153, 0.1);
  border: 1px solid rgba(52, 211, 153, 0.25);
  color: #6ee7b7;
}

.integ-alert.err {
  background: rgba(251, 113, 133, 0.1);
  border: 1px solid rgba(251, 113, 133, 0.25);
  color: #fda4af;
}

.integ-sync {
  padding: 1.35rem 1.5rem;
}

.integ-sync-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.integ-sync-sub {
  margin: 0.35rem 0 0;
  font-size: 0.8125rem;
  color: var(--rp-muted);
}

.integ-sync-table-wrap {
  overflow-x: auto;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.1);
}

.integ-sync-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}

.integ-sync-table th,
.integ-sync-table td {
  padding: 0.85rem 1rem;
  text-align: left;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.integ-sync-table th {
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--rp-muted);
  background: rgba(8, 11, 18, 0.55);
}

.integ-sync-table tbody tr:hover {
  background: rgba(34, 211, 238, 0.03);
}

.integ-site-cell {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.integ-site-mark {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 0.72rem;
  font-weight: 800;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.2), rgba(52, 211, 153, 0.15));
  color: var(--rp-accent);
}

.integ-site-cell strong {
  display: block;
  font-size: 0.875rem;
}

.integ-site-cell span {
  display: block;
  font-size: 0.72rem;
  color: var(--rp-muted);
}

.integ-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
}

.integ-badge.ok {
  background: rgba(52, 211, 153, 0.12);
  color: #6ee7b7;
  border: 1px solid rgba(52, 211, 153, 0.22);
}

.integ-badge.warn {
  background: rgba(251, 191, 36, 0.1);
  color: #fcd34d;
  border: 1px solid rgba(251, 191, 36, 0.2);
}

.integ-badge.muted {
  background: rgba(148, 163, 184, 0.08);
  color: var(--rp-muted);
}

.integ-note {
  font-size: 0.75rem;
  color: var(--rp-muted);
  max-width: 180px;
}

@media (max-width: 960px) {
  .integ-hero { grid-template-columns: 1fr; }
  .integ-hero-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .integ-field-grid { grid-template-columns: 1fr; }
  .integ-toolbar { flex-direction: column; align-items: stretch; }
  .integ-toolbar-left,
  .integ-toolbar-right { justify-content: stretch; }
  .integ-toolbar-right .integ-btn { flex: 1; justify-content: center; }
  .integ-acc-summary { flex-wrap: wrap; }
}

/* ─── Komisyon ─── */
.komisyon-hero {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 1.25rem;
  padding: 1.5rem 1.65rem;
  margin-bottom: 1.25rem;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background:
    linear-gradient(135deg, rgba(168, 85, 247, 0.08) 0%, transparent 45%),
    linear-gradient(225deg, rgba(34, 211, 238, 0.06) 0%, transparent 40%),
    rgba(12, 16, 24, 0.88);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.komisyon-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #c4b5fd;
  background: rgba(168, 85, 247, 0.12);
  border: 1px solid rgba(168, 85, 247, 0.22);
  margin-bottom: 0.75rem;
}

.komisyon-hero-copy h2 {
  margin: 0 0 0.5rem;
  font-size: 1.35rem;
  font-weight: 700;
}

.komisyon-hero-copy p {
  margin: 0;
  color: var(--rp-muted);
  font-size: 0.875rem;
  line-height: 1.55;
}

.komisyon-kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.komisyon-kpi {
  padding: 0.9rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 23, 42, 0.55);
}

.komisyon-kpi span {
  display: block;
  font-size: 0.72rem;
  color: var(--rp-muted);
  margin-bottom: 0.35rem;
}

.komisyon-kpi strong {
  font-size: 1.05rem;
  font-weight: 700;
  color: #f8fafc;
}

.komisyon-kpi.kpi-saha strong { color: #34d399; }
.komisyon-kpi.kpi-hitbot strong { color: #a78bfa; }
.komisyon-kpi.kpi-kalan strong { color: #22d3ee; }

.komisyon-workspace {
  padding: 0;
  margin-bottom: 1rem;
  overflow: hidden;
}

.komisyon-workspace-grid {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
  min-height: 420px;
}

.komisyon-rates-col,
.komisyon-templates-col {
  display: flex;
  flex-direction: column;
  padding: 1.25rem 1.35rem;
  min-height: 100%;
}

.komisyon-rates-col {
  border-right: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 23, 42, 0.35);
}

.komisyon-col-head { margin-bottom: 1rem; }

.komisyon-col-head p {
  margin: 0.35rem 0 0;
  font-size: 0.78rem;
  color: var(--rp-muted);
  line-height: 1.45;
}

.komisyon-col-head-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.komisyon-var-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.komisyon-var-chips code {
  font-size: 0.68rem;
  padding: 0.2rem 0.45rem;
  border-radius: 6px;
  background: rgba(34, 211, 238, 0.08);
  border: 1px solid rgba(34, 211, 238, 0.15);
  color: #67e8f9;
}

.komisyon-rate-stack {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  flex: 1;
}

.komisyon-rate-hints {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin: 1rem 0;
  font-size: 0.72rem;
  color: var(--rp-muted);
  line-height: 1.4;
}

.komisyon-rate-hints i {
  color: rgba(34, 211, 238, 0.65);
  margin-right: 0.25rem;
}

.komisyon-tpl-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
  flex: 1;
  align-content: start;
}

.komisyon-tpl-item {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.komisyon-tpl-item label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.4rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.komisyon-tpl-item .komisyon-textarea {
  flex: 1;
  min-height: 120px;
}

.komisyon-save-full {
  width: 100%;
  margin-top: auto;
  justify-content: center;
}

.komisyon-input-wrap {
  position: relative;
}

.komisyon-input-wrap .form-input {
  padding-right: 2rem;
}

.komisyon-suffix {
  position: absolute;
  right: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--rp-muted);
  font-weight: 600;
}

.komisyon-textarea {
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.78rem;
  line-height: 1.45;
}

.komisyon-save-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.komisyon-save-secondary {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.9), rgba(34, 211, 238, 0.75));
}

.komisyon-history { padding: 1.25rem 1.35rem 1.35rem; }

.komisyon-history-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.komisyon-history-head p {
  margin: 0.35rem 0 0;
  font-size: 0.8125rem;
  color: var(--rp-muted);
}

.komisyon-history-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
}

.komisyon-history-badge {
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #22d3ee;
  background: rgba(34, 211, 238, 0.1);
  border: 1px solid rgba(34, 211, 238, 0.22);
}

.komisyon-history-scroll {
  max-height: 340px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.08);
}

.komisyon-history-table tbody tr:hover {
  background: rgba(34, 211, 238, 0.04);
}

.komisyon-history-table .komisyon-amount {
  color: #22d3ee;
}

.komisyon-danger-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.85rem;
  border-radius: 10px;
  border: 1px solid rgba(248, 113, 113, 0.35);
  background: rgba(248, 113, 113, 0.08);
  color: #fca5a5;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.komisyon-danger-btn:hover {
  background: rgba(248, 113, 113, 0.15);
  border-color: rgba(248, 113, 113, 0.5);
}

.komisyon-danger-solid {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.85), rgba(220, 38, 38, 0.75));
  border-color: transparent;
  color: #fff;
}

.komisyon-danger-solid:hover {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.95), rgba(220, 38, 38, 0.85));
}

.komisyon-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--rp-muted);
}

.komisyon-empty i {
  font-size: 1.75rem;
  opacity: 0.45;
  margin-bottom: 0.5rem;
}

body.komisyon-modal-open { overflow: hidden; }

.komisyon-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.komisyon-modal[hidden] { display: none !important; }

.komisyon-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(4px);
}

.komisyon-modal-card {
  position: relative;
  width: min(100%, 420px);
  padding: 1.35rem 1.5rem;
  z-index: 1;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
}

.komisyon-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.komisyon-modal-head h3 {
  margin: 0;
  font-size: 1.05rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #fca5a5;
}

.komisyon-modal-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.15);
  background: transparent;
  color: var(--rp-muted);
  cursor: pointer;
}

.komisyon-modal-text {
  margin: 0 0 1rem;
  font-size: 0.875rem;
  color: var(--rp-muted);
  line-height: 1.5;
}

.komisyon-modal-actions {
  display: flex;
  gap: 0.65rem;
  justify-content: flex-end;
  margin-top: 1rem;
}

.komisyon-modal-cancel {
  padding: 0.55rem 1rem;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: transparent;
  color: var(--rp-muted);
  cursor: pointer;
}

@media (max-width: 1100px) {
  .komisyon-tpl-grid { grid-template-columns: 1fr; }
  .komisyon-tpl-item .komisyon-textarea { min-height: 88px; }
}

@media (max-width: 960px) {
  .komisyon-hero { grid-template-columns: 1fr; }
  .komisyon-workspace-grid { grid-template-columns: 1fr; min-height: 0; }
  .komisyon-rates-col {
    border-right: none;
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
  }
  .komisyon-rate-stack {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
  }
  .komisyon-rate-hints { grid-column: 1 / -1; }
}

@media (max-width: 520px) {
  .komisyon-rate-stack { grid-template-columns: 1fr; }
  .komisyon-history-actions { flex-wrap: wrap; }
}

.log-filter-bar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.log-filter-main { flex: 1; min-width: 200px; }

.log-export-btn {
  width: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  white-space: nowrap;
}

.log-stats-hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1rem 1.25rem;
  align-items: start;
  padding: 1.15rem 1.35rem;
  margin-bottom: 1rem;
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background:
    linear-gradient(135deg, rgba(34, 211, 238, 0.07) 0%, transparent 50%),
    rgba(12, 16, 24, 0.88);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.log-stats-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #22d3ee;
  margin-bottom: 0.35rem;
}

.log-stats-copy p {
  margin: 0;
  font-size: 0.8125rem;
  color: var(--rp-muted);
  line-height: 1.45;
  max-width: 280px;
}

.log-stats-grid {
  display: flex;
  gap: 0.65rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.log-stat-card {
  min-width: 108px;
  padding: 0.75rem 0.9rem;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 23, 42, 0.55);
}

.log-stat-card.log-stat-main {
  border-color: rgba(34, 211, 238, 0.22);
  background: rgba(34, 211, 238, 0.06);
}

.log-stat-label {
  display: block;
  font-size: 0.68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--rp-muted);
  margin-bottom: 0.25rem;
}

.log-stat-value {
  display: block;
  font-size: 1.35rem;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1.1;
}

.log-stat-main .log-stat-value { color: #22d3ee; }

.log-stat-card small {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.68rem;
  color: var(--rp-muted);
}

.log-stats-sites {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(148, 163, 184, 0.08);
}

.log-site-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background: rgba(8, 12, 20, 0.55);
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s;
}

.log-site-pill:hover {
  border-color: rgba(34, 211, 238, 0.35);
  background: rgba(34, 211, 238, 0.06);
}

.log-site-pill strong {
  font-size: 0.8125rem;
  color: #22d3ee;
}

.log-table-card { margin-top: 0; }

.log-table-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.log-table-head .rich-card-title { margin: 0; }

.log-table-meta {
  font-size: 0.8125rem;
  color: var(--rp-muted);
}

.log-table-meta strong { color: #22d3ee; }

.log-empty-msg {
  margin: 0;
  color: var(--rp-muted);
}

@media (max-width: 720px) {
  .log-stats-hero { grid-template-columns: 1fr; }
  .log-stats-grid { justify-content: flex-start; }
}

/* ─── Ayarlar ─── */
.ayar-hero {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 1.25rem;
  padding: 1.5rem 1.65rem;
  margin-bottom: 1.25rem;
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.12);
  background:
    linear-gradient(135deg, rgba(251, 191, 36, 0.07) 0%, transparent 45%),
    linear-gradient(225deg, rgba(34, 211, 238, 0.06) 0%, transparent 40%),
    rgba(12, 16, 24, 0.88);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.ayar-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: #fcd34d;
  background: rgba(251, 191, 36, 0.12);
  border: 1px solid rgba(251, 191, 36, 0.22);
  margin-bottom: 0.75rem;
}

.ayar-hero-copy h2 {
  margin: 0 0 0.5rem;
  font-size: 1.35rem;
  font-weight: 700;
}

.ayar-hero-copy p {
  margin: 0;
  color: var(--rp-muted);
  font-size: 0.875rem;
  line-height: 1.55;
}

.ayar-kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.ayar-kpi {
  padding: 0.9rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 23, 42, 0.55);
}

.ayar-kpi span {
  display: block;
  font-size: 0.72rem;
  color: var(--rp-muted);
  margin-bottom: 0.35rem;
}

.ayar-kpi strong {
  font-size: 1.05rem;
  font-weight: 700;
  color: #f8fafc;
}

.ayar-kpi strong small {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--rp-muted);
}

.ayar-kpi.ok strong { color: #34d399; }
.ayar-kpi.warn strong { color: #fb7185; }

.ayar-workspace {
  padding: 0;
  margin-bottom: 1rem;
  overflow: hidden;
}

.ayar-workspace-grid {
  display: grid;
  grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
}

.ayar-panel-col,
.ayar-context-col {
  padding: 1.25rem 1.35rem;
}

.ayar-panel-col {
  border-right: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 23, 42, 0.35);
}

.ayar-col-head { margin-bottom: 1rem; }

.ayar-col-head p {
  margin: 0.35rem 0 0;
  font-size: 0.78rem;
  color: var(--rp-muted);
  line-height: 1.45;
}

.ayar-save-btn {
  width: 100%;
  margin-top: 0.5rem;
}

.ayar-active-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
  border-radius: 14px;
  border: 1px solid rgba(34, 211, 238, 0.2);
  background: rgba(34, 211, 238, 0.06);
}

.ayar-active-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 0.85rem;
  color: #fff;
  background: linear-gradient(135deg, #0891b2, #10b981);
}

.ayar-active-card strong {
  display: block;
  font-size: 0.95rem;
}

.ayar-active-card span {
  display: block;
  font-size: 0.78rem;
  color: var(--rp-muted);
  margin-top: 0.15rem;
  word-break: break-all;
}

.ayar-site-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.15rem;
}

.ayar-site-pill-form { margin: 0; }

.ayar-site-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.15);
  background: rgba(15, 23, 42, 0.45);
  color: var(--rp-text);
  font: inherit;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.ayar-site-pill:hover,
.ayar-site-pill.active {
  border-color: rgba(34, 211, 238, 0.35);
  background: rgba(34, 211, 238, 0.08);
}

.ayar-site-pill.active { color: #22d3ee; }

.ayar-sync-bar {
  padding: 0.85rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 23, 42, 0.4);
}

.ayar-sync-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.45rem;
  font-size: 0.78rem;
  color: var(--rp-muted);
}

.ayar-sync-meta strong {
  color: #22d3ee;
  font-size: 0.95rem;
}

.ayar-sync-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.12);
  overflow: hidden;
  margin-bottom: 0.65rem;
}

.ayar-sync-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #0891b2, #34d399);
}

.ayar-resync-form { margin: 0; }

.ayar-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0;
  border: 0;
  background: none;
  color: var(--rp-accent);
  font: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
}

.ayar-link-btn:hover { text-decoration: underline; }

.ayar-links {
  padding: 1.25rem 1.35rem;
  margin-bottom: 1rem;
}

.ayar-links-head { margin-bottom: 1rem; }

.ayar-link-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.ayar-link-tile {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.1);
  background: rgba(15, 23, 42, 0.45);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, transform 0.15s, background 0.15s;
}

.ayar-link-tile:hover {
  border-color: rgba(34, 211, 238, 0.28);
  background: rgba(34, 211, 238, 0.06);
  transform: translateY(-1px);
}

.ayar-link-icon {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  background: rgba(34, 211, 238, 0.1);
  color: #22d3ee;
}

.ayar-link-text {
  flex: 1;
  min-width: 0;
}

.ayar-link-text strong {
  display: block;
  font-size: 0.875rem;
}

.ayar-link-text small {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.72rem;
  color: var(--rp-muted);
  line-height: 1.35;
}

.ayar-link-arrow {
  color: var(--rp-muted);
  font-size: 0.8rem;
  flex-shrink: 0;
}

.ayar-status {
  padding: 1.25rem 1.35rem;
  margin-bottom: 1rem;
}

.ayar-status-grid {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.ayar-status-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.08);
  background: rgba(15, 23, 42, 0.35);
}

.ayar-status-site {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 140px;
}

.ayar-status-active {
  font-style: normal;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #22d3ee;
}

.ayar-status-tags {
  display: flex;
  gap: 0.35rem;
  flex: 1;
}

.ayar-status-err {
  color: #fb7185;
  font-size: 0.85rem;
}

@media (max-width: 960px) {
  .ayar-hero { grid-template-columns: 1fr; }
  .ayar-workspace-grid { grid-template-columns: 1fr; }
  .ayar-panel-col {
    border-right: 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
  }
  .ayar-link-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  .ayar-link-grid { grid-template-columns: 1fr; }
  .ayar-status-row { flex-wrap: wrap; }
}
