:root {
  --bg: #FAF5EC;
  --bg-alt: #F1E9DD;
  --surface: #FFFFFF;
  --surface-raised: #FFFFFF;
  --border: #E8DFD3;
  --text: #211C18;
  --text-secondary: #6B5F53;
  --text-tertiary: #8A7C6E;
  --accent: #E8543D;
  --accent-pressed: #D14C37;
  --accent-soft: rgba(232, 84, 61, 0.1);
  --teal: #6FA89A;
  --teal-soft: rgba(111, 168, 154, 0.14);
  --gold: #C98A2E;
  --gold-soft: rgba(201, 138, 46, 0.14);
  --shadow-color: 33, 28, 24;
  --nav-bg: rgba(250, 245, 236, 0.78);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14161A;
    --bg-alt: #191C21;
    --surface: #1E2126;
    --surface-raised: #23262C;
    --border: #2C3038;
    --text: #F2F0EA;
    --text-secondary: #B8B3AA;
    --text-tertiary: #8A8781;
    --accent-soft: rgba(232, 84, 61, 0.16);
    --teal-soft: rgba(111, 168, 154, 0.18);
    --gold-soft: rgba(201, 138, 46, 0.18);
    --shadow-color: 0, 0, 0;
    --nav-bg: rgba(20, 22, 26, 0.72);
    color-scheme: dark;
  }
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

.wrap-narrow {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 24px;
}


.nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--nav-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

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

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.2px;
}

.brand img {
  width: 30px;
  height: 30px;
  border-radius: 8px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
}

.nav-links a { transition: color 0.15s ease; }
.nav-links a:hover { color: var(--text); }

.nav-cta {
  padding: 9px 18px;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  font-size: 13px;
  font-weight: 700;
  transition: transform 0.15s ease, opacity 0.15s ease;
}
.nav-cta:hover { opacity: 0.85; }

@media (max-width: 640px) {
  .nav-links-text { display: none; }
}


.hero-section {
  position: relative;
  padding: 88px 0 96px;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  top: -220px;
  right: -160px;
  width: 640px;
  height: 640px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-soft) 0%, rgba(232, 84, 61, 0) 70%);
  pointer-events: none;
  z-index: 0;
}

.hero-glow-2 {
  position: absolute;
  bottom: -260px;
  left: -200px;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--teal-soft) 0%, rgba(111, 168, 154, 0) 70%);
  pointer-events: none;
  z-index: 0;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 48px;
  }
  .hero-visual { order: -1; }
}

.hero-section h1 {
  font-size: clamp(34px, 5.4vw, 56px);
  font-weight: 800;
  letter-spacing: -1.4px;
  line-height: 1.06;
  margin: 0 0 20px;
  animation: fade-up 0.6s ease 0.05s both;
}

.hero-section h1 .accent-text { color: var(--accent); }

.hero-lede {
  font-size: clamp(16px, 1.6vw, 19px);
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 480px;
  animation: fade-up 0.6s ease 0.1s both;
}

@media (max-width: 900px) {
  .hero-lede { max-width: 520px; margin: 0 auto; }
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 32px;
  flex-wrap: wrap;
  animation: fade-up 0.6s ease 0.15s both;
}

@media (max-width: 900px) {
  .hero-actions { justify-content: center; }
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 700;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, opacity 0.15s ease;
  border: none;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: #FFFFFF;
  box-shadow: 0 10px 24px -8px rgba(232, 84, 61, 0.55);
}
.btn-primary:hover { background: var(--accent-pressed); transform: translateY(-1px); }

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover { background: var(--bg-alt); transform: translateY(-1px); }

.hero-trust {
  margin-top: 28px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text-tertiary);
  animation: fade-up 0.6s ease 0.2s both;
}

@media (max-width: 900px) {
  .hero-trust { justify-content: center; }
}

.hero-trust svg { width: 16px; height: 16px; color: var(--teal); flex-shrink: 0; }


.hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fade-in 0.7s ease 0.1s both;
}

.device-frame {
  position: relative;
  width: 260px;
  background: var(--surface-raised);
  border-radius: 32px;
  padding: 18px;
  box-shadow: 0 30px 60px -20px rgba(var(--shadow-color), 0.28), 0 2px 8px rgba(var(--shadow-color), 0.06);
  border: 1px solid var(--border);
}

.device-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 14px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--border);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-tertiary);
}
.device-search svg { width: 14px; height: 14px; color: var(--accent); flex-shrink: 0; }

.device-chips {
  display: flex;
  gap: 6px;
  margin-top: 12px;
}

.device-chip {
  padding: 6px 11px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  background: var(--accent-soft);
  color: var(--accent);
  white-space: nowrap;
}
.device-chip.alt { background: var(--teal-soft); color: var(--teal); }
.device-chip.neutral { background: var(--bg); color: var(--text-tertiary); border: 1px solid var(--border); }

