/* Importar Poppins desde Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

/* Reset básico y tipografía global */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

/* Body y fondo */
body {
    background: linear-gradient(135deg, #FAE7C3, #FFBCFF);
    color: #333;
}

/* Header */
.main-header {
    background: #AF02CB;
    padding: 1rem 2rem;
    color: #fff;
}
.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1100px;
    margin: 0 auto;
}
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}
.logo-img {
    height:115px;
    width: auto;
    display: block;
}
.nav-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 1.5rem;
    align-items: center;
}
.nav-menu a {
    text-decoration: none;
    font-weight: 600;
    color: #FFFAEB;
    transition: color 0.3s;
}
.nav-menu a:hover {
    color: #00D4F2;
}
.nav-logout {
    background: #FE23A8;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}
.nav-logout:hover {
    background: #00D4F2;
}

/* Contenedor principal / dashboard */
.content {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 80vh;
    padding: 2rem;
}
.dashboard, .admin-container, .login-container {
    max-width: 900px;
    width: 100%;
    background: #fff;
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 6px 24px rgba(0,0,0,0.1);
}

/* Dashboard / encabezados */
.dashboard h2, .admin-container h2, .login-container h1 {
    text-align: center;
    color: #AF02CB;
    margin-bottom: 2rem;
}

/* Fidelización */
.fidelizacion-box h3 {
    color: #FE23A8;
    margin-bottom: 1rem;
    margin-top: 3rem; /* Añade un margen superior para darle más espacio con el anterior */
}
.fidelizacion-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
    margin-top: 1rem;
}
.fidelizacion-item {
    background: #FFFAEB;
    border-radius: 12px;
    padding: 1rem;
    text-align: center;
    box-shadow: 0 3px 8px rgba(0,0,0,0.08);
    transition: transform 0.2s;
}
.fidelizacion-item:hover {
    transform: translateY(-3px);
}
.fidelizacion-item .icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}
.fidelizacion-item .info {
    font-size: 0.8rem;
    color: #555;
}
.fidelizacion-item .servicio-nombre {
    display: block;
    font-weight: 600;
    font-size: 0.85rem;
    color: #AF02CB;
}
.fidelizacion-item .servicio-fecha {
    display: block;
    font-size: 0.75rem;
    color: #777;
}
.fidelizacion-item.done {
    background: #E0F9FF;
    border: 2px solid #00D4F2;
}
.fidelizacion-item.pending {
    background: #FFBCFF;
    color: #999;
}
.fidelizacion-item.premio {
    background: #FFF4C1;
    border: 2px solid #FE23A8;
}

/* Formularios */
.form-servicio, .admin-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.form-servicio select, .form-servicio button,
.admin-form input, .admin-form select, .admin-form textarea,
.login-container input, .login-container button {
    padding: 0.8rem;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
}
.form-servicio button, .admin-form button, .login-container button {
    background: #AF02CB;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}
.form-servicio button:hover, .admin-form button:hover, .login-container button:hover {
    background: #FE23A8;
}

/* Botón redimir */
.btn-redimir {
    background: #00D4F2;
    color: #fff;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 8px;
    margin-top: 0.5rem;
    cursor: pointer;
    transition: background 0.3s;
}
.btn-redimir:hover {
    background: #FE23A8;
}

/* Botón logout general */
.logout-btn {
    background: #FE23A8;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}
.logout-btn:hover {
    background: #AF02CB;
}

/* Alertas */
.alert, .login-alert {
    padding: 12px 15px;
    margin-bottom: 20px;
    border-radius: 8px;
    font-size: 0.9rem;
    text-align: center;
}
.alert-success {
    background-color: #d4edda;
    color: #155724;
}
.alert-error {
    background-color: #f8d7da;
    color: #721c24;
}
.alert-pendiente {
    background-color: #fff3cd;
    color: #856404;
}

/* Tablas */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
    font-family: 'Poppins', sans-serif;
}
table th, table td {
    padding: 0.8rem 1rem;
    border-bottom: 1px solid #ddd;
    text-align: left;
}
table thead {
    background-color: #AF02CB;
    color: #fff;
}
table tr:hover {
    background-color: #f1f1f1;
}

/* Botones admin */
.admin-btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}
.admin-btn.edit {
    background: #00D4F2;
    color: #fff;
}
.admin-btn.edit:hover {
    background: #FE23A8;
}
.admin-btn.delete {
    background: #FE23A8;
    color: #fff;
}
.admin-btn.delete:hover {
    background: #AF02CB;
}

/* Footer */
.main-footer {
    background: #FFFAEB;
    text-align: center;
    padding: 1rem;
    color: #666;
    font-size: 0.9rem;
}
.register-box {
            max-width: 500px;
            margin: 40px auto;
            padding: 25px;
            background: #fff;
            border-radius: 12px;
            box-shadow: 0 0 12px rgba(0,0,0,0.1);
        }
        h2 {
            text-align: center;
            font-weight: 700;
            margin-bottom: 20px;
        }
.ruleta-container {
    margin: 20px 0;
    text-align: center;
}

.ruleta-grid {
    width: 100%;
    max-width: 900px;
    margin: 0 auto 20px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    font-size: small;
}

.ruleta-item {
    background: #f5f5f5;
    padding: 18px;
    border-radius: 8px;
    border: 2px solid #ddd;
    font-weight: bold;
    transition: 0.2s;
}

.ruleta-item.active {
    background: #ffe08a;
    border-color: #f1b300;
    transform: scale(1.1);
}

.ruleta-btn {
    background: #ff3b7a;
    padding: 10px 20px;
    color: white;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.ruleta-msg {
    margin-top: 15px;
    font-size: 18px;
    font-weight: bold;
    color: #28a745;
}


/* Responsive */
@media (max-width: 768px) {
    .fidelizacion-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .ruleta-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .header-container {
        flex-direction: column;
        gap: 1rem;
    }
    .nav-menu ul {
        flex-direction: column;
        gap: 1rem;
    }
    table th, table td {
        padding: 0.5rem 0.7rem;
    }
}
@media (max-width: 480px) {
    .fidelizacion-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .ruleta-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    table {
        font-size: 0.85rem;
    }
}
.whatsapp-agenda {
    text-align: center;
    margin: 2rem 0;
}

.whatsapp-agenda a {
    display: inline-block;
    background-color: #25D366; /* Verde WhatsApp */
    color: #fff;
    font-weight: 600;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    transition: background 0.3s, transform 0.2s;
}

.whatsapp-agenda a:hover {
    background-color: #1DA851;
    transform: translateY(-2px);
}


/* --- Responsive para formulario de registro / login --- */

.login-container {
    max-width: 500px;
    width: 100%;
}

.login-container input,
.login-container button {
    width: 100%;
    font-size: 1rem;
}

.fecha-line {
    display: flex;
    flex-direction: column; /* Apila en pantallas pequeñas */
    gap: 5px;
}

.fecha-line label {
    font-weight: 600;
}

@media (max-width: 480px) {

    .login-container {
        padding: 1.2rem;
    }

    .login-container input,
    .login-container button {
        font-size: 0.95rem;
        padding: 0.75rem;
    }

    .fecha-line {
        width: 100%;
    }

    .content {
        padding: 1rem;
    }

    .logo-img {
        height: 70px;   /* Reduce logo en móvil */
    }
}

