:root {
    --primary: #2c3e50;
    --secondary: #3498db;
    --accent: #e74c3c;
    --light: #ecf0f1;
    --dark: #2c3e50;
    --success: #2ecc71;
    --warning: #f39c12;
    --danger: #e74c3c;
    --gray: #ddd;
}

.shipping-options {
    width: 100%;
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 100%);
    color: #333;
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
}

.shipping-options h3 {
    margin-bottom: 15px;
    text-align: center;
    font-size: 1.3em;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    padding-bottom: 10px;
    color: #2c3e50;
}

.shipping-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    padding: 12px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.7);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.shipping-option:hover {
    background: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
}

.shipping-option.selected {
    background: rgba(46, 204, 113, 0.2);
    border: 2px solid #2ecc71;
}

.shipping-option.consultar {
    background: rgba(52, 152, 219, 0.2);
    border: 2px solid #3498db;
}

.shipping-method {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.shipping-method i {
    font-size: 1.3em;
    width: 24px;
    color: #2c3e50;
}

.shipping-title {
    font-weight: 600;
    color: #2c3e50;
}

.shipping-price {
    font-weight: bold;
    color: #27ae60;
    font-size: 1.1em;
}

.shipping-option.consultar .shipping-price {
    color: #e74c3c;
    font-style: italic;
}

/* Estilo para la opción "Sin Respaldo" */
.option-card[data-sin-respaldo="true"] {
    border: 2px dashed #e74c3c;
    background-color: rgba(231, 76, 60, 0.05);
}

.option-card[data-sin-respaldo="true"]:hover {
    border-color: #c0392b;
    background-color: rgba(231, 76, 60, 0.1);
}

.option-card[data-sin-respaldo="true"].selected {
    border: 2px solid #27ae60;
    background-color: rgba(39, 174, 96, 0.1);
}

.option-card[data-sin-respaldo="true"] p {
    margin-top: 5px;
    font-size: 0.9em;
}


* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f9f9f9;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    background: var(--primary);
    color: white;
    padding: 5px 0;
    text-align: center;
    border-radius: 0 0 15px 15px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin-bottom: 10px;
}

.select-container {
    margin-bottom: 20px;
}

.select-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark);
}

.select-container select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--gray);
    border-radius: 8px;
    font-size: 16px;
    background-color: white;
    transition: all 0.3s;
    cursor: pointer;
}

.select-container select:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(44, 62, 80, 0.1);
}

.select-container select:hover {
    border-color: #a0a0a0;
}

.logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 15px;
}

.logo {
    font-size: 2.5rem;
    font-weight: bold;
    color: white;
}

h1 {
    font-size: 2.2rem;
    margin-bottom: 10px;
}

.main-content {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    margin-bottom: 40px;
}

.customization-section {
    flex: 2;
    min-width: 300px;
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.08);
}

.preview-section {
    flex: 1;
    min-width: 300px;
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    align-items: center;
}

h2 {
    color: var(--primary);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 3px solid var(--light);
}

.customization-step {
    margin-bottom: 30px;
}

.step-title {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.step-number {
    background-color: var(--primary);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-right: 10px;
    font-weight: bold;
}

.select-container {
    margin-bottom: 20px;
}

.select-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark);
}

.select-container select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--gray);
    border-radius: 8px;
    font-size: 16px;
    background-color: white;
    transition: border-color 0.3s;
}

.select-container select:focus {
    border-color: var(--primary);
    outline: none;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
}

.option-card {
    border: 2px solid var(--gray);
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.option-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.option-card.selected {
    border-color: var(--primary);
    background-color: rgba(58, 99, 81, 0.05);
}

.option-card img {
    max-width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 5px;
    margin-bottom: 10px;
}

.color-options {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.color-option {
    height: 40px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.color-option.selected {
    border: 3px solid var(--primary);
    transform: scale(1.05);
}

.color-option:hover {
    transform: scale(1.05);
}

.color-name {
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 2px 5px;
    border-radius: 4px;
    font-size: 12px;
}

.preview-container {
    width: 100%;
    height: 250px;
    background-color: #f5f5f5;
    border-radius: 10px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.preview-sommier {
    width: 80%;
    height: 70%;
    background-color: #8d6e63;
    border-radius: 10px;
    position: relative;
    transition: all 0.3s ease;
}

.preview-headboard {
    width: 110%;
    height: 100%;
    position: absolute;
    top: -30%;
    left: -5%;
    border-radius: 10px 10px 0 0;
    transition: all 0.3s ease;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Estilo por defecto si no hay imagen */
.preview-headboard:not([style*="background-image"]) {
    background-color: #6d4c41; /* Color de respaldo por defecto */
}

.preview-pillows {
    width: 40%;
    height: 20%;
    background-color: #f0f0f0;
    position: absolute;
    top: 10%;
    left: 30%;
    border-radius: 5px;
    display: flex;
    justify-content: space-around;
    align-items: center;
    transition: all 0.3s ease;
}

.pillow {
    width: 40%;
    height: 70%;
    background-color: #f0f0f0;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.summary-box {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.total {
    font-weight: bold;
    font-size: 1.4em;
    color: white;
    border-top: 2px solid rgba(255, 255, 255, 0.5);
    padding-top: 15px;
    margin-top: 15px;
}

.btn-group {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}


#checkoutBtn {
    background-color: #25D366; /* Verde de WhatsApp */
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

#checkoutBtn:hover {
    background-color: #128C7E; /* Verde más oscuro al hover */
}

#checkoutBtn i {
    font-size: 20px;
}


button {
    flex: 1;
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s;
}

button:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
}

#resetBtn {
    background-color: var(--accent);
}

#resetBtn:hover {
    background-color: #d45a3c;
}

.price {
    font-weight: bold;
    color: var(--primary);
    margin-top: 5px;
}

.order-confirmation {
    background: #d4edda;
    color: #155724;
    padding: 15px;
    border-radius: 5px;
    margin: 20px 0;
    text-align: center;
}

.loading {
    text-align: center;
    padding: 20px;
    font-style: italic;
    color: #666;
}

.loading::after {
    content: '';
    animation: loading 1.5s infinite;
}


.payment-options {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
}

.payment-options h3 {
    margin-bottom: 15px;
    text-align: center;
    font-size: 1.3em;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
    padding-bottom: 10px;
}

.payment-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding: 10px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.payment-option.highlighted {
    background: rgba(39, 174, 96, 0.3);
    border: 1px solid #27ae60;
}

.payment-option.special {
    background: rgba(155, 89, 182, 0.3);
    border: 1px solid #9b59b6;
}

.payment-method {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.payment-method i {
    font-size: 1.2em;
    width: 20px;
}

.payment-title {
    font-weight: 600;
}

.payment-subtitle {
    font-size: 0.8em;
    opacity: 0.9;
    display: block;
    margin-top: 2px;
}

.payment-amount {
    font-weight: bold;
    font-size: 1.1em;
}

.payment-details {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.cuota-amount {
    font-weight: bold;
    font-size: 1.1em;
}

.cuota-text {
    font-size: 0.8em;
    opacity: 0.9;
}


@keyframes loading {
    0% { content: '.'; }
    33% { content: '..'; }
    66% { content: '...'; }
}

footer {
    text-align: center;
    padding: 20px;
    margin-top: 40px;
    background-color: var(--dark);
    color: white;
    border-radius: 10px 10px 0 0;
}

@media (max-width: 768px) {
    .main-content {
        flex-direction: column;
    }
    
    .options-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
    
    .color-options {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    }
    
    .btn-group {
        flex-direction: column;
    }
}