
:root {
  --bg: #090d18;
  --panel: #111827;
  --panel2: #172033;
  --text: #f4f6ff;
  --muted: #929bb0;
  --blue: #3985ff;
  --red: #f04459;
  --border: #273249;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Poppins, sans-serif;
}

button, input { font: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 22px;
  background:
    radial-gradient(ellipse at 15% 15%, #193e7555, transparent 40%),
    radial-gradient(ellipse at 90% 85%, #a51f3550, transparent 40%),
    var(--bg);
}

.login-card {
  width: min(100%, 420px);
  padding: 38px;
  background: #111827ed;
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: 0 25px 80px #0008;
}

.logo {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 17px;
  background: linear-gradient(135deg, var(--blue), var(--red));
  font-size: 30px;
}

.eyebrow {
  color: #6ca7ff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
}

.login-card h1 {
  margin: 7px 0;
  font-size: 30px;
}

.login-card h1 span { color: var(--blue); }

.muted, .login-note { color: var(--muted); }

.login-card form {
  display: grid;
  gap: 10px;
  margin-top: 28px;
}

.login-card label {
  margin-top: 8px;
  font-size: 13px;
  font-weight: 600;
}

input {
  width: 100%;
  padding: 13px 15px;
  color: var(--text);
  background: #0b1220;
  border: 1px solid var(--border);
  border-radius: 10px;
  outline: none;
}

input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px #3985ff22;
}

.primary-button, .secondary-button, .logout-button, .action-button {
  padding: 12px 16px;
  border: 0;
  border-radius: 10px;
  font-weight: 600;
}

.primary-button {
  margin-top: 12px;
  color: white;
  background: linear-gradient(100deg, #2675ed, #d93858);
}

.primary-button:disabled { opacity: .6; cursor: wait; }

.message { min-height: 20px; color: #ff8290; font-size: 12px; }
.login-note { text-align: center; font-size: 11px; }

.dashboard-page { min-height: 100vh; }

.sidebar {
  width: 245px;
  position: fixed;
  inset: 0 auto 0 0;
  display: flex;
  flex-direction: column;
  padding: 26px 18px;
  background: #0e1524;
  border-right: 1px solid var(--border);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: white;
  text-decoration: none;
  font-weight: 700;
}

.brand-icon {
  display: grid;
  place-items: center;
  width: 43px;
  height: 43px;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--blue), var(--red));
  font-size: 24px;
}

.brand small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 2px;
}

.sidebar nav {
  display: grid;
  gap: 9px;
  margin-top: 55px;
}

.nav-link {
  padding: 13px;
  color: var(--muted);
  text-decoration: none;
  border-radius: 10px;
}

.nav-link.active {
  color: white;
  background: #1d3152;
}

.sidebar-bottom {
  display: grid;
  gap: 9px;
  margin-top: auto;
  padding: 16px 5px 0;
}

.admin-label {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 1px;
}

.logout-button {
  margin-top: 8px;
  color: #ff9aa5;
  background: #f0445918;
}

.main-content {
  max-width: 1500px;
  margin-left: 245px;
  padding: 30px 38px;
}

.topbar, .section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.topbar h1, .section-heading h2 { margin: 3px 0; }
.public-link { color: #80b2ff; text-decoration: none; font-size: 13px; }

.welcome {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 30px;
  padding: 28px;
  overflow: hidden;
  background: linear-gradient(110deg, #173d72, #172033 65%, #502034);
  border: 1px solid #30476a;
  border-radius: 18px;
}

.welcome h2 { margin: 8px 0; }
.welcome p:last-child { color: #c2cde0; font-size: 13px; }
.welcome-star { font-size: 70px; color: #ffffff55; }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 17px;
  margin: 22px 0 45px;
}

.stat-card {
  padding: 21px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 15px;
}

.stat-card span, .stat-card small { display: block; color: var(--muted); }
.stat-card strong { display: block; margin: 8px 0; font-size: 34px; }

.media-section { scroll-margin-top: 25px; }
.section-heading { margin-bottom: 20px; }
.section-heading p { font-size: 12px; }

.secondary-button {
  color: #b8d4ff;
  background: #1d3152;
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 18px;
}

.toolbar input { max-width: 390px; }
.toolbar span { color: var(--muted); font-size: 12px; }

.media-list { display: grid; gap: 12px; }

.media-item {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding: 13px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 13px;
}

.media-item img, .media-item video, .media-placeholder {
  width: 100px;
  height: 76px;
  object-fit: cover;
  border-radius: 9px;
  background: #202b40;
}

.media-placeholder {
  display: grid;
  place-items: center;
  color: #9bbcff;
  font-size: 24px;
}

.media-details { min-width: 0; }
.media-details h3 { margin: 0 0 5px; overflow-wrap: anywhere; font-size: 14px; }
.media-details p { margin: 3px 0; color: var(--muted); font-size: 11px; }

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

.action-button { padding: 9px 12px; font-size: 11px; }
.edit-button { color: #9bc4ff; background: #3985ff20; }
.delete-button { color: #ff9ba5; background: #f0445920; }

.empty-state {
  padding: 40px 15px;
  color: var(--muted);
  text-align: center;
  background: var(--panel);
  border-radius: 13px;
}

footer {
  padding: 35px 0 10px;
  color: var(--muted);
  text-align: center;
  font-size: 11px;
}

@media (max-width: 800px) {
  .sidebar {
    position: static;
    width: 100%;
    padding: 14px 18px;
  }

  .sidebar nav {
    display: flex;
    margin-top: 15px;
  }

  .sidebar-bottom { display: none; }

  .main-content {
    margin: 0;
    padding: 23px 16px;
  }

  .welcome { padding: 21px; }
  .welcome-star { font-size: 45px; }
}

@media (max-width: 560px) {
  .login-card { padding: 27px 22px; }
  .topbar h1 { font-size: 24px; }
  .public-link { font-size: 11px; }
  .stats { gap: 8px; }
  .stat-card { padding: 13px 10px; }
  .stat-card span { font-size: 10px; }
  .stat-card strong { font-size: 25px; }
  .stat-card small { font-size: 9px; }
  .section-heading { align-items: flex-start; }
  .toolbar { align-items: stretch; flex-direction: column; }
  .toolbar input { max-width: none; }
  .media-item {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 11px;
  }
  .media-item img, .media-item video, .media-placeholder {
    width: 76px;
    height: 76px;
  }
  .media-actions { grid-column: 1 / -1; }
  .media-actions button { flex: 1; }
}
