/**
 * Partner Registration Form Styles
 * BEM naming: .partner-registration__*
 */

/* ─── Container ─── */
.partner-registration {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 20px 60px;
    font-family: 'Proza Libre', Georgia, serif;
    color: #1a1a2e;
}

.partner-registration__container {
    width: 100%;
}

/* ─── Header ─── */
.partner-registration__header {
    text-align: center;
    margin-bottom: 40px;
}

.partner-registration__title {
    font-size: 2rem;
    font-weight: 700;
    color: #010C80;
    margin: 0 0 12px;
    line-height: 1.2;
}

.partner-registration__subtitle {
    font-size: 1.1rem;
    color: #555;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ─── Layout: Form + Info Side-by-Side ─── */
.partner-registration__layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 48px;
    align-items: start;
}

.partner-registration__form-col {
    min-width: 0;
}

/* ─── Form ─── */
.partner-registration__form {
    position: relative;
}

.partner-registration__row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* ─── Fields ─── */
.partner-registration__field {
    margin-bottom: 20px;
}

.partner-registration__label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 6px;
}

.partner-registration__required {
    color: #dc3232;
}

.partner-registration__optional {
    font-weight: 400;
    color: #888;
    font-size: 0.85rem;
}

.partner-registration__input,
.partner-registration__textarea {
    display: block;
    width: 100%;
    padding: 10px 14px;
    font-size: 0.95rem;
    font-family: inherit;
    color: #1a1a2e;
    background: #fff;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.partner-registration__input:focus,
.partner-registration__textarea:focus {
    outline: none;
    border-color: #0080FF;
    box-shadow: 0 0 0 3px rgba(0, 128, 255, 0.12);
}

.partner-registration__input--error,
.partner-registration__textarea--error {
    border-color: #dc3232;
}

.partner-registration__input--error:focus,
.partner-registration__textarea--error:focus {
    box-shadow: 0 0 0 3px rgba(220, 50, 50, 0.12);
}

.partner-registration__textarea {
    resize: vertical;
    min-height: 100px;
}

.partner-registration__field-error {
    display: block;
    font-size: 0.82rem;
    color: #dc3232;
    margin-top: 4px;
    min-height: 1.2em;
}

/* ─── Custom Country Select ─── */
.partner-registration__select-wrapper {
    position: relative;
}

.partner-registration__select-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    background: #fff;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
    user-select: none;
    font-size: 0.95rem;
}

.partner-registration__select-display:focus {
    outline: none;
    border-color: #0080FF;
    box-shadow: 0 0 0 3px rgba(0, 128, 255, 0.12);
}

.partner-registration__select-display--open {
    border-color: #0080FF;
    box-shadow: 0 0 0 3px rgba(0, 128, 255, 0.12);
}

.partner-registration__select-display--error {
    border-color: #dc3232;
}

.partner-registration__select-placeholder {
    color: #9ca3af;
}

.partner-registration__select-display--selected .partner-registration__select-placeholder {
    color: #1a1a2e;
}

.partner-registration__select-arrow {
    flex-shrink: 0;
    color: #6b7280;
    transition: transform 0.2s;
}

.partner-registration__select-display--open .partner-registration__select-arrow {
    transform: rotate(180deg);
}

.partner-registration__select-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: #fff;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    z-index: 100;
    max-height: 280px;
    flex-direction: column;
}

.partner-registration__select-dropdown[hidden] {
    display: none;
}

.partner-registration__select-dropdown:not([hidden]) {
    display: flex;
}

.partner-registration__select-search {
    padding: 10px 14px;
    border: none;
    border-bottom: 1px solid #e5e7eb;
    font-size: 0.9rem;
    font-family: inherit;
    outline: none;
    flex-shrink: 0;
}

.partner-registration__select-list {
    list-style: none;
    margin: 0;
    padding: 4px 0;
    overflow-y: auto;
    flex: 1;
}

.partner-registration__select-option {
    padding: 8px 14px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.1s;
}

.partner-registration__select-option:hover,
.partner-registration__select-option--highlighted {
    background: #f0f7ff;
}

