/* ============================================================
   VideoHub UI Polish - 全局样式 (white theme for video site)
   ============================================================ */

:root {
  --ui-bg: #ffffff;
  --ui-surface: #ffffff;
  --ui-text: #1a1a1a;
  --ui-muted: #888888;
  --ui-line: #e0e0e0;
  --ui-primary: #3ea6ff;
  --ui-primary-dark: #1a73e8;
  --ui-primary-light: #e8f0fe;
  --ui-success: #2ecc71;
  --ui-warning: #f39c12;
  --ui-danger: #e74c3c;
  --ui-accent: #3ea6ff;
  --ui-shadow: 0 14px 34px rgba(0, 0, 0, .08);
  --ui-shadow-sm: 0 2px 8px rgba(0, 0, 0, .06);
  --ui-radius: 10px;
  --ui-transition: .2s cubic-bezier(.4, 0, .2, 1);
}

* {
  box-sizing: border-box;
}

body {
  color: var(--ui-text);
  background: #f8f9fa;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.55;
  margin: 0;
}

/* ===== Headings ===== */
h1, h2, h3 {
  color: var(--ui-text);
  letter-spacing: -.01em;
}

h2 {
  font-weight: 700;
}

/* ===== Buttons ===== */
.button,
button,
input[type="submit"] {
  border: 0;
  border-radius: 8px;
  background: var(--ui-primary);
  color: #fff;
  cursor: pointer;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(62, 166, 255, .20);
  transition: transform var(--ui-transition), box-shadow var(--ui-transition), background var(--ui-transition);
  padding: 8px 16px;
  font-size: 14px;
  display: inline-block;
}

.button:hover,
button:hover,
input[type="submit"]:hover {
  background: var(--ui-primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(62, 166, 255, .30);
}

.button:active,
button:active {
  transform: translateY(0);
}

.button.secondary {
  background: #6c757d;
  box-shadow: 0 4px 14px rgba(108, 117, 125, .20);
}

.button.secondary:hover {
  background: #5a6268;
}

.button.danger,
.btn-delete,
.delete {
  background: var(--ui-danger);
  box-shadow: 0 4px 14px rgba(231, 76, 60, .20);
}

.button.danger:hover,
.btn-delete:hover,
.delete:hover {
  background: #c0392b;
}

/* ===== Inputs ===== */
input,
select,
textarea {
  border: 1.5px solid var(--ui-line);
  border-radius: 8px;
  background: #fff;
  color: var(--ui-text);
  padding: 10px 14px;
  outline: none;
  transition: border-color var(--ui-transition), box-shadow var(--ui-transition);
  font-family: inherit;
  font-size: 14px;
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(62, 166, 255, .6);
  box-shadow: 0 0 0 4px rgba(62, 166, 255, .12);
}

input::placeholder,
textarea::placeholder {
  color: #aaa;
}

/* ===== Tables ===== */
table {
  background: var(--ui-surface);
  border: 1px solid var(--ui-line);
  border-radius: var(--ui-radius);
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  width: 100%;
}

th {
  background: var(--ui-primary-light);
  color: var(--ui-text);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: .04em;
  padding: 12px 14px;
}

td, th {
  border-bottom: 1px solid var(--ui-line);
  padding: 10px 14px;
  text-align: left;
}

tbody tr {
  transition: background .15s ease;
}

tbody tr:hover {
  background: #f5f5f5;
}

tbody tr:last-child td {
  border-bottom: 0;
}

/* ===== Messages ===== */
.message {
  color: var(--ui-success);
  font-weight: 600;
}

.error {
  color: var(--ui-danger);
  font-weight: 600;
}

.hint,
.meta {
  color: var(--ui-muted);
}

/* ===== Status badges ===== */
.status-pending_review { color: var(--ui-warning); }
.status-approved { color: var(--ui-success); }
.status-rejected { color: var(--ui-danger); }
.status-offline { color: var(--ui-muted); }

/* ===== Smooth scrolling ===== */
html {
  scroll-behavior: smooth;
}

/* ===== Better scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #aaa;
}

/* ===== Responsive helpers ===== */
@media (max-width: 600px) {
  table.responsive {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
  }
}
