body {
    background-color: #3e2f1c; /* Café oscuro */
    color: #f5deb3; /* Beige */
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 20px;
    text-align: center;
}

.titulo {
    margin-bottom: 30px;
    font-size: 2em;
    border-bottom: 2px solid #f5deb3;
    padding-bottom: 10px;
}

.boton-refrescar {
    margin-bottom: 20px;
}

.btn {
    text-decoration: none;
    background-color: #6f4e37;
    color: #fff;
    padding: 10px 20px;
    border-radius: 8px;
    margin: 10px;
    display: inline-block;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #563d2d;
}

.last-refresh-time {
    margin-top: 10px;
    font-size: 1.2em;
    color: #f5deb3;
    margin-bottom: 20px;
}

.ordenes-grid {
    margin: 30px 0;
    padding: 20px;
    border: 2px solid #f5deb3;
    border-radius: 15px;
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.orden {
    padding: 15px;
    border: 1px solid #f5deb3;
    border-radius: 10px;
    text-align: left;
    background-color: #4b3825;
    transition: transform 0.3s;
}

.orden:hover {
    transform: scale(1.05);
}

.orden.atendida {
    background-color: #5a4833;
}

.detalle {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.detalle th, .detalle td {
    border: 1px solid #f5deb3;
    padding: 5px;
    text-align: center;
}

.reimprimir {
    margin-top: 20px;
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    width: 100%;
}

.reimprimir:hover {
    background-color: #388e3c;
}

.atender {
    margin-top: 0px;
    background-color: #f9861e;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
}

.atender:hover {
    background-color: #E9760e;
}

/* Estilos para Orden de Recoger */
.orden-recoger {
    margin: 30px 0;
    padding: 20px;
    border: 3px solid #ff9800;
    border-radius: 15px;
    background-color: #5a3d1f;
    box-shadow: 0 4px 12px rgba(255, 152, 0, 0.3);
}

.orden-recoger h2.recoger {
    color: #ff9800;
    font-size: 1.8em;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.orden-recoger-container {
    display: flex;
    justify-content: center;
}

.orden.recoger-orden {
    background-color: #6b4a2a;
    border: 2px solid #ff9800;
    max-width: 600px;
    width: 100%;
}

.orden.recoger-orden pre {
    background-color: #3e2f1c;
    padding: 15px;
    border-radius: 8px;
    overflow-x: auto;
    color: #f5deb3;
    font-size: 0.9em;
    text-align: left;
    border: 1px solid #f5deb3;
}

.eliminar-recoger {
    margin-top: 15px;
    background-color: #f44336;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    width: 100%;
    font-size: 1em;
    font-weight: bold;
    transition: background-color 0.3s;
}

.eliminar-recoger:hover {
    background-color: #d32f2f;
}

body.productos-page .productos-grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

body.productos-page .producto-item {
    border: 1px solid #f5deb3;
    padding: 15px;
    background-color: #4b3825;
    border-radius: 8px;
    text-align: center;
    transition: transform 0.3s;
}

body.productos-page .producto-item:hover {
    transform: scale(1.05);
}

body.productos-page .foto-mini {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 50%;
    margin-bottom: 10px;
}

/****************************************/
/* 🛠️ Estilos específicos para editar.html */
/****************************************/
.editar-page .formulario-editar {
    max-width: 500px;
    margin: 30px auto;
    padding: 20px;
    background-color: #4b3825; 
    border-radius: 12px;
    border: 2px solid #f5deb3;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.editar-page .formulario-editar label {
    font-weight: bold;
    color: #f5deb3;
    margin-bottom: 5px;
}

.editar-page .formulario-editar input[type="text"],
.editar-page .formulario-editar input[type="file"],
.editar-page .formulario-editar select {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #f5deb3;
    border-radius: 6px;
    font-size: 1em;
    background-color: #3e2f1c;
    color: #f5deb3;
}

.editar-page .foto-mini {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid #f5deb3;
    margin-bottom: 15px;
}

.editar-page .switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    margin-bottom: 15px;
}

.editar-page .switch input {
    display: none;
}

.editar-page .slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: #ccc;
    transition: .3s;
    border-radius: 24px;
}

.editar-page .slider:before {
    content: "";
    height: 16px;
    width: 16px;
    position: absolute;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}

.editar-page input:checked + .slider {
    background-color: #4CAF50; 
}

.editar-page input:checked + .slider:before {
    transform: translateX(20px);
}

.editar-page .btn {
    background-color: #6f4e37;
    color: white;
    padding: 12px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1em;
    transition: background-color 0.3s;
    cursor: pointer;
    width: 100%;
}

.editar-page .btn:hover {
    background-color: #563d2d;
}

.editar-page .btn-guardar {
    background-color: #4CAF50; 
}

.editar-page .btn-guardar:hover {
    background-color: #388e3c;
}

.editar-page .titulo {
    text-align: center;
    font-size: 2em;
    color: #f5deb3;
    margin-bottom: 20px;
}

/****************************************/
/* 🛠️ Estilo para Botón Regresar (editar.html) */
/****************************************/
.editar-page .btn-regresar {
    background-color: #757575; /* Gris suave */
    color: white;
    padding: 12px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1em;
    transition: background-color 0.3s;
    cursor: pointer;
    width: 100%;
    box-sizing: border-box; /* Mantener dentro del recuadro */
}

.editar-page .btn-regresar:hover {
    background-color: #616161; /* Gris oscuro */
}

/****************************************/
/* 🛠️ Estilos para Crear Producto (crear.html) */
/****************************************/
.crear-page .formulario-crear {
    max-width: 500px;
    margin: 30px auto;
    padding: 20px;
    background-color: #4b3825;
    border-radius: 12px;
    border: 2px solid #f5deb3;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.crear-page .formulario-crear label {
    font-weight: bold;
    color: #f5deb3;
    margin-bottom: 5px;
}

.crear-page .formulario-crear input[type="text"],
.crear-page .formulario-crear input[type="file"],
.crear-page .formulario-crear select {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #f5deb3;
    border-radius: 6px;
    font-size: 1em;
    background-color: #3e2f1c;
    color: #f5deb3;
}

.crear-page .foto-mini {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid #f5deb3;
    margin-bottom: 15px;
}

.crear-page .switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    margin-bottom: 15px;
}

