*,
*::before,
*::after { box-sizing: border-box; }

:root {
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-glow: rgba(37, 99, 235, 0.18);
  --bg: #f0f2f8;
  --surface: #ffffff;
  --surface-alt: #f8f9fc;
  --text: #0f172a;
  --muted: #64748b;
  --border: #e2e8f0;
  --border-hover: #cbd5e1;
  --danger: #dc2626;
  --success: #16a34a;
  --warning: #f59e0b;
  --info: #0ea5e9;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 3px rgba(15,23,42,.06), 0 1px 2px rgba(15,23,42,.04);
  --shadow: 0 4px 24px rgba(15,23,42,.08);
  --shadow-lg: 0 10px 40px rgba(15,23,42,.12);
  --transition: .2s cubic-bezier(.4,0,.2,1);
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1120;
    --surface: #111827;
    --surface-alt: #1e293b;
    --text: #f1f5f9;
    --muted: #94a3b8;
    --border: #1e293b;
    --border-hover: #334155;
    --shadow-sm: 0 1px 3px rgba(0,0,0,.2);
    --shadow: 0 4px 24px rgba(0,0,0,.3);
    --shadow-lg: 0 10px 40px rgba(0,0,0,.4);
    --primary-glow: rgba(37, 99, 235, 0.12);
  }
}

html { font-size: 15px; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

.theme-app {
  background-image:
    radial-gradient(ellipse at 10% -10%, var(--primary-glow) 0%, transparent 50%),
    radial-gradient(ellipse at 90% 100%, rgba(139,92,246,.06) 0%, transparent 50%);
}

/* ---------- Layout ---------- */
.container { width: 100%; max-width: 1320px; margin: 0 auto; padding: 0 2rem; }
main.container { flex: 1; padding-top: 2rem; padding-bottom: 3rem; }

/* ---------- Header ---------- */
.site-header {
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: 60px;
}
.brand {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -.02em;
}
.brand-logo { height: 30px; width: auto; }

.nav-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .5rem .85rem;
}
.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  font-size: .9rem;
  padding: .35rem .5rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}
.nav-links a:hover,
.nav-links a.nav-active {
  color: var(--primary);
  background: var(--primary-glow);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: .6rem 1.15rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font-weight: 600;
  font-size: .875rem;
  cursor: pointer;
  text-decoration: none;
  background: var(--surface);
  color: var(--text);
  transition: all var(--transition);
  white-space: nowrap;
}
.btn:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}
.btn-primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.btn-primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  box-shadow: 0 4px 14px var(--primary-glow);
}
.btn-sm { padding: .4rem .75rem; font-size: .8rem; }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.link-btn {
  background: none;
  border: none;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  padding: .35rem .5rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}
.link-btn:hover { color: var(--primary); background: var(--primary-glow); }
.is-loading { opacity: .6; cursor: wait; pointer-events: none; }

.inline-form { display: inline; margin: 0; }

/* ---------- Cards ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.25rem;
  transition: all var(--transition);
}
.card:hover { box-shadow: var(--shadow); }
.card h1, .card h2, .card h3 { margin-top: 0; }
.card h1 { font-size: 1.5rem; }

/* ---------- Grid ---------- */
.grid { display: grid; gap: 1rem; }
@media (min-width: 720px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- Forms ---------- */
label { display: block; font-weight: 600; margin-bottom: .3rem; font-size: .9rem; color: var(--text); }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=url],
textarea, select {
  width: 100%;
  max-width: 100%;
  padding: .6rem .85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: .9rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}
textarea { min-height: 100px; resize: vertical; }
.form-row { margin-bottom: 1rem; }
.muted { color: var(--muted); font-size: .875rem; }

/* ---------- Checkbox / Radio restyle ---------- */
input[type=checkbox] {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
  vertical-align: middle;
  margin-right: .35rem;
}

