:root {
  font-family: 'Google Sans Flex', sans-serif;
  font-synthesis: none;
}
::selection {
  background: rgba(0, 221, 245, 0.35);
  color: #fff;
}
* {
  box-sizing: border-box;
}
html, body {
  height: 100%;
  overflow: hidden;
}
body {
  margin: 0;
}
button,
input,
select {
  font: inherit;
  font-family: 'Google Sans Flex', sans-serif;
}
button {
  cursor: pointer;
  color: inherit;
}
button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}
button {
  border: 0;
  background: none;
}
button svg,
svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
button {
  transition:
    background-color 0.15s,
    box-shadow 0.15s,
    scale 0.15s;
}
button:active {
  scale: 0.96;
}
button:disabled {
  opacity: 0.35;
  cursor: default;
}
:focus {
  outline: none;
}
:focus:not(:focus-visible) {
  outline: none !important;
}
button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--accent, #00ddf5);
  outline-offset: 2px;
}
input:not([type="range"]):focus,
select:focus,
input:not([type="range"]):focus-visible,
select:focus-visible {
  outline: none;
  border-color: var(--accent, #00ddf5);
  box-shadow: 0 0 0 3px rgba(0, 221, 245, 0.25);
}
canvas:focus,
canvas:focus-visible {
  outline: none !important;
  box-shadow: none !important;
}
button:hover {
  background-color: #edf0e9;
}
button.active {
  background: rgba(0, 221, 245, 0.15);
}
button[hidden],
[hidden] {
  display: none !important;
}
.icon-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}
.studio {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 22px;
  padding: 22px;
  height: 100dvh;
  min-height: 0;
  grid-template-rows: minmax(0, 1fr);
  max-width: 2400px;
  margin: auto;
}
.properties {
  border-radius: 21px;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}
.brand {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 28px 20px;
}
.brand-logo {
  display: block;
  height: 36px;
  width: auto;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
}
.create-footer {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
  padding: 40px 0;
}
.create-footer-logomark {
  display: block;
  height: 48px;
  width: auto;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
}
.create-footer-link {
  font-size: 8px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.2px;
  color: var(--subtext);
  text-decoration: none;
  transition: color 0.16s ease;
}
.create-footer-link:hover {
  color: var(--ink);
  text-decoration: underline;
}
.brand h1 {
  letter-spacing: -0.5px;
  font-size: 22px;
  font-weight: 700;
  white-space: nowrap;
  margin: 0;
}
.controls {
  position: static;
  min-height: 0;
  flex: 1;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
  padding: 0 24px 72px;
  overflow-x: hidden;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--scroll-thumb, #dbe0d4) transparent;
  contain: content;
  will-change: scroll-position;
}
.control-section {
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
}
.control-section:first-child {
  padding-top: 0;
}
#section-time {
  padding-top: 24px;
}
#section-style {
  padding-top: 16px;
}
.panel-view > .control-section:last-child,
.panel-view > .control-section:last-of-type,
#aurora-section {
  border-bottom: none;
}
#aurora-section {
  padding-bottom: 0;
}
#aurora-section .control-note:last-child {
  margin-bottom: 0;
}
.control-section > *:last-child {
  margin-bottom: 0 !important;
}
h2 {
  font-size: 13.5px;
  font-weight: 650;
  letter-spacing: -0.2px;
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
h2 svg {
  width: 17px;
  height: 17px;
}
.label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  line-height: 21px;
  color: #687068;
  margin-bottom: 10px;
}
.label-row output {
  font-variant-numeric: tabular-nums;
  color: #414c3d;
  font-weight: 500;
  font-size: 12px;
  background: #f4f6f0;
  padding: 0 6px;
  border-radius: 4px;
}
#hour-output {
  font: inherit;
  font-variant-numeric: tabular-nums;
  color: inherit;
  background: none;
  padding: 0;
  line-height: inherit;
}
input[type="range"] {
  width: 100%;
  margin: 0;
  display: block;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  outline: none;
  border: none;
}
/* Every slider except time of day is a pull slider: the track is a glass bar
   filled from the left by --progress, with the label and value laid over it. */
input[type="range"]:not(.time-range) {
  position: absolute;
  inset: 0;
  height: var(--pull-h, 44px);
  border-radius: inherit;
  background: transparent;
  padding: 0;
}
input[type="range"]:not(.time-range)::-webkit-slider-runnable-track {
  width: 100%;
  height: var(--pull-h, 44px);
  border-radius: inherit;
  border: none;
  background: linear-gradient(to right, var(--pull-fill) var(--progress, 0%), var(--pull-track) var(--progress, 0%));
}
input[type="range"]:not(.time-range)::-moz-range-track {
  width: 100%;
  height: var(--pull-h, 44px);
  border-radius: inherit;
  border: none;
  background: linear-gradient(to right, var(--pull-fill) var(--progress, 0%), var(--pull-track) var(--progress, 0%));
}
/* A thin grip at the fill's edge, shown while pointing, focused or dragging. */
input[type="range"]:not(.time-range)::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 4px;
  height: 22px;
  margin-top: 11px;
  border-radius: 999px;
  background: #fff;
  border: none;
  box-shadow: var(--pull-thumb-shadow);
  cursor: pointer;
  opacity: 0;
  transform: scale(0.65);
  transition: opacity 140ms ease, transform 140ms ease;
}
input[type="range"]:not(.time-range)::-moz-range-thumb {
  width: 4px;
  height: 22px;
  border-radius: 999px;
  background: #fff;
  border: none;
  box-shadow: var(--pull-thumb-shadow);
  cursor: pointer;
  opacity: 0;
  transform: scale(0.65);
  transition: opacity 140ms ease, transform 140ms ease;
}
input[type="range"]:not(.time-range):hover::-webkit-slider-thumb,
input[type="range"]:not(.time-range):focus-visible::-webkit-slider-thumb,
input[type="range"]:not(.time-range):active::-webkit-slider-thumb {
  opacity: 1;
  transform: scale(1);
}
input[type="range"]:not(.time-range):hover::-moz-range-thumb,
input[type="range"]:not(.time-range):focus-visible::-moz-range-thumb,
input[type="range"]:not(.time-range):active::-moz-range-thumb {
  opacity: 1;
  transform: scale(1);
}
/* Ticks and labels span the globe's travel (half a globe in from each edge), so
   00:00 and 24:00 sit under the globe at the ends. Labels centre on zero-width
   grid tracks at 0/25/50/75/100 %. */
.time-ticks {
  display: flex;
  justify-content: space-between;
  margin: 9px calc(var(--globe-size) / 2) 0;
}
.time-ticks i {
  width: 1px;
  height: 3px;
  background: #d1d5cb;
}
.time-ticks i:nth-child(6n + 1) {
  height: 5px;
}
.range-labels {
  display: grid;
  grid-template-columns: repeat(5, 0);
  justify-content: space-between;
  font-size: 9px;
  color: #687068;
  margin: 5px calc(var(--globe-size) / 2) 0;
}
.range-labels span {
  justify-self: center;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.time-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 0 0 16px;
}
.control-section .time-header h2 {
  margin: 0;
}
.time-caption {
  margin: 0;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--secondary, #687068);
}
.season-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin: 0 0 24px;
}
.season {
  border: 1px solid #e6e9e0;
  border-radius: 8px;
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 9px;
  padding: 12px 3px 10px;
  font-size: 11px;
  color: #687068;
}
.season.active {
  border-color: rgba(0, 221, 245, 0.35);
  color: #00ddf5;
  background: rgba(0, 221, 245, 0.15);
}
.season svg {
  width: 19px;
  height: 19px;
}
.text-button {
  display: flex;
  align-items: center;
  gap: 5px;
  border-radius: 12px;
  font-size: 11px;
  padding: 0 3px;
}
.text-button svg {
  width: 13px;
  height: 13px;
}
.presets {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 7px;
  margin: 0 0 24px;
}
.preset {
  padding: 0;
  border-radius: 12px;
  background: transparent !important;
  position: relative;
  min-width: 0;
}
.preset canvas {
  width: 100%;
  height: 43px;
  border-radius: 6px;
  display: block;
  background: #a9cde2;
  box-shadow: inset 0 0 0 1px #00000014;
}
.preset.active canvas {
  box-shadow: 0 0 0 2px #00c4dc;
}
.preset span {
  display: block;
  font-size: 10px;
  margin-top: 9px;
  color: #687068;
  white-space: nowrap;
}
.preset.active span {
  color: #00ddf5;
}
.celestial-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 7px;
  margin: 0 0 12px;
}
.celestial-options.celestial-bodies {
  grid-template-columns: repeat(3, 1fr);
}
.celestial {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 12px;
  text-align: center;
  color: #687068;
}
.celestial svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
}
.season span,
.celestial span {
  font-size: 12px;
  font-weight: 550;
}
.celestial.active {
  color: #00ddf5;
  border-color: rgba(0, 221, 245, 0.35);
  background: rgba(0, 221, 245, 0.15);
}
.eclipse-card {
  margin: 24px 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  transition: border-color 0.15s, background-color 0.15s;
}
.eclipse-card.active {
  border-color: rgba(0, 221, 245, 0.35);
  background: rgba(0, 221, 245, 0.08);
}
.eclipse-header {
  margin-bottom: 8px;
}
.eclipse-card .control-note {
  margin: 0;
}
.eclipse-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
}
.eclipse-title svg {
  width: 17px;
  height: 17px;
}
.toggle-switch {
  position: relative;
  flex: 0 0 auto;
  width: 44px;
  height: 24px;
  padding: 2px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--line, #e2e6dd);
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s;
}
.toggle-switch:hover {
  background: #d5dbcf;
}
.toggle-switch[aria-checked="true"] {
  background: #00a4b8;
  border-color: #008899;
}
.switch-track {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
}
.switch-thumb {
  position: absolute;
  top: 0;
  left: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.22);
  transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}
