:root {
  --bg: #eef1f6;
  --surface: rgba(255, 255, 255, 0.65);
  --card: rgba(255, 255, 255, 0.78);
  --glass: rgba(255, 255, 255, 0.55);
  --text: #0f172a;
  --muted: #5f6675;
  --border: rgba(15, 23, 42, 0.12);
  --accent: #0f62fe;
  --accent-2: #4d7cff;
  --on-accent: #f7f9ff;
  --danger: #d43a3a;
  --radius: 14px;
  --shadow-soft: 0 14px 34px rgba(15, 23, 42, 0.12);
  --shadow-card: 0 18px 44px rgba(15, 23, 42, 0.16);
  --blur: 18px;
  --transition: 0.22s ease;
  --font-body: "Inter", "SF Pro Display", "Segoe UI", system-ui, -apple-system, sans-serif;
}

[data-theme="dark"] {
  --bg: #0f1218;
  --surface: rgba(22, 26, 34, 0.7);
  --card: rgba(23, 27, 35, 0.82);
  --glass: rgba(23, 27, 35, 0.65);
  --text: #e9edf5;
  --muted: #aab1c2;
  --border: rgba(255, 255, 255, 0.08);
  --accent: #7bb2ff;
  --accent-2: #99c3ff;
  --on-accent: #0b1220;
  --danger: #f28585;
  --shadow-soft: 0 14px 34px rgba(0, 0, 0, 0.32);
  --shadow-card: 0 18px 44px rgba(0, 0, 0, 0.38);
}

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

body {
  background: radial-gradient(circle at 20% 20%, rgba(79, 131, 255, 0.08), transparent 30%),
    radial-gradient(circle at 80% 0%, rgba(255, 170, 120, 0.12), transparent 28%),
    var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

.container {
  width: min(1200px, 92vw);
  margin: 0 auto;
}

.header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--glass);
  backdrop-filter: blur(var(--blur));
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
}

[data-theme="dark"] .header {
  background: var(--glass);
}

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

.logo {
  letter-spacing: 6px;
  font-weight: 800;
  font-size: 18px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--glass);
  box-shadow: var(--shadow-soft);
}

[data-theme="dark"] .header-actions {
  background: var(--glass);
}

.nav {
  display: flex;
  gap: 16px;
  align-items: center;
}

.account {
  display: flex;
  align-items: center;
  gap: 10px;
}

.account-user {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px 6px 8px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: linear-gradient(120deg, var(--card), var(--surface));
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
}

.account img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid rgba(0, 0, 0, 0.04);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}

.account-name {
  font-size: 13px;
  color: var(--text);
  font-weight: 600;
}

.account-user .btn.secondary {
  padding: 9px 14px;
  background: rgba(0, 0, 0, 0.02);
  border-color: transparent;
  color: var(--text);
}

.account-user .btn.secondary:hover {
  background: var(--accent);
  color: var(--on-accent);
}

.hidden {
  display: none !important;
}

.nav a {
  padding: 10px 12px;
  color: var(--muted);
  border-radius: 12px;
  border: 1px solid transparent;
  transition: background var(--transition), color var(--transition), border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}

.nav a:hover,
.nav a.active {
  color: var(--text);
  background: linear-gradient(120deg, rgba(79, 124, 255, 0.12), rgba(79, 124, 255, 0.02));
  border-color: var(--border);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
  transform: translateY(-1px);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 14px;
  border: 1px solid transparent;
  font-weight: 600;
  letter-spacing: 0.2px;
  cursor: pointer;
  transition: background var(--transition), color var(--transition), border-color var(--transition), transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
}

.btn.primary {
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  color: var(--on-accent);
  border-color: transparent;
  box-shadow: 0 16px 36px rgba(15, 98, 254, 0.25);
}

.btn.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.08);
}

.btn.secondary {
  background: rgba(255, 255, 255, 0.2);
  color: var(--text);
  border-color: var(--border);
}

