.admin-section {
  padding: 4rem 0;
  min-height: 80vh;
}

.admin-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 3rem;
  flex-wrap: wrap;
  gap: 2rem;
}

.admin-title {
  font-size: 3rem;
  font-weight: 900;
  line-height: 1.2;
}

.admin-subtitle {
  display: block;
  font-size: 1.5rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
  letter-spacing: 3px;
}

.btn-add-project {
  background: var(--gradient-primary);
  color: white;
  border: none;
  padding: 1rem 2rem;
  border-radius: 8px;
  font-family: 'Orbitron', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 5px 20px rgba(0, 240, 255, 0.3);
}

.btn-add-project:hover {
  box-shadow: 0 5px 30px rgba(0, 240, 255, 0.5);
  transform: translateY(-2px);
}

.btn-logout {
  background: var(--gradient-secondary);
  color: white;
  border: none;
  padding: 0.5rem 1.5rem;
  border-radius: 6px;
  font-family: 'Orbitron', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.btn-logout:hover {
  box-shadow: 0 0 20px rgba(255, 0, 110, 0.5);
  transform: scale(1.05);
}

/* Stats Dashboard */
.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  transition: all 0.3s ease;
}

.stat-card:hover {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
  transform: translateY(-3px);
}

.stat-icon {
  font-size: 2.5rem;
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 240, 255, 0.1);
  border-radius: 12px;
}

.stat-info {
  flex: 1;
}

.stat-value {
  font-family: 'Orbitron', sans-serif;
  font-size: 2rem;
  font-weight: 900;
  color: var(--neon-cyan);
  margin-bottom: 0.25rem;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Table */
.admin-table-container {
  background: var(--bg-card);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: 12px;
  overflow: hidden;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-table thead {
  background: rgba(0, 240, 255, 0.1);
  border-bottom: 2px solid var(--neon-cyan);
}

.admin-table th {
  padding: 1.2rem 1rem;
  text-align: left;
  font-family: 'Orbitron', sans-serif;
  font-weight: 700;
  color: var(--neon-cyan);
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 1px;
}

.admin-table td {
  padding: 1.2rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

.admin-table tbody tr {
  transition: all 0.2s ease;
}

.admin-table tbody tr:hover {
  background: rgba(0, 240, 255, 0.05);
}

.loading-row {
  text-align: center;
  padding: 3rem !important;
}

.loading-row .loader {
  margin: 0 auto 1rem;
}

.status-badge-table {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-active {
  background: rgba(0, 255, 136, 0.1);
  color: var(--neon-green);
  border: 1px solid rgba(0, 255, 136, 0.3);
}

.status-maintenance {
  background: rgba(255, 234, 0, 0.1);
  color: var(--neon-yellow);
  border: 1px solid rgba(255, 234, 0, 0.3);
}

.status-archived {
  background: rgba(160, 160, 160, 0.1);
  color: var(--text-secondary);
  border: 1px solid rgba(160, 160, 160, 0.3);
}

.featured-icon {
  font-size: 1.2rem;
}

.table-actions {
  display: flex;
  gap: 0.5rem;
}

.btn-icon {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--text-primary);
  width: 36px;
  height: 36px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.btn-icon:hover {
  border-color: var(--neon-cyan);
  color: var(--neon-cyan);
  background: rgba(0, 240, 255, 0.1);
}

.btn-icon.delete:hover {
  border-color: var(--neon-pink);
  color: var(--neon-pink);
  background: rgba(255, 0, 110, 0.1);
}

/* Action Buttons */
.btn-edit,
.btn-delete-table {
  padding: 0.5rem 1rem;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-edit {
  background: rgba(0, 240, 255, 0.1);
  color: var(--neon-cyan);
  border: 1px solid rgba(0, 240, 255, 0.3);
}

.btn-edit:hover {
  background: rgba(0, 240, 255, 0.2);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.3);
  transform: translateY(-2px);
}

.btn-delete-table {
  background: rgba(255, 0, 110, 0.1);
  color: var(--neon-pink);
  border: 1px solid rgba(255, 0, 110, 0.3);
}

.btn-delete-table:hover {
  background: rgba(255, 0, 110, 0.2);
  border-color: var(--neon-pink);
  box-shadow: 0 0 15px rgba(255, 0, 110, 0.3);
  transform: translateY(-2px);
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.3s ease;
}

.modal.active {
  display: flex;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-content {
  background: var(--bg-card);
  border: 1px solid rgba(0, 240, 255, 0.3);
  border-radius: 16px;
  max-width: 800px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  animation: slideUp 0.3s ease;
}

.modal-small {
  max-width: 500px;
}

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

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem 2rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-title {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--neon-cyan);
}

.modal-close,
.btn-close {
  background: rgba(255, 0, 110, 0.1);
  border: 1px solid rgba(255, 0, 110, 0.3);
  color: var(--neon-pink);
  font-size: 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-weight: 700;
  line-height: 1;
}

.modal-close:hover,
.btn-close:hover {
  background: rgba(255, 0, 110, 0.2);
  border-color: var(--neon-pink);
  color: white;
  box-shadow: 0 0 20px rgba(255, 0, 110, 0.4);
  transform: rotate(90deg);
}

.modal-body {
  padding: 2rem;
}

/* Form */
.project-form {
  padding: 2rem;
}

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

.form-group {
  margin-bottom: 1.5rem;
}

/* Color Palette */
.color-palette {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.palette-item {
  width: 100%;
  height: 40px;
  border-radius: 6px;
  cursor: pointer;
  border: 2px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.palette-item:hover {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.5);
  transform: scale(1.08);
}

.palette-item.selected {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.6);
  transform: scale(1.05);
}

.palette-item.selected::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 1.3rem;
  font-weight: bold;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.8);
}

/* No Background Option */
.palette-item.no-bg {
  background: repeating-linear-gradient(
    45deg,
    rgba(255, 255, 255, 0.05),
    rgba(255, 255, 255, 0.05) 10px,
    rgba(255, 255, 255, 0.1) 10px,
    rgba(255, 255, 255, 0.1) 20px
  );
  border: 2px dashed rgba(255, 255, 255, 0.3);
}

.palette-item.no-bg:hover {
  background: repeating-linear-gradient(
    45deg,
    rgba(0, 240, 255, 0.1),
    rgba(0, 240, 255, 0.1) 10px,
    rgba(0, 240, 255, 0.15) 10px,
    rgba(0, 240, 255, 0.15) 20px
  );
  border-color: var(--neon-cyan);
}

.no-bg-icon {
  font-size: 1.5rem;
  color: var(--text-secondary);
  font-weight: bold;
}

.palette-item.no-bg.selected .no-bg-icon {
  color: var(--neon-cyan);
}

.palette-item.no-bg.selected::after {
  display: none;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.95rem;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  background: var(--bg-secondary);
  border: 1px solid rgba(0, 240, 255, 0.2);
  color: var(--text-primary);
  padding: 0.9rem 1rem;
  border-radius: 8px;
  font-family: 'Rajdhani', sans-serif;
  font-size: 1rem;
  transition: all 0.3s ease;
  outline: none;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.2);
}

/* Color input special styling */
#color {
  background: var(--bg-secondary);
  cursor: default;
  font-size: 0.9rem;
  color: var(--neon-cyan);
  font-weight: 600;
}

