/* ═══════════════════════════════════════════════════════════════════════
   LB MOBILE-WEB REDESIGN LAYER (2026-04-29)
   Light theme + Newsreader/Inter Tight typography + ember accent.
   These overrides re-skin the app to match Local Break Mobile Web mockups.
   ═══════════════════════════════════════════════════════════════════════ */

/* ── Hero card: light theme, soft border ───────────────────────── */
.top-hero-card {
  background: var(--lb-bg-raised);
  color: var(--lb-ink);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-lg);
  box-shadow: 0 1px 0 var(--lb-hairline);
  padding: 1.1rem 1rem 1rem;
}

.top-bar {
  align-items: flex-start;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
}

.top-bar-copy { gap: 0.25rem; }
.top-bar-copy .eyebrow {
  color: var(--lb-ink-60);
  font-family: var(--lb-font-mono);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.top-bar-copy h1 {
  font-family: var(--lb-font-serif);
  font-size: 1.55rem;
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--lb-ink);
}

/* ── Confidence tile (top-right): compact LB ConfidenceChip look ─ */

/* ── Local forecast title strip ───────────────────────────────── */
.rank-panel-head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 0.6rem;
}
.rank-panel-head .panel-label {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
}
.rank-panel-head .target-time {
  font-family: var(--lb-font-mono);
  font-size: 0.72rem;
  color: var(--lb-ink);
  font-weight: 500;
  letter-spacing: 0.04em;
}

/* ── Spot Score card (PaddleDial-style gauge) ─────────────────── */
.spot-check-card {
  background: var(--lb-surface);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.85rem 0.85rem 0.8rem;
  position: relative;
  overflow: hidden;
}

#rank-score-card.spot-check-card-score {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.85rem;
  padding: 0.95rem 0.95rem 0.85rem;
}
#rank-score-card .rank-gauge-shell {
  position: relative;
  inline-size: 6.6rem;
  block-size: 6.6rem;
  width: 6.6rem;
  height: 6.6rem;
  overflow: visible;
  opacity: 1;
  pointer-events: auto;
  align-self: center;
}
#rank-score-card .rank-gauge {
  width: 100%;
  height: 100%;
  overflow: visible;
}
#rank-score-card .decision-label {
  grid-column: 1 / -1;
  margin-bottom: 0.1rem;
  color: var(--lb-ember);
  font-family: var(--lb-font-mono);
  font-weight: 500;
  letter-spacing: 0.18em;
  font-size: 0.6rem;
  text-transform: uppercase;
}
#rank-score-card .spot-score-card-body {
  display: grid;
  align-content: center;
  gap: 0.6rem;
}
#rank-score-card .rank-score-copy {
  display: grid;
  gap: 0.15rem;
}
#rank-score-card .rank-verdict {
  display: block;
  font-family: var(--lb-font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 2.2rem;
  letter-spacing: -0.01em;
  color: var(--lb-ink);
  line-height: 0.95;
  margin: 0 0 0.15rem;
}
#rank-score-card .rank-value {
  font-family: var(--lb-font-sans);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1;
  color: var(--lb-ink-60);
  margin: 0;
}
#rank-score-card .rank-denom {
  color: var(--lb-ink-40);
  font-style: normal;
  font-size: 0.85rem;
  font-weight: 400;
  margin-left: 0.05rem;
}
#rank-score-card .rank-copy-below {
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink-60);
  margin: 0;
}
#rank-score-card .spot-score-temp-rail {
  display: flex;
  align-items: stretch;
  gap: 0;
  border-top: 1px solid var(--lb-hairline);
  padding-top: 0.5rem;
}
#rank-score-card .spot-score-temp-item {
  flex: 1;
  display: grid;
  gap: 0.12rem;
}
#rank-score-card .spot-score-temp-item + .spot-score-temp-item {
  border-left: 1px solid var(--lb-hairline);
  padding-left: 0.6rem;
  margin-left: 0.6rem;
}
#rank-score-card .spot-score-temp-label {
  font-family: var(--lb-font-mono);
  font-size: 0.55rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--lb-ink-40);
  text-transform: uppercase;
}
#rank-score-card .spot-score-temp-value {
  font-family: var(--lb-font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--lb-ink);
}

/* PaddleDial-style: hide arc fill, restyle ticks as ember radial */
.rank-gauge-track,
.rank-gauge-fill,
#rank-gauge-arc-segments {
  display: none;
}
.rank-gauge-ticks line {
  stroke: var(--lb-ink-20);
  stroke-width: 1.6;
  stroke-linecap: round;
}
.rank-gauge-ticks line.tick-active {
  stroke: var(--lb-ember);
  stroke-width: 1.8;
}
.rank-gauge-ticks line.tick-major {
  stroke-width: 2.4;
}

/* ── ConditionCard pattern for decision cells ─────────────────── */
.spot-check-card.decision-cell,
.spot-check-card.forecast-placeholder-card {
  background: var(--lb-surface);
  border: 1.5px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.75rem 0.8rem 0.7rem;
  display: grid;
  align-content: start;
  gap: 0.35rem;
  box-shadow: inset 0 0 0 1px transparent;
  position: relative;
  overflow: hidden;
}

.spot-check-card .decision-label {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
  margin: 0;
}

.spot-check-card .decision-value {
  font-family: var(--lb-font-serif);
  font-size: 1.85rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--lb-ink);
  text-align: left;
}
.spot-check-card .decision-subvalue {
  font-family: var(--lb-font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--lb-ink-60);
  text-align: left;
  letter-spacing: 0;
}

/* Quality color variants — applied via [data-state] from JS */
.spot-check-card[data-state="fire"],
.spot-check-card[data-state="firing"],
.spot-check-card[data-state="solid"] {
  border-color: var(--lb-fire);
  box-shadow: inset 0 0 0 1px var(--lb-fire-soft);
}
.spot-check-card[data-state="good"],
.spot-check-card[data-state="decent"],
.spot-check-card[data-state="clean"] {
  border-color: var(--lb-good);
  box-shadow: inset 0 0 0 1px var(--lb-good-soft);
}
.spot-check-card[data-state="fair"],
.spot-check-card[data-state="mediocre"],
.spot-check-card[data-state="slightly-bumpy"] {
  border-color: var(--lb-fair);
  box-shadow: inset 0 0 0 1px var(--lb-fair-soft);
}
.spot-check-card[data-state="skip"],
.spot-check-card[data-state="bumpy"],
.spot-check-card[data-state="poor"],
.spot-check-card[data-state="flat"] {
  border-color: var(--lb-bad);
  box-shadow: inset 0 0 0 1px var(--lb-bad-soft);
}

/* ── Session Planner ──────────────────────────────────────────── */
.rank-window-card.rank-window-row {
  background: var(--lb-bg-inset);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.85rem 0.85rem 0.85rem;
  margin-top: 0.7rem;
  color: var(--lb-ink);
  box-shadow: none;
}
.rank-window-card .rank-window-kicker {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
  margin: 0;
}
.rank-window-card .personal-best-window {
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink);
  font-weight: 500;
}
.session-planner-toggle {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  box-shadow: none;
}
.session-planner-toggle-btn {
  color: var(--lb-ink-60);
  font-family: var(--lb-font-sans);
  font-size: 0.7rem;
  font-weight: 600;
}
.session-planner-toggle-btn.active {
  background: var(--lb-ember);
  color: var(--lb-on-accent);
  box-shadow: none;
}
.session-planner-toggle-btn:not(.active):hover {
  background: var(--lb-ember-soft);
  color: var(--lb-ink);
}