.device-card {
  margin-top: 14px;
  padding: 12px;
  border-radius: 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.device-card-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.device-card-icon svg { width: 18px; height: 18px; color: #fff; }

.device-card-body { flex: 1; min-width: 0; }
.device-card-title { font-size: 12.5px; font-weight: 700; margin-bottom: 3px; }
.device-card-sub { font-size: 11px; color: var(--text-tertiary); line-height: 1.4; }

.device-card + .device-card { margin-top: 8px; }

.device-card.compact .device-card-icon { background: var(--teal); }

.float-badge {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 13px;
  border-radius: 14px;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  box-shadow: 0 14px 30px -12px rgba(var(--shadow-color), 0.25);
  font-size: 12px;
  font-weight: 700;
}

.float-badge svg { width: 15px; height: 15px; color: var(--gold); }

.float-badge-1 {
  top: 6%;
  right: -8%;
  animation: float-slow 5s ease-in-out infinite;
}

.float-badge-2 {
  bottom: 10%;
  left: -12%;
  animation: float-slow 5s ease-in-out infinite 1.2s;
}

@media (max-width: 520px) {
  .float-badge-1 { right: -2%; }
  .float-badge-2 { left: -2%; }
}

@keyframes float-slow {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@keyframes fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}


section { position: relative; }

.section-pad {
  padding: 80px 0;
}

@media (max-width: 640px) {
  .section-pad { padding: 56px 0; }
}

.section-head {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 48px;
}

.section-eyebrow {
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

.section-head h2 {
  font-size: clamp(26px, 3.4vw, 34px);
  font-weight: 800;
  letter-spacing: -0.7px;
  margin-bottom: 12px;
}

.section-head p {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.6;
}


.features {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

@media (max-width: 860px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .features-grid { grid-template-columns: 1fr; }
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 26px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 40px -20px rgba(var(--shadow-color), 0.22);
  border-color: transparent;
}

.feature-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  margin-bottom: 16px;
}

.feature-icon svg { width: 21px; height: 21px; color: var(--accent); }

.feature-card:nth-child(2n) .feature-icon { background: var(--teal-soft); }
.feature-card:nth-child(2n) .feature-icon svg { color: var(--teal); }

.feature-card h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.1px;
}

.feature-card p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
}


.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  counter-reset: step;
}

@media (max-width: 760px) {
  .steps { grid-template-columns: 1fr; gap: 36px; }
}

.step {
  position: relative;
  padding-left: 0;
}

.step-number {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--text);
  color: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 16px;
  margin-bottom: 18px;
}

.step h3 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 8px;
}

.step p {
  font-size: 14.5px;
  color: var(--text-secondary);
  line-height: 1.6;
}


.cta-band {
  border-radius: 28px;
  padding: 56px 40px;
  text-align: center;
  background: linear-gradient(135deg, var(--text) 0%, #372F28 100%);
  color: #F6F1E8;
  position: relative;
  overflow: hidden;
}

@media (prefers-color-scheme: dark) {
  .cta-band { background: linear-gradient(135deg, #23262C 0%, #14161A 100%); }
}

.cta-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 15% 20%, rgba(232, 84, 61, 0.35), transparent 45%),
              radial-gradient(circle at 85% 80%, rgba(111, 168, 154, 0.3), transparent 45%);
  pointer-events: none;
}

.cta-band > * { position: relative; z-index: 1; }

.cta-band h2 {
  font-size: clamp(24px, 3.2vw, 32px);
  font-weight: 800;
  letter-spacing: -0.6px;
  margin-bottom: 12px;
}

.cta-band p {
  font-size: 15.5px;
  color: rgba(246, 241, 232, 0.72);
  max-width: 440px;
  margin: 0 auto 28px;
  line-height: 1.6;
}

.cta-band .btn-primary {
  box-shadow: 0 10px 24px -8px rgba(0, 0, 0, 0.4);
}

@media (max-width: 640px) {
  .cta-band { padding: 44px 24px; }
}


footer.site {
  border-top: 1px solid var(--border);
  padding: 48px 0 36px;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.footer-brand p {
  font-size: 13.5px;
  color: var(--text-tertiary);
  margin-top: 10px;
  max-width: 260px;
  line-height: 1.6;
}

.footer-links {
  display: flex;
  gap: 56px;
  flex-wrap: wrap;
}

.footer-col h4 {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--text-tertiary);
  margin-bottom: 14px;
}

.footer-col a {
  display: block;
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 10px;
  transition: color 0.15s ease;
}
.footer-col a:hover { color: var(--accent); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 12.5px;
  color: var(--text-tertiary);
}


.doc-hero {
  padding: 56px 0 8px;
  text-align: center;
}

.back-link {
  margin-bottom: 28px;
}
.back-link svg { width: 16px; height: 16px; }

.doc h1 {
  font-size: clamp(28px, 4vw, 38px);
  font-weight: 800;
  letter-spacing: -0.7px;
  margin-bottom: 6px;
}

.doc .updated {
  font-size: 13px;
  color: var(--text-tertiary);
  margin-bottom: 8px;
}

.doc-body {
  max-width: 700px;
  margin: 0 auto;
  padding: 32px 0 96px;
}

.doc section {
  padding: 26px 0;
  border-bottom: 1px solid var(--border);
}
.doc section:last-child { border-bottom: none; }

.doc h2 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.2px;
}

