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

body {
    font-family: 'Quicksand', sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f8f9fa;
}

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

.hidden { display: none; }

/* FIXES UNIVERSALES PARA iOS - Color #999 en todos los inputs */
.form-group input,
.form-group select {
    width: 100%;
    padding: 13px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px; /* Importante para iOS */
    font-family: 'Quicksand', sans-serif;
    transition: border-color 0.3s;
    background-color: #ffffff !important;
    color: #999 !important; /* Color principal para todos */
}

.form-group input:not(:placeholder-shown),
.form-group select:not([value=""]),
.form-group input:valid,
.form-group select:valid {
    color: #999 !important; /* Mantener #999 incluso con contenido */
}

/* SELECT fixes espec&#65533;ficos para iOS */
.form-group select {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e") !important;
    background-position: right 12px center !important;
    background-repeat: no-repeat !important;
    background-size: 16px !important;
    padding-right: 40px !important;
    -webkit-box-shadow: none;
    box-shadow: none;
}

.form-group select option {
    background-color: #ffffff !important;
    color: #999 !important;
}

/* WRAPPER PARA INPUT DATE CON ICONO */
.date-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.date-input-wrapper input[type="date"],
.date-input-wrapper input[type="text"] {
    padding-right: 45px !important;
}

.calendar-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    pointer-events: none;
    z-index: 2;
}

/* INPUT DATE fixes optimizado para m&#65533;viles */
input[type="date"] {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    background-color: #ffffff !important;
    color: #999 !important;
}

/* Mejorar la experiencia del calendario en m&#65533;viles */
input[type="date"]::-webkit-calendar-picker-indicator {
    opacity: 0;
    position: absolute;
    right: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    z-index: 3;
}

/* Para dispositivos m&#65533;viles, hacer el indicador m&#65533;s grande */
@media (max-width: 768px) {
    input[type="date"]::-webkit-calendar-picker-indicator {
        width: 100%;
        height: 100%;
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        opacity: 0;
        cursor: pointer;
        z-index: 5;
    }
    
    /* Hacer el icono clickeable en m&#65533;vil */
    .calendar-icon {
        pointer-events: auto !important;
        cursor: pointer !important;
        z-index: 4;
    }
    
    /* Fix para input de fecha en m&#65533;viles - MISMO TAMA&#65533;O QUE OTROS CAMPOS */
    input[type="date"] {
        font-size: 16px !important; /* FORZAR mismo tama&#65533;o que otros inputs */
        line-height: 1.2 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }
    
    /* Asegurar que todos los inputs de fecha tengan el mismo tama&#65533;o */
    .form-group input[type="date"] {
        font-size: 16px !important;
        padding: 10px 15px !important;
    }
    
    .date-input-wrapper input[type="date"],
    .date-input-wrapper input[type="text"] {
        padding-right: 35px !important;
        min-width: 0 !important;
        width: 100% !important;
        font-size: 16px !important; /* FORZAR tama&#65533;o */
    }
    
    .calendar-icon {
        right: 8px !important;
        width: 16px !important;
        height: 16px !important;
    }
}

input[type="date"]::-webkit-datetime-edit-text,
input[type="date"]::-webkit-datetime-edit-month-field,
input[type="date"]::-webkit-datetime-edit-day-field,
input[type="date"]::-webkit-datetime-edit-year-field {
    color: #999 !important;
}

input[type="date"]:valid::-webkit-datetime-edit-text,
input[type="date"]:valid::-webkit-datetime-edit-month-field,
input[type="date"]:valid::-webkit-datetime-edit-day-field,
input[type="date"]:valid::-webkit-datetime-edit-year-field {
    color: #999 !important; /* Mantener #999 en lugar de #333 */
}

/* Para iOS espec&#65533;ficamente - mejorar el comportamiento del date picker */
@supports (-webkit-touch-callout: none) {
    input[type="date"] {
        /* Asegurar que el date picker funcione bien en iOS */
        -webkit-appearance: none !important;
        appearance: none !important;
    }
    
    input[type="date"]::-webkit-date-and-time-value {
        color: #999 !important;
    }
    
    input[type="date"]:valid::-webkit-date-and-time-value {
        color: #999 !important; /* Mantener #999 en lugar de #333 */
    }
    
    /* En iOS, hacer toda el &#65533;rea clickeable */
    input[type="date"]::-webkit-calendar-picker-indicator {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100%;
        opacity: 0;
        cursor: pointer;
        z-index: 6;
    }
}

/* Header */
header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    height: 40px;
}

.logo img {
    height: 100%;
    width: auto;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #2c5aa0;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #2c5aa0;
}

