/* ===== ESTILOS BASE PARA TODOS LOS DISPOSITIVOS ===== */
body {
    background-color: #f5f5f5 !important;
    font-family: Arial, Helvetica, sans-serif;
    margin: 0;
    padding: 0;
}


/* ===== MODAL - RESPONSIVE PARA TODOS ===== */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
    justify-content: center;
    align-items: center;
    padding: 1rem;
    box-sizing: border-box;
}

.modal-contenido {
    background-color: #f5f5f5;
    padding: 30px;
    border: 1px solid #888;
    width: 90%;
    max-width: 500px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    position: relative;
    animation: fadeIn 0.3s ease;
    margin: auto;
}

/* Modal más ancho para tablas */
.modal-contenido:has(table) {
    max-width: 90%;
    width: 95%;
}

/* Modal para formularios */
.modal-contenido:has(form) {
    max-width: 500px;
    width: 90%;
}

.modal-contenido form {
    width: 100%;
}

.modal-contenido .form-grupo {
    margin-bottom: 20px;
}

.modal-contenido label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
}

.modal-contenido input,
.modal-contenido textarea,
.modal-contenido select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    box-sizing: border-box;
    font-size: 14px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#cerrar-modal {
    position: absolute;
    top: 10px;
    right: 15px;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s ease;
}

#cerrar-modal:hover,
#cerrar-modal:focus {
    color: #333;
}

/* ===== HEADER Y NAVEGACIÓN ===== */
body::-webkit-scrollbar {
    display: none;
}

.navbar {
    overflow: hidden;
    font-family: Arial, Helvetica, sans-serif;
}

.baner {
    overflow: hidden;
    text-align: center;
    max-height: 300px;
}

#baner {
    width: 95vw;
    height: auto;
    max-width: 2000px;
    max-height: 300px;
    margin-left: 4%;
    margin-right: auto;
    display: block;
    margin-top: 3%;
    object-fit: cover;
}

/* CONTENEDOR GENERAL */
.logo-wrapper {
    width: 95%;
    margin: 20px auto;
}

/* Ocultar sidebar por defecto en desktop; se muestra solo en móviles */
.sidebar {
    display: none;
}

