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

html,
body {
  height: 100%;
}

/* Page fade transition for redirects */
html {
  transition: opacity 0.3s ease-in-out;
}

html.fade-out {
  opacity: 0;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: #111827;
  background: radial-gradient(circle at top, #fce7f3 0, #f3f4f6 45%, #e0f2fe 100%);
  display: flex;
  flex-direction: column;
  animation: fadeIn 0.4s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

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

a:hover {
  text-decoration: underline;
}

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

main {
  padding: 96px 16px 40px;
  max-width: 1120px;
  margin: 0 auto;
  flex: 1;
}

.page-main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 96px 16px 40px;
  flex: 1;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: #ffffffcc;
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #e5e7eb;
}

.nav-container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.logo {
  font-weight: 700;
  font-size: 1rem;
  color: #16a34a;
  white-space: nowrap;
  transition: transform 0.2s ease, color 0.2s ease;
  display: inline-block;
}

.logo:hover {
  transform: scale(1.05);
  color: #15803d;
}

.nav-links {
  display: flex;
  gap: 12px;
  font-size: 0.95rem;
  flex: 1;
  justify-content: center;
}

.nav-links a {
  padding: 6px 10px;
  border-radius: 999px;
  color: #374151;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.nav-links a::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(22, 163, 74, 0.1);
  transform: translate(-50%, -50%);
  transition: width 0.4s ease, height 0.4s ease;
}

.nav-links a:hover::before {
  width: 200px;
  height: 200px;
}

.nav-links a:hover {
  background: #e5e7eb;
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.nav-links a.active {
  background: #16a34a1a;
  color: #16a34a;
  font-weight: 600;
}

.nav-links a.active:hover {
  background: #16a34a26;
  transform: translateY(-1px);
}

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

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

.btn-primary,
.btn-secondary,
.btn-ghost {
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-size: 0.9rem;
  padding: 8px 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: #16a34a;
  color: #ffffff;
  box-shadow: 0 8px 20px rgba(22, 163, 74, 0.25);
  transform: translateY(0);
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transform: translate(-50%, -50%);
  transition: width 0.5s ease, height 0.5s ease;
}

.btn-primary:hover::before {
  width: 300px;
  height: 300px;
}

.btn-primary:hover {
  background: #15803d;
  text-decoration: none;
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 12px 28px rgba(22, 163, 74, 0.35);
}

.btn-primary:active {
  transform: translateY(0) scale(0.98);
  transition: all 0.1s ease;
}

.btn-secondary {
  background: #e5e7eb;
  color: #111827;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.btn-secondary:hover {
  background: #d1d5db;
  text-decoration: none;
  transform: translateY(-1px) scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.btn-secondary:active {
  transform: translateY(0) scale(0.98);
  transition: all 0.1s ease;
}

.btn-ghost {
  background: transparent;
  color: #4b5563;
}

.btn-ghost:hover {
  background: #e5e7eb;
  transform: translateY(-1px);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 2.1fr) minmax(0, 1.4fr);
  gap: 32px;
  align-items: center;
}

.hero-content h1 {
  font-size: 2.4rem;
  margin: 0 0 12px;
}

.hero-content p {
  margin: 0 0 20px;
  color: #4b5563;
  max-width: 36rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 8px;
}

.hero-sub {
  font-size: 0.9rem;
  color: #6b7280;
}

.link-inline {
  color: #16a34a;
  font-weight: 500;
  transition: all 0.2s ease;
  position: relative;
  display: inline-block;
}

.link-inline::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: #16a34a;
  transition: width 0.3s ease;
}

.link-inline:hover {
  text-decoration: none;
  color: #15803d;
  transform: translateX(2px);
}

.link-inline:hover::after {
  width: 100%;
}

.hero-side {
  display: flex;
  justify-content: flex-end;
}

.hero-card {
  background: #ffffff;
  border-radius: 20px;
  padding: 20px 22px;
  box-shadow: 0 24px 45px rgba(15, 23, 42, 0.12);
  max-width: 320px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  animation: slideInRight 0.6s ease-out;
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.hero-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 32px 60px rgba(15, 23, 42, 0.18);
}

.hero-card h2 {
  margin: 0 0 12px;
  font-size: 1.2rem;
}

.hero-list {
  margin: 0;
  padding-left: 16px;
  color: #4b5563;
  font-size: 0.95rem;
}

.steps {
  margin-top: 56px;
}

.steps h2 {
  margin-bottom: 12px;
}

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

.step-card {
  background: #ffffff;
  border-radius: 16px;
  padding: 16px 18px;
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
}

.step-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
  border-color: #bfdbfe;
}

