:root {
  --bg: #070708;
  --surface: #0d0d10;
  --surface-raised: #131318;
  --surface-hover: #191920;
  --surface-active: #202029;
  --border-soft: rgba(255, 255, 255, 0.075);
  --border: rgba(255, 255, 255, 0.13);
  --border-hover: rgba(255, 255, 255, 0.28);
  --text-1: #f3f3f5;
  --text-2: #9b9ba4;
  --text-3: #63636c;
  --accent: #ffffff;
  --accent-muted: rgba(255, 255, 255, 0.12);
  --green: #34d399;
  --green-soft: rgba(52, 211, 153, 0.12);
  --violet: #a78bfa;
  --violet-soft: rgba(167, 139, 250, 0.14);
  --amber: #fbbf24;
  --amber-soft: rgba(251, 191, 36, 0.12);
  --red: #f87171;
  --red-soft: rgba(248, 113, 113, 0.12);

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --ease: cubic-bezier(0.23, 1, 0.32, 1);

  --font-sans: 'Geist', 'Pretendard Variable', 'Pretendard', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'Geist Mono', 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

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

html {
  background-color: var(--bg);
  color: var(--text-1);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--bg);
  background-image:
    radial-gradient(ellipse 75% 42% at 50% -8%, rgba(255, 255, 255, 0.045), transparent 68%),
    linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
  background-size: 100% 100%, 48px 48px, 48px 48px;
  color: var(--text-1);
  overflow-x: hidden;
}

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

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
}

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

.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

/* Subtle Floating Decals (kova.page signature) */
.decals-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  overflow: hidden;
}

.decal-item {
  position: absolute;
  opacity: 0.72;
  filter: drop-shadow(0 12px 24px rgba(0, 0, 0, 0.7));
  transition: opacity 0.25s var(--ease);
}

.decal-item.pos-top-right {
  top: 24px;
  right: 22px;
  width: 72px;
}

.decal-item.pos-mid-right {
  top: 42%;
  right: 26px;
  width: 68px;
}

.decal-item.pos-bottom-left {
  bottom: 32px;
  left: 20px;
  width: 64px;
}

.decal-item.pos-top-left {
  top: 24px;
  left: 20px;
  width: 64px;
}

@media (max-width: 1280px) {
  .decals-layer {
    display: none;
  }
}

/* App Shell Layout: Top Sticky Architectural Command Bar + Centered Dossier Stream */
.app-shell {
  position: relative;
  z-index: 5;
  max-width: 960px;
  margin: 0 auto;
  padding: 20px 24px 96px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.mobile-topbar {
  display: none;
}

.kbd-pill {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-3);
  padding: 1px 5px;
  border-radius: 4px;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.03);
}

/* Top Sticky Command Bar */
.top-dock {
  width: 100%;
  position: sticky;
  top: 14px;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 12px;
  background: rgba(13, 13, 16, 0.84);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 12px 32px rgba(0, 0, 0, 0.45);
  flex-wrap: nowrap;
}

.top-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 2px 4px 2px 2px;
  border-radius: 8px;
  flex-shrink: 0;
  transition: opacity 0.14s var(--ease);
}

.top-brand:hover {
  opacity: 0.85;
}

.top-brand-avatar {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  object-fit: cover;
  border: 1px solid var(--border);
  background: var(--surface-raised);
  flex-shrink: 0;
}

.top-brand-name {
  font-size: 13.5px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-1);
}

.top-brand-tag {
  display: none;
}

.top-dock.admin-open .top-search-kbd {
  display: none;
}

.top-dock.admin-open .top-bgm-title {
  max-width: 52px;
}

.top-nav-tabs {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border-radius: 9px;
  border: 1px solid var(--border-soft);
  background: rgba(0, 0, 0, 0.35);
  flex-shrink: 0;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.top-nav-tabs::-webkit-scrollbar {
  display: none;
}

.top-nav-tab {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12.5px;
  color: var(--text-2);
  white-space: nowrap;
  transition: color 0.14s var(--ease), background-color 0.14s var(--ease);
}

.top-nav-tab:hover {
  color: var(--text-1);
  background: rgba(255, 255, 255, 0.04);
}

.top-nav-tab.active {
  color: #09090b;
  background: #f3f3f5;
  font-weight: 600;
}

.nav-count {
  font-family: var(--font-mono);
  font-size: 10.5px;
  opacity: 0.72;
}

.top-utilities {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  flex-wrap: nowrap;
}

.top-icon-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 29px;
  padding: 0 8px;
  border-radius: 7px;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.025);
  color: var(--text-2);
  font-size: 12px;
  white-space: nowrap;
  transition: all 0.14s var(--ease);
}