/* =============== DESKTOP =============== */
.logo-container-desktop {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Logo de escritorio */
.logo-desktop {
    width: 130px;
    height: 130px;
    border-radius: 50%;
    object-fit: cover;
}

/* Panel derecho */
.right-panel {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 5px;
}

p.don {
    margin: 0;
    font-size: 24px;
    font-weight: bold;
    color: #333;
}

/* Iconos alineados en una fila */
.icons {
    display: flex;
    gap: 20px;
    align-items: center;
}

.icons i {
    font-size: 20px;
    color: #333;
}

.phone {
    font-size: 18px;
    color: #333;
}

/* =============== MÓVIL =============== */

/* Ocultar desktop en móvil */
.top-row-mobile {
    display: none;
}

.logo-desktop {
    display: block;
}

@media (max-width: 768px) {

    /* FILA 1: Hamburguesa + Logo */
    .top-row-mobile {
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .hamburger {
        font-size: 32px;
        cursor: pointer;
        padding: 10px 15px;
        background: none;
        border: none;
        color: #333;
        display: flex;
        align-items: center;
        justify-content: center;
        min-width: 50px;
        min-height: 50px;
        transition: background-color 0.3s ease;
    }

    .hamburger:active {
        background-color: rgba(0, 0, 0, 0.1);
        border-radius: 5px;
    }

    .logo {
        width: 100px;
        height: 100px;
        border-radius: 50%;
        object-fit: cover;
    }

    /* Ocultar versión desktop */
    .logo-container-desktop {
        display: none;
    }

    p.don {
        text-align: center;
    }

    /* Segunda fila: nombre + iconos */
    .right-panel {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .icons {
        justify-content: center;
        flex-wrap: wrap;
    }

    /* Sidebar móvil */
    .sidebar {
        display: block !important;
        position: fixed;
        top: 0;
        left: -250px;
        width: 250px;
        height: 100%;
        background-color: #C1292E;
        padding-top: 80px;
        transition: left 0.3s;
        z-index: 9999;
        overflow-y: auto;
    }

    .sidebar a {
        color: white;
        text-decoration: none;
        display: block;
        font-size: 1.1rem;
        padding: 15px 20px;
        font-family: Arial, Helvetica, sans-serif;
        transition: background-color 0.3s;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .sidebar a:hover {
        background-color: #961d21;
        color: white;
    }

    /* Texto 'Info' que se añade al mover el icono al sidebar */
    .sidebar a .info-text {
        margin-left: 8px;
        font-weight: 600;
        color: #fff;
        font-size: 1rem;
    }

    .sidebar.active {
        left: 0;
    }

    .barra {
        display: none !important;
    }
}

/* .fa-circle-exclamation {
    position: absolute;
    top: 30%;
    left: 44%;
    color: #333;
    font-size: 1.5vw;
} */

#faceboock {
    position: absolute;
    top: 30%;
    left: 85%;
    color: #333;
    font-size: 1.5vw;
}

#cel {
    position: absolute;
    top: 30%;
    left: 88%;
    color: #333;
    font-size: 1.5vw;
}

/* #mapa {
    position: absolute;
    left: 20%;
    color: #333;
    font-size: 1.5vw;
} */

.barra {
    background-color: #C1292E;
    overflow: hidden;
    text-align: center;
    margin-bottom: 1%;
    margin-top: 1%;
    width: 100%;
}

.barra a {
    color: white;
    text-decoration: none;
    display: inline-block;
    font-size: 1.5rem;
    padding: 1% 5%;
    font-family: Arial, Helvetica, sans-serif;
    transition: background-color 0.3s;
}

.barra a:hover {
    background-color: #961d21;
    color: white;
}

/* ===== CARDS DE PRODUCTOS ===== */
.precio {
    font-family: Arial, Helvetica, sans-serif;
    color: #ffaf04;
    font-size: 1.5rem;
    font-weight: bold;
    margin-top: 5px;
    margin-right: 20px;
}

.img-platillo {
    width: 100%;
    height: 200px;
    object-fit: cover;
    object-position: center;
    cursor: pointer;
}

.card {
    background-color: #f5f5f5 !important;
    width: 40%;
    max-width: 450px;
    margin: 30px;
    border: 3px solid rgb(255, 175, 4) !important;
    border-radius: 8px;
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
}

.card i {
    font-size: 2rem;
    color: #333;
    cursor: pointer;
    margin-right: 20px;
    float: right;
    margin-bottom: 10px;
    transition: color 0.3s;
}

.card i:hover {
    color: #85877c;
}

/* ===== SECCIONES ===== */
.section {
    text-align: center;
    font-size: 1rem;
    margin: 1px 0;
    background-color: #ffaf04;
    border-radius: 8px;
    width: 15%;
    margin-left: 10%;
}

.section h2 {
    font-family: Arial, Helvetica, sans-serif;
    color: #333;
    font-size: 1.3rem;
    padding: 10px 0;
}

/* ===== LISTAS DE PRODUCTOS ===== */
.list-container {
    width: 100%;
    background-color: rgb(247, 194, 81);
    margin-bottom: 7px;
    padding: 3px;
}

.list-group-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.2rem;
    border: none;
    padding: 10px;
}

.product-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.product-name {
    font-size: 1rem;
    color: #333;
    font-family: Arial, Helvetica, sans-serif;
}

span.bidge {
    font-family: Arial, Helvetica, sans-serif;
    color: #333;
    padding: 2px 5px;
    border-radius: 12px;
    font-size: 1.5rem;
    margin-top: 5px;
}

.action-button {
    border: 3px solid #ffaf04;
    color: #333;
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s;
    margin-left: 65%;
    width: 30%;
    margin-top: -50px;
    text-align: center;
    text-decoration: none;
    font-family: Arial, Helvetica, sans-serif;
    background: white;
}

.action-button:hover {
    background-color: #ffaf04;
    color: #333;
    transform: translateY(3px);
}

.action-button:active {
    transform: translateY(1px);
}

/* ===== SECCIÓN SERVICIO ===== */
#servicio {
    margin-top: 5px;
    margin-bottom: 20px;
}

#servicio h3 {
    margin-top: 10%;
    margin-bottom: 15px;
    text-align: left;
}

.contenedor-tipos {
    display: flex;
    gap: 20px;
    justify-content: space-between;
    margin-top: 15px;
}