.btn.secondary:hover {
  background: var(--surface);
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.06);
}

.btn.danger {
  background: rgba(208, 85, 85, 0.08);
  color: var(--danger);
  border-color: rgba(208, 85, 85, 0.35);
}

.btn.danger:hover {
  background: rgba(208, 85, 85, 0.15);
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(208, 85, 85, 0.14);
}

.theme-toggle {
  font-size: 12px;
  padding: 10px 16px;
  border-color: var(--border);
  background: linear-gradient(120deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0));
}

.hero {
  min-height: 78vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 36px 0;
  background: linear-gradient(160deg, rgba(79,124,255,0.18), rgba(255,255,255,0.82)), url('/assets/img/hero.jpg') center/cover no-repeat;
}

[data-theme="dark"] .hero {
  background: linear-gradient(180deg, rgba(13,15,18,0.75), rgba(13,15,18,0.9)), url('/assets/img/hero.jpg') center/cover no-repeat;
}

.hero-content {
  max-width: 800px;
  display: grid;
  gap: 10px;
  color: var(--text);
}

.hero-title {
  font-size: clamp(36px, 6.5vw, 64px);
  font-weight: 600;
  letter-spacing: -0.5px;
  color: var(--text);
}

.hero-sub {
  color: var(--muted);
  font-size: 15px;
}

.section {
  padding: 56px 0;
}

.section header {
  margin-bottom: 24px;
}

.section h2 {
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.2px;
}

.muted {
  color: var(--muted);
}

.grid {
  display: grid;
  gap: 18px;
}

.grid.cols-3 {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.grid.cols-4 {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.manifesto {
  padding: 60px 0;
  text-align: center;
}

.manifesto h2 {
  font-size: clamp(30px, 5vw, 46px);
  font-weight: 600;
  letter-spacing: -0.4px;
}

.manifesto p {
  margin-top: 12px;
  color: var(--muted);
  font-size: 17px;
}

.lineup-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.line-item {
  padding: 18px;
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-soft);
}

.line-item h3 {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.2px;
}

.line-item p {
  color: var(--muted);
  margin-top: 8px;
}

.card {
  background: linear-gradient(180deg, rgba(0,0,0,0.04), rgba(0,0,0,0.1)), var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
  overflow: hidden;
}

.card:hover {
  border-color: #cfcfcf;
  box-shadow: 0 16px 36px rgba(0,0,0,0.12);
  transform: translateY(-4px);
}

.car-thumb {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  height: 210px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.car-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.car-price {
  font-weight: 600;
  margin: 6px 0 2px;
  font-size: 18px;
}

.card h3 {
  margin: 4px 0 0;
}

.card-body {
  display: grid;
  gap: 6px;
  flex: 1;
}

.action-row {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  justify-content: space-between;
  flex-wrap: wrap;
}

.action-row .btn {
  flex: 1 1 30%;
  min-height: 42px;
}

.action-row .btn + .btn {
  margin-left: 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 12px;
  background: var(--surface);
  width: fit-content;
}

.badge.sold {
  border-color: #f2d6d6;
  color: #7a1f1f;
  background: #fff4f4;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 12px;
  background: var(--surface);
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
  padding: 6px 0;
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 12px;
  backdrop-filter: blur(var(--blur));
  box-shadow: var(--shadow-soft);
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

label {
  font-size: 13px;
  color: var(--muted);
}

input,
select,
textarea {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.8);
  color: var(--text);
  font-family: var(--font-body);
  transition: border-color var(--transition), box-shadow var(--transition), background var(--transition);
  appearance: none;
}

[data-theme="dark"] input,
[data-theme="dark"] select,
[data-theme="dark"] textarea {
  background: rgba(23, 27, 35, 0.9);
  border-color: rgba(233, 237, 245, 0.14);
  color: var(--text);
}

[data-theme="dark"] input::placeholder,
[data-theme="dark"] textarea::placeholder {
  color: var(--muted);
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(15, 98, 254, 0.18);
  outline: none;
}

select option {
  color: #0f172a;
  background: #ffffff;
}

[data-theme="dark"] select option {
  color: #e9edf5;
  background: #171b23;
}

select:disabled,
select:disabled option {
  color: var(--muted);
}

/* Premium checkboxes (global) */
input[type="checkbox"] {
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 8px;
  border: 1px solid rgba(15, 23, 42, 0.22);
  background: linear-gradient(180deg, rgba(255,255,255,0.95), rgba(240,242,247,0.9));
  position: relative;
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition), transform var(--transition);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.8);
  vertical-align: middle;
}