.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: #dcfce7;
  color: #166534;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.featured {
  margin-top: 56px;
}

.section-header h2 {
  margin: 0 0 4px;
}

.section-header p {
  margin: 0 0 16px;
  color: #6b7280;
}

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

.category-card {
  background: #ffffff;
  border-radius: 16px;
  padding: 16px 18px;
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
  cursor: pointer;
}

.category-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.12);
  border-color: #16a34a;
  background: #f0fdf4;
}

.site-footer {
  border-top: 1px solid #e5e7eb;
  padding: 16px;
  text-align: center;
  font-size: 0.9rem;
  color: #6b7280;
  background: #ffffff;
}

.page-header h1 {
  margin: 0 0 8px;
}

.page-header p {
  margin: 0 0 20px;
  color: #6b7280;
}

.filters {
  margin-bottom: 12px;
}

.filters-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.9rem;
}

.field-grow {
  flex: 1;
}

label {
  color: #4b5563;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
select,
textarea {
  border-radius: 10px;
  border: 1px solid #d1d5db;
  padding: 8px 10px;
  font: inherit;
  background: #ffffff;
  transition: all 0.25s ease;
}

input:hover,
select:hover,
textarea:hover {
  border-color: #9ca3af;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #16a34a;
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.1), 0 2px 8px rgba(0, 0, 0, 0.05);
  transform: translateY(-1px);
}

textarea {
  resize: vertical;
}

.items-section {
  margin-top: 16px;
}

.items-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.item-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  animation: fadeInUp 0.5s ease-out;
  animation-fill-mode: both;
}

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

.item-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.15);
  border-color: #bfdbfe;
}

.item-card:nth-child(1) { animation-delay: 0.05s; }
.item-card:nth-child(2) { animation-delay: 0.1s; }
.item-card:nth-child(3) { animation-delay: 0.15s; }
.item-card:nth-child(4) { animation-delay: 0.2s; }
.item-card:nth-child(5) { animation-delay: 0.25s; }
.item-card:nth-child(6) { animation-delay: 0.3s; }

.item-image-placeholder {
  height: 130px;
  background: linear-gradient(135deg, #bbf7d0, #a5b4fc);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: #1f2937;
  font-weight: 600;
}

.item-image {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9ca3af;
  font-size: 0.9rem;
  flex-shrink: 0;
  transition: transform 0.4s ease, filter 0.4s ease;
}

.item-card:hover .item-image {
  transform: scale(1.05);
  filter: brightness(1.05);
}

.item-image.has-image {
  color: transparent;
}

.item-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

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

.item-title {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: #111827;
  flex: 1;
  line-height: 1.3;
}

.item-desc {
  margin: 0;
  font-size: 0.9rem;
  color: #6b7280;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.item-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  background: #f9fafb;
  border-radius: 10px;
  margin-top: auto;
}

.item-detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
}

.item-label {
  color: #6b7280;
  font-weight: 500;
}

.item-value {
  color: #111827;
  font-weight: 600;
  text-align: right;
}

.badge {
  display: inline-flex;
  padding: 2px 8px;
  border-radius: 999px;
  background: #e5e7eb;
  font-size: 0.75rem;
  color: #374151;
  flex-shrink: 0;
  transition: all 0.2s ease;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.8;
  }
}

.badge:hover {
  transform: scale(1.1);
}

.item-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  padding-top: 12px;
  border-top: 1px solid #e5e7eb;
}

.item-images-count {
  font-size: 0.8rem;
  color: #6b7280;
}

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

.item-actions .btn-secondary,
.item-actions .btn-primary {
  font-size: 0.85rem;
  padding: 8px 14px;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.25s ease;
}

.item-actions .btn-secondary:hover,
.item-actions .btn-primary:hover {
  transform: translateY(-2px) scale(1.05);
}

.item-actions .btn-secondary:active,
.item-actions .btn-primary:active {
  transform: translateY(0) scale(0.98);
}

