* { box-sizing: border-box; }

:root {
  color-scheme: dark;
  --background: #101010;
  --panel: #171717;
  --border: #77736a;
  --text: #d9d4c9;
  --dim: #77736a;
  --lamp-off: #302b24;
  --lamp-on: #b58b45;
}

html, body {
  min-height: 100%;
  margin: 0;
}

body {
  display: grid;
  place-items: center;
  padding: 18px;
  background: radial-gradient(circle at 50% 30%, #201d18 0, var(--background) 62%);
  color: var(--text);
  font-family: "Courier New", Courier, monospace;
}

.machine {
  width: min(100%, 610px);
  padding: 30px 26px;
  border: 1px solid var(--border);
  background: rgba(20, 20, 20, 0.96);
  box-shadow: 0 20px 60px rgba(0,0,0,.55), inset 0 0 32px rgba(255,255,255,.018);
}

h1 {
  margin: 0;
  text-align: center;
  font-size: clamp(1.3rem, 5vw, 1.8rem);
  font-weight: 400;
  letter-spacing: .2em;
}

.subtitle {
  margin: 8px 0 24px;
  color: var(--dim);
  text-align: center;
  font-size: .7rem;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.status {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 9px;
  min-height: 22px;
  margin-bottom: 18px;
  color: var(--dim);
  font-size: .72rem;
  letter-spacing: .16em;
}

.lamp {
  width: 8px;
  height: 8px;
  border: 1px solid #635848;
  border-radius: 50%;
  background: var(--lamp-off);
  box-shadow: inset 0 0 3px #000;
}

.lamp.active {
  background: var(--lamp-on);
  box-shadow: 0 0 7px rgba(181,139,69,.8), 0 0 18px rgba(181,139,69,.3);
}

.controls {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

button {
  display: block;
  min-width: 190px;
  margin: 0 auto;
  padding: 11px 16px;
  border: 1px solid #8a857b;
  background: #121212;
  color: #efebe2;
  font: inherit;
  font-size: .72rem;
  letter-spacing: .14em;
  cursor: pointer;
}

button:hover:not(:disabled),
button:focus-visible:not(:disabled) {
  background: #211d18;
  outline: none;
  box-shadow: 0 0 0 1px #b2a58f;
}

button:disabled {
  color: #625f59;
  border-color: #45423e;
  cursor: wait;
}

.thought-panel {
  display: grid;
  place-items: center;
  min-height: 150px;
  margin-top: 25px;
  padding: 24px 18px;
  border-top: 1px solid #34322f;
  border-bottom: 1px solid #34322f;
}

.transcript {
  width: 100%;
  min-height: 255px;
  max-height: 390px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
}

.transcript-line {
  margin: 0;
  color: #ddd7cb;
  font-size: clamp(.88rem, 2.8vw, 1.12rem);
  line-height: 1.55;
  letter-spacing: .035em;
  overflow-wrap: anywhere;
  transition: opacity .35s ease, color .35s ease;
}

.transcript-line.current {
  color: #f0eadf;
}

.transcript-placeholder {
  margin: 0;
  color: #77736a;
  text-align: center;
  font-size: .78rem;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.transcript.cc-off {
  visibility: hidden;
}

.report {
  margin-top: 20px;
  color: var(--dim);
  font-size: .68rem;
  letter-spacing: .08em;
}

.report summary {
  cursor: pointer;
  text-transform: uppercase;
}

pre {
  margin: 14px 0 0;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
  color: #aaa59b;
  font: .75rem/1.6 "Courier New", Courier, monospace;
}


.rare-line {
  padding: 3px 0;
  color: #d9c9a4;
  font-style: italic;
}

.rare-divider {
  width: 62%;
  height: 1px;
  margin: 2px auto;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(181, 139, 69, 0.52),
    transparent
  );
  transition: opacity .35s ease;
}