.partner-registration__select-option--selected {
    background: #e8f4ff;
    font-weight: 600;
}

.partner-registration__select-option--hidden {
    display: none;
}

.partner-registration__select-separator {
    height: 1px;
    background: #e5e7eb;
    margin: 4px 14px;
}

/* ─── Phone with Prefix ─── */
.partner-registration__phone-wrapper {
    display: flex;
    align-items: stretch;
}

.partner-registration__phone-prefix {
    display: flex;
    align-items: center;
    padding: 0 12px;
    background: #f3f4f6;
    border: 2px solid #e5e7eb;
    border-right: none;
    border-radius: 6px 0 0 6px;
    font-size: 0.9rem;
    color: #555;
    white-space: nowrap;
    min-width: 52px;
    justify-content: center;
}

.partner-registration__input--phone {
    border-radius: 0 6px 6px 0;
}

/* ─── Consent ─── */
.partner-registration__consent-group {
    margin: 28px 0 24px;
}

.partner-registration__consent {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 14px;
    cursor: pointer;
    line-height: 1.5;
}

.partner-registration__checkbox {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #0080FF;
    cursor: pointer;
}

.partner-registration__consent-text {
    font-size: 0.88rem;
    color: #444;
}

.partner-registration__consent-text a {
    color: #0080FF;
    text-decoration: underline;
}

.partner-registration__consent-text a:hover {
    color: #005BBB;
}

/* ─── Submit Button ─── */
.partner-registration__submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 14px 32px;
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    color: #fff;
    background: #0080FF;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.partner-registration__submit:hover {
    background: #005BBB;
}

.partner-registration__submit:active {
    transform: scale(0.98);
}

.partner-registration__submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* ─── Spinner ─── */
.partner-registration__spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: pdn-reg-spin 0.6s linear infinite;
}

@keyframes pdn-reg-spin {
    to { transform: rotate(360deg); }
}

/* ─── Error Banner ─── */
.partner-registration__error-banner {
    padding: 12px 16px;
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 6px;
    color: #991b1b;
    font-size: 0.9rem;
    margin-bottom: 20px;
}

/* ─── Success State ─── */
.partner-registration__success {
    text-align: center;
    padding: 60px 20px;
}

.partner-registration__success-icon {
    color: #1E6B27;
    margin-bottom: 20px;
}

.partner-registration__success-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1E6B27;
    margin: 0 0 12px;
}

.partner-registration__success-text {
    font-size: 1rem;
    color: #555;
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ─── Info Box ─── */
.partner-registration__info-col {
    position: sticky;
    top: 100px;
}

.partner-registration__info-box {
    background: #f0f7ff;
    border: 1px solid #d0e3f7;
    border-radius: 10px;
    padding: 28px 24px;
}

.partner-registration__info-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #010C80;
    margin: 0 0 20px;
}

.partner-registration__info-steps {
    list-style: none;
    margin: 0;
    padding: 0;
}

.partner-registration__info-step {
    display: flex;
    gap: 14px;
    margin-bottom: 20px;
}

.partner-registration__info-step:last-child {
    margin-bottom: 0;
}

.partner-registration__info-step-num {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    background: #0080FF;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    margin-top: 2px;
}

.partner-registration__info-step strong {
    display: block;
    font-size: 0.95rem;
    color: #1a1a2e;
    margin-bottom: 4px;
}

.partner-registration__info-step p {
    margin: 0;
    font-size: 0.85rem;
    color: #555;
    line-height: 1.5;
}

/* ─── Responsive ─── */
@media (max-width: 900px) {
    .partner-registration__layout {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .partner-registration__info-col {
        position: static;
        order: -1;
    }
}

@media (max-width: 600px) {
    .partner-registration {
        padding: 24px 16px 40px;
    }

    .partner-registration__title {
        font-size: 1.5rem;
    }

    .partner-registration__subtitle {
        font-size: 0.95rem;
    }

    .partner-registration__row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .partner-registration__header {
        margin-bottom: 24px;
    }
}
