/* The preview follows the app's GPUI popup (src/popup): the site popup is
   450px for the app's 360 DIP, so every DIP value is scaled by 1.25. */
.popup-mock {
  --ct-accent: #fb9a44;
  --ct-text: #fff;
  --ct-secondary: rgb(255 255 255 / .773);
  --ct-track: rgb(255 255 255 / .55);
  --ct-thumb-ring: #454545;
  --ct-divider: rgb(255 255 255 / .08);
  --ct-footer: rgb(0 0 0 / .18);
  --ct-hover: rgb(255 255 255 / .06);
  --ct-backdrop: linear-gradient(180deg, rgb(33 32 33 / .95) 8%, rgb(43 28 26 / .95) 52%, rgb(33 32 32 / .95) 90%);
  width: 450px;
  max-width: calc(100% - 32px);
  border-radius: 10px;
  border: 1px solid rgb(255 255 255 / .08);
  box-shadow: 0 24px 70px #0000006e;
  background: var(--ct-backdrop);
  backdrop-filter: blur(40px) saturate(140%);
  color: var(--ct-text);
  font-family: "Segoe UI Variable Text", "Segoe UI", var(--font);
  pointer-events: auto;
}

html[data-theme="light"] .popup-mock {
  --ct-accent: #d76a0f;
  --ct-text: #1b1b1b;
  --ct-secondary: rgb(0 0 0 / .62);
  --ct-track: rgb(0 0 0 / .42);
  --ct-thumb-ring: #fff;
  --ct-divider: rgb(0 0 0 / .08);
  --ct-footer: rgb(0 0 0 / .04);
  --ct-hover: rgb(0 0 0 / .05);
  --ct-backdrop: linear-gradient(180deg, rgb(249 246 244 / .96) 8%, rgb(250 240 232 / .96) 52%, rgb(247 245 243 / .96) 90%);
  border-color: rgb(0 0 0 / .1);
  box-shadow: 0 24px 70px #0000002e;
}

.popup-mock:not(.is-open) {
  pointer-events: none;
}

.ic {
  display: inline-block;
  flex: none;
  width: 20px;
  height: 20px;
  background: currentColor;
  -webkit-mask: var(--ic) center / contain no-repeat;
  mask: var(--ic) center / contain no-repeat;
}

.ct-display {
  padding: 22px 30px 18px;
}

.ct-display + .ct-display {
  border-top: 1px solid var(--ct-divider);
}

.ct-display-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 30px;
  margin-bottom: 4px;
}

.ct-display-name {
  font-size: 17px;
  font-weight: 600;
}

.ct-display-actions {
  display: flex;
  gap: 6px;
  color: var(--ct-secondary);
}

.ct-row {
  display: grid;
  grid-template-columns: 24px 1fr 40px;
  align-items: center;
  gap: 22px;
  height: 43px;
  color: var(--ct-secondary);
}

.ct-value {
  color: var(--ct-text);
  font-size: 16px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.ct-slider {
  --value: 50%;
  width: 100%;
  height: 24px;
  margin: 0;
  background: transparent;
  cursor: default;
  -webkit-appearance: none;
  appearance: none;
}

.ct-slider:focus-visible {
  outline: 2px solid var(--ct-accent);
  outline-offset: 2px;
  border-radius: 12px;
}

.ct-slider::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(to right, var(--ct-accent) var(--value), var(--ct-track) var(--value));
}

.ct-slider::-moz-range-track {
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(to right, var(--ct-accent) var(--value), var(--ct-track) var(--value));
}

.ct-slider::-webkit-slider-thumb {
  width: 24px;
  height: 24px;
  margin-top: -10px;
  border: 6px solid var(--ct-thumb-ring);
  border-radius: 50%;
  background: var(--ct-accent);
  box-shadow: 0 0 0 1px rgb(0 0 0 / .08);
  transition: border-width 120ms ease;
  -webkit-appearance: none;
  appearance: none;
}

.ct-slider::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: 6px solid var(--ct-thumb-ring);
  border-radius: 50%;
  background: var(--ct-accent);
  transition: border-width 120ms ease;
}

.ct-slider:hover::-webkit-slider-thumb {
  border-width: 5px;
}

.ct-slider:active::-webkit-slider-thumb {
  border-width: 7px;
}

.ct-footer {
  display: flex;
  justify-content: space-between;
  padding: 10px 14px;
  background: var(--ct-footer);
  border-top: 1px solid var(--ct-divider);
}