#color:focus {
  border-color: rgba(0, 240, 255, 0.2);
  box-shadow: none;
}

.form-group small {
  display: block;
  margin-top: 0.5rem;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  cursor: pointer;
  padding: 0.75rem 1rem;
  background: rgba(0, 240, 255, 0.05);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: 8px;
  margin-top: 0.5rem;
  transition: all 0.3s ease;
}

.checkbox-label:hover {
  background: rgba(0, 240, 255, 0.1);
  border-color: var(--neon-cyan);
}

.checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
  accent-color: var(--neon-cyan);
  margin-top: 2px;
  flex-shrink: 0;
}

.checkbox-label span {
  color: var(--text-primary);
  font-weight: 500;
  line-height: 1.5;
  font-size: 0.95rem;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-cancel {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--text-primary);
  padding: 0.9rem 2rem;
  border-radius: 8px;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-cancel:hover {
  border-color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.btn-submit {
  background: var(--gradient-primary);
  color: white;
  border: none;
  padding: 0.9rem 2rem;
  border-radius: 8px;
  font-family: 'Orbitron', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.btn-submit:hover {
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.5);
  transform: translateY(-2px);
}

.btn-delete {
  background: var(--gradient-secondary);
  color: white;
  border: none;
  padding: 0.9rem 2rem;
  border-radius: 8px;
  font-family: 'Orbitron', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.btn-delete:hover {
  box-shadow: 0 0 20px rgba(255, 0, 110, 0.5);
  transform: translateY(-2px);
}

.delete-warning {
  color: var(--neon-pink);
  font-weight: 600;
  margin-top: 0.5rem;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--bg-card);
  border: 1px solid var(--neon-cyan);
  color: var(--text-primary);
  padding: 1rem 1.5rem;
  border-radius: 8px;
  box-shadow: 0 5px 30px rgba(0, 240, 255, 0.3);
  transform: translateY(150%);
  transition: transform 0.3s ease;
  z-index: 2000;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
}

.toast.show {
  transform: translateY(0);
}

/* Responsive - Large Screens */
@media (min-width: 1680px) {
  .admin-title {
    font-size: 4rem;
  }

  .admin-subtitle {
    font-size: 2rem;
  }

  .btn-add-project {
    font-size: 1.2rem;
    padding: 1.2rem 2.5rem;
  }

  .btn-logout {
    font-size: 1.1rem;
    padding: 0.7rem 2rem;
  }

  .admin-stats {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
  }

  .stat-card {
    padding: 2rem;
  }

  .stat-icon {
    font-size: 3.5rem;
    width: 80px;
    height: 80px;
  }

  .stat-value {
    font-size: 2.5rem;
  }

  .stat-label {
    font-size: 1.1rem;
  }

  .admin-table {
    font-size: 1.1rem;
  }

  .admin-table th {
    padding: 1.5rem;
  }

  .admin-table td {
    padding: 1.5rem;
  }

  .modal-content {
    max-width: 1000px;
    padding: 3rem;
  }

  .modal-title {
    font-size: 2.5rem;
  }

  .form-label {
    font-size: 1.1rem;
  }

  .form-input,
  .form-select,
  .form-textarea {
    font-size: 1.1rem;
    padding: 1rem;
  }

  .color-palette {
    grid-template-columns: repeat(6, 1fr);
    gap: 1rem;
  }

  .palette-item {
    height: 50px;
  }

  .btn-submit,
  .btn-delete {
    font-size: 1.2rem;
    padding: 1.1rem 2.5rem;
  }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
  .admin-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-title {
    font-size: 2rem;
  }

  .admin-subtitle {
    font-size: 1.2rem;
  }

  .admin-stats {
    grid-template-columns: 1fr;
  }

  .admin-table-container {
    overflow-x: auto;
  }

  .admin-table {
    min-width: 800px;
  }

  .modal-content {
    width: 95%;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .color-palette {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.4rem;
  }

  .palette-item {
    height: 35px;
  }
}