.toggle-switch[aria-checked="true"] .switch-thumb {
  transform: translateX(20px);
}
#lunar-eclipse-card.active {
  border-color: rgba(226, 140, 115, 0.35);
  background: rgba(226, 140, 115, 0.08);
}
#lunar-eclipse-toggle[aria-checked="true"] {
  background: #b84c32;
  border-color: #a23f27;
}
#eclipse-tuning,
#lunar-eclipse-tuning {
  margin-top: 10px;
  padding-top: 6px;
  border-top: 1px dashed var(--line);
}
.styles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}
.style {
  font-size: 11px;
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 6px;
  padding: 9px 10px;
}
.style.active {
  background: rgba(0, 221, 245, 0.15);
  border-color: rgba(0, 221, 245, 0.35);
}
.style-thumb {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: #a9cde2;
  box-shadow: inset 0 0 0 1px #00000014;
}
.aurora-modes {
  grid-template-columns: repeat(2, 1fr);
  margin: 0 0 12px;
}
.aurora-presets {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--control-grid-gap, 10px);
  margin: 0 0 24px;
}
.aurora-preset-wrap {
  position: relative;
  min-width: 0;
  container-type: inline-size;
}
.aurora-preset {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto;
  width: 100%;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent !important;
}
.aurora-preset canvas,
.aurora-preset-shuffle {
  grid-column: 1;
  grid-row: 1;
}
.aurora-preset canvas {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 60.5 / 43;
  border-radius: 12px;
  background: #07111d;
  box-shadow: inset 0 0 0 1px var(--line);
  outline: none;
}
.aurora-preset span {
  grid-column: 1;
  grid-row: 2;
  display: block;
  margin-top: 9px;
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.aurora-preset.active canvas {
  box-shadow: 0 0 0 2px var(--track-fill);
}
.aurora-preset.active span {
  color: var(--accent-ink);
}
.aurora-palettes {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 7px;
  margin: 0 0 24px;
}
.aurora-palette {
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  padding: 10px;
  background: transparent;
  cursor: pointer;
}
.aurora-palette.active {
  background: rgba(0, 221, 245, 0.15);
  border-color: rgba(0, 221, 245, 0.35);
}
.aurora-presets .style.active {
  background: rgba(0, 221, 245, 0.15);
  border-color: rgba(0, 221, 245, 0.35);
  color: #00ddf5;
}
.palette-swatch {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 6px rgba(0, 0, 0, 0.2);
}
.swatch-emerald {
  background: linear-gradient(135deg, #0ceb6b, #10985c);
}
.swatch-crimson {
  background: linear-gradient(135deg, #eb1a47, #18da6d);
}
.swatch-magenta {
  background: linear-gradient(135deg, #18da6d, #db24b5);
}
.swatch-sar {
  background: linear-gradient(135deg, #f02534, #a4101d);
}
.atmospheric-phenomena-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin: 0 0 24px;
}
.weather-modes {
  grid-template-columns: repeat(2, 1fr);
  margin: 0 0 12px;
}
.weather-phenomena-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 0 0 24px;
}
.atmos-item {
  font-size: 11px;
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border-radius: 12px;
  padding: 8px 4px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease,
    box-shadow 0.15s ease,
    scale 0.15s ease;
  text-align: center;
  min-height: 48px;
}
.atmos-item-icon {
  font-size: 14px;
  line-height: 1;
}
.atmos-item-label {
  font-size: 10px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.atmos-item.active,
.atmos-item.triggered,
.weather-item.active,
.weather-item.triggered {
  background: rgba(0, 221, 245, 0.15);
  border-color: rgba(0, 221, 245, 0.35);
  color: #00ddf5;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.search-field {
  display: flex;
  border: 1px solid #dce2d4;
  border-radius: 7px;
  overflow: hidden;
}
.search-field input {
  min-width: 0;
  width: 100%;
  border: 0;
  font-size: 12px;
  padding: 10px;
  background: transparent;
  color: var(--ink);
}
.search-field button {
  padding: 8px;
  display: grid;
  place-items: center;
}
.search-field svg {
  width: 16px;
  height: 16px;
}
.location-result {
  width: 100%;
  text-align: left;
  padding: 10px 5px;
  font-size: 12px;
  border-bottom: 1px solid var(--line);
}
.location-result small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  margin-top: 3px;
}
.panel-footer {
  flex-shrink: 0;
  margin-top: auto;
  padding: 17px 24px;
  border-top: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 10px;
  color: #687068;
  background: #fff;
}
.canvas-panel {
  position: relative;
  overflow: hidden;
  border: none;
  outline: none;
  border-radius: 21px;
  background: transparent;
  isolation: isolate;
  min-width: 0;
}
#sky-canvas {
  display: block;
  width: 100%;
  height: 100%;
  border: none;
  outline: none;
  touch-action: pan-y;
}
.canvas-top {
  position: absolute;
  top: 25px;
  left: 29px;
  right: 25px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  pointer-events: none;
}
.scene-label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: #fff;
  text-shadow: 0 1px 5px #21446025;
  padding-top: 1px;
}
.scene-title {
  font-weight: 600;
  font-size: 13px;
  letter-spacing: -0.2px;
}
.scene-label #scene-detail {
  display: inline-block;
  min-width: 28ch;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  opacity: 0.8;
}
.export-wrap {
  position: relative;
  flex-shrink: 0;
  pointer-events: auto;
}
.export-button {
  display: flex;
  gap: 9px;
  align-items: center;
  background: #fffdf7ef;
  color: #344333;
  border: 1px solid #ffffff70;
  border-radius: 9px;
  padding: 12px 15px;
  font-size: 12px;
  font-weight: 500;
  backdrop-filter: blur(16px);
}
.export-button svg {
  width: 15px;
  height: 15px;
}
.export-button:hover {
  background: #fff;
}
.canvas-bottom {
  position: absolute;
  bottom: 26px;
  left: 29px;
  right: 26px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  pointer-events: none;
}
.canvas-toolbar {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px;
  border-radius: 11px;
  background: #fffefaeb;
  border: 1px solid #ffffff65;
  backdrop-filter: blur(16px);
  pointer-events: auto;
}
.tool svg {
  width: 17px;
  height: 17px;
}

#canvas-error {
  position: absolute;
  top: 40%;
  left: 10%;
  right: 10%;
  padding: 24px;
  background: #fffef5;
  border-radius: 12px;
  line-height: 1.6;
  font-size: 14px;
}
.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;
}
.canvas-panel:fullscreen {
  border-radius: 0;
  width: 100vw;
  height: 100vh;
}
.canvas-panel:-webkit-full-screen {
  border-radius: 0;
  width: 100vw;
  height: 100vh;
}
.canvas-panel.is-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 5;
  border-radius: 0;
}
:fullscreen .canvas-top,
.canvas-panel:fullscreen .canvas-top,
.canvas-panel.is-fullscreen .canvas-top {
  display: none !important;
}
:-webkit-full-screen .canvas-top,
.canvas-panel:-webkit-full-screen .canvas-top {
  display: none !important;
}
.night .scene-label {
  color: #e8edfa;
}
@media (min-height: 980px) {
  .control-section {
    padding-top: 36px;
    padding-bottom: 36px;
  }
  .brand {
    padding-top: 30px;
    padding-bottom: 30px;
  }
  .preset canvas {
    height: 51px;
  }
  .styles .style {
    padding-top: 12px;
    padding-bottom: 12px;
  }
}
@media (min-width: 1700px) {
  .studio {
    grid-template-columns: 350px minmax(0, 1fr);
    padding: 28px;
    gap: 28px;
  }
  .controls {
    padding: 0 27px;
  }
  .brand {
    padding-left: 27px;
    padding-right: 27px;
  }
  .preset canvas {
    height: 51px;
  }
  .season,
  .style {
    font-size: 12px;
  }
  .label-row {
    font-size: 13px;
  }
  .panel-footer {
    font-size: 11px;
  }
}
@media (max-width: 1050px) {
  .studio {
    grid-template-columns: 290px minmax(0, 1fr);
    gap: 14px;
    padding: 14px;
  }
  .controls {
    padding: 0 19px;
  }
  .brand {
    padding: 22px 18px;
  }
  .brand h1 {
    font-size: 20px;
  }
  .canvas-bottom {
    justify-content: flex-end;
  }
  .canvas-top {
    left: 22px;
    right: 20px;
  }
}
@media (max-width: 700px) {
  .studio {
    padding: 10px;
    gap: 12px;
    height: 100dvh;
    min-height: 0;
    grid-template-columns: 1fr;
    display: flex;
    flex-direction: column;
  }
  .canvas-panel {
    order: -1;
    height: 44%;
    min-height: 0;
    border-radius: 17px;
    flex-shrink: 0;
  }
  .properties {
    border-radius: 17px;
    min-height: 0;
    flex: 1;
    overflow: hidden;
  }
  .brand {
    padding: 20px 23px;
  }
  .brand h1 {
    font-size: 23px;
  }
  .controls {
    overflow-x: hidden;
    overflow-y: auto;
    padding: 0 23px 72px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 25px;
  }
  .control-section {
    padding: 23px 0;
  }
  .control-section:nth-child(3) {
    grid-column: 1/-1;
  }
  .control-section:nth-child(4) {
    grid-column: 1/-1;
  }
  .presets {
    gap: 11px;
  }
  .preset canvas {
    height: auto;
    aspect-ratio: 60.5 / 43;
  }
  .preset span,
  .season,
  .style {
    font-size: 12px;
  }
  .label-row {
    font-size: 13px;
  }
  .styles {
    grid-template-columns: repeat(4, 1fr);
  }
  .style {
    flex-direction: column;
    gap: 4px;
    padding: 11px 4px;
  }
  .canvas-top {
    left: 20px;
    top: 20px;
    right: 20px;
  }
  .canvas-bottom {
    bottom: 24px;
    left: 20px;
    right: 15px;
  }
  .scene-label {
    gap: 5px;
  }
  .export-button {
    padding: 11px 12px;
  }
  .control-section h2 {
    font-size: 14px;
  }
  .range-labels {
    font-size: 8px;
  }
  .season-options {
    gap: 4px;
  }
  .season {
    font-size: 10px;
    padding: 11px 2px;
  }
  .time-header {
    margin-bottom: 14px;
  }
  .time-caption {
    font-size: 11px;
  }
}
@media (max-width: 380px) {
  .controls {
    display: block;
  }
  .season {
    flex-direction: row;
    justify-content: center;
    font-size: 12px;
  }
  .range-labels {
    font-size: 10px;
  }
}
.label-row,
.label-row output,
.season,
.style,
.celestial,
.export-button {
  font-size: 14px;
}
.preset span,
.panel-footer,
.range-labels {
  font-size: 10px;
}
.text-button {
  font-size: 12px;
}
.export-button {
  min-height: 44px;
}
.tool {
  width: 38px;
  height: 38px;
}
.search-field input,
.location-result,
.export-menu label,
.export-menu select {
  font-size: 14px;
}
.export-menu button {
  font-size: 14px;
}
.export-menu button span {
  font-size: 12px;
}
.location-result small {
  font-size: 12px;
}
@media (max-width: 700px) {
  .controls {
    display: block;
  }
  .season {
    flex-direction: row;
    justify-content: center;
    font-size: 13px;
    gap: 7px;
    padding: 14px 4px;
  }
  .styles {
    grid-template-columns: 1fr 1fr;
  }
  .style {
    flex-direction: row;
    padding: 13px;
    gap: 10px;
  }
  .preset span {
    font-size: 12px;
  }
  .range-labels {
    font-size: 9px;
  }
  .scene-label #scene-detail {
    font-size: 9px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}

