* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

/* Barra de progreso */
.progress-bar {
    display: flex;
    justify-content: space-between;
    margin-bottom: 30px;
    background: #0a1011;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.progress-step {
    text-align: center;
    flex: 1;
    position: relative;
}

.progress-step::after {
    content: '';
    position: absolute;
    top: 20px;
    right: -50%;
    width: 100%;
    height: 3px;
    background-color: #e0e0e0;
    z-index: 1;
    transition: all 0.3s ease;
}

.progress-step:last-child::after {
    display: none;
}

.progress-step.active::after {
    background-color: #00ffea;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #e0e0e0;
    color: #121B1D;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    font-weight: bold;
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

.progress-step.active .step-number {
    background-color: #00ffea;
    transform: scale(1.1);
}

.step-title {
    font-size: 13px;
    color: #666;
    font-weight: 500;
    transition: all 0.3s ease;
}

.progress-step.active .step-title {
    color: #00ffea;
    font-weight: bold;
}

/* Layout principal */
.main-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
    margin-bottom: 30px;
}

.main-content {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    min-height: 600px;
}

.module {
    display: none;
}

.module.active {
    display: block;
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from { 
        opacity: 0; 
        transform: translateY(30px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

h2 {
    color: #333;
    margin-bottom: 25px;
    font-size: 28px;
    font-weight: 600;
}

/* Módulo 1: Encuadernación */
.binding-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.binding-option {
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    position: relative;
    overflow: hidden;
}

.binding-option::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(53, 248, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.binding-option:hover::before {
    left: 100%;
}

.binding-option:hover {
    border-color: #00ffea;
    box-shadow: 0 8px 25px rgba(53, 255, 245, 0.2);
    transform: translateY(-2px);
}

.binding-option.selected {
    border-color: #00ffea;
    background: linear-gradient(135deg, #fff8f6, #ffffff);
    box-shadow: 0 8px 25px rgba(53, 255, 245, 0.2);
    transform: translateY(-2px);
}

.binding-price {
    color: #121B1D;
    font-weight: bold;
    margin-bottom: 12px;
    font-size: 18px;
}

.binding-title {
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
    font-size: 16px;
}

.binding-description {
    color: #666;
    font-size: 14px;
}

/* Módulo 2: Tamaño */
.size-selector {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.size-categories {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.size-category h3 {
    color: #333;
    margin-bottom: 15px;
    font-size: 18px;
    font-weight: 600;
    border-bottom: 2px solid #00ffea;
    padding-bottom: 5px;
}

.size-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.size-option {
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    font-weight: 500;
}

.size-option:hover {
    border-color: #00ffea;
    background-color: #fff8f6;
    transform: translateX(5px);
}

.size-option.selected {
    border-color: #00ffea;
    background: linear-gradient(135deg, #00ffea, #155853);
    color: white;
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.size-visualizer {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.grid-container {
    position: relative;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    box-shadow: inset 0 2px 8px rgba(0,0,0,0.1);
}

#size-canvas {
    border: 2px solid #ddd;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.size-display {
    margin-top: 20px;
    font-weight: 600;
    color: #333;
    font-size: 18px;
    padding: 10px 20px;
    background: #00ffea;
    color: #0a1011;
    border-radius: 25px;
}

/* Módulo 3: Páginas */
.pages-info {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid #ff6b35;
    margin-bottom: 25px;
}

.pages-info p {
    margin-bottom: 10px;
    color: #666;
    font-size: 15px;
}

.pages-info p:last-child {
    margin-bottom: 0;
}

.pages-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.pages-row {
    display: grid;
    grid-template-columns: 250px 1fr auto;
    gap: 20px;
    align-items: center;
}

.pages-row label {
    font-weight: 600;
    color: #333;
    font-size: 16px;
}

.pages-row input {
    padding: 12px 16px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
}

.pages-row input:focus {
    outline: none;
    border-color: #ff6b35;
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.2);
}

.total-pages {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 12px;
    min-width: 140px;
    border: 2px solid #e0e0e0;
}

.total-pages span {
    display: block;
    font-size: 36px;
    font-weight: bold;
    color: #00ffea;
}

.total-pages div {
    font-size: 11px;
    color: #666;
    margin-top: 5px;
    font-weight: 600;
}

.color-pages-description {
    grid-column: 1 / -1;
}

.color-pages-description label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
    font-size: 16px;
}

.color-pages-description textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    resize: vertical;
    min-height: 120px;
    font-family: inherit;
    font-size: 14px;
    transition: all 0.3s ease;
}

.color-pages-description textarea:focus {
    outline: none;
    border-color: #ff6b35;
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.2);
}

/* Módulo 4: Cantidad */
.quantity-info {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid #ff6b35;
    margin-bottom: 25px;
}

.quantity-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.quantity-row {
    display: grid;
    grid-template-columns: 250px 1fr auto;
    gap: 20px;
    align-items: center;
}

.quantity-row label {
    font-weight: 600;
    color: #333;
    font-size: 16px;
}

.quantity-row input {
    padding: 12px 16px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
}

.quantity-row input:focus {
    outline: none;
    border-color: #ff6b35;
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.2);
}

.total-books {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 12px;
    min-width: 140px;
    border: 2px solid #e0e0e0;
}

.total-books span {
    display: block;
    font-size: 36px;
    font-weight: bold;
    color: #00ffea;
}

.total-books div {
    font-size: 11px;
    color: #666;
    margin-top: 5px;
    font-weight: 600;
}

.error-message {
    color: #d32f2f;
    font-size: 14px;
    padding: 12px;
    background: #ffebee;
    border-radius: 8px;
    border-left: 4px solid #d32f2f;
}

/* Módulo 5: Cotización */
.quote-note {
    background: linear-gradient(135deg, #e3f2fd, #f8f9fa);
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid #2196f3;
    margin-bottom: 25px;
}

.quote-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.quote-main {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.quick-price {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 25px;
    border-radius: 12px;
    border: 2px solid #e0e0e0;
}

.price-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.price-item:last-child {
    margin-bottom: 0;
}

.price-item .label {
    font-size: 20px;
    color: #333;
    font-weight: 600;
}

.price-item .value {
    font-size: 28px;
    font-weight: bold;
    color: #0a1011;
}

.books-count {
    text-align: center;
    font-size: 18px;
    color: #666;
    margin-top: 15px;
    font-weight: 500;
}

.rush-services h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 20px;
    font-weight: 600;
}

.rush-option {
    margin-bottom: 15px;
    padding: 10px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.rush-option:hover {
    background-color: #f8f9fa;
}

.rush-option input[type="radio"] {
    margin-right: 10px;
    transform: scale(1.2);
}

.rush-option label {
    font-size: 15px;
    color: #333;
    cursor: pointer;
    font-weight: 500;
}

.rush-note {
    font-size: 13px;
    color: #666;
    margin-top: 15px;
    margin-bottom: 10px;
    font-style: italic;
}

.shipping-section {
    border-top: 2px solid #e0e0e0;
    padding-top: 25px;
}

.shipping-estimate {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    align-items: center;
}

.shipping-estimate label {
    font-weight: 600;
    color: #333;
    font-size: 16px;
}

.shipping-estimate input {
    padding: 10px 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    width: 150px;
    transition: all 0.3s ease;
}

.shipping-estimate input:focus {
    outline: none;
    border-color: #2196f3;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.2);
}

.shipping-estimate button {
    padding: 10px 20px;
    background: linear-gradient(135deg, #2196f3, #1976d2);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.shipping-estimate button:hover {
    background: linear-gradient(135deg, #1976d2, #1565c0);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(33, 150, 243, 0.3);
}

.shipping-cost {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.shipping-cost .label {
    font-size: 18px;
    color: #333;
    font-weight: 600;
}

.shipping-cost .value {
    font-size: 20px;
    font-weight: bold;
    color: #666;
}

.total-section {
    border-top: 3px solid #ff6b35;
    padding-top: 25px;
}

.total-price {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.total-price .label {
    font-size: 24px;
    font-weight: bold;
    color: #333;
}

.total-price .value {
    font-size: 32px;
    font-weight: bold;
    color: #121B1D;
}

/* Panel lateral de cotización */
.quote-sidebar {
    background: linear-gradient(135deg, #37474f, #263238);
    color: white;
    border-radius: 12px;
    overflow: hidden;
    height: fit-content;
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
    position: sticky;
    top: 20px;
}

.sidebar-header {
    background: linear-gradient(135deg, #263238, #1c2833);
    padding: 20px;
    text-align: center;
    font-weight: bold;
    font-size: 16px;
    letter-spacing: 1px;
}

.sidebar-content {
    padding: 25px 20px;
}

.sidebar-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 13px;
    align-items: center;
}

.sidebar-label {
    color: #cfd8dc;
    font-weight: 500;
}

.sidebar-value {
    color: white;
    font-weight: 600;
    text-align: right;
}

.sidebar-divider {
    height: 2px;
    background: linear-gradient(90deg, transparent, #455a64, transparent);
    margin: 20px 0;
}

.sidebar-total {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 2px solid #455a64;
}

.sidebar-total .sidebar-label {
    font-size: 16px;
    font-weight: bold;
}

.sidebar-total .sidebar-value {
    font-size: 22px;
    font-weight: bold;
    color: #00ffea;
}

.shipping-note {
    text-align: center;
    font-size: 11px;
    color: #cfd8dc;
    margin-top: 8px;
    font-style: italic;
}

/* Botones de navegación */
.navigation-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
}

.navigation-buttons button {
    padding: 15px 40px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#prev-btn {
    background: linear-gradient(135deg, #6c757d, #5a6268);
    color: white;
}

#prev-btn:hover {
    background: linear-gradient(135deg, #5a6268, #495057);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(108, 117, 125, 0.3);
}

#next-btn {
    background: linear-gradient(135deg, #00ffea, #155853);
    color: white;
}

#next-btn:hover {
    background: linear-gradient(135deg, #155853, #00ffea);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

#next-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Mensaje final */
.final-message {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    text-align: center;
    margin-top: 20px;
}

.final-message h2 {
    color: #ff6b35;
    margin-bottom: 20px;
}

.final-message p {
    color: #666;
    font-size: 16px;
    line-height: 1.6;
}

/* Responsive */
@media (max-width: 1200px) {
    .main-layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .quote-sidebar {
        position: static;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .progress-bar {
        flex-direction: column;
        gap: 15px;
    }
    
    .progress-step::after {
        display: none;
    }
    
    .binding-options {
        grid-template-columns: 1fr;
    }
    
    .size-selector {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    .pages-row,
    .quantity-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .navigation-buttons {
        flex-direction: column;
        gap: 15px;
    }
    
    .navigation-buttons button {
        width: 100%;
    }
    
    .main-content {
        padding: 25px;
    }
}

/* Animaciones adicionales */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.sidebar-value.updating {
    animation: pulse 0.5s ease-in-out;
    color: #ff6b35;
}