:root {
  --celeste: #00aaff;
  --celeste-claro: #e6f7ff;
  --blanco: #ffffff;
  --gris: #f5f5f5;
  --texto: #333;
}

* {
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Arial, sans-serif;
  margin: 0;
  background: linear-gradient(135deg, var(--celeste-claro), var(--blanco));
  color: var(--texto);
}

/* -------- HEADER -------- */
header {
  background: var(--celeste);
  color: var(--blanco);
  text-align: center;
  padding: 15px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* -------- CONTENEDOR PRINCIPAL -------- */
main {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: stretch;
  padding: 20px;
  gap: 20px;
}

/* -------- TARJETAS -------- */
.main, .sidebar, .card {
  background: var(--blanco);
  border-radius: 15px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  padding: 25px;
  transition: transform 0.2s;
}

.main:hover, .card:hover {
  transform: scale(1.02);
}

/* -------- PÁGINA PRINCIPAL -------- */
.main {
  flex: 1 1 300px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.sidebar {
  flex: 1 1 250px;
  background: var(--gris);
  overflow-y: auto;
  max-height: 500px;
}

h1 {
  font-size: 3rem;
  margin: 10px 0;
}

.animando {
  color: #777;
  font-style: italic;
}

/* -------- BOTONES -------- */
button {
  background: var(--celeste);
  color: var(--blanco);
  border: none;
  border-radius: 25px;
  padding: 12px 25px;
  font-size: 1.1rem;
  cursor: pointer;
  margin-top: 20px;
  transition: background 0.3s;
}

button:hover {
  background: #0090dd;
}

button.danger {
  background: #f55;
}

button.danger:hover {
  background: #d33;
}

/* -------- FORMULARIOS -------- */
label {
  display: block;
  margin: 10px 0;
  font-weight: bold;
}

input[type="number"],
input[type="text"] {
  width: 80%;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 8px;
  text-align: center;
  font-size: 1rem;
}

/* -------- HISTORIAL -------- */
ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

li {
  background: var(--blanco);
  margin: 5px 0;
  padding: 8px;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  text-align: center;
}

/* -------- TARJETA ADMIN -------- */
.card {
  text-align: center;
  width: 90%;
  max-width: 400px;
}

/* -------- RESPONSIVE -------- */
@media (max-width: 768px) {
  main {
    flex-direction: column;
    align-items: center;
  }

  .sidebar {
    max-height: none;
    width: 100%;
  }

  h1 {
    font-size: 2.2rem;
  }
}

.admin-btn {
  background: transparent;
  color: var(--celeste);
  border: 2px solid var(--celeste);
  margin-top: 10px;
}

.admin-btn:hover {
  background: var(--celeste);
  color: var(--blanco);
}


/* ======== ESTILOS PANEL ADMIN ======== */

.admin-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 80vh;
}

.admin-card {
  max-width: 400px;
  width: 90%;
  background: var(--blanco);
  padding: 25px;
  border-radius: 12px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  text-align: center;
}

.admin-card h3 {
  margin-bottom: 20px;
  color: var(--celeste);
}

.admin-card label {
  display: block;
  margin-top: 10px;
  font-weight: 600;
}

.admin-card input {
  width: 100%;
  padding: 8px;
  margin-top: 5px;
  border: 2px solid var(--celeste);
  border-radius: 8px;
  text-align: center;
}

.rango-group {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 15px;
}

.btn-group {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

button.danger {
  background: #e74c3c;
  color: white;
}

button.volver {
  background: #bbb;
  color: white;
}

button.volver:hover {
  background: #999;
}
