/* ========================================
   Register PF Wizard - Kavo
   Design: fundo azul-cinza suave, card branco centralizado,
   timeline stepper com labels, logo + título no topo.
   Compatível com Register.cshtml (multi-país) e RegisterBR.cshtml
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Poppins:wght@400;500;600;700&display=swap');

:root {
    --rpf-primary: #111111;
    --rpf-primary-dark: #000000;
    --rpf-primary-light: rgba(17, 17, 17, 0.06);
    --rpf-success: #10b981;
    --rpf-warning: #f59e0b;
    --rpf-danger: #ef4444;
    --rpf-text: #0f172a;
    --rpf-text-secondary: #6b7280;
    --rpf-border: #e5e7eb;
    --rpf-border-light: #ececec;
    --rpf-bg: #f7f8fa;
    --rpf-white: #ffffff;
    --rpf-yellow: #FFC107;
    --rpf-yellow-dark: #FFA000;
    --rpf-shadow-input: none;
    --rpf-shadow-card: none;
    --rpf-radius: 12px;
    --rpf-radius-btn: 14px;
    --rpf-radius-card: 20px;
}

@keyframes rpfPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.06); }
    100% { transform: scale(1); }
}

/* Container principal - 100% largura responsivo */
.rpf-wizard {
    min-height: 100vh;
    width: 100%;
    background: var(--rpf-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    font-family: 'Manrope', 'Poppins', sans-serif;
    overflow-x: hidden;
    padding: 2rem 1rem 2rem;
}

.rpf-wizard * {
    font-family: 'Manrope', 'Poppins', sans-serif;
    box-sizing: border-box;
}

/* Header do wizard - Logo e Título acima do stepper */
.rpf-wizard-header {
    text-align: center;
    margin-bottom: 1.5rem;
    width: 100%;
    max-width: 600px;
}

.rpf-wizard-header__logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.rpf-wizard-header__logo img {
    height: 48px;
    width: auto;
}

.rpf-wizard-header__title {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--rpf-text);
    margin: 0;
    letter-spacing: -0.02em;
}

@media (max-width: 576px) {
    .rpf-wizard-header {
        margin-bottom: 1.25rem;
    }
    
    .rpf-wizard-header__logo img {
        height: 40px;
    }
    
    .rpf-wizard-header__title {
        font-size: 1.5rem;
    }
}


/* ========================================
   Timeline stepper — horizontal labels
   ======================================== */
.rpf-stepper {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 2.25rem;
    width: 100%;
    max-width: 600px;
    position: relative;
}

.rpf-stepper__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    position: relative;
    z-index: 1;
}

/* Connector line between steps */
.rpf-stepper__item:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 14px;
    left: calc(50% + 18px);
    width: calc(100% - 36px);
    height: 4px;
    background: linear-gradient(90deg, var(--rpf-border), var(--rpf-border-light));
    border-radius: 999px;
    z-index: 0;
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.rpf-stepper__item.completed:not(:last-child)::after {
    background: #111111;
    box-shadow: none;
}

.rpf-stepper__dot {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 3px solid var(--rpf-border);
    background: var(--rpf-white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--rpf-text-secondary);
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.rpf-stepper__dot::after {
    content: '';
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(20, 184, 166, 0.16), transparent 60%);
    opacity: 0;
    transition: opacity 0.25s ease;
    z-index: -1;
}

.rpf-stepper__item.active .rpf-stepper__dot {
    border-color: #111111;
    background: #111111;
    color: var(--rpf-white);
    box-shadow: 0 0 0 6px rgba(17, 17, 17, 0.1);
    animation: rpfPulse 1.2s ease-out infinite;
}

.rpf-stepper__item.active .rpf-stepper__dot::after {
    opacity: 1;
}

.rpf-stepper__item.completed .rpf-stepper__dot {
    border-color: #111111;
    background: #111111;
    color: var(--rpf-white);
    box-shadow: 0 4px 8px rgba(17, 17, 17, 0.12);
}

.rpf-stepper__label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--rpf-text-secondary);
    margin-top: 0.55rem;
    text-align: center;
    white-space: nowrap;
    letter-spacing: -0.01em;
    transition: color 0.3s ease, transform 0.3s ease;
}

.rpf-stepper__item.active .rpf-stepper__label {
    color: #111111;
    transform: translateY(-1px);
}

.rpf-stepper__item.completed .rpf-stepper__label {
    color: #4b5563;
}

/* ========================================
   White card wrapping each step
   ======================================== */
.rpf-content {
    width: 100%;
    max-width: 520px;
}