.top-icon-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-1);
  background: var(--surface-hover);
}

.top-icon-btn.lock-trigger {
  height: 29px;
  padding: 0 9px;
  gap: 5px;
  color: var(--text-3);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.05em;
}

.top-icon-btn.lock-trigger:hover {
  color: var(--text-1);
  border-color: var(--border-hover);
}

.top-admin-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 29px;
  padding: 0 9px;
  border-radius: 7px;
  border: 1px solid var(--border);
  background: var(--surface-raised);
  color: var(--text-2);
  font-size: 11.5px;
  font-weight: 500;
  white-space: nowrap;
  transition: all 0.14s var(--ease);
}

.top-admin-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-1);
  background: var(--surface-hover);
}

.top-admin-btn.primary {
  background: #f3f3f5;
  border-color: #f3f3f5;
  color: #09090b;
}

.top-admin-btn.primary:hover {
  background: #ffffff;
}

.top-admin-btn.editing-on {
  border-color: rgba(52, 211, 153, 0.45);
  background: rgba(52, 211, 153, 0.1);
  color: var(--green);
}

/* Compact Top BGM Pill */
.top-bgm-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 29px;
  padding: 0 7px;
  border-radius: 7px;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.025);
}

.bgm-play-btn {
  width: 19px;
  height: 19px;
  border-radius: 5px;
  border: 1px solid var(--border);
  background: var(--surface-raised);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-1);
  flex-shrink: 0;
  transition: background 0.14s var(--ease);
}

.bgm-play-btn:hover {
  background: var(--surface-hover);
}

.top-bgm-title {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-2);
  max-width: 72px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bgm-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 36px;
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  outline: none;
}

.bgm-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--text-1);
  cursor: pointer;
}

@media (max-width: 980px) {
  .top-brand-tag {
    display: none;
  }
}

@media (max-width: 860px) {
  .top-dock {
    padding: 8px 12px;
    gap: 8px;
    flex-wrap: wrap;
  }

  .top-utilities {
    flex-wrap: wrap;
  }

  .top-nav-tabs {
    order: 3;
    width: 100%;
  }

  .top-bgm-title,
  .bgm-slider,
  .top-search-kbd {
    display: none;
  }
}

/* Main Content Area */
.main-stream {
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

/* Signature Hero Dossier Card */
.dossier-card {
  position: relative;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.11);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.038) 0%, rgba(255, 255, 255, 0) 42%),
    var(--surface);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 24px 60px rgba(0, 0, 0, 0.55);
  overflow: hidden;
}

.dossier-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 18px;
  border-bottom: 1px solid var(--border-soft);
  background: rgba(0, 0, 0, 0.25);
}

.dossier-index {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  color: var(--text-3);
}

.hero-banner-logo {
  max-height: 40px;
  max-width: 210px;
  object-fit: contain;
  mix-blend-mode: lighten;
  filter: contrast(1.08) brightness(1.06);
  user-select: none;
}

.dossier-origin {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-3);
}

.dossier-body {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 22px;
  padding: 20px 20px 18px;
  align-items: center;
}

@media (max-width: 740px) {
  .dossier-body {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .dossier-origin {
    display: none;
  }
}

.dossier-identity {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.dossier-avatar-row {
  display: flex;
  align-items: center;
  gap: 15px;
}

.dossier-avatar {
  width: 76px;
  height: 76px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: #09090b;
  flex-shrink: 0;
}

.dossier-title-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}

.dossier-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.dossier-name {
  margin: 0;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--text-1);
}

.rank-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 8px;
  border-radius: 6px;
  border: 1px solid var(--violet-soft);
  background: rgba(167, 139, 250, 0.08);
  color: #c4b5fd;
  font-size: 11px;
  font-weight: 500;
}

