:root {
  color-scheme: dark;
  --ink: #eff6f5;
  --muted: #aac1c4;
  --surface: #152b2e;
  --edge: #315054;
  --highlight: #96ebcb;
  font: 16px/1.5 "Avenir Next", "Segoe UI", system-ui, sans-serif;
  color: var(--ink);
  background: #0c1c1e;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
a { color: var(--highlight); text-underline-offset: .2em; }
a:hover { color: #c5ffe9; }
button, select, input { font: inherit; }
button, .download, select { border-radius: .6rem; }
button, .download { cursor: pointer; }
button:disabled { opacity: .45; cursor: default; }
:focus-visible { outline: 2px solid var(--highlight); outline-offset: 3px; }
.top {
  min-height: 4.25rem; border-bottom: 1px solid #223d40; padding: 1rem max(3vw, 1rem);
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
}
.top > a { text-decoration: none; }
.top > a:last-child { font-size: .85rem; color: var(--muted); white-space: nowrap; }
.brand { display: inline-flex; gap: .55rem; align-items: center; color: var(--ink); font-weight: 680; }
.brand img, .empty img { border-radius: 9px; }
main { width: min(1210px, calc(100% - 2rem)); margin: 0 auto; }
.intro { margin: 2.65rem 0 1.65rem; }
h1, h2, p { margin: 0; }
h1 { font-size: clamp(1.85rem, 4.5vw, 3.15rem); line-height: 1.13; letter-spacing: -.045em; }
.intro p { margin-top: .6rem; color: var(--muted); }
.workspace { display: grid; grid-template-columns: minmax(0, 1fr) 18.75rem; gap: 1.15rem; align-items: start; }
.preview, .panel { background: var(--surface); border: 1px solid var(--edge); border-radius: .9rem; }
.toolbar, .timeline { display: flex; align-items: center; justify-content: space-between; gap: .65rem; padding: .65rem .85rem; }
.tabs { display: flex; gap: .15rem; border: 1px solid var(--edge); padding: .16rem; border-radius: .7rem; }
.tabs button { border: 0; background: transparent; color: var(--muted); padding: .37rem .65rem; }
.tabs [aria-pressed="true"] { color: var(--ink); background: #29474b; }
.screen { min-height: 17rem; display: grid; place-items: center; background: #081618; }
.empty { display: grid; justify-items: center; text-align: center; gap: .7rem; padding: 2.1rem 1.1rem; }
.empty strong { font-size: 1.27rem; }
.empty p { color: var(--muted); font-size: .9rem; }
.open-buttons { display: flex; gap: .6rem; flex-wrap: wrap; justify-content: center; }
.primary, .quiet {
  font-weight: 650; padding: .59rem .87rem; border: 1px solid transparent;
  text-align: center;
}
.primary { background: var(--highlight); color: #0a2523; }
.primary:hover:not(:disabled), a.primary:hover { background: #baffdf; color: #0a2523; }
.quiet { background: transparent; border-color: var(--edge); color: var(--ink); }
.quiet:hover { background: #27464a; }
.viewport { position: relative; width: 100%; max-width: 100%; line-height: 0; touch-action: none; }
#media { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.viewport canvas { position: relative; width: 100%; height: auto; display: block; }
.viewport[data-selectable="true"] { cursor: crosshair; }
.box { position: absolute; pointer-events: none; outline: 2px solid #a8ffdb; outline-offset: -1px; background: #7aeec528; }
.timeline { min-height: 3.5rem; }
.timeline input { flex: 1; min-width: 50px; accent-color: var(--highlight); }
.timeline span { font-variant-numeric: tabular-nums; font-size: .8rem; color: var(--muted); white-space: nowrap; }
.panel { padding: 1.05rem; display: grid; gap: 1.2rem; }
h2 { font-size: 1.05rem; letter-spacing: -.01em; }
.detail { margin-top: .34rem; color: var(--muted); font-size: .86rem; overflow-wrap: anywhere; }
.select-label { display: block; margin-top: .85rem; margin-bottom: .32rem; font-size: .84rem; }
select, .coords input { width: 100%; color: var(--ink); background: #0e2225; border: 1px solid var(--edge); padding: .4rem .55rem; }
.coords { display: grid; grid-template-columns: 1fr 1fr; gap: .45rem; margin-top: .62rem; }
.coords label { color: var(--muted); font-size: .78rem; }
.coords input { font-size: .9rem; border-radius: .4rem; margin-top: .15rem; }
.export { border-top: 1px solid var(--edge); padding-top: 1.1rem; }
.export button, .export .download, progress { width: 100%; margin-top: .65rem; }
progress { accent-color: var(--highlight); }
.download { display: block; text-decoration: none; }
.status { margin: .8rem 0 .45rem; min-height: 1.5rem; color: var(--muted); }
.status[data-error="true"] { color: #ffb5a6; }
footer { color: var(--muted); font-size: .83rem; padding: .35rem 0 1.8rem; }
.info { max-width: 720px; padding-top: 2.3rem; }
.info section { margin-top: 1.2rem; }
.info section p { color: var(--muted); margin-top: .35rem; }
@media (max-width: 840px) {
  .workspace { grid-template-columns: minmax(0, 1fr); }
  .panel { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .export { border: 0; border-left: 1px solid var(--edge); padding: 0 0 0 .9rem; }
}
@media (max-width: 490px) {
  .brand { font-size: .87rem; }
  .top > a:last-child { font-size: .78rem; }
  .intro { margin: 1.65rem 0 1.2rem; }
  .panel { grid-template-columns: minmax(0, 1fr); }
  .export { border: 0; border-top: 1px solid var(--edge); padding: .9rem 0 0; }
}