.doc p, .doc li {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-secondary);
}

.doc ul {
  margin: 0;
  padding-left: 20px;
}

.doc li { margin-bottom: 10px; }
.doc a { color: var(--accent); font-weight: 600; }
.doc a:hover { text-decoration: underline; }


.auth-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  padding: 24px;
}

.auth-screen .hero-glow, .auth-screen .hero-glow-2 { opacity: 0.7; }

.auth-logo {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 24px;
}

.auth-logo img {
  width: 52px;
  height: 52px;
  border-radius: 15px;
  box-shadow: 0 14px 30px -12px rgba(var(--shadow-color), 0.35);
  margin-bottom: 12px;
}

.auth-logo span {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-tertiary);
  letter-spacing: 0.2px;
}

.auth-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 380px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 34px;
  box-shadow: 0 30px 60px -30px rgba(var(--shadow-color), 0.3);
}

.auth-card h1 {
  font-size: 21px;
  font-weight: 800;
  margin-bottom: 6px;
  letter-spacing: -0.3px;
}

.auth-card p.hint {
  font-size: 13.5px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 24px;
}

.field { margin-bottom: 16px; }

.field label {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.field input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14.5px;
  font-family: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

.form-error {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  margin: -4px 0 14px;
  min-height: 1em;
}
.form-error.success { color: var(--teal); }
.form-error:empty { margin: 0; }
.form-error svg { width: 15px; height: 15px; flex-shrink: 0; }

.admin-app { display: flex; min-height: 100vh; align-items: flex-start; }

.admin-sidebar {
  width: 260px;
  flex-shrink: 0;
  min-height: 100vh;
  position: sticky;
  top: 0;
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 22px 16px;
}

.admin-brand-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 8px 20px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.admin-brand-row img { width: 32px; height: 32px; border-radius: 9px; }
.admin-brand-name { font-size: 15px; font-weight: 800; letter-spacing: -0.2px; line-height: 1.2; }

.admin-tag {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--accent);
}

.admin-side-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 6px;
}

.tab-btn {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  background: none;
  border: none;
  border-radius: 12px;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-secondary);
  padding: 10px 12px;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s ease, color 0.15s ease;
}
.tab-btn svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--text-tertiary); transition: color 0.15s ease; }
.tab-btn:hover { background: var(--bg-alt); color: var(--text); }
.tab-btn.active { background: var(--accent-soft); color: var(--accent); }
.tab-btn.active svg { color: var(--accent); }

.admin-side-footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.admin-user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 8px 12px;
}

.admin-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 12.5px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.admin-user-name { font-size: 13px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-user-role { font-size: 11.5px; color: var(--text-tertiary); }

.admin-main {
  flex: 1;
  min-width: 0;
  padding: 40px 44px 80px;
}

.panel { display: none; }
.panel.active { display: block; animation: fade-in 0.3s ease both; }

.panel-head { margin-bottom: 26px; }
.panel-head h1 { font-size: 24px; font-weight: 800; letter-spacing: -0.5px; }
.panel-head p { font-size: 14px; color: var(--text-secondary); margin-top: 4px; }

.row-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 20px 22px;
  margin-bottom: 14px;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
  animation: fade-up 0.35s ease both;
}
.row-card:hover { box-shadow: 0 16px 32px -22px rgba(var(--shadow-color), 0.35); }

.row-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.row-thumb {
  width: 60px;
  height: 60px;
  border-radius: 14px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--bg-alt);
}

.row-thumb-placeholder {
  width: 60px;
  height: 60px;
  border-radius: 14px;
  background: var(--bg-alt);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text-tertiary);
}
.row-thumb-placeholder svg { width: 24px; height: 24px; }