.rank-pill img {
  width: 13px;
  height: 13px;
  object-fit: contain;
}

.dossier-handle-bio {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--text-2);
}

.dossier-socials {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.dossier-social-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 7px;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.025);
  color: var(--text-2);
  font-size: 12px;
  transition: all 0.14s var(--ease);
}

.dossier-social-pill:hover {
  border-color: var(--border-hover);
  color: var(--text-1);
  background: var(--surface-hover);
}

.dossier-social-pill svg {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

/* 2x2 Telemetry Grid inside Dossier Card */
.dossier-telemetry-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border-soft);
  background: var(--border-soft);
}

.telemetry-cell {
  background: var(--surface-raised);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.telemetry-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}

.telemetry-value {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Dossier Footer Strip (Quick Copy + Inline Search) */
.dossier-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 18px;
  border-top: 1px solid var(--border-soft);
  background: rgba(0, 0, 0, 0.25);
  flex-wrap: wrap;
}

/* Category Jump Strip on Home */
.home-jump-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 780px) {
  .home-jump-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.jump-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  text-align: left;
  transition: border-color 0.15s var(--ease), background-color 0.15s var(--ease);
}

.jump-card:hover {
  border-color: var(--border-hover);
  background: var(--surface-raised);
}

.jump-card-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
}

.jump-card-sub {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-3);
  margin-top: 2px;
}

.jump-card-arrow {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-3);
}

.jump-card:hover .jump-card-arrow {
  color: var(--text-1);
}

/* d0cc.gg-inspired Quick Copy Action Strip + Search Bar */
.toolbar-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.quick-copy-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.copy-chip-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border-radius: 7px;
  border: 1px solid var(--border-soft);
  background: var(--surface);
  color: var(--text-2);
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.02em;
  transition: all 0.14s var(--ease);
}

.copy-chip-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-1);
  background: var(--surface-raised);
}

.copy-chip-btn.copied {
  border-color: rgba(52, 211, 153, 0.45);
  background: var(--green-soft);
  color: var(--green);
}

.inline-search-box {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 240px;
}

.inline-search-box svg {
  position: absolute;
  left: 10px;
  width: 14px;
  height: 14px;
  color: var(--text-3);
  pointer-events: none;
}

.inline-search-input {
  width: 100%;
  padding: 6px 32px 6px 30px;
  border-radius: 7px;
  border: 1px solid var(--border-soft);
  background: var(--surface);
  color: var(--text-1);
  font-family: var(--font-mono);
  font-size: 12px;
  outline: none;
  transition: border-color 0.14s var(--ease), background 0.14s var(--ease);
}

.inline-search-input:focus {
  border-color: var(--border-hover);
  background: var(--surface-raised);
}

.inline-search-clear {
  position: absolute;
  right: 8px;
  color: var(--text-3);
  font-size: 12px;
  padding: 2px 4px;
  display: none;
}

.inline-search-clear.visible {
  display: block;
}

.search-banner {
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--surface-raised);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--text-2);
}

.search-highlight {
  background: rgba(255, 255, 255, 0.14);
  color: var(--text-1);
  border-radius: 3px;
  padding: 0 2px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.28);
}

/* Section / Block Shell */
.section-header-bar {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.section-page-title {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0;
}

.section-page-sub {
  font-size: 12.5px;
  color: var(--text-3);
  margin: 2px 0 0;
}

.block-wrapper {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
}

.block-wrapper.edit-highlight {
  padding: 14px;
  border-radius: var(--radius-lg);
  border: 1px dashed rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.015);
}

.block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.block-title-group {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}

.block-title {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-2);
}

.block-subtitle {
  font-size: 12px;
  color: var(--text-3);
}

.block-edit-bar {
  display: flex;
  align-items: center;
  gap: 5px;
}

.edit-pill-btn {
  padding: 4px 8px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--surface-raised);
  color: var(--text-2);
  font-size: 11.5px;
  transition: all 0.14s var(--ease);
}

.edit-pill-btn:hover {
  color: var(--text-1);
  border-color: var(--border-hover);
  background: var(--surface-hover);
}

