:root {
    --bf-navy: #0c447c;
    --bf-navy-dark: #042c53;
    --bf-blue: #378add;
    --bf-blue-light: #e6f1fb;
    --bf-silver: #c8cdd4;
    --bf-silver-light: #e8eaed;
    --bf-text: #1c2330;
    --bf-muted: #667085;
    --bf-border: #dce3eb;
    --bf-surface: #ffffff;
    --bf-surface-alt: #f8f9fb;
    --bf-radius: 12px;
    --bf-shadow: 0 8px 24px rgba(4, 44, 83, 0.08);
}

.bf-account-nav,
.bf-account-section,
.bf-account-gate {
    box-sizing: border-box;
    color: var(--bf-text);
    font-family: Inter, "DM Sans", Arial, Helvetica, sans-serif;
}

.bf-account-nav *,
.bf-account-section *,
.bf-account-gate * {
    box-sizing: border-box;
}

.bf-account-nav {
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--bf-border);
    border-radius: var(--bf-radius);
    background: var(--bf-surface);
    box-shadow: var(--bf-shadow);
}

.bf-account-nav__identity {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 18px;
    border-bottom: 1px solid var(--bf-border);
    background: var(--bf-navy-dark);
    color: #fff;
}

.bf-account-nav__avatar {
    display: inline-flex;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--bf-silver);
    color: var(--bf-text);
    font-size: 13px;
    font-weight: 700;
}

.bf-account-nav__identity-text {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.bf-account-nav__identity-text strong {
    overflow: hidden;
    font-size: 14px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bf-account-nav__identity-text small {
    margin-top: 2px;
    color: #b5d4f4;
    font-size: 11px;
    text-transform: capitalize;
}

.bf-account-nav__list {
    margin: 0;
    padding: 10px;
    list-style: none;
}

.bf-account-nav__list--children {
    padding: 4px 0 8px 8px;
}

.bf-account-nav__item {
    margin: 0;
}

.bf-account-nav__row {
    position: relative;
    display: flex;
    overflow: hidden;
    align-items: stretch;
    border-radius: 9px;
    background: transparent;
    color: var(--bf-navy-dark);
    box-shadow: none;
    transition:
        background-color 0.15s ease,
        color 0.15s ease,
        box-shadow 0.15s ease;
}

.bf-account-nav__row:hover {
    background: rgba(55, 138, 221, 0.10);
    color: var(--bf-navy);
}

.bf-account-nav__row:focus-within {
    background: rgba(55, 138, 221, 0.10);
    color: var(--bf-navy);
    box-shadow: inset 0 0 0 2px rgba(55, 138, 221, 0.72);
}

/*
 * Selected items use a stronger treatment than hover. Merely expanding a
 * parent does not color the row.
 */
.bf-account-nav__item.is-current > .bf-account-nav__row {
    background: rgba(12, 68, 124, 0.14);
    color: var(--bf-navy-dark);
    box-shadow: inset 3px 0 0 var(--bf-navy);
}

.bf-account-nav__item.has-children.is-current > .bf-account-nav__row {
    background: rgba(200, 205, 212, 0.52);
    color: var(--bf-navy-dark);
}

.bf-account-nav__item.has-current-descendant > .bf-account-nav__row {
    background: transparent;
    color: var(--bf-navy);
    box-shadow: inset 3px 0 0 rgba(55, 138, 221, 0.82);
}

.bf-account-nav__item.has-current-descendant > .bf-account-nav__row:hover,
.bf-account-nav__item.has-current-descendant > .bf-account-nav__row:focus-within {
    background: rgba(55, 138, 221, 0.10);
}

.bf-account-nav__item.is-expanded:not(.is-current):not(.has-current-descendant) > .bf-account-nav__row {
    background: transparent;
    box-shadow: none;
}

.bf-account-nav__item.is-expanded:not(.is-current):not(.has-current-descendant) > .bf-account-nav__row:hover,
.bf-account-nav__item.is-expanded:not(.is-current):not(.has-current-descendant) > .bf-account-nav__row:focus-within {
    background: rgba(55, 138, 221, 0.10);
}

.bf-account-nav__link {
    display: flex;
    min-width: 0;
    flex: 1 1 auto;
    gap: 10px;
    align-items: center;
    padding: 11px 12px;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: inherit;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.25;
    text-decoration: none;
    box-shadow: none;
}

.bf-account-nav__link:hover,
.bf-account-nav__link:focus,
.bf-account-nav__link:focus-visible {
    border: 0;
    background: transparent;
    color: inherit;
    outline: 0;
    box-shadow: none;
}

.bf-account-nav__item.is-disabled > .bf-account-nav__row .bf-account-nav__link {
    cursor: not-allowed;
    opacity: 0.52;
}

.bf-account-nav__label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bf-account-nav__toggle,
.bf-account-nav .bf-account-nav__toggle:hover,
.bf-account-nav .bf-account-nav__toggle:focus,
.bf-account-nav .bf-account-nav__toggle:focus-visible {
    display: inline-flex;
    width: 44px;
    min-height: 44px;
    flex: 0 0 44px;
    align-items: center;
    justify-content: center;
    align-self: stretch;
    margin: 0;
    padding: 0;
    border: 0 !important;
    border-radius: 0;
    appearance: none;
    background: transparent !important;
    color: inherit;
    cursor: pointer;
    outline: 0 !important;
    box-shadow: none !important;
}


.bf-account-section {
    width: 100%;
}

.bf-account-section__header {
    margin-bottom: 24px;
}

.bf-account-section__header h1 {
    margin: 10px 0 8px;
    color: var(--bf-navy-dark);
    font-size: clamp(28px, 3vw, 42px);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.12;
}

.bf-account-section__header p {
    max-width: 760px;
    margin: 0;
    color: var(--bf-muted);
    font-size: 16px;
    line-height: 1.65;
}

.bf-account-dashboard__hero {
    padding: clamp(24px, 4vw, 48px);
    border-radius: var(--bf-radius);
    background: var(--bf-navy);
}

.bf-account-dashboard__hero h1 {
    color: #fff;
}

.bf-account-dashboard__hero p {
    color: #b5d4f4;
}

.bf-pill {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--bf-silver);
    color: var(--bf-text);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 1;
    text-transform: uppercase;
}

.bf-pill--muted {
    background: var(--bf-blue-light);
    color: var(--bf-navy);
}

.bf-account-dashboard__metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin: 24px 0;
}

