:root {
    --profile-primary: #3aadb8;
    --profile-primary-dark: #287b84;
    --profile-accent: #fca501;
    --profile-bg: #f5f8fa;
    --profile-border: #e3e8ee;
    --profile-text: #1c2b36;
    --profile-muted: #6c7c8c;
}

.profile-hero {
    background: linear-gradient(135deg, rgba(58, 173, 184, 0.12), rgba(40, 123, 132, 0.12));
    padding: 64px 0 40px;
}

.profile-hero__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
    align-items: stretch;
}

.profile-hero__eyebrow {
    display: inline-block;
    font-size: 14px;
    font-weight: 600;
    color: var(--profile-primary-dark);
    margin-bottom: 8px;
}

.profile-hero__title {
    font-size: 32px;
    font-weight: 700;
    color: var(--profile-text);
    margin-bottom: 12px;
}

.profile-hero__subtitle {
    font-size: 16px;
    color: var(--profile-muted);
    line-height: 1.9;
    margin-bottom: 20px;
}

.profile-hero__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
}

.profile-chip {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    background: rgba(58, 173, 184, 0.16);
    color: var(--profile-primary-dark);
}

.profile-chip--status {
    background: rgba(40, 123, 132, 0.1);
    color: #1f6f76;
}

.profile-chip--reward {
    background: rgba(252, 165, 1, 0.18);
    color: #c17900;
}

.profile-hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.profile-hero__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 22px;
    border-radius: 10px;
    border: 1px solid transparent;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s ease, background 0.2s ease;
}

.profile-hero__button--primary {
    background: var(--profile-primary);
    color: #fff;
}

.profile-hero__button--ghost {
    background: #fff;
    border-color: var(--profile-border);
    color: var(--profile-primary-dark);
}

.profile-hero__button:hover {
    transform: translateY(-2px);
}

.profile-hero__meta {
    display: grid;
    gap: 16px;
}

.profile-hero__card {
    background: #fff;
    border-radius: 18px;
    padding: 24px;
    box-shadow: 0 20px 45px rgba(28, 88, 96, 0.08);
    display: grid;
    gap: 12px;
}

.profile-hero__card--muted {
    background: linear-gradient(135deg, rgba(252, 165, 1, 0.08), rgba(252, 165, 1, 0.02));
}

.profile-hero__card-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--profile-muted);
    letter-spacing: 0.4px;
}

.profile-hero__card-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--profile-text);
}

.profile-hero__card-desc {
    font-size: 14px;
    color: var(--profile-muted);
    line-height: 1.8;
}

.profile-hero__ref {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(58, 173, 184, 0.12);
    padding: 8px 12px;
    border-radius: 12px;
    font-weight: 600;
    color: var(--profile-primary-dark);
}

.profile-hero__mini-link {
    font-size: 13px;
    color: var(--profile-primary-dark);
    text-decoration: none;
}

.profile-hero__mini-button {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 13px;
    font-family: inherit;
    color: var(--profile-primary-dark);
    padding: 0;
}

/* ── org portal aside: fix dark-on-dark text in public hero ── */
.public-hero__meta .profile-hero__ref {
    background: rgba(255,255,255,.12) !important;
    color: rgba(255,255,255,.9) !important;
    border: 1px solid rgba(255,255,255,.2);
}
.public-hero__meta .profile-hero__mini-link,
.public-hero__meta .profile-hero__mini-button {
    color: rgba(255,255,255,.85) !important;
}
.public-hero__meta .profile-hero__card-title {
    color: rgba(255,255,255,.7) !important;
}
.public-hero__meta .profile-hero__card-value {
    color: #fff !important;
}

.profile-tabs {
    background: #fff;
    border-bottom: 1px solid var(--profile-border);
}

.profile-tabs__list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.profile-tabs__item {
    margin: 0;
}

.profile-tabs__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 18px;
    border-radius: 10px 10px 0 0;
    color: var(--profile-muted);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease, background 0.2s ease;
}

.profile-tabs__link.is-active {
    background: #fff;
    border: 1px solid var(--profile-border);
    border-bottom-color: #fff;
    color: var(--profile-primary-dark);
}

.profile-tabs__link:hover {
    color: var(--profile-primary-dark);
}