.edit-pill-btn.danger:hover {
  color: var(--red);
  border-color: rgba(248, 113, 113, 0.4);
  background: var(--red-soft);
}

/* 1. Gear Showcase Grid (kova.page style) */
.gear-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 960px) {
  .gear-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .gear-grid {
    grid-template-columns: 1fr;
  }
}

.gear-card {
  position: relative;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 205px;
  transition: border-color 0.16s var(--ease), background-color 0.16s var(--ease);
}

.gear-card:hover {
  border-color: var(--border-hover);
  background: var(--surface-raised);
}

.gear-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 11.5px;
}

.status-tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-2);
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-3);
}

.status-tag.in-use .status-dot {
  background: var(--green);
}

.status-tag.in-rotation .status-dot {
  background: var(--violet);
}

.status-tag.incoming .status-dot,
.status-tag.wishlist .status-dot {
  background: var(--amber);
}

.gear-rating {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-2);
}

.gear-image-stage {
  height: 108px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 8px 0;
  position: relative;
}

.gear-image-stage img {
  max-height: 98px;
  max-width: 86%;
  object-fit: contain;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.55));
  transition: transform 0.2s var(--ease);
}

.gear-card:hover .gear-image-stage img {
  transform: scale(1.03);
}

.gear-card-bottom {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 8px;
}

.gear-cat-label {
  font-size: 11px;
  color: var(--text-3);
  margin-bottom: 2px;
}

.gear-brand {
  font-size: 12px;
  color: var(--text-2);
  line-height: 1.25;
}

.gear-model {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
  letter-spacing: -0.015em;
  line-height: 1.25;
}

.gear-note {
  font-size: 11px;
  color: var(--text-3);
  margin-top: 3px;
}

.rotation-controls {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.rot-btn {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  border: 1px solid var(--border-soft);
  background: var(--surface-raised);
  color: var(--text-2);
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.14s var(--ease);
}

.rot-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-1);
}

.rot-count {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-3);
  padding: 0 2px;
}

/* 2. Key-Value Settings Grid (d0cc.gg high-density table) */
.kv-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  overflow: hidden;
}

.kv-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.kv-grid.cols-1 {
  grid-template-columns: 1fr;
}

@media (max-width: 720px) {
  .kv-grid {
    grid-template-columns: 1fr;
  }
}

.kv-cell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-soft);
  border-right: 1px solid var(--border-soft);
  transition: background-color 0.12s var(--ease);
}

.kv-cell:hover {
  background: rgba(255, 255, 255, 0.02);
}

.kv-grid.cols-1 .kv-cell {
  border-right: none;
}

@media (min-width: 721px) {
  .kv-grid:not(.cols-1) .kv-cell:nth-child(2n) {
    border-right: none;
  }
}

@media (max-width: 720px) {
  .kv-cell {
    border-right: none;
  }
}

.kv-key {
  font-family: var(--font-mono);
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-2);
  flex-shrink: 0;
}

.kv-val {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-1);
  text-align: right;
  word-break: break-word;
}

/* 3. Setup Split (aech.wtf/setup In use + PC) */
.setup-split-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

@media (max-width: 780px) {
  .setup-split-grid {
    grid-template-columns: 1fr;
  }
}

.setup-panel {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  overflow: hidden;
}

.setup-panel-head {
  padding: 14px 16px 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
  border-bottom: 1px solid var(--border-soft);
}

.setup-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--border-soft);
}

.setup-row:last-child {
  border-bottom: none;
}

.setup-row-key {
  font-size: 12.5px;
  color: var(--text-3);
  flex-shrink: 0;
}

.setup-row-right {
  text-align: right;
}

.setup-row-val {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-1);
}

.setup-row-note {
  font-size: 11.5px;
  color: var(--text-3);
  margin-top: 2px;
}

/* 4. Collection Accordion (aech.wtf/setup Collection) */
.collection-box {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  overflow: hidden;
}

.collection-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-soft);
  flex-wrap: wrap;
}

.collection-search {
  padding: 5px 10px;
  border-radius: 6px;
  border: 1px solid var(--border-soft);
  background: var(--bg);
  color: var(--text-1);
  font-size: 12px;
  min-width: 210px;
  outline: none;
}