/* Both panes belong to the viewport; only properties own a scroll area. */
.control-note {
  margin: 12px 0 16px;
  font-size: 11.5px;
  font-weight: 400;
  line-height: 1.45;
  letter-spacing: -0.1px;
  color: var(--subtext);
}
.control-note:empty {
  display: none;
  margin: 0;
}
.control-note + .control-note {
  margin-top: -8px;
  margin-bottom: 16px;
}
.control-note a {
  color: var(--secondary);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.15s ease;
}
.control-note a:hover {
  color: var(--ink);
}
#aurora-status,
#atmospheric-status,
#weather-effects-status {
  margin: 10px 0 18px;
}
.celestial-note {
  margin-bottom: 24px;
}
#night-note {
  margin: 0 0 12px;
}
#style-description {
  margin: 12px 0 16px;
}
#style-description:empty {
  display: none;
  margin: 0;
}
.tuning-control {
  --pull-h: 44px;
  position: relative;
  height: var(--pull-h);
  margin: 8px 0 0;
  border-radius: 12px;
  border: 0.5px solid var(--glass-border);
  box-shadow: inset 0 0.5px 0 var(--glass-rim), inset 0 -0.5px 0 var(--glass-low-rim);
  overflow: hidden;
  isolation: isolate;
}
.tuning-control:first-child { margin-top: 0; }
.tuning-group { margin-top: 18px; }
.tuning-group:first-child { margin-top: 0; }
.tuning-group-heading {
  margin: 0 0 8px 4px;
  font-size: 9px;
  font-weight: 300;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--secondary);
  opacity: 0.85;
}
.tuning-group .tuning-control:first-child { margin-top: 0; }
/* JS builds these sliders after first paint; --rows (index.html) reserves their height. */
[id$="-tuning"] { min-height: calc(var(--rows, 0) * 52px - 8px); }
.tuning-control:has(input:focus-visible) { box-shadow: 0 0 0 2px var(--focus); }
/* Touch: app.js drives these from the wrapper, see touchSlide. */
@media (pointer: coarse) {
  .tuning-control,
  .time-range-wrap { touch-action: pan-y; }
  .tuning-control input[type="range"],
  .time-range-wrap input.time-range { pointer-events: none; }
  /* iOS zooms the page into any field set below 16px. */
  .control-section .text-field { font-size: 16px; }
}
.tuning-control .label-row {
  position: absolute;
  inset: 0;
  z-index: 1;
  margin: 0;
  padding: 0 14px;
  font-size: 13px;
  color: var(--secondary);
  pointer-events: none;
}
.tuning-control .label-row output {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  background: none;
  padding: 0;
}
.select-label { display: block; margin: 22px 0 8px; font-size: 13px; color: var(--secondary); }
.control-section select,
.control-section .text-field { width: 100%; min-height: 38px; background: #f9faf7; border: 1px solid var(--line); border-radius: 7px; color: var(--ink); padding: 7px 14px; font-size: 13px; font-family: 'Google Sans Flex', sans-serif; letter-spacing: normal; }
select option { font-family: 'Google Sans Flex', sans-serif; background: #141b20; color: var(--ink); }
.control-section .text-field:focus-visible { outline: 2px solid var(--accent-line, #00a4b8); outline-offset: 1px; }
/* One switch per line with its label, as the eclipse cards lay theirs out. */
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; font-size: 13px; color: var(--secondary); }
#ascii-options .control-note { margin: 8px 0 0; }
#sky-canvas { touch-action: none; }
.export-menu { max-height: calc(100dvh - 150px); overflow-y: auto; }
@media (max-width: 700px) {
  .brand { padding: 20px 20px; }
  .brand h1 { font-size: 20px; }
  .canvas-top { top: 14px; left: 16px; right: 14px; }
  .canvas-bottom { bottom: 16px; }
}
@media (max-height: 560px) {
  .studio { padding: 8px; gap: 8px; }
  .brand { padding-top: 10px; padding-bottom: 10px; }
  .panel-footer { padding-top: 8px; padding-bottom: 8px; }
}

/* Liquid Glass interface: a dedicated glass inspector sits beside the sky. */
:root {
  --app-background: #000;
  --glass-ambient-rgb: 139 194 226;
  --glass-fill: rgba(2, 7, 12, 0.46);
  --glass-border: rgba(195, 227, 246, 0.12);
  --glass-inner-line: rgba(242, 251, 255, 0.065);
  --glass-sheen: rgba(239, 250, 255, 0.028);
  --glass-rim: rgba(244, 251, 255, 0.1);
  --glass-low-rim: rgba(31, 87, 121, 0.21);
  --glass-ambient-strength: 0.09;
  --glass-reflection-strength: 0.055;
  --glass-directional-sheen: rgb(255 255 255 / 0.04);
  /* Sidebar Ambient Glare Controls: customize lighting, intensity, reach and balance */
  --sidebar-glare-opacity: 1;
  --sidebar-glare-tl-opacity: 1;
  --sidebar-glare-br-opacity: 1;
  --sidebar-glare-color: var(--glass-ambient-rgb);
  --sidebar-glare-strength: 0.09;
  --sidebar-glare-reflection-strength: 0.055;
  --sidebar-glare-size: 125% 78%;
  --sidebar-glare-reach: 58%;

  /* Glare aliases for quick developer control */
  --glare-opacity: var(--sidebar-glare-opacity);
  --glare-strength: var(--sidebar-glare-strength);
  --glare-reflection-strength: var(--sidebar-glare-reflection-strength);
  --glare-br-opacity: var(--sidebar-glare-br-opacity);
  --glare-tl-opacity: var(--sidebar-glare-tl-opacity);
  --glare-size: var(--sidebar-glare-size);
  --glare-reach: var(--sidebar-glare-reach);
  --glare-color: var(--sidebar-glare-color);
  --canvas-border: rgba(255, 255, 255, 0.025);
  --canvas-panel-shadow: none;
  --glass-filter: blur(30px) saturate(145%) contrast(1.08);
  --glass-shadow: 0 32px 80px rgba(0, 0, 0, 0.72), 0 12px 28px rgba(0, 0, 0, 0.42);
  --floating-fill: rgba(4, 6, 7, 0.7);
  --floating-border: rgba(255, 255, 255, 0.09);
  --floating-shadow: none;
  --floating-glass-fill: rgba(2, 7, 12, 0.18);
  --floating-icon-color: var(--ink);
  --floating-icon-opacity: 1;
  --floating-icon-disabled-opacity: 0.65;
  --menu-frost-bg:
    linear-gradient(145deg, rgba(255, 255, 255, 0.24) 0%, rgba(255, 255, 255, 0.08) 45%, rgba(255, 255, 255, 0.15) 100%),
    radial-gradient(120% 85% at 0% 0%, rgba(255, 255, 255, 0.28), transparent 60%),
    rgba(18, 24, 30, 0.38);
  --menu-frost-border: rgba(255, 255, 255, 0.18);
  --menu-frost-rim: rgba(255, 255, 255, 0.29);
  --menu-frost-filter: blur(40px) saturate(180%) contrast(1.05);
  --menu-control-bg: rgba(255, 255, 255, 0.13);
  --menu-control-border: rgba(255, 255, 255, 0.13);
  --menu-control-hover: rgba(255, 255, 255, 0.26);
  --menu-text-primary: #ffffff;
  --menu-text-secondary: rgba(255, 255, 255, 0.84);
  --menu-text-muted: rgba(255, 255, 255, 0.75);
  --line: rgba(255, 255, 255, 0.12);
  --muted: #aab4ae;
  --subtext: rgba(255, 255, 255, 0.52);
  --ink: #f4f7f5;
  --secondary: #d7ded9;
  --accent: #00ddf5;
  --accent-ink: #00ddf5;
  --accent-fill: rgba(0, 221, 245, 0.15);
  --accent-line: rgba(0, 221, 245, 0.35);
  --control-fill: rgba(255, 255, 255, 0.055);
  --control-hover: rgba(255, 255, 255, 0.1);
  --control-strong: rgba(255, 255, 255, 0.12);
  --track-fill: #00c4dc;
  --pull-track: rgba(255, 255, 255, 0.055);
  --pull-fill: rgba(255, 255, 255, 0.13);
  --pull-thumb-shadow: 0 1px 4px rgba(0, 0, 0, 0.55);
  --focus: var(--accent);
  --scroll-thumb: rgba(255, 255, 255, 0.12);
  color-scheme: dark;
}

body {
  color: var(--ink);
  background: var(--app-background);
}

.studio {
  position: relative;
  display: grid;
  grid-template-columns: 348px minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
  gap: 12px;
  width: 100%;
  max-width: none;
  height: 100dvh;
  min-height: 0;
  padding: 12px;
  background: var(--app-background);
}

.canvas-panel {
  position: relative;
  inset: auto;
  min-height: 0;
  border: 0.5px solid var(--canvas-border);
  outline: none;
  border-radius: 30px;
  background: transparent;
  box-shadow: var(--canvas-panel-shadow, none);
}

.properties {
  position: relative;
  z-index: 3;
  inset: auto;
  width: auto;
  color: var(--ink);
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 29%),
    linear-gradient(322deg, var(--glass-sheen), transparent 29%),
    radial-gradient(var(--glare-size) at 0% 0%, rgb(var(--glare-color) / calc(var(--glare-strength) * var(--glare-opacity) * var(--glare-tl-opacity))), transparent var(--glare-reach)),
    radial-gradient(var(--glare-size) at 100% 100%, rgb(var(--glare-color) / calc(var(--glare-strength) * var(--glare-opacity) * var(--glare-br-opacity))), transparent var(--glare-reach)),
    var(--glass-fill);
  border: 1px solid var(--glass-border);
  border-radius: 28px;
  box-shadow: var(--glass-shadow);
  isolation: isolate;
  transform: translateZ(0);
}

.properties::before {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    linear-gradient(112deg, var(--glass-directional-sheen), transparent 23%, transparent 72%, rgb(var(--glare-color) / calc(var(--glare-reflection-strength) * var(--glare-opacity)))),
    radial-gradient(92% 54% at 7% 0%, rgb(var(--glare-color) / calc(var(--glare-reflection-strength) * var(--glare-opacity) * var(--glare-tl-opacity))), transparent 65%),
    radial-gradient(92% 54% at 93% 100%, rgb(var(--glare-color) / calc(var(--glare-reflection-strength) * var(--glare-opacity) * var(--glare-br-opacity))), transparent 65%);
  box-shadow: inset 0 -0.5px 0 var(--glass-low-rim);
  opacity: var(--glare-opacity);
}

.properties::after {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(var(--glare-size) at 100% 100%, rgb(var(--glare-color) / calc(var(--glare-strength) * var(--glare-opacity) * var(--glare-br-opacity))), transparent var(--glare-reach)),
    radial-gradient(92% 54% at 93% 100%, rgb(var(--glare-color) / calc(var(--glare-reflection-strength) * var(--glare-opacity) * var(--glare-br-opacity))), transparent 65%);
  opacity: calc(var(--glare-opacity) * var(--glare-br-opacity));
}

.properties > * {
  position: relative;
  z-index: 2;
}

.properties > .controls {
  position: static;
  contain: none;
  will-change: auto;
}

.brand {
  gap: 9px;
  padding: 28px 20px;
}

.brand h1 {
  color: var(--ink);
  font-size: 21px;
  font-weight: 650;
  letter-spacing: -0.7px;
}

.preset.active span {
  color: var(--accent-ink);
}

/* Apple Liquid Glass Navigation & Anchor Chips */
.sky-nav-container {
  position: relative;
  z-index: 5;
  flex-shrink: 0;
  padding: 2px 20px 16px;
}

.sky-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
  padding: 3px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 999px;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.25);
  gap: 2px;
  margin-bottom: 20px;
}

