/* The poster's neutral surface, without changing the square's geometry. */
:root {
  --home-surface: linear-gradient(180deg, #bbb 0%, #c5c5c5 20%, #d5d5d5 40%, #ddd 50%, #e9e9e9 65%, #f4f4f4 80%, #fbfbfb 90%, #fff 100%);
}

.study-stage::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: var(--home-surface);
  opacity: var(--study-surface-opacity, 1);
}

.square-entry {
  background: var(--home-surface);
}

/* Local drawing units scale with the original 200-unit square. Its reflected
   height is 85% of the visible side; the original four pieces stay untouched. */
.study-shape::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: var(--study-reflection-height, 170px);
  box-sizing: content-box;
  border: 0;
  background: linear-gradient(180deg, rgba(255,89,0,.6) 0%, rgba(255,89,0,.38) 30%, rgba(255,89,0,.16) 65%, rgba(255,89,0,0) 100%);
  opacity: var(--study-reflection-opacity, 1);
  pointer-events: none;
}

/* Inactive language choices remain readable against the new gray surface. */
body[data-view="home"] .language-control button {
  color: #454a42;
}
body[data-view="home"] .language-control button[aria-pressed="true"] {
  color: var(--ink);
}
@media (hover: hover) and (pointer: fine) {
body[data-view="home"] .language-control button:hover {
  color: var(--ink);
}
}

/* Short landscape windows have space beside the reflection rather than below. */
@media (min-width: 700px) and (max-height: 500px) {
  .study-scroll-prompt {
    left: calc(50% + 165px);
    top: calc(50% - 24px);
    max-width: calc(50% - 80px);
  }
}