#tipo1,
#tipo2 {
    flex: 1;
    padding: 15px 10px;
    border-radius: 8px;
    text-align: center;
    background-color: #C1292E;
    color: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
    cursor: pointer;
    text-decoration: none;
}

#tipo1:hover,
#tipo2:hover {
    transform: translateY(-5px);
    background-color: #a82327;
}

#tipo1 i,
#tipo2 i {
    font-size: 1.5em;
    margin-top: 8px;
}

/* ===== HORARIOS ===== */
#horarios {
    max-width: 900px;
    padding: 20px;
    border-radius: 10px;
    background-color: #f5f5f5;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    font-family: Arial, sans-serif;
    margin: 20px auto;
}

#horarios h3 {
    color: #333;
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 3px solid #85877C;
}

.fila {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 0;
}

.fila:last-child {
    border-bottom: none;
}

.fila p {
    margin: 0;
    font-size: 0.95em;
}

.fila i {
    margin: 0 10px;
    color: #333;
}

/* ===== ADMINISTRACIÓN ===== */
#admin-grid-layout {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin: 30px auto;
    margin-bottom: 50px;
    max-width: 1200px;
}

#opcion-admin {
    margin: 20px auto;
    max-width: 1200px;
    padding: 0 15px;
    cursor: pointer;
}

.admin-card-style,
.admin-container {
    max-width: none;
    cursor: pointer;
}

.card-option {
    border: 2px solid #ffaf04;
    border-radius: 8px;
    transition: all 0.3s ease;
    text-align: center;
    padding: 20px;
    text-decoration: none;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 1rem;
    font-weight: bold;
    color: #333;
    background: white;
    display: block;
}

.card-option:hover {
    transform: translateY(-3px);
    background-color: #ffaf04;
    color: #333;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* ===== MODAL OPCIONES ===== */
/* Contenedor principal del modal */
#ventanaoption {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.65);
    justify-content: center;
    align-items: center;
}

/* Contenedor del modal */
.container-option {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 15px;
    position: relative; /* 👈 Necesario para la X */
}

/* Botón cerrar */
.cerrar-opcion {
  position: absolute;   /* 👈 Ya no fixed */
  top: 10px;
  right: 10px;
  font-size: 30px;
  cursor: pointer;
  color: #fff;
  z-index: 11000;
  user-select: none;
  background: rgba(0,0,0,0.25);
  border-radius: 6px;
  padding: 4px 8px;
}


/* Pequeña mejora visual en mobile */
@media (max-width: 480px) {
  .cerrar-opcion { font-size: 26px; top: 12px; right: 12px; }
}



#menu-option {
    background-color: #f5f5f5;
    padding: 20px;
    border-radius: 10px;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    position: relative;
}

#V-card {
    height: 100%;
    width: 100%;
    max-width: 500%;
    margin: 1%;
}

/* ===== MEDIA QUERIES PARA TODOS LOS DISPOSITIVOS ===== */

/* Tablets (768px - 1024px) */
@media (max-width: 1024px) {
    .card {
        width: 45%;
        margin: 20px;
    }
    
    #admin-grid-layout {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        margin: 20px;
    }
    
    .barra a {
        font-size: 1.2rem;
        padding: 0.8% 4%;
    }
}

/* Tablets pequeñas (600px - 768px) */
@media (max-width: 768px) {
    .modal-contenido {
        padding: 20px;
        width: 95%;
    }
    
    .logo {
        width: 12vw;
        height: 12vw;
    }
    
    p.don {
        font-size: 1.8vw;
    }
    
    .card {
        width: 80%;
        margin: 20px auto;
    }
    
    .section {
        width: 50%;
        margin-left: 25%;
    }
    
    .action-button {
        width: 40%;
        margin-left: 60%;
    }
    
    #admin-grid-layout {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .contenedor-tipos {
        flex-direction: column;
        gap: 15px;
    }
}

