:root {
  color-scheme: light;
  --page: oklch(96.7% 0.011 87);
  --paper: oklch(99% 0.006 87);
  --ink: oklch(29% 0.025 156);
  --muted: oklch(53% 0.02 135);
  --line: oklch(88.5% 0.017 92);
  --accent: oklch(44% 0.065 157);
  --soft: oklch(92.5% 0.022 130);
  --forest: #5d8060;
  --wool: #a5b97b;
  --grain: #dfbc69;
  --brick: #bd8264;
  --ore: #93a19b;
  --desert: #d6c7a0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
* {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
}
button,
input {
  font: inherit;
}
button,
a,
input,
summary {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  color: inherit;
  touch-action: manipulation;
}
button,
a {
  transition:
    background 0.18s,
    color 0.18s,
    opacity 0.18s;
}
button:active {
  opacity: 0.72;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 3px solid #b99253;
  outline-offset: 4px;
}
.app-view:focus {
  outline: none;
}
a {
  color: inherit;
}
button {
  border: 0;
}
h1,
h2,
p {
  margin-top: 0;
}
h1 {
  font-size: 36px;
  letter-spacing: -1.5px;
  line-height: 1.15;
  font-weight: 650;
  margin-bottom: 10px;
}
h2 {
  font-size: 23px;
  line-height: 1.3;
  letter-spacing: -0.7px;
  font-weight: 600;
}
p {
  line-height: 1.65;
}
.icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
.icon-library {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}
.app-shell {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 44px;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  position: relative;
}
.app-header {
  height: 96px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}
.brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  font-size: 25px;
  font-weight: 750;
  letter-spacing: -1.2px;
  gap: 9px;
}
.brand-mark {
  background: var(--accent);
  color: var(--page);
  border-radius: 11px;
  width: 36px;
  height: 38px;
  display: grid;
  place-items: center;
}
.brand-mark .icon {
  width: 28px;
  height: 28px;
  stroke-width: 1.3;
}
.brand-dot {
  color: #b87850;
  margin-left: -8px;
}
.header-note {
  font-size: 11px;
  color: var(--muted);
  margin-left: 9px;
}
.app-header > .icon-button {
  margin-left: auto;
}
.icon-button {
  min-width: 44px;
  min-height: 44px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
}
.icon-button:hover {
  background: var(--soft);
}
.app-nav {
  position: absolute;
  z-index: 5;
  top: 25px;
  right: 110px;
  display: flex;
  gap: 5px;
  padding: 4px;
}
.app-nav button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 15px;
  border-radius: 23px;
  color: var(--muted);
  background: transparent;
  font-size: 12px;
  position: relative;
  white-space: nowrap;
}
.app-nav button .icon {
  width: 18px;
  height: 18px;
}
.app-nav button[aria-selected="true"] {
  background: var(--soft);
  color: var(--accent);
  font-weight: 650;
}
.app-nav button:hover {
  background: #eaece2;
}
#rules-dot {
  width: 5px;
  height: 5px;
  background: #b67750;
  border-radius: 50%;
  position: absolute;
  top: 7px;
  right: 8px;
}
main {
  flex: 1;
  padding: 34px 0 0;
}
.page-heading {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  align-items: center;
  margin-bottom: 28px;
}
.eyebrow {
  color: #8c7b60;
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 1.65px;
  margin: 0 0 12px;
}
.page-heading p:last-child {
  color: var(--muted);
  font-size: 13px;
  margin: 0;
}
.board-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 270px;
  gap: 30px;
}
.board-panel {
  min-width: 0;
  overflow: hidden;
  border-radius: 24px;
  background: #e2e9df;
  position: relative;
  display: flex;
  flex-direction: column;
}
.board-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px 0;
  gap: 8px;
}
.live-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #62765b;
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 1.1px;
}
.live-label > i {
  width: 5px;
  height: 5px;
  background: #6c885e;
  border-radius: 50%;
}
.map-toggle {
  min-height: 36px;
  display: flex;
  align-items: center;
  gap: 5px;
  border-radius: 20px;
  background: #d4dfce;
  color: #4e6549;
  font-size: 10px;
  padding: 0 10px;
}
.map-toggle .icon {
  width: 15px;
  height: 15px;
}
.map-toggle[aria-pressed="false"] {
  color: #65725e;
  background: #e9eee6;
}
.board-canvas {
  flex: 1;
  display: grid;
  place-items: center;
  position: relative;
  min-height: 440px;
  padding: 4px 0;
  background-image: radial-gradient(#6b89641c 0.8px, transparent 0.8px);
  background-size: 15px 15px;
}
.board-canvas > svg {
  width: 100%;
  height: 100%;
  min-height: 440px;
  max-height: 520px;
  display: block;
}
.compass {
  color: #84957a;
  font-size: 8px;
  text-align: center;
  position: absolute;
  top: 11px;
  right: 21px;
  pointer-events: none;
}
.compass svg {
  width: 10px;
  height: 24px;
  display: block;
  margin-top: 3px;
  fill: currentColor;
  opacity: 0.65;
}
.board-bottom {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 22px 17px;
  color: #6c7a63;
  font-size: 10px;
}
#island-name {
  font-weight: 600;
  letter-spacing: 0.3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#island-detail {
  flex-shrink: 0;
  color: #7e8b73;
}
.island-controls {
  padding: 3px 0;
  display: flex;
  flex-direction: column;
}
.section-label {
  color: #807f6b;
  font-size: 9px;
  letter-spacing: 1.25px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 13px;
}
.section-label .icon {
  width: 17px;
  height: 17px;
  color: #87917c;
}
.segments {
  background: #eaece3;
  border: 1px solid #e3e6db;
  border-radius: 13px;
  padding: 4px;
  display: flex;
  gap: 4px;
}
.segments button {
  min-height: 59px;
  flex: 1;
  border-radius: 10px;
  background: transparent;
  color: #77816c;
  padding: 6px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}