.rpf-card {
    position: relative;
    background: var(--rpf-white);
    border: 1px solid var(--rpf-border);
    border-radius: var(--rpf-radius-card);
    box-shadow: var(--rpf-shadow-card);
    padding: 2rem 1.75rem 1.75rem;
    width: 100%;
    max-width: 520px;
}

/* Botão sair sutil - dentro do card, canto superior esquerdo */
.rpf-exit-btn-inline {
    position: absolute;
    top: 1rem;
    left: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    color: #dc2626;
    text-decoration: none;
    font-size: 0.85rem;
    border-radius: 8px;
    transition: all 0.2s ease;
    opacity: 0.6;
    z-index: 10;
}

.rpf-exit-btn-inline:hover {
    opacity: 1;
    background: rgba(220, 38, 38, 0.08);
    color: #b91c1c;
}

/* Header do card - Logo e Título */
.rpf-card-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-top: 0.5rem;
}

.rpf-card-header__logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.rpf-card-header__logo img {
    height: 42px;
    width: auto;
}

.rpf-card-header__title {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--rpf-text);
    margin: 0;
    letter-spacing: -0.02em;
}

@media (max-width: 576px) {
    .rpf-card-header {
        margin-bottom: 1.5rem;
    }
    
    .rpf-card-header__logo img {
        height: 36px;
    }
    
    .rpf-card-header__title {
        font-size: 1.25rem;
    }
}

/* Step container — transição suave */
.rpf-step {
    display: none;
    animation: rpfSlideIn 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.rpf-step.active {
    display: block;
}

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

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

/* Question — título grande e limpo */
.rpf-question {
    margin-bottom: 1.75rem;
    text-align: center;
}

.rpf-question__title {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--rpf-text);
    margin-bottom: 0.4rem;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.rpf-question__subtitle {
    font-size: 0.875rem;
    color: var(--rpf-text-secondary);
    margin: 0;
    line-height: 1.5;
    font-weight: 500;
}

/* Form groups */
.rpf-form-group {
    margin-bottom: 1.25rem;
}

.rpf-form-group__label {
    display: block;
    font-size: 0.67rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #4b5563;
    margin-bottom: 0.35rem;
}

.rpf-label {
    display: block;
    font-size: 0.67rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #4b5563;
    margin-bottom: 0.35rem;
}

/* Input styles — redondos, borda cinza clara, sombra leve */
.rpf-input {
    width: 100%;
    padding: 0.62rem 0.85rem;
    min-height: 42px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    transition: border-color 160ms ease, background-color 160ms ease;
    background: #f7f8fa;
    color: #111827;
    min-width: 0;
    box-shadow: none;
}

.rpf-input:focus {
    outline: none;
    border-color: #a3aab5;
    background: #f7f8fa;
    box-shadow: none;
}

.rpf-input:hover {
    border-color: #a3aab5;
    background: #f7f8fa;
}

.rpf-input.is-invalid {
    border-color: #b91c1c;
    box-shadow: none;
}

.rpf-input::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

/* Input with icon */
.rpf-input-icon {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.rpf-input-icon__icon {
    position: absolute;
    left: 1rem;
    color: #9ca3af;
    font-size: 1.15rem;
    pointer-events: none;
    z-index: 1;
}

.rpf-input-icon .rpf-input {
    padding-left: 3rem;
}

/* Phone group */
.rpf-phone-group {
    display: flex;
    gap: 0.5rem;
    width: 100%;
    align-items: stretch;
}

.rpf-phone-group__country {
    width: 100px;
    padding: 0.9rem 0.75rem;
    font-size: 1rem;
    border: 1.5px solid var(--rpf-border);
    border-radius: var(--rpf-radius);
    background: var(--rpf-white);
    color: var(--rpf-text);
    cursor: pointer;
    transition: all 0.2s;
    min-width: 90px;
    box-shadow: var(--rpf-shadow-input);
}

.rpf-phone-group__country:focus {
    outline: none;
    border-color: var(--rpf-primary);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.1);
}

.rpf-phone-group__input {
    flex: 1;
    min-width: 0;
}

/* Password group */
.rpf-password-group {
    position: relative;
    display: flex;
    align-items: center;
}

.rpf-password-group input {
    padding-right: 3rem;
}

.rpf-password-toggle {
    position: absolute;
    right: 1rem;
    background: none;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    padding: 0;
    font-size: 1.15rem;
    transition: color 0.2s;
}

.rpf-password-toggle:hover {
    color: var(--rpf-text);
}

/* Password requirements — layout vertical limpo */
.rpf-password-requirements {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    margin-top: 0.85rem;
    padding: 0.75rem 1rem;
    background: #f7f8fa;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
}

.rpf-password-req {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--rpf-text-secondary);
    transition: color 0.2s;
}