/* Hero Section */
.hero {
    background: 
        linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
        url('https://www.cartel.es/Images/obi-pixel6propix-aZKJEvydrNM-unsplash.jpg') center/cover no-repeat,
        #000000;
    color: white;
    padding: 100px 0 60px;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    width: 100%;
    margin: 0 auto;
    gap: 7%;
}

/* En escritorio: texto a la izquierda, formulario a la derecha */
.hero-text {
    order: 1;
}

.form-card {
    order: 2;
}

/* T&#65533;tulo m&#65533;vil - oculto por defecto */
.mobile-title {
    display: none;
}

.hero-text h1 {
    font-size: 3.3rem;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    font-weight: 700;
    padding-top: 15px;
}

.hero-text p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    font-weight: 400;
}

.hero-features {
    list-style: none;
    margin-bottom: 2rem;
}

.hero-features li {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    font-weight: 500;
    line-height: 21px;
    background: #22890a;
    padding: 12px 16px;
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.hero-features li::before {
    content: "\2713";
    background: #ffe800;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-weight: bold;
    color: #22890a;
}

.subtitle {
    font-size: 2rem!important;
    width: 90%;
    line-height: 2.6rem;
}

/* Form Card */
.form-card {
    background: white;
    border-radius: 15px;
    padding: 1rem 2.5rem 2.5rem 2.5rem;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    position: relative;
}

.form-card h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    margin-top: 0.5rem;
    color: #22890a;
    text-align: center;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.calculator-icon {
    width: 35px;
    height: 35px;
    fill: #22890a;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    padding-left: 0.2rem;
    margin-bottom: 0.1rem;
    PADDING-RIGHT: 1.2rem;
    font-weight: 600;
    color: #555;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #2c5aa0;
}

/* Form groups with placeholders (without labels) */
.form-group.no-label {
    margin-bottom: 0.8rem;
}

.form-group.no-label label {
    display: none;
}

/* Custom styling for date input to show placeholder text */
input[type="date"]:invalid {
    color: #999 !important; /* Cambiar de #323232 a #999 */
}

input[type="date"]:before {
    content: attr(data-placeholder);
    color: #999;
}

input[type="date"]:valid:before {
    display: none;
}

.radio-group {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.radio-option {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 7px 20px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    transition: all 0.3s;
    font-weight: 500;
}

.radio-option:hover {
    border-color: #2c5aa0;
    background: rgba(44, 90, 160, 0.05);
}

.radio-option input[type="radio"] {
    margin: 0 8px 0 16px;
    width: auto;
}

.radio-option input[type="radio"]:checked + span {
    color: #2c5aa0;
    font-weight: 600;
}

.radio-option:has(input[type="radio"]:checked) {
    border-color: #2c5aa0;
    background: rgba(44, 90, 160, 0.1);
}

.btn-primary {
    width: 100%;
    background: linear-gradient(135deg, #FFE800 0%, #FFE800 100%);
    color: #22890a;
    padding: 15px;
    border: 2px solid #22890a;
    border-radius: 8px;
    font-size: 1.3rem;
    font-weight: 700;
    font-family: 'Quicksand', sans-serif;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    margin-top: 1rem;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(255, 107, 53, 0.3);
}

/* Info Section */
.info-section {
    padding: 80px 0;
    background: white;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.info-card {
    background: #f8f9fa;
    padding: 2.5rem;
    border-radius: 15px;
    text-align: center;
    transition: transform 0.3s;
}

.info-card:hover {
    transform: translateY(-10px);
}

.info-card .icon {
    width: 49%;
    margin: 0 auto;
    font-size: 3rem;
    color: #ff6b35;
    height: 85px;
}

.info-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #22890a;
    font-weight: 600;
}

.info-card p {
    font-weight: 400;
}

/* Section Titles */
.section-title {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
    color: #22890a;
    font-weight: 400;
}

.section-title p {
    font-size: 1.2rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
    font-weight: 400;
}

/* Process Section */
.process-section {
    padding: 80px 0;
    background: #f8f9fa;
}

.process-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.process-step {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    text-align: center;
    position: relative;
}

.process-step .step-number {
    background: #22890a;
    color: #ffe800;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    font-size: 2rem;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin: 0 auto 1.5rem;
}

.process-step h3 {
    color: #22890a;
    font-weight: 600;
    margin-bottom: 1rem;
}

.process-step p {
    font-weight: 400;
}

/* Brands Section */
.brands-section {
    padding: 80px 0;
    background: white;
}

.brands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
    align-items: center;
}

.brand-item {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid #e9ecef;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-item:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.brand-item img {
    max-width: 100%;
    max-height: 100px;
    width: auto;
    height: auto;
    object-fit: contain;
}

/* Stats Section */
.stats-section {
    background: #041c35;
    color: white;
    padding: 80px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    text-align: center;
}

.stat-item h3 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.stat-item p {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 400;
}

/* Footer */
footer {
    background: #041c35;
    color: white;
    padding: 0px 0 30px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    color: #ff6b35;
    font-weight: 600;
}

.footer-section p,
.footer-section li {
    margin-bottom: 0.8rem;
    font-weight: 400;
}

.footer-section ul {
    list-style: none;
}

.footer-section a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: #ff6b35;
}

.footer-bottom {
    padding-top: 2rem;
    text-align: center;
    color: #ccc;
    font-weight: 400;
}

/* Responsive Design */
@media (max-width: 768px) {
    .btn-primary {
        width: 100%;
        background: linear-gradient(135deg, #FFE800 0%, #FFE800 100%);
        color: #22890a;
        padding: 10px;
        border: 2px solid #22890a;
        border-radius: 8px;
        font-size: 1.3rem;
        font-weight: 700;
        font-family: 'Quicksand', sans-serif;
        cursor: pointer;
        transition: transform 0.3s, box-shadow 0.3s;
        margin-top: 0.6rem;
    }
    
    .radio-option input[type="radio"] {
        margin: 0 8px 0 0px;
        width: auto;
    }
    
    .radio-option {
        padding: 3px 0!important;
    }
    
    .form-group {
        margin-bottom: 0.8rem!important;
    }
    
    .form-group input, .form-group select {
        width: 100%;
        padding: 10px 15px;
        border: 2px solid #e9ecef;
        border-radius: 8px;
        font-size: 16px; /* Mantener 16px para evitar zoom en iOS */
        font-family: 'Quicksand', sans-serif;
        transition: border-color 0.3s;
        color: #999 !important;
        background-color: #ffffff !important;
    }
    
    .calculator-icon {
        width: 24px;
        height: 25px;
        fill: #22890a;
    }
    
    .logo {
        height: 25px;
        margin: 0 auto;
    }
    
    .form-group label {
        display: block;
        padding-left: 0.2rem;
        margin-bottom: 0.1rem;
        font-weight: 600;
        color: #555;
        padding: 0;
    }
    
    .hero-features li {
        font-size: 1.2rem;
        margin-bottom: 0.5rem;
        display: flex;
        align-items: center;
        font-weight: 500;
        line-height: 21px;
        background: #22890a;
        padding: 12px 16px;
        border-radius: 8px;
        backdrop-filter: blur(10px);
    }
    
    .subtitle {
        font-size: 1.3rem !important;
        width: 100%;
        line-height: 1.8rem;
        margin-top: 22px;
    }
    
    .hero {
        padding: 120px 0 40px;
        margin-top: 70px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        display: flex;
        flex-direction: column;
        margin-top: -8px;
    }

    /* Mostrar t&#65533;tulo m&#65533;vil y ocultar el t&#65533;tulo original */
    .mobile-title {
        display: block;
        order: -1;
        font-size: 2.2rem;
        margin-bottom: 2rem;
        text-align: center;
        color: white;
        font-weight: 700;
        line-height: 1.2;
    }

    .hero-text h1 {
        display: none; /* Ocultar el t&#65533;tulo original en m&#65533;vil */
    }

    /* En m&#65533;vil: formulario segundo, resto del texto al final */
    .form-card {
        order: 1;
    }

    .hero-text {
        order: 2;
    }

    .hero-text p {
        font-size: 1.1rem;
        text-align: center;
        margin-bottom: 1.5rem;
        line-height: 23px;
    }

    .hero-features {
        margin-bottom: 0;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 1rem;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }

    .nav-links.active {
        display: flex;
    }

    .mobile-menu-toggle {
        display: none;
    }

    .info-grid,
    .process-steps {
        grid-template-columns: 1fr;
    }

    .section-title h2 {
        font-size: 2rem;
    }

    .brands-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 1rem;
    }

    .form-card {
        padding: 2rem;
    }

    .container {
        padding: 10px 15px;
    }

    .radio-group {
        gap: 0.5rem;
    }

    .radio-option {
        justify-content: center;
        width: 39%;
        display: flex!important;
        flex-direction: row;
    }
}

@media (max-width: 480px) {
    input[type="date"] {
        font-size: 13px !important;
    }
    
    .hero {
        padding: 51px 0 30px;
        margin-top: 0px;
    }

    .mobile-title {
        font-size: 1.7rem;
        margin-bottom: 0.9rem;
        width: 79%;
    }

    .form-card {
        padding: 1.3rem;
        padding-top: 0.5rem;
        width: 95%;
    }

    .form-card h3 {
        font-size: 1.3rem;
        margin-bottom: 0.6rem;
        margin-top: 0;
    }

    .info-card {
        padding: 2rem;
    }

    .process-step {
        padding: 1.5rem;
    }
}

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

.animate-on-scroll {
    animation: fadeInUp 0.6s ease-out;
}