.collection-search:focus {
  border-color: var(--border-hover);
}

.collection-group {
  border-bottom: 1px solid var(--border-soft);
}

.collection-group:last-child {
  border-bottom: none;
}

.collection-group-trigger {
  width: 100%;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  transition: background-color 0.14s var(--ease);
}

.collection-group-trigger:hover {
  background: rgba(255, 255, 255, 0.025);
}

.collection-group-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.collection-chevron {
  font-size: 11px;
  color: var(--text-3);
  transition: transform 0.16s var(--ease);
}

.collection-group.open .collection-chevron {
  transform: rotate(90deg);
}

.collection-group-name {
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-1);
}

.collection-group-count {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-3);
}

.collection-group-highlight {
  font-size: 12px;
  color: var(--text-3);
}

.collection-items-grid {
  display: none;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 2px 16px 16px;
}

.collection-group.open .collection-items-grid {
  display: grid;
}

@media (max-width: 960px) {
  .collection-items-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .collection-items-grid {
    grid-template-columns: 1fr;
  }
}

.col-item-card {
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  background: var(--surface-raised);
  padding: 10px 11px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: border-color 0.14s var(--ease), background 0.14s var(--ease);
}

.col-item-card:hover {
  border-color: var(--border);
  background: var(--surface-hover);
}

.col-item-thumb {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.col-item-thumb img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.col-item-info {
  min-width: 0;
  flex: 1;
}

.col-item-title {
  font-size: 12.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.col-item-brand {
  color: var(--text-2);
  margin-right: 4px;
}

.col-item-model {
  color: var(--text-1);
  font-weight: 500;
}

.col-item-sub {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--text-3);
  margin-top: 2px;
}

.col-status-pill {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 0 5px;
  border-radius: 4px;
  border: 1px solid var(--border-soft);
  color: var(--text-2);
}

.col-status-pill.in-use {
  border-color: rgba(52, 211, 153, 0.35);
  color: var(--green);
}

.col-status-pill.in-rotation {
  border-color: rgba(167, 139, 250, 0.35);
  color: var(--violet);
}

.col-status-pill.sold {
  opacity: 0.65;
}

/* 5. Config Command Block (aech.wtf/configs + d0cc.gg) */
.command-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  overflow: hidden;
}

.command-pre {
  margin: 0;
  padding: 14px 16px;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.65;
  color: var(--text-1);
  background: #0c0c0e;
  overflow-x: auto;
  border-top: 1px solid var(--border-soft);
  white-space: pre-wrap;
  word-break: break-all;
}

.command-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 16px;
  border-top: 1px solid var(--border-soft);
  background: var(--surface);
}

.btn-subtle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--surface-raised);
  color: var(--text-1);
  font-size: 12px;
  font-weight: 500;
  transition: all 0.14s var(--ease);
}

.btn-subtle:hover {
  border-color: var(--border-hover);
  background: var(--surface-hover);
}

.btn-subtle.copied {
  border-color: rgba(52, 211, 153, 0.45);
  color: var(--green);
  background: var(--green-soft);
}

/* 6. Aimgroups & Games & Benchmarks */
.aimgroups-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 640px) {
  .aimgroups-grid {
    grid-template-columns: 1fr;
  }
}

.aimgroup-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  transition: border-color 0.15s var(--ease), background 0.15s var(--ease);
}

.aimgroup-card:hover {
  border-color: var(--border-hover);
  background: var(--surface-raised);
}

.aimgroup-left {
  display: flex;
  align-items: center;
  gap: 11px;
}

.aimgroup-avatar {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid var(--border-soft);
}

.aimgroup-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: 5px;
}

.aimgroup-members {
  font-size: 12px;
  color: var(--text-3);
}

.aimgroup-role {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: #f87171;
}

.benchmark-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 720px) {
  .benchmark-grid {
    grid-template-columns: 1fr;
  }
}

.benchmark-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  padding: 13px 15px;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: border-color 0.15s var(--ease), background 0.15s var(--ease);
}

.benchmark-card:hover {
  border-color: var(--border-hover);
  background: var(--surface-raised);
}