.empty-state {
  padding: 18px;
  border-radius: 14px;
  background: #f9fafb;
  border: 1px dashed #d1d5db;
  color: #6b7280;
  text-align: center;
}

.form-card {
  background: #ffffff;
  border-radius: 18px;
  padding: 18px 18px 20px;
  border: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.field-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.form-actions {
  margin-top: 4px;
  display: flex;
  justify-content: flex-start;
}

.sell-success {
  margin: 8px 0 0;
  font-size: 0.9rem;
  color: #166534;
  background: #dcfce7;
  padding: 8px 10px;
  border-radius: 999px;
  display: none;
}

.item-upload-row {
  margin-top: 4px;
  font-size: 0.85rem;
  color: #6b7280;
}

.item-upload-label {
  font-weight: 500;
  color: #4b5563;
}

.item-upload-actions {
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.item-upload-status {
  font-size: 0.8rem;
  color: #6b7280;
}

.item-upload-preview {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.item-upload-thumb {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background-size: cover;
  background-position: center;
  border: 1px solid #e5e7eb;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.12);
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  animation: fadeInScale 0.3s ease-out;
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.item-upload-thumb:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.2);
  border-color: #16a34a;
}

.item-upload-thumb-remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: none;
  background: #ffffffdd;
  color: #4b5563;
  font-size: 0.7rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.3);
  transition: all 0.2s ease;
  opacity: 0.8;
}

.item-upload-thumb:hover .item-upload-thumb-remove {
  opacity: 1;
}

.item-upload-thumb-remove:hover {
  background: #fee2e2;
  color: #b91c1c;
  transform: scale(1.2) rotate(90deg);
  box-shadow: 0 4px 10px rgba(185, 28, 28, 0.4);
}

.item-upload-preview {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.item-upload-thumb {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background-size: cover;
  background-position: center;
  border: 1px solid #e5e7eb;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.12);
}

.info-banner {
  padding: 8px 10px;
  border-radius: 10px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 0.9rem;
  margin-bottom: 10px;
  display: none;
}

.mysales-list {
  margin-top: 20px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.mysales-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #e5e7eb;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  animation: fadeInUp 0.5s ease-out;
  animation-fill-mode: both;
}

.mysales-card:hover {
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.15);
  transform: translateY(-4px) scale(1.01);
  border-color: #bfdbfe;
}

.mysales-card:nth-child(1) { animation-delay: 0.05s; }
.mysales-card:nth-child(2) { animation-delay: 0.1s; }
.mysales-card:nth-child(3) { animation-delay: 0.15s; }
.mysales-card:nth-child(4) { animation-delay: 0.2s; }

.mysales-card-image {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9ca3af;
  font-size: 0.9rem;
  flex-shrink: 0;
  transition: transform 0.4s ease, filter 0.4s ease;
}

.mysales-card:hover .mysales-card-image {
  transform: scale(1.05);
  filter: brightness(1.05);
}

.mysales-card-image.has-image {
  color: transparent;
}

.mysales-card-body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 12px;
}

.mysales-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.mysales-card-title {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: #111827;
  flex: 1;
  line-height: 1.3;
}

.mysales-card-description {
  margin: 0;
  font-size: 0.9rem;
  color: #6b7280;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mysales-card-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  background: #f9fafb;
  border-radius: 10px;
  margin-top: auto;
}

.mysales-card-detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
}

.mysales-card-label {
  color: #6b7280;
  font-weight: 500;
}

.mysales-card-value {
  color: #111827;
  font-weight: 600;
  text-align: right;
}

.mysales-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
  padding-top: 12px;
  border-top: 1px solid #e5e7eb;
}

.mysales-card-images-count {
  font-size: 0.8rem;
  color: #6b7280;
}

.mysales-card-actions {
  display: flex;
  gap: 8px;
}

.mysales-card-actions .btn-primary,
.mysales-card-actions .btn-secondary {
  font-size: 0.85rem;
  padding: 8px 14px;
  white-space: nowrap;
  transition: all 0.25s ease;
}

.mysales-card-actions .btn-primary:hover,
.mysales-card-actions .btn-secondary:hover {
  transform: translateY(-2px) scale(1.05);
}

.mysales-card-actions .btn-primary:active,
.mysales-card-actions .btn-secondary:active {
  transform: translateY(0) scale(0.98);
}