.crear-page .switch input {
    display: none;
}

.crear-page .slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background-color: #ccc;
    transition: .3s;
    border-radius: 24px;
}

.crear-page .slider:before {
    content: "";
    height: 16px;
    width: 16px;
    position: absolute;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}

.crear-page input:checked + .slider {
    background-color: #4CAF50; 
}

.crear-page input:checked + .slider:before {
    transform: translateX(20px);
}

.crear-page .btn {
    background-color: #6f4e37;
    color: white;
    padding: 12px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1em;
    transition: background-color 0.3s;
    cursor: pointer;
    width: 100%;
}

.crear-page .btn:hover {
    background-color: #563d2d;
}

.crear-page .btn-guardar {
    background-color: #4CAF50; 
}

.crear-page .btn-guardar:hover {
    background-color: #388e3c;
}

.crear-page .titulo {
    text-align: center;
    font-size: 2em;
    color: #f5deb3;
    margin-bottom: 20px;
}

.crear-page .mensaje-error {
    max-width: 500px;
    margin: 0 auto 20px;
    padding: 12px 16px;
    background-color: #5c2d2d;
    border: 1px solid #c62828;
    border-radius: 8px;
    color: #ffcdd2;
    text-align: center;
}

.crear-page .btn-cancelar {
    background-color: #757575;
    color: white;
    padding: 12px;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1em;
    text-decoration: none;
    text-align: center;
    display: block;
    margin-top: 10px;
    transition: background-color 0.3s;
    box-sizing: border-box; /* Mantener dentro del recuadro */
}

.crear-page .btn-cancelar:hover {
    background-color: #616161;
}
