@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --sp-primary: #6d28d9;
  --sp-primary-dark: #5b21b6;
  --sp-primary-soft: #f5f3ff;
  --sp-gradient: linear-gradient(135deg, #6d28d9 0%, #2563eb 100%);

  --sp-ink: #0f172a;
  --sp-muted: #64748b;
  --sp-line: #e9ebf0;
  --sp-surface: #ffffff;
  --sp-bg: #f6f7fb;

  --sp-radius: 16px;
  --sp-radius-sm: 11px;
  --sp-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px -12px rgba(15, 23, 42, .12);
  --sp-shadow-lg: 0 18px 40px -18px rgba(15, 23, 42, .25);
}

html { font-size: 15px; }

body {
  background-color: var(--sp-bg);
  color: var(--sp-ink);
  font-family: 'Inter', -apple-system, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  letter-spacing: -.01em;
}

h1, h2, h3, h4, h5, h6 { font-weight: 700; letter-spacing: -.02em; }
.text-muted { color: var(--sp-muted) !important; }
a { text-decoration: none; }

/* Buttons */
.btn {
  border-radius: var(--sp-radius-sm);
  font-weight: 600;
  padding: .5rem 1.1rem;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease;
}
.btn:active { transform: translateY(1px); }
.btn-lg { padding: .75rem 1.4rem; font-size: 1rem; }
.btn-sm { border-radius: 9px; padding: .32rem .7rem; }

