/* Reset & base */
* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }
body {
  height: 100%;
  overflow: hidden;                       /* no scrollbars; stage always fits */
  background: #ffffff;
  color: #000000;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  transition: background 150ms linear, color 150ms linear;
}

/* Dark mode */
body.dark {
  background: #000000;
  color: #ffffff;
}

/* Full-viewport stage */
.stage {
  position: relative;
  width: 100%;
  height: 100dvh;                         /* fill window height (mobile-safe) */
}

/* Moving columns (container) — no borders, no background */
.col {
  position: absolute;
  left: 0;                                /* JS handles X via transform */
  bottom: 0;                              /* anchor to bottom so growth looks natural */
  height: 100%;                           /* column canvas area */
  will-change: transform;
  display: block;
  overflow: hidden;                     /* keep inner fill inside */
}

/* The growing fill inside each column (solid color only) */
.col .fill {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 0px;                            /* JS sets exact pixel height */
  background: #000;                       /* JS sets the color */
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
}

/* Label: tiny, bottom-right (inside the fill) */
.col .label {
  font-size: 14px;                        /* per request: max 10px */
  line-height: 1;
  color: #ffffff;
  padding: 2px 3px;
  opacity: 0.95;
  user-select: none;
  pointer-events: none;
}

/* Tiny controls just above the copyright */
.controls {
  position: fixed;
  left: 6px;
  bottom: 18px;                           /* slightly above the copyright */
  display: flex;
  gap: 6px;
  z-index: 1001;
}

.controls button {
  font-size: 9px;
  line-height: 1;
  padding: 3px 5px;
  color: rgba(0,0,0,0.6);
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(0,0,0,0.15);
  border-radius: 0px;
  cursor: pointer;
  opacity: 0.7;
  display: inline-block;
  transition: opacity 120ms linear, color 120ms linear, background 120ms linear, border-color 120ms linear;
}

.controls button:hover {
  opacity: 1;
}

body.dark .controls button {
  color: rgba(255,255,255,0.75);
  background: rgba(0,0,0,0.6);
  border-color: rgba(255,255,255,0.2);
}

/* Subtle copyright mark */
.kpeg {
  position: fixed;
  bottom: 4px;
  left: 6px;
  font-size: 9px;
  color: rgba(0,0,0,0.15);
  user-select: none;
  z-index: 1000;
}

.kpeg a {
  color: rgba(0,0,0,0.15);
  text-decoration: none;
}

.kpeg a:hover {
  color: rgba(0,0,0,0.35);
}

body.dark .kpeg { color: rgba(255,255,255,0.25); }
body.dark .kpeg a { color: rgba(255,255,255,0.25); }
body.dark .kpeg a:hover { color: rgba(255,255,255,0.45); }