:root {
  --blue: #003883;
  --blue-dark: #002b66;
  --yellow: #fed700;
  --ink: #17202a;
  --muted: #667085;
  --line: #dfe5ec;
  --bg: #f6f8fb;
  --card: #ffffff;
  --success: #137a4a;
  --shadow: 0 10px 30px rgba(12, 30, 57, .08);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
.hidden { display: none !important; }
.shell { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }

.site-header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
.header-inner { min-height: 86px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-logo { width: 66px; height: 66px; object-fit: contain; flex: 0 0 auto; }
.brand-copy { min-width: 0; }
.brand strong { display: block; color: var(--blue); letter-spacing: .02em; font-size: 18px; }
.brand small { display: block; color: var(--muted); margin-top: 2px; }
.account-area { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 14px; }

.auth-layout { min-height: calc(100vh - 154px); display: grid; grid-template-columns: 1.2fr .8fr; gap: 64px; align-items: center; padding: 70px 0; }
.hero-copy h1 { font-size: clamp(42px, 6vw, 68px); line-height: .98; max-width: 760px; margin: 10px 0 24px; letter-spacing: -.045em; }
.lead { font-size: 20px; line-height: 1.55; color: #475467; max-width: 720px; }
.eyebrow { color: var(--blue); font-size: 12px; font-weight: 900; letter-spacing: .13em; margin: 0; }
.eyebrow.light { color: #dbe7ff; }
.trust-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.trust-row span { background: #fff; border: 1px solid var(--line); padding: 8px 12px; border-radius: 999px; font-size: 13px; font-weight: 700; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); }
.login-card { padding: 30px; }
.login-card h2, .modal h2, .empty-state h2 { margin: 8px 0 10px; font-size: 28px; }
.muted { color: var(--muted); line-height: 1.55; }
label { display: block; font-weight: 750; font-size: 14px; margin: 18px 0 7px; }
input, select, textarea { width: 100%; border: 1px solid #cfd8e3; border-radius: 10px; background: #fff; padding: 12px 13px; color: var(--ink); outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0,56,131,.11); }
textarea { resize: vertical; }

.recording-guide { margin-top: 20px; padding: 16px 17px; border: 1px solid #cbd9ed; border-left: 5px solid var(--yellow); border-radius: 12px; background: #f7faff; }
.recording-guide h3 { margin: 7px 0 7px; color: var(--blue); font-size: 19px; }
.recording-guide > p:not(.eyebrow) { margin: 0; line-height: 1.5; color: #475467; }
.recording-guide ul { margin: 10px 0 0; padding-left: 20px; color: #344054; }
.recording-guide li { margin: 5px 0; line-height: 1.45; }
.recording-guide .recording-reassurance { margin-top: 12px; padding-top: 11px; border-top: 1px solid #dce5f1; font-size: 13px; color: var(--muted); }

.consent-check { display: flex; gap: 10px; align-items: flex-start; margin-top: 20px; padding: 13px 14px; border: 1px solid #d8e0ea; border-radius: 11px; background: #f8fafc; font-weight: 650; line-height: 1.45; cursor: pointer; }
.consent-check input { width: 18px; height: 18px; margin: 2px 0 0; padding: 0; flex: 0 0 auto; accent-color: var(--blue); }
.consent-check span { display: block; }
.consent-note { margin: 8px 2px 0; color: var(--muted); font-size: 12px; line-height: 1.45; }

.button { border: 0; border-radius: 10px; padding: 11px 15px; font-weight: 850; transition: .15s ease; }
.button:hover { transform: translateY(-1px); }
.button-primary { background: var(--blue); color: #fff; }
.button-primary:hover { background: var(--blue-dark); }
.button-yellow { background: var(--yellow); color: #17202a; }
.button-ghost { background: #fff; color: var(--blue); border: 1px solid #cbd5e1; }
.full { width: 100%; margin-top: 16px; }
.form-message { min-height: 22px; margin: 10px 0 0; color: var(--muted); font-size: 14px; }
.form-message.error { color: #b42318; }
.form-message.success { color: var(--success); }

.portal-hero { background: var(--blue); color: #fff; }
.portal-hero-inner { min-height: 210px; padding: 44px 0; display: flex; align-items: end; justify-content: space-between; gap: 24px; }
.portal-hero h1 { margin: 7px 0 8px; font-size: 44px; }
.portal-hero p:not(.eyebrow) { margin: 0; color: #dbe7ff; }
.portal-body { padding: 32px 0 70px; }
.players-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 18px; }
.player-card { padding: 22px; }
.player-top { display: flex; justify-content: space-between; gap: 14px; align-items: start; }
.player-name { font-size: 24px; margin: 0 0 5px; }
.player-ref { font-size: 12px; color: var(--muted); font-weight: 800; }
.player-meta { color: var(--muted); margin-top: 12px; font-size: 14px; }
.player-stats { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; margin: 18px 0; }
.stat { background: #f8fafc; border: 1px solid #edf1f5; padding: 12px; border-radius: 11px; }
.stat small { display: block; color: var(--muted); font-weight: 750; margin-bottom: 4px; }
.stat strong { display: block; line-height: 1.3; }
.player-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.empty-state, .loading-card { text-align: center; padding: 46px; }
.loading-card { color: var(--muted); }
.notice { border-radius: 12px; padding: 13px 15px; margin-bottom: 20px; background: #eef6ff; color: var(--blue); border: 1px solid #d6e9ff; }
.status-pill { display: inline-block; border-radius: 999px; padding: 5px 9px; font-size: 11px; font-weight: 900; background: #eef3f8; color: #475467; }

.modal { width: min(680px, calc(100% - 28px)); border: 0; border-radius: 18px; padding: 0; box-shadow: 0 28px 70px rgba(11,29,53,.22); }
.modal::backdrop { background: rgba(13,25,42,.55); }
.modal form, .modal > div:not(.modal-head) { padding: 26px; }
.modal form .modal-head { margin: -2px 0 6px; }
.modal-head { display: flex; align-items: start; justify-content: space-between; gap: 20px; }
.icon-button { border: 0; background: #f4f6f8; width: 36px; height: 36px; border-radius: 50%; font-size: 24px; color: var(--muted); }
.form-grid { display: grid; gap: 14px; }
.form-grid.two { grid-template-columns: repeat(2,1fr); }
.form-grid.three { grid-template-columns: repeat(3,1fr); }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
.info-box { margin-top: 20px; border-radius: 11px; background: #fff9d9; border: 1px solid #f8e77b; padding: 13px; line-height: 1.45; }
.modal-wide { width: min(860px, calc(100% - 28px)); padding: 26px; }
.profile-summary { display: flex; justify-content: space-between; gap: 20px; padding: 18px; background: #f8fafc; border-radius: 12px; margin: 18px 0 24px; }
.timeline { display: grid; gap: 12px; }
.timeline-item { border-left: 4px solid var(--yellow); padding: 14px 16px; background: #fff; border-radius: 0 11px 11px 0; border-top: 1px solid var(--line); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.timeline-item h4 { margin: 0 0 7px; }
.timeline-item p { margin: 4px 0; color: #475467; }

footer { border-top: 1px solid var(--line); color: var(--muted); padding: 24px 0; font-size: 13px; background: #fff; }

@media (max-width: 820px) {
  .auth-layout { grid-template-columns: 1fr; gap: 30px; padding: 40px 0; }
  .hero-copy h1 { font-size: 46px; }
  .players-grid { grid-template-columns: 1fr; }
  .portal-hero-inner { align-items: start; flex-direction: column; min-height: auto; }
  .form-grid.two, .form-grid.three { grid-template-columns: 1fr; }
  .profile-summary { flex-direction: column; }
}

@media (max-width: 520px) {
  .account-area span { display: none; }
  .brand-logo { width: 56px; height: 56px; }
  .brand strong { font-size: 16px; }
  .brand small { font-size: 12px; }
  .hero-copy h1 { font-size: 38px; }
  .login-card { padding: 22px; }
  .player-stats { grid-template-columns: 1fr; }
  .player-actions .button { flex: 1; }
}