/* ═══════════════════════════════════════
   PARISHOP — Design System
   Deep Dark + Neon Purple
════════════════════════════════════════ */

:root {
  --bg:        #090909;
  --bg-card:   #1A1A1A;
  --bg-input:  #111111;
  --accent:    #8A2BE2;
  --accent-dim:#6B22B0;
  --text:      #FFFFFF;
  --text-muted:#B0B0B0;
  --text-hint: #666666;
  --border:    #2A2A2A;
  --danger:    #E53935;
  --radius:    14px;
  --radius-sm: 8px;
  --header-h:  56px;
  --nav-h:     64px;
  --safe-top:  env(safe-area-inset-top, 0px);
  --safe-bot:  env(safe-area-inset-bottom, 0px);
}

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

html { height: 100%; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100%;
  overflow-x: hidden;
}

/* ── Page transitions ── */
#app-content {
  transition: opacity 0.12s ease, transform 0.12s ease;
}
#app-content.page-exit {
  opacity: 0;
  transform: translateY(5px);
}
#app-content.page-enter {
  animation: page-enter 0.35s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes page-enter {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Header ── */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  background: rgba(9, 9, 9, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  z-index: 100;
}

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

.logo {
  display: flex;
  align-items: center;
}

.icon-btn {
  position: relative;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
  transition: color 0.2s, background 0.2s, transform 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}
@media (hover: hover) {
  .icon-btn:hover { color: var(--text); background: rgba(255,255,255,0.06); }
}
.icon-btn:active { background: var(--border); color: var(--text); transform: scale(0.9); }

.cart-badge {
  position: absolute;
  top: 0;
  right: 0;
  background: var(--accent);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  padding: 0 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Main scroll area ── */
main {
  padding-top: calc(var(--header-h) + 12px);
  padding-bottom: calc(var(--nav-h) + 16px + var(--safe-bot));
  min-height: 100vh;
}

/* ── Bottom nav ── */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: calc(var(--nav-h) + var(--safe-bot));
  padding-bottom: var(--safe-bot);
  background: rgba(9, 9, 9, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  z-index: 100;
}

.nav-item {
  flex: 1;
  background: none;
  border: none;
  color: var(--text-hint);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 8px 4px;
  font-size: 0.7rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-item.active { color: var(--accent); }
.nav-item svg { transition: transform 0.2s, stroke 0.2s; }
.nav-item:active svg { transform: scale(0.85); }
.nav-item.active svg { transform: scale(1.1); }

/* ── Section headers ── */
.section-title {
  font-size: 1.4rem;
  font-weight: 700;
  padding: 0 16px;
  margin-bottom: 16px;
}

/* ── Catalog banner ── */
.catalog-banner {
  margin: 0 16px 14px;
  padding: 16px 18px;
  background: linear-gradient(135deg, rgba(138,43,226,0.18) 0%, rgba(138,43,226,0.04) 100%);
  border: 1px solid rgba(138,43,226,0.22);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.catalog-banner-text {}
.catalog-banner-greeting {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 3px;
}
.catalog-banner-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}
.catalog-banner-emoji {
  font-size: 2rem;
  line-height: 1;
  flex-shrink: 0;
}

/* ── Category filter tabs ── */
.category-tabs {
  display: flex;
  gap: 6px;
  padding: 0 16px 14px;
  overflow-x: auto;
  scrollbar-width: none;
}
.category-tabs::-webkit-scrollbar { display: none; }

.tab-btn {
  flex-shrink: 0;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 20px;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 5px 13px;
  cursor: pointer;
  transition: all 0.22s;
}
@media (hover: hover) {
  .tab-btn:hover { border-color: rgba(138,43,226,0.5); color: var(--text); }
}
.tab-btn:active { transform: scale(0.95); }
.tab-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 600;
}

/* ── Product grid ── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  padding: 0 16px;
}

/* Overlay-style cards — image fills entire card */
.product-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 3/4;
  background: #111;
  transition: transform 0.22s cubic-bezier(0.22,1,0.36,1), box-shadow 0.22s;
  animation: card-enter 0.4s cubic-bezier(0.22,1,0.36,1) both;
}
@keyframes card-enter {
  from { opacity: 0; transform: translateY(16px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@media (hover: hover) {
  .product-card:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 32px rgba(138,43,226,0.25);
  }
}
.product-card:active { transform: scale(0.95); }

.product-img-wrap {
  position: absolute;
  inset: 0;
}
.product-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.product-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  background: var(--bg-card);
}

.badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 3px 7px;
  border-radius: 6px;
  z-index: 2;
}

/* Gradient overlay at bottom of card */
.product-overlay {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: linear-gradient(to top, rgba(0,0,0,1) 0%, rgba(0,0,0,0.75) 50%, transparent 100%);
  padding: 36px 10px 12px;
  z-index: 1;
}
.product-name {
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
}
.product-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.product-price {
  font-size: 1rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0,0,0,0.6);
}
.add-btn-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: var(--accent);
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.18s, transform 0.15s, box-shadow 0.18s;
  line-height: 1;
}
@media (hover: hover) {
  .add-btn-circle:hover {
    background: #9d3df5;
    box-shadow: 0 0 12px rgba(138,43,226,0.6);
    transform: scale(1.1);
  }
}
.add-btn-circle:active   { transform: scale(0.85); }
.add-btn-circle.in-cart  { background: var(--accent-dim); font-size: 0.75rem; }

