:root {
  --color-bg: #0f172a;
  --color-surface: #111827;
  --color-surface-alt: #020617;
  --color-border: #1f2937;
  --color-accent: #3b82f6;
  --color-accent-soft: rgba(59, 130, 246, 0.15);
  --color-text: #e5e7eb;
  --color-text-muted: #9ca3af;
  --color-danger: #ef4444;
  --radius-lg: 16px;
  --radius-md: 10px;
  --shadow-soft: 0 22px 45px rgba(15, 23, 42, 0.85);
}

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

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: radial-gradient(160% 160% at top, #1d4ed8 0%, #020617 45%, #020617 100%);
  color: var(--color-text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: var(--color-accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.site-header {
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  backdrop-filter: blur(24px);
  background: linear-gradient(to bottom, rgba(15, 23, 42, 0.85), transparent);
  position: sticky;
  top: 0;
  z-index: 10;
}

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

.logo {
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #ffffff;
  text-decoration: none;
  font-size: 1.5rem;
}

.nav-links {
  display: flex;
  gap: 1rem;
  align-items: center;
  font-size: 0.95rem;
}

.nav-links a {
  color: #ffffff;
  text-decoration: none;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-links a:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.nav-user {
  color: #ffffff;
}

.nav-user-link {
  display: inline-flex;
  align-items: center;
}
.nav-user-link:hover {
  text-decoration: none;
}

.nav-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  border: 2px solid var(--color-border);
}
.nav-user-link:hover .nav-avatar {
  border-color: var(--color-accent);
}

.nav-user-text {
  color: inherit;
}

.nav-inbox-link {
  position: relative;
}

.nav-inbox-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.35rem;
  margin-left: 0.25rem;
  font-size: 0.7rem;
  font-weight: 600;
  color: #fef2f2;
  background: #dc2626;
  border-radius: 999px;
  vertical-align: middle;
}

.nav-logout-form {
  display: inline;
  margin: 0;
}

.nav-link-btn {
  background: none;
  border: none;
  color: #ffffff;
  font-size: inherit;
  font-family: inherit;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-link-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.site-main-wrap {
  display: flex;
  flex: 1;
  gap: 0;
  min-width: 0;
}

.site-sidebar {
  flex-shrink: 0;
  width: 220px;
  padding: 2rem 1rem 2rem 1.25rem;
}

.site-sidebar-left {
  padding-left: 1.25rem;
}

.site-sidebar-right {
  padding-right: 1.25rem;
}

.advert-panel {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.advert-card {
  background: linear-gradient(145deg, var(--color-surface), var(--color-surface-alt));
  border-radius: var(--radius-md);
  border: 1px solid rgba(148, 163, 184, 0.25);
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.6);
}

.advert-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.advert-card-link:hover .advert-card-title {
  text-decoration: underline;
}

.advert-card-image {
  width: 100%;
  height: 120px;
  object-fit: cover;
  display: block;
}

.advert-card-body {
  padding: 0.65rem 0.75rem 0.75rem;
}

.advert-card-title {
  margin: 0 0 0.25rem;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.3;
}

.advert-card-desc {
  margin: 0;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  line-height: 1.4;
}

.site-main {
  padding: 2.5rem 0 3rem;
  flex: 1;
  min-width: 0;
}

@media (max-width: 900px) {
  .site-sidebar-left,
  .site-sidebar-right {
    display: none;
  }
}

.site-footer {
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  padding: 1.25rem 0 1.75rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  background: radial-gradient(120% 230% at bottom, #020617 10%, #020617 70%, #020617 100%);
}

.site-footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.site-footer-copy {
  margin: 0;
}

.site-footer-links {
  margin: 0;
}

.site-footer-links a {
  color: var(--color-text-muted);
}

.site-footer-links a:hover {
  color: var(--color-text);
}

.site-footer-links span {
  margin: 0 0.35rem;
  color: var(--color-text-muted);
}

.site-message {
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  border-radius: var(--radius-md);
  background: var(--color-accent-soft);
  border: 1px solid rgba(59, 130, 246, 0.35);
}

.site-message-text {
  margin: 0;
  font-size: 0.95rem;
  color: var(--color-text);
  line-height: 1.4;
}

.hero {
  padding: 2rem;
  border-radius: 24px;
  background: radial-gradient(circle at top left, rgba(59, 130, 246, 0.18), transparent 55%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.98));
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: var(--shadow-soft);
  margin-bottom: 2.5rem;
}

.hero h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.9rem, 3.2vw, 2.4rem);
}

.hero p {
  margin: 0 0 1.5rem;
  color: var(--color-text-muted);
  max-width: 520px;
}

.search-form {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
  max-width: 420px;
}

.search-input {
  flex: 1;
  padding: 0.55rem 0.75rem;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.9);
  color: var(--color-text);
  font-size: 0.95rem;
}

