/* 21.11.2026 (operator: the table cube as the second QR product beside the stand): the QR Masa Küpü's page is the
   stand's page with another stage. The cards, the fields, the photos and the other product's card are the stand's
   (qr-standi.css); here stands what the cube alone has: the 3D view and the four inlays below it. */
@import url('qr-standi.css');

/* The cube on its table: the stand's studio ground, the view over all of it. The view takes the height the column
   beside it leaves, so the page fits one screen; it lies over its box, whose size it then cannot push itself. */
.qk-sahne {
  grid-template-rows: minmax(0, 1fr) auto auto;
}
.qk-isik {
  position: relative;
  min-height: min(52vh, 520px);
  padding: 0;
}
.qk-kup,
.qk-yedek {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.qk-kup {
  cursor: grab;
  /* A finger's way down the page stays the page's; across, it turns the cube. */
  touch-action: pan-y;
}
.qk-kup:active {
  cursor: grabbing;
}
.qk-yedek {
  object-fit: cover;
}
.qk-kup[hidden],
.qk-yedek[hidden] {
  display: none;
}
/* The cube's shadow on the table, below its dome. */
.qk-isik::after {
  position: absolute;
  bottom: 13%;
  left: 50%;
  width: 34%;
  height: 7%;
  border-radius: 50%;
  background: rgba(27, 33, 48, 0.3);
  content: '';
  filter: blur(18px);
  pointer-events: none;
  transform: translateX(-50%);
}

/* The four engraved inlays, flat: a click turns the cube to the one. */
.qk-yuzler {
  display: grid;
  /* Narrower on a narrow phone: four of 76 px and their gaps are wider than a window of 320 px leaves. */
  grid-template-columns: repeat(4, minmax(0, 76px));
  justify-content: center;
  gap: 12px;
}
.qk-yuz {
  display: grid;
  gap: 6px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.qk-yuz canvas {
  display: block;
  width: 100%;
  height: auto;
  border: 3px solid #1b1d1e;
  border-radius: 8px;
  transition:
    transform 320ms var(--ease),
    box-shadow 320ms var(--ease);
}
.qk-yuz:focus-visible {
  outline: none;
}
.qk-yuz:focus-visible canvas {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
@media (hover: hover) {
  .qk-yuz:hover {
    color: var(--ink);
  }
  .qk-yuz:hover canvas {
    box-shadow: 0 16px 28px -18px rgba(34, 38, 65, 0.6);
    transform: translateY(-3px);
  }
}

/* The table's number. One cube or a set of them: two tiles, the chosen one lit. */
.qk-adet {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.qk-adet button {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 10px 8px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  /* A tile's words wrap, unlike the site's other buttons (base.css): in Russian they are wider than the tile of a
     narrow phone. */
  white-space: normal;
  transition:
    border-color 180ms var(--ease),
    box-shadow 180ms var(--ease),
    transform 180ms var(--ease);
}
.qk-adet svg {
  width: 44px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 220ms var(--ease);
}
.qk-adet button:active {
  transform: scale(0.98);
}
.qk-adet button[aria-checked='true'] {
  border-color: var(--accent);
  background: #fff;
  color: var(--ink);
  box-shadow: 0 0 0 4px rgba(82, 127, 168, 0.14);
}
.qk-adet button[aria-checked='true'] svg {
  transform: translateY(-1px) scale(1.08);
}
/* A number with its two steps: its word, one less, the number, one more. */
.qk-sayac {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px 64px 40px;
  align-items: center;
  gap: 6px;
}
.qk-sayac[hidden] {
  display: none;
}
/* A set's last table comes in below the first. */
.qk-sayac + .qk-sayac {
  animation: qk-belir 420ms var(--ease) both;
}
@keyframes qk-belir {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
}
.qk-sayac label {
  color: var(--muted);
  font-size: 13px;
}
.qk-sayac button {
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  font-size: 19px;
  line-height: 1;
  transition:
    border-color 200ms var(--ease),
    transform 200ms var(--ease);
}
.qk-sayac button:active {
  transform: scale(0.92);
}
.qk-sayac input {
  min-width: 0;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 700;
  text-align: center;
}
.qk-sayac input:focus-visible {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(82, 127, 168, 0.18);
  outline: none;
}
.qk-adet button:focus-visible,
.qk-sayac button:focus-visible {
  outline-offset: 3px;
}
/* What a set comes to, how many cubes for which tables, stands where the hint stood and is read first. */
.qk-takim {
  color: var(--ink);
}
@media (hover: hover) {
  .qk-adet button:hover,
  .qk-sayac button:hover {
    border-color: var(--accent);
  }
}
/* The two links: each field with its state line, the link to try it beside the line. */
.qk-baglanti {
  display: flex;
  flex-wrap: wrap;
  align-items: start;
  gap: 6px 12px;
}
.qk-baglanti .qs-alan {
  flex: 1 0 100%;
}
.qk-baglanti .ipucu {
  flex: 1 1 0;
}

@media (max-width: 980px) {
  .qk-isik {
    min-height: min(52vh, 460px);
  }
}
@media (prefers-reduced-motion: reduce) {
  .qk-yuz canvas,
  .qk-adet button,
  .qk-adet svg,
  .qk-sayac button {
    transition: none;
  }
  .qk-sayac + .qk-sayac {
    animation: none;
  }
  .qk-adet button:active,
  .qk-adet button[aria-checked='true'] svg,
  .qk-sayac button:active {
    transform: none;
  }
}