input[type="checkbox"]:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 12px rgba(15, 98, 254, 0.18);
}

input[type="checkbox"]:focus-visible {
  outline: 2px solid rgba(15, 98, 254, 0.4);
  outline-offset: 2px;
}

input[type="checkbox"]:checked {
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(15, 98, 254, 0.25);
  transform: translateY(-1px);
}

input[type="checkbox"]::after {
  content: '';
  position: absolute;
  inset: 4px;
  border-radius: 4px;
  background: var(--on-accent);
  opacity: 0;
  transform: scale(0.6);
  transition: opacity var(--transition), transform var(--transition);
}

input[type="checkbox"]:checked::after {
  opacity: 1;
  transform: scale(1);
}

[data-theme="dark"] input[type="checkbox"] {
  background: rgba(233, 237, 245, 0.08);
  border-color: rgba(233, 237, 245, 0.16);
}

.status-line {
  color: var(--muted);
  min-height: 22px;
  margin-bottom: 12px;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 40;
}

.modal.open {
  display: flex;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.modal-content {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  width: min(560px, 92vw);
  z-index: 1;
  max-height: 90vh;
  overflow-y: auto;
  backdrop-filter: blur(var(--blur));
  box-shadow: var(--shadow-card);
}

.auction-window {
  padding-top: 48px;
}

.macos-bar {
  position: absolute;
  top: 14px;
  left: 16px;
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.06);
  border: 1px solid var(--border);
}

[data-theme="dark"] .macos-bar {
  background: rgba(255, 255, 255, 0.06);
}

.macos-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-flex;
  border: none;
  padding: 0;
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
}

.macos-dot.red:hover {
  box-shadow: 0 0 0 2px rgba(255, 95, 87, 0.3);
}