.status-available {
  background: #fef9c3;
  color: #92400e;
}

.status-reserved {
  background: #dbeafe;
  color: #1d4ed8;
}

.status-paid {
  background: #dcfce7;
  color: #166534;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 24px;
}

.steps-list {
  padding-left: 18px;
  font-size: 0.95rem;
  color: #4b5563;
}

.steps-list li {
  margin-bottom: 10px;
}

.safety-list {
  padding-left: 18px;
  font-size: 0.95rem;
  color: #4b5563;
}

.safety-list li {
  margin-bottom: 8px;
}

.auth-main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 108px 16px 48px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex: 1;
}

.auth-card {
  background: #ffffff;
  border-radius: 18px;
  padding: 28px 26px 24px;
  border: 1px solid #e5e7eb;
  width: 100%;
  max-width: 430px;
  box-shadow: 0 22px 45px rgba(15, 23, 42, 0.22);
  position: relative;
  overflow: hidden;
  animation: authCardIn 0.5s ease-out;
}

.auth-card h1 {
  margin: 0 0 6px;
  font-size: 1.5rem;
}

.auth-card p {
  margin: 0 0 16px;
  color: #6b7280;
}

.auth-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, #bbf7d0 0, transparent 55%),
    radial-gradient(circle at bottom right, #bfdbfe 0, transparent 55%);
  opacity: 0.35;
  pointer-events: none;
}

.auth-card > * {
  position: relative;
  z-index: 1;
}

.toast {
  position: fixed;
  top: 88px;
  left: 50%;
  transform: translateX(-50%) translateY(-10px);
  padding: 11px 18px;
  border-radius: 14px;
  background: #16a34a;
  color: #ecfdf3;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 14px 35px rgba(22, 163, 74, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
  z-index: 60;
}

