/* Estilos Base para Escritorio */
#carrito-seccion {
    max-width: 1000px;
    margin: 20px auto;
    padding: 15px;
    font-family: sans-serif;
}

.carrito-tabla {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.carrito-tabla th, .carrito-tabla td {
    padding: 12px;
    border-bottom: 1px solid #ddd;
    text-align: left;
}

.resumen-carrito {
    text-align: right;
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
}

.btn-pagar {
    background-color: #28a745;
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.1rem;
}

/* --- MODO MÓVIL (Media Query) --- */
@media screen and (max-width: 600px) {
    /* Ocultamos el encabezado de la tabla */
    .carrito-tabla thead {
        display: none;
    }

    .carrito-tabla, .carrito-tabla tbody, .carrito-tabla tr, .carrito-tabla td {
        display: block;
        width: 100%;
    }

    .carrito-tabla tr {
        margin-bottom: 15px;
        border: 1px solid #eee;
        border-radius: 8px;
        padding: 10px;
        box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    }

    .carrito-tabla td {
        text-align: right;
        padding-left: 50%;
        position: relative;
        border-bottom: 1px solid #f1f1f1;
    }

    /* Creamos etiquetas usando el contenido antes de cada celda */
    .carrito-tabla td::before {
        content: attr(data-label); /* Necesitaremos agregar este atributo al HTML */
        position: absolute;
        left: 10px;
        width: 45%;
        font-weight: bold;
        text-align: left;
    }

    .carrito-tabla td:last-child {
        border-bottom: none;
    }

    /* Ajuste para la imagen en móvil */
    .carrito-tabla td:first-child {
        text-align: center;
        padding-left: 12px;
    }
    
    .carrito-tabla td:first-child::before {
        content: ""; /* Quitamos la etiqueta para la imagen */
    }
}


/* ============================================ pago estado */
/* Estilos generales de la sección */
.payment-status-container {
    max-width: 600px;
    margin: 20px auto;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    text-align: center;
    border-top: 8px solid #ccc;
}

/* Variaciones de colores */
.status-4 { border-top-color: #28a745; background-color: #f8fff9; } /* Verde - Aprobada */
.status-6 { border-top-color: #dc3545; background-color: #fff8f8; } /* Rojo - Rechazada */
.status-5 { border-top-color: #ffc107; background-color: #fffdf5; } /* Amarillo - Expirada */

.status-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 20px;
}

/* Colores de títulos según el código */
.title-4 { color: #28a745; }
.title-6 { color: #dc3545; }
.title-5 { color: #856404; } /* Un amarillo más oscuro para que sea legible */

.payment-details {
    text-align: left;
    background: white;
    padding: 20px;
    border-radius: 10px;
    border: 1px solid #eee;
    margin-bottom: 20px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f9f9f9;
}

.detail-row b { color: #555; }

.footer-msg {
    color: #666;
    font-style: italic;
    font-size: 14px;
}

.progreso-bar {
    display: flex;
    justify-content: space-between; /* Distribuye los pasos equitativamente */
    align-items: center;
    position: relative;
    max-width: 600px; /* Ancho máximo de la barra */
    margin: 40px auto;
    padding: 0 10px;
}

/* Esta es la línea gris de fondo que conecta todos los números */
.progreso-bar::before {
    content: '';
    position: absolute;
    top: 20px; /* Alineado justo en el centro vertical de los círculos */
    left: 0;
    right: 0;
    height: 4px;
    background-color: #e0e0e0;
    z-index: 1;
}

/* Contenedor individual de cada paso */
.paso {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2; /* Se posiciona por encima de la línea gris */
    flex: 1;
}

/* El círculo con el número */
.numero {
    width: 40px;
    height: 40px;
    background-color: #ffffff;
    border: 3px solid #e0e0e0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #999;
    transition: all 0.3s ease;
}

/* Texto opcional debajo del número */
.texto {
    margin-top: 8px;
    font-size: 14px;
    color: #999;
    font-family: sans-serif;
}

/* ===================================================
   ESTADOS ACTIVOS / COMPLETADOS (Colores de tu marca)
   =================================================== */

/* Cuando agregues la clase .activo al paso, cambiará a azul */
.paso.activo .numero {
    background-color: #1F509F; /* Azul Castellpet */
    border-color: #1F509F;
    color: white;
}

.paso.activo .texto {
    color: #1F509F;
    font-weight: bold;
}
