:root {
  color-scheme: dark;
  --bg: #05070a;
  --panel: #0f172a;
  --panel-strong: #1e293b;
  --line: #334155;
  --line-strong: #475569;
  --text: #f8fafc;
  --muted: #94a3b8;
  --accent: #ffcc33;
  --accent-strong: #ffe066;
  --teal: #33d6ff;
  --green: #22c55e;
  --danger: #ff3333;
  --input: #1e293b;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-width: 0;
  background: var(--bg);
}

body {
  margin: 0;
  min-width: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, Roboto, Arial, sans-serif;
  overflow-x: hidden;
}

button,
input,
select {
  font: inherit;
}

.page-shell {
  display: grid;
  grid-template-columns: minmax(300px, 380px) minmax(0, 1fr);
  gap: 28px;
  width: min(1480px, calc(100vw - 36px));
  margin: 0 auto;
  padding: 28px 0 50px;
}

.lynx-header {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  margin-bottom: 4px;
}

.lynx-header > div:last-child {
  min-width: 0;
}

.brand {
  color: var(--text);
  font-size: 54px;
  font-weight: 950;
  line-height: .9;
  letter-spacing: 0;
}

.divider {
  width: 5px;
  height: 46px;
  border-radius: 5px;
  background: var(--accent);
}

.subtitle {
  min-width: 0;
  color: var(--text);
  font-size: 22px;
  font-weight: 950;
  line-height: 1.05;
  overflow-wrap: normal;
  word-break: normal;
}