.rpf-password-req__icon {
    font-size: 0.8rem;
    flex-shrink: 0;
}

.rpf-password-req.valid {
    color: #10b981;
}

.rpf-password-req.valid .rpf-password-req__icon {
    color: #10b981;
}

/* Step footer — botões Voltar + Continuar lado a lado dentro do card */
.rpf-step-footer {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #f3f4f6;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

.rpf-step-footer:has(> :only-child),
.rpf-step-footer:has(.rpf-footer__btn:only-child) {
    grid-template-columns: 1fr;
}

.rpf-footer__btn {
    padding: 0.72rem 1rem;
    font-size: 0.88rem;
    font-weight: 700;
    border-radius: var(--rpf-radius-btn);
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background-color 180ms ease, transform 180ms ease, border-color 180ms ease;
    white-space: nowrap;
    width: 100%;
    min-width: 0;
    letter-spacing: 0.01em;
    box-shadow: none;
}

.rpf-footer__btn--back {
    order: 1;
    background: #f7f8fa;
    color: #111111;
    border: 1px solid #e5e7eb;
}

.rpf-footer__btn--back:hover {
    background: #f3f4f6;
    border-color: #a3aab5;
}

.rpf-footer__btn--primary {
    order: 2;
    background: #111111;
    color: #ffffff;
    border: none;
    margin-left: 0;
}

.rpf-footer__btn--primary:hover {
    background: #000000;
    transform: translateY(-1px);
}

.rpf-footer__btn--submit {
    order: 2;
    background: #111111;
    color: #ffffff;
    font-weight: 700;
    border: none;
    margin-left: 0;
}

.rpf-footer__btn--submit:hover {
    background: #000000;
    transform: translateY(-1px);
}

.rpf-footer__btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* Info box — fundo suave */
.rpf-info {
    background: #f7f8fa;
    border-left: 3px solid #d1d5db;
    padding: 0.75rem 1rem;
    border-radius: 10px;
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}

.rpf-info--warning {
    background: rgba(245, 158, 11, 0.06);
    border-left-color: var(--rpf-warning);
}

.rpf-info__icon {
    color: #6b7280;
    font-size: 1.1rem;
    flex-shrink: 0;
    margin-top: 1px;
}

.rpf-info--warning .rpf-info__icon {
    color: var(--rpf-warning);
}

.rpf-info__text {
    font-size: 0.875rem;
    color: var(--rpf-text-secondary);
    margin: 0;
    line-height: 1.5;
}

/* Checkbox — moderno */
.rpf-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    cursor: pointer;
}

.rpf-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    border: 1.5px solid var(--rpf-border);
    border-radius: 6px;
    cursor: pointer;
    flex-shrink: 0;
    margin-top: 2px;
    accent-color: #111111;
}

.rpf-checkbox__label {
    font-size: 0.875rem;
    color: var(--rpf-text-secondary);
    line-height: 1.5;
}

.rpf-checkbox__label a {
    color: var(--rpf-primary);
    text-decoration: none;
    font-weight: 600;
}

.rpf-checkbox__label a:hover {
    text-decoration: underline;
}

/* Links de navegação — linha compacta abaixo do card */
.rpf-links {
    text-align: center;
    margin-top: 1.25rem;
    padding: 0 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.35rem;
    font-size: 0.875rem;
}

.rpf-links__text {
    color: var(--rpf-text-secondary);
}

.rpf-links a {
    color: #374151;
    text-decoration: none;
    font-weight: 600;
}

.rpf-links a:hover {
    text-decoration: underline;
}

.rpf-links__divider {
    color: var(--rpf-border);
    margin: 0 0.15rem;
}

.rpf-links__dealer {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    color: #111111 !important;
}

/* Footer — segurança */
.rpf-page-footer__secure {
    text-align: center;
    font-size: 0.78rem;
    color: var(--rpf-text-secondary);
    margin: 1rem 0 0;
    letter-spacing: 0.02em;
}

/* ========================================
   WhatsApp FAB — flutuante canto inferior direito
   ======================================== */
.rpf-whatsapp-fab {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 9000;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #25D366;
    color: #fff;
    padding: 0.75rem 1.25rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(37, 211, 102, 0.35);
    transition: transform 0.2s, box-shadow 0.2s;
}

.rpf-whatsapp-fab:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(37, 211, 102, 0.45);
    color: #fff;
    text-decoration: none;
}

.rpf-whatsapp-fab i {
    font-size: 1.25rem;
}

