/**
 * Estilos para Auto Finance Calculator
 */
 
/* Contenedor principal */
.afc-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: stretch;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

/* Estilos originales */
.afc-style1 .afc-form__wrapper {
    width: 60%;
}

.afc-style1 .afc-summary {
    width: 35%;
    background-color: #f9f9f9;
    border-radius: 4px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.afc-style2 .afc-form__wrapper {
    width: 100%;
}

/* Estilo Figma */
.afc-style3 {
    display: flex;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.afc-style3 .afc-form__wrapper {
    width: 48%;
    flex-shrink: 0;
}

.afc-style3 .afc-summary-figma {
    width: calc(52% - 20px);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

/* Títulos y descripciones */
.afc-title {
    font-family: "Roboto", sans-serif;
    color: #232221;
    font-size: 24px;
    margin-bottom: 10px;
    font-weight: 600;
}

.afc-description {
    font-family: "Roboto", sans-serif;
    color: #666;
    font-size: 16px;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* Wrapper del formulario */
.afc-form__wrapper {
    overflow: hidden;
    margin: 0 auto;
    width: 100%;
    height: auto;
    position: relative;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* Contenedor del formulario */
.afc-form__container {
    padding: 20px;
}

/* Etiquetas */
.afc-form__label {
    font-family: "Roboto", sans-serif;
    color: #232221;
    font-size: 16px;
    margin-bottom: 10px;
    font-weight: 500;
}

/* Select */
.afc-select-modelo {
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: #f5f5f5;
    width: 100%;
    margin-bottom: 20px;
    appearance: none;
    background-image: url('data:image/svg+xml;charset=US-ASCII,<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M6 9l6 6 6-6"/></svg>');
    background-repeat: no-repeat;
    background-position: right 10px center;
    cursor: pointer;
}

.afc-select-modelo:focus {
    outline: none;
    border-color: #0B62BD;
    box-shadow: 0 0 0 2px rgba(11, 98, 189, 0.2);
}

.afc-select-modelo option {
    padding: 10px;
    font-size: 16px;
}

/* Filas de opciones */
.afc-form__row {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 20px;
}

/* Contenedores de campos */
.afc-form__field__container {
    position: relative;
    padding: 5px;
    vertical-align: top;
}

.afc-form__field__container--half {
    width: 32.5%;
    display: inline-block;
}

/* Campos */
.afc-form__field--half {
    display: flex;
    width: 100%;
    height: 30px;
    border-radius: 2px;
    text-align: center;
    border: 1px solid #d8d9da;
    transition: all ease 0.3s;
    margin-bottom: 10px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}

/* Opciones seleccionadas */
.afc-selected {
    background-color: #e7eff8;
    color: #0B62BD;
    position: relative;
    padding-right: 30px;
}

.afc-selected::before {
    content: '';
    position: absolute;
    top: 50%;
    right: 10px;
    width: 12px;
    height: 12px;
    background-image: url('data:image/svg+xml;charset=US-ASCII,<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="%230B62BD" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="20 6 9 17 4 12"></polyline></svg>');
    background-size: cover;
    background-repeat: no-repeat;
    transform: translateY(-50%);
}

/* Botón */
.afc-form__button {
    white-space: nowrap;
    display: flex;
    width: 100%;
    height: 40px;
    text-align: center;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 6px rgba(50, 50, 93, 0.11), 0 1px 3px rgba(0, 0, 0, 0.08);
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.025em;
    color: #fff !important;
    background: #23D366;
    text-decoration: none !important;
    transition: all 0.15s ease;
    cursor: pointer;
    margin: 20px auto;
    border-radius: 100px;
}

.afc-form__button:hover {
    transform: translateY(-1px);
    box-shadow: 0 7px 14px rgba(50, 50, 93, 0.1), 0 3px 6px rgba(0, 0, 0, 0.08);
    color: #fff !important;
}

#afc-whats-icon {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    margin-bottom: -2px;
}

/* Resumen */
.afc-summary__row {
    display: flex;
    justify-content: space-between;
    padding: 15px 0;
    border-bottom: 1px solid #eee;
}

.afc-summary__row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.afc-summary__label {
    color: #232221;
    font-weight: 500;
    font-size: 16px;
}

.afc-summary__value {
    color: #0B62BD;
    font-weight: 600;
    font-size: 16px;
}

/* Textos legales */
.afc-legal-text {
    margin-top: 20px;
    font-size: 12px;
    color: #777;
    line-height: 1.4;
}

.afc-small-legal-text {
    margin-top: 20px;
    font-size: 11px;
    color: #999;
    line-height: 1.3;
}

/* Estilos específicos para Figma */
.afc-summary-data {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    z-index: 1;
    margin-top: 20px;
}

/* Fondo e imagen de marca de agua */
.afc-summary-figma {
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.afc-watermark-text {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding-top: 20px;
    font-size: 4vw;
    font-weight: 700;
    color: rgba(200, 210, 220, 0.2);
    white-space: nowrap;
    user-select: none;
    pointer-events: none;
    z-index: 2;
    text-align: center;
}

.afc-figma-car-container {
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    max-height: 250px;
    overflow: hidden;
    margin-top: 70px; /* Espacio para que esté debajo del texto */
}

.afc-figma-car-image {
    max-width: 100%;
    max-height: 250px;
    object-fit: contain;
}

.afc-summary-figma .afc-summary__row {
    padding: 12px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.afc-summary-figma .afc-summary__label {
    font-size: 17px;
}

.afc-summary-figma .afc-summary__value {
    font-size: 17px;
}

/* Checkbox para protección adicional */
.afc-protection-option {
    margin: 15px 0;
    padding: 10px;
    border: 1px solid #eee;
    border-radius: 4px;
    background-color: #f9f9f9;
}

.afc-checkbox-container {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.afc-checkbox-container input[type="checkbox"] {
    margin-right: 10px;
}

.afc-checkbox-text {
    flex-grow: 1;
}

.afc-info-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background-color: #0B62BD;
    color: white;
    text-align: center;
    line-height: 16px;
    font-size: 12px;
    font-style: italic;
    cursor: help;
    margin-left: 5px;
}

.afc-protection-cost {
    margin: 5px 0 0 25px;
    font-size: 12px;
    color: #666;
}

#afc-agencias-list {
    margin-top: 10px;
}

.afc-agencia-item {
    display:flex;
    justify-content: space-between;
    align-items:center;
    padding:10px;
    border:1px solid #ddd;
    margin-bottom:5px;
}

.afc-contactar {
    background:#25D366;
    color:#fff;
    border:none;
    padding:5px 10px;
    cursor:pointer;
}

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.afc-fade-in {
    animation: fadeIn 0.3s ease-in;
}

.afc-agencias-list {
    margin-top: 15px;
}

.afc-agencia-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f5f7fa;
    padding: 12px 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    transition: all 0.2s ease;
}

.afc-agencia-item:hover {
    background: #e9eef3;
}

.afc-agencia-item span {
    font-weight: 500;
    color: #333;
}

/* BOTÓN WHATSAPP 🔥 */
.afc-contactar {
    background-color: #25D366;
    color: #fff;
    border: none;
    padding: 8px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

/* Hover */
.afc-contactar:hover {
    background-color: #1ebe5d;
    transform: scale(1.05);
}

/* Efecto click */
.afc-contactar:active {
    transform: scale(0.95);
}

/* Responsivo */
@media screen and (max-width: 991px) {
    .afc-style3 {
        flex-direction: column;
    }
    
    .afc-style3 .afc-form__wrapper,
    .afc-style3 .afc-summary-figma {
        width: 100%;
    }
    
    .afc-watermark-text {
        font-size: 8vw;
    }
    
    .afc-figma-car-container {
        max-height: 200px;
        margin-top: 50px;
    }
    
    .afc-figma-car-image {
        max-height: 200px;
    }
}

@media screen and (max-width: 768px) {
    .afc-style1 .afc-form__wrapper,
    .afc-style1 .afc-summary {
        width: 100%;
    }
    
    .afc-form__wrapper {
        margin: 20px auto;
    }
    
    .afc-form__container {
        padding: 15px;
    }
    
    .afc-select-modelo {
        width: 100%;
    }
    
    .afc-form__field__container--half {
        width: 31%;
    }
    
    .afc-form__button {
        width: 100%;
    }
    
    .afc-protection-option {
        padding: 10px;
    }
}

@media screen and (max-width: 480px) {
    .afc-form__wrapper {
        height: auto !important;
    }
    
    .afc-form__container {
        padding: 10px !important;
    }
    
    .afc-form__field__container--half {
        width: 31% !important;
    }
    
    .afc-selected::before {
        right: 5px;
        width: 10px;
        height: 10px;
    }
    
    .afc-figma-car-image {
        max-height: 150px;
    }
    
    .afc-watermark-text {
        font-size: 10vw;
        opacity: 0.15;
    }
    
    .afc-summary-figma .afc-summary__label,
    .afc-summary-figma .afc-summary__value {
        font-size: 15px;
    }
}