.bf-metric-card,
.bf-panel-card,
.bf-profile-card,
.bf-empty-state {
    border: 1px solid var(--bf-border);
    border-radius: var(--bf-radius);
    background: var(--bf-surface);
    box-shadow: 0 4px 16px rgba(4, 44, 83, 0.04);
}

.bf-metric-card {
    padding: 20px;
}

.bf-metric-card__value {
    display: block;
    margin-bottom: 10px;
    color: var(--bf-blue);
    font-size: 30px;
    line-height: 1;
}

.bf-metric-card h2,
.bf-panel-card h2,
.bf-empty-state h2 {
    margin: 0 0 7px;
    color: var(--bf-navy-dark);
    font-size: 17px;
    line-height: 1.25;
}

.bf-metric-card p,
.bf-panel-card p,
.bf-empty-state p {
    margin: 0;
    color: var(--bf-muted);
    font-size: 13px;
    line-height: 1.55;
}

.bf-account-dashboard__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.bf-panel-card {
    padding: 24px;
}

.bf-panel-card h2 {
    margin-top: 13px;
    font-size: 20px;
}

.bf-profile-card {
    padding: clamp(20px, 3vw, 34px);
}

.bf-profile-card__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 0 0 20px;
}

.bf-profile-card__grid > div {
    padding: 15px;
    border-radius: 9px;
    background: var(--bf-surface-alt);
}