.benchmark-rank-icon {
  width: 34px;
  height: 34px;
  object-fit: contain;
  flex-shrink: 0;
}

.benchmark-score-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.benchmark-score {
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-1);
}

.benchmark-rank-label {
  font-size: 11.5px;
  color: var(--violet);
  font-weight: 500;
}

.benchmark-scenario {
  font-size: 12.5px;
  color: var(--text-2);
  margin-top: 2px;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 760px) {
  .games-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 500px) {
  .games-grid {
    grid-template-columns: 1fr;
  }
}

.game-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.game-card-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.game-icon {
  width: 24px;
  height: 24px;
  border-radius: 5px;
  object-fit: contain;
}

.game-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-1);
}

.game-rank {
  font-size: 11.5px;
  color: var(--text-3);
}

.game-rank-badge {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

/* 7. Reviews, Clips & Comments */
.review-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: border-color 0.15s var(--ease), background 0.15s var(--ease);
}

.review-card:hover {
  border-color: var(--border-hover);
  background: var(--surface-raised);
}

.review-thumb {
  width: 84px;
  height: 64px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid var(--border-soft);
  flex-shrink: 0;
}

.review-product {
  font-size: 12px;
  color: var(--text-3);
}

.review-title {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-1);
  margin: 2px 0;
}

.review-meta {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-2);
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 680px) {
  .media-grid {
    grid-template-columns: 1fr;
  }
}

.clip-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s var(--ease), transform 0.15s var(--ease);
}

.clip-card:hover {
  border-color: var(--border-hover);
}

.clip-thumb-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #0d0d0f;
  overflow: hidden;
}

.clip-thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.86;
  transition: opacity 0.2s var(--ease), transform 0.25s var(--ease);
}

.clip-card:hover .clip-thumb-wrap img {
  opacity: 1;
  transform: scale(1.02);
}

.clip-play-pill {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 38px;
  height: 38px;
  border-radius: 999px;
  background: rgba(9, 9, 9, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
}

.clip-info {
  padding: 10px 13px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.clip-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-1);
}

.clip-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-3);
}

.comments-box {
  border-radius: var(--radius-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
  overflow: hidden;
}

.comment-row {
  padding: 11px 15px;
  border-bottom: 1px solid var(--border-soft);
  display: flex;
  align-items: center;
  gap: 11px;
}

.comment-row:last-child {
  border-bottom: none;
}

.comment-avatar {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  object-fit: cover;
  border: 1px solid var(--border-soft);
  background: var(--surface-raised);
  flex-shrink: 0;
}

.comment-author {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-1);
}

.comment-time {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-3);
  margin-left: 6px;
}

.comment-text {
  font-size: 13px;
  color: var(--text-2);
  margin-top: 1px;
}

/* 8. Aimer License ID Card (kova.page/maental3/card) */
.aimer-card-stage {
  display: flex;
  justify-content: center;
  padding: 16px 0;
}

.aimer-license-card {
  width: 100%;
  max-width: 580px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background:
    radial-gradient(80% 70% at 50% 0%, rgba(255, 255, 255, 0.06), transparent 65%),
    linear-gradient(155deg, #141418 0%, #0b0b0e 100%);
  padding: 20px 22px 16px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.65);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.license-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.license-tag {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-2);
}

.license-center-logo {
  max-height: 52px;
  object-fit: contain;
  margin-top: -4px;
  mix-blend-mode: lighten;
  filter: contrast(1.06);
}

.license-brand {
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.04em;
  color: var(--text-1);
}

.license-brand span {
  color: #ef4444;
}

.license-main {
  display: grid;
  grid-template-columns: 128px 1fr;
  gap: 20px;
  align-items: center;
}

@media (max-width: 540px) {
  .license-main {
    grid-template-columns: 1fr;
  }
}

.license-photo-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.license-photo {
  width: 118px;
  height: 118px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid var(--border);
  background: #09090b;
}

.license-signature {
  font-family: Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: 19px;
  color: var(--text-2);
  letter-spacing: -0.02em;
}

.license-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
}

.license-field-label {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 3px;
}

.license-field-value {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
  display: flex;
  align-items: center;
  gap: 6px;
}

