/* DEPOOL RADIO LIVE - Clean Modern Admin Dashboard (Matches Front Page) */
:root {
  --admin-bg: #f8fafc;
  --admin-card: #ffffff;
  --admin-card-border: #e2e8f0;
  --admin-primary: #dc2626;
  --admin-primary-hover: #b91c1c;
  --admin-text-main: #0f172a;
  --admin-text-muted: #64748b;
  --admin-success: #10b981;
  --radius: 16px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.04);
  --shadow-card: 0 10px 25px -5px rgba(0,0,0,0.06), 0 8px 10px -6px rgba(0,0,0,0.04);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--admin-bg);
  color: var(--admin-text-main);
  min-height: 100vh;
  padding: 20px;
}

.admin-layout {
  max-width: 1000px;
  margin: 0 auto;
}

/* Header */
.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: var(--admin-card);
  border: 1px solid var(--admin-card-border);
  border-radius: var(--radius);
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}

.admin-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.admin-logo {
  height: 40px;
  border-radius: 8px;
}

.admin-title {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.3px;
  color: var(--admin-text-main);
}

.admin-subtitle {
  font-size: 12px;
  color: var(--admin-text-muted);
}

.header-nav {
  display: flex;
  gap: 10px;
}

/* Grid Layout */
.dashboard-grid-2cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

@media (max-width: 768px) {
  .dashboard-grid-2cols {
    grid-template-columns: 1fr;
  }
}

/* Cards */
.admin-card {
  background: var(--admin-card);
  border: 1px solid var(--admin-card-border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-card);
}

.card-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.card-heading {
  font-size: 16px;
  font-weight: 800;
  color: var(--admin-text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Forms */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--admin-text-muted);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--admin-card-border);
  background: #ffffff;
  color: var(--admin-text-main);
  font-size: 14px;
  transition: all 0.2s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--admin-primary);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12);
}

textarea.form-control {
  min-height: 90px;
  resize: vertical;
}

/* Buttons */
.btn-primary {
  background: var(--admin-primary);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 12px 20px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
}

.btn-primary:hover {
  background: var(--admin-primary-hover);
  transform: translateY(-1px);
}

.btn-secondary {
  background: #e2e8f0;
  color: var(--admin-text-main);
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background: #cbd5e1;
}

.btn-ghost {
  background: transparent;
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-card-border);
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.btn-ghost:hover {
  color: var(--admin-text-main);
  background: #f1f5f9;
}

/* Posts List */
.posts-list-table {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.post-row-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: #f8fafc;
  border: 1px solid var(--admin-card-border);
  border-radius: 12px;
  gap: 16px;
}

.post-row-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  min-width: 0;
}

.post-row-thumb {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
  background: #e2e8f0;
}

.post-row-details {
  flex: 1;
  min-width: 0;
}

.post-row-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--admin-text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.post-row-meta {
  font-size: 12px;
  color: var(--admin-text-muted);
  margin-top: 2px;
}

.post-row-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-danger-icon {
  background: #fee2e2;
  color: #dc2626;
  border: 1px solid #fecaca;
  border-radius: 8px;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-danger-icon:hover {
  background: #fca5a5;
  color: #991b1b;
}

/* Toast */
.toast-notice {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0f172a;
  color: #fff;
  padding: 12px 20px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 10px 25px rgba(0,0,0,0.2);
  z-index: 9999;
  display: none;
  animation: slideUp 0.3s ease;
}

/* Login Modal */
.login-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.login-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 32px;
  width: 100%;
  max-width: 360px;
  text-align: center;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

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

.admin-subtitle {
  font-size: 11px;
  color: var(--admin-text-muted);
}

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

.btn-ghost {
  background: transparent;
  color: var(--admin-text-muted);
  border: 1px solid var(--admin-card-border);
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-ghost:hover {
  color: #fff;
  border-color: #334155;
}

/* Grid */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 768px) {
  .dashboard-grid-2cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }
}

/* Cards */
.admin-card {
  background: var(--admin-card);
  border: 1px solid var(--admin-card-border);
  border-radius: var(--radius);
  padding: 24px;
  position: relative;
}

.card-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.card-heading {
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Form Styles */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--admin-text-muted);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  background: #0b0f19;
  border: 1px solid var(--admin-card-border);
  border-radius: 10px;
  padding: 10px 14px;
  color: #fff;
  font-size: 13px;
  transition: border-color 0.2s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--admin-primary);
}

textarea.form-control {
  resize: vertical;
  min-height: 80px;
}

.btn-primary {
  background: var(--admin-primary);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background 0.2s ease;
}

.btn-primary:hover {
  background: var(--admin-primary-hover);
}

.btn-secondary {
  background: #1e293b;
  color: #fff;
  border: 1px solid #334155;
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background: #334155;
}

/* Post Items Management */
.posts-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
  max-height: 500px;
  overflow-y: auto;
}

.post-row-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: #0b0f19;
  border: 1px solid var(--admin-card-border);
  padding: 12px;
  border-radius: 10px;
}

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

.post-row-thumb {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}

.post-row-details {
  min-width: 0;
}

.post-row-title {
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 320px;
}

.post-row-meta {
  font-size: 11px;
  color: var(--admin-text-muted);
}

.post-row-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-danger-icon {
  background: rgba(220, 38, 38, 0.15);
  color: #ef4444;
  border: 1px solid rgba(220, 38, 38, 0.3);
  border-radius: 8px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.btn-danger-icon:hover {
  background: #dc2626;
  color: #fff;
}

/* Login Modal */
.login-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}

.login-card {
  background: var(--admin-card);
  border: 1px solid var(--admin-card-border);
  border-radius: var(--radius);
  padding: 32px;
  width: 100%;
  max-width: 380px;
  text-align: center;
}

.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #10b981;
  color: #fff;
  padding: 12px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 13px;
  display: none;
  z-index: 999;
}