.macos-dot.red { background: #ff5f57; }
.macos-dot.yellow { background: #febc2e; }
.macos-dot.green { background: #28c840; }

.auction-window .modal-close {
  top: 12px;
  right: 12px;
}

.modal-wide {
  width: min(880px, 94vw);
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 32px;
  height: 32px;
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 50%;
  cursor: pointer;
}

.toast {
  position: fixed;
  bottom: 18px;
  right: 18px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  color: var(--text);
  display: none;
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(var(--blur));
  min-width: 220px;
}

.toast.show {
  display: block;
}

.details-body {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 18px;
}

.details-media img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.details-info h3 {
  font-size: 24px;
  margin-bottom: 6px;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
}

.pill-status {
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 12px;
  border: 1px solid var(--border);
  background: var(--card);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.pill-status::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--muted);
}

.pill-status.ok {
  border-color: #d8ead8;
  color: #245c2c;
}

.pill-status.ok::before {
  background: #4fa65f;
}

.pill-status.warn {
  border-color: #f0e6c4;
  color: #6a5315;
}

.pill-status.warn::before {
  background: #d9b200;
}

.pill-status.no {
  border-color: #f2d6d6;
  color: #7a1f1f;
}

.pill-status.no::before {
  background: #d05555;
}

.spec-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.spec-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 0.8fr;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card);
  align-items: center;
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.spec-row:hover {
  transform: translateY(-2px);
  border-color: #cfcfcf;
  box-shadow: 0 8px 16px rgba(0,0,0,0.04);
}

.spec-row .spec-status {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.spec-row .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.spec-row.ok .dot { background: #4fa65f; }
.spec-row.warn .dot { background: #d9b200; }
.spec-row.no .dot { background: #d05555; }

.spec-row.ok { border-color: #d8ead8; }
.spec-row.warn { border-color: #f0e6c4; }
.spec-row.no { border-color: #f2d6d6; }

.details-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.admin-page .section {
  display: none;
  padding: 0;
}

.admin-page .section.active {
  display: block;
  animation: sectionFade 0.22s ease;
}

@keyframes sectionFade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.admin-dashboard {
  display: flex;
  min-height: 100vh;
}

.admin-sidebar {
  width: 260px;
  padding: 24px 18px;
  background: linear-gradient(180deg, rgba(0,0,0,0.08), rgba(0,0,0,0.02)), var(--card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 20;
}

.admin-brand {
  font-weight: 700;
  letter-spacing: 2px;
  font-size: 14px;
  padding: 12px 10px 20px;
}

.admin-menu {
  display: grid;
  gap: 8px;
  flex: 1;
}

.admin-menu-item {
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  padding: 12px 14px;
  border-radius: 12px;
  cursor: pointer;
  text-align: left;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition), transform var(--transition);
  position: relative;
}

.admin-menu-item::before {
  content: '';
  position: absolute;
  left: -18px;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 0;
  border-radius: 999px;
  background: var(--accent);
  transition: height var(--transition);
}

.admin-menu-item:hover {
  background: rgba(15, 98, 254, 0.08);
  border-color: rgba(15, 98, 254, 0.2);
  transform: translateX(2px);
}

.admin-menu-item.active {
  background: rgba(15, 98, 254, 0.12);
  border-color: rgba(15, 98, 254, 0.35);
  box-shadow: 0 10px 26px rgba(15, 98, 254, 0.12);
}

.admin-menu-item.active::before {
  height: 26px;
}

.admin-sidebar-footer {
  padding-top: 14px;
  border-top: 1px solid var(--border);
  display: grid;
  gap: 10px;
}

.admin-logout {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(208, 85, 85, 0.35);
  color: var(--danger);
  background: rgba(208, 85, 85, 0.08);
  font-weight: 600;
  width: 100%;
}

.admin-logout:hover {
  background: rgba(208, 85, 85, 0.16);
}

.admin-content {
  flex: 1;
  padding: 32px 36px 48px;
  max-width: 1200px;
}

.admin-topbar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.admin-topbar-title {
  font-size: 20px;
  font-weight: 600;
}

.admin-menu-toggle {
  display: none;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  padding: 10px 14px;
  border-radius: 12px;
  cursor: pointer;
}

.sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 10;
}

.section-header {
  margin-bottom: 20px;
}

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

.overview-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  display: grid;
  gap: 8px;
  box-shadow: var(--shadow-soft);
}

.overview-card strong {
  font-size: 28px;
}

.image-preview {
  margin-top: 10px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  min-height: 120px;
  display: grid;
  place-items: center;
  overflow: hidden;
}

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

.extra-images {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.extra-image {
  display: grid;
  gap: 10px;
}

.extra-image-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}

.extra-image-input {
  width: 100%;
}

.add-image-btn {
  margin-top: 10px;
  width: fit-content;
}

.remove-image-btn {
  white-space: nowrap;
}

.auction-hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
  align-items: center;
  padding: 26px;
  border-radius: 20px;
  background: linear-gradient(140deg, rgba(15, 98, 254, 0.14), rgba(255, 255, 255, 0.7));
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
  margin-bottom: 24px;
}

.auction-filters {
  display: flex;
  gap: 12px;
  margin: 8px 0 18px;
  flex-wrap: wrap;
}

.auction-filter {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}

.auction-filter:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-soft);
}

.auction-filter.active {
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  border-color: transparent;
  color: var(--on-accent);
  box-shadow: 0 12px 24px rgba(15, 98, 254, 0.2);
}

.auction-hero h1 {
  font-size: clamp(32px, 4.8vw, 52px);
  letter-spacing: -0.4px;
  margin: 10px 0;
}

.auction-hero-panel {
  display: grid;
  gap: 12px;
  padding: 18px;
  border-radius: 16px;
  background: var(--card);
  border: 1px solid var(--border);
}

.auction-hero-panel strong {
  font-size: 16px;
}

.auction-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.auction-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto 1fr;
  box-shadow: var(--shadow-soft);
  transition: transform var(--transition), box-shadow var(--transition);
}

.auction-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card);
}

