@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;800&display=swap');

/* ===========================
   HILLTOP SHOP — SELLER UPLOAD
   Neon Dark Dashboard
   =========================== */

:root {
  --bg-dark: #0b0f14;
  --panel-dark: #121823;
  --panel-darker: #0d131c;
  --border-dark: #1f2a38;
  --neon: #39ff14;
  --neon-soft: rgba(57, 255, 20, 0.35);
  --text-main: #e8fbe8;
  --text-muted: #9fb7a5;
}

/* ---------- Base ---------- */

body.upload-page {
  font-family: 'Inter', system-ui, sans-serif;
  background:
    radial-gradient(circle at top, #0f1624, #05070b 70%);
  color: var(--text-main);
  padding: 40px 20px;
  margin: 0;
  min-height: 100vh;
}

/* ---------- Home Button ---------- */

#home-btn {
  position: fixed;
  top: 16px;
  left: 16px;
  z-index: 2000;
  padding: 10px 16px;
  border-radius: 999px;
  background: #0e151f;
  color: var(--neon);
  text-decoration: none;
  font-weight: 800;
  border: 1px solid var(--neon-soft);
  box-shadow: 0 0 14px var(--neon-soft);
}

#home-btn:hover {
  box-shadow: 0 0 22px var(--neon);
}

/* ---------- Upload Form Section ---------- */

#upload-form-section {
  max-width: 520px;
  margin: 80px auto 60px;
  background: linear-gradient(
    180deg,
    var(--panel-dark),
    var(--panel-darker)
  );
  padding: 34px;
  border-radius: 18px;
  border: 1px solid var(--border-dark);
  box-shadow:
    0 0 30px rgba(0,0,0,0.6),
    inset 0 0 0 1px rgba(255,255,255,0.02);
}

#upload-form-section h2 {
  text-align: center;
  margin-bottom: 26px;
  color: var(--neon);
  text-transform: uppercase;
  font-size: 1.4rem;
  letter-spacing: 1px;
  text-shadow: 0 0 14px var(--neon-soft);
}

/* ---------- Form ---------- */

#upload-form {
  display: flex;
  flex-direction: column;
}

#upload-form label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 6px;
}

#upload-form input,
#upload-form textarea,
#upload-form select {
  padding: 12px 14px;
  margin-bottom: 18px;
  border-radius: 10px;
  background: #080c12;
  border: 1px solid var(--border-dark);
  color: var(--text-main);
  font-size: 0.95rem;
}

#upload-form textarea {
  resize: vertical;
  min-height: 90px;
}

#upload-form input::placeholder,
#upload-form textarea::placeholder {
  color: #6f8576;
}

#upload-form input:focus,
#upload-form textarea:focus,
#upload-form select:focus {
  outline: none;
  border-color: var(--neon);
  box-shadow: 0 0 12px var(--neon-soft);
}

#upload-form input[type="file"] {
  background: #0a0f16;
}

/* ---------- Upload Button ---------- */

#upload-form button {
  margin-top: 10px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid var(--neon);
  background: transparent;
  color: var(--neon);
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
  box-shadow: 0 0 16px var(--neon-soft);
}

#upload-form button:hover {
  background: rgba(57,255,20,0.08);
  box-shadow: 0 0 26px var(--neon);
}

/* ---------- Product List ---------- */

.product-list-container {
  max-width: 1200px;
  margin: 0 auto 60px;
}

.product-list-container h2 {
  text-align: center;
  margin-bottom: 26px;
  color: var(--neon);
  font-size: 1.3rem;
  text-shadow: 0 0 12px var(--neon-soft);
}

/* ---------- Product Grid ---------- */

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 22px;
}

/* ---------- Product Cards ---------- */

.product-card {
  background: linear-gradient(
    180deg,
    var(--panel-dark),
    var(--panel-darker)
  );
  border-radius: 16px;
  padding: 16px;
  text-align: center;
  border: 1px solid var(--border-dark);
  box-shadow: 0 6px 16px rgba(0,0,0,0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.product-card:hover {
  transform: translateY(-6px);
  box-shadow:
    0 10px 26px rgba(0,0,0,0.5),
    0 0 18px var(--neon-soft);
}

.product-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 10px;
}

.product-card h3 {
  margin: 8px 0 4px;
  font-size: 0.95rem;
  color: var(--neon);
}

.product-card p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}


/* ================================
   EDIT PRODUCT MODAL
================================ */

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
}

.modal.hidden {
  display: none;
}

.modal-content {
  background: #ffffff;
  width: 100%;
  max-width: 420px;
  padding: 1.5rem;
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.25);
  animation: popIn 0.2s ease-out;
}

@keyframes popIn {
  from {
    transform: scale(0.95);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.modal-content h3 {
  margin-bottom: 1rem;
  color: #2e7d32;
  text-align: center;
}

/* Inputs */
.modal-content input,
.modal-content textarea,
.modal-content select {
  width: 100%;
  padding: 0.6rem;
  margin-bottom: 0.7rem;
  border-radius: 8px;
  border: 1px solid #ccc;
  font-size: 0.95rem;
}

.modal-content textarea {
  resize: vertical;
  min-height: 70px;
}

/* Buttons */
.modal-actions {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
}

#save-edit {
  background: #4CAF50;
  color: #fff;
  border: none;
  padding: 0.6rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  flex: 1;
}

#cancel-edit {
  background: #e0e0e0;
  border: none;
  padding: 0.6rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  flex: 1;
}

#save-edit:hover {
  background: #43a047;
}

#cancel-edit:hover {
  background: #d5d5d5;
}

/* ================================
   SELLER REVENUE SECTION
================================ */

.seller-revenue {
  max-width: 1200px;
  margin: 40px auto 80px;
  padding: 30px;
  background: linear-gradient(
    180deg,
    var(--panel-dark),
    var(--panel-darker)
  );
  border-radius: 18px;
  border: 1px solid var(--border-dark);
  box-shadow: 0 0 28px rgba(0,0,0,0.6);
}

.seller-revenue h2 {
  text-align: center;
  margin-bottom: 30px;
  color: var(--neon);
  text-shadow: 0 0 14px var(--neon-soft);
}

.revenue-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 22px;
}

.revenue-card {
  background: #080c12;
  border: 1px solid var(--border-dark);
  border-radius: 14px;
  padding: 24px;
  text-align: center;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.02);
}

.revenue-card h4 {
  margin-bottom: 10px;
  color: var(--text-muted);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.revenue-card p {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--neon);
  text-shadow: 0 0 12px var(--neon-soft);
}


/* ---------- Mobile ---------- */

@media (max-width: 768px) {
  body.upload-page {
    padding: 20px 12px;
  }

  #upload-form-section {
    padding: 22px;
    margin-top: 70px;
  }

  #upload-form-section h2 {
    font-size: 1.2rem;
  }

  .product-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }
}
