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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.container {
    width: 100%;
    max-width: 900px;
}

.form-box {
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    padding: 40px;
    animation: slideIn 0.5s ease-out;
}

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

h1 {
    color: #333;
    margin-bottom: 10px;
    font-size: 28px;
    text-align: center;
}

h2 {
    color: #333;
    font-size: 20px;
    margin-top: 20px;
    margin-bottom: 15px;
}

.subtitle {
    color: #666;
    text-align: center;
    margin-bottom: 30px;
    font-size: 14px;
}

fieldset {
    border: 2px solid #f0f0f0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
    background-color: #fafafa;
}

legend {
    color: #667eea;
    font-size: 16px;
    font-weight: 600;
    padding: 0 10px;
    margin-left: -10px;
}

/* Estilos para fieldsets de huéspedes */
.huesped-fieldset {
    border: 2px solid #e3e3ff;
    background-color: #f9f9ff;
    position: relative;
}

.huesped-fieldset legend {
    background: white;
    border: 2px solid #667eea;
    border-radius: 6px;
    padding: 5px 15px;
    margin-left: -12px;
    color: #667eea;
}

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

.huesped-number {
    font-weight: bold;
    color: #667eea;
    font-size: 14px;
}

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

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

.form-row-3 {
    grid-template-columns: 1fr 1fr 1fr;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
    font-size: 14px;
}

label .required {
    color: #ff4444;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
input[type="number"],
select,
textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="date"]:focus,
input[type="number"]:focus,
select:focus,
textarea:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

textarea {
    resize: vertical;
    min-height: 80px;
}

.form-group.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 20px;
}

.form-group.checkbox input[type="checkbox"] {
    width: auto;
    margin-top: 3px;
    cursor: pointer;
    accent-color: #667eea;
    min-width: 18px;
    height: 18px;
}

.form-group.checkbox label {
    margin: 0;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    font-weight: normal;
}

.btn-submit {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

.btn-submit:active {
    transform: translateY(0);
}

.btn-action {
    padding: 12px 24px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-right: 10px;
    margin-top: 10px;
}

.btn-action:hover {
    background: #764ba2;
}

.form-note {
    text-align: center;
    font-size: 12px;
    color: #999;
    margin-top: 15px;
}

.success-message {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, #84fab0 0%, #8fd3f4 100%);
    border-radius: 12px;
    color: #2d5016;
}

.success-message h2 {
    margin-bottom: 15px;
    font-size: 24px;
    color: #2d5016;
}

.success-message p {
    margin-bottom: 10px;
    font-size: 14px;
    color: #2d5016;
}

.small-text {
    font-size: 12px;
    opacity: 0.9;
}

.btn-reset {
    padding: 10px 30px;
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.btn-reset:hover {
    background: #667eea;
    color: white;
}

.comprobante {
    display: none;
    background: white;
    padding: 40px;
    border: 2px solid #333;
    margin: 20px 0;
    border-radius: 8px;
}

.comprobante.visible {
    display: block;
}

.comprobante-header {
    border-bottom: 2px solid #333;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.comprobante-section {
    margin-bottom: 20px;
}

.comprobante-section h3 {
    color: #667eea;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.comprobante-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 10px;
}

.comprobante-item {
    font-size: 13px;
}

.comprobante-item strong {
    color: #333;
}

@media (max-width: 900px) {
    .form-row-3 {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 600px) {
    .form-box {
        padding: 25px;
    }

    h1 {
        font-size: 24px;
    }

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

    .form-row-3 {
        grid-template-columns: 1fr;
    }

    fieldset {
        padding: 15px;
        margin-bottom: 20px;
    }
}

/* Animación de carga */
input:invalid:required {
    border-color: #ff6b6b;
}

input:valid:required {
    border-color: #51cf66;
}

/* Mensaje de aviso */
.warning-message {
    background-color: #fff3cd;
    border: 1px solid #ffc107;
    color: #856404;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 13px;
}

.error-message {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 13px;
}