.sky-tab {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  padding: 0 16px;
  border-radius: 999px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 550;
  letter-spacing: -0.2px;
  line-height: 1;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  transition: color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease, transform 0.12s ease;
}

.sky-tab:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.sky-tab.active {
  color: #ffffff;
  font-weight: 650;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.13) 100%);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4), inset 0 0.5px 0.5px rgba(255, 255, 255, 0.35);
}

/* Horizontal scrolling anchor chips */
.anchor-bar {
  position: relative;
  width: 100%;
  overflow: hidden;
  transition: opacity 0.2s ease, max-height 0.2s ease;
}

.anchor-bar[hidden] {
  display: none !important;
}

.anchor-track {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 2px 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  mask-image: linear-gradient(to right, transparent, black 14px, black calc(100% - 14px), transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 14px, black calc(100% - 14px), transparent);
}

.anchor-track::-webkit-scrollbar {
  display: none;
}

.anchor-chip {
  flex-shrink: 0;
  white-space: nowrap;
  height: 30px;
  padding: 0 13px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 400;
  letter-spacing: -0.15px;
  line-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.09);
  color: var(--muted);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25), inset 0 0.5px 0 rgba(255, 255, 255, 0.1);
  transition: color 0.16s ease, background-color 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, transform 0.12s ease;
}

.anchor-chip:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  transform: translateY(-0.5px);
}

.anchor-chip.active,
.anchor-chip.active:hover {
  color: var(--accent-ink);
  background: var(--accent-fill);
  border-color: var(--accent-line);
  font-weight: 400;
}

/* Panel views inside controls */
.panel-view[hidden] {
  display: none !important;
}

.tab-styles-active #location-menu {
  display: none;
}

.controls {
  /* Match the horizontal edge used by the desktop navigation tabs. */
  --controls-pad: 20px;
  /* Chrome reserves an 11px layout lane for its thin native scrollbar. */
  --scrollbar-lane: 11px;
  padding-block: 0 72px;
  padding-inline-start: var(--controls-pad);
  padding-inline-end: calc(var(--controls-pad) - var(--scrollbar-lane));
  scrollbar-width: thin;
  scrollbar-color: var(--scroll-thumb) transparent;
}

/* Fallback for engines without the standard thin scrollbar mode. */
@supports selector(::-webkit-scrollbar) {
  .controls::-webkit-scrollbar {
    width: 8px;
  }

  .controls::-webkit-scrollbar-track {
    background: transparent;
    margin-block: 4px;
  }

  .controls::-webkit-scrollbar-thumb {
    background: var(--scroll-thumb);
    border-radius: 999px;
  }

  .controls::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.28);
  }
}

.control-section,
.panel-footer,
.location-result {
  border-color: var(--line);
}

h2 { color: var(--ink); }
.label-row,
.select-label {
  color: var(--secondary);
}
.range-labels,
.time-caption,
.preset span,
.celestial {
  color: var(--muted);
}
.control-note,
.panel-footer {
  color: var(--subtext);
}

.label-row output {
  color: var(--secondary);
  background: var(--control-fill);
  border-radius: 7px;
}

button:hover { background-color: var(--control-hover); }
button.active { background: var(--accent-fill); }
button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
input:not([type="range"]):focus,
select:focus,
input:not([type="range"]):focus-visible,
select:focus-visible {
  outline: none;
  border-color: var(--focus);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 28%, transparent);
}
canvas:focus,
canvas:focus-visible {
  outline: none !important;
  box-shadow: none !important;
}

/* Time of day: a full-width native range whose thumb is an invisible globe-sized
   square; the globe canvas rides its centre. A native thumb's centre travels from
   half a thumb in from each edge, so the painted track spans exactly that range. */
#section-time {
  --globe-size: 38px;
}

.time-range-wrap {
  --hour-progress: 58.333%;
  position: relative;
  height: 42px;
  margin-top: 6px;
}

.time-range-wrap::before {
  content: "";
  position: absolute;
  top: 50%;
  left: calc(var(--globe-size) / 2);
  right: calc(var(--globe-size) / 2);
  height: 9px;
  border-radius: 6px;
  transform: translateY(-50%);
  background: linear-gradient(90deg, #182947, #675f7d, #d99e80, #9ac4da, #6fb9e5, #dfb675, #9c697d, #172744);
}

.time-range-wrap input.time-range {
  position: relative;
  width: 100%;
  height: 100%;
  margin: 0;
  background: transparent;
}

.time-range-wrap input.time-range::-webkit-slider-thumb {
  width: var(--globe-size);
  height: var(--globe-size);
  border: 0;
  background: transparent;
  box-shadow: none;
  opacity: 0;
}

.time-range-wrap input.time-range::-moz-range-thumb {
  width: var(--globe-size);
  height: var(--globe-size);
  border: 0;
  background: transparent;
  box-shadow: none;
  opacity: 0;
}

.earth-globe {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: var(--hour-progress);
  display: block;
  width: var(--globe-size);
  height: var(--globe-size);
  border-radius: 50%;
  pointer-events: none;
  filter: drop-shadow(0 6px 7px rgba(0, 0, 0, 0.45)) drop-shadow(0 2px 3px rgba(0, 0, 0, 0.3));
  transform: translate(-50%, -50%);
}

.time-range:focus,
.time-range:focus-visible,
input[type="range"]:focus,
input[type="range"]:focus-visible {
  outline: none !important;
  border-color: transparent !important;
  box-shadow: none !important;
}

.time-range:focus-visible + .earth-globe {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}

@media (forced-colors: active) {
  :focus-visible {
    outline: 2px solid Highlight !important;
    outline-offset: 2px;
  }
}

.time-ticks i { background: var(--line); }


.season,
.celestial,
.style,
.search-field,
.control-section select {
  color: var(--secondary);
  background: var(--control-fill);
  border-color: var(--line);
  border-radius: 12px;
}

.season,
.celestial,
.style {
  min-height: 44px;
}

.season.active,
.celestial.active,
.style.active {
  color: var(--accent-ink);
  background: var(--accent-fill);
  border-color: var(--accent-line);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.16);
}

.celestial .celestial-orb {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  display: block;
  border-radius: 50%;
}
.celestial:not(.active) .celestial-orb {
  opacity: 0.58;
  filter: saturate(0.72) brightness(0.88);
}

.preset.active canvas,
.aurora-preset.active canvas {
  box-shadow: none;
  outline: 2px solid var(--track-fill);
  outline-offset: 2px;
}

.preset canvas {
  border-radius: 12px;
  box-shadow: inset 0 0 0 1px var(--line);
  outline: none;
}

.search-field input,
.control-section select,
.control-section .text-field {
  color: var(--ink);
}
.control-section .text-field {
  background: var(--control-fill);
  border-color: var(--line);
  border-radius: 12px;
}
/* Drawn chevron, inset to match the row padding, in place of the OS one that hugs the edge. */
.control-section select {
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23aab4ae' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 15px;
  padding-right: 40px;
  cursor: pointer;
}

.search-field input::placeholder { color: var(--muted); opacity: 0.82; }

.panel-footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 5;
  width: 100%;
  margin: 0;
  padding: 24px 24px 16px;
  border-top: none;
  box-sizing: border-box;
  background: linear-gradient(
    to top,
    #04070a 70%,
    rgba(4, 7, 10, 0.85) 45%,
    transparent
  );
  border-bottom-left-radius: 28px;
  border-bottom-right-radius: 28px;
}

.canvas-top { left: 29px; }
.canvas-bottom { left: 29px; }
.canvas-toolbar { left: 50%; }