.license-field-value img {
  width: 15px;
  height: 15px;
  border-radius: 3px;
  object-fit: contain;
}

.license-gear-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--border-soft);
}

@media (max-width: 560px) {
  .license-gear-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.license-gear-slot {
  border-right: 1px solid var(--border-soft);
  padding-right: 8px;
}

.license-gear-slot:last-child {
  border-right: none;
}

.license-gear-cat {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}

.license-gear-model {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-1);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.license-mrz {
  padding-top: 10px;
  border-top: 1px solid var(--border-soft);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.2em;
  line-height: 1.55;
  color: var(--text-3);
  word-break: break-all;
  user-select: all;
}

/* Inline Add Block Bar */
.inline-add-block-bar {
  display: flex;
  justify-content: center;
  padding: 12px 0;
}

.inline-add-block-btn {
  padding: 10px 18px;
  border-radius: 9px;
  border: 1px dashed var(--border);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-2);
  font-size: 13px;
  transition: all 0.15s var(--ease);
}

.inline-add-block-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-1);
  background: var(--surface-raised);
}

/* Command Palette Modal (Ctrl+K) */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop.open {
  display: flex;
}

.cmd-palette {
  width: 100%;
  max-width: 580px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #121215;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.75);
  overflow: hidden;
}

.cmd-input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-soft);
}

.cmd-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-1);
  font-size: 14px;
}

.cmd-results {
  max-height: 360px;
  overflow-y: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.cmd-result-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 12px;
  border-radius: 8px;
  text-align: left;
  width: 100%;
  transition: background 0.12s var(--ease);
}

.cmd-result-item:hover {
  background: var(--surface-hover);
}

/* Admin Entry Keycode Modal */
.keycode-modal {
  width: 100%;
  max-width: 400px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: #101014;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 24px 80px rgba(0, 0, 0, 0.85);
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.keycode-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.keycode-badge {
  font-size: 10.5px;
  letter-spacing: 0.14em;
  color: var(--text-3);
}

.keycode-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-1);
}

.keycode-desc {
  margin: 0;
  font-size: 12.5px;
  color: var(--text-2);
}

.keycode-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 2px;
}

.keycode-input-wrap {
  display: flex;
  align-items: center;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #08080a;
  padding-right: 6px;
  transition: border-color 0.14s var(--ease);
}

.keycode-input-wrap:focus-within {
  border-color: var(--border-hover);
}

.keycode-input {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  background: transparent;
  border: none;
  outline: none;
  font-size: 13.5px;
  color: var(--text-1);
}

.keycode-vis-btn {
  padding: 4px 8px;
  border-radius: 5px;
  font-size: 11px;
  color: var(--text-3);
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.03);
}

.keycode-vis-btn:hover {
  color: var(--text-1);
  border-color: var(--border);
}

.keycode-error {
  font-size: 12px;
  color: var(--red);
  padding: 7px 10px;
  border-radius: 6px;
  border: 1px solid rgba(248, 113, 113, 0.35);
  background: var(--red-soft);
}

.keycode-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 2px;
}

/* Visual Dashboard Studio Modal (Zero-HTML Korean Builder) */
.dash-modal {
  width: 100%;
  max-width: 980px;
  height: min(88vh, 840px);
  border-radius: 14px;
  border: 1px solid var(--border);
  background: #111114;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.85);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dash-header {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border-soft);
  background: #141418;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.dash-title-wrap {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.dash-title {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--text-1);
}

.dash-subtitle {
  font-size: 12px;
  color: var(--text-3);
}

.dash-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.dash-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 10px 20px 0;
  border-bottom: 1px solid var(--border-soft);
  background: #131317;
  overflow-x: auto;
}

.dash-tab {
  padding: 8px 14px 10px;
  font-size: 13px;
  color: var(--text-2);
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  transition: color 0.14s var(--ease), border-color 0.14s var(--ease);
}

.dash-tab:hover {
  color: var(--text-1);
}

.dash-tab.active {
  color: var(--text-1);
  font-weight: 500;
  border-bottom-color: var(--text-1);
}

