.portal-main {
  min-height: calc(100vh - 210px);
  overflow: hidden;
  padding-bottom: 90px;
}

.portal-hero {
  position: relative;
  display: flex;
  min-height: 390px;
  align-items: center;
  justify-content: space-between;
  gap: 48px;
  padding-block: 74px 64px;
  isolation: isolate;
}

.portal-hero::before {
  position: absolute;
  z-index: -1;
  top: 0;
  right: -15%;
  width: 75%;
  height: 100%;
  background: radial-gradient(ellipse at 70% 40%, rgba(197, 243, 52, .12), transparent 62%);
  content: "";
  pointer-events: none;
}

.portal-hero-copy { max-width: 720px; }
.portal-hero-copy > .eyebrow { margin-bottom: 18px; }
.portal-title { font-size: clamp(4rem, 9vw, 7rem); line-height: .8; }
.portal-title span { display: block; color: var(--lime); }
.portal-hero-copy > p { max-width: 600px; margin: 24px 0 0; color: #b7b9ae; font-size: 1.02rem; line-height: 1.8; }
.portal-hero-mark { width: min(30vw, 300px); flex: 0 0 min(30vw, 300px); aspect-ratio: 1; }
.portal-mark-orbit { position: relative; width: 100%; height: 100%; display: grid; place-items: center; border: 1px solid rgba(197,243,52,.28); border-radius: 50%; color: var(--lime); box-shadow: inset 0 0 70px rgba(197,243,52,.035); }
.portal-mark-orbit::before, .portal-mark-orbit::after { position: absolute; inset: 12%; border: 1px solid rgba(243,242,234,.12); border-radius: 50%; content: ""; }
.portal-mark-orbit::after { inset: 25%; border-color: rgba(197,243,52,.16); }
.portal-mark-orbit > .roblox-mark { z-index: 1; width: 54px; height: 54px; flex-basis: 54px; }
.portal-mark-orbit > .roblox-mark::after { inset: 18px; background: var(--bg); }
.portal-mark-label { z-index: 1; position: absolute; display: grid; place-content: center; width: 37%; aspect-ratio: 1; border: 1px solid rgba(197,243,52,.45); border-radius: 50%; background: #141510; color: var(--lime); font-family: var(--display); font-size: 2rem; font-weight: 900; line-height: .9; text-align: center; }
.portal-mark-label small { margin-top: 6px; font-family: var(--body); font-size: .48rem; font-weight: 800; letter-spacing: .13em; }
.allowlist-hero-mark .portal-mark-orbit > svg { z-index: 1; width: 58px; height: 58px; }
.portal-hero-compact { min-height: 345px; }
.portal-hero-compact .portal-title { font-size: clamp(3.7rem, 8vw, 6.2rem); }

.portal-content { display: grid; gap: 20px; }
.portal-card { min-width: 0; padding: 30px; border: 1px solid var(--line); background: linear-gradient(135deg, rgba(255,255,255,.025), transparent 58%), var(--surface); }
.portal-card h2, .portal-card h3 { font-family: var(--display); font-weight: 800; letter-spacing: .005em; text-transform: uppercase; }
.portal-card h2 { margin: 4px 0 0; font-size: clamp(1.7rem, 3vw, 2.45rem); line-height: 1; }
.portal-card-heading { display: flex; align-items: center; gap: 16px; }
.portal-card-heading .eyebrow { margin-bottom: 7px; }
.portal-icon, .discord-icon { width: 54px; height: 54px; flex: 0 0 54px; display: grid; place-items: center; border: 1px solid rgba(197,243,52,.32); border-radius: 50%; color: var(--lime); }
.portal-icon .roblox-mark { width: 21px; height: 21px; flex-basis: 21px; }
.portal-icon .roblox-mark::after { inset: 7px; background: var(--surface); }
.portal-card > p { color: var(--muted); line-height: 1.75; }
.portal-card > p strong { color: var(--text); }
.login-card { max-width: 730px; margin: 0 auto; padding: 38px; }
.login-card > p { max-width: 600px; margin: 22px 0; }
.portal-primary-button { min-height: 54px; }
.portal-primary-button .roblox-mark { width: 16px; height: 16px; flex: 0 0 16px; transform: rotate(15deg); }
.portal-primary-button .roblox-mark::after { inset: 5px; background: var(--lime); }
.portal-primary-button:hover .roblox-mark::after { background: var(--bg); }
.verification-card { max-width: 730px; margin: 0 auto; }
.verification-card > p { line-height: 1.7; }
.verification-code-panel { display: grid; justify-items: start; gap: 14px; margin-top: 20px; padding: 20px; border: 1px solid rgba(197,243,52,.3); background: rgba(197,243,52,.05); }
.verification-code-panel > p { margin: 0; color: var(--muted); font-size: .88rem; line-height: 1.65; }
.verification-code { padding: 12px 18px; border: 1px dashed rgba(197,243,52,.55); background: #11120f; color: var(--lime); font-family: var(--body); font-size: clamp(1.4rem, 5vw, 2rem); font-weight: 800; letter-spacing: .12em; }
.verification-cancel { margin-top: 18px; border: 0; background: none; cursor: pointer; }
.portal-fine-print { margin: 15px 0 0 !important; color: #85877c !important; font-size: .78rem; line-height: 1.6 !important; }
.portal-notice { padding: 16px 19px; border: 1px solid rgba(197,243,52,.35); background: rgba(197,243,52,.07); color: var(--text); font-size: .9rem; line-height: 1.6; }
.portal-notice[data-type="error"] { border-color: rgba(255,115,115,.42); background: rgba(255,115,115,.08); }
.portal-notice[data-type="success"] { border-color: rgba(197,243,52,.45); }
[hidden] { display: none !important; }

.portal-dashboard-heading, .portal-section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.portal-section-title { margin: 8px 0 0; font-size: clamp(2.5rem, 5vw, 4rem); }
.portal-logout { min-height: 42px; }
.portal-dashboard-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 23px; }
.profile-main { display: flex; align-items: center; gap: 17px; }
.profile-avatar, .profile-avatar-fallback { width: 82px; height: 82px; flex: 0 0 82px; border: 1px solid rgba(197,243,52,.35); border-radius: 50%; background: #24261e; object-fit: cover; }
.profile-avatar-fallback { display: grid; place-items: center; }
.profile-avatar-fallback .roblox-mark { width: 28px; height: 28px; flex-basis: 28px; color: var(--lime); }
.profile-avatar-fallback .roblox-mark::after { inset: 9px; background: #24261e; }
.profile-names h3 { margin: 5px 0 2px; font-size: 1.65rem; line-height: 1; }
.profile-names p { margin: 0; color: var(--muted); font-size: .9rem; }
.profile-id-row { display: flex; justify-content: space-between; gap: 14px; margin-top: 25px; padding-top: 15px; border-top: 1px solid var(--line); color: var(--muted); font-size: .78rem; }
.profile-id-row code { color: #d3d4ca; font-family: var(--body); font-size: .78rem; }
.profile-provider-note { display: flex; align-items: center; gap: 8px; margin-top: 17px; color: #a4a69a; font-size: .78rem; }
.provider-dot, .linked-badge > span { width: 7px; height: 7px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 9px rgba(197,243,52,.5); }
.discord-card .portal-card-heading { margin-bottom: 20px; }
.discord-icon { border-color: rgba(124,137,255,.38); color: #aeb5ff; }
.discord-icon svg { width: 26px; height: 26px; }
.discord-linked-profile { display: flex; align-items: center; gap: 11px; margin: 18px 0; }
.discord-avatar, .discord-avatar-fallback { width: 42px; height: 42px; flex: 0 0 42px; border-radius: 50%; object-fit: cover; }
.discord-avatar-fallback { display: grid; place-items: center; background: #34365d; color: #dfe1ff; font-weight: 800; }
.discord-linked-profile > div { min-width: 0; display: grid; gap: 3px; }
.discord-linked-profile strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.discord-linked-profile > div > span { color: var(--muted); font-size: .8rem; }
.linked-badge { display: inline-flex; align-items: center; gap: 7px; margin-left: auto; padding: 6px 9px; border: 1px solid rgba(197,243,52,.24); color: var(--lime); font-size: .68rem; font-weight: 800; text-transform: uppercase; white-space: nowrap; }
.linked-badge > span { width: 6px; height: 6px; }
.discord-description { margin: 0 0 17px; color: var(--muted); font-size: .87rem; line-height: 1.65; }
.portal-discord-button { min-height: 43px; border-color: #6870c9; background: #6870c9; color: #fff; }
.portal-discord-button:hover { border-color: #aeb5ff; color: #c9cdff; }
.account-next-step { display: flex; align-items: center; gap: 18px; margin-top: 19px; border-color: rgba(197,243,52,.29); background: linear-gradient(105deg, rgba(197,243,52,.07), transparent 63%), var(--surface); }
.account-next-icon { width: 52px; height: 52px; flex: 0 0 52px; display: grid; place-items: center; border: 1px solid rgba(197,243,52,.32); border-radius: 50%; color: var(--lime); }
.account-next-icon svg { width: 24px; height: 24px; }
.account-next-copy { flex: 1; }
.account-next-copy h2 { margin-top: 4px; font-size: clamp(1.4rem, 3vw, 2rem); }
.account-next-copy p { margin: 8px 0 0; color: var(--muted); font-size: .85rem; line-height: 1.6; }

.account-strip { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-block: 18px; }
.account-strip-profile { display: flex; align-items: center; gap: 13px; }
.account-strip-profile > div:last-child { display: grid; gap: 4px; }
.account-strip-profile strong { font-size: .96rem; }
.account-strip-profile > div:last-child > span { color: var(--muted); font-size: .8rem; }
.account-strip-avatar, .account-strip-fallback { width: 54px; height: 54px; flex: 0 0 54px; border: 1px solid rgba(197,243,52,.35); border-radius: 50%; background: #24261e; object-fit: cover; }
.account-strip-fallback { display: grid; place-items: center; }
.account-strip-fallback .roblox-mark { width: 19px; height: 19px; flex-basis: 19px; color: var(--lime); }
.account-strip-fallback .roblox-mark::after { inset: 6px; background: #24261e; }
.text-link { color: var(--lime); font-size: .83rem; font-weight: 700; }
.text-link:hover { text-decoration: underline; text-underline-offset: 4px; }
.discord-required { display: flex; align-items: center; gap: 18px; border-color: rgba(124,137,255,.4); background: linear-gradient(110deg, rgba(104,112,201,.09), transparent 70%), var(--surface); }
.discord-required .discord-icon { width: 48px; height: 48px; flex-basis: 48px; }
.discord-required .discord-icon svg { width: 23px; height: 23px; }
.discord-required-copy { flex: 1; }
.discord-required-copy .eyebrow { margin-bottom: 5px; }
.discord-required-copy h2 { font-size: 1.7rem; }
.discord-required-copy p { margin: 6px 0 0; color: var(--muted); font-size: .83rem; line-height: 1.6; }
.applications-section, .application-form-card, .admin-panel { margin-top: 3px; }
.portal-section-heading { margin-bottom: 20px; }
.portal-section-heading h2 { margin-top: 5px; }
.section-roblox-tag { display: inline-flex; align-items: center; gap: 8px; color: #a4a69a; font-size: .68rem; font-weight: 800; letter-spacing: .1em; }
.section-roblox-tag .roblox-mark { width: 12px; height: 12px; flex: 0 0 12px; color: var(--lime); }
.section-roblox-tag .roblox-mark::after { inset: 4px; background: var(--surface); }
.application-list { display: grid; gap: 12px; }
.application-card { padding: 21px; border: 1px solid var(--line); background: rgba(0,0,0,.13); }
.application-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.application-heading h3 { margin: 0; font-size: 1.35rem; }
.application-date { margin-top: 5px; color: #85877c; font-size: .75rem; }
.status-badge { display: inline-flex; align-items: center; gap: 7px; padding: 7px 10px; border: 1px solid rgba(197,243,52,.26); color: var(--lime); font-size: .68rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; white-space: nowrap; }
.status-badge::before { width: 6px; height: 6px; border-radius: 50%; background: currentColor; content: ""; }
.status-badge[data-status="in_review"] { border-color: rgba(127,178,255,.35); color: #91b9ff; }
.status-badge[data-status="approved"] { border-color: rgba(197,243,52,.4); color: var(--lime); }
.status-badge[data-status="rejected"] { border-color: rgba(255,115,115,.4); color: #ff9292; }
.application-progress { display: grid; grid-template-columns: repeat(3, 1fr); margin: 25px 0 20px; }
.progress-step { position: relative; display: grid; justify-items: center; gap: 8px; color: #777a70; font-size: .7rem; text-align: center; }
.progress-step:not(:last-child)::after { position: absolute; top: 10px; left: calc(50% + 15px); width: calc(100% - 30px); height: 1px; background: #393b32; content: ""; }
.progress-step.is-complete:not(:last-child)::after { background: var(--lime); }
.progress-step-mark { z-index: 1; width: 21px; height: 21px; display: grid; place-items: center; border: 1px solid #47493f; border-radius: 50%; background: #181a15; font-size: .65rem; }
.progress-step.is-complete, .progress-step.is-current { color: #d3d4ca; }
.progress-step.is-complete .progress-step-mark, .progress-step.is-current .progress-step-mark { border-color: var(--lime); background: var(--lime); color: #17190f; }
.application-answer { margin-top: 15px; padding-top: 14px; border-top: 1px solid var(--line); }
.application-answer h4 { margin: 0 0 6px; color: #d9dbd1; font-size: .76rem; font-weight: 700; }
.application-answer p { margin: 0; color: var(--muted); font-size: .83rem; line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.reviewer-note { margin-top: 15px; padding: 13px 15px; border-left: 2px solid var(--lime); background: rgba(197,243,52,.055); }
.reviewer-note h4 { margin: 0 0 5px; color: var(--lime); font-size: .74rem; text-transform: uppercase; }
.reviewer-note p { margin: 0; color: #d3d4ca; font-size: .83rem; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
.application-history { display: grid; gap: 8px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.application-history h4 { margin: 0; color: #a4a69a; font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; }
.history-event { display: grid; grid-template-columns: 9px 1fr auto; align-items: start; gap: 9px; color: var(--muted); font-size: .77rem; line-height: 1.5; }
.history-event::before { width: 7px; height: 7px; margin-top: 5px; border-radius: 50%; background: var(--lime); content: ""; }
.history-event time { color: #777a70; font-size: .7rem; white-space: nowrap; }
.application-delivery-warning { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 15px; padding: 12px 14px; border: 1px solid rgba(255,146,146,.28); background: rgba(255,80,80,.05); }
.application-delivery-warning p { margin: 0; color: #ffb1b1; font-size: .78rem; line-height: 1.5; }
.application-delivery-warning .button { min-height: 38px; padding: 9px 13px; font-size: .72rem; }
.empty-applications { padding: 28px 15px; border: 1px dashed rgba(243,242,234,.17); text-align: center; }
.empty-icon { color: var(--lime); font-size: 1.5rem; }
.empty-applications h3 { margin: 9px 0 6px; font-family: var(--display); font-size: 1.4rem; text-transform: uppercase; }
.empty-applications p { max-width: 510px; margin: 0 auto; color: var(--muted); font-size: .85rem; line-height: 1.65; }
.form-intro { max-width: 780px; margin: -6px 0 23px; color: var(--muted); font-size: .86rem; line-height: 1.65; }
.form-intro a { color: var(--lime); text-decoration: underline; text-underline-offset: 3px; }
.form-required { color: #85877c; font-size: .72rem; }
.portal-field { display: grid; gap: 9px; margin-bottom: 19px; color: #e3e4dc; font-size: .86rem; font-weight: 700; }
.portal-field > span > span, .portal-checkbox > span > span { color: var(--lime); }
.portal-field input, .portal-field textarea, .admin-filter select, .admin-review-note { width: 100%; border: 1px solid rgba(243,242,234,.16); border-radius: 2px; outline: none; background: #11120f; color: var(--text); font: inherit; }
.portal-field input, .portal-field textarea { padding: 13px 14px; font-size: .88rem; font-weight: 400; line-height: 1.6; transition: border-color .2s, box-shadow .2s; }
.portal-field textarea { min-height: 120px; resize: vertical; }
.portal-field input::placeholder, .portal-field textarea::placeholder { color: #74766d; }
.portal-field input:focus, .portal-field textarea:focus, .admin-filter select:focus, .admin-review-note:focus { border-color: var(--lime); box-shadow: 0 0 0 3px rgba(197,243,52,.08); }
.portal-field small { color: #85877c; font-size: .72rem; font-weight: 400; }
.portal-checkbox { display: flex; align-items: flex-start; gap: 11px; margin: 8px 0 20px; color: #b7b9ae; font-size: .8rem; line-height: 1.65; cursor: pointer; }
.portal-checkbox input { width: 17px; height: 17px; flex: 0 0 17px; margin: 2px 0 0; accent-color: var(--lime); }
.form-actions { display: flex; align-items: center; gap: 15px; flex-wrap: wrap; }
.form-feedback { color: var(--muted); font-size: .8rem; }
.form-feedback[data-type="error"] { color: #ff9292; }
.form-feedback[data-type="success"] { color: var(--lime); }
.admin-panel { border-color: rgba(197,243,52,.3); }
.admin-filter { display: flex; align-items: center; gap: 12px; margin: 0 0 16px; color: var(--muted); font-size: .82rem; }
.admin-filter select { width: auto; min-width: 170px; padding: 9px 32px 9px 11px; }
.admin-application-list { display: grid; gap: 12px; }
.admin-application-card { padding: 20px; border: 1px solid var(--line); background: rgba(0,0,0,.16); }
.admin-app-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 15px; margin-top: 7px; color: var(--muted); font-size: .77rem; }
.admin-answers { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 15px; }
.admin-answers .application-answer { margin-top: 0; }
.admin-review-controls { display: grid; grid-template-columns: minmax(150px, .35fr) minmax(220px, 1fr) auto; align-items: end; gap: 11px; margin-top: 17px; padding-top: 15px; border-top: 1px solid var(--line); }
.admin-control { display: grid; gap: 7px; color: var(--muted); font-size: .73rem; }
.admin-review-controls select { min-height: 42px; padding: 8px 10px; border: 1px solid rgba(243,242,234,.16); background: #11120f; color: var(--text); font: inherit; }
.admin-review-note { min-height: 42px; padding: 10px; font-size: .8rem; }
.admin-review-controls .button { min-height: 42px; padding-inline: 14px; }
.admin-empty { color: var(--muted); font-size: .87rem; }

.portal-footer { border-top: 1px solid var(--line); }
.portal-footer-inner { min-height: 120px; display: flex; align-items: center; justify-content: space-between; gap: 22px; }
.portal-footer-links { display: flex; gap: 20px; color: #c7c9bf; font-size: .8rem; font-weight: 600; }
.portal-footer-links a:hover { color: var(--lime); }
.portal-footer-copy { color: #777a70; font-size: .73rem; }

@media (max-width: 760px) {
  .portal-main { padding-bottom: 60px; }
  .portal-hero { min-height: 330px; padding-block: 58px 42px; }
  .portal-hero-mark { display: none; }
  .portal-title { font-size: clamp(3.8rem, 17vw, 6rem); }
  .portal-hero-compact .portal-title { font-size: clamp(3.45rem, 15vw, 5.3rem); }
  .portal-hero-copy > p { margin-top: 18px; font-size: .93rem; }
  .portal-content { gap: 14px; }
  .portal-card { padding: 22px 18px; }
  .login-card { padding: 25px 20px; }
  .portal-dashboard-heading { align-items: flex-start; flex-direction: column; }
  .portal-dashboard-grid { grid-template-columns: 1fr; gap: 12px; margin-top: 15px; }
  .account-next-step { align-items: flex-start; flex-wrap: wrap; gap: 13px; margin-top: 15px; }
  .account-next-copy { flex-basis: calc(100% - 70px); }
  .account-next-step > .button { margin-left: 65px; }
  .account-strip { align-items: flex-start; }
  .discord-required { align-items: flex-start; flex-wrap: wrap; }
  .discord-required-copy { flex-basis: calc(100% - 70px); }
  .discord-required > .button { margin-left: 66px; }
  .portal-section-heading { align-items: flex-start; }
  .section-roblox-tag { display: none; }
  .application-card { padding: 17px 14px; }
  .admin-answers { grid-template-columns: 1fr; gap: 0; }
  .admin-review-controls { grid-template-columns: 1fr; }
  .admin-review-controls .button { width: 100%; }
  .portal-footer-inner { align-items: flex-start; flex-direction: column; justify-content: center; padding-block: 27px; }
  .portal-footer-links { flex-wrap: wrap; gap: 12px 19px; }
}

@media (prefers-reduced-motion: reduce) {
  .portal-mark-orbit { animation: none; }
}