/* ── Paddling-out CTA: pill + ember gradient ──────────────────── */
.paddling-inline {
  margin-top: 0.7rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--lb-hairline);
  display: grid;
  gap: 0.6rem;
}
.paddling-status,
.paddling-status.paddling-target {
  font-family: var(--lb-font-mono);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
}
.paddling-out-btn {
  width: 100%;
  padding: 0.95rem 1rem;
  background: linear-gradient(180deg, var(--lb-ember), var(--lb-ember-deep));
  color: var(--lb-on-accent);
  border: 0;
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  box-shadow:
    0 8px 24px var(--lb-ember-soft),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 0.06s ease;
}
.paddling-out-btn:active { transform: translateY(1px); }
.paddling-out-arrow {
  font-weight: 400;
  font-size: 1rem;
  line-height: 1;
}

.paddling-lines {
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink-60);
  display: grid;
  gap: 0.2rem;
}

/* ── Surf Journal action row ──────────────────────────────────── */
.surf-journal-actions {
  margin: 0.7rem 0;
}
.surf-journal-action-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}
.surf-journal-action-btn {
  padding: 0.7rem 0.9rem;
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid var(--lb-hairline-2);
  background: var(--lb-bg-raised);
  color: var(--lb-ink);
  transition: background 0.12s ease;
}
.surf-journal-action-btn:hover { background: var(--lb-bg-inset); }
.surf-journal-action-btn-primary {
  background: linear-gradient(180deg, var(--lb-ember), var(--lb-ember-deep));
  color: var(--lb-on-accent);
  border: 0;
  box-shadow: 0 6px 18px var(--lb-ember-soft);
}
.surf-journal-action-btn-primary:hover {
  background: linear-gradient(180deg, var(--lb-ember), var(--lb-ember-deep));
  filter: brightness(1.05);
}
.surf-journal-status {
  margin-top: 0.5rem;
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink-60);
}
.surf-journal-status[data-tone="success"],
.surf-journal-page-status[data-tone="success"] {
  display: block;
  padding: 0.78rem 0.9rem;
  border: 1px solid var(--lb-good);
  border-radius: var(--lb-rad-md);
  background: var(--lb-good-soft);
  color: var(--lb-ink);
  font-size: 0.84rem;
  font-weight: 650;
  line-height: 1.35;
  box-shadow: 0 8px 22px rgba(42, 102, 67, 0.1);
}

/* ── Eyes On It report panel ──────────────────────────────────── */
.report-panel {
  background: var(--lb-bg-inset);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.95rem 0.85rem 1rem;
  margin-top: 0.85rem;
}
.report-panel .panel-label {
  color: var(--lb-ink-60);
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: 0 0 0.6rem;
}

/* Time pills (LIVE / 30M / 1H) */
.report-observed-options {
  display: flex;
  gap: 0.4rem;
  margin-bottom: 0.6rem;
  flex-wrap: wrap;
}
.report-observed-btn {
  padding: 0.42rem 0.85rem;
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  cursor: pointer;
  background: transparent;
  color: var(--lb-ink-80);
  border: 1px solid var(--lb-hairline-2);
}
.report-observed-btn.active {
  background: var(--lb-ember);
  color: var(--lb-on-accent);
  border-color: var(--lb-ember);
}

/* Observed conditions grid */
.report-compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}
.rc-strip-item {
  background: var(--lb-bg-inset);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-sm);
  padding: 0.6rem 0.7rem;
  display: grid;
  gap: 0.25rem;
}
.rc-strip-label {
  font-family: var(--lb-font-mono);
  font-size: 0.55rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-40);
  text-transform: uppercase;
  margin: 0;
}
.rc-strip-value {
  font-family: var(--lb-font-serif);
  font-size: 1.5rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--lb-ink);
  line-height: 1;
}
.rc-strip-wind-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.rc-strip-wind-dir {
  font-family: var(--lb-font-mono);
  font-size: 0.65rem;
  color: var(--lb-ink-60);
  letter-spacing: 0.08em;
  font-weight: 600;
}

/* Calibration block — feedback grid */
.calibration-block {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.85rem;
}
.feedback-section {
  display: grid;
  gap: 0.45rem;
  position: relative;
}
.feedback-section-label {
  font-family: var(--lb-font-mono);
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ember);
  text-transform: uppercase;
}
.feedback-group p {
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink);
  margin: 0 0 0.35rem;
}
.feedback-group > div {
  display: flex;
  gap: 0.3rem;
  flex-wrap: wrap;
}
.feedback-group button {
  padding: 0.4rem 0.7rem;
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  cursor: pointer;
  background: transparent;
  color: var(--lb-ink-80);
  border: 1px solid var(--lb-hairline-2);
  transition: background 0.1s ease;
}
.feedback-group button:hover { background: var(--lb-ember-soft); }
.feedback-group button.active,
.feedback-group button[aria-pressed="true"],
.feedback-group button[data-active="true"] {
  background: var(--lb-ember);
  color: var(--lb-on-accent);
  border-color: var(--lb-ember);
}

#report-input {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border-radius: var(--lb-rad-pill);
  border: 1px solid var(--lb-hairline);
  background: var(--lb-bg-raised);
  font-family: var(--lb-font-sans);
  font-size: 0.85rem;
  color: var(--lb-ink);
  margin-top: 0.65rem;
  outline: none;
}
#report-input::placeholder { color: var(--lb-ink-40); }

.memory-strip {
  margin-top: 0.6rem;
  display: grid;
  gap: 0.15rem;
  font-family: var(--lb-font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  color: var(--lb-ink-60);
}

.feedback-status,
.identity-status,
.report-feed {
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink-60);
}

