* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, #000 0%, #1a1a1a 100%);
    min-height: 100vh;
    padding: 15px;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(255, 215, 0, 0.5);
    overflow: visible;
    border: 4px solid #ffd700;
}

header {
    background: #000;
    color: #fff;
    padding: 40px 20px;
    text-align: center;
    border-bottom: 5px solid #ffd700;
    position: sticky;
    top: 0;
    z-index: 999;
    border-radius: 15px 15px 0 0;
    margin-top: -15px;
}

header h1 {
    font-size: 2.5em;
    color: #ffd700;
    text-shadow: 3px 3px 6px rgba(255, 215, 0, 0.3);
    margin-bottom: 10px;
}

header p {
    font-size: 1.1em;
    color: #fff;
}

.promo-banner {
    background: linear-gradient(90deg, #ffd700, #ffed4e);
    padding: 15px;
    text-align: center;
    animation: pulse 2s infinite;
    color: #000;
    font-weight: 700;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
}

.content {
    padding: 20px;
    background: #fff;
}

h2 {
    color: #000;
    font-size: 1.8em;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 4px solid #ffd700;
}

.filtros {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin: 20px 0;
}

.filtro-btn {
    padding: 10px 20px;
    border: 3px solid #ffd700;
    background: #fff;
    color: #000;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 700;
    transition: all .3s;
}

.filtro-btn:hover,
.filtro-btn.active {
    background: #ffd700;
}

.catalogo {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.producto {
    background: #fff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transition: transform .3s;
    border: 4px solid #ffd700;
}

.producto:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 35px rgba(255, 215, 0, 0.4);
}

.producto-img {
    width: 100%;
    height: 200px;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.producto-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.producto-img-placeholder {
    color: #999;
    font-size: 60px;
}

.producto-header {
    background: #000;
    padding: 15px;
    border-bottom: 3px solid #ffd700;
}

.producto-tipo {
    font-size: 11px;
    color: #ffd700;
    font-weight: 700;
    text-transform: uppercase;
}

.producto-nombre {
    font-size: 18px;
    font-weight: 900;
    color: #fff;
    margin-top: 5px;
}

.producto-body {
    padding: 15px;
}

.producto-desc {
    color: #555;
    font-size: 13px;
    min-height: 40px;
    margin-bottom: 15px;
    line-height: 1.4;
}

.producto-precio {
    font-size: 32px;
    font-weight: 900;
    color: #000;
    margin-bottom: 10px;
}

.producto-stock {
    background: #000;
    color: #ffd700;
    padding: 5px 12px;
    border-radius: 5px;
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 15px;
    border: 2px solid #ffd700;
}

.producto-stock.bajo {
    background: #fff;
    color: #d32f2f;
    border-color: #d32f2f;
}

.producto-stock.agotado {
    background: #d32f2f;
    color: #fff;
    border-color: #d32f2f;
}

.cantidad-control {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
}

.cantidad-btn {
    background: #ffd700;
    color: #000;
    border: 2px solid #000;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 18px;
    font-weight: 900;
    cursor: pointer;
    transition: all .3s;
}

.cantidad-btn:hover {
    background: #000;
    color: #ffd700;
}

.cantidad-input {
    width: 50px;
    text-align: center;
    font-size: 18px;
    font-weight: 900;
    border: 3px solid #ffd700;
    border-radius: 8px;
    padding: 6px;
}

.btn-agregar {
    background: #ffd700;
    color: #000;
    padding: 12px;
    border: 2px solid #000;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 900;
    width: 100%;
    transition: all .3s;
}

.btn-agregar:hover {
    background: #000;
    color: #ffd700;
}

.btn-agregar:disabled {
    background: #ccc;
    color: #666;
    cursor: not-allowed;
    border-color: #999;
}

.carrito-flotante {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background: #ffd700;
    color: #000;
    width: 65px;
    height: 65px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.6);
    transition: all .3s;
    z-index: 100;
    border: 4px solid #000;
}

.carrito-flotante:hover {
    transform: scale(1.15);
    background: #000;
    color: #ffd700;
}

.carrito-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #d32f2f;
    color: #fff;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 900;
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: #fff;
    padding: 25px;
    border-radius: 15px;
    width: 95%;
    max-width: 550px;
    max-height: 90vh;
    overflow-y: auto;
    border: 4px solid #ffd700;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 4px solid #ffd700;
}

.modal-header h2 {
    border: none;
    padding: 0;
    margin: 0;
    font-size: 1.8em;
}

.close {
    font-size: 28px;
    cursor: pointer;
    color: #000;
    font-weight: 900;
    transition: color 0.3s;
}

.close:hover {
    color: #d32f2f;
}

.carrito-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    border: 2px solid #ffd700;
    margin-bottom: 10px;
    border-radius: 8px;
}

.carrito-item-img {
    width: 50px;
    height: 50px;
    border-radius: 5px;
    object-fit: cover;
    margin-right: 10px;
}

.carrito-item-info {
    flex: 1;
}

.carrito-item-nombre {
    font-weight: 900;
    color: #000;
    font-size: 14px;
}

.carrito-item-precio {
    color: #666;
    font-size: 12px;
    margin-top: 3px;
}