.profile-tabs__item--logout {
    margin-right: auto;
}

.profile-tabs__link--logout {
    color: #d9534f;
}

.profile-main {
    background: #fff;
    padding: 40px 0 80px;
}

.profile-alert {
    margin: 16px auto;
    max-width: 720px;
    padding: 14px 18px;
    border-radius: 12px;
    font-weight: 600;
    text-align: center;
}

.profile-alert--success {
    background: rgba(82, 196, 26, 0.12);
    color: #3f8c15;
}

.profile-phase {
    margin-bottom: 48px;
}

.profile-phase__header {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 24px;
}

.profile-phase__badge {
    align-self: flex-start;
    padding: 4px 12px;
    border-radius: 999px;
    background: rgba(58, 173, 184, 0.12);
    color: var(--profile-primary-dark);
    font-weight: 600;
    font-size: 12px;
    letter-spacing: 0.4px;
}

.profile-phase__badge--muted {
    background: rgba(108, 124, 140, 0.12);
    color: var(--profile-muted);
}

.profile-phase__header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--profile-text);
    margin: 0;
}

.profile-phase__header p {
    font-size: 15px;
    color: var(--profile-muted);
    margin: 0;
    line-height: 1.9;
}

.profile-phase__content {
    display: grid;
    gap: 24px;
}

.profile-phase__content--columns {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.profile-phase__content--grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
}

.profile-phase__content--faq details {
    background: #fff;
    border: 1px solid var(--profile-border);
    border-radius: 14px;
    padding: 16px 18px;
    font-size: 14px;
    color: var(--profile-text);
}

.profile-phase__content--faq summary {
    cursor: pointer;
    font-weight: 600;
    color: var(--profile-primary-dark);
}

.profile-card {
    background: #fff;
    border: 1px solid var(--profile-border);
    border-radius: 18px;
    padding: 24px;
    display: grid;
    gap: 20px;
    box-shadow: 0 12px 32px rgba(28, 88, 96, 0.06);
}

.profile-card--form {
    align-content: start;
}

.profile-card--summary {
    background: linear-gradient(135deg, rgba(58, 173, 184, 0.08), rgba(58, 173, 184, 0.02));
}

.profile-card--share {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

.profile-card--empty,
.profile-card--info {
    text-align: center;
    background: rgba(108, 124, 140, 0.06);
    border: 1px dashed rgba(108, 124, 140, 0.4);
}

.profile-card__title {
    font-size: 16px;
    font-weight: 700;
    margin: 0;
    color: var(--profile-text);
}

.profile-form {
    display: grid;
    gap: 16px;
}

.profile-edit-request {
    display: grid;
    gap: 12px;
    padding: 16px 18px;
    border: 1px dashed var(--profile-border);
    border-radius: 14px;
    background: rgba(58, 173, 184, 0.06);
}

.profile-edit-request form {
    margin: 0;
}

.profile-edit-request p {
    margin: 0;
    font-size: 14px;
    line-height: 1.9;
    color: var(--profile-muted);
}

.profile-edit-request .profile-button {
    justify-self: start;
}

.profile-form__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.profile-form__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 14px;
    color: var(--profile-muted);
}

.profile-form__field input,
.profile-form__field select,
.profile-share__input,
.profile-share__select,
.profile-search input {
    border: 1px solid var(--profile-border);
    border-radius: 12px;
    padding: 10px 12px;
    font-size: 14px;
    transition: border 0.2s ease;
}

.profile-form__field input:focus,
.profile-form__field select:focus,
.profile-share__input:focus,
.profile-share__select:focus,
.profile-search input:focus {
    outline: none;
    border-color: var(--profile-primary);
}

.profile-form__field--full {
    grid-column: 1 / -1;
}

.profile-form__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.profile-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 18px;
    border-radius: 12px;
    border: 1px solid transparent;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.profile-button--primary {
    background: var(--profile-primary);
    color: #fff;
    box-shadow: 0 10px 20px rgba(58, 173, 184, 0.18);
}

.profile-button--ghost {
    background: #fff;
    border-color: var(--profile-border);
    color: var(--profile-primary-dark);
}

.profile-button--mini {
    padding: 6px 12px;
    font-size: 12px;
}

.profile-button--mini.profile-button--primary {
    box-shadow: none;
}

