/* Lab 02: Floating Points – the images spread over a transparent globe you can turn and zoom.
   Red outside the globe, light inside it (script.js swaps the "is-outside" class). The buttons, labels and panel
   are the light ones in both – the site's light mode */

html,
body {
  margin: 0;
  height: 100%;
  overflow: hidden; /* the page never scrolls – scrolling and pinching zoom the globe */
  overscroll-behavior: none;
}

/* The globe is drawn transparently on top of the page's colour: light inside the globe… */
html {
  background: #ededed;
  transition: background-color 0.6s ease;
}

/* …and red outside it */
html.is-outside {
  background: #fe0000;
}

.globe {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none; /* touch turns and pinches the globe instead of scrolling or zooming the page */
}

/* The panel for working out how the globe should be (tuning.js – not on the published page): bottom left,
   sliders in groups. Light grey boxes on both the dark and the light background, like the buttons at the top */
.tuning {
  position: fixed;
  left: var(--gutter, 4px);
  bottom: var(--gutter, 4px);
  z-index: 150; /* over the veil the page fades in from */
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  font-family: "Suisse Intl", sans-serif;
  font-size: 12px;
  line-height: 1.2;
  color: #121212;
}

.tuning-button,
.tuning-action {
  padding: 6px 10px;
  border: 0;
  background: rgba(237, 237, 237, 0.92);
  font: inherit;
  color: inherit;
  cursor: var(--cursor-clickable, pointer);
}

.tuning-button:hover,
.tuning-action:hover {
  background: #ffffff;
}

.tuning-box {
  display: none;
  width: 290px;
  max-height: calc(100vh - 110px);
  overflow-y: auto;
  padding: 8px 10px 10px;
  background: rgba(237, 237, 237, 0.92);
  scrollbar-width: thin;
}

.tuning.is-open .tuning-box {
  display: block;
}

.tuning-group {
  margin: 10px 0 4px;
  padding-top: 8px;
  border-top: 1px solid #c4c4c4;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 10px;
  color: #757575;
}

.tuning-group:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.tuning-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px 8px;
  margin-bottom: 7px;
}

.tuning-name {
  cursor: var(--cursor-clickable, pointer);
}

.tuning-value {
  font-variant-numeric: tabular-nums;
}

.tuning-row input {
  grid-column: 1 / -1;
  width: 100%;
  margin: 0;
  accent-color: #121212;
  cursor: var(--cursor-clickable, pointer);
}

.tuning-buttons {
  display: flex;
  gap: 2px;
  margin-top: 12px;
}

.tuning-buttons .tuning-action {
  flex: 1;
  background: #d9d9d9;
}

.tuning-note {
  margin-top: 8px;
  font-size: 10px;
  color: #757575;
}
