/* --------------------------------------------------
RESET BÁSICO
-------------------------------------------------- */

*,
*::before,
*::after {
box-sizing: border-box;
margin: 0;
padding: 0;
}

html, body {
height: 100%;
}

/* --------------------------------------------------
TIPOGRAFÍA Y FONDO GENERAL
-------------------------------------------------- */

body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
background: #f4f3ef; /* gris cálido */
color: #37352f; /* marrón/gris suave */
line-height: 1.5;
}

/* Links generales */

a {
color: inherit;
text-decoration: none;
}

a:hover {
text-decoration: none;
}

/* Texto tenue / muted */

.muted {
color: #8b8574;
font-size: 0.9rem;
}

/* --------------------------------------------------
CONTENEDOR GENERAL (para páginas centradas)
-------------------------------------------------- */

main,
.dashboard {
max-width: 1080px;
margin: 24px auto 40px;
padding: 0 20px 40px;
}

/* --------------------------------------------------
HEADER / MENÚ SUPERIOR
-------------------------------------------------- */

header,
.site-header {
background: #ffffff;
border-bottom: 1px solid rgba(0, 0, 0, 0.03);
box-shadow: 0 6px 18px rgba(63, 74, 47, 0.12); /* sombra olivo */
padding: 14px 40px;
display: flex;
align-items: center;
justify-content: space-between;
position: sticky;
top: 0;
z-index: 100;
}

/* Marca Be Studio */
header .logo,
.site-header .logo,
header > a:first-child,
header > span:first-child {
font-size: 20px;
font-weight: 700;
letter-spacing: 0.18em;
text-transform: uppercase;
color: #3f4a2f; /* verde olivo oscuro */
}

/* Navegación */
header nav,
.site-nav {
display: flex;
gap: 20px;
align-items: center;
flex-wrap: wrap;
}

header nav a,
.site-nav a,
header a {
font-size: 14px;
color: #7b8074; /* gris/marrón */
position: relative;
padding-bottom: 2px;
transition: color 0.2s ease, transform 0.15s ease;
}

header nav a:hover,
.site-nav a:hover {
color: #3f4a2f;
transform: translateY(-1px);
}

header nav a::after,
.site-nav a::after {
content: "";
position: absolute;
left: 0;
bottom: -2px;
width: 0;
height: 2px;
background: #3f4a2f; /* subrayado olivo */
border-radius: 999px;
transition: width 0.2s ease;
}

header nav a:hover::after,
.site-nav a:hover::after {
width: 100%;
}

/* --------------------------------------------------
CABECERA DEL DASHBOARD
-------------------------------------------------- */

.dashboard-header {
margin-bottom: 24px;
}

.dashboard-title {
font-size: 28px;
font-weight: 700;
margin-bottom: 4px;
color: #3f4a2f;
}

.dashboard-subtitle {
color: #8b8574;
font-size: 14px;
}

/* --------------------------------------------------
SECCIONES DEL DASHBOARD (tarjetas grandes)
-------------------------------------------------- */