.submit-btn,
#submit-report-btn.submit-btn {
  width: 100%;
  padding: 0.85rem 1rem;
  margin-top: 0.7rem;
  border-radius: var(--lb-rad-pill);
  border: 0;
  background: linear-gradient(180deg, var(--lb-ember), var(--lb-ember-deep));
  color: var(--lb-on-accent);
  font-family: var(--lb-font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow:
    0 8px 24px var(--lb-ember-soft),
    inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

/* ── Crew/Identity panel ──────────────────────────────────────── */
.identity-panel,
.panel.identity-panel {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-lg);
  padding: 1rem;
  margin-bottom: 0.85rem;
  box-shadow: 0 1px 0 var(--lb-hairline);
  color: var(--lb-ink);
}
.identity-panel .panel-label {
  color: var(--lb-ink-80);
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.identity-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}
.identity-logout {
  background: transparent;
  border: 1px solid var(--lb-hairline-2);
  border-radius: var(--lb-rad-pill);
  color: var(--lb-ink);
  padding: 0.35rem 0.75rem;
  font-family: var(--lb-font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  cursor: pointer;
}
.identity-logout:hover {
  background: var(--lb-bg-inset);
}

.identity-hero {
  margin-bottom: 0.7rem;
}
.identity-crew-name {
  font-family: var(--lb-font-serif);
  font-size: 1.4rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--lb-ink);
}
.identity-summary {
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink-80);
  margin-top: 0.2rem;
}
.identity-break-block {
  margin-top: 0.7rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--lb-hairline);
}
.identity-break-block .panel-label {
  margin-bottom: 0.4rem;
}
.identity-break-name-form {
  display: flex; gap: 0.4rem; align-items: center;
}
.identity-break-name-input {
  flex: 1;
  font-family: var(--lb-font-serif);
  font-size: 1.2rem;
  font-weight: 400;
  background: transparent;
  border: 0;
  color: var(--lb-ink);
  outline: none;
  letter-spacing: -0.01em;
  padding: 0.2rem 0;
  border-bottom: 1px solid transparent;
  transition: border-color 0.15s ease;
}
.identity-break-name-input:focus {
  border-bottom-color: var(--lb-ember);
}
.identity-break-save-btn,
.identity-secondary-btn {
  padding: 0.5rem 0.9rem;
  background: transparent;
  border: 1px solid var(--lb-hairline-2);
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--lb-ink-80);
  cursor: pointer;
  transition: background 0.12s ease;
}
.identity-secondary-btn:hover {
  background: var(--lb-bg-inset);
}
.identity-link-btn {
  background: transparent;
  border: 0;
  color: var(--lb-ember);
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  padding: 0.3rem 0.4rem;
}
.identity-link-btn-danger {
  color: var(--lb-bad);
}
.identity-break-coords,
.identity-break-meta,
.identity-break-name-hint {
  font-family: var(--lb-font-mono);
  font-size: 0.65rem;
  color: var(--lb-ink-80);
  letter-spacing: 0.06em;
}
.identity-break-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.3rem;
}
.identity-quick-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.85rem;
}
.invite-share-copy,
.invite-private-copy {
  margin-top: 0.45rem;
}
.invite-private-copy {
  font-weight: 600;
  color: var(--lb-ink);
}
.invite-modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.identity-session-row {
  margin-top: 0.85rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--lb-hairline);
}
.identity-user-kicker {
  font-family: var(--lb-font-mono);
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
}
.identity-session-copy {
  display: flex;
  gap: 0.5rem;
  align-items: baseline;
  margin-top: 0.2rem;
}
.identity-session-copy strong {
  font-family: var(--lb-font-serif);
  font-size: 1rem;
  font-weight: 400;
  color: var(--lb-ink);
  letter-spacing: -0.01em;
}
.identity-session-copy span {
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink-80);
}

/* ── Source line + made-in copy ──────────────────────────────── */
.app-source-line {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  color: var(--lb-ink-40);
  text-transform: uppercase;
  text-align: center;
  margin: 0.85rem 0 0.4rem;
}
.app-made-in.made-in-copy {
  color: var(--lb-ink-40);
  text-align: center;
  font-family: var(--lb-font-mono);
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.18em;
}

/* ── Bottom Tab Bar (visual chrome — single-page app) ─────────── */
.lb-tab-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 3;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 0.7rem 0.5rem 1.05rem;
  background: var(--lb-bg-raised);
  border-top: 1px solid var(--lb-hairline);
  max-width: 430px;
  margin: 0 auto;
}
.lb-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.22rem;
  background: transparent;
  border: 0;
  color: var(--lb-ink-40);
  cursor: pointer;
  font-family: var(--lb-font-sans);
  font-size: 0.65rem;
  letter-spacing: 0.02em;
  padding: 0.3rem 0.45rem;
}
.lb-tab[aria-current="page"],
.lb-tab.active {
  color: var(--lb-ember);
}
.lb-tab svg { display: block; }

/* ── Auth gate light theme ───────────────────────────────────── */
.auth-gate {
  background: rgba(26, 15, 6, 0.55);
}
.auth-card {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-lg);
  color: var(--lb-ink);
}
.auth-eyebrow {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ember);
  text-transform: uppercase;
}
#auth-title {
  font-family: var(--lb-font-serif);
  font-size: 2.2rem;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--lb-ink);
  line-height: 1;
  margin-top: 0.3rem;
}
.auth-copy {
  font-family: var(--lb-font-sans);
  color: var(--lb-ink-60);
  font-size: 0.92rem;
  line-height: 1.4;
}
.auth-made-in.made-in-copy {
  color: var(--lb-ink-40);
}
.auth-submit,
.auth-home-primary {
  background: linear-gradient(180deg, var(--lb-ember), var(--lb-ember-deep));
  color: var(--lb-on-accent);
  border: 0;
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.85rem 1.1rem;
  cursor: pointer;
  box-shadow: 0 6px 18px var(--lb-ember-soft);
}
.auth-path-btn,
.auth-home-secondary {
  background: transparent;
  color: var(--lb-ink);
  border: 1px solid var(--lb-hairline-2);
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 0.78rem 1.1rem;
  cursor: pointer;
}
.auth-section-label {
  font-family: var(--lb-font-mono);
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ember);
  text-transform: uppercase;
  margin: 0 0 0.4rem;
}
.auth-helper,
.auth-gate-status {
  font-family: var(--lb-font-sans);
  font-size: 0.78rem;
  color: var(--lb-ink-60);
}
.auth-form label {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
  display: grid;
  gap: 0.3rem;
}
.auth-form input {
  font-family: var(--lb-font-sans);
  font-size: 0.95rem;
  color: var(--lb-ink);
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.7rem 0.85rem;
  outline: none;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 400;
}
.auth-form input:focus {
  border-color: var(--lb-ember);
}

/* ── Modal cards (invite/crew manage/journal) ────────────────── */
.invite-modal-card,
.crew-manage-card,
.surf-journal-page-card,
.surf-journal-chooser-card {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-lg);
  color: var(--lb-ink);
}
.invite-modal-backdrop,
.surf-journal-page-backdrop {
  background: rgba(26, 15, 6, 0.6);
}
.invite-modal-head strong,
.crew-manage-head strong,
.surf-journal-page-head strong {
  font-family: var(--lb-font-serif);
  font-size: 1.25rem;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--lb-ink);
}

/* ── Submission notification (toast) ─────────────────────────── */
.submission-notification {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  color: var(--lb-good);
  border-radius: var(--lb-rad-pill);
  box-shadow: 0 8px 24px rgba(26, 15, 6, 0.16);
}

/* ── Detail timeline strip ───────────────────────────────────── */
.timeline-wrap.rank-timeline-wrap {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.5rem 0.6rem 0.4rem;
  margin-top: 0.6rem;
}
.timeline-labels {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  color: var(--lb-ink-40);
  text-transform: uppercase;
}

/* ── Text inputs + selects (general) ─────────────────────────── */
.identity-panel input,
.identity-panel select,
.identity-control input,
.identity-control select,
.identity-control textarea {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  color: var(--lb-ink);
  font-family: var(--lb-font-sans);
  font-size: 0.92rem;
  padding: 0.55rem 0.75rem;
}