.auction-media {
  height: 190px;
  overflow: hidden;
  background: var(--surface);
}

.auction-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.auction-body {
  padding: 16px;
  display: grid;
  gap: 10px;
}

.auction-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.auction-timer {
  font-size: 12px;
  color: var(--muted);
}

.auction-timer.expired {
  color: var(--danger);
}

.auction-bid {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.auction-bid strong {
  font-size: 18px;
}

.auction-modal {
  display: grid;
  gap: 18px;
}

.auction-modal-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 18px;
}

.auction-modal-media {
  border-radius: 14px;
  border: 1px solid var(--border);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: var(--surface);
}

.auction-modal-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.auction-modal-info {
  display: grid;
  gap: 12px;
}

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

.auction-chat-panel {
  position: fixed;
  top: 50%;
  right: 6px;
  transform: translateY(-50%);
  width: min(360px, 92vw);
  height: 70vh;
  max-height: 760px;
  z-index: 45;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition), transform var(--transition);
}

.auction-chat-panel.open {
  opacity: 1;
  pointer-events: auto;
}

.auction-chat {
  display: flex;
  flex-direction: column;
  gap: 10px;
  height: 100%;
  padding: 0;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--card);
  box-shadow: var(--shadow-card);
}

.auction-chat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.auction-chat-messages {
  flex: 1;
  overflow: auto;
  padding: 4px 8px;
  display: grid;
  gap: 0;
}

.chat-message {
  display: flex;
  align-items: baseline;
  gap: 3px;
  font-size: 12px;
  color: var(--text);
  line-height: 1.05;
  padding: 1px 0;
}

.chat-name {
  font-weight: 700;
  color: var(--accent);
  font-size: 12px;
}

.chat-body {
  flex: 1 1 auto;
  font-size: 12px;
  line-height: 1.05;
  color: var(--text);
  word-break: break-word;
}

.chat-time {
  color: var(--muted);
  font-size: 10px;
  margin-left: auto;
}

.auction-chat-input {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 12px 14px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.auction-winner {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(15, 98, 254, 0.08);
  border: 1px solid rgba(15, 98, 254, 0.2);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
}

.auction-card .auction-winner {
  margin-top: 10px;
  font-size: 12px;
}

.auction-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--surface);
}

.auction-stats strong {
  display: block;
  margin-top: 4px;
  font-size: 16px;
}

.auction-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
}

.auction-bid-bar {
  position: sticky;
  bottom: 0;
  margin-top: 16px;
  padding: 14px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.8));
  border: 1px solid var(--border);
  box-shadow: 0 -12px 30px rgba(15, 23, 42, 0.12);
  display: grid;
  gap: 12px;
}

[data-theme="dark"] .auction-bid-bar {
  background: linear-gradient(180deg, rgba(18, 22, 30, 0.92), rgba(18, 22, 30, 0.82));
}

.auction-bid-field {
  display: grid;
  gap: 6px;
}

.auction-bid-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.auction-bid-actions .btn {
  flex: 1 1 160px;
}

.auction-history {
  border-top: 1px solid var(--border);
  padding-top: 16px;
  display: grid;
  gap: 10px;
}

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

.auction-history-list {
  display: grid;
  gap: 8px;
}

.auction-history-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
}