.export-button,
.canvas-toolbar,
.fullscreen-button,
.sound-toggle-button,
.snapshot-shutter,
.record-hud-panel,
.snapshot-thumb,
#toast,
#canvas-error {
  position: relative;
  color: var(--ink);
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 32%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / var(--glass-ambient-strength)), transparent 58%),
    var(--floating-glass-fill, var(--glass-fill));
  border: 0.5px solid var(--glass-border);
  box-shadow:
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px var(--glass-inner-line),
    inset 0 -0.5px 0 var(--glass-low-rim);
  -webkit-backdrop-filter: var(--glass-filter);
  backdrop-filter: var(--glass-filter);
  isolation: isolate;
}

.export-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  min-height: 44px;
  padding: 0;
  border-radius: 50%;
  cursor: pointer;
  transition: background 180ms ease, box-shadow 180ms ease, transform 150ms ease;
}

.export-label { display: none; }

.export-button svg {
  width: 16px;
  height: 16px;
  stroke-width: 1.8;
}

.export-button:hover {
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 26%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / calc(var(--glass-ambient-strength) * 1.5)), transparent 55%),
    var(--control-strong);
  box-shadow:
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.14);
}

.export-button:active {
  transform: scale(0.97);
}

.export-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: auto;
  margin: 0;
  max-width: none;
  width: 272px;
  padding: 18px;
  border-radius: 22px;
  color: var(--menu-text-primary);
  background: var(--menu-frost-bg);
  border: 0.5px solid var(--menu-frost-border);
  box-shadow:
    inset 0 0.75px 0.5px var(--menu-frost-rim),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.09),
    inset 0 -0.5px 0 rgba(255, 255, 255, 0.05);
  -webkit-backdrop-filter: var(--menu-frost-filter);
  backdrop-filter: var(--menu-frost-filter);
  isolation: isolate;
}

.export-menu p {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--menu-text-muted);
  margin: 0 0 16px;
}

.export-menu label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--secondary);
  margin-bottom: 7px;
}

.export-menu select {
  width: 100%;
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 550;
  font-family: 'Google Sans Flex', sans-serif;
  color: var(--menu-text-primary);
  background: var(--menu-control-bg);
  border: 1px solid var(--menu-control-border);
  box-shadow: inset 0 1px 0.5px rgba(255, 255, 255, 0.32);
  border-radius: 12px;
  margin-bottom: 14px;
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 15px;
  padding-right: 32px;
  cursor: pointer;
  transition: border-color 150ms ease, box-shadow 150ms ease, background-color 150ms ease;
}

.export-menu select:hover {
  background-color: var(--menu-control-hover);
  border-color: rgba(255, 255, 255, 0.48);
}

.export-menu select:focus,
.export-menu select:focus-visible {
  outline: none;
  border-color: var(--focus);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 35%, transparent);
}

.export-menu button {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 14px;
  margin-top: 7px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 650;
  color: var(--menu-text-primary);
  background: var(--menu-control-bg);
  border: 1px solid var(--menu-control-border);
  box-shadow: inset 0 1px 0.5px rgba(255, 255, 255, 0.32);
  cursor: pointer;
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transition: background-color 150ms ease, border-color 150ms ease, transform 120ms ease, box-shadow 150ms ease;
}

.export-menu button:hover {
  background: var(--menu-control-hover);
  border-color: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.45);
}

.export-menu button:active {
  transform: scale(0.98);
  background: color-mix(in srgb, var(--menu-control-hover) 85%, #fff);
}

.export-menu button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--focus) 40%, transparent);
}

.export-menu .export-format {
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: var(--menu-text-primary);
}

.export-menu .export-desc,
.export-menu button:not(.capture-option) span:not(.export-format) {
  font-size: 12px;
  font-weight: 500;
  color: var(--menu-text-secondary);
  margin-left: auto;
  margin-right: 6px;
}

.export-menu .export-icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  stroke-width: 2;
  color: var(--menu-text-secondary);
  opacity: 0.9;
  transition: transform 150ms ease, color 150ms ease, opacity 150ms ease;
}

.export-menu button:hover .export-icon {
  color: var(--menu-text-primary);
  transform: translateY(1px);
  opacity: 1;
}


.export-menu .export-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: auto;
  height: auto;
  padding: 0;
  margin: 0 0 16px;
  border: 0;
  border-radius: 0;
  background: transparent;
  justify-content: flex-start;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--menu-text-muted);
  cursor: pointer;
}

.export-menu .export-back:hover {
  color: var(--menu-text-primary);
}

.export-menu .export-back svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.export-video-summary,
#video-export-status {
  display: block;
  margin-top: 12px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.45;
  color: var(--menu-text-secondary);
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.export-menu .export-video-action,
.export-menu .export-cancel {
  margin-top: 14px;
}

#video-export-progress label {
  margin-bottom: 8px;
}

#video-export-meter {
  display: block;
  width: 100%;
  height: 8px;
  overflow: hidden;
  border: 0;
  border-radius: 999px;
  background: var(--menu-control-bg);
  accent-color: var(--accent-fill);
}

#video-export-meter::-webkit-progress-bar {
  background: var(--menu-control-bg);
}

#video-export-meter::-webkit-progress-value {
  background: var(--accent-fill);
}

#video-export-meter::-moz-progress-bar {
  background: var(--accent-fill);
}

.export-error {
  margin: 12px 0 0;
  padding: 9px 10px;
  border: 1px solid color-mix(in srgb, #ff8b7c 45%, transparent);
  border-radius: 10px;
  color: var(--menu-text-primary);
  background: color-mix(in srgb, #ff8b7c 13%, var(--menu-control-bg));
  font-size: 12px;
  line-height: 1.4;
}


.canvas-toolbar {
  gap: 4px;
  padding: 5px;
  border-radius: 18px;
}

.tool {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 13px;
  color: var(--floating-icon-color, var(--ink));
  opacity: var(--floating-icon-opacity, 1);
  background: transparent;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease, transform 120ms ease, box-shadow 150ms ease;
}

.tool svg {
  width: 17px;
  height: 17px;
  stroke-width: 2.1;
  opacity: var(--floating-icon-opacity, 1);
}

.tool:hover {
  background: var(--control-hover);
  color: var(--ink);
}

.tool:active {
  transform: scale(0.92);
}

@keyframes dice-roll {
  0% {
    transform: rotate(0deg) scale(1);
  }
  35% {
    transform: rotate(180deg) scale(1.18);
  }
  70% {
    transform: rotate(330deg) scale(0.95);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

.tool.rolling svg {
  animation: dice-roll 420ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.tool.active {
  color: var(--ink);
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 26%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / calc(var(--glass-ambient-strength) * 1.35)), transparent 55%),
    var(--control-strong);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow:
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.22),
    inset 0 -0.5px 0 var(--glass-low-rim);
}

.tool:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2.5px color-mix(in srgb, var(--focus) 45%, transparent);
}

#undo:disabled {
  opacity: var(--floating-icon-disabled-opacity, 0.65);
  cursor: default;
  background: transparent !important;
  transform: none !important;
  box-shadow: none !important;
}

.fullscreen-button,
.sound-toggle-button {
  pointer-events: auto;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  aspect-ratio: 1;
  padding: 0;
  border-radius: 50%;
  flex-shrink: 0;
  color: var(--ink);
  cursor: pointer;
  transition: background 180ms ease, box-shadow 180ms ease, transform 150ms ease, border-color 150ms ease;
}

.fullscreen-button {
  margin-left: auto;
}

.fullscreen-button svg,
.sound-toggle-button svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2.1;
}

.fullscreen-button:hover,
.sound-toggle-button:hover,
.snapshot-shutter:hover {
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 26%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / calc(var(--glass-ambient-strength) * 1.5)), transparent 55%),
    var(--control-strong);
  box-shadow:
    inset 0 1px 0 var(--glass-rim),
    inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.fullscreen-button:active,
.sound-toggle-button:active {
  transform: scale(0.92);
}

.fullscreen-button:focus-visible,
.sound-toggle-button:focus-visible {
  outline: none;
  box-shadow:
    inset 0 1px 0 var(--glass-rim),
    inset 0 0 0 1px rgba(255, 255, 255, 0.28),
    0 0 0 3px color-mix(in srgb, var(--focus) 45%, transparent);
}

.sound-toggle-button.active {
  color: var(--ink);
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 32%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / var(--glass-ambient-strength)), transparent 58%),
    var(--floating-glass-fill, var(--glass-fill));
  border: 0.5px solid var(--glass-border);
  box-shadow:
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px var(--glass-inner-line),
    inset 0 -0.5px 0 var(--glass-low-rim);
}

.canvas-panel.canvas-ui-light {
  --floating-glass-fill: rgba(255, 255, 255, 0.2);
  --glass-border: rgba(14, 22, 28, 0.11);
  --glass-inner-line: rgba(255, 255, 255, 0.34);
  --glass-sheen: rgba(255, 255, 255, 0.22);
  --glass-rim: rgba(255, 255, 255, 0.72);
  --glass-low-rim: rgba(14, 22, 28, 0.08);
  --glass-ambient-strength: 0.045;
  --glass-ambient-rgb: 180 200 210;
  --glass-filter: blur(24px) saturate(130%) contrast(1.03);
  --floating-icon-color: rgba(18, 28, 34, 0.82);
  --floating-icon-disabled-opacity: 0.42;
  --control-hover: rgba(14, 22, 28, 0.06);
  --control-strong: rgba(255, 255, 255, 0.72);
}

.canvas-panel.canvas-ui-light :is(.export-button, .canvas-toolbar, .fullscreen-button, .sound-toggle-button, .snapshot-shutter, #toast) {
  box-shadow:
    0 4px 14px rgba(12, 20, 28, 0.07),
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px var(--glass-inner-line),
    inset 0 -0.5px 0 var(--glass-low-rim);
}

.canvas-panel.canvas-ui-light #toast {
  color: #121c22;
}

.canvas-panel.canvas-ui-light :is(.fullscreen-button, .sound-toggle-button, .export-button, .tool, .capture-wrap.is-selected #toolbar-capture, .snapshot-shutter) {
  color: var(--floating-icon-color);
}

.canvas-panel.canvas-ui-light .snapshot-shutter-icon {
  filter: brightness(0) saturate(100%);
  opacity: 0.82;
}

.canvas-panel.canvas-ui-light .tool.active,
.canvas-panel.canvas-ui-light .capture-wrap.is-selected #toolbar-capture {
  border-color: rgba(14, 22, 28, 0.1);
  box-shadow:
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.42),
    inset 0 -0.5px 0 var(--glass-low-rim);
}