.dash-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.dash-card {
  border-radius: 10px;
  border: 1px solid var(--border-soft);
  background: #16161a;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.dash-card-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.dash-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.dash-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 720px) {
  .dash-grid-2,
  .dash-grid-3 {
    grid-template-columns: 1fr;
  }
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.form-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-2);
}

.form-hint {
  font-size: 11px;
  color: var(--text-3);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 8px 10px;
  border-radius: 7px;
  border: 1px solid var(--border-soft);
  background: #0d0d10;
  color: var(--text-1);
  font-size: 13px;
  outline: none;
  transition: border-color 0.14s var(--ease);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--border-hover);
}

.form-textarea {
  min-height: 92px;
  resize: vertical;
  font-family: var(--font-mono);
  font-size: 12px;
}

/* Discord Image URL Helper */
.discord-img-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.discord-img-preview {
  width: 44px;
  height: 44px;
  border-radius: 7px;
  border: 1px solid var(--border);
  background: #09090b;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
  font-size: 10px;
  color: var(--text-3);
}

.discord-img-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.discord-tip-banner {
  padding: 10px 13px;
  border-radius: 8px;
  border: 1px solid rgba(167, 139, 250, 0.25);
  background: rgba(167, 139, 250, 0.06);
  color: #d4d4d8;
  font-size: 12px;
  line-height: 1.55;
}

.dash-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 13px;
  border-radius: 7px;
  border: 1px solid var(--border);
  background: var(--surface-raised);
  color: var(--text-1);
  font-size: 12.5px;
  font-weight: 500;
  transition: all 0.14s var(--ease);
}

.dash-btn:hover {
  border-color: var(--border-hover);
  background: var(--surface-hover);
}

.dash-btn.primary {
  background: #f4f4f5;
  color: #09090b;
  border-color: #f4f4f5;
}

.dash-btn.primary:hover {
  background: #ffffff;
}

.dash-btn.danger {
  color: var(--red);
  border-color: rgba(248, 113, 113, 0.3);
  background: rgba(248, 113, 113, 0.07);
}

.dash-btn.sm {
  padding: 5px 9px;
  font-size: 11.5px;
  white-space: nowrap;
  flex-shrink: 0;
}

.dash-item-row {
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  background: #111114;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.dash-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.preset-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 680px) {
  .preset-grid {
    grid-template-columns: 1fr;
  }
}

.template-card {
  padding: 12px 14px;
  border-radius: 9px;
  border: 1px solid var(--border-soft);
  background: #121216;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: all 0.14s var(--ease);
}

.template-card:hover {
  border-color: var(--border-hover);
  background: #1a1a20;
}

.template-card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
}

.template-card-desc {
  font-size: 11.5px;
  color: var(--text-3);
}

/* Toast Notification */
.toast-container {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 120;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  padding: 9px 14px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #16161a;
  color: var(--text-1);
  font-size: 12.5px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.5);
}

.toast.success {
  border-color: rgba(52, 211, 153, 0.45);
}

.toast.error {
  border-color: rgba(248, 113, 113, 0.45);
}

/* Responsive Compact Layout */
@media (max-width: 720px) {
  .app-shell {
    padding: 12px 14px 72px;
    gap: 16px;
  }

  .top-dock {
    top: 8px;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Minimal Monochrome Footer & External Sync Status */
.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 28px;
  padding: 14px 4px 6px;
  border-top: 1px solid var(--border-soft);
  color: var(--text-3);
  font-family: var(--font-mono);
  font-size: 11px;
}

.footer-meta-group {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.sync-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.025);
  font-size: 10.5px;
  color: var(--text-2);
}

.sync-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-3);
}

.sync-dot.live {
  background: var(--green);
}

.footer-admin-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  border-radius: 6px;
  border: 1px solid transparent;
  color: var(--text-3);
  font-family: var(--font-mono);
  font-size: 11px;
  transition: all 0.14s var(--ease);
}

.footer-admin-btn:hover {
  color: var(--text-1);
  border-color: var(--border-soft);
  background: rgba(255, 255, 255, 0.03);
}

.remote-sync-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 12px;
  border-radius: 9px;
  border: 1px solid var(--border-soft);
  background: rgba(255, 255, 255, 0.02);
}