.row-avatar {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: var(--teal-soft);
  color: var(--teal);
  font-size: 15px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.row-title { font-size: 15.5px; font-weight: 800; letter-spacing: -0.1px; display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.row-sub { font-size: 13.5px; color: var(--text-secondary); margin-top: 4px; line-height: 1.55; }

.reason-box {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  background: var(--accent-soft);
  color: var(--accent-pressed);
  border-radius: 12px;
  padding: 9px 12px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  margin-top: 10px;
}
.reason-box svg { width: 15px; height: 15px; flex-shrink: 0; margin-top: 2px; }

.meta-strip { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 12px; }

.meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  color: var(--text-tertiary);
  font-weight: 600;
}
.meta-chip svg { width: 13px; height: 13px; flex-shrink: 0; }
.meta-chip.link { color: var(--accent); }
.meta-chip.link:hover { text-decoration: underline; }
.meta-chip .dot { width: 6px; height: 6px; border-radius: 999px; background: var(--teal); flex-shrink: 0; }
.meta-chip .dot.stale { background: var(--text-tertiary); }

.row-actions { display: flex; gap: 8px; flex-shrink: 0; flex-wrap: wrap; }

.btn-sm {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  font-size: 12.5px;
  border-radius: 999px;
  font-weight: 700;
  font-family: inherit;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}
.btn-sm svg { width: 14px; height: 14px; flex-shrink: 0; }
.btn-sm:hover { background: var(--bg-alt); transform: translateY(-1px); }
.btn-sm.danger { color: var(--accent); border-color: var(--accent-soft); }
.btn-sm.danger:hover { background: var(--accent-soft); }
.btn-sm.gold { color: var(--gold); border-color: var(--gold-soft); }
.btn-sm.gold:hover { background: var(--gold-soft); }
.btn-sm.teal { color: var(--teal); border-color: var(--teal-soft); }
.btn-sm.teal:hover { background: var(--teal-soft); }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.2px;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--bg-alt);
  color: var(--text-tertiary);
  text-transform: uppercase;
}
.badge svg { width: 11px; height: 11px; }
.badge.premium { background: var(--gold-soft); color: var(--gold); }
.badge.admin { background: var(--teal-soft); color: var(--teal); }
.badge.banned { background: var(--accent-soft); color: var(--accent); }

.search-row { display: flex; gap: 10px; margin-bottom: 24px; max-width: 440px; }
.search-row-input { position: relative; flex: 1; }
.search-row-input svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--text-tertiary); }
.search-row-input input {
  width: 100%;
  padding: 12px 14px 12px 38px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14.5px;
  font-family: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.search-row-input input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

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

.stat-tile {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 20px 22px;
}

.stat-icon-wrap {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: 14px;
}
.stat-icon-wrap svg { width: 19px; height: 19px; }
.stat-icon-wrap.teal { background: var(--teal-soft); color: var(--teal); }
.stat-icon-wrap.gold { background: var(--gold-soft); color: var(--gold); }

.stat-value { font-size: 28px; font-weight: 800; letter-spacing: -0.6px; }
.stat-label { font-size: 12.5px; color: var(--text-secondary); margin-top: 4px; font-weight: 600; }

.empty-note {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 10px;
  color: var(--text-tertiary);
  font-size: 14px;
  padding: 48px 20px;
  border: 1px dashed var(--border);
  border-radius: 18px;
}
.empty-note svg { width: 26px; height: 26px; color: var(--text-tertiary); }

.spinner {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  animation: spin 0.7s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.toast-container {
  position: fixed;
  bottom: 22px;
  right: 22px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-end;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 16px;
  box-shadow: 0 20px 40px -18px rgba(var(--shadow-color), 0.4);
  font-size: 13.5px;
  font-weight: 700;
  max-width: 340px;
  animation: toast-in 0.25s ease both;
  pointer-events: auto;
}
.toast svg { width: 17px; height: 17px; flex-shrink: 0; }
.toast.success svg { color: var(--teal); }
.toast.error svg { color: var(--accent); }
.toast.leaving { animation: toast-out 0.2s ease forwards; }

@keyframes toast-in {
  from { opacity: 0; transform: translateY(10px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes toast-out {
  to { opacity: 0; transform: translateY(6px) scale(0.97); }
}

@media (max-width: 860px) {
  .admin-app { flex-direction: column; }
  .admin-sidebar {
    width: 100%;
    height: auto;
    min-height: 0;
    position: static;
    flex-direction: row;
    align-items: center;
    padding: 14px 16px;
    gap: 16px;
    overflow-x: auto;
  }
  .admin-brand-row { border-bottom: none; padding: 0; margin: 0; flex-shrink: 0; }
  .admin-side-nav { flex-direction: row; margin-top: 0; }
  .tab-btn { white-space: nowrap; }
  .admin-side-footer { margin-top: 0; padding-top: 0; border-top: none; margin-left: auto; flex-shrink: 0; }
  .admin-user-chip { padding: 0; }
  .admin-main { padding: 28px 20px 60px; }
}