.canvas-panel.canvas-ui-light :is(.fullscreen-button:hover, .sound-toggle-button:hover, .tool:hover, .export-button:hover, .snapshot-shutter:hover) {
  box-shadow:
    0 6px 18px rgba(12, 20, 28, 0.09),
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.48),
    inset 0 -0.5px 0 var(--glass-low-rim);
}

#toast {
  position: absolute;
  top: 25px;
  left: 50%;
  bottom: auto;
  transform: translateX(-50%);
  z-index: 6;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 16px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: -0.1px;
  line-height: 1.4;
  white-space: nowrap;
  border-radius: 9999px;
  pointer-events: none;
  max-width: calc(100% - 280px);
  overflow: hidden;
  text-overflow: ellipsis;
  animation: toast-fade-in 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

#toast .sky-at {
  opacity: 0.7;
  margin-right: 0.35em;
}

#toast svg,
#toast .toast-icon {
  width: 14px;
  height: 14px;
  margin-right: 6px;
  stroke: currentColor;
  stroke-width: 2.1;
  fill: none;
  flex-shrink: 0;
}
#toast .toast-icon-trailing {
  margin-right: 0;
  margin-left: 8px;
}
#toast .toast-icon-success {
  stroke: #34d399;
  color: #34d399;
}

@keyframes toast-fade-in {
  from {
    opacity: 0;
    transform: translate(-50%, -6px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
}

@keyframes toast-fade-in-bottom {
  from {
    opacity: 0;
    transform: translate(-50%, 6px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
}

#canvas-error {
  color: var(--ink);
  border-radius: 18px;
  padding: 16px 22px;
}

@media (max-width: 1050px) {
  .studio {
    grid-template-columns: 310px minmax(0, 1fr);
    gap: 8px;
    padding: 8px;
  }
  .canvas-panel { inset: auto; }
  .properties {
    inset: auto;
    width: auto;
  }
  .brand { padding: 28px 17px; }
  .brand h1 { font-size: 19px; }
  .controls {
    --controls-pad: 16px;
  }
  .panel-footer {
    padding-inline: 18px;
  }
  .canvas-top,
  .canvas-bottom { left: 22px; }
  .canvas-toolbar { left: 50%; }
}

@media (max-width: 700px) {
  .studio {
    display: flex;
    flex-direction: column;
    padding: 8px;
    gap: 8px;
  }
  .canvas-panel {
    position: relative;
    order: -1;
    inset: auto;
    width: auto;
    height: 44%;
    min-height: 0;
    border-radius: 25px;
    flex-shrink: 0;
  }
  .properties {
    position: relative;
    inset: auto;
    width: auto;
    min-height: 0;
    border-radius: 25px;
    flex: 1;
  }
  .brand { padding: 20px 16px; }
  .brand-logo { height: 31.68px; }
  .sky-nav-container {
    position: static;
    padding: 8px 16px 14px;
    transition: padding-bottom 0.2s ease, padding-top 0.2s ease;
  }
  .sky-tabs {
    position: absolute;
    top: 15.84px;
    left: calc(16px + 65.34px + 24px);
    width: min(220px, calc(100% - 120px));
    margin-bottom: 0;
    z-index: 10;
  }
  .sky-tab {
    height: 32px;
    padding: 0 10px;
    font-size: 12.5px;
  }
  .controls {
    --controls-pad: 16px;
    /* Mobile browsers overlay the scrollbar, so it needs no reserved lane. */
    --scrollbar-lane: 0px;
  }
  #section-time { padding-top: 16px; }
  .canvas-top { top: 18px; left: 18px; right: 18px; }
  .canvas-bottom {
    right: 18px;
    bottom: 18px;
    left: 18px;
  }
  .canvas-toolbar { left: 50%; }
  /* Opened modally on phones: top layer, centred, scrim from ::backdrop. */
  .export-menu {
    position: fixed;
    inset: 0;
    margin: auto;
    width: min(300px, 100vw - 40px);
    height: fit-content;
    max-height: calc(100dvh - 80px);
  }
  .export-menu::backdrop { background: rgb(0 0 0 / 0.55); }
  .panel-footer { position: static; padding: 14px 0 18px; background: transparent; }
  .controls { padding-bottom: 0; }
  .export-button { width: 44px; padding: 0; justify-content: center; border-radius: 50%; }
  .export-label { display: none; }
  .anchor-bar { max-height: 48px; }
  .sky-nav-container.collapsed { padding-top: 0; padding-bottom: 0; }
  .sky-nav-container.collapsed .anchor-bar { max-height: 0; opacity: 0; }
  #toast {
    top: auto;
    bottom: 84px;
    min-height: 28px;
    padding: 5px 14px;
    font-size: 11px;
    max-width: calc(100% - 48px);
    animation: toast-fade-in-bottom 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  }
}

/* One material, with flat controls inside it. The tint follows the current sky. */
:root { --control-grid-gap: 10px; }

.season-options,
.presets,
.aurora-presets,
.celestial-options,
.styles {
  gap: var(--control-grid-gap);
}



.shuffle-button {
  position: relative;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin: -4px -4px -4px 0;
  padding: 0;
  color: var(--muted);
  background: none;
  border: 0;
  border-radius: 12px;
  box-shadow: none;
  cursor: pointer;
  transition: color 150ms ease;
}

.shuffle-button:hover { color: var(--ink); }
.shuffle-button svg { width: 12px; height: 12px; }

.preset-wrap {
  position: relative;
  min-width: 0;
  container-type: inline-size;
}

.preset {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto;
  width: 100%;
}

.preset canvas,
.preset-shuffle {
  grid-column: 1;
  grid-row: 1;
}

.preset > span {
  grid-column: 1;
  grid-row: 2;
}

.preset-shuffle,
.aurora-preset-shuffle {
  position: absolute;
  z-index: 2;
  top: 21px;
  top: calc(100cqi * 43 / 121);
  left: 50%;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  color: var(--ink);
  background: rgb(5 12 16 / 0.68);
  border: 1px solid rgb(255 255 255 / 0.42);
  border-radius: 12px;
  box-shadow: 0 5px 14px rgb(0 0 0 / 0.38), inset 0 1px rgb(255 255 255 / 0.12);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.9);
  transition: opacity 150ms ease, transform 150ms ease;
}

.preset-shuffle svg,
.aurora-preset-shuffle svg { width: 15px; height: 15px; }
.preset-shuffle:hover,
.aurora-preset-shuffle:hover {
  background: rgb(5 12 16 / 0.68);
}
.preset-wrap:focus-within .preset-shuffle,
.aurora-preset-wrap:focus-within .aurora-preset-shuffle {
  opacity: 1;
  transform: translate(-50%, -50%);
}
@media (hover: hover) {
  .preset-wrap:hover .preset-shuffle,
  .aurora-preset-wrap:hover .aurora-preset-shuffle {
    opacity: 1;
    transform: translate(-50%, -50%);
  }
}

.preset-wrap:has([data-preset="clear"]) .preset-shuffle,
[data-preset="clear"] ~ .preset-shuffle {
  display: none !important;
}

@media (max-width: 700px) {
  .preset-wrap:has(.preset.active) .preset-shuffle,
  .aurora-preset-wrap:has(.aurora-preset.active) .aurora-preset-shuffle {
    opacity: 1;
    transform: translate(-50%, -50%);
  }
  #section-time {
    --globe-size: 34px;
  }
}

@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .properties,
  .export-button,
  .canvas-toolbar,
  .export-menu,
  .fullscreen-button,
  .sound-toggle-button,
  .record-hud-panel,
  .snapshot-thumb,
  .snapshot-shutter,
  #glass-tooltip,
  #toast,
  #canvas-error {
    background: color-mix(in srgb, var(--app-background) 94%, transparent);
  }
}

@media (prefers-reduced-transparency: reduce) {
  .properties,
  .export-button,
  .canvas-toolbar,
  .export-menu,
  .fullscreen-button,
  .sound-toggle-button,
  .record-hud-panel,
  .snapshot-thumb,
  .snapshot-shutter,
  #glass-tooltip,
  #toast,
  #canvas-error {
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    background: var(--app-background);
  }
}

@media (prefers-contrast: more) {
  .properties,
  .export-button,
  .canvas-toolbar,
  .export-menu,
  .fullscreen-button,
  .sound-toggle-button,
  .record-hud-panel,
  .snapshot-thumb {
    border-width: 2px;
  }
  :root { --muted: #c8cfca; --glass-fill: rgba(0, 0, 0, 0.9); }
}

/* Compact location picker */
.location-menu {
  position: relative;
  z-index: 10;
  flex-shrink: 0;
  margin: 24px 0 0;
  grid-column: 1 / -1;
}
.current-location {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 46px;
  gap: 10px;
  padding: 10px 14px;
  color: var(--secondary);
  text-align: left;
  background: color-mix(in srgb, var(--control-fill) 92%, transparent);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: inset 0 1px rgb(255 255 255 / 0.14);
}
.current-location:hover { background: var(--control-hover); }
.current-location > svg:first-child { width: 15px; height: 15px; color: var(--muted); }
.location-summary {
  display: grid;
  min-width: 0;
  gap: 4px;
}
#current-location-name {
  overflow: hidden;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#current-location-meta {
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.current-location .chevron {
  width: 14px;
  height: 14px;
  margin-left: auto;
  color: var(--muted);
  transition: transform 150ms ease;
}
.current-location[aria-expanded="true"] .chevron { transform: rotate(180deg); }
.location-popover {
  position: absolute;
  z-index: 20;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  display: flex;
  flex-direction: column;
  padding: 14px;
  border-radius: 20px;
  color: var(--menu-text-primary);
  background:
    linear-gradient(168deg, rgba(28, 36, 48, 0.94) 0%, rgba(16, 21, 29, 0.96) 50%, rgba(10, 14, 20, 0.98) 100%);
  border: 0.5px solid rgba(255, 255, 255, 0.16);
  box-shadow:
    0 24px 52px rgba(0, 0, 0, 0.6),
    0 8px 20px rgba(0, 0, 0, 0.38),
    inset 0 0.75px 0.5px rgba(255, 255, 255, 0.25),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.06);
  -webkit-backdrop-filter: var(--menu-frost-filter);
  backdrop-filter: var(--menu-frost-filter);
  isolation: isolate;
  overflow: hidden;
}