.header-note {
  min-width: 0;
  margin: 8px 0 0;
  color: var(--muted);
  font-size: clamp(11px, 1.2vw, 13px);
  font-weight: 800;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.overview {
  position: sticky;
  top: 18px;
  align-self: start;
  display: grid;
  gap: 22px;
  min-width: 0;
  padding: 24px;
  border: 2px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  box-shadow: 0 20px 45px rgba(0, 0, 0, .35);
}

.logo {
  display: none;
  width: min(220px, 100%);
  height: auto;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  font-size: 36px;
  line-height: .95;
  overflow-wrap: anywhere;
}

h2 {
  font-size: 24px;
  line-height: 1.1;
}

.overview-copy p:last-child {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.service-list {
  display: grid;
  gap: 10px;
}

.service-list div,
.summary-box {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.service-list span,
.summary-box span,
.summary-box small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.service-list strong,
.summary-box strong {
  font-size: 15px;
  line-height: 1.3;
}

.summary-box {
  border-color: rgba(244, 197, 66, .55);
}

.summary-box small {
  text-transform: none;
  line-height: 1.35;
}

.registration-area {
  min-width: 0;
  border: 2px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  box-shadow: 0 20px 45px rgba(0, 0, 0, .35);
  overflow: hidden;
}

.account-access-panel,
.account-session-panel {
  display: grid;
  gap: 18px;
  padding: 28px;
  border-bottom: 1px solid var(--line);
}

.account-session-panel {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.auth-form {
  gap: 0;
}

.auth-actions,
.account-actions,
.mini-actions,
.service-link-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.auth-actions {
  align-self: end;
}

.auth-actions > *,
.account-actions > *,
.mini-actions > * {
  flex: 1 1 160px;
}

.registration-gate {
  display: grid;
}

.form-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 28px 28px 24px;
  border-bottom: 1px solid var(--line);
}

.profile-summary-card {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  min-width: 0;
  margin: 18px 28px 0;
  padding: 16px;
  border: 1px solid rgba(51, 214, 255, .45);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.profile-summary-card > div {
  min-width: 0;
}

.profile-summary-card h3 {
  margin: 0;
  color: var(--text);
  font-size: 18px;
  line-height: 1.15;
}

.profile-summary-card p:last-child {
  margin: 8px 0 0;
  line-height: 1.45;
}

form {
  display: grid;
  gap: 0;
}

fieldset {
  min-width: 0;
  margin: 0;
  padding: 26px 28px;
  border: 0;
  border-bottom: 1px solid var(--line);
}

legend {
  float: left;
  width: 100%;
  margin: 0 0 14px;
  padding: 0;
  color: var(--text);
  font-size: 18px;
  font-weight: 950;
}

legend + * {
  clear: both;
}

.field-grid {
  display: grid;
  gap: 18px;
  margin-bottom: 18px;
}

.field-grid:last-child {
  margin-bottom: 0;
}

.field-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.field-grid.address {
  grid-template-columns: minmax(220px, 2fr) minmax(100px, .7fr) minmax(160px, 1fr) minmax(100px, .6fr);
}

.field-grid.compact {
  margin-top: 14px;
}

label {
  display: grid;
  gap: 9px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

input,
select {
  width: 100%;
  min-width: 0;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--input);
  color: var(--text);
  padding: 13px 14px;
  outline: none;
  font-weight: 700;
}

select {
  cursor: pointer;
}

input:focus,
select:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 2px rgba(51, 214, 255, .18);
}

input::placeholder {
  color: rgba(183, 185, 168, .62);
}

.website-code {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.plan-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.plan-option {
  cursor: pointer;
}

.plan-option > input[type="radio"] {
  position: absolute;
  width: 1px;
  min-height: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.plan-option > span {
  display: grid;
  align-content: start;
  gap: 8px;
  min-height: 218px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.plan-option > span > strong {
  color: var(--text);
  font-size: 16px;
}

.plan-option > span > small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  text-transform: none;
}

.plan-option > input[type="radio"]:checked + span {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px rgba(244, 197, 66, .45);
}

.plan-card-fields {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

.plan-field {
  display: grid;
  gap: 5px;
}

.plan-field > span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  line-height: 1.15;
  text-transform: uppercase;
}

.plan-field input {
  width: 100%;
  min-height: 42px;
  padding: 9px 10px;
  border-radius: 10px;
  font-size: 13px;
}

.plan-field input:disabled {
  opacity: .62;
  cursor: not-allowed;
  pointer-events: none;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.module-grid label,
.check-line {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
  color: var(--text);
  text-transform: none;
}

.module-grid input,
.check-line input {
  flex: 0 0 auto;
  width: 20px;
  min-height: 20px;
  height: 20px;
  accent-color: var(--accent);
}

.module-grid span,
.check-line span {
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 14px;
  font-weight: 850;
}

.check-line + .check-line {
  margin-top: 10px;
}

.submit-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 24px 28px 28px;
}

.status {
  flex: 1 1 260px;
  min-width: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
}

.status:empty {
  display: none;
}

.status.error {
  color: var(--danger);
}

.status.ok {
  color: var(--green);
}

button {
  appearance: none;
  min-height: 48px;
  border: 0;
  border-radius: 14px;
  padding: 14px 18px;
  background: var(--accent);
  color: #08111f;
  cursor: pointer;
  font-weight: 950;
}

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border-radius: 14px;
  padding: 14px 18px;
  background: var(--accent);
  color: #08111f;
  font-weight: 950;
  text-decoration: none;
}

button:hover,
.button-link:hover {
  background: var(--accent-strong);
}

.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 18px;
  background: var(--panel-strong);
  color: var(--text);
  text-align: center;
  text-decoration: none;
}

.secondary-button:hover {
  background: var(--input);
}

button:disabled {
  cursor: progress;
  opacity: .56;
}

dialog {
  width: min(520px, calc(100vw - 28px));
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  color: var(--text);
  padding: 0;
}

dialog::backdrop {
  background: rgba(0, 0, 0, .72);
}

.dialog-content {
  display: grid;
  gap: 16px;
  padding: 24px;
}

.dialog-content p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

dl div {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel-strong);
}

dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

dd {
  margin: 0;
  color: var(--teal);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 16px;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.dialog-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.dialog-actions > * {
  flex: 1 1 180px;
}

.dashboard-page {
  background: var(--bg);
}

.client-shell {
  width: min(1320px, calc(100vw - 36px));
  margin: 0 auto;
  padding: 22px 0 44px;
}

.client-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 330px);
  gap: 18px;
  align-items: end;
  margin: 18px 0;
}

.client-logo {
  display: none;
  width: min(220px, 100%);
  height: auto;
  margin-bottom: 18px;
}

.client-status-card,
.dashboard-panel {
  border: 2px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  box-shadow: 0 20px 45px rgba(0, 0, 0, .28);
}

.client-status-card {
  display: grid;
  gap: 6px;
  padding: 18px;
}

.client-status-card .mini-actions {
  margin-top: 10px;
}

.client-status-card span,
.client-status-card small,
.metric-row span,
.facts-list dt {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.client-status-card strong {
  color: var(--accent);
  font-size: 22px;
  line-height: 1.1;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, .75fr);
  gap: 14px;
  margin-bottom: 14px;
}

.dashboard-grid.lower {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.dashboard-panel {
  min-width: 0;
  padding: 18px;
}

.dashboard-panel h2 {
  font-size: 24px;
  line-height: 1.05;
}

.muted-text {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.4;
}

.error-panel {
  display: grid;
  gap: 14px;
}

.hero-panel {
  display: grid;
  align-content: start;
  gap: 24px;
}

.metric-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.metric-row div,
.facts-list div,
.module-status-grid div {
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.metric-row strong,
.facts-list dd {
  display: block;
  margin-top: 5px;
  color: var(--text);
  font-size: 16px;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.timeline-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.timeline-list article {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.timeline-list span {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  color: #08111f;
  font-weight: 950;
}

.timeline-list strong {
  display: block;
  margin-bottom: 4px;
}

.timeline-list p {
  margin: 0;
  color: var(--muted);
  line-height: 1.35;
}

.module-status-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.module-status-grid div.enabled {
  border-color: rgba(84, 209, 122, .5);
}

.module-status-grid div.disabled {
  opacity: .58;
}

.module-status-grid span,
.module-status-grid strong {
  display: block;
}

.module-status-grid span {
  color: var(--text);
  font-weight: 900;
}

.module-status-grid strong {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

.roadbook-pro-panel,
.service-wallet-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 14px;
  align-content: stretch;
}

.compact-heading {
  display: block;
}

.roadbook-pro-wallet,
.service-wallet {
  display: grid;
  gap: 10px;
  align-content: start;
  margin-top: 0;
}

.roadbook-pro-status,
.service-wallet-status {
  display: grid;
  align-content: center;
  gap: 7px;
  min-width: 0;
  min-height: 132px;
  padding: 14px;
  border: 1px solid rgba(255, 204, 51, .55);
  border-radius: 14px;
  background: rgba(30, 41, 59, .72);
}

.roadbook-pro-status.disabled,
.service-wallet-status.disabled {
  border-color: var(--line);
  opacity: .7;
}

.service-wallet-status.exhausted {
  border-color: rgba(148, 163, 184, .65);
}

.roadbook-pro-status span,
.roadbook-pro-facts span,
.service-wallet-status span,
.service-wallet-facts span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.roadbook-pro-status strong,
.service-wallet-status strong {
  color: var(--accent);
  font-size: clamp(34px, 5vw, 52px);
  font-weight: 950;
  line-height: .9;
  overflow-wrap: anywhere;
}

.service-wallet-status strong.text-value {
  font-size: clamp(28px, 3vw, 42px);
  line-height: .98;
}

.roadbook-pro-status small,
.service-wallet-status small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.35;
}

.roadbook-pro-facts,
.service-wallet-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-auto-rows: minmax(76px, auto);
  gap: 10px;
}

.roadbook-pro-facts div,
.service-wallet-facts div {
  display: grid;
  align-content: center;
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.roadbook-pro-facts strong,
.service-wallet-facts strong {
  display: block;
  margin-top: 5px;
  color: var(--text);
  font-size: 15px;
  font-weight: 950;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.facts-list {
  display: grid;
  gap: 10px;
  margin: 14px 0 0;
}

.facts-list dd {
  margin-left: 0;
}

.active-configurations-panel,
.account-services-panel {
  display: grid;
  gap: 16px;
  margin-bottom: 14px;
}

.services-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  min-width: 0;
}

#purchaseHistory {
  min-width: 0;
}

.active-services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.active-configurations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 10px;
}

.active-configuration-card {
  display: grid;
  gap: 12px;
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(255, 204, 51, .5);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.active-configuration-card.tracking {
  border-color: rgba(34, 197, 94, .58);
}

.active-configuration-card.complete {
  border-color: rgba(167, 139, 250, .58);
}

.active-configuration-card.empty {
  border-color: var(--line);
  opacity: .82;
}

.active-configuration-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.active-configuration-head span,
.active-configuration-meta span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.active-configuration-head strong {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 18px;
  font-weight: 950;
  line-height: 1.08;
  overflow-wrap: anywhere;
}

.active-configuration-head em {
  flex: 0 0 auto;
  border: 1px solid currentColor;
  border-radius: 999px;
  padding: 4px 9px;
  color: var(--green);
  font-size: 11px;
  font-style: normal;
  font-weight: 950;
  line-height: 1.1;
  text-align: center;
  text-transform: uppercase;
}

.active-configuration-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.active-configuration-meta span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 9px;
  background: rgba(15, 23, 42, .5);
}

.active-configuration-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.active-configuration-actions .service-button {
  flex: 1 1 130px;
}

.danger-service-button {
  border-color: #ff3355;
  color: #ff3355;
  background: transparent;
}

.danger-service-button:hover {
  background: rgba(255, 51, 85, .12);
}

.active-configuration-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.35;
}

.account-service-card {
  display: grid;
  align-content: start;
  gap: 10px;
  min-width: 0;
  min-height: 138px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.account-service-card.active {
  border-color: rgba(34, 197, 94, .65);
}

.account-service-card.pending {
  border-color: rgba(255, 204, 51, .6);
}

.account-service-card.exhausted {
  border-color: rgba(148, 163, 184, .65);
}

.account-service-card.disabled {
  opacity: .58;
}

.service-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.service-card-head strong {
  min-width: 0;
  color: var(--text);
  font-size: 15px;
  font-weight: 950;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.service-card-head span {
  flex: 0 0 auto;
  max-width: 128px;
  border: 1px solid currentColor;
  border-radius: 999px;
  padding: 3px 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  line-height: 1.15;
  text-align: center;
  text-transform: uppercase;
}

.account-service-card.active .service-card-head span {
  color: var(--green);
}

.account-service-card.pending .service-card-head span {
  color: var(--accent);
}

.account-service-card.exhausted .service-card-head span {
  color: var(--muted);
}

.account-service-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.account-service-card p strong {
  color: var(--text);
  font-weight: 950;
}

.services-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.service-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.service-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  max-width: 100%;
  min-height: 46px;
  border: 1px solid var(--accent);
  border-radius: 14px;
  padding: 11px 14px;
  color: var(--accent);
  font-weight: 950;
  line-height: 1.15;
  overflow: hidden;
  overflow-wrap: normal;
  text-decoration: none;
  text-overflow: ellipsis;
  white-space: nowrap;
  word-break: normal;
}

.disabled-link {
  border-color: var(--line);
  color: var(--muted);
  cursor: not-allowed;
  pointer-events: none;
}

.account-list {
  display: grid;
  gap: 14px;
}

.account-card {
  display: grid;
  gap: 14px;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.account-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.account-card-head strong {
  color: var(--text);
  font-size: 20px;
  font-weight: 950;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.account-card-head p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.35;
}

.current-subscription-banner {
  display: grid;
  gap: 14px;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .72);
}

.current-subscription-banner.active {
  border-color: rgba(34, 197, 94, .48);
}

.current-subscription-banner.pending {
  border-color: rgba(255, 204, 51, .52);
}

.subscription-dashboard-link {
  display: grid;
  gap: 14px;
  color: inherit;
  text-decoration: none;
}

.subscription-dashboard-link:hover .subscription-main strong,
.history-actions a:hover {
  color: var(--accent);
}

.subscription-main {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  min-width: 0;
}

.subscription-main strong {
  display: block;
  margin-top: 6px;
  color: var(--text);
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 950;
  line-height: 1.02;
  overflow-wrap: anywhere;
}

.subscription-main p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 15px;
  font-weight: 700;
}

.subscription-metrics {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.subscription-metrics div {
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(15, 23, 42, .55);
}

.subscription-metrics span,
.purchase-table th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.subscription-metrics strong {
  display: block;
  margin-top: 5px;
  color: var(--text);
  font-size: 15px;
  font-weight: 950;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.purchase-history-panel {
  display: grid;
  gap: 14px;
}

.new-purchase-panel {
  display: grid;
  gap: 16px;
  margin-bottom: 14px;
}

.purchase-heading .service-button {
  flex: 0 0 auto;
}

.purchase-heading-actions {
  flex: 0 1 auto;
  justify-content: flex-end;
}

.dashboard-live-button:not(.disabled-link) {
  border-color: rgba(34, 197, 94, .95);
  color: #22c55e;
  background: rgba(34, 197, 94, .12);
}

.dashboard-live-button:not(.disabled-link):hover {
  background: rgba(34, 197, 94, .2);
}

.purchase-options-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.purchase-option-card {
  display: grid;
  align-content: space-between;
  gap: 14px;
  min-width: 0;
  min-height: 205px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(30, 41, 59, .68);
}

.purchase-option-copy {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.purchase-option-copy span {
  color: var(--accent);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.purchase-option-copy strong {
  color: var(--text);
  font-size: 18px;
  font-weight: 950;
  line-height: 1.08;
  overflow-wrap: anywhere;
}

.purchase-option-copy p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.35;
}

.purchase-table-wrap {
  width: 100%;
  min-width: 0;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.purchase-table {
  width: 100%;
  min-width: 1040px;
  border-collapse: collapse;
  table-layout: fixed;
  background: rgba(15, 23, 42, .48);
}

.purchase-col-date {
  width: 10%;
}

.purchase-col-client {
  width: 11%;
}

.purchase-col-services {
  width: 16%;
}

.purchase-col-details {
  width: 25%;
}

.purchase-col-price {
  width: 10%;
}

.purchase-col-status {
  width: 9%;
}

.purchase-col-actions {
  width: 9%;
}

.purchase-table th,
.purchase-table td {
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  padding: 10px 11px;
  text-align: left;
  vertical-align: top;
}

.purchase-table th:last-child,
.purchase-table td:last-child {
  border-right: 0;
}

.purchase-table tbody tr:last-child td {
  border-bottom: 0;
}

.purchase-table tbody tr:hover {
  background: rgba(255, 204, 51, .05);
}

.purchase-table td {
  color: var(--text);
  font-size: clamp(12px, .92vw, 13px);
  font-weight: 800;
  line-height: 1.25;
  overflow-wrap: anywhere;
  word-break: normal;
}

.purchase-table td strong,
.purchase-table td small {
  display: block;
}

.purchase-table td small {
  margin-top: 5px;
  color: var(--muted);
  font-size: clamp(10.5px, .8vw, 11.5px);
  font-weight: 800;
  overflow-wrap: anywhere;
  word-break: normal;
}

.purchase-table td small:empty {
  display: none;
}

.purchase-table td strong {
  overflow-wrap: anywhere;
  word-break: normal;
}

.compact-history-cell,
.purchase-details-cell {
  white-space: normal;
}

.purchase-details-cell {
  overflow-wrap: anywhere;
}

.history-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.history-actions a,
.history-actions span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 950;
  text-decoration: none;
}

.history-actions span {
  color: var(--muted);
}

.account-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  max-width: 100%;
  min-height: 24px;
  border: 1px solid currentColor;
  border-radius: 999px;
  padding: 4px 10px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 950;
  line-height: 1.08;
  text-align: center;
  text-transform: uppercase;
  white-space: normal;
  overflow-wrap: anywhere;
}

.purchase-table td .account-pill + small {
  margin-top: 7px;
}

.account-pill.active {
  color: var(--green);
}

.account-pill.concluded {
  color: var(--muted);
}

@media (max-width: 1100px) {
  .purchase-history-panel .purchase-table-wrap {
    overflow: visible;
    border: 0;
    border-radius: 0;
  }

  .purchase-history-panel .purchase-table,
  .purchase-history-panel .purchase-table colgroup,
  .purchase-history-panel .purchase-table thead,
  .purchase-history-panel .purchase-table tbody,
  .purchase-history-panel .purchase-table tr,
  .purchase-history-panel .purchase-table td {
    display: block;
  }

  .purchase-history-panel .purchase-table {
    min-width: 0;
    background: transparent;
  }

  .purchase-history-panel .purchase-table colgroup,
  .purchase-history-panel .purchase-table thead {
    display: none;
  }

  .purchase-history-panel .purchase-table tbody {
    display: grid;
    gap: 12px;
  }

  .purchase-history-panel .purchase-table tr {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(15, 23, 42, .52);
  }

  .purchase-history-panel .purchase-table tbody tr:hover {
    background: rgba(15, 23, 42, .52);
  }

  .purchase-history-panel .purchase-table td {
    display: grid;
    grid-template-columns: minmax(112px, .34fr) minmax(0, 1fr);
    gap: 12px;
    border-right: 0;
    padding: 12px;
    font-size: 13px;
  }

  .purchase-history-panel .purchase-table td::before {
    content: attr(data-label);
    color: var(--muted);
    font-size: 11px;
    font-weight: 950;
    line-height: 1.15;
    text-transform: uppercase;
  }

  .purchase-history-panel .purchase-table td > * {
    min-width: 0;
  }

  .purchase-history-panel .history-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 520px) {
  .purchase-history-panel .purchase-table td {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .purchase-history-panel .history-actions {
    display: grid;
  }
}

.compact-metrics {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.service-link-row {
  margin-top: 2px;
}

.admin-shell {
  gap: 18px;
}

.admin-login-panel {
  max-width: 560px;
}

.admin-login-form {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.admin-login-form label {
  display: grid;
  gap: 7px;
}

.admin-login-form span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.admin-table-wrap {
  border-radius: 12px;
}

.admin-table {
  min-width: 1120px;
}

.admin-col-date {
  width: 12%;
}

.admin-col-client {
  width: 20%;
}

.admin-col-service {
  width: 20%;
}

.admin-col-billing {
  width: 17%;
}

.admin-col-status {
  width: 15%;
}

.admin-col-actions {
  width: 16%;
}

.admin-account-table {
  min-width: 1040px;
}

.admin-account-col-created {
  width: 14%;
}

.admin-account-col-email {
  width: 24%;
}

.admin-account-col-profile {
  width: 22%;
}

.admin-account-col-registrations {
  width: 13%;
}

.admin-account-col-status {
  width: 11%;
}

.admin-account-col-actions {
  width: 16%;
}

.admin-actions {
  align-items: flex-start;
  flex-direction: column;
}

.admin-actions .secondary-button {
  width: 100%;
  min-height: 38px;
  border-color: var(--accent);
  color: var(--accent);
  cursor: pointer;
  text-align: center;
}

.admin-actions .secondary-button:disabled {
  border-color: var(--line);
  color: var(--muted);
  cursor: wait;
}

.admin-actions .danger-button {
  border-color: var(--danger);
  color: var(--danger);
}

.admin-actions .danger-button:hover {
  background: rgba(255, 51, 51, 0.12);
}

@media (max-width: 980px) {
  .page-shell {
    grid-template-columns: 1fr;
  }

  .overview {
    position: static;
  }

  .service-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .plan-grid,
  .module-grid,
  .field-grid.three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .field-grid.address {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .client-header,
  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-grid.lower,
  .active-services-grid,
  .purchase-options-grid {
    grid-template-columns: 1fr;
  }

  .service-wallet-panel {
    grid-template-rows: auto auto;
  }

  .subscription-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .client-header {
    align-items: stretch;
  }
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100%, calc(100vw - 20px));
    padding: 10px 0 28px;
  }

  .lynx-header {
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
  }

  .brand {
    font-size: clamp(34px, 11vw, 46px);
  }

  .divider {
    width: 4px;
    height: 36px;
  }

  .subtitle {
    font-size: clamp(14px, 4.25vw, 19px);
    white-space: nowrap;
  }

  .header-note {
    margin-top: 5px;
    font-size: clamp(8px, 2.5vw, 11px);
  }

  .overview,
  .registration-area {
    border-radius: 8px;
  }

  .form-heading,
  .profile-summary-card,
  .submit-row {
    flex-direction: column;
    align-items: stretch;
  }

  .account-access-panel,
  .account-session-panel {
    padding: 16px;
  }

  .account-session-panel,
  .account-card-head {
    grid-template-columns: 1fr;
    display: grid;
  }

  fieldset,
  .form-heading,
  .profile-summary-card,
  .submit-row {
    padding: 16px;
  }

  .profile-summary-card {
    margin: 12px 16px 0;
  }

  h1 {
    font-size: 40px;
  }

  h2 {
    font-size: 28px;
  }

  .field-grid.two,
  .field-grid.three,
  .field-grid.address,
  .plan-grid,
  .module-grid,
  .service-list {
    grid-template-columns: 1fr;
  }

  input,
  select {
    font-size: 16px;
  }

  button,
  .secondary-button {
    width: 100%;
  }

  .button-link {
    width: 100%;
  }

  .client-shell {
    width: min(100%, calc(100vw - 20px));
    padding: 10px 0 28px;
  }

  .dashboard-panel {
    padding: clamp(14px, 4vw, 18px);
  }

  .metric-row,
  .compact-metrics,
  .module-status-grid,
  .roadbook-pro-facts,
  .service-wallet-facts,
  .active-services-grid,
  .subscription-metrics,
  .purchase-options-grid {
    grid-template-columns: 1fr;
  }

  .roadbook-pro-status,
  .service-wallet-status {
    min-height: clamp(150px, 34vw, 190px);
    padding: 16px;
  }

  .roadbook-pro-facts,
  .service-wallet-facts {
    grid-auto-rows: minmax(88px, auto);
  }

  .roadbook-pro-facts div,
  .service-wallet-facts div {
    padding: 15px;
  }

  .subscription-main {
    display: grid;
  }

  .services-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .services-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .active-configuration-head,
  .active-configuration-actions {
    display: grid;
  }

  .active-configuration-card,
  .account-service-card,
  .purchase-option-card {
    min-height: auto;
    gap: 12px;
    padding: 15px;
  }

  .service-card-head {
    display: grid;
  }

  .service-card-head span {
    justify-self: start;
    max-width: 100%;
  }

  .service-actions {
    display: grid;
  }

  .service-button {
    width: 100%;
    padding-inline: 10px;
    font-size: clamp(13px, 4vw, 15px);
  }

  .purchase-option-card {
    align-content: start;
  }
}