.profile-button:hover {
    transform: translateY(-1px);
    text-decoration: none;
}

.profile-tips {
    margin: 0;
    padding-right: 18px;
    display: grid;
    gap: 10px;
    font-size: 14px;
    color: var(--profile-muted);
}

.profile-mini-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border-radius: 999px;
    border: 1px solid var(--profile-border);
    font-size: 13px;
    color: var(--profile-primary-dark);
    text-decoration: none;
}

.profile-summary-card {
    background: #fff;
    border: 1px solid var(--profile-border);
    border-radius: 18px;
    padding: 24px;
    display: grid;
    gap: 16px;
    box-shadow: 0 12px 26px rgba(28, 88, 96, 0.06);
}

.profile-summary-card__header {
    display: grid;
    gap: 6px;
}

.profile-summary-card__eyebrow {
    font-size: 12px;
    color: var(--profile-muted);
    letter-spacing: 0.4px;
}

.profile-summary-card__actions,
.profile-summary-card__cta-stack,
.profile-card__cta-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.profile-summary-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: 8px;
    font-size: 14px;
    color: var(--profile-text);
}

.profile-note {
    font-size: 13px;
    color: var(--profile-muted);
    line-height: 1.8;
}

.profile-share__summary {
    display: grid;
    gap: 12px;
}

.profile-share__code {
    font-size: 28px;
    font-weight: 700;
    color: var(--profile-primary-dark);
    letter-spacing: 2px;
    text-align: center;
    padding: 12px;
    background: rgba(58, 173, 184, 0.12);
    border-radius: 16px;
}

.profile-share__stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    font-size: 13px;
    color: var(--profile-muted);
    text-align: center;
}

.profile-share__stats strong {
    display: block;
    margin-top: 4px;
    color: var(--profile-text);
    font-size: 16px;
}

.profile-share__builder {
    display: grid;
    gap: 12px;
}

.profile-share__label {
    font-size: 13px;
    color: var(--profile-muted);
}

.profile-share__input-group {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    align-items: center;
}

.profile-share__copy {
    border: 1px solid var(--profile-primary);
    background: var(--profile-primary);
    color: #fff;
    padding: 10px 16px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
}

.profile-share__quick {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.profile-share__social {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--profile-border);
    color: var(--profile-primary-dark);
    font-size: 13px;
    text-decoration: none;
}

.profile-assessment-card {
    background: #fff;
    border: 1px solid var(--profile-border);
    border-radius: 18px;
    padding: 20px;
    display: grid;
    gap: 16px;
    box-shadow: 0 12px 30px rgba(28, 88, 96, 0.05);
}

.profile-assessment-card--completed {
    border-color: rgba(58, 173, 184, 0.4);
}

.profile-assessment-card__icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: rgba(58, 173, 184, 0.12);
    color: var(--profile-primary-dark);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.profile-assessment-card__media {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 14px;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(58, 173, 184, 0.1), rgba(21, 99, 107, 0.12));
}

.profile-assessment-card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.profile-assessment-card__body h3 {
    margin: 0 0 6px;
    font-size: 18px;
    color: var(--profile-text);
}

.profile-assessment-card__body p {
    margin: 0 0 14px;
    font-size: 14px;
    color: var(--profile-muted);
}

.profile-assessment-card__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.profile-assessment-card__history details {
    background: rgba(58, 173, 184, 0.08);
    border-radius: 12px;
    padding: 12px 14px;
    font-size: 13px;
    color: var(--profile-text);
}

.profile-assessment-card__history ul {
    list-style: none;
    padding: 8px 0 0;
    margin: 0;
    display: grid;
    gap: 6px;
}

.profile-assessment-card__history li {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--profile-muted);
}

.profile-assessment-card__empty {
    font-size: 13px;
    color: var(--profile-muted);
}

.profile-table {
    overflow-x: auto;
    background: #fff;
    border-radius: 18px;
    border: 1px solid var(--profile-border);
}

.profile-table table {
    width: 100%;
    border-collapse: collapse;
}

.profile-table th,
.profile-table td {
    padding: 11px 16px;
    text-align: center;
    font-size: 14px;
    color: var(--profile-text);
    border-bottom: 1px solid var(--profile-border);
    white-space: nowrap;
}