/* ── Surf journal: cards, badges, chooser, form ───────────────── */
.surf-journal-page-card,
.surf-journal-form-card {
  background: var(--lb-bg-raised);
  color: var(--lb-ink);
  border: 1px solid var(--lb-hairline);
  box-shadow: 0 12px 40px rgba(26, 15, 6, 0.10);
}
.surf-journal-page-head {
  border-bottom: 1px solid var(--lb-hairline);
}
.surf-journal-page-head strong {
  font-family: var(--lb-font-serif);
  font-weight: 400;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  color: var(--lb-ink);
}
.surf-journal-summary {
  display: grid;
  gap: 0.75rem;
}
.surf-journal-summary[hidden] {
  display: none;
}
.surf-journal-summary-section {
  display: grid;
  gap: 0.48rem;
}
.surf-journal-summary-section .surf-journal-section-label {
  margin: 0;
}
.surf-journal-summary-note {
  margin: -0.18rem 0 0;
  color: var(--lb-ink-60);
  font-size: 0.78rem;
  line-height: 1.35;
}
.surf-journal-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
}
.surf-journal-summary-item {
  display: grid;
  gap: 0.18rem;
  min-width: 0;
  padding: 0.75rem 0.65rem;
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  background: var(--lb-bg);
}
.surf-journal-summary-item strong {
  overflow: hidden;
  color: var(--lb-ink);
  font-family: var(--lb-font-serif);
  font-size: 1.12rem;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.05;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.surf-journal-summary-item span {
  color: var(--lb-ink-60);
  font-family: var(--lb-font-mono);
  font-size: 0.56rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  line-height: 1.25;
  text-transform: uppercase;
}
.surf-journal-summary-item small {
  overflow: hidden;
  color: var(--lb-ink-40);
  font-size: 0.72rem;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.surf-journal-section-label {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
}
.surf-journal-session-row {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  box-shadow: none;
  padding: 0.85rem 0.95rem;
}
.surf-journal-session-row-compact { box-shadow: none; }
.surf-journal-session-head strong {
  font-family: var(--lb-font-serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--lb-ink);
  font-size: 1rem;
}
.surf-journal-session-badge {
  font-family: var(--lb-font-mono);
  font-weight: 500;
  letter-spacing: 0.16em;
  font-size: 0.58rem;
  border-radius: var(--lb-rad-sm);
  padding: 0.22rem 0.5rem;
}
.surf-journal-session-badge-live {
  background: var(--lb-ember-soft);
  color: var(--lb-ember-deep);
}
.surf-journal-session-badge-timed_out {
  background: var(--lb-fair-soft);
  color: var(--lb-fair);
}
.surf-journal-session-badge-completed {
  background: var(--lb-good-soft);
  color: var(--lb-good);
}
.surf-journal-session-meta,
.surf-journal-session-notes {
  color: var(--lb-ink-60);
  font-size: 0.8rem;
}
.surf-journal-current-session {
  padding: 0.85rem;
  border: 1px solid rgba(232, 115, 26, 0.2);
  border-radius: var(--lb-rad-md);
  background: var(--lb-ember-soft);
}
.surf-journal-current-session .surf-journal-session-row {
  background: var(--lb-bg-raised);
}
.surf-journal-empty {
  display: grid;
  gap: 0.35rem;
  padding: 1rem;
  border: 1px dashed var(--lb-hairline-2);
  border-radius: var(--lb-rad-md);
  background: var(--lb-bg);
}
.surf-journal-empty strong {
  color: var(--lb-ink);
  font-family: var(--lb-font-serif);
  font-size: 1.05rem;
  font-weight: 400;
  letter-spacing: 0;
}
.surf-journal-empty p {
  margin: 0;
  color: var(--lb-ink-60);
  font-size: 0.86rem;
  line-height: 1.45;
}
.surf-journal-empty span {
  color: var(--lb-ember-deep);
  font-size: 0.78rem;
  font-weight: 600;
}
.surf-journal-quality-label,
.surf-journal-notes-count {
  color: var(--lb-ink-60);
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.surf-journal-quality-buttons button {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline-2);
  color: var(--lb-ink-80);
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-weight: 500;
  font-size: 0.8rem;
  padding: 0.65rem 0.4rem;
}
.surf-journal-quality-buttons button.active {
  background: var(--lb-ember);
  color: var(--lb-on-accent);
  border-color: var(--lb-ember);
}
.surf-journal-form input[type="datetime-local"],
.surf-journal-form textarea {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.6rem 0.8rem;
  font-family: var(--lb-font-sans);
  color: var(--lb-ink);
}
.surf-journal-form textarea:focus,
.surf-journal-form input[type="datetime-local"]:focus {
  border-color: var(--lb-ember);
  outline: none;
}
.surf-journal-delete-confirm {
  background: var(--lb-bad-soft);
  border: 1px solid var(--lb-bad);
  border-radius: var(--lb-rad-md);
}
.surf-journal-overlap-warning { color: var(--lb-bad); }

.submission-notification {
  background: rgba(26, 15, 6, 0.35);
}
.submission-notification-content {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-lg);
}
.submission-notification-icon {
  background: var(--lb-good-soft);
  color: var(--lb-good);
}

/* ── Settings modal ───────────────────────────────────────────── */
html.crew-manage-open,
body.crew-manage-open {
  overflow: hidden;
  overscroll-behavior: none;
}

body.crew-manage-open {
  touch-action: none;
}

.crew-manage-modal {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100dvh;
  z-index: 61;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.2rem;
  background: rgba(26, 15, 6, 0.6);
  overflow: hidden;
  overscroll-behavior: contain;
  touch-action: none;
}
.crew-manage-modal .invite-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
}
.crew-manage-card {
  position: fixed;
  z-index: 62;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(100%, 26rem);
  height: min(42rem, calc(100dvh - 2.4rem));
  max-height: calc(100dvh - 2.4rem);
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  padding: 0;
  overflow: hidden;
  background: var(--lb-bg-raised);
  color: var(--lb-ink);
  border: 1px solid var(--lb-hairline);
  box-shadow: 0 12px 40px rgba(26, 15, 6, 0.10);
}
.crew-manage-head {
  position: relative;
  top: auto;
  z-index: 2;
  margin: 0;
  padding: 1rem 1rem 0.82rem;
  border-bottom: 1px solid var(--lb-hairline);
  background: var(--lb-bg-raised);
}
.crew-manage-body {
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 0.9rem;
  padding: 0.82rem 1rem 1rem;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
}
#crew-manage-title {
  color: var(--lb-ink);
}
.crew-manage-nav {
  min-height: 0;
}
.crew-manage-nav:empty {
  display: none;
}
.crew-manage-nav:not(:has(button:not([hidden]))) {
  display: none;
}
.crew-manage-card .identity-manage-note {
  color: var(--lb-ink-80);
  font-size: 0.88rem;
  line-height: 1.45;
}
.crew-manage-card .surf-fit-summary,
.crew-manage-card .surf-preference-advanced summary,
.crew-manage-card .break-settings-hint {
  color: var(--lb-ink-60);
}
.crew-manage-card .surf-preference-advanced summary {
  font-weight: 700;
}
.crew-manage-card .surf-fit-panel {
  overflow: visible;
  padding: 0.9rem;
  border: 1px solid rgba(232, 115, 26, 0.26);
  border-radius: var(--lb-rad-md);
  background: rgba(232, 115, 26, 0.07);
}
.crew-manage-card .settings-scope-panel {
  display: grid;
  gap: 0.74rem;
  padding: 0.88rem 0.9rem;
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  background: var(--lb-bg-raised);
}
.crew-manage-card .settings-scope-panel[hidden] {
  display: none;
}
.crew-manage-card #surf-read-panel {
  border-color: rgba(100, 181, 246, 0.28);
  background: rgba(100, 181, 246, 0.08);
}
.crew-manage-card #break-details-panel {
  border-color: rgba(70, 148, 118, 0.3);
  background: rgba(70, 148, 118, 0.08);
}
.settings-scope-head,
.surf-fit-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}
.settings-scope-note {
  margin: 0.18rem 0 0;
  color: var(--lb-ink-60);
  font-size: 0.78rem;
  line-height: 1.35;
}
.break-details-summary {
  display: grid;
  gap: 0.48rem;
}
.break-details-row {
  display: grid;
  grid-template-columns: minmax(5.8rem, auto) minmax(0, 1fr);
  gap: 0.7rem;
  align-items: baseline;
  font-size: 0.84rem;
}
.break-details-row span {
  color: var(--lb-ink-60);
}
.break-details-row strong {
  min-width: 0;
  color: var(--lb-ink);
  font-weight: 800;
  overflow-wrap: anywhere;
}
.break-setup-controls {
  display: grid;
  gap: 0.62rem;
}
.crew-manage-card .surf-fit-panel::before {
  display: none;
}
.crew-manage-card .surf-fit-summary {
  margin-top: 0.28rem;
  line-height: 1.35;
}
.crew-manage-card .surf-fit-options {
  margin-top: 0.1rem;
}
.crew-manage-card .surf-preference-advanced {
  margin-top: 0.1rem;
  padding-top: 0.76rem;
  border-top: 1px solid rgba(232, 115, 26, 0.22);
}
.crew-manage-card .surf-preference-advanced[hidden] {
  display: none;
}
.crew-manage-card .surf-preference-advanced summary {
  width: fit-content;
  cursor: pointer;
}
.crew-manage-card .surf-preference-helper,
.crew-manage-card .surf-preference-source {
  color: var(--lb-ink-60);
}
.crew-manage-card .surf-preference-source {
  font-weight: 700;
}
.crew-manage-card #break-settings-panel,
.crew-manage-card #crew-manage-menu-panel {
  padding-top: 0.9rem;
  border-top: 1px solid var(--lb-hairline);
}
.crew-manage-card #break-settings-panel[hidden],
.crew-manage-card #crew-manage-menu-panel[hidden] {
  display: none;
}
.crew-manage-card .break-settings-hint {
  font-size: 0.84rem;
}
.crew-manage-card .break-settings-prior-btn {
  border-color: var(--lb-hairline);
  background: var(--lb-bg-raised);
  color: var(--lb-ink-60);
}
.crew-manage-card .break-settings-prior-btn:hover {
  background: var(--lb-bg-inset);
  color: var(--lb-ink);
}
.crew-manage-card .break-settings-prior-btn-active {
  border-color: rgba(100, 181, 246, 0.75);
  background: rgba(100, 181, 246, 0.14);
  color: #1e7bc6;
}
.crew-manage-section-label {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
}
.crew-manage-action {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  color: var(--lb-ink);
  font-family: var(--lb-font-sans);
  font-size: 0.9rem;
  border-radius: var(--lb-rad-md);
  padding: 0.7rem 0.9rem;
  text-align: left;
  cursor: pointer;
  transition: background 0.12s ease;
}
.crew-manage-action:hover { background: var(--lb-bg-inset); }
.crew-manage-action::after {
  color: var(--lb-ink-40);
}
.crew-manage-action-danger { color: var(--lb-bad); }
.invite-modal-close {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 122, 28, 0.12)),
    var(--lb-brand-paper);
  border: 2px solid var(--lb-ink);
  color: var(--lb-ink);
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-weight: 800;
  font-size: 0.72rem;
  padding: 0.35rem 0.7rem;
  cursor: pointer;
}