.carrito-item-cantidad {
    margin: 0 10px;
    font-weight: 900;
    font-size: 16px;
}

.carrito-total {
    margin-top: 20px;
    background: #000;
    padding: 20px;
    border-radius: 10px;
    text-align: right;
}

.carrito-total-label {
    font-size: 18px;
    color: #ffd700;
}

.carrito-total-precio {
    font-size: 36px;
    font-weight: 900;
    color: #fff;
    margin-top: 8px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 700;
    color: #000;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 3px solid #ffd700;
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
}

.form-group input:focus {
    outline: none;
    border-color: #ff6b35;
    box-shadow: 0 0 10px rgba(255, 107, 53, 0.3);
}

.btn-confirmar {
    background: #ffd700;
    color: #000;
    padding: 14px;
    border: 2px solid #000;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 900;
    width: 100%;
    transition: all .3s;
}

.btn-confirmar:hover {
    background: #000;
    color: #ffd700;
    transform: translateY(-2px);
}

.btn-confirmar:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.btn-eliminar {
    background: #d32f2f;
    color: #fff;
    border: none;
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 700;
    font-size: 12px;
    transition: all 0.3s;
}

.btn-eliminar:hover {
    background: #b71c1c;
    transform: scale(1.05);
}

.carrito-vacio {
    text-align: center;
    padding: 40px;
    color: #999;
}

.carrito-vacio h3 {
    color: #000;
    margin-bottom: 10px;
    font-size: 1.5em;
}

.carrito-vacio p {
    font-size: 1.1em;
}

.mensajeError {
    background: #d32f2f;
    color: white;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    display: none;
}

.mensajeError.show {
    display: block;
}

.loading {
    text-align: center;
    padding: 30px;
    color: #ffd700;
    font-size: 1.2em;
    font-weight: 700;
}

@media (max-width: 768px) {
    .catalogo {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }

    header h1 {
        font-size: 1.8em;
    }

    .modal-content {
        max-width: 90vw;
    }

    .carrito-item {
        flex-direction: column;
        gap: 10px;
    }
}

/* ===== ANIMACIONES PARA NOTIFICACIONES ===== */

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

/* ===== NOTIFICACIÓN DE ÉXITO FLOTANTE ===== */

.notificacion-exitosa {
    position: fixed;
    bottom: 100px;
    right: 25px;
    background: #4caf50;
    color: white;
    padding: 15px 25px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    font-weight: 700;
    animation: slideIn 0.3s ease-in-out;
    border-left: 5px solid #45a049;
}

/* ============================================
   BARRA DE USUARIO Y CERRAR SESIÓN
   Agregar al final de tu VistaSocios.css existente
   ============================================ */

/* Ajustar body y container para dejar espacio a la barra y header */
body {
    padding-top: 60px !important;
}

/* Hacer que el container también deje espacio para el header fijo */
.container {
    padding-top: 20px;
}

/* Si el header existe, hacerlo fijo también */
header {
    position: sticky;
    top: 60px; /* Justo debajo de la barra de usuario */
    z-index: 999;
    margin-bottom: 20px;
}

/* Barra de usuario fija arriba */
.user-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    padding: 12px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    border-bottom: 3px solid #ffd700;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    font-weight: 600;
    font-size: 15px;
}

.user-icon {
    background: #ffd700;
    color: #000;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.btn-logout {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(231, 76, 60, 0.3);
}

.btn-logout:hover {
    background: linear-gradient(135deg, #c0392b 0%, #a93226 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(231, 76, 60, 0.4);
}

.btn-logout:active {
    transform: translateY(0);
}

/* Modal de confirmación de cerrar sesión */
.modal-logout {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10000;
    justify-content: center;
    align-items: center;
}

.modal-logout.active {
    display: flex;
}

.modal-logout-content {
    background: linear-gradient(135deg, #2d2d2d 0%, #1a1a1a 100%);
    padding: 35px;
    border-radius: 15px;
    max-width: 400px;
    text-align: center;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.5);
    border: 2px solid #ffd700;
}

.modal-logout-content h3 {
    color: #ffd700;
    margin-bottom: 15px;
    font-size: 24px;
    font-weight: 900;
}

.modal-logout-content p {
    color: #bbb;
    margin-bottom: 25px;
    font-size: 15px;
    line-height: 1.6;
}

.modal-logout-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.btn-cancelar {
    background: #95a5a6;
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.btn-cancelar:hover {
    background: #7f8c8d;
    transform: translateY(-2px);
}

.btn-confirmar-logout {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.btn-confirmar-logout:hover {
    background: linear-gradient(135deg, #c0392b 0%, #a93226 100%);
    transform: translateY(-2px);
}

/* Responsive para móviles */
@media (max-width: 768px) {
    body {
        padding-top: 55px !important;
    }

    .user-bar {
        padding: 10px 15px;
    }
    
    .user-info {
        font-size: 13px;
    }
    
    .user-icon {
        width: 30px;
        height: 30px;
        font-size: 16px;
    }
    
    .btn-logout {
        padding: 8px 15px;
        font-size: 12px;
    }

    .modal-logout-content {
        margin: 20px;
        padding: 25px;
    }

    .modal-logout-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .btn-cancelar,
    .btn-confirmar-logout {
        width: 100%;
    }
}