/* ==================== RESPONSIVE.CSS ==================== */

/* ===================================================
   TABLET (max 900px)
=================================================== */
@media (max-width: 900px) {

    /* HEADER */
    .header-nav {
        display: flex;
        gap: 1.2rem;
    }

    .menu-hamburguesa {
        display: none;
    }

    .menu-mobile {
        display: none !important;
    }

    .menu-overlay {
        display: none !important;
    }

    /* HERO HOME */
    .home-hero {
        grid-template-columns: 1fr !important;
        min-height: auto;
    }

    .home-hero-left {
        padding: 2.5rem 1.5rem;
        border-right: none;
        border-bottom: 1px solid #e8e8e8;
    }

    .home-hero-right {
        display: flex !important;
        min-height: 200px;
        padding: 2rem;
    }

    .home-logo-img {
        height: 120px;
    }

    /* STATS */
    .home-stats {
        grid-template-columns: repeat(3, 1fr);
    }

    /* SERVICIOS */
    .home-servicios {
        padding: 2.5rem 1.5rem;
    }

    .home-servicios-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    /* BANNER AMBIENT */
    .home-ambient {
        height: 420px;
    }

    .home-ambient-text {
        font-size: 36px;
    }

    /* RESERVA */
    .reserva-section {
        padding: 2rem 1.5rem;
    }

    .reserva-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .horas-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .reserva-resumen {
        flex-direction: column;
    }

    .resumen-email-aviso {
        max-width: 100%;
    }

    /* MIS CITAS */
    .mis-citas-section {
        padding: 2rem 1.5rem;
    }

    /* ADMIN — quitar sticky sidebar */
    .admin-layout {
        grid-template-columns: 1fr;
    }

    .admin-sidebar {
        position: static !important;
        height: auto !important;
        min-height: auto !important;
    }

    .admin-nav {
        display: flex;
        overflow-x: auto;
        padding: 0;
        gap: 0;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .admin-nav::-webkit-scrollbar {
        display: none;
    }

    .admin-nav-item {
        white-space: nowrap;
        border-left: none !important;
        border-bottom: 2px solid transparent;
        padding: 0.7rem 1.2rem;
    }

    .admin-nav-item.active {
        border-left: none !important;
        border-bottom-color: #fff !important;
        background: none;
    }

    .admin-main {
        padding: 1.5rem 1rem;
        overflow-x: hidden;
    }

    .admin-bloqueo-form {
        flex-direction: column;
    }

    .admin-input {
        width: 100%;
    }
}

/* ===================================================
   MOVIL (max 600px)
=================================================== */
@media (max-width: 600px) {

    body {
        padding-top: 60px;
    }

    header {
        height: 60px;
        padding: 0 1rem;
    }

    /* HEADER */
    .header-logo-img {
        height: 36px;
    }

    .header-logo-sub {
        display: none;
    }

    .header-nav {
        display: flex;
        gap: 0.8rem;
    }

    .nav-link {
        font-size: 10px;
        letter-spacing: 1px;
    }

    .icon-btn span {
        display: none;
    }

    /* HERO HOME */
    .home-hero {
        grid-template-columns: 1fr !important;
        min-height: auto;
    }

    .home-hero-left {
        padding: 2rem 1.2rem;
        border-right: none;
        border-bottom: 1px solid #e8e8e8;
    }

    .home-hero-right {
        display: flex !important;
        min-height: 160px;
        padding: 1.5rem;
    }

    .home-logo-img {
        height: 90px;
    }

    .section-title {
        font-size: 26px;
        letter-spacing: -1px;
    }

    .home-hero-text {
        font-size: 13px;
    }

    .home-hero-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .home-hero-actions .btn-primary,
    .home-hero-actions .btn-outline {
        width: 100%;
        text-align: center;
    }

    /* STATS */
    .home-stats {
        grid-template-columns: repeat(3, 1fr);
    }

    .home-stat {
        padding: 1rem 0.5rem;
    }

    .home-stat-num {
        font-size: 24px;
    }

    .home-stat-label {
        font-size: 8px;
        letter-spacing: 1px;
    }

    /* SERVICIOS */
    .home-servicios {
        padding: 2rem 1.2rem;
    }

    .home-servicios-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .servicio-card {
        padding: 1.2rem 0.8rem;
    }

    .servicio-nombre {
        font-size: 13px;
    }

    /* BANNER AMBIENT */
    .home-ambient {
        height: 300px;
    }

    .home-ambient-overlay {
        padding: 0 1.5rem;
    }

    .home-ambient-text {
        font-size: 28px;
        letter-spacing: -0.5px;
    }

    /* CTA */
    .home-cta {
        padding: 2.5rem 1.2rem;
    }

    .home-cta .section-title {
        font-size: 22px;
    }

    /* RESERVA */
    .reserva-section {
        padding: 1.5rem 1rem;
    }

    .reserva-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .horas-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .reserva-resumen {
        flex-direction: column;
    }

    .resumen-email-aviso {
        display: none;
    }

    .cal-dia {
        font-size: 11px;
        padding: 0.45rem 0;
    }

    /* MIS CITAS */
    .mis-citas-section {
        padding: 1.5rem 1rem;
    }

    .cita-fila {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.6rem;
    }

    /* LOGIN */
    .login-container {
        padding: 1rem;
    }

    .login-box {
        padding: 1.5rem 1.2rem;
    }

    .login-logo-img {
        height: 55px;
    }

    /* FOOTER */
    .footer-main {
        padding: 2rem 1.2rem 1.2rem;
    }

    .footer-content {
        flex-direction: column;
        gap: 1.2rem;
    }

    .footer-logo {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .footer-logo-img {
        height: 40px;
    }

    .footer-logo-sub {
        font-size: 9px;
    }

    .footer-info p {
        font-size: 11px;
    }

    .footer-bottom p {
        font-size: 10px;
    }

    /* ADMIN */
    .admin-layout {
        grid-template-columns: 1fr;
    }

    .admin-sidebar {
        position: static !important;
        height: auto !important;
        min-height: auto !important;
    }

    .admin-sidebar-header {
        padding: 1rem 1.2rem;
    }

    .admin-nav {
        display: flex;
        overflow-x: auto;
        padding: 0;
        gap: 0;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .admin-nav::-webkit-scrollbar {
        display: none;
    }

    .admin-nav-item {
        white-space: nowrap;
        flex-shrink: 0;
        border-left: none !important;
        border-bottom: 2px solid transparent;
        padding: 0.7rem 1rem;
        font-size: 10px;
    }

    .admin-nav-item.active {
        border-left: none !important;
        border-bottom-color: #fff !important;
        background: none;
    }

    .admin-main {
        padding: 1rem;
        overflow-x: hidden;
    }

    .admin-seccion-titulo {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .admin-bloqueo-form {
        flex-direction: column;
    }

    .admin-input {
        width: 100%;
    }

    /* TABLA ADMIN: scroll horizontal para no cortar contenido */
    .admin-tabla-wrap {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .admin-tabla-wrap::-webkit-scrollbar {
        display: none;
    }

    .admin-tabla {
        min-width: 500px;
        /* fuerza scroll en vez de cortar */
        width: 100%;
    }

    .admin-tabla th,
    .admin-tabla td {
        padding: 0.6rem 0.8rem;
        font-size: 12px;
        white-space: nowrap;
    }
}

/* ===================================================
   MÓVILES ESTRECHOS (max 380px)
   Galaxy S8/S9, iPhone SE, Galaxy A/J... pantallas de 360px
=================================================== */
@media (max-width: 380px) {

    /* BANNER AMBIENT: un poco más alto para que la foto se vea bien
       (la foto es casi cuadrada y en 300px quedaba muy pequeña) */
    .home-ambient {
        height: 340px;
    }

    .home-ambient-overlay {
        padding: 0 1.2rem;
    }

    .home-ambient-text {
        font-size: 24px;
        letter-spacing: -0.3px;
    }

    /* HERO */
    .home-hero-left {
        padding: 1.8rem 1.2rem;
    }

    .section-title {
        font-size: 26px;
    }

    /* SERVICIOS */
    .home-servicios {
        padding: 2rem 1rem;
    }

    /* RESERVA: 3 huecos de hora por fila caben justos en 360px */
    .horas-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.4rem;
    }

    .cal-dia {
        font-size: 10px;
    }

    /* LOGIN */
    .login-box {
        padding: 1.3rem 1rem;
    }
}

/* ===================================================
   ACCESIBILIDAD: usuarios que piden reducir animaciones
=================================================== */
@media (prefers-reduced-motion: reduce) {

    /* Sin Ken Burns ni parallax: la foto siempre visible y quieta */
    .home-ambient img,
    .home-ambient-bg {
        animation: none !important;
    }

    .anim-fade-up,
    .anim-fade-left {
        opacity: 1 !important;
        transform: none !important;
    }
}