.btn-primary {
  background: var(--sp-gradient);
  border: 0;
  box-shadow: 0 6px 16px -6px rgba(109, 40, 217, .6);
}
.btn-primary:hover, .btn-primary:focus, .btn-primary:active {
  background: linear-gradient(135deg, #5b21b6 0%, #1d4ed8 100%) !important;
  border: 0;
  box-shadow: 0 10px 22px -8px rgba(109, 40, 217, .7);
}
.btn-outline-primary {
  color: var(--sp-primary);
  border-color: #ddd6fe;
  background: #fff;
}
.btn-outline-primary:hover, .btn-outline-primary:focus {
  background: var(--sp-primary-soft);
  border-color: var(--sp-primary);
  color: var(--sp-primary-dark);
}
.btn-outline-secondary {
  color: #475569;
  border-color: var(--sp-line);
  background: #fff;
}
.btn-outline-secondary:hover { background: #f1f5f9; border-color: #cbd5e1; color: var(--sp-ink); }

/* Marketing site */
.brand-gradient {
  background: var(--sp-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero {
  background: var(--sp-gradient);
  padding: 4rem 0;
}

.feature-card {
  border: 0;
  box-shadow: 0 1px 3px rgba(16, 24, 40, .08);
  transition: transform .15s ease, box-shadow .15s ease;
}
.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(16, 24, 40, .12);
}
.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: rgba(109, 40, 217, .1);
  color: var(--sp-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

.plan-card {
  border: 1px solid #e5e7eb;
}
.plan-featured {
  border: 2px solid var(--sp-primary);
  box-shadow: 0 8px 24px rgba(109, 40, 217, .15);
}

.auth-card {
  border: 0;
  box-shadow: 0 4px 16px rgba(16, 24, 40, .08);
}

/* ===== App shell (Panel + Admin) ===== */
.app-shell {
  display: flex;
  min-height: 100vh;
}

.app-sidebar {
  width: 258px;
  flex-shrink: 0;
  background: linear-gradient(180deg, #14161f 0%, #0d0f16 100%);
  color: #cbd5e1;
  display: flex;
  flex-direction: column;
  padding: 0 .75rem 1.5rem;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.app-sidebar::-webkit-scrollbar { width: 6px; }
.app-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.12); border-radius: 100px; }

.app-sidebar .sidebar-brand {
  padding: 1.4rem .75rem 1.25rem;
  font-weight: 800;
  font-size: 1.05rem;
  color: #fff;
  display: flex;
  align-items: center;
  gap: .5rem;
  letter-spacing: -.02em;
}
.app-sidebar .sidebar-brand i {
  background: var(--sp-gradient);
  width: 30px; height: 30px;
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  font-size: .95rem;
}

.app-sidebar .nav-link {
  color: #94a3b8;
  padding: .58rem .75rem;
  margin-bottom: 2px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  gap: .7rem;
  font-size: .89rem;
  font-weight: 500;
  transition: background .15s ease, color .15s ease;
}
.app-sidebar .nav-link i { font-size: 1.05rem; width: 20px; text-align: center; }
.app-sidebar .nav-link:hover { color: #fff; background: rgba(255,255,255,.06); }
.app-sidebar .nav-link.active {
  color: #fff;
  font-weight: 600;
  background: linear-gradient(100deg, rgba(109,40,217,.85), rgba(37,99,235,.55));
  box-shadow: 0 6px 16px -8px rgba(109, 40, 217, .9);
}
.app-sidebar .nav-link.disabled { color: #475569; pointer-events: none; }

.app-main { flex-grow: 1; min-width: 0; display: flex; flex-direction: column; }

.app-topbar {
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--sp-line);
  padding: .85rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 20;
}
.app-topbar > span:first-child { font-size: 1.05rem; font-weight: 700; letter-spacing: -.02em; }

.app-content { padding: 1.75rem 2rem 3rem; max-width: 1360px; width: 100%; }

/* Cards */
.card, .stat-card {
  border: 1px solid var(--sp-line);
  border-radius: var(--sp-radius);
  box-shadow: var(--sp-shadow);
  background: var(--sp-surface);
}
.stat-card .stat-icon {
  width: 46px;
  height: 46px;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}

/* Forms */
.form-label { font-weight: 600; font-size: .85rem; color: #334155; margin-bottom: .35rem; }
.form-control, .form-select {
  border-radius: var(--sp-radius-sm);
  border-color: var(--sp-line);
  padding: .55rem .85rem;
  font-size: .92rem;
  background-color: #fdfdff;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.form-control:focus, .form-select:focus {
  border-color: #c4b5fd;
  background-color: #fff;
  box-shadow: 0 0 0 4px rgba(109, 40, 217, .1);
}
.form-control::placeholder { color: #a3adbd; }
.form-control-lg, .form-select-lg { padding: .7rem 1rem; font-size: .98rem; border-radius: 13px; }
.form-check-input:checked { background-color: var(--sp-primary); border-color: var(--sp-primary); }
.form-check-input:focus { box-shadow: 0 0 0 4px rgba(109, 40, 217, .12); border-color: #c4b5fd; }
.form-text { color: var(--sp-muted); }

/* Tables */
.table { --bs-table-hover-bg: #faf9ff; }
.table > thead th {
  font-size: .74rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--sp-muted);
  font-weight: 700;
  border-bottom: 1px solid var(--sp-line);
  padding-bottom: .6rem;
}
.table > tbody td { border-color: #f1f3f7; padding-top: .7rem; padding-bottom: .7rem; }
.table > tbody tr:last-child td { border-bottom: 0; }

/* Badges, alerts, misc */
.badge { border-radius: 100px; font-weight: 600; padding: .35em .7em; letter-spacing: .01em; }
.alert {
  border: 0;
  border-radius: var(--sp-radius-sm);
  border-left: 3px solid transparent;
  font-size: .9rem;
}
.alert-success { background: #f0fdf4; color: #166534; border-left-color: #16a34a; }
.alert-danger { background: #fef2f2; color: #991b1b; border-left-color: #dc2626; }
.alert-warning { background: #fffbeb; color: #92400e; border-left-color: #f59e0b; }
.alert-info { background: #eff6ff; color: #1e40af; border-left-color: #3b82f6; }

.dropdown-menu { border: 1px solid var(--sp-line); border-radius: 14px; box-shadow: var(--sp-shadow-lg); padding: .4rem; }
.dropdown-item { border-radius: 9px; font-size: .88rem; }
.nav-pills .nav-link { border-radius: 10px; font-weight: 600; font-size: .88rem; color: #475569; }
.nav-pills .nav-link.active { background: var(--sp-primary); }
.accordion-button { font-weight: 600; }
.accordion-button:not(.collapsed) { background: var(--sp-primary-soft); color: var(--sp-primary-dark); box-shadow: none; }
.accordion-button:focus { box-shadow: none; border-color: var(--sp-line); }
.progress { border-radius: 100px; background: #eef0f5; }
.progress-bar { background: var(--sp-gradient); }

/* Sidebar: "Yakında" grubu */
.app-sidebar .nav-section-title {
  margin: 1.1rem .75rem .4rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, .07);
  font-size: .68rem;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: #64748b;
  font-weight: 700;
}
.app-sidebar .nav-link.soon { color: #64748b; }
.app-sidebar .nav-link.soon:hover { color: #cbd5e1; }
.app-sidebar .nav-link.soon.active { color: #fff; }

@media (max-width: 991.98px) {
  .app-sidebar { width: 72px; padding: 0 .5rem 1rem; }
  .app-sidebar .sidebar-brand span,
  .app-sidebar .nav-link span,
  .app-sidebar .nav-link .badge { display: none; }
  .app-sidebar .sidebar-brand { justify-content: center; padding-left: 0; padding-right: 0; }
  .app-sidebar .nav-link { justify-content: center; padding: .6rem 0; }
  .app-sidebar .nav-section-title { font-size: 0; padding-top: .7rem; margin: .7rem .25rem .4rem; }
  .app-topbar { padding: .75rem 1rem; }
  .app-content { padding: 1.25rem 1rem 2.5rem; }
}

/* ===== Panel dashboard ===== */
.dash-hero {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  padding: 2rem 2.25rem;
  margin-bottom: 1.5rem;
  background: linear-gradient(120deg, #3b0764 0%, #6d28d9 55%, #2563eb 100%);
  color: #fff;
}
.dash-hero-glow {
  position: absolute;
  width: 420px; height: 420px;
  right: -120px; top: -200px;
  background: radial-gradient(circle, rgba(255,255,255,.22) 0%, transparent 65%);
  pointer-events: none;
}
.dash-hero-content {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.dash-hero-plan {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  background: rgba(255,255,255,.16);
  border-radius: 100px;
  padding: .25rem .85rem;
  font-size: .78rem;
  font-weight: 600;
  margin-bottom: .75rem;
}
.dash-hero-title { font-size: 1.75rem; font-weight: 700; margin: 0 0 .35rem; }
.dash-hero-sub { opacity: .85; margin: 0; font-size: .95rem; }
.dash-hero-stats { display: flex; gap: 2rem; }
.dash-hero-stats div { text-align: center; }
.dash-hero-stats span { display: block; font-size: 1.6rem; font-weight: 700; line-height: 1.1; }
.dash-hero-stats small { opacity: .8; font-size: .75rem; }

.dash-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.dash-action {
  display: flex;
  align-items: center;
  gap: .9rem;
  padding: 1.1rem 1.25rem;
  border-radius: 16px;
  background: #fff;
  border: 1px solid #eceef2;
  text-decoration: none;
  color: inherit;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.dash-action:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(16, 24, 40, .10);
  border-color: transparent;
  color: inherit;
}
.dash-action-icon {
  width: 46px; height: 46px;
  flex-shrink: 0;
  border-radius: 13px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  color: #fff;
  background: linear-gradient(135deg, var(--a1), var(--a2));
}
.dash-action-body { display: flex; flex-direction: column; min-width: 0; }
.dash-action-body strong { font-size: .98rem; }
.dash-action-body span { font-size: .78rem; color: #6b7280; }
.dash-action-go { margin-left: auto; color: #c7cbd3; transition: transform .18s ease, color .18s ease; }
.dash-action:hover .dash-action-go { transform: translateX(3px); color: var(--sp-primary); }

.dash-panel {
  background: #fff;
  border: 1px solid #eceef2;
  border-radius: 18px;
  padding: 1.4rem 1.5rem;
}
.dash-panel-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 1.1rem;
}
.dash-panel-head h6 { margin: 0; font-weight: 700; }
.dash-panel-head a { text-decoration: none; color: var(--sp-primary); }

.dash-meter { margin-bottom: 1rem; }
.dash-meter-top {
  display: flex; justify-content: space-between; align-items: center;
  font-size: .85rem; margin-bottom: .35rem;
}
.dash-meter-bar { height: 8px; border-radius: 100px; background: #f1f2f6; overflow: hidden; }
.dash-meter-bar div { height: 100%; border-radius: 100px; transition: width .4s ease; }
.dash-meter-note { font-size: .72rem; color: #9ca3af; margin-top: .25rem; }

.dash-referral {
  display: flex; align-items: center; gap: .85rem;
  margin-top: 1.25rem;
  padding: .9rem 1rem;
  border-radius: 14px;
  text-decoration: none;
  color: #4c1d95;
  background: linear-gradient(120deg, #f5f3ff, #ede9fe);
  border: 1px dashed #c4b5fd;
  transition: border-color .18s ease;
}
.dash-referral:hover { border-color: var(--sp-primary); color: #4c1d95; }
.dash-referral i { font-size: 1.5rem; }
.dash-referral strong { display: block; font-size: .88rem; }
.dash-referral span { font-size: .76rem; opacity: .8; }

.dash-media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: .6rem;
  margin-bottom: 1.25rem;
}
.dash-media {
  position: relative;
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  display: block;
  background: #0f172a;
}
.dash-media img, .dash-media video { width: 100%; height: 100%; object-fit: cover; }
.dash-media-play {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  color: #fff; font-size: 1.4rem; opacity: .9;
}
.dash-media-ai {
  position: absolute; top: 5px; left: 5px;
  background: var(--sp-primary); color: #fff;
  font-size: .6rem; font-weight: 700;
  padding: .1rem .35rem; border-radius: 5px;
}

.dash-feed { display: flex; flex-direction: column; gap: .5rem; }
.dash-feed-item {
  display: flex; align-items: center; gap: .75rem;
  padding: .6rem .75rem;
  border-radius: 12px;
  background: #fafafc;
}
.dash-feed-icon {
  width: 32px; height: 32px; flex-shrink: 0;
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  background: #ede9fe; color: var(--sp-primary);
  font-size: .9rem;
}
.dash-feed-icon.err { background: #fee2e2; color: #dc2626; }
.dash-feed-body { display: flex; flex-direction: column; min-width: 0; flex-grow: 1; }
.dash-feed-title {
  font-size: .84rem; font-weight: 500;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.dash-feed-time { font-size: .72rem; color: #9ca3af; }

.dash-empty { text-align: center; padding: 2.5rem 1rem; }
.dash-empty i { font-size: 2.5rem; color: #c4b5fd; display: block; margin-bottom: .75rem; }
.dash-empty h6 { font-weight: 700; }
.dash-empty p { color: #6b7280; font-size: .88rem; max-width: 380px; margin: 0 auto 1.1rem; }

/* ===== Subscription & usage ===== */
.sub-hero {
  display: flex; justify-content: space-between; align-items: center;
  gap: 1.5rem; flex-wrap: wrap;
  background: linear-gradient(120deg, #3b0764 0%, #6d28d9 55%, #2563eb 100%);
  color: #fff;
  border-radius: 20px;
  padding: 1.75rem 2rem;
  margin-bottom: 1.5rem;
}
.sub-hero-label { font-size: .78rem; opacity: .8; text-transform: uppercase; letter-spacing: .06em; }
.sub-hero-plan { font-size: 1.9rem; font-weight: 800; line-height: 1.15; }
.sub-hero-price { font-size: 1.05rem; opacity: .9; }
.sub-hero-price small { opacity: .75; }
.sub-hero-date { font-size: .82rem; opacity: .8; margin-top: .5rem; }
.sub-hero-right { display: flex; gap: 1rem; flex-wrap: wrap; }
.sub-hero-quota {
  background: rgba(255,255,255,.14);
  border-radius: 14px;
  padding: .8rem 1.1rem;
  text-align: center;
  min-width: 118px;
}
.sub-hero-quota span { display: block; font-size: 1.5rem; font-weight: 800; line-height: 1.1; }
.sub-hero-quota small { font-size: .7rem; opacity: .85; }

.quota-row { padding: .9rem 0; border-bottom: 1px solid #f1f3f7; }
.quota-row:last-of-type { border-bottom: 0; }
.quota-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: .45rem; }
.quota-name { font-weight: 600; font-size: .92rem; }
.quota-nums { font-size: .8rem; color: var(--sp-muted); }
.quota-bar { height: 9px; border-radius: 100px; background: #f1f2f6; overflow: hidden; }
.quota-bar div { height: 100%; border-radius: 100px; transition: width .4s ease; }
.quota-foot {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: .35rem; font-size: .8rem;
}
.quota-left { color: #16a34a; }
.quota-foot a { color: var(--sp-primary); font-weight: 600; }

.quota-bonus {
  display: flex; align-items: center; gap: .8rem;
  margin-top: 1rem; padding: .8rem 1rem;
  border-radius: 13px;
  background: linear-gradient(120deg, #f5f3ff, #ede9fe);
  border: 1px dashed #c4b5fd;
  color: #4c1d95;
}
.quota-bonus i { font-size: 1.3rem; }
.quota-bonus strong { display: block; font-size: .87rem; }
.quota-bonus span { font-size: .75rem; opacity: .85; }
.quota-bonus a { margin-left: auto; font-weight: 600; font-size: .8rem; color: var(--sp-primary); white-space: nowrap; }

.quota-extra {
  display: flex; gap: 1.5rem; flex-wrap: wrap;
  margin-top: 1rem; padding-top: .9rem;
  border-top: 1px solid #f1f3f7;
  font-size: .85rem; color: #475569;
}

.upgrade-card {
  position: relative;
  border: 1px solid var(--sp-line);
  border-radius: 15px;
  padding: 1.1rem 1.2rem;
  margin-bottom: 1rem;
}
.upgrade-card.featured { border-color: var(--sp-primary); box-shadow: 0 10px 26px -14px rgba(109,40,217,.6); }
.upgrade-tag {
  position: absolute; top: -10px; right: 14px;
  background: var(--sp-gradient); color: #fff;
  font-size: .68rem; font-weight: 700;
  padding: .18rem .6rem; border-radius: 100px;
}
.upgrade-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: .6rem; }
.upgrade-head strong { font-size: 1.05rem; }
.upgrade-head span { font-weight: 700; color: var(--sp-primary); }
.upgrade-head small { font-weight: 500; font-size: .72rem; color: var(--sp-muted); }
.upgrade-list { list-style: none; padding: 0; margin: 0 0 .9rem; }
.upgrade-list li { font-size: .83rem; padding: .18rem 0; color: #475569; display: flex; gap: .4rem; }
.upgrade-list li i { color: #16a34a; }

/* ===== "Yakında" feature page ===== */
.soon-wrap { display: flex; justify-content: center; padding: 1rem 0 2rem; }
.soon-card {
  max-width: 620px; width: 100%;
  background: #fff;
  border: 1px solid #eceef2;
  border-radius: 22px;
  padding: 2.25rem 2rem;
  text-align: center;
  position: relative;
}
.soon-badge {
  position: absolute; top: 1rem; right: 1rem;
  background: #fef3c7; color: #92400e;
  font-size: .72rem; font-weight: 700;
  padding: .25rem .7rem; border-radius: 100px;
}
.soon-icon {
  width: 76px; height: 76px; margin: 0 auto 1rem;
  border-radius: 22px;
  display: flex; align-items: center; justify-content: center;
  font-size: 2.1rem; color: #fff;
  background: linear-gradient(135deg, #6d28d9, #2563eb);
}
.soon-title { font-weight: 700; font-size: 1.5rem; margin-bottom: .5rem; }
.soon-summary { color: #6b7280; max-width: 460px; margin: 0 auto 1.5rem; }
.soon-features {
  text-align: left;
  background: #fafafc;
  border-radius: 14px;
  padding: 1.1rem 1.25rem;
}
.soon-features-head { font-weight: 700; font-size: .9rem; margin-bottom: .6rem; }
.soon-features ul { list-style: none; padding: 0; margin: 0; }
.soon-features li {
  display: flex; align-items: flex-start; gap: .55rem;
  font-size: .87rem; padding: .3rem 0; color: #374151;
}
.soon-features li i { color: #16a34a; margin-top: .15rem; }
.soon-note {
  margin-top: 1.1rem;
  font-size: .82rem;
  color: #92400e;
  background: #fffbeb;
  border-radius: 12px;
  padding: .7rem .9rem;
}
.soon-note a { color: #92400e; font-weight: 600; }

/* ===== Ödeme sonuç sayfası ===== */
.odeme-ikon {
  width: 76px; height: 76px; margin: .5rem auto 1.1rem;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 2.1rem;
}
.odeme-ikon.basari { background: #dcfce7; color: #16a34a; }
.odeme-ikon.hata { background: #fee2e2; color: #dc2626; }
.odeme-ikon.bekliyor { background: #fef3c7; color: #d97706; }

.odeme-ozet {
  margin-top: 1.5rem;
  border: 1px solid var(--sp-line);
  border-radius: 14px;
  overflow: hidden;
}
.odeme-ozet > div {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: .7rem 1rem;
  font-size: .87rem;
  border-bottom: 1px solid #f1f3f7;
}
.odeme-ozet > div:last-child { border-bottom: 0; }
.odeme-ozet > div:nth-child(odd) { background: #fafbfd; }
.odeme-ozet span { color: var(--sp-muted); }

/* ===== Admin: sidebar badges ===== */
.app-sidebar .nav-link { position: relative; }
.nav-badge {
  margin-left: auto;
  min-width: 20px; text-align: center;
  font-size: .68rem; font-weight: 700;
  padding: .1rem .38rem; border-radius: 100px;
  background: rgba(255,255,255,.18); color: #fff;
}
.nav-badge.danger { background: #ef4444; color: #fff; }
.nav-badge.warn { background: #f59e0b; color: #422006; }
.nav-soon {
  margin-left: auto;
  font-size: .62rem; font-weight: 700; letter-spacing: .02em;
  padding: .1rem .4rem; border-radius: 100px;
  background: rgba(255,255,255,.14); color: rgba(255,255,255,.75);
}

/* ===== Admin dashboard ===== */
.adash-hero {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1.25rem;
  background: var(--sp-gradient);
  border-radius: 22px;
  padding: 1.6rem 1.8rem;
  color: #fff;
  margin-bottom: 1.25rem;
  box-shadow: 0 18px 40px -26px rgba(109,40,217,.9);
}
.adash-hero-greet { font-size: 1.5rem; font-weight: 700; }
.adash-hero-sub { margin: .3rem 0 0; font-size: .88rem; opacity: .85; }
.adash-hero-mrr {
  text-align: right;
  background: rgba(255,255,255,.14);
  border-radius: 16px;
  padding: .8rem 1.2rem;
  backdrop-filter: blur(6px);
}
.adash-hero-mrr span { display: block; font-size: .72rem; opacity: .8; }
.adash-hero-mrr strong { display: block; font-size: 1.7rem; line-height: 1.2; }
.adash-hero-mrr small { font-size: .72rem; opacity: .8; }

.adash-alerts { display: flex; flex-wrap: wrap; gap: .7rem; margin-bottom: 1.25rem; }
.adash-alert {
  display: flex; align-items: center; gap: .55rem;
  padding: .6rem .95rem;
  border-radius: 100px;
  font-size: .84rem; text-decoration: none;
  border: 1px solid transparent;
  transition: transform .15s ease, box-shadow .15s ease;
}
.adash-alert:hover { transform: translateY(-1px); box-shadow: var(--sp-shadow); }
.adash-alert.danger { background: #fef2f2; border-color: #fecaca; color: #b91c1c; }
.adash-alert.warn { background: #fffbeb; border-color: #fde68a; color: #b45309; }
.adash-alert.info { background: #eff6ff; border-color: #bfdbfe; color: #1d4ed8; }
.adash-alert .bi-chevron-right { font-size: .7rem; opacity: .6; }

.adash-kpis {
  display: grid; gap: 1rem; margin-bottom: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
}
.adash-kpi {
  display: flex; align-items: center; gap: .9rem;
  background: #fff; border: 1px solid #eceef2; border-radius: 18px;
  padding: 1.1rem 1.2rem; text-decoration: none; color: inherit;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.adash-kpi:hover { transform: translateY(-2px); box-shadow: var(--sp-shadow); border-color: #ddd6fe; }
.adash-kpi-icon {
  flex: 0 0 auto; width: 46px; height: 46px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.25rem;
}
.adash-kpi-body { display: flex; flex-direction: column; min-width: 0; }
.adash-kpi-label { font-size: .76rem; color: var(--sp-muted); }
.adash-kpi-value { font-size: 1.5rem; font-weight: 700; line-height: 1.15; }
.adash-kpi-sub { font-size: .72rem; color: #9ca3af; }

.adash-plan { padding: .65rem 0; border-bottom: 1px solid #f1f3f7; }
.adash-plan:last-child { border-bottom: 0; }
.adash-plan-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: .35rem; font-size: .87rem; }
.adash-plan-foot { margin-top: .3rem; font-size: .78rem; color: var(--sp-primary); font-weight: 600; }

.adash-quick { display: grid; grid-template-columns: 1fr 1fr; gap: .55rem; }
.adash-quick a {
  display: flex; align-items: center; gap: .45rem;
  font-size: .8rem; text-decoration: none; color: #475569;
  background: #f8f9fc; border-radius: 12px; padding: .6rem .7rem;
  transition: background .15s ease, color .15s ease;
}
.adash-quick a:hover { background: #f1eaff; color: var(--sp-primary); }

/* ===== Admin: subscriptions / media summary strip ===== */
.sub-summary {
  display: grid; gap: 1rem; margin-bottom: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}
.sub-summary-item {
  background: #fff; border: 1px solid #eceef2; border-radius: 16px;
  padding: .95rem 1.1rem;
}
.sub-summary-item span { display: block; font-size: .76rem; color: var(--sp-muted); }
.sub-summary-item strong { display: block; font-size: 1.55rem; font-weight: 700; line-height: 1.25; }
.sub-summary-item.accent strong { color: var(--sp-primary); }
.sub-summary-item.warn { border-color: #fde68a; background: #fffbeb; }
.sub-summary-item.warn strong { color: #b45309; }

tr.row-warn { background: #fffbeb; }

/* ===== Admin: finance ===== */
.fin-grid {
  display: grid; gap: 1rem; margin-bottom: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
}
.fin-card {
  border-radius: 18px; padding: 1.15rem 1.3rem;
  border: 1px solid #eceef2; background: #fff;
  display: flex; flex-direction: column; gap: .15rem;
}
.fin-label { font-size: .78rem; color: var(--sp-muted); }
.fin-value { font-size: 1.75rem; font-weight: 700; line-height: 1.2; }
.fin-sub { font-size: .73rem; color: #9ca3af; }
.fin-card.revenue { background: linear-gradient(135deg, #ecfdf5, #f0fdf4); border-color: #bbf7d0; }
.fin-card.revenue .fin-value { color: #15803d; }
.fin-card.cost { background: linear-gradient(135deg, #fef2f2, #fff1f2); border-color: #fecaca; }
.fin-card.cost .fin-value { color: #be123c; }
.fin-card.profit { background: linear-gradient(135deg, #f5f3ff, #eef2ff); border-color: #ddd6fe; }
.fin-card.profit .fin-value { color: #6d28d9; }
.fin-card.profit.negative { background: #fef2f2; border-color: #fecaca; }
.fin-card.profit.negative .fin-value { color: #b91c1c; }
.fin-card.rate code { font-size: .68rem; }
.fin-card.tokens { background: linear-gradient(135deg, #eff6ff, #f0f9ff); border-color: #bfdbfe; }
.fin-card.tokens .fin-value { color: #1d4ed8; }

.fin-unit {
  display: grid; gap: .75rem; margin-bottom: .6rem;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}
.fin-unit-item {
  background: #fff; border: 1px solid #eceef2; border-radius: 14px;
  padding: .7rem .9rem;
}
.fin-unit-item span { display: block; font-size: .72rem; color: var(--sp-muted); line-height: 1.35; }
.fin-unit-item strong { display: block; font-size: 1.15rem; font-weight: 700; margin-top: .15rem; }
.fin-unit-item.good strong { color: #16a34a; }
.fin-unit-item.bad { border-color: #fecaca; background: #fef2f2; }
.fin-unit-item.bad strong { color: #b91c1c; }

/* ===== Admin: media oversight ===== */
.amedia-grid {
  display: grid; gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
}
.amedia-card {
  background: #fff; border: 1px solid #eceef2; border-radius: 16px;
  overflow: hidden; display: flex; flex-direction: column;
  transition: box-shadow .18s ease, border-color .18s ease;
}
.amedia-card:hover { box-shadow: var(--sp-shadow); border-color: #ddd6fe; }
.amedia-thumb {
  position: relative; aspect-ratio: 4 / 3; background: #0f172a;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.amedia-thumb img, .amedia-thumb video { width: 100%; height: 100%; object-fit: cover; }
.amedia-play {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 2rem; text-shadow: 0 2px 12px rgba(0,0,0,.6); pointer-events: none;
}
.amedia-kind {
  position: absolute; left: .5rem; top: .5rem;
  background: rgba(15,23,42,.75); color: #fff;
  font-size: .66rem; font-weight: 600;
  padding: .12rem .45rem; border-radius: 100px;
}
.amedia-kind.vid { background: rgba(190,18,60,.85); }
.amedia-ai {
  position: absolute; right: .5rem; top: .5rem;
  background: var(--sp-gradient); color: #fff;
  font-size: .66rem; font-weight: 700;
  padding: .12rem .45rem; border-radius: 100px;
}
.amedia-body { padding: .7rem .85rem; flex: 1 1 auto; }
.amedia-owner { font-size: .8rem; font-weight: 600; text-decoration: none; color: var(--sp-ink); }
.amedia-owner:hover { color: var(--sp-primary); }
.amedia-meta { font-size: .7rem; color: #9ca3af; margin-top: .15rem; }
.amedia-prompt {
  font-size: .73rem; color: #64748b; margin-top: .4rem;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.amedia-foot {
  display: flex; justify-content: space-between; align-items: center;
  padding: .5rem .85rem; border-top: 1px solid #f1f3f7;
}
.amedia-link { font-size: .75rem; text-decoration: none; color: var(--sp-primary); font-weight: 600; }
.amedia-foot form { margin: 0; }

/* ===== Feature flags (admin) ===== */
.flag-intro {
  display: flex; gap: 1rem; align-items: flex-start;
  background: linear-gradient(120deg, #f5f3ff, #eef2ff);
  border: 1px solid #ddd6fe;
  border-radius: 18px;
  padding: 1.25rem 1.4rem;
  margin-bottom: 1.25rem;
}
.flag-intro-icon {
  flex: 0 0 auto;
  width: 46px; height: 46px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.35rem; color: #fff;
  background: var(--sp-gradient);
}
.flag-intro h5 { font-weight: 700; font-size: 1.02rem; color: #3b0764; }
.flag-intro p { font-size: .85rem; color: #4c1d95; line-height: 1.6; }

.flag-toolbar {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: .75rem; margin-bottom: 1rem;
}
.flag-count { font-size: .88rem; font-weight: 600; }
.flag-count-num {
  display: inline-block; min-width: 26px; text-align: center;
  background: #dcfce7; color: #15803d;
  border-radius: 8px; padding: .05rem .4rem; margin-right: .2rem;
}

.flag-new {
  background: #fff;
  border: 1px dashed var(--sp-line);
  border-radius: 16px;
  padding: 1.1rem 1.2rem;
}

.flag-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 1rem;
}
.flag-card {
  background: #fff;
  border: 1px solid #eceef2;
  border-radius: 18px;
  padding: 1.1rem 1.2rem;
  display: flex; flex-direction: column;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.flag-card.on { border-color: #bbf7d0; box-shadow: 0 8px 22px -18px rgba(22,163,74,.9); }
.flag-card.off { background: #fcfcfd; }
.flag-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: .75rem; }
.flag-name { font-weight: 700; font-size: 1rem; line-height: 1.3; }
.flag-key {
  font-size: .72rem; color: #94a3b8;
  background: #f5f6f9; border-radius: 6px; padding: .05rem .35rem;
}
.flag-desc {
  font-size: .83rem; color: #64748b;
  margin: .7rem 0 0; flex: 1 1 auto; line-height: 1.55;
}
.flag-card-foot {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: .9rem; padding-top: .7rem;
  border-top: 1px solid #f1f3f7;
}
.flag-state { font-size: .78rem; font-weight: 600; color: #94a3b8; }
.flag-card.on .flag-state { color: #16a34a; }
.flag-delete {
  border: 0; background: transparent; color: #cbd5e1;
  font-size: .95rem; padding: .1rem .3rem; border-radius: 8px;
  transition: color .15s ease, background .15s ease;
}
.flag-delete:hover { color: #dc2626; background: #fef2f2; }

.flag-switch-form { margin: 0; }
.flag-switch { position: relative; display: inline-block; width: 50px; height: 28px; cursor: pointer; }
.flag-switch input { opacity: 0; width: 0; height: 0; }
.flag-slider {
  position: absolute; inset: 0;
  background: #d7dbe3; border-radius: 100px;
  transition: background .25s ease;
}
.flag-slider::before {
  content: ""; position: absolute;
  height: 22px; width: 22px; left: 3px; top: 3px;
  background: #fff; border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,.25);
  transition: transform .25s ease;
}
.flag-switch input:checked + .flag-slider { background: #16a34a; }
.flag-switch input:checked + .flag-slider::before { transform: translateX(22px); }
.flag-switch input:focus-visible + .flag-slider { outline: 2px solid var(--sp-primary); outline-offset: 2px; }

.flag-empty {
  background: #fff; border: 1px dashed var(--sp-line);
  border-radius: 18px; padding: 2.5rem 1.5rem; text-align: center;
}
.flag-empty i { font-size: 2.2rem; color: #cbd5e1; display: block; margin-bottom: .6rem; }

/* ===== Public site (modern) ===== */
.site-body { background-color: #fff; }

.site-nav {
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--sp-line);
}
.site-nav .nav-link { font-weight: 600; color: #475569; font-size: .93rem; }
.site-nav .nav-link:hover { color: var(--sp-primary); }
.site-nav .nav-link.active { color: var(--sp-primary); }

.hero-modern {
  background:
    radial-gradient(1000px 500px at 85% -10%, rgba(56, 189, 248, .35), transparent 60%),
    radial-gradient(800px 500px at 10% 110%, rgba(217, 70, 239, .28), transparent 60%),
    linear-gradient(135deg, #3b0764 0%, #6d28d9 48%, #1d4ed8 100%);
  overflow: hidden;
}
.hero-modern h1 { letter-spacing: -.035em; }
.feature-card { border: 1px solid var(--sp-line); border-radius: var(--sp-radius); }
.feature-card:hover { box-shadow: var(--sp-shadow-lg); }
.plan-card { border: 1px solid var(--sp-line); border-radius: var(--sp-radius); }
.plan-featured { border: 2px solid var(--sp-primary); border-radius: var(--sp-radius); }
.auth-card { border: 1px solid var(--sp-line); border-radius: 20px; box-shadow: var(--sp-shadow-lg); }

.hero-badge {
  background: rgba(255, 255, 255, .15);
  color: #fff;
  padding: .35rem .9rem;
  border-radius: 100px;
  font-size: .85rem;
}

.hero-cards {
  position: relative;
  height: 340px;
  max-width: 420px;
}
.hero-card {
  position: absolute;
  background: #fff;
  border-radius: 14px;
  padding: 1rem 1.2rem;
  width: 220px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, .25);
}
.hero-card-1 { top: 10px; left: 0; transform: rotate(-4deg); }
.hero-card-2 { top: 120px; right: 0; transform: rotate(3deg); }
.hero-card-3 { bottom: 10px; left: 40px; transform: rotate(-2deg); }

.stats-band { background: #f8f9fc; border-bottom: 1px solid #eef0f4; }

.step-circle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--sp-gradient);
  color: #fff;
  font-size: 1.4rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cta-band { background: var(--sp-gradient); }

.page-hero { background: var(--sp-gradient); }

.news-card {
  border: 1px solid #eef0f4;
  color: inherit;
  transition: transform .15s ease, box-shadow .15s ease;
  overflow: hidden;
}
.news-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(16, 24, 40, .12);
  color: inherit;
}
.news-cover { height: 170px; object-fit: cover; }

.site-footer { background: #111827; color: #9ca3af; }
.site-footer a { color: #9ca3af; text-decoration: none; }
.site-footer a:hover { color: #fff; }
.footer-social { color: #9ca3af; }
.footer-social:hover { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .08); }