/* Móviles grandes (480px - 600px) */
@media (max-width: 600px) {
    .modal-contenido {
        padding: 15px;
    }
    
    #baner {
        width: 100%;
        margin-left: 0;
    }
    
    .logo-container {
        height: 60px;
        margin-bottom: 10%;
    }
    
    .logo {
        width: 50px;
        height: 50px;
    }
    
    p.don {
        font-size: 1rem;
        margin-left: 30%;
    }
    
    .fa-circle-exclamation,
    #faceboock,
    #cel,
    #mapa {
        font-size: 1.2rem;
    }
    
    .barra a {
        font-size: 1rem;
        padding: 8px 10px;
        display: block;
        width: 100%;
        margin: 2px 0;
    }
    
    .img-platillo {
        height: 150px;
    }
    
    .section {
        width: 80%;
        margin-left: 10%;
    }
    
    .list-group-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .action-button {
        width: 100%;
        margin: 10px 0 0 0;
    }
    
    .fila {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Móviles medianos (400px - 480px) */
@media (max-width: 480px) {
    .modal-contenido {
        padding: 12px;
    }
    
    .logo-container {
        margin-bottom: 15%;
    }
    
    p.don {
        font-size: 0.9rem;
    }
    
    .fa-circle-exclamation,
    #faceboock,
    #cel,
    #mapa {
        font-size: 1rem;
    }
    
    .barra a {
        font-size: 0.9rem;
        padding: 6px 8px;
    }
    
    .img-platillo {
        height: 120px;
    }
    
    .precio {
        font-size: 1.2rem;
    }
    
    .card i {
        font-size: 1.5rem;
    }
}

/* Móviles pequeños (320px - 400px) */
@media (max-width: 400px) {
    .modal-contenido {
        padding: 10px;
    }
    
    .logo-container {
        margin-bottom: 20%;
    }
    
    p.don {
        font-size: 0.8rem;
        margin-left: 35%;
    }
    
    .fa-circle-exclamation,
    #faceboock,
    #cel,
    #mapa {
        font-size: 0.9rem;
    }
    
    #faceboock { left: 70%; }
    #cel { left: 80%; }
    #mapa { left: 25%; }
    
    .barra a {
        font-size: 0.8rem;
        padding: 5px 6px;
    }
    
    .img-platillo {
        height: 100px;
    }
    
    .precio {
        font-size: 1.1rem;
    }
    
    .product-name {
        font-size: 0.9rem;
    }
    
    span.bidge {
        font-size: 1.2rem;
    }
}

/* Móviles muy pequeños (240px - 320px) */
@media (max-width: 320px) {
    p.don {
        font-size: 0.7rem;
    }
    
    .fa-circle-exclamation,
    #faceboock,
    #cel,
    #mapa {
        font-size: 0.8rem;
    }
    
    .barra a {
        font-size: 0.7rem;
        padding: 4px 5px;
    }
    
    .img-platillo {
        height: 80px;
    }
    
    .precio {
        font-size: 1rem;
    }
    
    .card i {
        font-size: 1.2rem;
    }
}

/* Dispositivos mínimos (200px - 240px) */
@media (max-width: 240px) {
    .modal-contenido {
        padding: 8px;
        font-size: 12px;
    }
    
    .logo-container {
        margin-bottom: 25%;
    }
    
    .logo {
        width: 40px;
        height: 40px;
    }
    
    p.don {
        font-size: 0.6rem;
        margin-left: 40%;
    }
    
    /* Ocultar elementos menos importantes en pantallas muy pequeñas */
    .fa-circle-exclamation {
        display: none;
    }
    
    #faceboock,
    #cel {
        font-size: 0.7rem;
    }
    
    #faceboock { left: 60%; }
    #cel { left: 75%; }
    #mapa { 
        font-size: 0.7rem;
        left: 15%;
    }
    
    .barra a {
        font-size: 0.6rem;
        padding: 3px 4px;
    }
    
    .img-platillo {
        height: 60px;
    }
    
    .precio {
        font-size: 0.9rem;
    }
    
    .product-name {
        font-size: 0.8rem;
    }
    
    span.bidge {
        font-size: 1rem;
    }
    
    .action-button {
        font-size: 0.8rem;
        padding: 6px;
    }
}

/* Para tablas en móviles */
@media (max-width: 768px) {
    .modal-contenido:has(table) {
        overflow-x: auto;
    }
    
    .modal-contenido table {
        font-size: 12px;
        min-width: 400px;
    }
}

/* Mejoras de usabilidad táctil */
@media (max-width: 1024px) {
    .action-button,
    .card-option,
    #tipo1,
    #tipo2,
    .barra a {
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    input, select, textarea {
        min-height: 44px;
    }
}