.brand__icon {
  min-width: 38px;
}

.brand h1 {
  max-width: 240px;
}

.app-frame--screenshot .topbar,
.app-frame--screenshot .acc-settings-panel {
  display: none !important;
}

.acc-settings-panel {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  padding: 16px;
  color: #111827;
  background: rgba(248, 250, 252, 0.94);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.28);
}

.acc-settings-panel__header,
.acc-template-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.acc-settings-panel__header p,
.acc-template-panel__header p {
  margin: 0 0 4px;
  color: #526173;
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.acc-settings-panel__header h2,
.acc-template-panel__header h3 {
  margin: 0;
  color: #111827;
  letter-spacing: 0;
}

.acc-settings-panel__header h2 {
  font-size: 1.28rem;
}

.acc-template-panel__header h3 {
  font-size: 1.06rem;
}

.acc-settings-panel__summary {
  max-width: 360px;
  color: #526173;
  font-size: 0.88rem;
  line-height: 1.35;
  text-align: right;
}

.acc-settings-panel__modes {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
  margin: 14px 0;
}

.acc-mode-button {
  min-height: 42px;
  border: 1px solid #cbd5e1;
  border-radius: 7px;
  color: #334155;
  background: #ffffff;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 850;
  line-height: 1.1;
  cursor: pointer;
  transition: border-color 160ms ease, color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.acc-mode-button:hover,
.acc-mode-button:focus-visible {
  color: #111827;
  border-color: #0ea5e9;
}

.acc-mode-button.is-active {
  color: #07111f;
  border-color: transparent;
  background: linear-gradient(135deg, #9be7ff, #b7f5c9);
  box-shadow: 0 8px 18px rgba(14, 165, 233, 0.22);
}

.acc-settings-panel__body {
  display: grid;
  grid-template-columns: minmax(220px, 0.62fr) minmax(0, 1.4fr);
  gap: 14px;
  align-items: start;
}

.acc-settings-panel__controls {
  display: grid;
  gap: 10px;
  min-height: 100%;
  border: 1px solid #d7dee9;
  border-radius: 8px;
  padding: 12px;
  background: #f8fafc;
}

.acc-field {
  display: grid;
  gap: 6px;
  color: #334155;
  font-size: 0.82rem;
  font-weight: 900;
}

.acc-field input,
.acc-field select {
  min-height: 40px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 8px 10px;
  color: #111827;
  background: #ffffff;
  font: inherit;
  font-size: 0.92rem;
}

.acc-field-note,
.acc-template-panel__scale,
.acc-template-status {
  color: #526173;
  font-size: 0.82rem;
  line-height: 1.35;
}

.acc-template-panel {
  display: grid;
  gap: 12px;
  border: 1px solid #d7dee9;
  border-radius: 8px;
  padding: 12px;
  background: #ffffff;
}

.acc-template-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.acc-template-card {
  display: grid;
  gap: 6px;
  min-height: 132px;
  border: 1px solid #d7dee9;
  border-radius: 8px;
  padding: 10px;
  background: #f8fafc;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.acc-template-card:hover,
.acc-template-card:focus-visible,
.acc-template-card.is-selected {
  border-color: #0ea5e9;
  background: #eefaff;
  box-shadow: 0 8px 20px rgba(14, 165, 233, 0.18);
  outline: none;
}

.acc-template-card span {
  color: #0f7490;
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.acc-template-card strong {
  color: #111827;
  font-size: 0.92rem;
  line-height: 1.12;
}

.acc-template-card p {
  margin: 0;
  color: #526173;
  font-size: 0.76rem;
  line-height: 1.34;
}

.acc-edge-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  width: min(calc(100cqw * var(--wheel-scale)), calc(100cqh * var(--wheel-scale)));
  max-width: 100%;
  aspect-ratio: 1;
  margin: auto;
  pointer-events: none;
  transform: translate(var(--wheel-offset-x), calc(var(--wheel-offset-y) - 14px));
}

.acc-edge-overlay svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.acc-edge-ring {
  fill: none;
  stroke: rgba(15, 23, 42, 0.36);
  stroke-width: 3;
}

.acc-edge-ring--inner {
  stroke: rgba(255, 255, 255, 0.52);
  stroke-width: 2;
}

.acc-edge-tick {
  stroke-linecap: round;
}

.acc-edge-tick--major {
  stroke: rgba(15, 23, 42, 0.68);
  stroke-width: 4;
}

.acc-edge-tick--minor {
  stroke: rgba(255, 255, 255, 0.7);
  stroke-width: 2;
}

.acc-edge-label {
  dominant-baseline: middle;
  text-anchor: middle;
  paint-order: stroke;
  stroke-linejoin: round;
  pointer-events: none;
  letter-spacing: 0;
}

.acc-edge-label--major {
  fill: #06111f;
  stroke: rgba(255, 255, 255, 0.92);
  stroke-width: 7px;
  font-size: 28px;
  font-weight: 950;
}

.acc-edge-label--minor {
  fill: #ffffff;
  stroke: rgba(6, 17, 31, 0.72);
  stroke-width: 5px;
  font-size: 19px;
  font-weight: 900;
}

.acc-edge-caption {
  text-anchor: middle;
  fill: #ffffff;
  paint-order: stroke;
  stroke: rgba(6, 17, 31, 0.78);
  stroke-width: 6px;
  font-size: 25px;
  font-weight: 950;
  letter-spacing: 0;
}

.app[data-acc-mode]:not([data-acc-mode="annual"]) .cadence-wheel__month-label,
.app[data-acc-mode]:not([data-acc-mode="annual"]) .cadence-wheel__week-label {
  opacity: 0.08;
}

.app[data-acc-mode]:not([data-acc-mode="annual"]) .cadence-wheel {
  opacity: 0;
  pointer-events: none;
}

.acc-mode-wheel {
  position: absolute;
  inset: 0;
  z-index: 3;
  width: min(calc(100cqw * var(--wheel-scale)), calc(100cqh * var(--wheel-scale)));
  max-width: 100%;
  aspect-ratio: 1;
  margin: auto;
  pointer-events: auto;
  transform: translate(var(--wheel-offset-x), calc(var(--wheel-offset-y) - 14px));
}

.acc-mode-wheel svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.acc-mode-shadow {
  fill: rgba(0, 0, 0, 0.16);
  filter: url(#accModeShadow);
}

.acc-mode-face {
  fill: url(#accModeFace);
  stroke: rgba(255, 255, 255, 0.76);
  stroke-width: 4;
}

.acc-mode-outer-segment {
  stroke: rgba(255, 255, 255, 0.88);
  stroke-width: 4;
}

.acc-mode-outer-segment--0 {
  fill: #0ea5e9;
}

.acc-mode-outer-segment--1 {
  fill: #1aaee4;
}

.acc-mode-outer-segment--2 {
  fill: #0f9bd4;
}

.acc-mode-outer-segment--3 {
  fill: #18b6de;
}

.acc-mode-outer-segment--4 {
  fill: #087fbd;
}

.acc-mode-outer-segment--5 {
  fill: #14a3c7;
}

.acc-mode-scale-ring,
.acc-mode-event-field {
  fill: none;
  stroke: rgba(15, 23, 42, 0.2);
  stroke-width: 3;
}

.acc-mode-event-field {
  stroke: rgba(15, 23, 42, 0.14);
  stroke-width: 2;
}

.acc-mode-cell {
  fill: rgba(238, 245, 252, 0.94);
  stroke: rgba(148, 163, 184, 0.48);
  stroke-width: 1.4;
}

.acc-mode-cell--labeled {
  fill: rgba(219, 234, 254, 0.95);
}

.acc-mode-major-label,
.acc-mode-cell-label,
.acc-mode-caption,
.acc-mode-event-label {
  dominant-baseline: middle;
  text-anchor: middle;
  paint-order: stroke;
  stroke-linejoin: round;
  letter-spacing: 0;
}

.acc-mode-major-label {
  fill: #ffffff;
  stroke: rgba(6, 17, 31, 0.72);
  stroke-width: 8px;
  font-size: 31px;
  font-weight: 950;
}

.acc-mode-cell-label {
  fill: #0f172a;
  stroke: rgba(255, 255, 255, 0.88);
  stroke-width: 4px;
  font-size: 14px;
  font-weight: 900;
}

.acc-mode-caption {
  fill: #ffffff;
  stroke: rgba(6, 17, 31, 0.78);
  stroke-width: 7px;
  font-size: 27px;
  font-weight: 950;
}

.acc-mode-event-arc {
  fill: var(--event-color);
  stroke: rgba(255, 255, 255, 0.9);
  stroke-width: 2.5;
  filter: drop-shadow(0 8px 12px rgba(15, 23, 42, 0.32));
}

.acc-mode-event-arc--full {
  opacity: 0.88;
  stroke-width: 2;
}

.acc-mode-event-control {
  cursor: pointer;
  outline: none;
}

.acc-mode-marker-chain {
  fill: none;
  stroke: var(--event-color);
  stroke-linecap: round;
  stroke-width: 4;
  opacity: 0.38;
}

.acc-mode-marker {
  fill: var(--event-color);
  stroke: rgba(255, 255, 255, 0.96);
  stroke-width: 3;
  filter: drop-shadow(0 7px 9px rgba(15, 23, 42, 0.24));
}

.acc-mode-marker--lead {
  stroke: rgba(15, 23, 42, 0.78);
  stroke-width: 3.2;
}

.acc-mode-marker-number,
.acc-mode-event-label--token {
  fill: #ffffff;
  text-anchor: middle;
  dominant-baseline: middle;
  paint-order: stroke;
  stroke: rgba(15, 23, 42, 0.66);
  stroke-width: 3px;
  font-size: 15px;
  font-weight: 950;
  letter-spacing: 0;
  pointer-events: none;
}

.acc-mode-event-token-bg {
  fill: rgba(15, 23, 42, 0.24);
  stroke: rgba(255, 255, 255, 0.88);
  stroke-width: 2;
}

.acc-mode-event-hit {
  fill: rgba(255, 255, 255, 0);
  pointer-events: all;
}

.acc-mode-event-control:hover .acc-mode-event-arc,
.acc-mode-event-control:focus-visible .acc-mode-event-arc,
.acc-mode-event-control.is-selected .acc-mode-event-arc {
  stroke: rgba(15, 23, 42, 0.86);
  stroke-width: 4;
}

.acc-mode-event-control:hover .acc-mode-event-label,
.acc-mode-event-control:focus-visible .acc-mode-event-label,
.acc-mode-event-control.is-selected .acc-mode-event-label,
.acc-mode-event-control:hover .acc-mode-marker,
.acc-mode-event-control:focus-visible .acc-mode-marker,
.acc-mode-event-control.is-selected .acc-mode-marker {
  stroke: rgba(2, 6, 23, 0.88);
}

.acc-mode-event-label {
  fill: #ffffff;
  stroke: rgba(15, 23, 42, 0.68);
  stroke-width: 4px;
  font-size: 15px;
  font-weight: 950;
}

.acc-mode-event-label--time {
  font-size: 14px;
  stroke-width: 3.6px;
}

.acc-mode-center {
  fill: #ffffff;
  stroke: #cbd5e1;
  stroke-width: 4;
}

.acc-mode-center-text {
  fill: #111827;
  text-anchor: middle;
  font-size: 31px;
  font-weight: 950;
  letter-spacing: 0;
}

.app[data-acc-mode]:not([data-acc-mode="annual"]) .details-card > :not(.acc-mode-details) {
  display: none !important;
}

.app[data-acc-mode="annual"] .acc-mode-details {
  display: none !important;
}

.acc-mode-details {
  display: grid;
  gap: 16px;
}

.acc-mode-details__title {
  display: flex;
  gap: 14px;
  align-items: center;
}

.acc-mode-details__title > span {
  display: grid;
  width: 58px;
  height: 58px;
  border: 4px solid rgba(255, 255, 255, 0.75);
  border-radius: 8px;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(180deg, var(--active-accent), var(--active-accent-strong));
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.2);
  padding: 4px;
  font-size: 0.66rem;
  font-weight: 950;
  line-height: 1.05;
  overflow-wrap: anywhere;
  text-align: center;
}

.acc-mode-details__title p {
  margin: 0 0 4px;
  color: #526173;
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.acc-mode-details__title h2 {
  margin: 0;
  color: #111827;
  font-size: 1.55rem;
  line-height: 1.12;
  letter-spacing: 0;
}

.acc-mode-details__intro {
  margin: 0;
  color: #253246;
  line-height: 1.45;
}

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

.acc-mode-details__metrics div {
  border: 1px solid #d7dee9;
  border-radius: 8px;
  padding: 12px;
  background: #f8fafc;
}

.acc-mode-details__metrics strong,
.acc-mode-details__metrics span {
  display: block;
}

.acc-mode-details__metrics strong {
  min-height: 1.8em;
  color: #111827;
  font-size: 1.05rem;
  line-height: 1.1;
}

.acc-mode-details__metrics span {
  margin-top: 4px;
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.acc-mode-details__list {
  display: grid;
  gap: 10px;
}

.acc-mode-details__list article {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 10px;
  border: 1px solid #d7dee9;
  border-radius: 8px;
  padding: 11px;
  background: #ffffff;
  cursor: pointer;
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.acc-mode-details__list article:hover,
.acc-mode-details__list article:focus-visible,
.acc-mode-details__list article.is-selected {
  border-color: #0ea5e9;
  background: #f0faff;
  box-shadow: 0 8px 20px rgba(14, 165, 233, 0.16);
  outline: none;
}

.acc-mode-details__list article > span {
  grid-row: 1 / span 3;
  display: grid;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  place-items: center;
  color: #ffffff;
  background: var(--event-color);
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.18);
  font-size: 0.78rem;
  font-weight: 950;
}

.acc-mode-details__list small {
  display: block;
  color: #0f7490;
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.acc-mode-details__list strong {
  display: block;
  margin-top: 2px;
  color: #111827;
  font-size: 0.96rem;
  line-height: 1.14;
}

.acc-mode-details__list p {
  margin: 5px 0 0;
  color: #526173;
  font-size: 0.82rem;
  line-height: 1.35;
}

@media (max-width: 1400px) {
  .topbar {
    grid-template-columns: minmax(165px, 0.7fr) minmax(185px, 210px) auto auto auto;
  }

  .brand h1 {
    max-width: 175px;
  }

  .topbar__nav button,
  .wheel-nudge button,
  .button {
    padding-inline: 8px;
  }

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

@media (max-width: 980px) {
  .acc-settings-panel__modes,
  .acc-settings-panel__body,
  .acc-template-grid {
    grid-template-columns: 1fr;
  }

  .acc-settings-panel__summary {
    max-width: none;
    text-align: left;
  }
}
