/* Reset y Variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #c6a15b;
    --primary-dark: #9f7d40;
    --success-color: #43b884;
    --error-color: #d75f5f;
    --warning-color: #d8a743;
    --bg-color: #111113;
    --card-bg: #17171b;
    --card-bg-soft: #1f2026;
    --text-primary: #f1efe8;
    --text-secondary: #b7b0a2;
    --border-color: #3a3429;
    --shadow: 0 10px 24px rgba(0, 0, 0, 0.32);
    --shadow-lg: 0 18px 48px rgba(0, 0, 0, 0.5);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background:
        radial-gradient(circle at 20% 20%, rgba(198, 161, 91, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 80% 15%, rgba(198, 161, 91, 0.07) 0%, transparent 35%),
        linear-gradient(145deg, #0d0d10 0%, #17181d 45%, #0f1013 100%);
    min-height: 100vh;
    padding: 20px;
    color: var(--text-primary);
}

.auth-wrapper {
    min-height: calc(100vh - 40px);
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: linear-gradient(160deg, rgba(25, 25, 30, 0.95), rgba(16, 17, 20, 0.95));
    border: 1px solid rgba(198, 161, 91, 0.35);
    backdrop-filter: blur(8px);
    border-radius: 18px;
    box-shadow: var(--shadow-lg);
    padding: 30px;
}

.login-logo {
    width: 112px;
    height: 112px;
    object-fit: cover;
    border-radius: 999px;
    display: block;
    margin: 0 auto 14px auto;
    border: 2px solid rgba(198, 161, 91, 0.45);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.32);
}

.login-card h2 {
    color: #f6e4bf;
    font-family: 'Cinzel', serif;
    letter-spacing: 0.08em;
    margin-bottom: 8px;
}

.login-subtitle {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.login-error {
    color: var(--error-color);
    font-size: 0.9rem;
}

.container {
    max-width: 920px;
    margin: 0 auto;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 30px;
    color: white;
    position: relative;
}

.header h1 {
    font-family: 'Cinzel', serif;
    font-size: 3rem;
    letter-spacing: 0.2em;
    font-weight: 700;
    margin-bottom: 10px;
    color: #f4ddb0;
    text-shadow: 0 2px 18px rgba(198, 161, 91, 0.25);
}

.subtitle {
    font-size: 1rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: #d9d1c0;
}

.btn-logout {
    position: absolute;
    right: 0;
    top: 0;
    background: rgba(198, 161, 91, 0.12);
    color: #f5e8cd;
    border: 1px solid rgba(198, 161, 91, 0.5);
    border-radius: 10px;
    padding: 8px 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-logout:hover {
    background: rgba(198, 161, 91, 0.24);
}

/* Main Content */
.main-content {
    background: linear-gradient(180deg, rgba(25, 25, 31, 0.98) 0%, rgba(18, 18, 22, 0.98) 100%);
    border: 1px solid rgba(198, 161, 91, 0.35);
    border-radius: 18px;
    padding: 40px;
    box-shadow: var(--shadow-lg);
    margin-bottom: 30px;
}

/* Formulario */
.form-container h2 {
    color: #f6e3bd;
    margin-bottom: 10px;
    font-family: 'Cinzel', serif;
    font-size: 1.9rem;
    text-align: center;
}

.form-intro {
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 26px;
}

.pago-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

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

label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #ebe4d7;
    font-size: 0.95rem;
}

.required {
    color: var(--error-color);
}

.optional {
    color: var(--text-secondary);
    font-weight: normal;
    font-size: 0.85em;
}

input[type="text"],
input[type="tel"],
input[type="password"],
input[type="date"],
select {
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: var(--card-bg-soft);
    color: #f3efe6;
}

input[readonly] {
    background: #2a2b33;
    border-color: #5c4a2e;
    color: #f4ddb0;
    font-weight: 600;
    cursor: not-allowed;
}

input:focus,
select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(198, 161, 91, 0.18);
}

input:invalid:not(:placeholder-shown) {
    border-color: var(--error-color);
}

small {
    margin-top: 5px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.checkbox-group {
    margin-top: 10px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: normal;
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

/* Botón Submit */
.btn-submit {
    background: linear-gradient(130deg, #d2b071 0%, #b58a45 48%, #8f6a34 100%);
    color: #1b1306;
    padding: 16px 32px;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(198, 161, 91, 0.3);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-loader {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Resultado */
.result-container {
    text-align: center;
}

.result-content {
    padding: 30px;
}

.result-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.result-title {
    font-size: 1.8rem;
    margin-bottom: 15px;
    font-weight: 700;
}

.result-success .result-title {
    color: var(--success-color);
}

.result-error .result-title {
    color: var(--error-color);
}

.result-message {
    font-size: 1.1rem;
    margin-bottom: 25px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.result-details {
    background: rgba(198, 161, 91, 0.08);
    border: 1px solid rgba(198, 161, 91, 0.18);
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    text-align: left;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-label {
    font-weight: 600;
    color: #cbbfa6;
}

.detail-value {
    color: var(--text-primary);
    font-weight: 600;
}

.btn-back {
    background: #4a3820;
    color: #f8e6c1;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 20px;
}

.btn-back:hover {
    background: #5f4727;
    transform: translateY(-2px);
}

/* Footer */
.footer {
    text-align: center;
    color: #d7cfbe;
    padding: 20px;
    opacity: 0.94;
}

.footer p {
    margin: 5px 0;
}

.disclaimer {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Responsive */
@media (max-width: 768px) {
    .header h1 {
        font-size: 2.15rem;
        letter-spacing: 0.12em;
    }

    .main-content {
        padding: 25px;
    }

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

    .result-icon {
        font-size: 3rem;
    }

    .result-title {
        font-size: 1.5rem;
    }

    .btn-logout {
        position: static;
        margin-top: 14px;
    }
}

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-container,
.result-container {
    animation: fadeIn 0.5s ease;
}