button[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

@media (max-width: 900px) {
  .auction-hero {
    grid-template-columns: 1fr;
  }
  .auction-modal-grid {
    grid-template-columns: 1fr;
  }
  .auction-chat-panel {
    right: 16px;
    left: 16px;
    top: auto;
    bottom: 16px;
    transform: none;
    width: auto;
    height: 45vh;
  }
}

.admin-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 16px;
  align-items: start;
}

.admin-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
}

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

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.input-wide {
  grid-column: 1 / -1;
}

.chip-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.chip-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 12px;
  color: var(--muted);
}

.chip-switch input {
  position: absolute;
  opacity: 0;
}

.chip-switch .track {
  width: 36px;
  height: 20px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.08);
  border: 1px solid rgba(15, 23, 42, 0.18);
  position: relative;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.chip-switch .track::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(180deg, #ffffff, #e6e9f2);
  box-shadow: 0 3px 8px rgba(15, 23, 42, 0.18);
  transition: transform var(--transition), background var(--transition), box-shadow var(--transition);
}

.chip-switch input:focus-visible + .track {
  outline: 2px solid rgba(15, 98, 254, 0.4);
  outline-offset: 2px;
}

.chip-switch input:checked + .track {
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(15, 98, 254, 0.25);
}

.chip-switch input:checked + .track::after {
  transform: translateX(16px);
  background: #f7f9ff;
  box-shadow: 0 6px 14px rgba(15, 98, 254, 0.24);
}

[data-theme="dark"] .chip-switch .track {
  background: rgba(233, 237, 245, 0.08);
  border: 1px solid rgba(233, 237, 245, 0.16);
}

.table {
  display: grid;
  gap: 10px;
}

.finance-row {
  display: grid;
  grid-template-columns: 1fr 1.3fr 0.9fr;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.finance-row strong {
  display: block;
  margin-bottom: 4px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--muted);
  background: var(--card);
  font-size: 12px;
}

.status-pill.ok {
  border-color: #d8ead8;
  color: #245c2c;
}

.status-pill.warn {
  border-color: #f0e6c4;
  color: #6a5315;
}

.status-pill.no {
  border-color: #f2d6d6;
  color: #7a1f1f;
}

.mini-list {
  display: grid;
  gap: 8px;
}

.admin-side {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 16px;
  align-items: start;
}

.admin-sidebar {
  display: grid;
  gap: 10px;
  align-content: start;
}

.sidebar-btn {
  width: 100%;
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  cursor: pointer;
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.sidebar-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.08);
}

.sidebar-btn.active {
  border-color: rgba(15, 98, 254, 0.5);
  box-shadow: 0 12px 26px rgba(15, 98, 254, 0.18);
}

.sidebar-btn .tag {
  white-space: nowrap;
}

.online-list {
  display: grid;
  gap: 10px;
}

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

.online-user-main {
  display: flex;
  align-items: center;
  gap: 12px;
}

.online-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid rgba(0, 0, 0, 0.05);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);
  background: rgba(0, 0, 0, 0.04);
}

.online-status {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}

.mini-item {
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}

.mini-item .muted {
  font-size: 12px;
}

.mini-item.sold {
  opacity: 0.7;
}

.mini-info {
  display: grid;
  gap: 4px;
}

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

.mini-actions .btn {
  padding: 8px 12px;
  box-shadow: none;
}

.action-menu {
  position: relative;
}

.action-trigger {
  padding: 0;
  width: 36px;
  height: 36px;
  font-size: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.action-sheet {
  position: absolute;
  right: 0;
  top: 120%;
  min-width: 170px;
  background: linear-gradient(180deg, rgba(0,0,0,0.04), rgba(0,0,0,0.08)), var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
  display: none;
  z-index: 4;
  overflow: hidden;
}

.action-menu.open .action-sheet {
  display: block;
}

.action-sheet button {
  width: 100%;
  text-align: left;
  padding: 12px 14px;
  background: transparent;
  border: none;
  color: var(--text);
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 12px;
  transition: background var(--transition), transform var(--transition), color var(--transition);
}

.action-sheet button:hover {
  background: rgba(0, 0, 0, 0.06);
  transform: translateX(2px);
}

.action-sheet .danger {
  color: #b12b2b;
}

.action-sheet button + button {
  border-top: 1px solid var(--border);
}

.action-icon {
  width: 22px;
  height: 22px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.06);
  color: var(--muted);
  font-size: 12px;
}