.bf-profile-card dt {
    margin-bottom: 4px;
    color: var(--bf-muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.bf-profile-card dd {
    margin: 0;
    color: var(--bf-navy-dark);
    font-size: 14px;
    overflow-wrap: anywhere;
}


.bf-account-message {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin: 0 0 18px;
    padding: 14px 16px;
    border: 1px solid var(--bf-border);
    border-radius: 9px;
    background: var(--bf-surface);
}

.bf-account-message .dashicons {
    flex: 0 0 auto;
    margin-top: 1px;
}

.bf-account-message p {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
}

.bf-account-message--success {
    border-color: #b8d7a0;
    background: #f4f9ef;
    color: #27500a;
}

.bf-account-message--error {
    border-color: #e7b6b6;
    background: #fff5f5;
    color: #791f1f;
}

.bf-profile-form__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.bf-profile-form__field {
    min-width: 0;
}

.bf-profile-form__field label {
    display: block;
    margin-bottom: 7px;
    color: var(--bf-navy-dark);
    font-size: 13px;
    font-weight: 700;
}

.bf-profile-form__field label span {
    color: #b42318;
}

.bf-profile-form__field input,
.bf-profile-form__field select,
.bf-profile-form__field textarea {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid var(--bf-border);
    border-radius: 8px;
    background: var(--bf-surface);
    color: var(--bf-text);
    font: inherit;
    line-height: 1.35;
}

.bf-profile-form__field textarea {
    min-height: 110px;
    resize: vertical;
}

.bf-profile-form__field input:focus,
.bf-profile-form__field select:focus,
.bf-profile-form__field textarea:focus {
    border-color: var(--bf-blue);
    outline: 2px solid rgba(55, 138, 221, 0.22);
    outline-offset: 1px;
}

.bf-profile-form__description {
    margin: 6px 0 0;
    color: var(--bf-muted);
    font-size: 11px;
    line-height: 1.45;
}

.bf-profile-card__grid--readonly {
    margin-top: 4px;
}

.bf-profile-card__term,
.bf-profile-card__value {
    display: block;
}

.bf-profile-card__term {
    margin-bottom: 4px;
    color: var(--bf-muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.bf-profile-card__value {
    color: var(--bf-navy-dark);
    font-size: 14px;
    overflow-wrap: anywhere;
}

.bf-profile-form__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.bf-profile-card__notice {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin-bottom: 18px;
    padding: 14px;
    border: 1px solid #cfe1f5;
    border-radius: 9px;
    background: #f3f8fd;
}

.bf-profile-card__notice p {
    margin: 0;
    color: var(--bf-muted);
    font-size: 13px;
    line-height: 1.5;
}

.bf-empty-state {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    padding: clamp(22px, 4vw, 38px);
    border-style: dashed;
    background: var(--bf-surface-alt);
}

.bf-empty-state > .dashicons {
    width: 42px;
    height: 42px;
    color: var(--bf-blue);
    font-size: 42px;
}

.bf-account-gate {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    padding: clamp(22px, 4vw, 38px);
    border: 1px solid var(--bf-border);
    border-radius: var(--bf-radius);
    background: var(--bf-surface);
    box-shadow: var(--bf-shadow);
}

.bf-account-gate__icon {
    width: 38px;
    height: 38px;
    color: var(--bf-blue);
    font-size: 38px;
}

.bf-account-gate h2 {
    margin: 0 0 8px;
    color: var(--bf-navy-dark);
    font-size: 24px;
}

.bf-account-gate p {
    margin: 0;
    color: var(--bf-muted);
    line-height: 1.6;
}

.bf-account-gate__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.bf-button {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    padding: 9px 16px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
}

.bf-button--primary {
    border-color: var(--bf-navy);
    background: var(--bf-navy);
    color: #fff;
}

.bf-button--secondary {
    border-color: var(--bf-silver);
    background: var(--bf-silver-light);
    color: var(--bf-text);
}

.bf-button:hover,
.bf-button:focus-visible {
    filter: brightness(0.96);
}

@media (max-width: 980px) {
    .bf-account-dashboard__metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .bf-account-dashboard__metrics,
    .bf-account-dashboard__grid,
    .bf-profile-card__grid,
    .bf-profile-form__grid {
        grid-template-columns: 1fr;
    }

    .bf-account-gate,
    .bf-empty-state {
        flex-direction: column;
    }
}

.bf-account-link {
    display: inline-flex;
    gap: 5px;
    align-items: center;
    margin-top: 14px;
    color: var(--bf-blue);
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
}

.bf-account-link:hover,
.bf-account-link:focus-visible {
    color: var(--bf-navy);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Suite v0.14.1: self-hosted SVG account navigation icons. */
.bf-account-nav__icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    background: currentColor;
    -webkit-mask: var(--bf-account-icon) center / contain no-repeat;
    mask: var(--bf-account-icon) center / contain no-repeat;
}

.bf-account-nav__chevron {
    display: inline-block;
    width: 9px;
    height: 9px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform .15s ease;
}

.bf-account-nav__toggle[aria-expanded="true"] .bf-account-nav__chevron {
    transform: rotate(225deg) translate(-1px, -1px);
}