.segments strong {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.2;
}
.segments span {
  font-size: 10px;
}
.segments button[aria-pressed="true"] {
  background: var(--paper);
  box-shadow: 0 2px 5px #2a39200a;
  color: var(--ink);
}
.hint {
  font-size: 11px;
  color: var(--muted);
  margin: 9px 0 0;
}
.board-health {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 22px 0;
}
.check-icon {
  width: 27px;
  height: 27px;
  background: #e6ebde;
  color: #69805b;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.check-icon .icon {
  width: 16px;
  height: 16px;
}
.board-health strong {
  font-size: 11px;
  font-weight: 550;
}
.board-health p {
  font-size: 10px;
  color: var(--muted);
  margin: 4px 0 0;
}
.text-button {
  min-width: 44px;
  min-height: 44px;
  background: transparent;
  color: #6f7e62;
  display: inline-grid;
  place-items: center;
  margin-left: auto;
}
.text-button .icon {
  width: 19px;
  height: 19px;
}
.primary {
  width: 100%;
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  padding: 12px 18px;
  border-radius: 13px;
  background: var(--accent);
  color: var(--paper);
  font-size: 13px;
  font-weight: 550;
}
.primary > .icon {
  width: 19px;
  height: 19px;
}
.primary:hover {
  background: oklch(38% 0.065 157);
}
.primary .action-arrow {
  margin-left: auto;
  width: 17px;
}
.secondary {
  width: 100%;
  min-height: 45px;
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 11px;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
}
.secondary .icon {
  width: 15px;
  height: 15px;
}
.secondary:hover {
  background: #eaece2;
}
.spots-preview {
  border-top: 1px solid var(--line);
  padding-top: 23px;
  margin-top: auto;
}
.spots-preview .section-label {
  font-size: 8px;
  margin-bottom: 10px;
}
.spots-preview h2 {
  font-size: 22px;
  margin-bottom: 9px;
}
.spots-preview p:not(.section-label) {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 15px;
}
.spot-shortcuts {
  display: flex;
  gap: 7px;
  margin-bottom: 8px;
}
.spot-shortcuts button {
  background: var(--paper);
  border: 1px solid #d5dbcc;
  color: #5b7054;
  border-radius: 50%;
  min-width: 35px;
  height: 35px;
  font-size: 12px;
}
.spot-shortcuts button:hover,
.spot-shortcuts button[aria-pressed="true"] {
  background: #dbe4d2;
  border-color: #91a67d;
}
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: none;
  padding: 10px 0;
  min-height: 44px;
  font-size: 11px;
  font-weight: 550;
  color: var(--accent);
}
.text-link .icon {
  width: 16px;
  height: 16px;
}
.resource-key {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 18px;
  padding: 20px 0 8px;
  max-width: calc(100% - 300px);
}
.resource-key > span {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 9px;
  color: #7a826f;
}
.resource-key i {
  width: 9px;
  height: 10px;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
}
.wood {
  background: var(--forest);
}
.wool {
  background: var(--wool);
}
.grain {
  background: var(--grain);
}
.brick {
  background: var(--brick);
}
.ore {
  background: var(--ore);
}
.desert {
  background: var(--desert);
}
.board-status {
  text-align: center;
  max-width: calc(100% - 300px);
  font-size: 9px;
  color: #7f8877;
  margin: 5px 0 0;
  line-height: 1.8;
}
.starts-layout {
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 44px;
  margin-top: 37px;
}
.starts-explainer {
  padding-top: 12px;
}
.mini-island {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  background: #e6ebdc;
  border-radius: 18px;
  color: #6e845d;
  margin-bottom: 24px;
}
.mini-island .icon {
  width: 30px;
  height: 30px;
  stroke-width: 1.3;
}
.starts-explainer h2 {
  font-size: 25px;
  margin-bottom: 14px;
}
.starts-explainer > p {
  font-size: 12px;
  color: var(--muted);
}
.fairness-note {
  margin-top: 28px;
  display: flex;
  align-items: flex-start;
  gap: 9px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
  color: #748363;
}
.fairness-note .icon {
  width: 16px;
  height: 16px;
  margin-top: 1px;
}
.fairness-note p {
  font-size: 11px;
  margin: 0;
}
.player-cards {
  border-top: 1px solid var(--line);
}
.player-card {
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.player-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 19px;
}
.player-name {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  font-weight: 550;
}
.position-badge {
  display: inline-grid;
  place-items: center;
  width: 35px;
  height: 35px;
  border: 1px solid #bdc9b0;
  border-radius: 50%;
  background: #e8eddf;
  color: #526b46;
  font-size: 15px;
  font-weight: 600;
  flex-shrink: 0;
}
.view-position {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  min-height: 44px;
  padding: 8px 0 8px 12px;
  background: none;
  color: var(--muted);
  font-size: 11px;
}
.view-position .icon {
  width: 16px;
  height: 16px;
}
.player-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  padding-left: 47px;
}
.metric strong {
  font-size: 24px;
  font-weight: 500;
  letter-spacing: -0.8px;
}
.metric small {
  font-size: 11px;
  color: #9b9e8d;
  margin-left: 3px;
}
.metric > span {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-top: 5px;
}
.starting-resources {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
  padding-left: 47px;
  margin-top: 19px;
}
.starting-resources > span:first-child {
  font-size: 10px;
  color: #87917a;
  margin-right: 4px;
}
.resource-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #eceedf;
  padding: 5px 7px;
  border-radius: 5px;
  font-size: 9px;
  color: #657257;
}
.resource-chip > i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}
.score-explainer {
  margin: 25px 0 0 314px;
  font-size: 11px;
  color: var(--muted);
}
.score-explainer summary {
  min-height: 44px;
  cursor: pointer;
  padding-top: 12px;
}
.score-explainer p {
  line-height: 1.8;
  max-width: 70ch;
}
.rules-layout {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 70px;
  margin-top: 42px;
}
.rules-section-label {
  margin-bottom: 18px;
}
.rules-list {
  border-top: 1px solid var(--line);
}
.toggle-row {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 100px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.rule-token {
  background: #ebe9df;
  border: 1px solid #e0dece;
  color: #7b7c67;
  width: 37px;
  height: 37px;
  position: relative;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  font-size: 14px;
  font-weight: 650;
}
.rule-token > span {
  position: absolute;
  bottom: -6px;
  right: -7px;
  border: 2px solid var(--page);
  border-radius: 50%;
  background: #e7e7da;
  width: 24px;
  height: 24px;
  font-size: 10px;
  display: grid;
  place-items: center;
}
.red-token {
  color: #b16e50;
  background: #f0e3d5;
  border-color: #e7d5c0;
}
.red-token > span {
  background: #eeddca;
}
.terrain-token {
  background: #e1e7d7;
  border-color: #d2ddc5;
  color: #7d9169;
  border-radius: 10px;
}
.rule-copy {
  flex: 1;
}
.rule-copy strong {
  display: block;
  font-size: 13px;
  font-weight: 550;
}
.rule-copy small {
  display: block;
  font-size: 11px;
  line-height: 1.5;
  color: var(--muted);
  margin-top: 6px;
}
.toggle-row input {
  appearance: none;
  width: 43px;
  height: 26px;
  border-radius: 18px;
  background: #dcded2;
  position: relative;
  margin: 0;
  flex-shrink: 0;
  cursor: pointer;
  transition: background 0.18s;
  border: 1px solid #d5d8ca;
}
.toggle-row input:before {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--paper);
  box-shadow: 0 1px 3px #34452818;
  transition: transform 0.18s;
}
.toggle-row input:checked {
  background: var(--accent);
  border-color: var(--accent);
}
.toggle-row input:checked:before {
  transform: translateX(17px);
}
.rules-caption {
  font-size: 10px;
  color: #929680;
  margin-top: 17px;
}
.seed-section {
  padding-top: 0;
}
.seed-section > .section-label {
  margin-bottom: 27px;
}
.seed-section h2 {
  font-size: 24px;
  margin-bottom: 12px;
}
.seed-section > p {
  font-size: 12px;
  color: var(--muted);
  max-width: 35ch;
}
.field-label {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin: 24px 0 9px;
}
.seed-input {
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  padding: 0 13px;
  gap: 9px;
  min-height: 53px;
}
.seed-input > span {
  color: #959a86;
  font-size: 16px;
}
.seed-input input {
  background: none;
  border: 0;
  width: 100%;
  min-width: 0;
  height: 44px;
  font-size: 13px;
  color: var(--ink);
}
.seed-input button {
  display: grid;
  place-items: center;
  background: transparent;
  color: var(--muted);
  min-height: 44px;
  min-width: 33px;
}
.seed-input .icon {
  width: 19px;
  height: 19px;
}
.seed-section > .primary {
  margin-top: 18px;
}
.seed-section .seed-foot {
  text-align: center;
  max-width: none;
  font-size: 9px;
  margin-top: 13px;
  color: #929680;
}
.help {
  padding: 23px;
  margin-bottom: 24px;
  background: #e8eddf;
  border-radius: 15px;
}
.help h2 {
  font-size: 19px;
}
.help p,
.help a {
  font-size: 12px;
  max-width: 75ch;
}
.help a {
  color: var(--accent);
}
.selection-clear {
  position: absolute;
  bottom: 1px;
  left: 50%;
  transform: translateX(-50%);
  background: #f7f5eb;
  color: #52674b;
  border-radius: 20px;
  padding: 8px 12px;
  min-height: 34px;
  font-size: 10px;
  box-shadow: 0 2px 6px #3f56351a;
  white-space: nowrap;
}
.hex {
  stroke: #f5f1db;
  stroke-width: 0.055;
  stroke-linejoin: round;
}
.token {
  fill: #f5f0d9;
  stroke: #e3d9b9;
  stroke-width: 0.018;
}
.number {
  font:
    700 0.43px -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  text-anchor: middle;
  fill: #3a4638;
}
.number.hot {
  fill: #a64e37;
}
.pip {
  fill: #655a3c;
}
.pip.hot {
  fill: #a64e37;
}
.settlement {
  stroke: #516557;
  stroke-width: 0.035;
}
.position-number {
  font:
    700 0.24px -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  fill: #304637;
  text-anchor: middle;
  dominant-baseline: middle;
  pointer-events: none;
}
.position-piece {
  transition: opacity 0.18s;
}
.position-piece.dimmed {
  opacity: 0.17;
}
.port-label {
  font:
    0.16px -apple-system,
    BlinkMacSystemFont,
    sans-serif;
  fill: #6f826b;
  text-anchor: middle;
}
.port-line {
  stroke: #96a58b;
  stroke-width: 0.025;
  stroke-dasharray: 0.06 0.06;
}
.terrain-art {
  opacity: 0.27;
  fill: none;
  stroke: #314a31;
  stroke-width: 0.025;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
}
.terrain-label {
  font-size: 0.11px;
  fill: #344a34;
  opacity: 0.6;
  text-anchor: middle;
  letter-spacing: 0.025px;
  pointer-events: none;
}
footer {
  display: flex;
  gap: 15px;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  margin-top: 34px;
  padding: 20px 0 22px;
  color: #929681;
  font-size: 10px;
}
footer small {
  font-size: 9px;
}
#error,
#toast {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  padding: 15px 20px;
  z-index: 20;
  border-radius: 13px;
  max-width: min(90vw, 500px);
  width: max-content;
  font-size: 12px;
  box-shadow: 0 4px 20px #233c2515;
}
#error {
  background: #f4e0d4;
  color: #8b4e38;
  border: 1px solid #ddbfa6;
}
#toast {
  color: var(--paper);
  background: var(--ink);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s;
}
#toast.show {
  opacity: 1;
}
.share-link {
  display: block;
  position: fixed;
  z-index: 20;
  bottom: 30px;
  left: 5%;
  width: 90%;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
}
@media (min-width: 1100px) {
  .header-note {
    display: inline;
  }
  .board-canvas > svg {
    min-height: 470px;
  }
}
@media (max-width: 1099px) {
  .header-note {
    display: none;
  }
  .app-shell {
    padding: 0 32px;
  }
  .app-nav {
    right: 98px;
  }
  .board-layout {
    grid-template-columns: minmax(0, 1fr) 235px;
    gap: 24px;
  }
  .board-canvas {
    min-height: 420px;
  }
  .board-canvas > svg {
    min-height: 420px;
  }
  .resource-key,
  .board-status {
    max-width: calc(100% - 259px);
  }
  .resource-key {
    gap: 11px;
  }
  .spots-preview h2 {
    font-size: 20px;
  }
  .starts-layout {
    gap: 30px;
    grid-template-columns: 230px 1fr;
  }
  .score-explainer {
    margin-left: 260px;
  }
  .rules-layout {
    gap: 35px;
  }
  .rule-copy small {
    font-size: 10px;
  }
}
@media (max-width: 760px) {
  .app-shell {
    padding: 0 22px;
    max-width: 560px;
    padding-bottom: calc(85px + env(safe-area-inset-bottom));
  }
  .app-header {
    height: 76px;
    border: 0;
    padding-top: env(safe-area-inset-top);
  }
  .brand {
    font-size: 24px;
  }
  .brand-mark {
    width: 32px;
    height: 35px;
    border-radius: 10px;
  }
  .brand-mark .icon {
    width: 25px;
    height: 25px;
  }
  .app-header > .icon-button {
    width: 42px;
    height: 42px;
    background: #edece3;
    border: 0;
  }
  .app-nav {
    position: fixed;
    top: auto;
    right: 0;
    left: 0;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    padding: 9px max(12px, calc((100vw - 500px) / 2))
      calc(9px + env(safe-area-inset-bottom));
    background: var(--page);
    border-top: 1px solid #e0e2d7;
    z-index: 10;
  }
  .app-nav button {
    flex-direction: column;
    height: 54px;
    font-size: 10px;
    gap: 5px;
    padding: 0 6px;
    border-radius: 13px;
    background: none;
    color: #89907e;
  }
  .app-nav button .icon {
    width: 23px;
    height: 23px;
    stroke-width: 1.5;
  }
  .app-nav button[aria-selected="true"] {
    background: none;
    color: var(--accent);
  }
  .app-nav button[aria-selected="true"]:before {
    content: "";
    position: absolute;
    background: #e3e9d9;
    width: 51px;
    height: 30px;
    border-radius: 20px;
    top: 0;
    z-index: -1;
  }
  #rules-dot {
    right: calc(50% - 22px);
    top: 0;
  }
  main {
    padding-top: 16px;
  }
  .page-heading {
    margin-bottom: 24px;
  }
  .page-heading > .icon-button {
    min-width: 40px;
    min-height: 40px;
    margin-top: 12px;
  }
  .page-heading > .icon-button .icon {
    width: 18px;
    height: 18px;
  }
  .eyebrow {
    font-size: 8px;
    letter-spacing: 1.35px;
    margin-bottom: 11px;
  }
  h1 {
    font-size: 32px;
    letter-spacing: -1.2px;
    margin-bottom: 8px;
  }
  .page-heading p:last-child {
    font-size: 12px;
  }
  .board-layout {
    display: flex;
    flex-direction: column;
    gap: 22px;
  }
  .board-panel {
    border-radius: 23px;
    margin: 0 -9px;
  }
  .board-top {
    padding: 12px 15px 0;
  }
  .live-label {
    font-size: 7px;
    letter-spacing: 1px;
  }
  .map-toggle {
    font-size: 9px;
    min-height: 34px;
  }
  .board-canvas {
    min-height: 310px;
    padding: 0;
  }
  .board-canvas > svg {
    min-height: 0;
    height: auto;
    aspect-ratio: 1.05;
    max-height: none;
  }
  .board-bottom {
    font-size: 9px;
    padding: 11px 18px 16px;
  }
  .compass {
    right: 16px;
    top: 4px;
    font-size: 7px;
  }
  .compass svg {
    width: 8px;
    height: 20px;
  }
  .island-controls {
    display: grid;
    grid-template-columns: 1fr;
    padding: 0;
  }
  .table-settings {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    column-gap: 15px;
  }
  .table-settings > .section-label {
    font-size: 8px;
    margin: 0;
  }
  .table-settings > .section-label .icon {
    display: none;
  }
  .hint {
    grid-column: 1;
    grid-row: 2;
    font-size: 10px;
    margin-top: 4px;
  }
  .segments {
    grid-column: 2;
    grid-row: 1/3;
    padding: 3px;
    border-radius: 12px;
    gap: 3px;
  }
  .segments button {
    min-height: 43px;
    min-width: 48px;
    padding: 7px 11px;
    border-radius: 9px;
  }
  .segments strong {
    font-size: 17px;
  }
  .segments span {
    display: none;
  }
  .board-health {
    padding: 18px 0 15px;
  }
  .board-health strong {
    font-size: 11px;
  }
  .board-health p {
    font-size: 10px;
  }
  .check-icon {
    width: 28px;
    height: 28px;
  }
  .board-actions {
    display: grid;
    grid-template-columns: 1fr 48px;
    gap: 9px;
  }
  .primary {
    min-height: 52px;
    font-size: 13px;
    border-radius: 13px;
  }
  .secondary {
    height: 52px;
    min-height: 52px;
    padding: 0;
    margin: 0;
    background: #e9ecdf;
    border-radius: 13px;
    font-size: 0;
    gap: 0;
  }
  .secondary .icon {
    width: 20px;
    height: 20px;
  }
  .spots-preview {
    display: grid;
    grid-template-columns: 1fr auto;
    margin-top: 25px;
    padding-top: 20px;
    column-gap: 12px;
  }
  .spots-preview .section-label {
    font-size: 7px;
    letter-spacing: 1px;
  }
  .spots-preview h2 {
    font-size: 18px;
    letter-spacing: -0.4px;
    line-height: 1.4;
    margin-bottom: 3px;
  }
  .spots-preview h2 br {
    display: none;
  }
  .spots-preview p:not(.section-label) {
    display: none;
  }
  .spot-shortcuts {
    align-self: center;
    gap: 4px;
    margin: 0;
    flex-wrap: wrap;
    max-width: 126px;
    justify-content: flex-end;
  }
  .spot-shortcuts button {
    min-width: 36px;
    height: 36px;
    font-size: 11px;
  }
  .spots-preview .text-link {
    grid-column: 1/-1;
    font-size: 10px;
    padding-bottom: 0;
  }
  .resource-key,
  .board-status {
    max-width: none;
  }
  .resource-key {
    padding: 26px 0 7px;
    gap: 12px;
  }
  .resource-key > span {
    font-size: 8px;
    gap: 4px;
  }
  .resource-key i {
    width: 7px;
    height: 8px;
  }
  .board-status {
    font-size: 8px;
    margin-bottom: 0;
  }
  .starts-layout {
    display: flex;
    flex-direction: column;
    gap: 19px;
    margin-top: 0;
  }
  .starts-explainer {
    padding: 0;
    display: grid;
    grid-template-columns: 43px 1fr;
    column-gap: 12px;
  }
  .mini-island {
    width: 43px;
    height: 43px;
    border-radius: 13px;
    margin: 2px 0 0;
    grid-row: 1/3;
  }
  .mini-island .icon {
    width: 25px;
    height: 25px;
  }
  .starts-explainer h2 {
    font-size: 15px;
    letter-spacing: -0.2px;
    margin-bottom: 5px;
  }
  .starts-explainer h2 br {
    display: none;
  }
  .starts-explainer > p {
    font-size: 11px;
    margin-bottom: 0;
  }
  .starts-explainer > .text-link {
    display: none;
  }
  .fairness-note {
    grid-column: 1/-1;
    margin-top: 17px;
    padding: 12px 13px;
    border: 0;
    border-radius: 10px;
    background: #e9eddf;
  }
  .fairness-note p {
    font-size: 10px;
  }
  .player-card {
    padding: 18px 0;
  }
  .player-heading {
    margin-bottom: 16px;
  }
  .player-name {
    font-size: 14px;
    gap: 10px;
  }
  .position-badge {
    width: 32px;
    height: 32px;
    font-size: 14px;
  }
  .view-position {
    font-size: 10px;
  }
  .view-position .icon {
    width: 15px;
  }
  .player-metrics {
    padding-left: 42px;
  }
  .metric strong {
    font-size: 24px;
  }
  .metric small {
    font-size: 10px;
  }
  .metric > span {
    font-size: 9px;
  }
  .starting-resources {
    padding-left: 42px;
    margin-top: 15px;
  }
  .starting-resources > span:first-child {
    font-size: 9px;
  }
  .resource-chip {
    font-size: 8px;
    padding: 4px 6px;
  }
  .score-explainer {
    margin: 13px 0 0;
    font-size: 10px;
  }
  .rules-layout {
    display: flex;
    flex-direction: column;
    gap: 26px;
    margin-top: 29px;
  }
  .rules-section-label {
    font-size: 8px;
    margin-bottom: 13px;
  }
  .toggle-row {
    min-height: 90px;
    gap: 16px;
    padding: 19px 0;
  }
  .rule-token {
    width: 34px;
    height: 34px;
    font-size: 13px;
  }
  .rule-token > span {
    width: 23px;
    height: 23px;
  }
  .rule-copy strong {
    font-size: 12px;
  }
  .rule-copy small {
    font-size: 10px;
    margin-top: 5px;
  }
  .toggle-row input {
    width: 42px;
    height: 26px;
  }
  .rules-caption {
    font-size: 9px;
    margin: 13px 0 0;
  }
  .seed-section {
    border-top: 1px solid var(--line);
    padding-top: 24px;
  }
  .seed-section > .section-label {
    font-size: 8px;
    margin-bottom: 15px;
  }
  .seed-section h2 {
    font-size: 22px;
  }
  .seed-section > p {
    font-size: 11px;
    max-width: 40ch;
  }
  .field-label {
    margin-top: 19px;
  }
  .seed-input input {
    font-size: 16px;
  }
  .seed-section .seed-foot {
    font-size: 9px;
  }
  .help {
    padding: 18px;
  }
  .help p,
  .help a {
    font-size: 11px;
  }
  footer {
    margin-top: 27px;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    border: 0;
    padding: 0 0 4px;
    font-size: 9px;
  }
  footer small {
    font-size: 8px;
    color: #a0a38f;
  }
  #toast,
  #error {
    bottom: calc(90px + env(safe-area-inset-bottom));
    font-size: 11px;
  }
  .share-link {
    bottom: calc(90px + env(safe-area-inset-bottom));
  }
}
@media (max-width: 370px) {
  .app-shell {
    padding-left: 18px;
    padding-right: 18px;
  }
  h1 {
    font-size: 29px;
  }
  .eyebrow {
    font-size: 7px;
  }
  .board-canvas {
    min-height: 270px;
  }
  .resource-key {
    gap: 9px;
  }
  .resource-key > span {
    font-size: 7px;
  }
  .rule-copy small {
    max-width: 160px;
  }
  .spots-preview {
    grid-template-columns: 1fr;
  }
  .spot-shortcuts {
    max-width: none;
    justify-content: flex-start;
    margin-top: 12px;
  }
  .spots-preview .text-link {
    grid-column: 1;
  }
  .spot-shortcuts button {
    min-width: 39px;
    height: 39px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
@media print {
  .app-header,
  .app-nav,
  .page-heading,
  .island-controls,
  .board-top,
  .resource-key,
  .board-status,
  footer,
  .selection-clear,
  .view-position,
  .score-explainer,
  .starts-explainer {
    display: none !important;
  }
  .app-shell {
    padding: 0;
  }
  .app-view[hidden] {
    display: block !important;
  }
  #view-rules {
    display: none !important;
  }
  .board-layout,
  .starts-layout {
    display: block;
  }
  .board-canvas > svg {
    height: 450px;
    min-height: 450px;
  }
  .board-panel {
    break-inside: avoid;
    background: #eef0e7;
  }
  .player-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  .player-card {
    break-inside: avoid;
  }
  .player-metrics,
  .starting-resources {
    padding-left: 0;
  }
  .position-piece.dimmed {
    opacity: 1;
  }
}

@media (max-width: 760px) {
  .page-heading p:last-child {
    font-size: 13px;
  }
  .app-nav button {
    font-size: 11px;
  }
  .eyebrow,
  .table-settings > .section-label {
    font-size: 9px;
  }
  .hint,
  .board-health p {
    font-size: 11px;
  }
  .board-health strong {
    font-size: 12px;
  }
  .board-top .live-label {
    font-size: 8px;
  }
  .map-toggle {
    font-size: 10px;
  }
  .primary {
    font-size: 14px;
  }
  .spots-preview .section-label {
    font-size: 8px;
  }
  .spots-preview .text-link {
    font-size: 12px;
  }
  .resource-key {
    gap: 11px;
  }
  .resource-key > span {
    font-size: 10px;
  }
  .board-status {
    font-size: 10px;
  }
  .rule-copy strong {
    font-size: 14px;
  }
  .rule-copy small {
    font-size: 12px;
  }
  .rule-token {
    margin-right: 2px;
  }
  .rules-caption {
    font-size: 11px;
  }
  .rules-section-label,
  .seed-section > .section-label {
    font-size: 10px;
  }
  .seed-section > p,
  .seed-section .seed-foot {
    font-size: 12px;
  }
  .starts-explainer > p {
    font-size: 12px;
  }
  .fairness-note p {
    font-size: 12px;
  }
  .metric > span,
  .starting-resources > span:first-child {
    font-size: 11px;
  }
  .resource-chip {
    font-size: 10px;
  }
  .view-position {
    font-size: 12px;
  }
  .score-explainer {
    font-size: 12px;
  }
  .terrain-label {
    display: none;
  }
}
@media (max-width: 370px) {
  .rule-copy small {
    font-size: 11px;
  }
  .resource-key {
    gap: 9px 12px;
  }
  .resource-key > span {
    font-size: 9px;
  }
}
/* Illustrated tabletop board. */
.board-panel {
  background: #eee9da;
}
.board-canvas {
  background: none;
}
.hex {
  stroke: #e6ce92;
  stroke-width: 0.09;
  stroke-linejoin: round;
}
.hex-border {
  stroke: #977c4f;
  stroke-width: 0.012;
  stroke-linejoin: round;
}
.sea-frame {
  stroke: #8bb5be;
  stroke-width: 0.035;
  stroke-linejoin: round;
}
.token {
  fill: #e7cc8a;
  stroke: #453e2d;
  stroke-width: 0.018;
}
.number {
  font-size: 0.51px;
  font-weight: 900;
  fill: #201e17;
  letter-spacing: -0.02px;
}
.number.hot,
.pip.hot {
  fill: #c93620;
}
.pip {
  fill: #28261b;
}
.harbor-pier {
  stroke: #8c7752;
  stroke-width: 0.055;
  fill: none;
}
.port-label {
  font:
    750 0.17px -apple-system,
    BlinkMacSystemFont,
    sans-serif;
  fill: #4d4530;
  text-anchor: middle;
}
.port-resource {
  font:
    700 0.085px -apple-system,
    BlinkMacSystemFont,
    sans-serif;
  fill: #6a5738;
  text-anchor: middle;
}
.app-nav button {
  padding-left: 11px;
  padding-right: 11px;
}
.header-note {
  display: none;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.leaderboard-root {
  max-width: 760px;
  margin: 36px auto 0;
}
.league-toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}
.league-toolbar select {
  font: inherit;
  font-size: 14px;
  font-weight: 550;
  padding: 13px 36px 13px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  color: var(--ink);
  min-width: 0;
  flex: 1;
}
.league-new {
  min-height: 46px;
  background: var(--soft);
  color: var(--accent);
  padding: 10px 17px;
  border-radius: 12px;
  font-size: 13px;
}
.league-create {
  max-width: 450px;
  padding: 24px 0 30px;
  margin: 0 auto;
}
.league-emblem {
  display: grid;
  place-items: center;
  width: 65px;
  height: 65px;
  border-radius: 21px;
  background: #eee6ce;
  color: #a1803a;
  margin-bottom: 22px;
}
.league-emblem .icon {
  width: 32px;
  height: 32px;
}
.league-create h2 {
  font-size: 26px;
  margin-bottom: 12px;
}
.league-create p {
  font-size: 13px;
  color: var(--muted);
}
.league-create > input,
.add-player input {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  padding: 14px;
  border-radius: 11px;
  font: inherit;
  font-size: 16px;
}
.league-create > .primary {
  margin-top: 13px;
}
.league-create > .primary span {
  margin-left: auto;
}
.standings-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 28px 0 20px;
  gap: 16px;
}
.standings-header .section-label {
  margin-bottom: 7px;
}
.standings-header h2 {
  margin: 0;
  font-size: 25px;
  word-break: break-word;
}
.undo-score {
  min-height: 44px;
  background: transparent;
  padding: 10px 0 10px 14px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}