/* ---------- Flash messages ---------- */
.flash {
  padding: .85rem 1.1rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  font-weight: 500;
  font-size: .9rem;
  border-left: 4px solid;
}
.flash-error { background: rgba(220,38,38,.08); color: var(--danger); border-left-color: var(--danger); }
.flash-success { background: rgba(22,163,74,.08); color: var(--success); border-left-color: var(--success); }
.flash-info { background: rgba(14,165,233,.08); color: var(--info); border-left-color: var(--info); }

/* ---------- Tables ---------- */
table.data {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: .85rem;
}
table.data th, table.data td {
  border-bottom: 1px solid var(--border);
  padding: .65rem .75rem;
  text-align: left;
  vertical-align: top;
}
table.data th {
  background: var(--surface-alt);
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  font-size: .75rem;
  letter-spacing: .04em;
  position: sticky;
  top: 0;
  z-index: 2;
}
table.data tbody tr {
  transition: background var(--transition);
}
table.data tbody tr:hover td,
table.data tbody tr.row-hover td {
  background: var(--primary-glow);
}
table.data tbody tr:last-child td { border-bottom: none; }

/* ---------- Badges ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  padding: .15rem .6rem;
  border-radius: 999px;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .03em;
  text-transform: uppercase;
  background: var(--surface-alt);
  color: var(--muted);
  border: 1px solid var(--border);
}
.badge-ok { background: rgba(22,163,74,.1); color: var(--success); border-color: rgba(22,163,74,.2); }
.badge-warn { background: rgba(245,158,11,.1); color: var(--warning); border-color: rgba(245,158,11,.2); }
.badge-bad { background: rgba(220,38,38,.1); color: var(--danger); border-color: rgba(220,38,38,.2); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.25rem 0;
  margin-top: auto;
  text-align: center;
}

/* ---------- Results & Code ---------- */
.results-wrap {
  overflow-x: auto;
  max-height: 70vh;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-top: .5rem;
}
pre.raw-json {
  background: var(--surface-alt);
  padding: 1rem;
  border-radius: var(--radius-sm);
  overflow: auto;
  font-size: .8rem;
  border: 1px solid var(--border);
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  line-height: 1.5;
}

/* ---------- Results summary bar ---------- */
.results-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .5rem;
  padding: .75rem 1rem;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  font-size: .9rem;
}
.results-summary__actions { display: flex; gap: .35rem; }

/* ---------- DB collapsible sections ---------- */
.db-section {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: .75rem;
  overflow: hidden;
  background: var(--surface);
}
.db-section__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .65rem 1rem;
  background: var(--surface-alt);
  cursor: pointer;
  user-select: none;
  transition: background var(--transition);
  border-bottom: 1px solid var(--border);
}
.db-section__header:hover { background: var(--primary-glow); }
.db-section__title {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-weight: 600;
  font-size: .9rem;
  word-break: break-all;
}
.db-section__chevron {
  transition: transform var(--transition);
  flex-shrink: 0;
}
.db-section.is-collapsed .db-section__chevron { transform: rotate(-90deg); }
.db-section.is-collapsed .db-section__body { display: none; }
.db-section__body { padding: 0; }
.db-section__body .results-wrap { border: none; border-radius: 0; margin-top: 0; }

