/* Public portal homepage — refined theme.
   Scoped to .portal-home--refined so classic portals stay pixel-identical. */

.portal-home--refined {
    font-family: var(--rp-font, Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif);
    -webkit-font-smoothing: antialiased;
    color: var(--rp-text, #18181b);
}

.portal-home--refined .box-content {
    color: var(--rp-text, #18181b);
}

.portal-home--refined .nav-channel {
    border-bottom-color: var(--rp-border, #e4e4e7) !important;
    background: var(--rp-surface, #ffffff);
}

.portal-home--refined .btn-follow {
    background-color: transparent !important;
    border: 1px solid var(--rp-border-strong, #d4d4d8) !important;
    color: var(--rp-text, #18181b) !important;
    border-radius: var(--rp-radius-sm, 6px) !important;
    min-height: 0;
    line-height: 1.2;
    padding: 0.5rem 0.875rem;
    text-transform: none;
    letter-spacing: 0;
    font-weight: 500;
    font-size: 0.8125rem;
}

.portal-home--refined .btn-follow:hover {
    background-color: var(--rp-surface-subtle, #f4f4f5) !important;
    border-color: var(--rp-border-strong, #d4d4d8) !important;
    color: var(--rp-text, #18181b) !important;
}

.portal-home--refined .btn-follow br {
    display: none;
}

.portal-home--refined .follow-text {
    font-size: inherit;
}

.portal-home--refined .follow-text::after {
    content: ' ';
}

.portal-home--refined .forms {
    color: var(--rp-text, #18181b);
}

.portal-home--refined .overview-description {
    text-align: left;
}

.portal-home--refined .overview-description h4,
.portal-home--refined .overview-description h3,
.portal-home--refined .overview-description h2 {
    font-size: 1.5rem;
    font-weight: 650;
    letter-spacing: -0.02em;
    line-height: 1.25;
    color: var(--rp-text, #18181b);
    margin-bottom: 0.5rem;
}

.portal-home--refined .overview-description p,
.portal-home--refined .overview-description div {
    font-size: 0.9375rem;
    line-height: 1.55;
    color: var(--rp-text-secondary, #52525b);
}

.portal-home--refined .box-item {
    min-height: 0 !important;
    padding: 1.125rem 1.25rem;
    border: 1px solid var(--rp-border, #e4e4e7);
    border-radius: var(--rp-radius, 10px);
    background: var(--rp-surface, #ffffff);
    box-shadow: var(--rp-shadow-xs, 0 1px 2px rgba(0, 0, 0, 0.04));
    text-align: left !important;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.portal-home--refined .box-item:hover {
    transform: none;
    border-color: var(--rp-border-strong, #d4d4d8);
    box-shadow: var(--rp-shadow-sm, 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04));
}

.portal-home--refined .block-form-logo {
    margin: 0 !important;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--rp-radius-sm, 6px);
    background: color-mix(in srgb, var(--primary, #FF88C8) 18%, white);
    border: 1px solid color-mix(in srgb, var(--primary, #FF88C8) 28%, white);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--rp-accent, var(--primary, #FF88C8));
    flex-shrink: 0;
}

.portal-home--refined .block-form-logo .form-icon,
.portal-home--refined .block-form-logo .form-icon.my-4 {
    margin: 0 !important;
    width: 1.25rem;
    height: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.portal-home--refined .block-form-logo svg,
.portal-home--refined .block-form-logo i,
.portal-home--refined .block-form-logo .ti,
.portal-home--refined .block-form-logo .width-50,
.portal-home--refined .form-icon svg,
.portal-home--refined .form-icon i,
.portal-home--refined .form-icon .ti {
    width: 1.25rem !important;
    height: 1.25rem !important;
    font-size: 1.25rem;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.portal-home--refined .block-form-title-description {
    flex: 1 1 auto;
    min-width: 0;
}

.portal-home--refined .form-title,
.portal-home--refined .form-description {
    text-align: left;
}

.portal-home--refined .form-title {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.3;
    color: var(--rp-text, #18181b);
    margin-bottom: 0.25rem;
}

.portal-home--refined .form-title h4,
.portal-home--refined .form-title h3 {
    font-size: inherit;
    font-weight: inherit;
    margin: 0;
}

.portal-home--refined .form-description {
    margin-bottom: 0 !important;
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--rp-text-secondary, #52525b);
}

.portal-home--refined .btn-form {
    position: static !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    margin: 0 !important;
    width: auto !important;
    max-width: 100%;
    min-height: 2rem;
    height: 2rem !important;
    padding: 0 0.875rem !important;
    border-radius: var(--rp-radius-sm, 6px) !important;
    font-size: 0.8125rem;
    font-weight: 500;
    align-self: flex-start;
}

.portal-home--refined .forms:not(.forms_list_view) .form-description {
    margin-bottom: 0 !important;
}

.portal-home--refined .forms:not(.forms_list_view) input.editable-form-button.btn-form,
.portal-home--refined .forms:not(.forms_list_view) .btn-form {
    position: static !important;
    bottom: auto !important;
}

.portal-home--refined .edit-form-meta {
    position: static !important;
    align-items: flex-start;
    gap: 0.125rem;
    margin: 0.375rem 0 0;
}

.portal-home--refined .forms.forms_list_view .edit-form-meta {
    align-items: flex-end;
}

.portal-home--refined a.edit-form-questions,
.portal-home--refined button.edit-form-details {
    position: static !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    z-index: 2;
    display: inline-flex !important;
    align-items: center;
    justify-content: flex-start !important;
    width: auto !important;
    max-width: none !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    color: var(--rp-text-secondary, #52525b) !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    line-height: 1.3;
    text-decoration: none;
    cursor: pointer;
}

.portal-home--refined a.edit-form-questions:hover,
.portal-home--refined button.edit-form-details:hover {
    color: var(--rp-text, #18181b) !important;
    background: transparent !important;
}

.portal-home--refined .forms.forms_list_view .form .box-item {
    flex-direction: row;
    align-items: flex-start;
    gap: 1rem;
    min-height: 0 !important;
}

.portal-home--refined .forms.forms_list_view .form .box-item .block-form-logo {
    flex: 0 0 2.5rem !important;
}

.portal-home--refined .forms.forms_list_view .form .box-item .block-form-button {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.portal-home--refined .portal-home-trust {
    display: flex;
    justify-content: center;
    width: 100%;
    flex: 0 0 100%;
    max-width: 100%;
    margin: 0.5rem 0 0.25rem;
    padding: 0;
    background: transparent;
    color: inherit;
    font-size: inherit;
    font-weight: inherit;
}

.portal-home--refined .portal-home-trust__pill {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.625rem;
    border-radius: 999px;
    background: var(--rp-success-bg, #ecfdf5);
    color: var(--rp-success, #059669);
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.3;
}

.portal-home--refined .portal-home-trust svg {
    flex-shrink: 0;
}

.portal-home--refined .portal-section {
    padding: 3.5rem 1.5rem;
    color: var(--rp-text, #18181b);
}

.portal-home--refined .portal-section-title {
    font-size: 1.25rem;
    font-weight: 650;
    letter-spacing: -0.02em;
    margin-bottom: 1.75rem;
}

.portal-home--refined .portal-how-it-works {
    background-color: var(--rp-surface-muted, #fafafa);
}

.portal-home--refined .portal-steps {
    gap: 0.5rem;
}

.portal-home--refined .portal-step {
    max-width: 200px;
    padding: 0.5rem;
}

.portal-home--refined .portal-step-number {
    width: 1.5rem;
    height: 1.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.portal-home--refined .portal-step-icon {
    display: none;
}

.portal-home--refined .portal-step-title {
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.portal-home--refined .portal-step-desc {
    font-size: 0.8125rem;
    color: var(--rp-text-secondary, #52525b);
}

.portal-home--refined .portal-step-arrow {
    padding-top: 0.35rem;
    font-size: 1rem;
    color: var(--rp-text-tertiary, #71717a);
    opacity: 1;
}

.portal-home--refined .portal-faq {
    background-color: var(--rp-surface, #ffffff);
}

.portal-home--refined .portal-faq-item {
    border-color: var(--rp-border, #e4e4e7);
    border-radius: var(--rp-radius, 10px);
    margin-bottom: 0.5rem;
}

.portal-home--refined .portal-faq-question {
    font-size: 0.875rem;
    font-weight: 550;
    color: var(--rp-text, #18181b);
    padding: 0.875rem 1rem;
}

.portal-home--refined .portal-faq-question:hover {
    background: var(--rp-surface-muted, #fafafa);
}

.portal-home--refined .portal-faq-answer-body {
    font-size: 0.875rem;
    color: var(--rp-text-secondary, #52525b);
    padding: 0 1rem 1rem;
}

.portal-home--refined .portal-compliance {
    background: var(--rp-surface-muted, #fafafa);
}

.portal-home--refined .portal-compliance-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    max-width: 880px;
}

.portal-home--refined .portal-compliance-item {
    background: var(--rp-surface, #ffffff);
    border: 1px solid var(--rp-border, #e4e4e7);
    border-radius: var(--rp-radius, 10px);
    box-shadow: none;
    padding: 0.875rem 1rem;
    min-width: 160px;
    flex: 1 1 160px;
    max-width: 200px;
    text-align: left;
}

.portal-home--refined .portal-compliance-item:hover {
    transform: none;
    box-shadow: none;
    border-color: var(--rp-border-strong, #d4d4d8);
}

.portal-home--refined .portal-compliance-icon {
    width: 1.5rem;
    height: 1.5rem;
    margin: 0 0 0.5rem;
}

.portal-home--refined .portal-compliance-icon svg {
    width: 1.5rem;
    height: 1.5rem;
}

.portal-home--refined .portal-compliance-label {
    font-size: 0.8125rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.portal-home--refined .portal-compliance-desc {
    font-size: 0.75rem;
    color: var(--rp-text-secondary, #52525b);
    line-height: 1.45;
}

.portal-home--refined .portal-leadership {
    background-color: var(--rp-surface, #ffffff);
}

.portal-home--refined .portal-leadership-card {
    background: var(--rp-surface-muted, #fafafa);
    border: 1px solid var(--rp-border, #e4e4e7);
    border-radius: var(--rp-radius, 10px);
    box-shadow: none;
    padding: 1.75rem 2rem;
}

.portal-home--refined .portal-leadership-card.is-compact {
    padding: 1.25rem 1.5rem;
}

.portal-home--refined .portal-leadership-card.is-compact .portal-leadership-author {
    margin: 0;
}

.portal-home--refined .portal-leadership-message {
    font-size: 1rem;
    font-style: normal;
    color: var(--rp-text, #18181b);
}

.portal-home--refined .portal-footer-section {
    background-color: var(--rp-surface-subtle, #f4f4f5);
    padding: 2.5rem 1.5rem;
}

.portal-home--refined .portal-home-utility {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 1rem 2.5rem;
}

.portal-home--refined .qrcode {
    box-shadow: none;
    border: 1px solid var(--rp-border, #e4e4e7);
    border-radius: var(--rp-radius, 10px);
    background: var(--rp-surface, #ffffff);
    margin: 0;
    color: var(--rp-text-secondary, #52525b);
    font-size: 0.8125rem;
}

@media (max-width: 767px) {
    .portal-home--refined .overview-description {
        text-align: center;
    }

    .portal-home--refined .box-item {
        text-align: center !important;
        align-items: center;
    }

    .portal-home--refined .form-title,
    .portal-home--refined .form-description {
        text-align: center;
    }

    .portal-home--refined .btn-form {
        align-self: center;
    }

    .portal-home--refined .forms.forms_list_view .form .box-item {
        flex-direction: column;
        text-align: center;
    }

    .portal-home--refined .forms.forms_list_view .form .box-item .block-form-button {
        align-items: center;
    }

    .portal-home--refined .portal-compliance-item {
        text-align: center;
        max-width: none;
    }

    .portal-home--refined .portal-compliance-icon {
        margin-left: auto;
        margin-right: auto;
    }
}