.location-popover .search-field {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 40px;
  padding: 2px;
  border-radius: 12px;
  background: var(--menu-control-bg);
  border: 1px solid var(--menu-control-border);
  box-shadow: inset 0 1px 0.5px rgba(255, 255, 255, 0.14);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.location-popover .search-field:focus-within {
  border-color: var(--menu-control-border);
  box-shadow: inset 0 1px 0.5px rgba(255, 255, 255, 0.14);
}

.location-popover .search-field input:focus,
.location-popover .search-field input:focus-visible {
  outline: none;
  box-shadow: none;
  border-color: transparent;
}

.location-popover .search-field input {
  flex: 1;
  min-width: 0;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 550;
  color: var(--menu-text-primary);
  background: transparent;
  border: none;
  outline: none;
}

.location-popover .search-field input::placeholder {
  color: var(--menu-text-muted);
}

.location-popover .search-field button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 10px;
  color: var(--menu-text-muted);
  background: transparent;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: color 150ms ease, background-color 150ms ease;
}

.location-popover .search-field button:hover {
  color: var(--menu-text-primary);
  background: var(--menu-control-hover);
}

.location-popover .search-field button svg {
  width: 15px;
  height: 15px;
}

.location-results {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 240px;
  margin-top: 10px;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  padding-right: 6px;
  padding-bottom: 4px;
}

/* Apple Liquid Glass thin custom scrollbar */
.location-results::-webkit-scrollbar {
  width: 4px;
}
.location-results::-webkit-scrollbar-track {
  background: transparent;
  margin: 4px 0;
}
.location-results::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  box-shadow: inset 0 0.5px 0.5px rgba(255, 255, 255, 0.35);
}
.location-results::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.42);
  box-shadow: inset 0 0.5px 0.5px rgba(255, 255, 255, 0.6);
}

.location-result {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  min-height: 40px;
  gap: 2px;
  padding: 6px 30px 6px 10px;
  color: var(--menu-text-primary);
  text-align: left;
  background: transparent;
  border: none;
  border-radius: 12px;
  box-shadow: none;
  cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease;
}

.location-result:not(:last-child)::after {
  content: '';
  position: absolute;
  bottom: -4.5px;
  left: 8px;
  right: 8px;
  height: 1px;
  background: var(--line);
  pointer-events: none;
}

.location-result:hover {
  background: var(--menu-control-hover);
}

.location-result:hover::after {
  opacity: 0;
}

.location-result:active {
  background: var(--menu-control-bg);
}

.location-result.active {
  color: var(--accent-ink);
  background: transparent;
}

.location-result.active::before {
  content: '✓';
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-ink);
}

.location-result > span {
  font-size: 13px;
  font-weight: 550;
  line-height: 1.25;
}

.location-result.active > span {
  font-weight: 650;
}

.location-result small {
  font-size: 10.5px;
  line-height: 1.25;
  color: var(--menu-text-muted);
}

.location-result.active small {
  color: color-mix(in srgb, var(--accent-ink) 78%, transparent);
}

#weather-status {
  display: none;
}

.time-caption > .time-swatch {
  display: inline-block;
  width: 4px;
  height: 4px;
  flex: 0 0 4px;
  border-radius: 50%;
  background: var(--time-swatch-color, #6fb9e5);
  box-shadow: 0 0 0 1px rgb(255 255 255 / 0.35), 0 1px 2px rgb(0 0 0 / 0.2);
}

/* Intro splash screen overlay */
.intro-splash {
  position: fixed;
  inset: 0;
  z-index: 100000;
  background: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  box-sizing: border-box;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.5s ease;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
  cursor: default;
}

.intro-splash.fade-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.intro-card {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  width: min(780px, calc(100vw - 48px));
  padding: 16px;
  gap: 28px;
  box-sizing: border-box;
  color: var(--ink);
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 29%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / var(--glass-ambient-strength)), transparent 58%),
    var(--glass-fill);
  border: 0.5px solid var(--glass-border);
  border-radius: 28px;
  box-shadow: var(--glass-shadow), inset 0 0 0 0.5px var(--glass-inner-line);
  isolation: isolate;
  transform: translateZ(0);
}

.intro-card::before {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    linear-gradient(112deg, var(--glass-directional-sheen), transparent 23%, transparent 72%, rgb(var(--glass-ambient-rgb) / var(--glass-reflection-strength))),
    radial-gradient(92% 54% at 7% 0%, rgb(var(--glass-ambient-rgb) / var(--glass-reflection-strength)), transparent 65%);
  box-shadow: inset 0 0.5px 0 var(--glass-rim), inset 0.5px 0 0 rgb(255 255 255 / 0.07), inset 0 -0.5px 0 var(--glass-low-rim);
  opacity: 1;
}

.intro-card > * {
  position: relative;
  z-index: 1;
}

.intro-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  align-self: center;
  flex: 1 1 240px;
  min-width: 170px;
  padding: 8px 0 8px 12px;
  gap: 32px;
  text-align: left;
}

.intro-logo {
  display: block;
  height: 48px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
  margin: 0;
}

.intro-tagline {
  font-family: 'Google Sans Flex', sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.65);
  margin: 0;
  padding: 0;
  letter-spacing: -0.01em;
  text-align: left;
}

.intro-loading {
  font-family: 'Google Sans Flex', sans-serif;
  font-size: 13px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.38);
  display: flex;
  align-items: baseline;
  margin: 0;
  text-align: left;
}

.intro-dots {
  display: inline-flex;
  margin-left: 1px;
  letter-spacing: 1px;
}

.intro-dots span {
  display: inline-block;
  opacity: 0.2;
  animation: introDotPulse 1.2s infinite ease-in-out both;
}

.intro-dots span:nth-child(1) {
  animation-delay: 0s;
}

.intro-dots span:nth-child(2) {
  animation-delay: 0.2s;
}

.intro-dots span:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes introDotPulse {
  0%, 100% {
    opacity: 0.2;
    transform: translateY(0);
  }
  50% {
    opacity: 1;
    transform: translateY(-1.5px);
  }
}

.intro-media {
  flex: 1.4 1 420px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 20px;
  overflow: hidden;
  background: url('assets/skystudio-intro-poster.webp') center / cover no-repeat;
}

.intro-video {
  width: 100%;
  height: auto;
  max-height: 290px;
  aspect-ratio: 1918 / 1080;
  object-fit: cover;
  border-radius: 20px;
  display: block;
  pointer-events: none;
}

@media (max-width: 700px) {
  .intro-card {
    flex-direction: column-reverse;
    gap: 24px;
    border-radius: 22px;
    width: min(440px, calc(100vw - 32px));
    max-height: 90vh;
    overflow-y: auto;
  }
  .intro-media {
    width: 100%;
    flex: 0 0 auto;
    border-radius: 16px;
  }
  .intro-video {
    width: 100%;
    max-height: none;
    border-radius: 16px;
  }
  .intro-content {
    width: 100%;
    flex: 0 0 auto;
    padding: 0;
    gap: 16px;
  }
  .intro-logo {
    height: 40px;
  }
  .intro-tagline {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.65);
  }
  .intro-loading {
    font-size: 11.5px;
  }
}

.record-hud-panel .record-volume-control {
  --pull-h: 36px;
  flex: 0 0 112px;
  width: 112px;
  height: var(--pull-h);
  margin: 0;
}
.record-hud-panel .record-volume-control .label-row {
  justify-content: flex-end;
  padding: 0 10px;
  font-size: 11px;
}
.record-hud-panel .record-volume-control .label-row output {
  font-size: 11px;
  font-weight: 600;
}
.record-sound-toggle {
  display: none;
  place-items: center;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: 13px;
  color: var(--ink);
  background: var(--menu-control-bg);
  border: 1px solid var(--menu-control-border);
  cursor: pointer;
}
.record-sound-toggle svg {
  width: 17px;
  height: 17px;
  stroke-width: 2.1;
}
.record-sound-toggle:active {
  transform: scale(0.96);
}
.sound-toggle-button {
  position: absolute;
  left: 26px;
  bottom: 26px;
  z-index: 7;
}

.capture-wrap {
  position: relative;
  display: grid;
  place-items: center;
}
.capture-wrap.is-selected #toolbar-capture {
  color: var(--ink);
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 26%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / calc(var(--glass-ambient-strength) * 1.35)), transparent 55%),
    var(--control-strong);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow:
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.22),
    inset 0 -0.5px 0 var(--glass-low-rim);
}
.capture-menu {
  top: auto;
  bottom: calc(100% + 20px);
  left: 50%;
  right: auto;
  transform: translateX(-50%);
}
.capture-menu button.capture-option {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  text-align: left;
}
.capture-menu .capture-option-icon {
  order: -1;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  stroke-width: 2;
  color: var(--menu-text-secondary);
}
.capture-menu .capture-option:hover .capture-option-icon {
  color: var(--menu-text-primary);
}
.capture-menu .capture-option-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.capture-menu .capture-option-copy .export-format,
.capture-menu .capture-option-copy .export-desc {
  margin: 0;
  margin-left: 0;
  margin-right: 0;
}
.capture-menu .capture-option-copy .export-desc {
  font-size: 12px;
  font-weight: 500;
  color: var(--menu-text-secondary);
}
.snapshot-shutter {
  position: absolute;
  left: 50%;
  bottom: calc(26px + 52px + 20px);
  z-index: 8;
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  min-width: 88px;
  min-height: 88px;
  padding: 0;
  border-radius: 50%;
  color: var(--ink);
  cursor: pointer;
  pointer-events: auto;
  transform: translateX(-50%);
  transition: background 180ms ease, box-shadow 180ms ease, transform 150ms ease;
}
.snapshot-shutter-icon {
  display: block;
  width: 34px;
  height: 34px;
  opacity: 0.7;
}
.snapshot-shutter:hover {
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 26%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / calc(var(--glass-ambient-strength) * 1.5)), transparent 55%),
    var(--control-strong);
  box-shadow:
    inset 0 1px 0 var(--glass-rim),
    inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}
.snapshot-shutter:active {
  transform: translateX(-50%) scale(0.94);
}
.snapshot-shutter:focus-visible {
  outline: none;
  box-shadow:
    inset 0 1px 0 var(--glass-rim),
    inset 0 0 0 1px rgba(255, 255, 255, 0.28),
    0 0 0 3px color-mix(in srgb, var(--focus) 45%, transparent);
}

