:root {
  --bg: #0b0f14;
  --card: rgba(255, 255, 255, 0.06);
  --card2: rgba(255, 255, 255, 0.08);
  --text: rgba(255, 255, 255, 0.92);
  --muted: rgba(255, 255, 255, 0.68);
  --border: rgba(255, 255, 255, 0.10);
  --accent: #d4af6a;
  --danger: #ff6b6b;
  --ok: #55efc4;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, "Noto Sans",
    "Helvetica Neue", sans-serif;
  background: radial-gradient(1200px 500px at 20% -10%, rgba(212, 175, 106, 0.18), transparent 60%),
    radial-gradient(1000px 500px at 90% 0%, rgba(255, 255, 255, 0.10), transparent 55%),
    var(--bg);
  color: var(--text);
}

a {
  color: inherit;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px 16px 42px;
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand img {
  width: 44px;
  height: 44px;
  display: block;
  padding: 0;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  object-fit: contain;
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.45));
}

.brand h1 {
  margin: 0;
  font-size: 18px;
  letter-spacing: 0.3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand p {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 12px;
}

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

.btn {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 12px;
  text-decoration: none;
  font-size: 13px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.btn:hover {
  background: rgba(255, 255, 255, 0.09);
}

.btn:active {
  transform: translateY(0.5px);
}

.btn.primary {
  border-color: rgba(212, 175, 106, 0.35);
  background: rgba(212, 175, 106, 0.10);
  margin-top: 15px;
}

.btn.danger {
  border-color: rgba(255, 107, 107, 0.35);
  background: rgba(255, 107, 107, 0.10);
}

.hero {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  padding: 18px 16px;
  background: linear-gradient(135deg, rgba(212, 175, 106, 0.14), rgba(255, 255, 255, 0.04));
  border: 1px solid var(--border);
  border-radius: 18px;
  margin-bottom: 16px;
  overflow: hidden;
}

.hero h2 {
  margin: 0;
  font-size: 22px;
  letter-spacing: 0.2px;
}

.hero p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.55;
  font-size: 13px;
}

.hero-card {
  background: rgba(0, 0, 0, 0.30);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 14px;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.stat {
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.10);
}

.stat .k {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.60);
}

.stat .v {
  margin-top: 6px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  margin-bottom: 16px;
}

.loadmore {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 14px;
}

.spinner {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  border: 2px solid rgba(255, 255, 255, 0.20);
  border-top-color: rgba(212, 175, 106, 0.95);
  animation: spin 650ms linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.search {
  flex: 1;
  display: flex;
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.search input {
  flex: 1;
  min-width: 0;
  padding: 12px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.10);
  color: var(--text);
  outline: none;
}

.search input::placeholder {
  color: rgba(255, 255, 255, 0.45);
}

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

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

.card.selected {
  outline: 2px solid rgba(212, 175, 106, 0.55);
  outline-offset: 2px;
}

.select-btn.is-selected {
  border-color: rgba(212, 175, 106, 0.45);
  background: rgba(212, 175, 106, 0.14);
}

.leadbar {
  position: sticky;
  bottom: 12px;
  z-index: 20;
  margin-top: 14px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(10, 14, 20, 0.85);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

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

.leadbar-title {
  font-weight: 700;
  font-size: 13px;
}

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

.card {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: var(--card);
}

.thumb {
  aspect-ratio: 4 / 3;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
  display: grid;
  place-items: center;
  overflow: hidden;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.01);
  transition: transform 250ms ease;
}

.card:hover .thumb img {
  transform: scale(1.06);
}

.content {
  padding: 12px 12px 14px;
}

.title {
  margin: 0;
  font-size: 14px;
  font-weight: 650;
  letter-spacing: 0.2px;
}

.desc,
.item .small {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
  display: -webkit-box;
  line-clamp: 2;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.10);
  box-shadow: 0 14px 50px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(10px);
  padding: 10px;
}

.empty {
  padding: 24px;
  border-radius: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  text-align: center;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.68);
  z-index: 50;
}

.modal.open {
  display: flex;
}

.modal-card {
  width: min(980px, 100%);
  background: rgba(15, 19, 26, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.45);
}

.modal-top {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
}

.modal-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.modal-title {
  margin: 0;
  font-size: 14px;
  color: var(--text);
}

.modal-close {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text);
  padding: 9px 12px;
  border-radius: 12px;
  cursor: pointer;
}

.modal-body {
  display: grid;
  grid-template-columns: 1fr;
}

.modal-media {
  background: rgba(255, 255, 255, 0.03);
  display: grid;
  place-items: center;
}

.modal-media img {
  max-width: 100%;
  max-height: 75vh;
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
  touch-action: none;
}

.modal-info {
  padding: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.10);
}

.modal-info p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.field label {
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
  letter-spacing: 0.15px;
}

.field input,
.field textarea {
  width: 100%;
  padding: 12px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.10);
  color: var(--text);
  outline: none;
}

.field input:focus,
.field textarea:focus {
  border-color: rgba(212, 175, 106, 0.35);
  box-shadow: 0 0 0 4px rgba(212, 175, 106, 0.10);
}

.field input[type="file"] {
  padding: 10px;
  cursor: pointer;
  width: 100%;
  max-width: 100%;
  background: rgba(0, 0, 0, 0.20);
}

.field .muted {
  margin-top: 6px;
  display: block;
  line-height: 1.4;
}

textarea {
  min-height: 96px;
  resize: vertical;
}

.note {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
}

.notice {
  padding: 12px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  font-size: 13px;
}

.notice.ok {
  border-color: rgba(85, 239, 196, 0.35);
  background: rgba(85, 239, 196, 0.10);
  color: rgba(255, 255, 255, 0.92);
}

.notice.err {
  border-color: rgba(255, 107, 107, 0.35);
  background: rgba(255, 107, 107, 0.10);
  color: rgba(255, 255, 255, 0.92);
}

.errlist {
  margin: 8px 0 0;
  padding-left: 18px;
}

.muted {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

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

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

button[type="submit"] {
  cursor: pointer;
}

.section-title {
  margin: 0;
  font-size: 14px;
  letter-spacing: 0.2px;
  color: rgba(255, 255, 255, 0.88);
}

.split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.items {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 14px;
}

.item {
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.item .thumb {
  aspect-ratio: 4 / 3;
  background: rgba(255, 255, 255, 0.03);
  overflow: hidden;
}

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

.item .body {
  padding: 12px;
}

.item .name {
  margin: 0;
  font-size: 13px;
  font-weight: 650;
}

.item .actions {
  margin-top: 10px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