/* ---------- Result table enhancements ---------- */
table.data--results { font-size: .82rem; }
table.data--results tbody tr:nth-child(even) td { background: var(--surface-alt); }
table.data--results tbody tr:hover td { background: var(--primary-glow) !important; }
table.data--results td {
  max-width: 320px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
table.data--results td:hover { white-space: normal; word-break: break-all; }
.row-num-col { width: 42px; text-align: center; color: var(--muted); font-size: .75rem; }

/* Monospace for credential-type columns */
table.data--results td[data-col="hash"],
table.data--results td[data-col="password"],
table.data--results td[data-col="salt"],
table.data--results td[data-col="lastip"] {
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: .78rem;
}

.show-more-btn {
  margin: .75rem 1rem;
}

/* ---------- Payload details ---------- */
.payload-details { margin-top: 1rem; }
.payload-details summary {
  cursor: pointer;
  font-weight: 600;
  padding: .5rem 0;
  color: var(--muted);
  font-size: .9rem;
}
.payload-details summary:hover { color: var(--primary); }

/* ---------- Extract toolbar ---------- */
.extract-toolbar {
  background: var(--surface);
  padding: 1.25rem;
}
.extract-toolbar__header { margin-bottom: .75rem; }
.extract-toolbar__fields {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  margin-bottom: .85rem;
}
.extract-chip {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .3rem .7rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-alt);
  font-size: .8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  margin: 0;
}
.extract-chip:hover { border-color: var(--primary); }
.extract-chip input[type=checkbox] { width: 14px; height: 14px; margin: 0; }
.extract-chip input[type=checkbox]:checked + span { color: var(--primary); font-weight: 600; }
.extract-chip:has(input:checked) {
  border-color: var(--primary);
  background: var(--primary-glow);
}
.extract-toolbar__actions { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: .5rem; }

/* Extract results panel */
.extract-result-panel {
  margin-top: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.extract-result-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .5rem;
  padding: .75rem 1rem;
  background: var(--surface-alt);
  border-bottom: 1px solid var(--border);
}
.extract-result-panel__body {
  padding: .75rem 1rem;
}
.extract-result-field__list {
  font-family: 'JetBrains Mono', 'Fira Code', monospace;
  font-size: .8rem;
  line-height: 1.8;
  white-space: pre-wrap;
  word-break: break-all;
  max-height: 400px;
  overflow-y: auto;
  background: var(--surface-alt);
  padding: .85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  counter-reset: extract-line;
}
.extract-copy-btn {
  padding: .25rem .6rem;
  font-size: .75rem;
}

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: .35rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.tabs a {
  padding: .5rem 1rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  font-size: .875rem;
  transition: all var(--transition);
}
.tabs a:hover { border-color: var(--border-hover); color: var(--text); }
.tabs a.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 2px 10px var(--primary-glow);
}

/* ---------- Typography ---------- */
h1 { font-size: 1.6rem; margin: 0 0 1rem; font-weight: 700; letter-spacing: -.02em; }
h2 { font-size: 1.25rem; font-weight: 700; letter-spacing: -.01em; }
h3 { font-size: 1.05rem; font-weight: 600; }
.actions { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }

/* ---------- Admin grid tiles ---------- */
.admin-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}
.admin-tile {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}
.admin-tile::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--primary);
  opacity: 0;
  transition: opacity var(--transition);
}
.admin-tile:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--border-hover);
}
.admin-tile:hover::before { opacity: 1; }
.admin-tile h3 { margin: 0 0 .3rem; font-size: 1rem; }
.admin-tile p { margin: 0; color: var(--muted); font-size: .85rem; }

/* ---------- Dashboard cards ---------- */
.dash-welcome { margin-bottom: 1.5rem; }
.dash-welcome h1 { margin-bottom: .15rem; }

.dash-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  margin-bottom: 2rem;
}
.dash-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  gap: 1rem;
  transition: all var(--transition);
}
.dash-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.dash-card__icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--primary-glow);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
}
.dash-card__body { flex: 1; display: flex; flex-direction: column; }
.dash-card__label { font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; }
.dash-card__value { font-size: 1.6rem; font-weight: 700; line-height: 1.2; margin-top: .2rem; }
.dash-card__value--muted { color: var(--muted); font-size: 1.1rem; }
.dash-card__value small { font-size: .8rem; font-weight: 400; }
.dash-card__meta { font-size: .8rem; color: var(--muted); margin-top: .25rem; }
.dash-card__link { font-size: .85rem; color: var(--primary); text-decoration: none; margin-top: .35rem; font-weight: 500; }
.dash-card__link:hover { text-decoration: underline; }