.rpf-whatsapp-fab__label {
    white-space: nowrap;
}

/* Error messages */
.rpf-error {
    color: var(--rpf-danger);
    font-size: 0.825rem;
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.rpf-error__icon {
    font-size: 0.9rem;
}

/* Email suggestions */
.rpf-email-suggestions {
    position: absolute;
    top: calc(100% + 7px);
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #d7dce3;
    border-radius: 12px;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.09), 0 2px 6px rgba(15, 23, 42, 0.04);
    z-index: 1000;
    display: none;
    max-height: 200px;
    overflow-y: auto;
}

.rpf-email-suggestions.show {
    display: block;
}

.rpf-email-suggestion-item {
    margin: 2px 6px;
    padding: 8px 10px;
    cursor: pointer;
    transition: background-color 140ms ease;
    border-radius: 8px;
    font-size: 0.88rem;
    font-weight: 500;
    color: #111827;
}

.rpf-email-suggestion-item:hover {
    background: #f3f4f6;
}

.rpf-email-suggestion-item strong {
    color: var(--rpf-text);
}

/* Modal customizado para termos */
.rpf-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    backdrop-filter: blur(2px);
}

.rpf-modal.show {
    display: flex;
}

.rpf-modal__content {
    background: var(--rpf-white);
    border-radius: 18px;
    max-width: 500px;
    width: 100%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.15);
}

.rpf-modal__header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--rpf-border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.rpf-modal__title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--rpf-text);
    margin: 0;
}

.rpf-modal__close {
    background: none;
    border: none;
    font-size: 1.25rem;
    color: var(--rpf-text-secondary);
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all 0.2s;
}

.rpf-modal__close:hover {
    background: var(--rpf-bg);
    color: var(--rpf-text);
}

.rpf-modal__body {
    padding: 1.5rem;
    overflow-y: auto;
    flex: 1;
}

.rpf-modal__body h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--rpf-text);
    margin: 1.5rem 0 0.75rem;
}

.rpf-modal__body h3:first-child {
    margin-top: 0;
}

.rpf-modal__body p {
    font-size: 0.9rem;
    color: var(--rpf-text-secondary);
    line-height: 1.6;
    margin-bottom: 0.75rem;
}

.rpf-modal__body ul {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.rpf-modal__body li {
    font-size: 0.9rem;
    color: var(--rpf-text-secondary);
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

/* ========================================
   Search-select (departamento/cidade) — rw-* classes
   Replicado do register-wizard.css para funcionar
   no Register.cshtml (PF) sem carregar o CSS do dealer
   ======================================== */

.rw-search-select {
    position: relative;
}

.rw-search-select .rw-input-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.rw-input-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.rw-input-icon__icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    font-size: 1.15rem;
    pointer-events: none;
    z-index: 1;
}

.rw-input-icon .rpf-input,
.rw-input-icon .rw-input {
    padding-left: 3rem;
    width: 100%;
}

.rw-search-select__icon--search,
.rw-search-select__icon--place {
    transition: opacity 0.15s;
}

.rw-search-select__clear {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 0.25rem;
    cursor: pointer;
    color: #9ca3af;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    line-height: 1;
    z-index: 2;
}

.rw-search-select__clear:hover {
    color: var(--rpf-text);
}

.rpf-location-suggestions {
    position: absolute;
    top: calc(100% + 7px);
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #d7dce3;
    border-radius: 12px;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.09), 0 2px 6px rgba(15, 23, 42, 0.04);
    max-height: 220px;
    overflow-y: auto;
    z-index: 40;
    display: none;
}

.rpf-location-suggestions.show {
    display: block;
}

.rw-location-suggestion-item {
    width: 100%;
    text-align: left;
    background: transparent;
    border: none;
    color: #111827;
    margin: 2px 6px;
    width: calc(100% - 12px);
    padding: 8px 10px;
    cursor: pointer;
    transition: background-color 140ms ease;
    font-size: 0.88rem;
    font-weight: 500;
    border-radius: 8px;
}

.rw-location-suggestion-item:hover {
    background: #f3f4f6;
}

.rpf-location-suggestion {
    padding: 8px 10px;
    margin: 2px 6px;
    cursor: pointer;
    font-size: 0.88rem;
    font-weight: 500;
    border-radius: 8px;
    border-bottom: none;
    color: #111827;
    transition: background-color 140ms ease;
}

.rpf-location-suggestion:hover {
    background: #f3f4f6;
}

.rpf-location-suggestion--empty {
    cursor: default;
    color: #9ca3af;
}

/* ========================================
   Verificacao de Codigo
   ======================================== */