.toast.toast-error {
  background: #b91c1c;
  box-shadow: 0 14px 35px rgba(185, 28, 28, 0.45);
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.password-field label {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.password-input-wrapper {
  display: flex;
  align-items: center;
  gap: 6px;
  border-radius: 10px;
  border: 1px solid #d1d5db;
  background: #f9fafb;
  padding: 2px 6px 2px 10px;
}

.password-input-wrapper input[type="password"],
.password-input-wrapper input[type="text"] {
  border: none;
  background: transparent;
  padding: 6px 4px;
  flex: 1;
  outline: none;
}

.password-input-wrapper .lock-icon {
  font-size: 0.9rem;
  color: #9ca3af;
}

.toggle-password {
  border-radius: 999px;
  border: none;
  background: #e5e7eb;
  color: #4b5563;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  font-size: 0.9rem;
  transition: all 0.25s ease;
}

.toggle-password:hover {
  background: #d1d5db;
  transform: scale(1.1);
}

.toggle-password.is-active {
  background: #16a34a;
  color: #ffffff;
  transform: scale(1.05);
}

.toggle-password.is-active:hover {
  background: #15803d;
  transform: scale(1.15);
}

@keyframes authCardIn {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.auth-switch {
  margin-top: 14px;
  font-size: 0.9rem;
  color: #4b5563;
}

.auth-switch a {
  color: #16a34a;
}

.nav-user-trigger {
  border-radius: 999px;
  border: none;
  background: #e5e7eb;
  padding: 4px 10px 4px 4px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 0.9rem;
  color: #111827;
  transition: all 0.25s ease;
}

.nav-user-trigger:hover {
  background: #d1d5db;
  transform: translateY(-1px) scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.nav-avatar {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: linear-gradient(135deg, #bbf7d0, #22c55e);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 600;
  color: #064e3b;
  overflow: hidden;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 1px #d1fae5;
  background-size: cover;
  background-position: center;
}

.nav-user-trigger:hover .nav-avatar {
  transform: scale(1.03);
}

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

.profile-modal.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.profile-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  animation: fadeIn 0.3s ease;
}

.profile-dialog {
  position: relative;
  background: #ffffff;
  border-radius: 18px;
  padding: 22px 22px 24px;
  max-width: 440px;
  width: 100%;
  z-index: 10;
  box-shadow: 0 24px 55px rgba(15, 23, 42, 0.35);
  animation: authCardIn 0.4s ease-out;
  border: 1px solid #e5e7eb;
  overflow: hidden;
}

.profile-dialog::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, #bbf7d0 0, transparent 55%),
    radial-gradient(circle at bottom right, #bfdbfe 0, transparent 55%);
  opacity: 0.35;
  pointer-events: none;
}

.profile-dialog > * {
  position: relative;
  z-index: 1;
}

.profile-dialog h2 {
  margin: 0 0 4px;
}

.profile-text {
  margin: 0 0 14px;
  font-size: 0.9rem;
  color: #4b5563;
}

.profile-email-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 10px;
  border-radius: 10px;
  background: #f9fafb;
  border: 1px dashed #d1d5db;
  font-size: 0.85rem;
  color: #4b5563;
}

.profile-email-label {
  font-weight: 500;
}

.profile-email-value {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas,
    "Liberation Mono", "Courier New", monospace;
}

.profile-actions {
  justify-content: space-between;
  align-items: center;
}

.profile-upload-row {
  margin-top: 6px;
  font-size: 0.85rem;
  color: #6b7280;
}

.profile-upload-actions {
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.profile-upload-status {
  font-size: 0.8rem;
  color: #6b7280;
}

.profile-avatar-preview-wrap {
  display: flex;
  justify-content: center;
  margin: 8px 0 12px;
}

.profile-avatar-preview {
  width: 80px;
  height: 80px;
  font-size: 1.6rem;
}

.profile-actions .btn-logout {
  background: #fee2e2;
  color: #b91c1c;
  box-shadow: 0 4px 14px rgba(185, 28, 28, 0.15);
}

.profile-actions .btn-logout:hover {
  background: #fecaca;
  color: #991b1b;
  box-shadow: 0 6px 18px rgba(185, 28, 28, 0.25);
  text-decoration: none;
}

.notif-bell {
  position: relative;
  border: none;
  background: #f3f4f6;
  border-radius: 999px;
  padding: 6px 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.25s ease;
}

.notif-bell:hover {
  background: #e5e7eb;
  transform: translateY(-1px) scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.notif-bell:active {
  transform: scale(0.95);
}

.bell-icon {
  font-size: 1rem;
}

.notif-badge {
  min-width: 16px;
  height: 16px;
  border-radius: 999px;
  background: #ef4444;
  color: #ffffff;
  font-size: 0.7rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nav-user {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  color: #374151;
}

.notif-panel {
  position: fixed;
  right: 24px;
  top: 64px;
  width: 360px;
  max-width: calc(100vw - 48px);
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.25);
  border: 1px solid #e5e7eb;
  padding: 12px;
  display: none;
  z-index: 50;
  max-height: calc(100vh - 80px);
  overflow: hidden;
  flex-direction: column;
  opacity: 0;
  transform: translateY(-10px) scale(0.95);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.notif-panel.open {
  display: flex;
  opacity: 1;
  transform: translateY(0) scale(1);
}

.notif-header {
  padding-bottom: 8px;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 8px;
}

.notif-header h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: #111827;
}

.notif-list {
  max-height: calc(100vh - 160px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.notif-empty {
  font-size: 0.9rem;
  color: #6b7280;
  padding: 24px 12px;
  text-align: center;
}

.notif-item {
  border: none;
  background: #f9fafb;
  border-radius: 12px;
  padding: 10px;
  text-align: left;
  cursor: pointer;
  width: 100%;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.notif-item:hover {
  background: #f3f4f6;
  border-color: #e5e7eb;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.1);
}

.notif-item-chat {
  background: #eff6ff;
}

.notif-item-chat:hover {
  background: #dbeafe;
}

.notif-item-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.1);
}

.notif-item-content {
  flex: 1;
  min-width: 0;
}

.notif-item-main {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.875rem;
  margin-bottom: 4px;
}

.notif-item-title {
  font-weight: 600;
  color: #111827;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.notif-item-amount {
  font-weight: 700;
  color: #16a34a;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.notif-item-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  color: #6b7280;
  gap: 8px;
}

.notif-item-type {
  font-weight: 500;
  color: #16a34a;
  background: #dcfce7;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
  flex-shrink: 0;
}

.notif-item-chat .notif-item-type {
  color: #2563eb;
  background: #dbeafe;
}

.notif-item-purchase {
  background: #fef3c7;
}

.notif-item-purchase:hover {
  background: #fde68a;
}

.chat-window {
  position: fixed;
  right: 16px;
  bottom: 12px;
  width: 360px;
  max-width: 90vw;
  height: 500px;
  max-height: calc(100vh - 24px);
  border-radius: 16px 16px 10px 16px;
  background: #ffffff;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.24);
  border: 1px solid #e5e7eb;
  display: none;
  flex-direction: column;
  overflow: hidden;
  z-index: 70;
  opacity: 0;
  transform: translateY(20px) scale(0.95);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.chat-window.open {
  display: flex;
  opacity: 1;
  transform: translateY(0) scale(1);
  animation: slideUpIn 0.35s ease-out;
}

@keyframes slideUpIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 10px;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: #ecfdf3;
}

.chat-title {
  font-size: 0.9rem;
  font-weight: 600;
}

.chat-subtitle {
  font-size: 0.78rem;
  opacity: 0.9;
}

.chat-close {
  border: none;
  background: #bbf7d0;
  color: #064e3b;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.chat-close:hover {
  background: #a7f3d0;
  transform: rotate(90deg) scale(1.1);
}

.chat-messages {
  padding: 12px 10px;
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.85rem;
  background: #f9fafb;
  min-height: 0;
}

.chat-messages::-webkit-scrollbar {
  width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
  background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 3px;
}

.chat-messages::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

.chat-message {
  align-self: flex-start;
  max-width: 75%;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.chat-message-text {
  padding: 8px 12px;
  border-radius: 12px 12px 12px 4px;
  background: #e5e7eb;
  color: #111827;
  word-wrap: break-word;
  line-height: 1.4;
}

.chat-message.is-mine {
  align-self: flex-end;
}

.chat-message.is-mine .chat-message-text {
  border-radius: 12px 12px 4px 12px;
  background: #16a34a;
  color: #ecfdf3;
}

.chat-message-sender {
  font-size: 0.7rem;
  color: #6b7280;
  padding: 0 4px;
  font-weight: 500;
}

.chat-message.is-mine .chat-message-sender {
  text-align: right;
  color: #16a34a;
}

.chat-form {
  padding: 10px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-top: 1px solid #e5e7eb;
  background: #ffffff;
  flex-shrink: 0;
}

.chat-input {
  flex: 1;
  border-radius: 999px;
  border: 1px solid #d1d5db;
  padding: 6px 10px;
  font: inherit;
}

.chat-input:focus {
  outline: none;
  border-color: #16a34a;
  box-shadow: 0 0 0 1px #16a34a33;
}

.chat-send {
  padding-inline: 12px;
}

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

.purchase-confirm-modal.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.purchase-confirm-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  animation: fadeIn 0.3s ease;
}

.purchase-confirm-dialog {
  position: relative;
  background: #ffffff;
  border-radius: 18px;
  padding: 24px;
  max-width: 400px;
  width: 100%;
  z-index: 10;
  box-shadow: 0 24px 55px rgba(15, 23, 42, 0.35);
  border: 1px solid #e5e7eb;
  animation: authCardIn 0.4s ease-out;
}

.purchase-confirm-dialog h2 {
  margin: 0 0 12px;
  font-size: 1.25rem;
  color: #111827;
}

.purchase-confirm-message {
  margin: 0 0 20px;
  font-size: 1rem;
  color: #4b5563;
  text-align: center;
}

.purchase-confirm-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

.purchase-confirm-actions .btn-secondary,
.purchase-confirm-actions .btn-primary {
  padding: 10px 20px;
  font-size: 0.95rem;
}

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

.receipt-modal.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.receipt-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  animation: fadeIn 0.3s ease;
}

.receipt-dialog {
  position: relative;
  background: #ffffff;
  border-radius: 18px;
  padding: 20px 20px 18px;
  max-width: 420px;
  width: 100%;
  z-index: 10;
  box-shadow: 0 24px 55px rgba(15, 23, 42, 0.35);
}

.receipt-dialog h2 {
  margin: 0 0 10px;
}

.receipt-details {
  margin: 0 0 12px;
}

.receipt-details div {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  padding: 4px 0;
}

.receipt-details dt {
  font-weight: 500;
  color: #4b5563;
}

.receipt-details dd {
  margin: 0;
  color: #111827;
}

.receipt-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

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

.item-modal.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.item-modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  animation: fadeIn 0.3s ease;
}

.item-modal-dialog {
  position: relative;
  background: #ffffff;
  border-radius: 18px;
  padding: 16px 16px 18px;
  max-width: 720px;
  width: 100%;
  z-index: 10;
  box-shadow: 0 24px 55px rgba(15, 23, 42, 0.35);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 16px;
}

.item-gallery {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: #f3f4f6;
}

.item-gallery-main {
  height: 260px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: #4b5563;
}

.item-gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border-radius: 999px;
  border: none;
  background: #ffffffdd;
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.25);
  transition: all 0.25s ease;
}

.item-gallery-nav:hover {
  background: #ffffff;
  transform: translateY(-50%) scale(1.15);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.35);
}

.item-gallery-nav:active {
  transform: translateY(-50%) scale(0.95);
}

.item-gallery-prev {
  left: 10px;
}

.item-gallery-next {
  right: 10px;
}

.item-modal-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.item-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}