.action-sheet .danger .action-icon {
  background: rgba(177, 43, 43, 0.12);
  color: #b12b2b;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  font-size: 12px;
  color: var(--muted);
  background: var(--surface);
}

.setup-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
  margin-top: 6px;
}

.setup-block {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  background: linear-gradient(180deg, rgba(0,0,0,0.04), rgba(0,0,0,0.1)), var(--card);
  display: grid;
  gap: 12px;
  box-shadow: var(--shadow-soft);
}

.setup-block-title {
  font-weight: 600;
  font-size: 14px;
}

.setup-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 12px;
  align-items: center;
}

.setup-row > * {
  min-width: 0;
}

.setup-left {
  display: grid;
  gap: 2px;
}

.setup-title {
  font-weight: 700;
}

.setup-sub {
  font-size: 12px;
}

.setup-right {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.setup-row select,
.setup-row input[type="number"] {
  width: 100%;
  background: rgba(15, 23, 42, 0.08);
  color: var(--text);
  border: 1px solid rgba(15, 23, 42, 0.15);
  min-width: 0;
  padding: 10px 12px;
}

[data-theme="dark"] .setup-row select,
[data-theme="dark"] .setup-row input[type="number"] {
  background: rgba(233, 237, 245, 0.06);
  border: 1px solid rgba(233, 237, 245, 0.12);
}

.setup-row select:disabled {
  background: rgba(15, 23, 42, 0.04);
  color: var(--muted);
}

[data-theme="dark"] .setup-row select:disabled {
  background: rgba(233, 237, 245, 0.04);
}

.check {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-weight: 600;
  color: var(--text);
}

.ios-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.ios-switch input {
  position: absolute;
  opacity: 0;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.ios-switch .track {
  width: 44px;
  height: 24px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.1);
  border: 1px solid rgba(15, 23, 42, 0.18);
  position: relative;
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
}

.ios-switch .track::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(180deg, #ffffff, #e6e9f2);
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.18);
  transition: transform var(--transition), background var(--transition), box-shadow var(--transition);
}

.ios-switch input:focus-visible + .track {
  outline: 2px solid rgba(15, 98, 254, 0.4);
  outline-offset: 2px;
}

.ios-switch input:checked + .track {
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(15, 98, 254, 0.25);
}

.ios-switch input:checked + .track::after {
  transform: translateX(20px);
  background: #f7f9ff;
  box-shadow: 0 6px 14px rgba(15, 98, 254, 0.24);
}

[data-theme="dark"] .ios-switch .track {
  background: rgba(233, 237, 245, 0.08);
  border: 1px solid rgba(233, 237, 245, 0.16);
}

.check input[type="checkbox"] {
  width: 18px;
  height: 18px;
}

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

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

.destaque-card {
  animation: fadeUp 0.6s ease both;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.footer {
  padding: 30px 0 40px;
  border-top: 1px solid var(--border);
  margin-top: 30px;
}

.footer p {
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 900px) {
  .hero {
    min-height: 70vh;
  }

  .nav {
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .admin-grid {
    grid-template-columns: 1fr;
  }

  .admin-dashboard {
    flex-direction: column;
  }

  .admin-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    transform: translateX(-100%);
    transition: transform var(--transition);
    height: 100vh;
  }

  .admin-dashboard.sidebar-open .admin-sidebar {
    transform: translateX(0);
  }

  .admin-dashboard.sidebar-open .sidebar-backdrop {
    display: block;
  }

  .admin-content {
    padding: 24px;
    max-width: 100%;
  }

  .admin-menu-toggle {
    display: inline-flex;
  }

  .container {
    width: 94vw;
  }
}