.dash-actions { margin-top: .5rem; }
.dash-actions h2 { margin-bottom: 1rem; }

/* ---------- Progress bar ---------- */
.progress-bar {
  width: 100%;
  height: 8px;
  background: var(--surface-alt);
  border-radius: 999px;
  overflow: hidden;
  margin-top: .4rem;
  border: 1px solid var(--border);
}
.progress-bar__fill {
  height: 100%;
  border-radius: 999px;
  background: var(--primary);
  transition: width .6s ease;
}
.progress-bar__fill--danger { background: var(--danger); }

/* ---------- User search dropdown (admin) ---------- */
.user-search-dropdown {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  max-height: 240px;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  z-index: 50;
  margin-top: .35rem;
}
.us-item {
  padding: .6rem .85rem;
  cursor: pointer;
  font-size: .875rem;
  transition: background var(--transition);
  border-bottom: 1px solid var(--border);
}
.us-item:last-child { border-bottom: none; }
.us-item:hover { background: var(--primary-glow); }
.selected-user-tag { margin-top: .5rem; }
.selected-user-tag .badge { font-size: .85rem; padding: .3rem .75rem; }
.clear-user { color: var(--danger); text-decoration: none; margin-left: .5rem; font-weight: 600; }
.clear-user:hover { text-decoration: underline; }

/* ---------- History detail header ---------- */
.history-detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .5rem;
  margin-bottom: .75rem;
}
.history-detail-header h1 { margin-bottom: 0; }
.history-db-name { margin-top: 1.25rem; margin-bottom: .5rem; }

/* ---------- Packages cards ---------- */
.package-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
}
.package-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.package-card h3 { font-size: 1.15rem; margin: 0 0 .5rem; }
.package-card .price { font-size: 1.8rem; font-weight: 700; color: var(--primary); line-height: 1; }
.package-card .price small { font-size: .85rem; font-weight: 400; color: var(--muted); }
.package-card .features { margin: 1rem 0; flex: 1; }
.package-card .features li {
  list-style: none;
  padding: .3rem 0;
  font-size: .875rem;
  color: var(--muted);
}
.package-card .features li::before {
  content: '✓';
  margin-right: .5rem;
  color: var(--success);
  font-weight: 700;
}

/* ---------- Login / register centered card ---------- */
.auth-card {
  max-width: 440px;
  margin: 2rem auto;
}

/* ---------- Landing page ---------- */
.main-landing { flex: 1; }

.landing { }

/* Hero */
.landing-hero {
  background:
    radial-gradient(ellipse at 60% 0%, rgba(37,99,235,.13) 0%, transparent 60%),
    radial-gradient(ellipse at 10% 100%, rgba(139,92,246,.09) 0%, transparent 50%);
  padding: 6rem 2rem 5rem;
  text-align: center;
  border-bottom: 1px solid var(--border);
}
.landing-hero__inner { max-width: 720px; margin: 0 auto; }

.landing-badge {
  display: inline-block;
  padding: .3rem .85rem;
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  background: var(--primary-glow);
  color: var(--primary);
  border: 1px solid rgba(37,99,235,.2);
  margin-bottom: 1.5rem;
}