#glass-tooltip {
  position: fixed;
  z-index: 10000;
  width: max-content;
  max-width: calc(100vw - 24px);
  padding: 6px 10px;
  color: #121c22;
  -webkit-text-fill-color: #121c22;
  font-size: 11px;
  font-weight: 550;
  line-height: 1.25;
  text-align: center;
  white-space: nowrap;
  pointer-events: none;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.92);
  border: 0.5px solid rgba(14, 22, 28, 0.12);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 140ms ease, visibility 140ms ease;
}
#glass-tooltip.is-side {
  color: #f4f7f5;
  -webkit-text-fill-color: #f4f7f5;
  text-align: left;
  background:
    linear-gradient(142deg, rgb(255 255 255 / 0.08), transparent 36%),
    color-mix(in srgb, var(--app-background) 94%, transparent);
  border: 0.5px solid rgba(195, 227, 246, 0.12);
  box-shadow:
    inset 0 0.5px 0 rgba(244, 251, 255, 0.1),
    inset 0 0 0 0.5px rgba(242, 251, 255, 0.065),
    inset 0 -0.5px 0 rgba(31, 87, 121, 0.21),
    0 8px 24px rgb(0 0 0 / 0.35);
}
#glass-tooltip.is-visible {
  opacity: 1;
  visibility: visible;
}

@media (min-width: 701px) {
  #glass-tooltip {
    font-size: 13px;
    font-weight: 400;
  }
}

.snapshot-stack-wrap {
  position: absolute;
  right: 22px;
  bottom: 24px;
  z-index: 7;
  width: 96px;
  height: 68px;
  pointer-events: auto;
}
.snapshot-stack {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.snapshot-clear {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 14px);
  right: auto;
  top: auto;
  z-index: 5;
  padding: 5px 9px;
  color: var(--ink);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
  border-radius: 999px;
  cursor: pointer;
  pointer-events: auto;
  opacity: 0;
  visibility: hidden;
  transform: translateX(-50%);
  transition: opacity 140ms ease, visibility 140ms ease, transform 140ms ease;
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 32%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / var(--glass-ambient-strength)), transparent 58%),
    var(--floating-glass-fill, var(--glass-fill));
  border: 0.5px solid var(--glass-border);
  box-shadow:
    inset 0 0.5px 0 var(--glass-rim),
    inset 0 0 0 0.5px var(--glass-inner-line),
    inset 0 -0.5px 0 var(--glass-low-rim);
  -webkit-backdrop-filter: var(--glass-filter);
  backdrop-filter: var(--glass-filter);
}
.snapshot-stack-wrap:hover .snapshot-clear,
.snapshot-stack-wrap:focus-within .snapshot-clear {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%);
}
.snapshot-clear:hover {
  background:
    linear-gradient(142deg, var(--glass-sheen), transparent 26%),
    radial-gradient(125% 78% at 0% 0%, rgb(var(--glass-ambient-rgb) / calc(var(--glass-ambient-strength) * 1.5)), transparent 55%),
    var(--control-strong);
}
.snapshot-clear:active {
  transform: translateX(-50%) scale(0.96);
}
.snapshot-thumb {
  position: absolute;
  inset: 0;
  padding: 0;
  overflow: hidden;
  border-radius: 14px;
  cursor: pointer;
  pointer-events: auto;
  outline: 1px solid oklch(1 0 0 / 0.1);
}
.snapshot-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.snapshot-thumb:hover {
  transform: scale(1.03);
}
.snapshot-thumb:active {
  transform: scale(0.96);
}
.snapshot-lightbox {
  max-width: min(920px, calc(100vw - 40px));
  padding: 16px;
  border: 0.5px solid var(--menu-frost-border);
  border-radius: 22px;
  color: var(--menu-text-primary);
  background: var(--menu-frost-bg);
  box-shadow:
    inset 0 0.75px 0.5px var(--menu-frost-rim),
    inset 0 0 0 0.5px rgba(255, 255, 255, 0.09);
  -webkit-backdrop-filter: var(--menu-frost-filter);
  backdrop-filter: var(--menu-frost-filter);
}
.snapshot-lightbox::backdrop {
  background: rgb(0 0 0 / 0.55);
}
.snapshot-lightbox img {
  display: block;
  width: 100%;
  max-height: min(70vh, 640px);
  object-fit: contain;
  border-radius: 14px;
  outline: 1px solid oklch(1 0 0 / 0.1);
}
.snapshot-lightbox form {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
}

.record-hud {
  position: absolute;
  left: 50%;
  bottom: 28px;
  z-index: 8;
  transform: translateX(-50%);
  pointer-events: auto;
}
.record-hud-panel {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 52px;
  padding: 7px 10px 7px 16px;
  border-radius: 22px;
}
.record-hud-panel p {
  margin: 0 8px 0 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--menu-text-muted);
}
.record-live-dot {
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff453a;
  box-shadow: 0 0 0 0 rgb(255 69 58 / 0.55);
  animation: record-live-pulse 1.15s ease-in-out infinite;
}
@keyframes record-live-pulse {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
    box-shadow: 0 0 0 0 rgb(255 69 58 / 0.55);
  }
  50% {
    opacity: 0.55;
    transform: scale(0.88);
    box-shadow: 0 0 0 4px rgb(255 69 58 / 0);
  }
}
#record-timer {
  min-width: 3.4em;
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.2px;
}
#record-controls {
  flex-wrap: nowrap;
}
.record-hud-panel select {
  flex: 0 0 auto;
  min-width: 84px;
  max-width: 96px;
  padding: 8px 28px 8px 10px;
  font-size: 12px;
  font-weight: 550;
  font-family: inherit;
  color: var(--menu-text-primary);
  background: var(--menu-control-bg);
  border: 1px solid var(--menu-control-border);
  border-radius: 12px;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  background-size: 14px;
}
.record-stop {
  flex-shrink: 0;
  min-height: 36px;
  padding: 0 16px;
  border-radius: 13px;
  color: #fff;
  background: rgba(210, 45, 45, 0.9);
  border: 1px solid rgba(255, 120, 120, 0.42);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.record-stop:hover {
  background: rgba(228, 55, 55, 0.96);
}
#record-done {
  min-height: 36px;
  padding: 0 16px;
  border-radius: 13px;
  color: var(--accent-ink);
  background: var(--accent-fill);
  border: 1px solid var(--accent-line);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
#record-done:hover {
  background: color-mix(in srgb, var(--accent-fill) 80%, white);
}
.record-stop:active,
#record-done:active {
  transform: scale(0.96);
}
#record-export,
#record-saved {
  min-width: min(360px, calc(100vw - 40px));
  flex-wrap: wrap;
  padding: 14px 18px;
}
#record-meter {
  display: block;
  width: 140px;
  height: 8px;
  overflow: hidden;
  border: 0;
  border-radius: 999px;
  background: var(--menu-control-bg);
  accent-color: var(--accent);
}
#record-status,
#record-saved-detail {
  color: var(--menu-text-secondary);
  font-size: 12px;
  font-weight: 500;
}

body.record-mode {
  overflow: hidden;
}
body.record-mode .studio {
  display: block;
  padding: 0;
  max-width: none;
  height: 100dvh;
}
body.record-mode .properties,
body.record-mode .canvas-top,
body.record-mode .canvas-bottom,
body.record-mode .snapshot-stack-wrap,
body.record-mode .snapshot-shutter,
body.record-mode .intro-splash {
  display: none !important;
}
body.record-mode .sound-toggle-button {
  display: grid;
}
body.record-mode .canvas-panel {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100dvh;
  border-radius: 0;
  z-index: 40;
  background: #000;
}
body.record-mode #sky-canvas {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media (max-width: 700px) {
  .capture-menu {
    position: fixed;
    inset: 0;
    margin: auto;
    width: min(300px, 100vw - 40px);
    height: fit-content;
    max-height: calc(100dvh - 80px);
    transform: none;
  }
  .capture-menu::backdrop {
    background: rgb(0 0 0 / 0.55);
  }
  .record-hud {
    left: 16px;
    right: 16px;
    bottom: 16px;
    transform: none;
  }
  .record-hud-panel {
    width: 100%;
    justify-content: space-between;
  }
  .record-hud-panel .record-volume-control {
    display: none;
  }
  .record-sound-toggle {
    display: grid;
  }
  body.snapshot-mode #toast {
    top: 25px;
    bottom: auto;
    animation: toast-fade-in 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  }
  .snapshot-stack-wrap {
    display: none !important;
  }
  .sound-toggle-button {
    left: 16px;
    bottom: 16px;
  }
  .snapshot-shutter {
    bottom: calc(16px + 52px + 20px);
  }
  .canvas-panel :is(.export-button, .tool, .fullscreen-button, .sound-toggle-button, .snapshot-shutter, .snapshot-clear) {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }
  .canvas-panel :is(.export-button, .tool, .fullscreen-button, .sound-toggle-button, .snapshot-shutter, .snapshot-clear):focus,
  .canvas-panel :is(.export-button, .tool, .fullscreen-button, .sound-toggle-button, .snapshot-shutter, .snapshot-clear):focus-visible {
    outline: none !important;
  }
  .canvas-panel .tool:focus,
  .canvas-panel .tool:focus-visible {
    box-shadow: none;
  }
  .canvas-panel .tool.active:focus,
  .canvas-panel .tool.active:focus-visible {
    box-shadow:
      inset 0 0.5px 0 var(--glass-rim),
      inset 0 0 0 0.5px rgba(255, 255, 255, 0.22),
      inset 0 -0.5px 0 var(--glass-low-rim);
  }
  .canvas-panel .fullscreen-button:focus,
  .canvas-panel .fullscreen-button:focus-visible,
  .canvas-panel .sound-toggle-button:focus,
  .canvas-panel .sound-toggle-button:focus-visible,
  .canvas-panel .snapshot-shutter:focus,
  .canvas-panel .snapshot-shutter:focus-visible,
  .canvas-panel .export-button:focus,
  .canvas-panel .export-button:focus-visible {
    box-shadow:
      inset 0 0.5px 0 var(--glass-rim),
      inset 0 0 0 0.5px var(--glass-inner-line),
      inset 0 -0.5px 0 var(--glass-low-rim);
  }
}