.crew-manage-card .invite-modal-close {
  color: var(--lb-ink);
  border-color: var(--lb-ink);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.2), rgba(255, 122, 28, 0.12)),
    var(--lb-brand-paper);
}

@media (max-width: 640px) {
  .crew-manage-modal {
    align-items: flex-end;
    padding: 0;
  }

  .crew-manage-card {
    left: 0;
    right: 0;
    top: auto;
    bottom: 0;
    transform: none;
    width: 100%;
    height: min(86dvh, 42rem);
    max-height: min(86dvh, 42rem);
    padding: 0;
    border-radius: 1.2rem 1.2rem 0 0;
    overflow: hidden;
    overscroll-behavior: contain;
    touch-action: auto;
  }

  .crew-manage-head {
    padding: 0.9rem 0.84rem 0.72rem;
  }

  .crew-manage-body {
    padding: 0.78rem 0.84rem max(1rem, env(safe-area-inset-bottom));
  }

  .crew-create {
    grid-template-columns: 1fr;
  }
}

/* ── Surf-fit edit panel ──────────────────────────────────────── */
.surf-fit-options {
  display: grid;
  gap: 0.5rem;
}
.surf-fit-summary {
  font-family: var(--lb-font-sans);
  color: var(--lb-ink);
  font-size: 0.9rem;
}
.surf-fit-nudge {
  background: var(--lb-ember-soft);
  border: 1px solid var(--lb-ember);
  border-radius: var(--lb-rad-md);
  padding: 0.85rem;
  color: var(--lb-ink);
}
.surf-fit-nudge-copy {
  font-family: var(--lb-font-sans);
  color: var(--lb-ink);
}