.panel-section {
background: linear-gradient(135deg, #ffffff, #f0eee7); /* blanco + beige */
border-radius: 20px;
padding: 24px 26px 26px;
margin-bottom: 24px;
box-shadow: 0 14px 30px rgba(63, 74, 47, 0.10);
}

.panel-title {
font-size: 18px;
letter-spacing: 0.16em;
text-transform: uppercase;
color: #3f4a2f; /* títulos olivo */
margin-bottom: 6px;
}

.panel-description {
font-size: 14px;
color: #8b8574; /* gris/marrón suave */
margin-bottom: 18px;
}

/* Tarjetas internas (paquetes, membresía, etc.) */

.panel-card {
background: #ffffff;
border-radius: 14px;
padding: 14px 16px 16px;
margin-bottom: 14px;
box-shadow: 0 8px 18px rgba(0,0,0,0.05);
}

.card-title {
font-size: 15px;
font-weight: 700;
letter-spacing: 0.14em;
text-transform: uppercase;
margin-bottom: 4px;
color: #3f4a2f;
}

/* --------------------------------------------------
BOTONES (estilo Be Studio)
-------------------------------------------------- */

.btn-primary,
.btn-secondary,
.btn-pill,
.btn-pill-outline,
.btn-primary.btn-small {
display: inline-flex;
align-items: center;
justify-content: center;
border-radius: 999px;
border: none;
cursor: pointer;
font-size: 13px;
letter-spacing: 0.12em;
text-transform: uppercase;
padding: 10px 26px;
text-decoration: none;
transition: transform 0.15s ease, box-shadow 0.2s ease,
background 0.2s ease, color 0.2s ease;
}

/* Principal verde olivo */
.btn-primary,
.btn-primary.btn-small {
background: #3f4a2f;
color: #ffffff;
box-shadow: 0 8px 18px rgba(63, 74, 47, 0.35);
}

.btn-primary.btn-small {
font-size: 12px;
padding: 8px 18px;
}

.btn-primary:hover,
.btn-primary.btn-small:hover {
transform: translateY(-1px);
box-shadow: 0 12px 24px rgba(63, 74, 47, 0.45);
}

/* Secundario */
.btn-secondary {
background: #ffffff;
color: #3f4a2f;
border: 1px solid rgba(63, 74, 47, 0.28);
}

.btn-secondary:hover {
background: #f3f1eb;
}

/* Botones tipo pastilla (membresías) */
.btn-pill {
background: #3f4a2f;
color: #ffffff;
padding-inline: 24px;
font-size: 12px;
}

.btn-pill-outline {
background: transparent;
color: #3f4a2f;
border: 1px solid rgba(63, 74, 47, 0.35);
}

.btn-pill:hover {
transform: translateY(-1px);
}

.btn-pill-outline:hover {
background: #3f4a2f;
color: #ffffff;
}

/* --------------------------------------------------
PASTILLAS DE DISCIPLINAS (colores por clase)
-------------------------------------------------- */

.discipline-pills {
display: flex;
flex-wrap: wrap;
gap: 10px;
margin-bottom: 18px;
}

.pill {
padding: 8px 18px;
border-radius: 999px;
font-size: 12px;
letter-spacing: 0.16em;
text-transform: uppercase;
color: #ffffff;
box-shadow: 0 8px 18px rgba(0,0,0,0.18);
}

/* Colores específicos por disciplina */
.pill-pilates { background: #6b8bff; }
.pill-yoga { background: #5ad1ff; }
.pill-barre { background: #e59ffb; }
.pill-kpop { background: #ff97b9; }
.pill-ballet { background: #c89bff; }
.pill-dancefit { background: #8be78b; }

/* Mismos colores para las tarjetas de clase */
.disc-pilates { background: #6b8bff; }
.disc-yoga { background: #5ad1ff; }
.disc-barre { background: #e59ffb; }
.disc-kpop { background: #ff97b9; }
.disc-ballet { background: #c89bff; }
.disc-dancefit { background: #8be78b; }
.disc-default { background: #dde2ff; }

/* --------------------------------------------------
CALENDARIO DE CLASES (manteniendo el diseño actual)
-------------------------------------------------- */

.calendar-wrapper {
overflow-x: auto;
margin-top: 4px;
}

/* Grid: columna de hora + 6 días (Lun–Sáb) */
.calendar-grid {
display: grid;
grid-template-columns: 80px repeat(6, minmax(130px, 1fr));
grid-auto-rows: minmax(72px, auto); /* alto mínimo por hora, crece si hace falta */
border-radius: 18px;
background: #f3f1eb; /* beige claro */
box-shadow: inset 0 0 0 1px rgba(255,255,255,0.6);
}

/* Cabeceras */
.calendar-header-cell {
font-size: 12px;
text-transform: uppercase;
letter-spacing: 0.16em;
color: #7f7a6e;
padding: 10px 12px;
border-bottom: 1px solid rgba(0,0,0,0.05);
border-right: 1px solid rgba(0,0,0,0.03);
background: rgba(255,255,255,0.75);
}

.calendar-hour-col {
border-top-left-radius: 18px;
}

/* Columna de la hora (izquierda) */
.calendar-hour-cell {
font-size: 11px;
color: #a39b8d;
padding: 10px 8px;
border-right: 1px solid rgba(0,0,0,0.03);
border-bottom: 1px solid rgba(0,0,0,0.02);
}

/* Cada celda de día/hora */
.calendar-cell {
border-right: 1px solid rgba(0,0,0,0.02);
border-bottom: 1px solid rgba(0,0,0,0.02);
padding: 6px 6px;
position: relative;
}

/* Tarjeta de clase (todo el texto dentro del cuadro de color) */
.calendar-class-card {
border-radius: 14px;
padding: 6px 9px 8px;
display: flex;
flex-direction: column;
justify-content: space-between;
box-shadow: 0 10px 22px rgba(0,0,0,0.18);
color: #1e2438; /* texto oscuro dentro del pastel */
}

/* Texto interno de la tarjeta */
.class-discipline {
font-size: 10px;
text-transform: uppercase;
letter-spacing: 0.14em;
font-weight: 600;
margin-bottom: 2px;
}

.class-title {
font-size: 13px;
font-weight: 700;
margin-bottom: 3px;
}

.class-meta {
font-size: 10px;
color: #1e2438;
display: flex;
flex-direction: column;
gap: 1px;
margin-bottom: 4px;
}

/* Aseguramos que el botón se quede adentro y no expanda otras filas */
.calendar-class-card .btn-primary.btn-small {
align-self: flex-start;
}

/* --------------------------------------------------
TABLA DE RESERVAS
-------------------------------------------------- */

.table-reservas {
width: 100%;
border-collapse: collapse;
margin-top: 8px;
font-size: 14px;
}

.table-reservas th,
.table-reservas td {
padding: 8px 10px;
border-bottom: 1px solid rgba(0,0,0,0.04);
text-align: left;
}

.table-reservas th {
font-size: 11px;
text-transform: uppercase;
letter-spacing: 0.16em;
color: #7b8074;
}

/* Estados visuales básicos */
.estado-confirmed {
color: #2f855a;
font-weight: 600;
}

.estado-pending,
.estado-pendiente {
color: #b7791f;
font-weight: 500;
}

.estado-cancelled,
.estado-canceled {
color: #c53030;
}

/* --------------------------------------------------
RESPONSIVE BÁSICO
-------------------------------------------------- */

@media (max-width: 768px) {
header,
.site-header {
padding: 12px 16px;
flex-direction: column;
align-items: flex-start;
gap: 8px;
}

main,
.dashboard {
padding: 0 14px 30px;
}

.panel-section {
padding: 18px 16px 20px;
}

.discipline-pills {
gap: 6px;
}

.pill {
font-size: 10px;
padding: 6px 12px;
}

.calendar-grid {
min-width: 760px; /* permite scroll horizontal en móviles */
}
}

.alert-success {
background: #e8f3ec;
color: #2f5d3f;
padding: 14px 20px;
border-radius: 10px;
margin-bottom: 20px;
border: 1px solid #a8cbb3;
font-weight: 600;
}

.alert-error {
background: #fbecec;
color: #842029;
padding: 14px 20px;
border-radius: 10px;
margin-bottom: 20px;
border: 1px solid #f1b0b7;
font-weight: 600;
}

/* ================================
PÁGINA DE LOGIN / AUTH
================================ */

.auth-body {
margin: 0;
font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
background: #f5f3f0;
}

.auth-page {
display: flex;
min-height: 100vh;
}

/* Columna izquierda (imagen/hero) */
.auth-hero {
flex: 1.1;
position: relative;
background: url('login/fondo.jpg') center center / cover no-repeat;
/* Si no tienes imagen aún, deja un degradado: */
background-color: #c4b7a6;
background-image:
linear-gradient(135deg, rgba(48,60,52,0.7), rgba(156,175,136,0.7)),
url('images/login-hero.jpg');
color: #fff;
}

.auth-hero-overlay {
position: absolute;
inset: 0;
padding: 2.5rem 3rem;
display: flex;
flex-direction: column;
justify-content: space-between;
}

.auth-brand {
display: flex;
align-items: center;
gap: 0.75rem;
}

.auth-logo-circle {
width: 40px;
height: 40px;
border-radius: 999px;
background: rgba(245,243,240,0.15);
border: 1px solid rgba(245,243,240,0.4);
display: flex;
align-items: center;
justify-content: center;
font-weight: 700;
font-size: 1.3rem;
}

.auth-logo-text {
font-weight: 600;
font-size: 1.2rem;
letter-spacing: 0.08em;
text-transform: uppercase;
}

.auth-hero-text h1 {
font-size: 2.4rem;
margin-bottom: 0.75rem;
}

.auth-hero-text p {
max-width: 320px;
font-size: 0.98rem;
line-height: 1.6;
}

/* Columna derecha (formulario) */
.auth-panel {
flex: 0.9;
display: flex;
align-items: center;
justify-content: center;
padding: 2rem;
}

.auth-card {
width: 100%;
max-width: 420px;
background: #ffffff;
border-radius: 24px;
box-shadow: 0 20px 45px rgba(0,0,0,0.06);
padding: 2.5rem 2.25rem;
}

.auth-card-header h2 {
margin: 0 0 0.5rem;
font-size: 1.7rem;
color: #303c34; /* verde olivo oscuro */
}

.auth-card-header p {
margin: 0;
font-size: 0.95rem;
color: #7b7b7b;
}

.auth-alert {
margin-top: 1.3rem;
}

/* Formularios de login */
.auth-form {
margin-top: 1.8rem;
display: flex;
flex-direction: column;
gap: 1rem;
}

.auth-form .form-group {
display: flex;
flex-direction: column;
gap: 0.35rem;
}

.auth-form label {
font-size: 0.9rem;
font-weight: 500;
color: #4f4f4f;
}

.auth-form input[type="email"],
.auth-form input[type="password"] {
border-radius: 999px;
border: 1px solid #d3d0cb;
padding: 0.7rem 1rem;
font-size: 0.95rem;
outline: none;
background-color: #faf8f6;
transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.auth-form input[type="email"]:focus,
.auth-form input[type="password"]:focus {
border-color: #6e7f5b; /* olivo medio */
background-color: #ffffff;
box-shadow: 0 0 0 3px rgba(110,127,91,0.15);
}

/* Botón principal reutilizando tu .btn-primary */
.btn-full {
width: 100%;
}

/* Pie del formulario */
.auth-footer-links {
margin-top: 0.8rem;
display: flex;
align-items: center;
gap: 0.35rem;
font-size: 0.85rem;
}

.link-muted {
color: #8a8278;
text-decoration: none;
}

.link-muted:hover {
text-decoration: underline;
}

.auth-small-note {
margin-top: 2rem;
font-size: 0.8rem;
color: #a39a90;
text-align: center;
}

/* Alertas ya existentes, pero por si no están: */
.alert {
border-radius: 999px;
padding: 0.6rem 1rem;
font-size: 0.87rem;
}

.alert-success {
background: #edf7ee;
color: #2f6b3a;
}

.alert-error {
background: #fdeaea;
color: #8b3131;
}

/* Responsive: en móviles ocultamos la columna de imagen */
@media (max-width: 900px) {
.auth-page {
flex-direction: column;
}

.auth-hero {
display: none;
}

.auth-panel {
flex: 1;
padding: 2rem 1.25rem;
}

.auth-card {
box-shadow: none;
border-radius: 0;
max-width: 480px;
margin: 0 auto;
}
}

/* ====== LOGIN PAGE (Be Studio) ====== */

.login-page {
margin: 0;
min-height: 100vh;
font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
background: #f3f1eb;
color: #1f2933;
display: flex;
align-items: center;
justify-content: center;
}

.login-wrapper {
width: 100%;
max-width: 1024px;
background: #f8f6f1;
box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
border-radius: 28px;
display: grid;
grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
overflow: hidden;
}

/* COLUMNA IZQUIERDA: IMAGEN */

.login-hero {
position: relative;
min-height: 420px;
background-image: url('images/login-hero.jpg');
background-size: cover;
background-position: center;
background-repeat: no-repeat;
}

.login-hero-overlay {
position: absolute;
inset: 0;
background: linear-gradient(
to top,
rgba(24, 31, 18, 0.68),
rgba(24, 31, 18, 0.15)
);
}

.login-hero-text {
position: absolute;
left: 28px;
right: 28px;
bottom: 28px;
color: #f9fafb;
}

.login-hero-text .hero-logo {
font-weight: 700;
letter-spacing: 0.14em;
text-transform: uppercase;
font-size: 13px;
margin-bottom: 10px;
}

.login-hero-text h1 {
font-size: 30px;
margin: 0 0 4px;
}

.login-hero-text p {
margin: 0;
font-size: 14px;
color: #e5e7eb;
}

/* COLUMNA DERECHA: FORMULARIO */

.login-panel {
display: flex;
align-items: center;
justify-content: center;
padding: 32px;
}

.login-panel-inner {
width: 100%;
max-width: 360px;
}

.login-form-title {
font-size: 22px;
margin: 0 0 4px;
color: #1f2933;
}

.login-form-subtitle {
font-size: 14px;
margin: 0 0 20px;
color: #6b7280;
}

.login-form {
display: flex;
flex-direction: column;
gap: 16px;
margin-bottom: 24px;
}

.form-group {
display: flex;
flex-direction: column;
gap: 6px;
}

.form-group label {
font-size: 13px;
font-weight: 600;
color: #374151;
}

.form-group input {
border-radius: 999px;
border: 1px solid #d1d5db;
padding: 10px 16px;
font-size: 14px;
outline: none;
background: #fdfcf9;
transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.form-group input:focus {
border-color: #556b2f;
box-shadow: 0 0 0 2px rgba(85, 107, 47, 0.3);
background: #ffffff;
}

.btn-primary.btn-block {
width: 100%;
}

.login-links {
font-size: 13px;
text-align: left;
}

.login-links a {
color: #4b5563;
text-decoration: none;
}

.login-links a:hover {
text-decoration: underline;
}

.login-footer {
font-size: 11px;
color: #9ca3af;
}

/* Alertas */

.alert {
border-radius: 999px;
padding: 10px 16px;
font-size: 13px;
margin-bottom: 12px;
}

.alert-error {
background: #fef2f2;
color: #991b1b;
border: 1px solid #fecaca;
}

/* Responsive móvil */

@media (max-width: 768px) {
.login-wrapper {
grid-template-columns: 1fr;
max-width: 100%;
border-radius: 0;
box-shadow: none;
min-height: 100vh;
}

.login-hero {
display: none;
}

.login-panel {
padding: 32px 20px 24px;
}
}

/* ==== Calendario: vista tipo "chip" por clase ==== */

.calendar-cell-classes {
display: flex;
flex-direction: column;
gap: 0.5rem;
}

/* Card base ya existe; solo ajustamos detalles */
.calendar-class-chip {
position: relative;
cursor: pointer;
padding: 8px 10px;
}

/* Solo mostrar el nombre de la disciplina al inicio */
.calendar-class-chip .chip-label {
font-weight: 600;
letter-spacing: 0.08em;
text-transform: uppercase;
font-size: 11px;
}

/* Detalles ocultos hasta hover/click */
.calendar-class-chip .chip-details {
margin-top: 6px;
display: none;
font-size: 12px;
}

/* Mostrar detalles al pasar el cursor */
.calendar-class-chip:hover .chip-details {
display: block;
}

/* Mostrar detalles al hacer clic (clase .is-open desde JS) */
.calendar-class-chip.is-open .chip-details {
display: block;
}

/* Desactivar visualmente clases pasadas */
.calendar-class-chip.class-disabled {
opacity: 0.5;
cursor: default;
}

.calendar-class-chip.class-disabled .btn-primary {
pointer-events: none;
opacity: 0.6;
}
