:root {
  --ink: #172033;
  --muted: #647089;
  --surface: #fff;
  --soft: #f5f7fc;
  --line: #dde3ef;
  --accent: #5038d8;
  --accent-dark: #3924b5;
  --teal: #0c7e78;
  --shadow: 0 18px 48px rgba(25, 37, 66, .10);
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--soft); font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif; }
a { color: inherit; }
.site-header { background: #090b10; border-bottom: 1px solid rgba(255,255,255,.1); }
.site-nav { min-height: 76px; max-width: 1240px; margin: auto; padding: 0 28px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 800; }
.brand img { display: block; width: 43px; height: 43px; object-fit: contain; filter: drop-shadow(0 0 1px rgba(255,255,255,.9)); }
.header-actions { position: relative; }
.profile-menu-toggle { display: none; width: 44px; height: 44px; padding: 9px; border: 1px solid rgba(255,255,255,.2); border-radius: 9px; background: #17191f; color: #fff; cursor: pointer; }
.profile-menu-toggle:hover { background: #24272f; }
.profile-menu-toggle:focus-visible { outline: 3px solid #8f7cff; outline-offset: 2px; }
.profile-menu-toggle svg { display: block; width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 22px; }
nav a { color: #d9deea; font-size: .94rem; font-weight: 700; text-decoration: none; }
nav a:hover, nav a.active { color: #fff; }
nav a.active { border-bottom: 2px solid #8f7cff; padding-bottom: 5px; }
.page-shell { max-width: 1120px; margin: auto; padding: 68px 28px 84px; }
.page-intro { max-width: 720px; margin-bottom: 34px; }
.page-intro.centered { margin: 0 auto 38px; text-align: center; }
.eyebrow { color: var(--accent); font-size: .76rem; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
h1, h2, p { margin-top: 0; }
h1 { margin: 8px 0 12px; font-size: clamp(2.2rem, 5vw, 3.8rem); letter-spacing: -.045em; line-height: 1; }
h2 { margin-bottom: 12px; font-size: 1.35rem; }
.page-intro p, .advisor-hero p { color: var(--muted); font-size: 1.08rem; line-height: 1.65; }
.account-layout { display: grid; grid-template-columns: minmax(260px, .78fr) minmax(0, 1.5fr); gap: 24px; }
.profile-summary { padding: 32px; border-radius: 24px; color: white; background: linear-gradient(145deg, var(--teal), var(--accent)); box-shadow: var(--shadow); }
.profile-summary .eyebrow { color: #ded7ff; }
.profile-summary h2 { font-size: 1.8rem; margin: 14px 0 10px; }
.profile-summary p:not(.eyebrow) { color: #f1efff; line-height: 1.6; }
.avatar, .advisor-avatar { display: grid; place-items: center; width: 70px; height: 70px; border-radius: 50%; color: var(--accent-dark); background: #fff; font-size: 1.2rem; font-weight: 850; }
.button { display: inline-flex; min-height: 46px; align-items: center; justify-content: center; padding: 0 18px; border: 0; border-radius: 12px; font: inherit; font-weight: 800; text-decoration: none; cursor: pointer; }
.button-primary { color: #fff; background: var(--accent); }
.button-primary:hover { background: var(--accent-dark); }
.button-light { margin-top: 14px; color: var(--accent-dark); background: #fff; }
.detail-card, .feedback-card, .application-form, .application-benefits { padding: 30px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); box-shadow: var(--shadow); }
.card-heading { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.card-heading h2 { margin: 7px 0 0; }
.status-badge { padding: 7px 10px; border-radius: 999px; color: #087252; background: #e3f8ef; font-size: .8rem; font-weight: 800; white-space: nowrap; }
.account-details { margin: 0; }
.account-details > div { display: grid; grid-template-columns: 170px 1fr; gap: 18px; padding: 20px 0; border-bottom: 1px solid var(--line); }
.account-details > div:last-child { border: 0; }
dt { color: var(--muted); font-size: .9rem; font-weight: 700; }
dd { margin: 0; font-weight: 750; }
.notice { margin-top: 20px; padding: 14px 16px; border-left: 4px solid var(--accent); border-radius: 8px; color: #4f5669; background: #f1efff; line-height: 1.5; }
.advisor-hero { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 24px; margin-bottom: 26px; padding: 34px; border-radius: 24px; color: #fff; background: linear-gradient(125deg, #14203a, #5038d8); box-shadow: var(--shadow); }
.advisor-hero .eyebrow { color: #cfc5ff; }
.advisor-hero h1 { margin: 7px 0; font-size: 2.4rem; }
.advisor-hero p { margin-bottom: 12px; color: #edf0ff; font-size: 1rem; }
.advisor-avatar { color: #fff; background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.34); }
.advisor-meta { display: flex; flex-wrap: wrap; gap: 14px; color: #e8e4ff; font-size: .9rem; font-weight: 700; }
.advisor-hero .button { color: var(--accent-dark); background: #fff; white-space: nowrap; }
.advisor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.compact > div { grid-template-columns: 105px 1fr; }
.service-list, .application-benefits ul { display: grid; gap: 14px; margin: 20px 0 0; padding: 0; list-style: none; }
.service-list li, .application-benefits li { padding-left: 27px; position: relative; line-height: 1.55; }
.service-list li::before, .application-benefits li::before { content: "✓"; position: absolute; left: 0; color: var(--teal); font-weight: 900; }
.feedback-card { display: grid; grid-template-columns: .75fr 1.25fr; gap: 38px; align-items: start; margin-top: 24px; }
.feedback-card p { color: var(--muted); line-height: 1.55; }
.feedback-form, .application-form { display: grid; gap: 18px; }
fieldset { display: flex; flex-wrap: wrap; gap: 14px 22px; margin: 0; padding: 0; border: 0; }
legend { width: 100%; margin-bottom: 8px; font-weight: 800; }
label { display: grid; gap: 8px; color: #3d475d; font-size: .93rem; font-weight: 750; }
label span { color: var(--muted); font-weight: 500; }
input, textarea { width: 100%; padding: 12px 13px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: #fff; font: inherit; }
input:focus, textarea:focus { outline: 3px solid rgba(80,56,216,.14); border-color: var(--accent); }
textarea { resize: vertical; }
.application-layout { display: grid; grid-template-columns: .72fr 1.28fr; gap: 24px; align-items: start; }
.application-benefits { color: #fff; background: linear-gradient(160deg, var(--teal), #125a88); }
.application-benefits h2 { margin-bottom: 14px; }
.application-benefits li::before { color: #b4f4e7; }
.application-benefits p { margin: 28px 0 0; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.25); color: #e0f5f3; line-height: 1.6; }
.form-heading h2 { margin: 7px 0 0; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .wide { grid-column: 1 / -1; }
.consent { display: flex; align-items: flex-start; gap: 10px; color: var(--muted); font-weight: 600; }
.consent input { width: 18px; min-height: 18px; margin-top: 2px; accent-color: var(--accent); }
.hidden { display: none !important; }
.auth-layout { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(30px, 7vw, 90px); align-items: center; min-height: 560px; }
.auth-copy h1 { max-width: 600px; }
.auth-copy > p { max-width: 560px; color: var(--muted); font-size: 1.08rem; line-height: 1.65; }
.auth-benefits { display: grid; gap: 12px; padding: 0; margin: 28px 0 0; list-style: none; color: #3d475d; font-weight: 700; }
.auth-benefits li { position: relative; padding-left: 28px; }
.auth-benefits li::before { content: "✓"; position: absolute; left: 0; color: var(--teal); }
.auth-card { padding: 30px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); box-shadow: var(--shadow); }
.narrow-page { max-width: 640px; }
.standalone-card h1 { margin-top: 8px; font-size: clamp(2rem, 5vw, 3rem); }
.standalone-card > p { color: var(--muted); line-height: 1.6; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; margin-bottom: 26px; padding: 4px; border-radius: 12px; background: var(--soft); }
.auth-tab { padding: 10px; border: 0; border-radius: 9px; color: var(--muted); background: transparent; font: inherit; font-weight: 800; cursor: pointer; }
.auth-tab.active { color: var(--accent-dark); background: #fff; box-shadow: 0 2px 8px rgba(31,40,70,.08); }
.auth-form { display: grid; gap: 16px; }
.auth-form h2 { margin: 0 0 4px; }
.forgot-password { justify-self: start; margin-top: -5px; color: var(--accent-dark); font-size: .88rem; font-weight: 800; text-decoration: none; }
.forgot-password:hover { text-decoration: underline; }
.auth-form .consent { font-size: .84rem; }
.auth-form .consent a { color: var(--accent-dark); }
.form-message { min-height: 22px; margin: 16px 0 0; font-size: .9rem; font-weight: 700; }
.form-message.error { color: #bd2639; }
.form-message.success { color: #087252; }
.profile-actions { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-top: 22px; }
.button-secondary { color: var(--accent-dark); background: #f1efff; }
.text-button { border: 0; color: var(--accent-dark); background: transparent; font: inherit; font-weight: 800; cursor: pointer; }
@media (max-width: 800px) {
  .site-nav { position: relative; min-height: 68px; padding: 12px 20px; align-items: center; }
  .brand { min-width: 0; }
  .brand span { overflow: hidden; font-size: .94rem; text-overflow: ellipsis; white-space: nowrap; }
  .header-actions { flex: 0 0 auto; margin-left: 12px; }
  .profile-menu-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .header-actions nav {
    position: absolute;
    z-index: 1000;
    top: calc(100% + 10px);
    right: 0;
    display: none;
    width: min(78vw, 270px);
    padding: 8px;
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 12px;
    background: #17191f;
    box-shadow: 0 14px 34px rgba(0,0,0,.6);
  }
  .header-actions nav.is-open { display: flex; flex-direction: column; align-items: stretch; gap: 2px; }
  .header-actions nav a { display: block; padding: 12px 14px; border-radius: 8px; font-size: .88rem; text-align: left; }
  .header-actions nav a:hover { background: #2a2d35; color: #fff; }
  .header-actions nav a.active { border-bottom: 0; background: #29233f; }
  .page-shell { padding: 45px 20px 60px; }
  .account-layout, .advisor-grid, .application-layout, .feedback-card, .auth-layout { grid-template-columns: 1fr; }
  .advisor-hero { grid-template-columns: auto 1fr; }
  .advisor-hero .button { grid-column: 1 / -1; }
  .account-details > div { grid-template-columns: 1fr; gap: 5px; }
}
@media (max-width: 500px) {
  .site-nav { gap: 12px; }
  nav { justify-content: flex-end; }
  nav a { font-size: .74rem; }
  .profile-summary, .detail-card, .feedback-card, .application-form, .application-benefits, .advisor-hero { padding: 23px; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .wide { grid-column: auto; }
}