/* Keep .add-btn for sticky footer and other uses */
.add-btn {
  width: 100%;
  background: var(--accent);
  border: none;
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 8px;
  cursor: pointer;
  transition: opacity 0.15s;
}
.add-btn:active  { opacity: 0.8; }
.add-btn.in-cart { background: var(--accent-dim); }

/* ── Product detail ── */
.product-detail { padding: 0 16px; }

.product-detail-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius);
  background: var(--bg-card);
  margin-bottom: 20px;
}

.product-detail-img-placeholder {
  width: 100%;
  aspect-ratio: 1;
  background: var(--bg-card);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 5rem;
  margin-bottom: 20px;
}

.product-detail-name {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.product-detail-price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 16px;
}

.product-detail-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 80px;
}

.sticky-footer {
  position: fixed;
  bottom: calc(var(--nav-h) + var(--safe-bot));
  left: 0;
  right: 0;
  padding: 12px 16px;
  background: rgba(9, 9, 9, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  z-index: 90;
}

/* ── Buttons ── */
.btn {
  display: block;
  width: 100%;
  padding: 15px;
  border: none;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.18s, transform 0.15s, box-shadow 0.18s, filter 0.18s;
  text-align: center;
}
@media (hover: hover) {
  .btn-primary:hover {
    filter: brightness(1.15);
    box-shadow: 0 4px 20px rgba(138,43,226,0.45);
    transform: translateY(-1px);
  }
  .btn-secondary:hover { background: #222; }
  .btn-danger:hover { filter: brightness(1.1); }
}
.btn:active { opacity: 0.85; transform: scale(0.98); box-shadow: none; }

.btn-primary { background: var(--accent); color: #fff; }
.btn-secondary { background: var(--bg-card); color: var(--text); border: 1px solid var(--border); }
.btn-danger { background: var(--danger); color: #fff; }

/* ── Cart ── */
.cart-list { padding: 0 16px; display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }

.cart-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  animation: cart-item-enter 0.35s cubic-bezier(0.22,1,0.36,1) both;
}
@keyframes cart-item-enter {
  from { opacity: 0; transform: translateX(-10px); }
  to   { opacity: 1; transform: translateX(0); }
}
.cart-item:nth-child(1) { animation-delay: 0ms; }
.cart-item:nth-child(2) { animation-delay: 50ms; }
.cart-item:nth-child(3) { animation-delay: 100ms; }
.cart-item:nth-child(4) { animation-delay: 150ms; }
.cart-item:nth-child(5) { animation-delay: 200ms; }

.cart-item-img {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: #111;
  flex-shrink: 0;
}

.cart-item-img-placeholder {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  background: #111;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  flex-shrink: 0;
}

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

.cart-item-name {
  font-size: 0.85rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 4px;
}

.cart-item-price { font-size: 0.9rem; color: var(--accent); font-weight: 700; }

.qty-control {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.qty-btn {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, transform 0.12s, border-color 0.15s;
}
.qty-btn:active { background: var(--accent); border-color: var(--accent); transform: scale(0.88); }

.qty-val { font-size: 0.9rem; font-weight: 600; min-width: 20px; text-align: center; }

.cart-total-block {
  margin: 0 16px;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.cart-total-label { color: var(--text-muted); font-size: 0.9rem; }
.cart-total-val { font-size: 1.2rem; font-weight: 700; color: var(--accent); }

.cart-checkout-wrap { padding: 0 16px; }

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 60px 24px;
  color: var(--text-hint);
}
.empty-state-icon { font-size: 3rem; }
.empty-state-text { font-size: 0.95rem; }

/* ── Checkout ── */
.checkout-form { padding: 0 16px; display: flex; flex-direction: column; gap: 20px; }

.form-group { position: relative; }

.form-input {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 1rem;
  padding: 20px 16px 8px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(138,43,226,0.12);
}

.form-label {
  position: absolute;
  left: 16px;
  top: 14px;
  color: var(--text-hint);
  font-size: 1rem;
  pointer-events: none;
  transition: all 0.2s;
}
.form-input:focus ~ .form-label,
.form-input:not(:placeholder-shown) ~ .form-label {
  top: 6px;
  font-size: 0.72rem;
  color: var(--accent);
}

.form-section-title {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.choice-card {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 10px;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s, transform 0.15s;
}
@media (hover: hover) {
  .choice-card:hover { border-color: rgba(138,43,226,0.5); }
}
.choice-card:active { transform: scale(0.97); }
.choice-card.selected {
  border-color: var(--accent);
  background: rgba(138, 43, 226, 0.12);
  box-shadow: 0 0 0 1px rgba(138,43,226,0.2);
}

.choice-card-icon { font-size: 1.4rem; margin-bottom: 4px; }
.choice-card-label { font-size: 0.8rem; font-weight: 500; }

/* ── Order success ── */
.success-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px;
  min-height: calc(100vh - var(--header-h) - var(--nav-h));
  animation: success-appear 0.45s cubic-bezier(0.22,1,0.36,1) both;
}
@keyframes success-appear {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Circle with checkmark */
.success-circle {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: rgba(138,43,226,0.12);
  border: 2px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 28px;
  animation: success-pop 0.5s 0.1s cubic-bezier(0.22,1,0.36,1) both;
}
@keyframes success-pop {
  from { opacity: 0; transform: scale(0.6); }
  to   { opacity: 1; transform: scale(1); }
}
.success-check {
  width: 40px;
  height: 40px;
  stroke: var(--accent);
  stroke-width: 2.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 60;
  stroke-dashoffset: 60;
  animation: draw-check 0.4s 0.35s ease forwards;
}
@keyframes draw-check {
  to { stroke-dashoffset: 0; }
}

.success-order-num {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
  opacity: 0;
  animation: fade-up 0.3s 0.5s ease forwards;
}
.success-title {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 10px;
  opacity: 0;
  animation: fade-up 0.3s 0.6s ease forwards;
}
.success-sub {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  max-width: 260px;
  opacity: 0;
  animation: fade-up 0.3s 0.7s ease forwards;
}
.success-btn-wrap {
  margin-top: 36px;
  opacity: 0;
  animation: fade-up 0.3s 0.85s ease forwards;
}
@keyframes fade-up {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Loader ── */
.loader {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 48px;
}
.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Toast ── */
.toast {
  position: fixed;
  bottom: calc(var(--nav-h) + var(--safe-bot) + 12px);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 10px 20px;
  font-size: 0.88rem;
  color: var(--text);
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 999;
  pointer-events: none;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── Admin panel ── */
.admin-tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
  padding: 0 16px;
  margin-bottom: 16px;
}

.admin-tab {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 10px 16px;
  cursor: pointer;
  margin-bottom: -1px;
  transition: color 0.2s, border-color 0.2s;
}
.admin-tab.active { color: var(--accent); border-bottom-color: var(--accent); }

.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  margin-bottom: 16px;
}

.admin-list {
  padding: 0 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.admin-list-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  gap: 12px;
  transition: border-color 0.2s, transform 0.15s;
  animation: list-item-enter 0.3s cubic-bezier(0.22,1,0.36,1) both;
}
@keyframes list-item-enter {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (hover: hover) {
  .admin-list-item:hover { border-color: rgba(138,43,226,0.4); }
}

.admin-list-item-main {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

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

.admin-list-item-name {
  font-size: 0.9rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-list-item-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 3px;
}

.admin-list-item-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.status-dot--green { background: #4CAF50; }
.status-dot--red   { background: var(--danger); }

/* User search */
.user-search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.user-search-icon {
  position: absolute;
  left: 12px;
  color: var(--text-hint);
  pointer-events: none;
  flex-shrink: 0;
}
.user-search-input {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 0.9rem;
  padding: 11px 14px 11px 38px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.user-search-input::placeholder { color: var(--text-hint); }
.user-search-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(138,43,226,0.12);
}

/* Role selector */
.role-select {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.78rem;
  padding: 6px 10px;
  cursor: pointer;
  outline: none;
  transition: border-color 0.2s;
}
.role-select:focus { border-color: var(--accent); }
.role-select:disabled { opacity: 0.45; cursor: not-allowed; }

/* Product form textarea */
textarea.form-input {
  min-height: 80px;
  resize: vertical;
  padding-top: 22px;
  line-height: 1.5;
}

/* ── Logo ── */
.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}
.logo-img {
  height: 100px;
  width: 100px;
  object-fit: cover;
  border-radius: 10px;
  display: block;
  flex-shrink: 0;
}
.logo-text {
  font-size: 1.05rem;
  letter-spacing: 2.5px;
  line-height: 1;
}
.logo-pari {
  font-weight: 300;
  color: rgba(255, 255, 255, 0.9);
}
.logo-shop {
  font-weight: 800;
  color: var(--accent);
}


/* ── Splash screen ── */
#splash {
  position: fixed;
  inset: 0;
  background: #090909;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.45s ease;
}
#splash.splash-hide {
  opacity: 0;
  pointer-events: none;
}

.splash-spinner {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 3px solid rgba(138,43,226,0.2);
  border-top-color: var(--accent);
  animation: spin 0.85s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}



/* ── Image upload area ── */
.upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.2s;
  background: var(--bg-input);
}
.upload-area:active,
.upload-area:focus-within { border-color: var(--accent); }

.upload-placeholder {
  aspect-ratio: 16/9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--text-hint);
  font-size: 0.85rem;
}
.upload-placeholder-icon { font-size: 2.2rem; }

.upload-preview-img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
}

/* ── Utility ── */
.hidden { display: none !important; }