.item-modal-title {
  margin: 0;
  font-size: 1.2rem;
}

.item-modal-price {
  font-weight: 600;
  color: #16a34a;
}

.item-modal-meta {
  margin: 0;
  font-size: 0.85rem;
  color: #6b7280;
}

.item-modal-desc {
  margin: 4px 0 0;
  font-size: 0.9rem;
  color: #4b5563;
}

.item-modal-actions {
  margin-top: auto;
  display: flex;
  justify-content: flex-end;
}

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

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

.forgot-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
}

.forgot-dialog {
  position: relative;
  background: #ffffff;
  border-radius: 18px;
  padding: 18px 18px 20px;
  max-width: 420px;
  width: 100%;
  z-index: 10;
  box-shadow: 0 22px 50px rgba(15, 23, 42, 0.4);
  animation: forgotIn 0.32s ease-out;
}

.forgot-dialog h2 {
  margin: 0 0 6px;
}

.forgot-text {
  margin: 0 0 12px;
  font-size: 0.9rem;
  color: #4b5563;
}

.forgot-password {
  margin-top: 8px;
  font-size: 0.9rem;
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
}

.forgot-password:hover {
  text-decoration: underline;
}

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

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

.edit-item-modal.open {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.edit-item-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  animation: fadeIn 0.3s ease;
}