/* ── Auth setup (onboarding break picker) ────────────────────── */
.auth-setup-actions {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.7rem;
}
.auth-location-controls {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: end;
}
.auth-location-controls .auth-setup-select-wrap {
  display: grid;
  gap: 0.3rem;
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
}
.auth-location-controls .auth-setup-select-wrap:last-child {
  grid-column: 1 / -1;
}
.auth-location-controls select {
  width: 100%;
  font-family: var(--lb-font-sans);
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.95rem;
  padding: 0.7rem 0.85rem;
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  color: var(--lb-ink);
}
.auth-secondary-btn {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline-2);
  color: var(--lb-ink);
  border-radius: var(--lb-rad-pill);
  font-family: var(--lb-font-sans);
  font-size: 0.85rem;
  padding: 0.65rem 0.9rem;
  cursor: pointer;
}
.auth-back-btn {
  background: transparent;
  border: 0;
  color: var(--lb-ink-60);
  font-family: var(--lb-font-sans);
  font-size: 0.85rem;
  padding: 0.4rem 0;
  cursor: pointer;
}
.auth-break-list {
  display: grid;
  gap: 0.5rem;
}
.auth-map-card {
  background: var(--lb-bg-inset);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-lg);
  padding: 0.95rem;
  display: grid;
  gap: 0.5rem;
}
.auth-map-card strong {
  font-family: var(--lb-font-serif);
  font-weight: 400;
  letter-spacing: -0.01em;
  font-size: 1.15rem;
  color: var(--lb-ink);
}
.auth-map-card span {
  color: var(--lb-ink-60);
  font-family: var(--lb-font-sans);
  font-size: 0.85rem;
  line-height: 1.4;
}
.auth-setup-map {
  height: 220px;
  border-radius: var(--lb-rad-md);
  overflow: hidden;
  border: 1px solid var(--lb-hairline);
}
.auth-setup-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.7rem;
}
.auth-region-picker label {
  font-family: var(--lb-font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-60);
  text-transform: uppercase;
  display: grid;
  gap: 0.3rem;
}
.auth-region-picker select {
  font-family: var(--lb-font-sans);
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.95rem;
  padding: 0.7rem 0.85rem;
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  color: var(--lb-ink);
}
.auth-request-hero {
  background: var(--lb-ember-soft);
  border: 1px solid var(--lb-ember);
  border-radius: var(--lb-rad-md);
  padding: 0.85rem;
  margin: 0.7rem 0;
  display: grid;
  gap: 0.3rem;
}
.auth-request-hero strong {
  font-family: var(--lb-font-serif);
  font-weight: 400;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
  color: var(--lb-ink);
}
.auth-request-hero span {
  color: var(--lb-ink-80);
  font-family: var(--lb-font-sans);
  font-size: 0.85rem;
  line-height: 1.4;
}

@media (max-width: 520px) {
  .auth-location-controls {
    grid-template-columns: 1fr;
  }

  .auth-location-controls .auth-setup-select-wrap:last-child {
    grid-column: auto;
  }
}

.auth-home-cta {
  display: grid;
  gap: 0.55rem;
  margin-top: 1rem;
}

/* ── Confidence support-line restored when needed (no-display only on top-bar) */
.surf-fit-panel .surf-fit-summary {
  color: var(--lb-ink-60);
  font-family: var(--lb-font-sans);
}

/* ── Timeline (Session Planner) light-theme overrides ─────────── */
.timeline-wrap.rank-timeline-wrap .timeline-chart::before {
  background: var(--lb-bg-inset);
  border: 1px solid var(--lb-hairline);
  box-shadow: none;
}
.timeline-wrap.rank-timeline-wrap .timeline-strip::after {
  background: linear-gradient(90deg, var(--lb-hairline-2), var(--lb-hairline));
}
.timeline-wrap.rank-timeline-wrap .timeline-day-divider {
  background: linear-gradient(180deg, var(--lb-hairline-2), var(--lb-hairline));
}
.timeline-wrap.rank-timeline-wrap .timeline-day-label {
  color: var(--lb-ink-60);
  font-family: var(--lb-font-mono);
  font-weight: 500;
  letter-spacing: 0.16em;
}
.timeline-wrap.rank-timeline-wrap .timeline-bar {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 6px 14px -16px var(--timeline-bar-glow, rgba(26, 15, 6, 0.18));
}
.timeline-wrap.rank-timeline-wrap .timeline-popularity-marker::after {
  background: linear-gradient(180deg, var(--lb-ink-40), var(--lb-ink-20));
}

#hour-slider {
  width: 100%;
  margin-top: 0.4rem;
}

/* ── Score card body alignment ────────────────────────────────── */
.spot-check-card-score .rank-value {
  display: inline-flex;
  align-items: baseline;
  gap: 0.2rem;
  justify-content: flex-start;
  transform: none;
}

/* Hide the now-redundant rank-copy below the verdict word */
#rank-copy.rank-copy-below {
  display: none;
}

/* ── Score gauge svg sizing override ─────────────────────────── */
#rank-score-card .rank-gauge {
  display: block;
}

/* ── Decision/wave bumpers — make sure score bg is white ─────── */
.spot-check-card-score {
  background: var(--lb-bg-raised) !important;
  background-image: none !important;
}