button:disabled {
  cursor: default;
}
.score-table {
  border-top: 1px solid var(--line);
}
.score-row {
  display: flex;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  min-height: 87px;
  padding: 14px 0;
}
.score-rank {
  width: 28px;
  flex-shrink: 0;
  font-size: 13px;
  color: #959b86;
  text-align: center;
}
.score-rank.leading {
  color: #ac8439;
}
.score-rank .icon {
  width: 24px;
  height: 24px;
}
.score-player {
  font-size: 15px;
  font-weight: 550;
  flex: 1;
  overflow-wrap: anywhere;
  min-width: 0;
}
.score-stepper {
  display: flex;
  align-items: center;
  gap: 5px;
}
.score-stepper button {
  width: 40px;
  height: 40px;
  font-size: 20px;
  background: #e8eddf;
  border-radius: 11px;
  color: var(--accent);
}
.score-stepper button:hover {
  background: #dce6ce;
}
.score-stepper input {
  appearance: textfield;
  -moz-appearance: textfield;
  border: 0;
  background: transparent;
  color: var(--ink);
  width: 64px;
  padding: 6px 0;
  text-align: center;
  font: inherit;
  font-size: 25px;
  letter-spacing: -0.8px;
  font-weight: 550;
}
.score-stepper input::-webkit-inner-spin-button,
.score-stepper input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.score-tip {
  font-size: 11px;
  color: var(--muted);
  text-align: right;
  margin-top: 14px;
}
.add-player {
  margin-top: 28px;
}
.add-player .field-label {
  font-size: 12px;
}
.add-player > div {
  display: flex;
  gap: 9px;
}
.add-player button {
  background: var(--accent);
  color: var(--paper);
  font-size: 13px;
  border-radius: 11px;
  padding: 10px 20px;
  min-width: 83px;
  display: flex;
  justify-content: center;
  gap: 10px;
  align-items: center;
}
.no-players {
  text-align: center;
  background: #eceedf;
  border-radius: 15px;
  padding: 28px 20px;
}
.no-players p {
  margin-bottom: 5px;
  font-size: 16px;
}
.no-players span {
  font-size: 12px;
  color: var(--muted);
}
.leaderboard-storage {
  border-top: 1px solid var(--line);
  margin-top: 35px;
  padding-top: 23px;
}
.device-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #78866a;
}
.device-badge .icon {
  width: 14px;
  height: 14px;
}
.leaderboard-storage > p {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.8;
  max-width: 70ch;
  margin: 10px 0;
}
.backup-actions {
  display: flex;
  gap: 22px;
}
.backup-actions button {
  background: none;
  color: var(--accent);
  min-height: 44px;
  font-size: 12px;
  padding: 10px 0;
}
.storage-warning {
  color: #9c6544;
  background: #f0e4d3;
  padding: 15px;
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.6;
}
@media (max-width: 850px) and (min-width: 761px) {
  .brand {
    font-size: 21px;
    gap: 6px;
  }
  .brand-mark {
    width: 30px;
    height: 34px;
  }
  .app-nav button {
    padding: 0 9px;
    gap: 5px;
    font-size: 11px;
  }
  .app-nav {
    right: 90px;
    gap: 0;
  }
}
@media (max-width: 760px) {
  .app-nav {
    grid-template-columns: repeat(4, 1fr);
    padding-left: max(4px, calc((100vw - 500px) / 2));
    padding-right: max(4px, calc((100vw - 500px) / 2));
  }
  .app-nav button {
    padding: 0 3px;
    font-size: 10px;
  }
  .leaderboard-root {
    margin-top: 24px;
  }
  .league-create {
    padding-top: 10px;
  }
  .league-create h2 {
    font-size: 23px;
  }
  .league-create p {
    font-size: 13px;
  }
  .league-emblem {
    width: 57px;
    height: 57px;
    border-radius: 18px;
  }
  .league-toolbar {
    gap: 9px;
    padding-bottom: 20px;
  }
  .league-toolbar select {
    font-size: 14px;
  }
  .league-new {
    padding: 10px 14px;
    font-size: 12px;
  }
  .standings-header h2 {
    font-size: 22px;
  }
  .score-row {
    gap: 9px;
    min-height: 83px;
  }
  .score-player {
    font-size: 14px;
  }
  .score-rank {
    width: 24px;
  }
  .score-stepper {
    gap: 0;
  }
  .score-stepper button {
    width: 36px;
    height: 42px;
  }
  .score-stepper input {
    width: 58px;
    font-size: 24px;
  }
  .score-tip {
    font-size: 10px;
    text-align: center;
  }
  .leaderboard-storage > p {
    font-size: 12px;
  }
  .backup-actions button {
    font-size: 12px;
  }
  .device-badge {
    font-size: 12px;
  }
}
@media (max-width: 370px) {
  .app-nav button {
    font-size: 9px;
  }
  .score-row {
    gap: 7px;
  }
  .score-stepper button {
    width: 32px;
  }
  .score-stepper input {
    width: 51px;
    font-size: 22px;
  }
  .score-player {
    font-size: 13px;
  }
  .score-rank {
    width: 20px;
  }
}
@media print {
  #view-leaderboard {
    display: none !important;
  }
}
.map-interaction-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 9px 16px 0;
}
.map-interaction-bar > span {
  font-size: 10px;
  color: var(--muted);
}
.board-canvas {
  overflow: hidden;
  isolation: isolate;
}
.board-canvas > #board {
  transform-origin: center;
  will-change: auto;
}
.board-canvas.zoom-enabled {
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}
.board-canvas.zoom-enabled > #board {
  will-change: transform;
}
.board-canvas.zoom-enabled.is-zoomed {
  cursor: grab;
}
.board-canvas.zoom-enabled.is-zoomed:active {
  cursor: grabbing;
}
.map-zoom-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-top: 1px solid #ded8c8;
}
.map-zoom-controls button {
  min-width: 44px;
  min-height: 44px;
  border-radius: 11px;
  background: #f7f4e8;
  font-size: 21px;
  color: var(--ink);
}
#map-zoom-reset {
  padding: 0 13px;
  font-size: 12px;
  margin-left: 5px;
}
#map-zoom-level {
  min-width: 48px;
  text-align: center;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.board-layout > *,