.search-input:focus {
  outline: none;
  border-color: var(--color-accent);
}

.search-results-meta {
  margin: 0 0 1rem;
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

.nav-search-form {
  display: flex;
  gap: 0.25rem;
  align-items: center;
}

.nav-search-input {
  width: 120px;
  padding: 0.35rem 0.5rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.8);
  color: var(--color-text);
  font-size: 0.85rem;
}

.nav-search-input::placeholder {
  color: var(--color-text-muted);
}

.nav-search-input:focus {
  outline: none;
  border-color: var(--color-accent);
}

.nav-search-btn {
  padding: 0.35rem 0.6rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.8);
  color: var(--color-text-muted);
  font-size: 0.85rem;
  cursor: pointer;
}

.nav-search-btn:hover {
  background: rgba(148, 163, 184, 0.16);
  color: #e5e7eb;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.3rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  background: rgba(15, 23, 42, 0.8);
  color: var(--color-text);
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease, border-color 0.12s ease;
}

.btn-primary {
  background: linear-gradient(120deg, #3b82f6, #2563eb);
  box-shadow: 0 18px 40px rgba(37, 99, 235, 0.5);
  color: #e5e7eb;
}

.btn-danger {
  background: linear-gradient(120deg, #dc2626, #b91c1c);
  box-shadow: 0 18px 40px rgba(185, 28, 28, 0.4);
  color: #fef2f2;
}

.btn-danger:hover {
  background: linear-gradient(120deg, #ef4444, #dc2626);
  box-shadow: 0 18px 42px rgba(220, 38, 38, 0.5);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.9);
  text-decoration: none;
}

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

.pagination {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
}
.pagination-info {
  margin: 0;
  color: var(--color-text-muted);
  font-size: 0.95rem;
}
.pagination-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 0.5rem;
}
.pagination-links li {
  margin: 0;
}

.card {
  background: linear-gradient(145deg, var(--color-surface), var(--color-surface-alt));
  border-radius: var(--radius-lg);
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.card-image-wrap {
  position: relative;
}

.card-sold-badge {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  padding: 0.25rem 0.6rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #fef2f2;
  background: #b91c1c;
  border-radius: 999px;
}

.card-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
  background-color: #020617;
}

.card-sold-label {
  color: var(--color-text-muted);
  font-weight: normal;
}

.card-image--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  font-size: 0.9rem;
  background: radial-gradient(circle at top, #1f2937, #020617);
}

.card-body {
  padding: 1rem 1.1rem 1.1rem;
}

.card-title {
  margin: 0 0 0.25rem;
  font-size: 1rem;
}

.card-title a {
  color: #e5e7eb;
  text-decoration: none;
}

.card-title a:hover {
  text-decoration: underline;
}

.card-price {
  margin: 0 0 0.35rem;
  font-weight: 600;
}

.card-meta {
  margin: 0;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.panel {
  background: linear-gradient(130deg, var(--color-surface), var(--color-surface-alt));
  border-radius: 20px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  padding: 1.75rem 1.5rem;
  box-shadow: var(--shadow-soft);
}

.panel-narrow {
  max-width: 480px;
  margin: 0 auto;
}

.layout-two-column {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1.4fr);
  gap: 1.75rem;
}

@media (max-width: 800px) {
  .layout-two-column {
    grid-template-columns: minmax(0, 1fr);
  }
}

.item-detail-gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.item-detail-gallery .detail-image {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  flex-shrink: 0;
}

.item-detail-gallery a {
  display: block;
  line-height: 0;
}

.item-detail-gallery a:hover .detail-image {
  opacity: 0.9;
}

.detail-image {
  width: 100%;
  border-radius: 16px;
  margin-bottom: 1rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.detail-price {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0.25rem 0 0.5rem;
}

.detail-meta {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.detail-description {
  margin-top: 0.5rem;
  line-height: 1.6;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  border: 1px solid rgba(148, 163, 184, 0.5);
  margin-top: 0.75rem;
}

.badge-muted {
  background: rgba(148, 163, 184, 0.1);
  color: var(--color-text-muted);
}

.form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.form p {
  margin: 0;
}

.form label {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.form input[type="text"],
.form input[type="email"],
.form input[type="password"],
.form input[type="number"],
.form textarea {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.9);
  color: var(--color-text);
  padding: 0.55rem 0.75rem;
  font-size: 0.95rem;
}

.form input:focus,
.form textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 1px var(--color-accent-soft);
}

.form-footer {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.form-hint {
  display: block;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-top: 0.25rem;
}

.form-file {
  width: 100%;
  padding: 0.35rem 0;
}

.item-form-image-list {
  list-style: none;
  padding: 0;
  margin: 0.5rem 0 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.item-form-thumb {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.35);
}

.form-actions {
  margin-top: 1.25rem;
}

.form-actions-inner {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.messages {
  margin-bottom: 1.25rem;
}

.message {
  border-radius: 999px;
  padding: 0.4rem 0.9rem;
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  background: rgba(22, 163, 74, 0.16);
  border: 1px solid rgba(22, 163, 74, 0.5);
}

.message-error,
.message-danger {
  background: rgba(239, 68, 68, 0.16);
  border-color: rgba(239, 68, 68, 0.55);
}

.list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.list-item {
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.25);
}

.list-item:last-child {
  border-bottom: none;
}

.list-title {
  margin: 0 0 0.25rem;
  font-weight: 500;
}

.list-subtitle {
  margin: 0 0 0.35rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.list-body {
  margin: 0;
  line-height: 1.55;
}

.blog-intro {
  color: var(--color-text-muted);
  margin: 0 0 1.25rem;
}

.blog-teaser {
  padding: 1.25rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.25);
}

.blog-teaser:last-child {
  border-bottom: none;
}

.blog-teaser-title {
  margin: 0 0 0.35rem;
  font-size: 1.25rem;
}

.blog-teaser-title a {
  color: #e5e7eb;
  text-decoration: none;
}

.blog-teaser-title a:hover {
  text-decoration: underline;
}

.blog-teaser-meta {
  margin: 0 0 0.5rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.blog-teaser-excerpt {
  margin: 0 0 0.75rem;
  line-height: 1.55;
  color: var(--color-text-muted);
}

.blog-detail-image {
  width: 100%;
  max-height: 400px;
  object-fit: cover;
  display: block;
  margin-bottom: 1rem;
  border-radius: var(--radius-md);
}

.blog-teaser-image-wrap {
  display: block;
  margin-bottom: 0.75rem;
}
.blog-teaser-image {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  display: block;
  border-radius: var(--radius-md);
}

.blog-content {
  line-height: 1.65;
  margin-top: 0.5rem;
}

.list-title-meta {
  font-weight: normal;
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.conversation-messages {
  margin: 1.5rem 0;
  padding: 1rem 0;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
}

.conversation-message {
  margin-bottom: 1.25rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  max-width: 85%;
}

.conversation-message--sent {
  margin-left: auto;
  background: rgba(59, 130, 246, 0.2);
  border: 1px solid rgba(59, 130, 246, 0.4);
}

.conversation-message--received {
  background: rgba(148, 163, 184, 0.12);
  border: 1px solid rgba(148, 163, 184, 0.3);
}

.conversation-message-meta {
  margin: 0 0 0.35rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.conversation-message-body {
  margin: 0;
  line-height: 1.5;
}

.conversation-empty {
  color: var(--color-text-muted);
  font-style: italic;
  margin: 1rem 0;
}

.conversation-reply {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
}

.conversation-reply h2 {
  margin: 0 0 0.75rem;
  font-size: 1.1rem;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0 2rem;
}

.dashboard-card {
  padding: 1.25rem;
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-md);
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.dashboard-card-title {
  margin: 0 0 0.75rem;
  font-size: 1.1rem;
}

.dashboard-card p {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
  color: var(--color-text-muted);
}

.dashboard-card p:last-child {
  margin-top: 0.75rem;
  margin-bottom: 0;
}

.dashboard-section {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
}

.dashboard-section-title {
  margin: 0 0 0.5rem;
  font-size: 1.2rem;
}

.dashboard-item-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
}

.dashboard-item-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

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

.dashboard-item-thumb {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.6);
}

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

.dashboard-item-thumb--placeholder {
  color: var(--color-text-muted);
  font-size: 1.25rem;
  text-decoration: none;
}

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

.dashboard-item-info a {
  display: block;
  font-weight: 500;
  margin-bottom: 0.15rem;
}

.dashboard-item-meta {
  display: block;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.dashboard-item-actions {
  flex-shrink: 0;
  display: flex;
  gap: 0.5rem;
}

.member-profile-subtitle {
  margin: 1rem 0 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text-muted);
}

.member-profile-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}
.member-profile-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--color-border);
}
.member-profile-title-with-avatar {
  margin: 0;
}

.member-bio {
  margin: 0;
  line-height: 1.6;
}

.member-profile-actions {
  margin-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.panel-divider {
  border: none;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
  margin: 1.5rem 0 1rem;
}

.review-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
}

.review-item {
  padding: 1rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.review-item:last-child {
  border-bottom: none;
}

.review-meta {
  margin: 0 0 0.25rem;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.review-item-context {
  margin: 0 0 0.5rem;
  font-size: 0.85rem;
}

.review-content {
  margin: 0;
  line-height: 1.5;
}

@media (max-width: 640px) {
  .hero {
    padding: 1.5rem 1.25rem;
  }

  .header-inner {
    padding-inline: 0.25rem;
  }

  .nav-links {
    gap: 0.5rem;
    font-size: 0.85rem;
  }
}