/* ── Identity panel sub-elements: override dark-theme cascades ─ */
.identity-panel .panel-label,
.identity-panel .identity-summary,
.identity-panel .identity-break-meta,
.identity-panel .identity-member-status,
.identity-panel .identity-members-empty,
.identity-panel .identity-session-copy span,
.identity-panel .identity-break-name-hint,
.identity-panel .identity-control,
.identity-panel .identity-owned-crews-label,
.identity-panel .coords,
.identity-panel .feedback-status {
  color: var(--lb-ink-80);
}
.identity-panel .identity-hero,
.identity-panel .identity-session-row,
.identity-panel .identity-people,
.identity-panel .identity-utility-stack,
.identity-panel .identity-status {
  border-color: var(--lb-hairline);
}
.identity-panel input,
.identity-panel select,
.identity-panel textarea {
  background: var(--lb-bg-raised);
  border: 1px solid var(--lb-hairline);
  color: var(--lb-ink);
}
.identity-panel button {
  font-family: var(--lb-font-sans);
}
.identity-panel .identity-session-copy strong {
  color: var(--lb-ink);
}
.identity-panel .identity-user-kicker {
  color: var(--lb-ink-60);
}
.identity-panel .identity-crew-name,
.identity-panel .identity-break-name-input {
  color: var(--lb-ink);
}
.identity-panel .identity-break-name-input[readonly] {
  background: #ffffff;
  border-color: var(--lb-hairline-2);
  color: var(--lb-ink);
  opacity: 1;
}
.identity-panel .identity-logout,
.identity-panel .identity-secondary-btn {
  border-color: var(--lb-hairline-2);
  color: var(--lb-ink);
}
.identity-panel .identity-primary-btn {
  background: linear-gradient(180deg, var(--lb-ember), var(--lb-ember-deep));
  border-color: transparent;
  color: var(--lb-on-accent);
  box-shadow:
    0 8px 20px -16px var(--lb-ember-glow),
    inset 0 1px 0 rgba(255, 255, 255, 0.26);
}
.identity-panel .identity-primary-btn:hover {
  background: linear-gradient(180deg, #ff8a2f, var(--lb-ember-deep));
}
.identity-panel .identity-link-btn {
  color: var(--lb-ember-deep);
}

/* ── Force light hero card across legacy darkening rules ──────── */
.app-shell .top-hero-card {
  background: var(--lb-bg-raised);
  color: var(--lb-ink);
}
.top-hero-card * {
  /* allow text color cascade through */
}
.top-hero-card .panel-label,
.rank-window-card .rank-window-kicker,
.rank-window-card .rank-window-title,
.rank-window-card .rank-window-summary {
  color: var(--lb-ink-60) !important;
}

/* ── Mobile breakpoint tweaks ────────────────────────────────── */
@media (max-width: 460px) {
  .top-bar-copy h1 { font-size: 1.4rem; }
  #rank-score-card .rank-verdict { font-size: 1.95rem; }
  #rank-score-card .rank-value { font-size: 0.95rem; }
  .spot-check-card .decision-value { font-size: 1.6rem; }
  .lb-tab-bar { padding: 0.55rem 0.4rem 0.95rem; }
  .lb-tab span { font-size: 0.6rem; }
}

/* ═══════════════════════════════════════════════════════════════════════
   LB TODAY — mockup-faithful layout (2026-04-29)
   Mirrors `screens-today.jsx` from Claude Design handoff.
   ═══════════════════════════════════════════════════════════════════════ */

.lb-today {
  background: var(--lb-bg);
  color: var(--lb-ink);
  font-family: var(--lb-font-sans);
  padding: 0.5rem 0.4rem 0.5rem;
  margin-bottom: 0.5rem;
}

.lb-legacy-data { display: none !important; }
.lb-cta-block[hidden] { display: none !important; }

/* Compact header */
.lb-today-header {
  position: relative;
  z-index: 12;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(8rem, 16rem);
  align-items: start;
  gap: clamp(0.8rem, 3vw, 1.8rem);
  margin-bottom: 0.82rem;
  padding: clamp(0.7rem, 2.8vw, 1.35rem) 0 0.5rem;
}
.lb-today-headline {
  min-width: 0;
}
.lb-today-spot {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  gap: clamp(0.44rem, 1.3vw, 0.62rem);
  margin-top: 0;
  min-width: 0;
  max-width: 100%;
}
.lb-spot-name {
  font-family: "Satoshi", var(--lb-font-sans);
  font-size: clamp(3.15rem, 7.8vw, 5.35rem);
  font-weight: 900;
  letter-spacing: -0.045em;
  color: var(--lb-ink);
  margin: 0;
  line-height: 0.86;
  max-width: 100%;
  overflow: visible;
  overflow-wrap: anywhere;
  white-space: normal;
}
.lb-spot-coords {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  margin: 0;
  color: var(--lb-ember);
  font-family: "Satoshi", var(--lb-font-sans);
  font-size: clamp(1.05rem, 2.8vw, 1.35rem);
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.1;
}
.lb-spot-coords[hidden] {
  display: none;
}
.lb-spot-coords::before {
  content: "";
  width: 0.72em;
  height: 0.72em;
  flex: 0 0 auto;
  border-radius: 50% 50% 50% 0;
  background:
    radial-gradient(circle at 50% 50%, var(--lb-bg) 0 22%, transparent 24%),
    var(--lb-ember);
  transform: rotate(-45deg);
}
@media (max-width: 560px) {
  .lb-today-header {
    grid-template-columns: minmax(0, 1fr) minmax(7.75rem, 8.5rem);
    gap: 0.72rem;
    padding-top: 0.6rem;
  }

  .lb-confidence-chip {
    min-width: 0;
  }

  .lb-spot-name {
    font-size: clamp(2.55rem, 11.4vw, 3.35rem);
    line-height: 0.9;
  }

  .lb-spot-coords {
    font-size: clamp(0.9rem, 4vw, 1.1rem);
    gap: 0.34rem;
  }
}

@media (max-width: 340px) {
  .lb-today-header {
    grid-template-columns: 1fr;
  }
}
.lb-eyebrow {
  font-family: var(--lb-font-mono);
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: 0;
}
.lb-eyebrow-mute  { color: var(--lb-ink-40); }
.lb-eyebrow-ember { color: var(--lb-ember); }

/* Confidence chip */
.lb-confidence-wrap {
  position: relative;
  flex: 0 0 auto;
}

.lb-today-header .lb-confidence-wrap {
  display: flex;
  align-self: stretch;
  min-width: 0;
  padding-left: clamp(0.72rem, 2.4vw, 1.35rem);
  border-left: 1px solid var(--lb-hairline);
}

.lb-confidence-chip {
  position: relative;
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid rgba(106, 131, 143, 0.16);
  border-radius: 10px;
  padding: 0.52rem 0.58rem 0.6rem;
  text-align: right;
  display: grid;
  gap: 0.22rem;
  align-content: start;
  cursor: pointer;
  font-family: var(--lb-font-sans);
  min-width: 7.5rem;
  box-shadow:
    0 8px 18px rgba(55, 79, 91, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.54);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}
.lb-today-header .lb-confidence-chip {
  width: 100%;
  min-width: 0;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0.1rem 0 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  text-align: left;
}
.lb-confidence-chip:hover,
.lb-confidence-chip:focus-visible,
.lb-confidence-chip[aria-expanded="true"] {
  border-color: rgba(232, 115, 26, 0.34);
  box-shadow:
    0 10px 22px rgba(55, 79, 91, 0.09),
    0 0 0 3px rgba(232, 115, 26, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.64);
}
.lb-today-header .lb-confidence-chip:hover,
.lb-today-header .lb-confidence-chip:focus-visible,
.lb-today-header .lb-confidence-chip[aria-expanded="true"] {
  box-shadow: none;
}
.lb-confidence-chip:active {
  transform: translateY(1px);
}
.lb-confidence-kicker {
  font-family: var(--lb-font-mono);
  font-size: 0.69rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  color: var(--lb-ink-40);
  text-transform: uppercase;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.3rem;
  text-align: right;
}
.lb-today-header .lb-confidence-kicker {
  justify-content: flex-start;
  text-align: left;
  margin-bottom: 0.3rem;
}
.lb-confidence-kicker .confidence-kicker {
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  color: inherit;
  text-transform: inherit;
  margin: 0;
}
.lb-confidence-cue {
  display: inline-grid;
  place-items: center;
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background: rgba(232, 115, 26, 0.13);
  color: var(--lb-ember);
  font-family: var(--lb-font-sans);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1;
}
.lb-confidence-metrics {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 0.4rem;
}
.lb-today-header .lb-confidence-metrics {
  justify-content: flex-start;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.42rem;
  margin-bottom: 0.18rem;
}
.lb-confidence-chip .confidence-level {
  font-family: var(--lb-font-sans);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--lb-ink);
  letter-spacing: 0;
  margin: 0;
}
.lb-today-header .lb-confidence-chip .confidence-level {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--lb-great);
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.lb-model-trend {
  display: none;
  align-items: center;
  padding: 0.1rem 0.46rem;
  border: 1px solid var(--lb-great);
  border-radius: var(--lb-rad-pill);
  font-size: 0.58rem;
  font-weight: 600;
  color: var(--lb-great);
  letter-spacing: 0.01em;
  line-height: 1.5;
}
.lb-today-header .lb-confidence-chip:not([data-state="fresh"]) .lb-model-trend {
  display: inline-flex;
}
.lb-confidence-percent {
  font-family: var(--lb-font-serif);
  font-size: 1.38rem;
  font-weight: 400;
  color: var(--lb-ember);
  letter-spacing: -0.02em;
  line-height: 1;
}
.lb-today-header .lb-confidence-percent {
  font-family: "Satoshi", var(--lb-font-sans);
  font-size: clamp(1.9rem, 4.8vw, 2.5rem);
  font-weight: 900;
  color: var(--lb-great);
  letter-spacing: -0.04em;
  line-height: 1;
  margin-bottom: 0.1rem;
}
.lb-confidence-pct-suffix {
  font-family: var(--lb-font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  margin-left: 1px;
}
.lb-today-header .lb-confidence-pct-suffix {
  font-size: 0.48em;
  font-weight: 700;
}
.lb-confidence-chip .confidence-support {
  display: none;
}
.lb-today-header .lb-confidence-chip .confidence-support {
  display: block;
  font-size: 0.63rem;
  color: var(--lb-ink-60);
  line-height: 1.3;
  margin-bottom: 0.28rem;
}
.lb-confidence-track {
  position: relative;
  display: block;
  height: 4px;
  width: 6.9rem;
  margin-left: auto;
  background: var(--lb-ink-20);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 0.32rem;
}
.lb-today-header .lb-confidence-track {
  width: 100%;
  margin-left: 0;
  margin-top: 0;
}
.lb-confidence-track .confidence-progress-fill {
  position: absolute;
  inset: 0 auto 0 0;
  background: var(--lb-ember);
  border-radius: 2px;
  height: 100%;
}
.lb-today-header .lb-confidence-track .confidence-progress-fill {
  background: var(--lb-great);
}
.lb-confidence-hidden { display: none; }

.lb-confidence-popout {
  position: absolute;
  top: calc(100% + 0.48rem);
  right: 0;
  z-index: 20;
  width: min(18rem, calc(100vw - 1.5rem));
  padding: 0.74rem;
  border: 1px solid rgba(106, 131, 143, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.98);
  color: var(--lb-ink);
  box-shadow: 0 18px 38px rgba(43, 63, 75, 0.18);
}

.lb-confidence-popout::before {
  content: "";
  position: absolute;
  top: -0.36rem;
  right: 1.1rem;
  width: 0.7rem;
  height: 0.7rem;
  border-left: 1px solid rgba(106, 131, 143, 0.16);
  border-top: 1px solid rgba(106, 131, 143, 0.16);
  background: rgba(255, 255, 255, 0.98);
  transform: rotate(45deg);
}

.lb-confidence-popout-head,
.lb-confidence-popout-steps {
  display: grid;
  gap: 0.42rem;
}

.lb-confidence-popout-head {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.lb-confidence-popout-head strong {
  font-family: var(--lb-font-serif);
  font-size: 1.08rem;
  font-weight: 500;
  line-height: 1;
}

.lb-confidence-popout-head span {
  padding: 0.18rem 0.4rem;
  border-radius: 999px;
  background: rgba(232, 115, 26, 0.12);
  color: var(--lb-ember);
  font-size: 0.62rem;
  font-weight: 800;
  line-height: 1;
}

.lb-confidence-popout p {
  margin: 0.48rem 0 0;
  color: var(--lb-ink-70);
  font-size: 0.78rem;
  font-weight: 520;
  line-height: 1.28;
}

.lb-confidence-popout-steps {
  margin-top: 0.62rem;
}

.lb-confidence-popout-steps span {
  padding: 0.44rem 0.5rem;
  border-radius: 7px;
  background: rgba(236, 244, 247, 0.78);
  color: var(--lb-ink-80);
  font-size: 0.74rem;
  line-height: 1.25;
}

.lb-confidence-popout-steps strong {
  color: var(--lb-ink);
}

#confidence-popout-next {
  color: var(--lb-ink);
  font-weight: 760;
}

#confidence-popout-meta {
  margin-top: 0.24rem;
  color: var(--lb-ink-60);
}