.profile-table th {
    background: rgba(58, 173, 184, 0.08);
    font-weight: 700;
}

.profile-table__hint {
    font-size: 12px;
    color: var(--profile-muted);
}

.profile-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}

.profile-status--success {
    background: rgba(82, 196, 26, 0.15);
    color: #3f8c15;
}

.profile-status--warning {
    background: rgba(252, 165, 1, 0.15);
    color: #c17900;
}

.profile-search {
    display: grid;
    gap: 8px;
}

.profile-panels {
    background: var(--profile-bg);
    padding: 36px 0;
    margin-bottom: 40px;
}

.profile-panels__header {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 20px;
}

.profile-panels__header h2 {
    font-size: 22px;
    margin: 0;
    color: var(--profile-text);
}

.profile-panels__header p {
    margin: 0;
    color: var(--profile-muted);
    font-size: 14px;
}

.profile-panels__grid {
    display: grid;
    gap: 18px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.profile-panel-card {
    background: #fff;
    border-radius: 18px;
    border: 1px solid var(--profile-border);
    padding: 20px;
    display: grid;
    gap: 16px;
    box-shadow: 0 16px 32px rgba(28, 88, 96, 0.08);
}

.profile-panel-card__icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(58, 173, 184, 0.12);
    color: var(--profile-primary-dark);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.profile-panel-card__top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.profile-panel-card__top h3 {
    margin: 0;
    font-size: 17px;
    color: var(--profile-text);
}

.profile-panel-card__badge {
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
}

.profile-panel-card__badge--success {
    background: rgba(82, 196, 26, 0.15);
    color: #3f8c15;
}

.profile-panel-card__badge--warning {
    background: rgba(252, 165, 1, 0.18);
    color: #c17900;
}

.profile-panel-card__badge--danger {
    background: rgba(220, 53, 69, 0.12);
    color: #a61c2d;
}

.profile-panel-card__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.profile-panel-card__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    border-radius: 12px;
    border: 1px solid transparent;
    background: var(--profile-primary);
    color: #fff;
    font-weight: 600;
    text-decoration: none;
}

.profile-panel-card__btn--secondary {
    background: #fff;
    border-color: var(--profile-border);
    color: var(--profile-primary-dark);
}

@media (max-width: 768px) {
    .profile-hero {
        padding-top: 48px;
    }

    .profile-tabs__list {
        overflow-x: auto;
        padding: 0 12px;
    }

    .profile-main {
        padding: 32px 0 60px;
    }

    .profile-phase__header h2 {
        font-size: 20px;
    }
}

/* ══════════════════════════════════════════
   Shared Profile Page Hero (.phero)
   Unified gradient header used across all
   profile pages (dashboard, tests, security,
   finance, rewards, verification, support…).
══════════════════════════════════════════ */
.phero {
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(135deg, #1f6f78, #2c93a0);
    color: #fff;
    border-radius: 18px;
    padding: 1.3rem 1.5rem;
    box-shadow: 0 10px 26px rgba(31, 111, 120, .22);
    margin: 22px 0 20px;
}
.phero__icon {
    width: 50px;
    height: 50px;
    flex: none;
    border-radius: 14px;
    background: rgba(255, 255, 255, .18);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}
.phero__text { flex: 1; min-width: 0; }
.phero__text h1 { margin: 0 0 3px; font-size: 21px; font-weight: 800; }
.phero__text p { margin: 0; font-size: 13px; color: rgba(255, 255, 255, .85); }
.phero__state {
    font-size: 12px;
    font-weight: 800;
    padding: .4rem .8rem;
    border-radius: 999px;
    white-space: nowrap;
}
.phero__state--ok { background: #d7f5e3; color: #15724a; }
.phero__state--warn { background: #ffe1b0; color: #8a5b00; }
.phero__action {
    background: #fff;
    color: #1f6f78;
    text-decoration: none;
    font-weight: 800;
    font-size: 14px;
    padding: .6rem 1.2rem;
    border-radius: 11px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 7px;
}
.phero__action:hover { color: #15545b; }
@media (max-width: 600px) {
    .phero { flex-wrap: wrap; gap: 10px; padding: 1.1rem 1.1rem; }
    .phero__text h1 { font-size: 18px; }
}
