/* ===== RR Form Styles ===== */
.rr-form-wrapper {
    max-width: 700px;
    margin: 0 auto;
    font-family: 'Segoe UI', sans-serif;
}

.rr-referral-badge {
    background: rgba(200,160,80,0.15);
    border: 1px solid rgba(200,160,80,0.4);
    color: #c8a050;
    padding: 10px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
}

.rr-form-container {
    background: rgba(20, 10, 5, 0.85);
    border: 1px solid rgba(200,160,80,0.3);
    border-radius: 12px;
    padding: 36px 40px;
    color: #e8e0d0;
}

.rr-form-header {
    text-align: center;
    margin-bottom: 28px;
}

.rr-form-header h2 {
    font-size: 26px;
    font-weight: 700;
    color: #f0e8d0;
    margin: 0 0 8px;
    letter-spacing: 1px;
}

.rr-form-header h2 em {
    color: #c8a050;
    font-style: italic;
}

.rr-form-header p {
    font-size: 13px;
    color: #a09080;
    margin: 0;
}

.rr-section-title {
    font-size: 11px;
    letter-spacing: 2px;
    color: #c8a050;
    font-weight: 600;
    margin: 24px 0 14px;
    border-bottom: 1px solid rgba(200,160,80,0.2);
    padding-bottom: 6px;
}

.rr-row {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.rr-field {
    flex: 1;
    min-width: 200px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.rr-field.rr-full {
    flex: 0 0 100%;
}

.rr-field label {
    font-size: 11px;
    letter-spacing: 1.5px;
    color: #c8a050;
    font-weight: 600;
}

.rr-field .req { color: #e05050; }

.rr-field input,
.rr-field select {
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(200,160,80,0.3);
    border-radius: 8px;
    color: #f0e8d0;
    padding: 12px 14px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
    width: 100%;
    box-sizing: border-box;
}

.rr-field input::placeholder { color: #706050; }

.rr-field input:focus,
.rr-field select:focus {
    border-color: #c8a050;
    background: rgba(255,255,255,0.1);
}

.rr-field select option {
    background: #1a1008;
    color: #f0e8d0;
}

.rr-hint {
    font-size: 11px;
    color: #806050;
    margin-top: 4px;
}

/* Select2 custom dark theme */
.select2-container--default .select2-selection--single {
    background: rgba(255,255,255,0.07) !important;
    border: 1px solid rgba(200,160,80,0.3) !important;
    border-radius: 8px !important;
    height: 46px !important;
    display: flex !important;
    align-items: center !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #f0e8d0 !important;
    line-height: normal !important;
    padding: 0 32px 0 14px !important;
    display: flex !important;
    align-items: center !important;
    height: 46px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 46px !important;
    top: 0 !important;
    right: 8px !important;
    display: flex !important;
    align-items: center !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
    border-color: #c8a050 transparent transparent transparent !important;
    margin-top: 0 !important;
    top: auto !important;
}

.select2-container--default .select2-selection--single .select2-selection__clear {
    height: 46px !important;
    line-height: 46px !important;
    color: #c8a050 !important;
    margin-right: 4px !important;
}

.select2-dropdown {
    background: #1a1008 !important;
    border: 1px solid rgba(200,160,80,0.4) !important;
    border-radius: 8px !important;
}

.select2-container--default .select2-results__option {
    color: #e8e0d0 !important;
    padding: 10px 14px !important;
}

.select2-container--default .select2-results__option--highlighted {
    background: rgba(200,160,80,0.2) !important;
    color: #f0e8d0 !important;
}

.select2-search--dropdown .select2-search__field {
    background: rgba(255,255,255,0.1) !important;
    border: 1px solid rgba(200,160,80,0.3) !important;
    color: #f0e8d0 !important;
    border-radius: 6px !important;
    padding: 8px 12px !important;
}

.rr-legal {
    font-size: 11px;
    color: #706050;
    text-align: center;
    margin: 20px 0 16px;
    letter-spacing: 0.5px;
}

.rr-submit-btn {
    width: 100%;
    background: linear-gradient(135deg, #c8a050, #a07830);
    color: #1a0e04;
    border: none;
    border-radius: 8px;
    padding: 16px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 2px;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.1s;
}

.rr-submit-btn:hover { opacity: 0.9; }
.rr-submit-btn:active { transform: scale(0.99); }
.rr-submit-btn:disabled { opacity: 0.5; cursor: not-allowed; }

.rr-msg {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
    text-align: center;
}

.rr-msg.success {
    background: rgba(50,180,80,0.15);
    border: 1px solid rgba(50,180,80,0.4);
    color: #50c870;
}

.rr-msg.error {
    background: rgba(220,50,50,0.15);
    border: 1px solid rgba(220,50,50,0.4);
    color: #e07070;
}

@media (max-width: 600px) {
    .rr-form-container { padding: 24px 20px; }
    .rr-row { flex-direction: column; }
    .rr-field { min-width: 100%; }
}

/* ── Validación ── */
.rr-field-error {
    display: block;
    color: #e05050;
    font-size: 12px;
    font-weight: 500;
    margin-top: 6px;
    padding-left: 2px;
    letter-spacing: 0.3px;
}

.rr-field input.rr-input-error {
    border-color: #c0392b !important;
    background: rgba(192, 57, 43, 0.08) !important;
}

.rr-field input.rr-input-error:focus {
    border-color: #c0392b !important;
    box-shadow: 0 0 0 2px rgba(192, 57, 43, 0.2);
}

.select2-selection.rr-input-error {
    border-color: #c0392b !important;
    background: rgba(192, 57, 43, 0.08) !important;
}

/* Limpiar error al escribir */
.rr-field input:not(.rr-input-error):focus {
    border-color: #c8a050;
}

/* ── Modal de éxito ── */
.rr-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    animation: rr-fade-in 0.25s ease;
}

@keyframes rr-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.rr-modal-box {
    background: rgba(30, 15, 8, 0.82);
    border: 1px solid rgba(200, 160, 80, 0.25);
    border-radius: 20px;
    padding: 48px 40px 40px;
    max-width: 520px;
    width: 90%;
    text-align: center;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 24px 60px rgba(0,0,0,0.5);
    animation: rr-slide-up 0.3s ease;
}

@keyframes rr-slide-up {
    from { transform: translateY(30px); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}

.rr-modal-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 1.5px solid rgba(200, 160, 80, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 28px;
    color: #c8a050;
}

.rr-modal-icon svg {
    width: 32px;
    height: 32px;
    stroke: #c8a050;
}

.rr-modal-title {
    font-size: 28px;
    font-weight: 600;
    color: #f0e8d0;
    margin: 0 0 14px;
    letter-spacing: 0.5px;
}

.rr-modal-title em {
    font-style: italic;
    color: #e8d8b0;
}

.rr-modal-text {
    font-size: 15px;
    color: #a09080;
    margin: 0 0 32px;
    line-height: 1.6;
}

.rr-modal-btn {
    width: 100%;
    background: transparent;
    border: 1px solid rgba(200, 160, 80, 0.4);
    border-radius: 10px;
    color: #c8a050;
    padding: 16px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 2px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.rr-modal-btn:hover {
    background: rgba(200, 160, 80, 0.12);
    color: #f0d890;
}