.surf-map-view-row {
  display: flex;
  align-items: center;
  gap: 0.62rem;
  min-width: 0;
  margin: 0 0 0.72rem;
}

.surf-map-view-helper {
  min-width: 0;
  margin: 0;
  color: var(--lb-ink-60);
  font-family: var(--lb-font-sans);
  font-size: 0.82rem;
  font-weight: 500;
  line-height: 1.2;
}

.surf-map-view-helper strong {
  color: var(--lb-ember);
  font-weight: 650;
}

.surf-map-view-row .lb-spark-toggle {
  flex: 0 0 auto;
  margin: 0;
  padding: 0.16rem;
  border-color: rgba(35, 22, 10, 0.12);
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 8px 22px rgba(35, 22, 10, 0.06);
}

.surf-map-view-row .lb-spark-toggle .session-planner-toggle-btn {
  min-width: 3.2rem;
  padding: 0.44rem 0.76rem;
  font-size: 0.78rem;
}

/* Score + verdict */
.lb-dial-row {
  display: none;
  align-items: baseline;
  gap: clamp(0.65rem, 4vw, 1.2rem);
  margin: 0.15rem 0 0.95rem;
  min-width: 0;
  white-space: nowrap;
}
.lb-dial-card {
  width: auto;
  height: auto;
  flex: 0 0 auto;
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  line-height: 0.9;
}
.lb-dial-card #rank-number,
.lb-score-number {
  display: block;
  font-family: var(--lb-font-serif);
  font-size: clamp(3rem, 18vw, 5.25rem);
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.025em;
  color: var(--score-accent, var(--lb-ink));
  line-height: 0.84;
}
.lb-verdict-block {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: baseline;
}
.lb-verdict {
  display: block;
  font-family: var(--lb-font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(2.05rem, 11vw, 4.05rem);
  letter-spacing: -0.01em;
  color: var(--lb-ink);
  line-height: 0.95;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 2x2 ConditionCard grid */
.lb-condition-grid {
  display: none;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
  margin-bottom: 0.85rem;
}
.lb-condition-card {
  background: var(--lb-surface);
  border: 1.5px solid var(--lb-hairline);
  border-radius: var(--lb-rad-md);
  padding: 0.7rem 0.75rem 0.6rem;
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 0.4rem;
  align-content: start;
  box-shadow: inset 0 0 0 1px transparent;
}
.lb-condition-card[data-quality="great"] {
  border-color: var(--lb-great);
  box-shadow: inset 0 0 0 1px var(--lb-great-soft);
}
.lb-condition-card[data-quality="fire"] {
  border-color: var(--lb-fire);
  box-shadow: inset 0 0 0 1px var(--lb-fire-soft);
}
.lb-condition-card[data-quality="good"] {
  border-color: var(--lb-good);
  box-shadow: inset 0 0 0 1px var(--lb-good-soft);
}
.lb-condition-card[data-quality="fair"] {
  border-color: var(--lb-fair);
  box-shadow: inset 0 0 0 1px var(--lb-fair-soft);
}
.lb-condition-card[data-quality="bad"],
.lb-condition-card[data-quality="skip"] {
  border-color: var(--lb-bad);
  box-shadow: inset 0 0 0 1px var(--lb-bad-soft);
}
.lb-condition-card::after {
  content: "";
  position: absolute;
  top: 0; right: 0;
  width: 60px; height: 60px;
  background: radial-gradient(circle at 100% 0%, var(--lb-cc-glow, transparent), transparent 70%);
  pointer-events: none;
}
.lb-condition-card[data-quality="great"] { --lb-cc-glow: var(--lb-great-soft); }
.lb-condition-card[data-quality="fire"] { --lb-cc-glow: var(--lb-fire-soft); }
.lb-condition-card[data-quality="good"] { --lb-cc-glow: var(--lb-good-soft); }
.lb-condition-card[data-quality="fair"] { --lb-cc-glow: var(--lb-fair-soft); }
.lb-condition-card[data-quality="bad"]  { --lb-cc-glow: var(--lb-bad-soft); }
