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

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(160deg, #fff1d9 0%, #f7931e 40%, #c1272d 100%);
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    position: relative;
}

.header {
    background: linear-gradient(135deg, #f7931e 0%, #c1272d 100%);
    color: white;
    padding: 30px 30px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;

    &::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 3px;
        background: linear-gradient(90deg, transparent, #f5d442, transparent);
    }

    img {
        width: 100px;
    }

    h1 {
        font-size: 24px;
        margin-bottom: 10px;
        font-weight: bold;
    }

    .header-info {
        margin-top: 20px;
        font-size: 1em;

        .legend {
            margin: 1rem;
            display: block;
            color: #f5d442;
            text-transform: uppercase;
            font-weight: bold;
        }
    }

    .header-title {
        display: flex;
        align-items: center;
        justify-content: space-around;
        gap: 1rem;
        flex-wrap: wrap;
    }
}

.form-container {
    padding: 20px 30px 30px;

    h2 {
        font-size: 18px;
        font-weight: 500;
        color: #a1a1a1;
        text-align: center;
        margin-bottom: 1rem;
    }

    h3.section-title {
        font-size: 16px;
        font-weight: 700;
        color: #c1272d;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        margin: 30px 0 20px;
        padding-bottom: 8px;
        border-bottom: 2px solid #ffe4cc;
    }
}

.form-group {
    margin-bottom: 25px;
}

.subtitle {
    color: #a1a1a1;
    font-size: 0.8em;
    margin-bottom: 10px;
    font-weight: 500;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
    font-size: 0.95em;
}

input,
select,
textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: #f9f9f9;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #f7931e;
    background: white;
    box-shadow: 0 0 0 3px rgba(247, 147, 30, 0.18);
}

select {
    cursor: pointer;
}

/* ===== Estado readonly del campo país ===== */
input.field-readonly {
    background: #f0ece6;
    color: #777;
    cursor: not-allowed;
    border-color: #d8d2c6;
}

input.field-readonly:focus {
    border-color: #d8d2c6;
    background: #f0ece6;
    box-shadow: none;
}

/* ===== Sección de pago ===== */
.payment-info {
    background: #fff8e8;
    padding: 0;
    margin: 1rem 0 1.5rem;
    border-radius: 10px;
    font-size: 1em;
    color: #333;
    border-left: 4px solid #f5d442;
    overflow: hidden;
}

.payment-placeholder {
    padding: 18px;
    color: #6c757d;
    font-style: italic;
    text-align: center;
}

.price-card {
    padding: 18px 20px;
}

.price-row {
    padding: 10px 0;
}

.price-row + .price-row {
    border-top: 1px dashed #e9d8a3;
    margin-top: 10px;
}

.price-row-secondary {
    opacity: 0.8;
}

.price-label {
    font-size: 0.8em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #c1272d;
    font-weight: 700;
}

.price-amount {
    font-size: 1.8em;
    font-weight: 800;
    color: #2c2c2c;
    line-height: 1.1;
    margin-top: 4px;
}

.price-amount-old {
    text-decoration: line-through;
    color: #999;
    font-size: 1.4em;
}

.price-currency {
    font-size: 0.55em;
    color: #888;
    font-weight: 600;
    margin-left: 4px;
    vertical-align: middle;
    letter-spacing: 1px;
}

.price-deadline {
    font-size: 0.85em;
    color: #777;
    margin-top: 2px;
}

.payment-details {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e9d8a3;
    text-align: left;
    font-size: 0.95em;
}

.payment-details p {
    margin: 4px 0;
}

.payment-details a {
    color: #c1272d;
    text-decoration: none;
}

.payment-details a:hover {
    text-decoration: underline;
}

/* ===== File upload (soporte de pago) ===== */
.file-upload {
    position: relative;
    display: inline-block;
    width: 100%;
}

.file-input {
    position: absolute;
    left: -9999px;
}

.file-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 15px;
    border: 2px dashed #f7931e;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff8f0;
    color: #c1272d;
    font-weight: bold;
    min-height: 120px;
    text-align: center;
}

.file-label:hover {
    background: #ffeed8;
    border-color: #c1272d;
    transform: translateY(-2px);
}

.file-label.has-file {
    background: #e8f5e8;
    border-color: #4caf50;
    color: #2e7d32;
    padding: 20px 15px;
    min-height: auto;
}

.file-label.drag-over {
    background: #fff8e1;
    border-color: #f5d442;
    color: #c1272d;
    transform: scale(1.02);
}

.upload-icon {
    font-size: 2.5em;
    margin-bottom: 10px;
    opacity: 0.7;
}

.upload-text {
    font-size: 1.1em;
    margin-bottom: 5px;
}

.upload-hint {
    font-size: 0.9em;
    opacity: 0.8;
    font-weight: normal;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.file-preview {
    width: 40px;
    height: 40px;
    border-radius: 5px;
    object-fit: cover;
}

.upload-format-hint {
    color: #6c757d;
    margin-top: 8px;
    display: block;
}

/* ===== Checkbox aceptación política ===== */
.privacy-acceptance {
    background: #fff8f0;
    border: 1px solid #ffd9b3;
    border-radius: 10px;
    padding: 14px 16px;
    margin-top: 24px;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-weight: normal;
    color: #333;
    margin-bottom: 0;
    font-size: 0.95em;
    line-height: 1.45;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: #c1272d;
    cursor: pointer;
}

.checkbox-text {
    flex: 1;
}

.checkbox-text a {
    color: #c1272d;
    font-weight: 700;
    text-decoration: underline;
}

.checkbox-text a:hover {
    color: #8b1a1f;
}

.checkbox-text small {
    display: block;
    margin-top: 4px;
    color: #777;
    font-size: 0.85em;
}

.submit-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #f7931e 0%, #c1272d 100%);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(247, 147, 30, 0.4);
}

.submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Loading animation */
.loading {
    display: none;
    text-align: center;
    margin-top: 20px;
}

.loading-dots {
    display: inline-flex;
    gap: 8px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #c1272d;
    animation: bounce 1.4s ease-in-out infinite both;
}

.dot:nth-child(1) {
    animation-delay: -0.32s;
}

.dot:nth-child(2) {
    animation-delay: -0.16s;
}

.dot:nth-child(3) {
    animation-delay: 0;
}

@keyframes bounce {

    0%,
    80%,
    100% {
        transform: scale(0);
    }

    40% {
        transform: scale(1);
    }
}

.success-message,
.error-message {
    padding: 15px;
    border-radius: 10px;
    margin-top: 20px;
    display: none;
}

.success-message {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.error-message {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.footer-info {
    background: #f8f9fa;
    padding: 20px 30px;
    text-align: center;
    color: #6c757d;
    border-top: 1px solid #e9ecef;

    a {
        color: #c1272d;
        text-decoration: none;
        font-weight: bold;
        margin: 12px 0;
        display: inline-block;
    }
}

@media (max-width: 640px) {
    body {
        padding: 0;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .container {
        margin: 0;
        border-radius: 0;
    }

    .header {
        padding: 30px 20px;

        .header-title {
            flex-direction: column;
            align-items: center;

            img {
                width: 80px;
            }
        }
    }

    .header h1 {
        font-size: 1.8em;
    }

    .form-container {
        padding: 30px 20px;
    }
}