.rules-layout > *,
.starts-layout > *,
.app-view {
  min-width: 0;
}
@media (max-width: 760px) {
  .map-interaction-bar .map-toggle {
    min-height: 44px;
    font-size: 11px;
  }
  .map-interaction-bar > span {
    font-size: 10px;
  }
  .board-bottom {
    flex-wrap: wrap;
  }
  .page-heading > div {
    min-width: 0;
  }
  .score-player,
  .standings-header h2 {
    overflow-wrap: anywhere;
  }
}
@media (max-width: 370px) {
  .app-shell {
    padding-left: 14px;
    padding-right: 14px;
  }
  .rule-copy {
    min-width: 0;
  }
  .toggle-row {
    gap: 12px;
  }
  .map-interaction-bar {
    padding-left: 12px;
    padding-right: 12px;
  }
}
@media print {
  .map-interaction-bar,
  .map-zoom-controls {
    display: none !important;
  }
  #board {
    transform: none !important;
  }
}
.map-zoom-controls button,
.selection-clear,
.undo-score,
.league-new,
.backup-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
}
.map-zoom-controls .icon {
  width: 19px;
  height: 19px;
}
.selection-clear .icon,
.undo-score .icon,
.league-new .icon,
.backup-actions .icon {
  width: 16px;
  height: 16px;
}
.score-stepper button {
  display: inline-grid;
  place-items: center;
}
.score-stepper .icon {
  width: 18px;
  height: 18px;
}
.board-status > span {
  display: inline-flex;
  vertical-align: middle;
  margin-right: 5px;
}
.board-status .icon {
  width: 12px;
  height: 12px;
}
.help a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.help a .icon {
  width: 15px;
  height: 15px;
}
.compass .icon {
  fill: none;
  stroke: currentColor;
}
.local-data-settings {
  margin: 34px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
.local-data-settings h2 {
  font-size: 16px;
  margin-bottom: 9px;
}
.local-data-settings p {
  font-size: 12px;
  color: var(--muted);
  max-width: 65ch;
  margin-bottom: 5px;
}
.danger-outline {
  padding: 12px 16px;
  min-height: 44px;
  border: 1px solid #c8a18c;
  border-radius: 11px;
  color: #985b42;
  background: transparent;
  font-size: 12px;
  flex-shrink: 0;
}
#clear-data-dialog {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--page);
  color: var(--ink);
  padding: 28px;
  max-width: min(480px, calc(100vw - 32px));
  max-height: 85svh;
  overflow: auto;
}
#clear-data-dialog::backdrop {
  background: #1b2d25a8;
}
#clear-data-dialog h2 {
  font-size: 23px;
}
#clear-data-dialog p {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.8;
}
.dialog-actions {
  display: flex;
  gap: 10px;
  margin-top: 23px;
}
.dialog-actions button {
  min-height: 46px;
  padding: 12px 15px;
  border-radius: 11px;
  font-size: 12px;
  flex: 1;
}
#cancel-clear {
  background: var(--soft);
  color: var(--accent);
}
.danger-button {
  background: #a54e37;
  color: #fff7ec;
}
@media (max-width: 760px) {
  .local-data-settings {
    align-items: flex-start;
    flex-direction: column;
    gap: 13px;
  }
  .danger-outline {
    width: 100%;
  }
  #clear-data-dialog {
    padding: 23px;
  }
  .dialog-actions {
    flex-direction: column;
  }
}