.rpf-verification-channels {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.rpf-channel-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1.25rem 1rem;
    background: var(--rpf-white);
    border: 1.5px solid var(--rpf-border);
    border-radius: var(--rpf-radius);
    cursor: pointer;
    transition: all 0.2s;
}

.rpf-channel-btn:hover {
    border-color: var(--rpf-primary);
    background: var(--rpf-primary-light);
}

.rpf-channel-btn.active {
    border-color: var(--rpf-primary);
    background: var(--rpf-primary-light);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

.rpf-channel-btn i {
    font-size: 1.75rem;
    color: var(--rpf-text-secondary);
}

.rpf-channel-btn.active i {
    color: var(--rpf-primary);
}

.rpf-channel-btn[data-channel="whatsapp"] i {
    color: #25D366;
}

.rpf-channel-btn__label {
    font-weight: 600;
    color: var(--rpf-text);
    font-size: 0.95rem;
}

.rpf-channel-btn__value {
    font-size: 0.8rem;
    color: var(--rpf-text-secondary);
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rpf-send-code {
    margin-top: 1.5rem;
}

.rpf-code-input-section {
    text-align: center;
}

.rpf-code-sent-to {
    color: var(--rpf-text-secondary);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.rpf-code-sent-to strong {
    color: var(--rpf-text);
}

.rpf-code-inputs {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.rpf-code-digit {
    width: 48px;
    height: 56px;
    text-align: center;
    font-size: 1.5rem;
    font-weight: 600;
    border: 1.5px solid var(--rpf-border);
    border-radius: 12px;
    background: var(--rpf-white);
    transition: all 0.2s;
    box-shadow: var(--rpf-shadow-input);
}

.rpf-code-digit:focus {
    border-color: var(--rpf-primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

.rpf-code-digit.is-invalid {
    border-color: var(--rpf-danger);
    background: #fef2f2;
    animation: shake 0.4s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-5px); }
    40%, 80% { transform: translateX(5px); }
}

.rpf-code-error {
    color: var(--rpf-danger);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    background: #fef2f2;
    border-radius: 10px;
    text-align: center;
}

.rpf-resend-section {
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: var(--rpf-text-secondary);
}

.rpf-resend-btn {
    background: none;
    border: none;
    color: var(--rpf-primary);
    font-weight: 600;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    margin-left: 0.25rem;
    transition: all 0.2s;
}

.rpf-resend-btn:hover:not(:disabled) {
    text-decoration: underline;
}

.rpf-resend-btn:disabled {
    color: var(--rpf-text-secondary);
    cursor: not-allowed;
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 576px) {
    body {
        overflow-x: hidden;
        max-width: 100vw;
    }

    .rpf-wizard {
        padding: 1.25rem 0.75rem 1.5rem;
        max-width: 100vw;
        overflow-x: hidden;
    }

    .rpf-top__title {
        font-size: 1.15rem;
    }

    .rpf-top__logo img {
        height: 36px;
    }

    .rpf-stepper {
        margin-bottom: 1rem;
        gap: 0.5rem;
    }

    .rpf-stepper__label {
        font-size: 0.6rem;
    }

    .rpf-stepper__dot {
        width: 24px;
        height: 24px;
        font-size: 0.65rem;
    }

    .rpf-stepper__item:not(:last-child)::after {
        top: 11px;
        left: calc(50% + 13px);
        width: calc(100% - 26px);
    }

    .rpf-card {
        padding: 1.25rem 1rem 1rem;
        border-radius: 16px;
    }

    .rpf-question {
        margin-bottom: 1.25rem;
    }

    .rpf-question__title {
        font-size: 1.15rem;
    }

    .rpf-step-footer {
        margin-top: 1.25rem;
        grid-template-columns: 1fr;
    }

    .rpf-footer__btn--back {
        order: 2;
    }

    .rpf-footer__btn--primary,
    .rpf-footer__btn--submit {
        order: 1;
    }

    .rpf-whatsapp-fab {
        bottom: 1rem;
        right: 1rem;
        padding: 0.7rem;
        border-radius: 50%;
    }

    .rpf-whatsapp-fab__label {
        display: none;
    }

    .rpf-whatsapp-fab i {
        font-size: 1.4rem;
    }
}

@media (max-width: 400px) {
    .rpf-wizard {
        padding: 1rem 0.5rem 1rem;
    }

    .rpf-card {
        padding: 1rem 0.875rem 1rem;
    }

    .rpf-stepper__label {
        font-size: 0.55rem;
    }

    .rpf-modal__body {
        padding: 1rem;
    }

    .rpf-question__title {
        font-size: 1.05rem;
    }
}