.edit-item-dialog {
  position: relative;
  background: #ffffff;
  border-radius: 18px;
  padding: 22px 22px 24px;
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  z-index: 10;
  box-shadow: 0 24px 55px rgba(15, 23, 42, 0.35);
  animation: authCardIn 0.4s ease-out;
  border: 1px solid #e5e7eb;
}

.edit-item-dialog h2 {
  margin: 0 0 4px;
}

.edit-item-text {
  margin: 0 0 14px;
  font-size: 0.9rem;
  color: #4b5563;
}

.edit-item-upload-preview {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.edit-item-upload-status {
  font-size: 0.8rem;
  color: #6b7280;
}

@media (max-width: 768px) {
  .nav-container {
    flex-wrap: wrap;
  }

  .nav-links {
    order: 3;
    justify-content: flex-start;
    overflow-x: auto;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-side {
    justify-content: flex-start;
  }

  .two-column {
    grid-template-columns: minmax(0, 1fr);
  }

  .item-footer {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .item-images-count {
    text-align: center;
  }

  .item-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .item-actions .btn-secondary,
  .item-actions .btn-primary {
    flex: 1;
    min-width: 0;
  }

  .chat-window {
    width: calc(100vw - 32px);
    height: calc(100vh - 24px);
    max-height: calc(100vh - 24px);
    right: 16px;
    bottom: 12px;
  }

  .edit-item-dialog {
    max-width: calc(100vw - 32px);
    max-height: calc(100vh - 24px);
  }

  .notif-panel {
    width: calc(100vw - 48px);
    right: 24px;
    max-height: calc(100vh - 80px);
  }

  .mysales-list {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .mysales-card-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .mysales-card-actions {
    width: 100%;
  }

  .mysales-card-actions .btn-primary,
  .mysales-card-actions .btn-secondary {
    width: 100%;
  }

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

/* Tablet view - 2 columns */
@media (min-width: 769px) and (max-width: 1024px) {
  .items-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Small desktop - 3 columns */
@media (min-width: 1025px) and (max-width: 1280px) {
  .items-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}