.ct-footer-group {
  display: flex;
  gap: 7px;
}

.ct-icon-btn {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--ct-secondary);
  cursor: default;
}

.ct-icon-btn:hover:not(:disabled) {
  background: var(--ct-hover);
  color: var(--ct-text);
}

.ct-icon-btn.is-active {
  color: var(--ct-accent);
}

.ct-icon-btn:disabled {
  opacity: .9;
}

/* The tray glyph, white like the app's light-on-dark tray icon. */
.ct-tray {
  display: grid;
  place-items: center;
  width: 40px;
  color: #fff;
}

.ct-tray .ic {
  width: 18px;
  height: 18px;
}

html[data-theme="light"] .ct-tray {
  color: #1b1b1b;
}

.feature-chips {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 12px;
  line-height: 1.3;
}

.feature-chips li {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px 10px;
}

.feature-chips li + li {
  border-left: 1px solid var(--border);
}

.feature-chips .ic {
  width: 22px;
  height: 22px;
  color: var(--text);
}

@media (max-width: 640px) {
  .feature-chips {
    grid-template-columns: repeat(3, 1fr);
  }

  .feature-chips li:nth-child(4) {
    border-left: 0;
  }

  .feature-chips li:nth-child(n + 4) {
    border-top: 1px solid var(--border);
  }
}

/* The page plays the monitor: the first display's slider dims the screen. */
.ct-dim {
  position: absolute;
  inset: 0;
  z-index: 60;
  border-radius: inherit;
  background: #000;
  opacity: var(--ct-dim, 0);
  pointer-events: none;
  transition: opacity 160ms linear;
}

/* The left column scrolls inside the screen; the backdrop, popup and taskbar stay put. */
.hero-scroll {
  position: absolute;
  inset: 0 0 60px;
  z-index: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, transparent 52px, #000 116px, #000 calc(100% - 24px), transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0, transparent 52px, #000 116px, #000 calc(100% - 24px), transparent 100%);
}

.hero-scroll .hero-grid {
  min-height: 100%;
  padding-top: 4rem;
}

.hero-more {
  width: min(100% - 2.5rem, var(--shell));
  margin-inline: auto;
  padding-bottom: 5rem;
}

.more-section {
  width: min(100%, 43rem);
  padding: 3.5rem 0 1rem;
}

.more-section h2 {
  margin: 0;
  color: var(--text);
  font-size: clamp(1.7rem, 2.6vw, 2.3rem);
  font-weight: 560;
  letter-spacing: -0.04em;
  line-height: 1.1;
}

.more-lede {
  max-width: 37rem;
  margin: 0.75rem 0 1.75rem;
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.55;
}

.more-note {
  margin: 14px 0 0;
  color: var(--text-tertiary);
  font-size: 12px;
}

.more-shot {
  margin: 0 0 16px;
}

.more-shot img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 18px 50px rgb(0 0 0 / 0.35);
}

.weight-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.weight-card {
  padding: 20px 22px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: color-mix(in srgb, var(--bg-soft) 70%, transparent);
  backdrop-filter: blur(12px);
}

.weight-label {
  margin: 0;
  color: var(--text-tertiary);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.weight-ratio {
  margin: 6px 0 16px;
  color: var(--text);
  font-size: 17px;
  font-weight: 500;
}

.weight-ratio strong {
  margin-right: 4px;
  color: #fb9a44;
  font-size: 40px;
  font-weight: 700;
  letter-spacing: -0.03em;
}

html[data-theme="light"] .weight-ratio strong {
  color: #d76a0f;
}

.weight-bars {
  display: grid;
  gap: 10px;
  margin: 0;
}

.weight-bars div {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

.weight-bars dt {
  color: var(--text-secondary);
}

.weight-bars dd {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  margin: 0;
  color: var(--text);
  font-weight: 600;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.weight-bar {
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--text-tertiary) var(--w), var(--accent-soft) var(--w));
}

.weight-bars .is-candle .weight-bar {
  background: linear-gradient(90deg, #fb9a44 max(var(--w), 6px), var(--accent-soft) max(var(--w), 6px));
}

@media (max-width: 900px) {
  .hero-scroll .hero-grid {
    padding-top: clamp(4rem, 11vh, 7rem);
  }

  .hero-more {
    width: min(100% - 1.5rem, var(--shell));
  }
}

@media (max-width: 720px) {
  .weight-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}