.landing-hero__title {
  font-size: 3.2rem;
  font-weight: 800;
  letter-spacing: -.04em;
  line-height: 1.1;
  margin: 0 0 1.1rem;
  background: linear-gradient(135deg, var(--text) 30%, var(--primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.landing-hero__sub {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto 2.2rem;
  line-height: 1.7;
}
.landing-hero__cta { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; }
.btn-lg { padding: .75rem 1.6rem; font-size: 1rem; border-radius: 10px; }

/* Sections */
.landing-section {
  padding: 4.5rem 2rem;
  max-width: 1100px;
  margin: 0 auto;
}
.landing-section--alt {
  background: var(--surface-alt);
  max-width: 100%;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.landing-section--alt > *,
.landing-section--alt > div { max-width: 1100px; margin-left: auto; margin-right: auto; padding: 0 2rem; }
.landing-section__title {
  font-size: 1.9rem;
  font-weight: 800;
  text-align: center;
  letter-spacing: -.03em;
  margin: 0 0 .5rem;
}
.landing-section__sub {
  text-align: center;
  color: var(--muted);
  font-size: 1rem;
  margin: 0 0 2.5rem;
}

/* Feature cards */
.landing-features {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}
.landing-feature {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}
.landing-feature:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.landing-feature__icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--primary-glow);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}
.landing-feature h3 { margin: 0 0 .5rem; font-size: 1.05rem; }
.landing-feature p  { margin: 0; color: var(--muted); font-size: .9rem; line-height: 1.6; }

/* Data-type tags */
.landing-tags {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  justify-content: center;
  max-width: 760px;
  margin: 0 auto;
}
.landing-tag {
  padding: .4rem .9rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: .82rem;
  font-weight: 500;
  color: var(--text);
}

/* How it works steps */
.landing-steps {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  max-width: 900px;
  margin: 0 auto;
}
.landing-step {
  flex: 1;
  min-width: 200px;
  max-width: 260px;
  text-align: center;
}
.landing-step__num {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: 1.3rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
}
.landing-step h3 { font-size: 1rem; margin: 0 0 .4rem; }
.landing-step p  { font-size: .875rem; color: var(--muted); margin: 0; line-height: 1.55; }
.landing-step__arrow {
  font-size: 1.6rem;
  color: var(--border-hover);
  align-self: center;
  flex-shrink: 0;
  margin-top: -1rem;
}

/* Bottom CTA bar */
.landing-cta-bar {
  text-align: center;
  padding: 4rem 2rem;
  border-top: 1px solid var(--border);
  background: color-mix(in srgb, var(--primary-glow) 50%, transparent);
}
.landing-cta-bar h2 { font-size: 2rem; margin: 0 0 .5rem; letter-spacing: -.03em; }
.landing-cta-bar p  { color: var(--muted); margin: 0 0 1.75rem; font-size: 1rem; }

/* ---------- Landing stats bar ---------- */
.landing-stats-bar {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.landing-stats-bar__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0;
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.25rem 2rem;
}
.landing-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: .5rem 2.5rem;
  text-align: center;
}
.landing-stat__num {
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -.04em;
  color: var(--primary);
  line-height: 1.1;
}
.landing-stat__label {
  font-size: .78rem;
  font-weight: 500;
  color: var(--muted);
  margin-top: .2rem;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.landing-stat__div {
  width: 1px;
  height: 40px;
  background: var(--border);
  flex-shrink: 0;
}
@media (max-width: 640px) {
  .landing-stats-bar__inner { gap: .5rem; }
  .landing-stat { padding: .5rem 1rem; }
  .landing-stat__div { display: none; }
  .landing-stat__num { font-size: 1.35rem; }
}

/* ---------- Breach cards ---------- */
.breach-grid {
  display: grid;
  gap: 1.1rem;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  margin-bottom: 1.25rem;
}
.breach-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem 1.4rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  gap: .65rem;
}
.breach-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.breach-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  flex-wrap: wrap;
}
.breach-card__name {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -.01em;
}
.breach-badge {
  font-size: .72rem;
  font-weight: 700;
  padding: .25rem .65rem;
  border-radius: 999px;
  letter-spacing: .04em;
  text-transform: uppercase;
  flex-shrink: 0;
}
.breach-badge--red    { background: rgba(239,68,68,.12);  color: #dc2626; border: 1px solid rgba(239,68,68,.25); }
.breach-badge--orange { background: rgba(249,115,22,.12); color: #ea580c; border: 1px solid rgba(249,115,22,.25); }
.breach-badge--yellow { background: rgba(234,179,8,.12);  color: #ca8a04; border: 1px solid rgba(234,179,8,.25); }
.breach-card__desc {
  font-size: .875rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
  flex: 1;
}
.breach-card__fields {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem;
  margin-top: .1rem;
}
.breach-card__fields span {
  font-size: .72rem;
  font-weight: 600;
  padding: .2rem .55rem;
  background: var(--primary-glow);
  color: var(--primary);
  border-radius: 999px;
  letter-spacing: .03em;
}
.breach-grid__note {
  text-align: center;
  color: var(--muted);
  font-size: .875rem;
  margin: .25rem 0 0;
}

/* Old .hero kept for non-home contexts */
.hero {
  text-align: center;
  padding: 3rem 0 2rem;
}
.hero h1 {
  font-size: 2.2rem;
  margin-bottom: .5rem;
  background: linear-gradient(135deg, var(--primary), #8b5cf6);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p { max-width: 540px; margin: 0 auto 1.5rem; color: var(--muted); font-size: 1.05rem; }
.hero .btn { margin: 0 .35rem; }

/* ---------- Admin two-column layout ---------- */
.admin-layout {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  padding-top: 1.5rem;
  padding-bottom: 3rem;
  min-height: calc(100vh - 61px);
}

.admin-sidebar {
  width: 220px;
  flex-shrink: 0;
  position: sticky;
  top: 80px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem .5rem;
  box-shadow: var(--shadow-sm);
}

.admin-sidebar__label {
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  padding: .25rem .75rem .6rem;
}

.admin-sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: .1rem;
}

.admin-sidebar__link {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .55rem .75rem;
  border-radius: var(--radius-sm);
  color: var(--muted);
  text-decoration: none;
  font-size: .875rem;
  font-weight: 500;
  transition: all var(--transition);
  white-space: nowrap;
}
.admin-sidebar__link svg { flex-shrink: 0; opacity: .7; }
.admin-sidebar__link:hover {
  background: var(--primary-glow);
  color: var(--primary);
}
.admin-sidebar__link:hover svg { opacity: 1; }
.admin-sidebar__link.is-active {
  background: var(--primary-glow);
  color: var(--primary);
  font-weight: 600;
}
.admin-sidebar__link.is-active svg { opacity: 1; }

.admin-content {
  flex: 1;
  min-width: 0;
}

@media (max-width: 900px) {
  .admin-layout { flex-direction: column; gap: 1rem; }
  .admin-sidebar {
    width: 100%;
    position: static;
    padding: .5rem .25rem;
  }
  .admin-sidebar__nav { flex-direction: row; flex-wrap: wrap; }
  .admin-sidebar__link { font-size: .8rem; padding: .4rem .6rem; }
  .admin-sidebar__label { display: none; }
}

/* ---------- Animations ---------- */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
.animate-in { animation: fadeInUp .35s ease both; }
.card, .admin-tile, .dash-card, .package-card {
  animation: fadeInUp .4s ease both;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .container { padding: 0 1rem; }
  .dash-grid { grid-template-columns: 1fr; }
  .header-inner { height: auto; padding: .75rem 0; flex-wrap: wrap; }
  .hero h1 { font-size: 1.6rem; }
  .landing-hero { padding: 4rem 1rem 3rem; }
  .landing-hero__title { font-size: 2.2rem; }
  .landing-section { padding: 3rem 1rem; }
  .landing-step__arrow { display: none; }
  .landing-steps { gap: 1.5rem; }
}
@media (max-width: 480px) {
  .nav-links { gap: .25rem .5rem; font-size: .8rem; }
  .dash-card__value { font-size: 1.3rem; }
  .landing-hero__title { font-size: 1.75rem; }
  .btn-lg { width: 100%; }
  .landing-hero__cta { flex-direction: column; align-items: center; }
  .breach-grid { grid-template-columns: 1fr; }
  .landing-section--alt > *, .landing-section--alt > div { padding: 0 1rem; }
}
