/* The management workspace: quieter than the cinematic public site.
   All existing data hooks and native controls are retained. */
.portal-page {
  --bg: #080a0e;
  --surface: #111721;
  --muted: #aeb9c8;
  --cyan: #a8d4ee;
  --portal-cyan: #a8d4ee;
  --line: #ffffff20;
  background: radial-gradient(ellipse at 5% 20%, #182a3a80, transparent 52%), var(--bg);
  color: #f3f5f8;
}
.portal-page :is(a, button, input, select, summary):focus-visible {
  outline: 2px solid #a8d4ee;
  outline-offset: 5px;
}
.portal-header { min-height: 88px; height: auto; padding-block: 18px; background: #080a0ecf; }
.portal-header .brand strong { letter-spacing: .12em; }
.portal-header .brand small { color: #b0bdca; }
.portal-header .brand img { border-radius: 12px; }
.portal-header-actions { flex-wrap: wrap; justify-content: flex-end; gap: 18px; }
.portal-header .text-button { min-height: 44px; display: inline-flex; align-items: center; }
.portal-main { max-width: 1320px; padding: clamp(32px, 6vw, 88px) clamp(20px, 4vw, 56px) 80px; min-height: calc(100svh - 200px); }
.auth-layout { grid-template-columns: minmax(0, 1.1fr) minmax(360px, .9fr); gap: clamp(36px, 6vw, 96px); min-height: 560px; }
.auth-intro h1 { font-size: clamp(48px, 5.9vw, 82px); line-height: 1.04; font-weight: 500; letter-spacing: -.055em; }
.auth-intro .section-kicker { text-transform: none; letter-spacing: 0; font-size: 15px; color: #a8d4ee; margin-bottom: 24px; }
.auth-intro > p:not(.section-kicker) { font-size: 18px; line-height: 1.65; max-width: 470px; }
.auth-intro .auth-help { font-size: 14px !important; max-width: 410px !important; }
.auth-points { display: grid; gap: 14px; margin: 30px 0; }
.auth-points span { padding: 0; border: 0; font-size: 14px; color: #d0dae5; }
.auth-points span::before { content: '✓'; margin-right: 12px; color: #a8d4ee; }
.auth-panel { padding: clamp(24px, 3vw, 40px); border-radius: 24px; background: linear-gradient(140deg, #1b2533, #10151d 70%); border-color: #ffffff25; box-shadow: 0 30px 90px #0005, inset 0 1px #ffffff09; }
.auth-tabs { background: #080c12; border-radius: 12px; padding: 5px; gap: 3px; }
.auth-tabs button { min-height: 48px; padding: 8px 6px; border-radius: 8px; font-size: 13px; color: #b5c0ce; }
.auth-tabs button[aria-selected="true"] { background: #d9e7f3; color: #101923; box-shadow: 0 2px 8px #0003; }
.auth-form { margin-top: 30px; }
.auth-form label, .source-dialog label { font-size: 14px; color: #e0e6ed; gap: 12px; margin-block: 22px; }
.auth-form input, .source-dialog input, .source-dialog select { min-height: 54px; border-radius: 10px; border-color: #8095ad66; background: #090f16; }
.auth-form input::placeholder { color: #8e9baa; opacity: 1; }
.auth-form [name="code"] { font-size: clamp(11px, 1.05vw, 14px); letter-spacing: 0; }
.portal-page .form-note, .portal-page .billing-note, .portal-page .section-note { color: #aeb9c8; font-size: 14px; line-height: 1.6; }
.portal-page .portal-button { min-height: 48px; border-radius: 10px; padding: 12px 18px; line-height: 1.4; text-align: center; }
.portal-page .portal-button:hover { transform: none; background: #ffffff14; }
.portal-page .portal-button.primary { background: #d9e7f3; color: #101923; border-color: #d9e7f3; }
.portal-page .portal-button.primary:hover { background: #fff; }
.portal-page .danger-button { color: #ffb4a8; border-color: #ffb4a84d; }
.portal-page button:disabled { cursor: not-allowed; }
[data-dvr-enrollment-identities] { overflow-wrap: anywhere; }
.dashboard-heading { margin-bottom: 40px; gap: 24px; }
.dashboard-heading h1 { font-size: clamp(42px, 5vw, 68px); line-height: 1.1; letter-spacing: -.045em; }
.portal-page .section-kicker, .portal-page .panel-label { color: #a8d4ee; text-transform: none; font-size: 13px; letter-spacing: 0; font-weight: 500; }
.free-pill { font-size: 11px; letter-spacing: .04em; }
.management-code-panel { border-radius: 18px; background: #14202b; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; }
.management-code { font-size: clamp(13px, 1.45vw, 18px); letter-spacing: .02em; overflow-wrap: anywhere; }
.management-grid { gap: 24px; margin-top: 24px; grid-template-columns: minmax(0, 1.45fr) minmax(280px, .85fr); }
.portal-page .portal-section { padding: clamp(22px, 2.5vw, 32px); border: 1px solid var(--line); border-radius: 18px; background: #111721; min-width: 0; }
.portal-section h2, .dialog-heading h2, .management-code-panel h2 { font-size: clamp(22px, 2.4vw, 28px); letter-spacing: -.025em; line-height: 1.2; }
.portal-section-heading { flex-wrap: wrap; gap: 16px; }
.source-row, .profile-row, .device-row { background: #0c121b; border: 0; border-radius: 12px; gap: 12px; padding: 16px 12px; }
.source-row > div, .profile-row > div, .device-row > div { min-width: 0; }
.portal-page .source-row span:not(.source-icon), .profile-row div span, .device-row div span { color: #aeb9c8; font-size: 12px; }
.portal-page :is(.profile-row, .device-row) div span { white-space: normal; overflow-wrap: anywhere; line-height: 1.5; }
.source-action { min-height: 44px; padding: 8px; color: #d6e2ee; font-size: 13px; border-radius: 6px; }
.source-action:hover { background: #ffffff12; }
.source-icon, .device-icon { background: #1d3040; color: #c4e2f5; }
.empty-state { border-style: solid; background: #0c121b; border-color: #ffffff0a; border-radius: 12px; padding: 40px 20px; }
.plan-section { position: static; }
.store-prices div { border-radius: 10px; }
.store-prices span, .account-section p:not(.panel-label) { color: #aeb9c8; font-size: 14px; }
.source-dialog { border-radius: 20px; background: #111923; max-height: calc(100dvh - 32px); }
.dialog-shell { padding: clamp(22px, 4vw, 36px); }
.dialog-heading { gap: 20px; }
.dialog-close { width: 44px; height: 44px; flex-shrink: 0; color: #e5edf5; }
.dialog-actions { flex-wrap: wrap; gap: 12px; }
.source-dialog label > span { color: #aeb9c8; }
.source-dialog .check-row input { min-height: 0; }
.portal-footer { max-width: 1320px; margin: 0 auto; padding: 24px clamp(20px, 4vw, 56px) 36px; display: flex; align-items: center; flex-wrap: wrap; gap: 20px; border-top: 1px solid var(--line); color: #aeb9c8; font-size: 13px; }
.portal-footer nav { flex-wrap: wrap; gap: 24px; }
.portal-footer a { display: inline-flex; align-items: center; min-height: 44px; color: #e0e8f0; }
@media (max-width: 960px) {
  .auth-layout { grid-template-columns: 1fr; max-width: 640px; margin: auto; gap: 36px; min-height: 0; padding: 0; }
  .auth-intro h1 { font-size: clamp(46px, 8vw, 66px); }
  .auth-intro .auth-help { margin-bottom: 0; }
  .auth-form [name="code"] { font-size: 14px; }
  .management-grid, .management-code-panel { grid-template-columns: 1fr; }
  .source-section, .profile-section, .device-section, .plan-section, .account-section { grid-column: 1; grid-row: auto; }
  .code-actions { justify-content: flex-start; }
}
@media (max-width: 600px) {
  .portal-header { padding: 12px 20px; gap: 12px; }
  .portal-header .brand img { width: 36px; height: 36px; }
  .portal-header .brand strong { font-size: 12px; }
  .portal-header .brand small { font-size: 7px; }
  .portal-header .text-button { font-size: 13px; }
  .portal-main { padding-top: 36px; }
  .auth-intro > p:not(.section-kicker) { font-size: 16px; }
  .auth-panel { padding: 22px; border-radius: 18px; }
  .auth-tabs button { font-size: 12px; }
  .auth-form [name="code"] { font-size: 11px; padding-inline: 10px; }
  .auth-points { gap: 10px; margin-block: 24px; }
  .portal-footer nav { margin-left: 0; }
  .source-row.has-dvr-policy { grid-template-columns: 44px minmax(0, 1fr); }
  .device-row, .profile-row { grid-template-columns: 40px minmax(0, 1fr) auto; gap: 8px; }
  .device-status, .auto-badge { font-size: 9px; padding: 6px; }
}
