/* Farbklecks – Schreiben (Nachspuren). All rules scoped to .screen-trace, classes prefixed .tr- */

.screen-trace {
  --tr-track: #e3e0ef;
  --tr-line: #8fbbe9;
  --tr-line-strong: #5b95dc;
  --tr-band: #eaf5ff;
  --tr-tile: 112px;
  --side: 150px;
  --side-end: 380px;
}

/* ---------- overview ---------- */

.screen-trace .tr-over-view {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.screen-trace .tr-in { animation: tr-in .34s cubic-bezier(.2, 1.2, .4, 1); }
@keyframes tr-in { from { transform: scale(.96); opacity: 0; } to { transform: none; opacity: 1; } }

.screen-trace .tr-tabs {
  flex: none;
  display: flex;
  justify-content: center;
  gap: 16px;
  padding: 2px 4px 8px;
}
.screen-trace .tr-tab {
  position: relative;
  flex: 0 1 190px;
  min-width: 0;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 14px;
  border: 4px solid var(--ink);
  border-radius: 24px;
  background: var(--sticker);
  box-shadow: 0 6px 0 var(--ink);
  color: var(--ink);
  cursor: pointer;
  touch-action: manipulation;
  transition: transform .18s cubic-bezier(.3, 1.6, .5, 1), box-shadow .18s, background-color .2s;
}
.screen-trace .tr-tab:active { transform: translateY(4px); box-shadow: 0 2px 0 var(--ink); }
.screen-trace .tr-tab:focus-visible { outline: 5px solid #fff; outline-offset: 3px; }
.screen-trace .tr-tab.on { background: var(--sun); transform: translateY(-3px) rotate(-2deg); box-shadow: 0 9px 0 var(--ink); }
.screen-trace .tr-tab-name {
  font-family: var(--read);
  font-size: 38px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .02em;
  padding-top: 4px;
}
.screen-trace .tr-tab-prog {
  display: flex;
  align-items: center;
  gap: 1px;
  padding: 2px 9px 2px 3px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .75);
  border: 2px solid rgba(35, 32, 61, .2);
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
}
.screen-trace .tr-tab.on .tr-tab-prog { background: #fff; }
.screen-trace .tr-tab-prog .ic { width: 24px; height: 24px; }

.screen-trace .tr-scroll { padding: 8px 6px 20px; }
.screen-trace .tr-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(var(--tr-tile), 1fr));
  gap: 16px;
  max-width: 1100px;
  margin: 0 auto;
}
.screen-trace .tr-tile {
  position: relative;
  min-width: 0;
  aspect-ratio: 1 / 1;
  padding: 0;
  border: 4px solid var(--ink);
  border-radius: 24px;
  background: var(--sticker);
  box-shadow: 0 6px 0 var(--ink);
  cursor: pointer;
  touch-action: manipulation;
  transform: rotate(var(--tilt, 0deg));
  transition: transform .15s ease, box-shadow .15s ease;
}
.screen-trace .tr-tile:active { transform: translateY(4px) rotate(var(--tilt, 0deg)) scale(.97); box-shadow: 0 2px 0 var(--ink); }
.screen-trace .tr-tile:focus-visible { outline: 5px solid #fff; outline-offset: 3px; }
.screen-trace .tr-tile svg { display: block; width: 100%; height: 100%; pointer-events: none; overflow: visible; }
.screen-trace .tr-tile-ln { stroke: var(--tr-line); stroke-width: 2.5; stroke-linecap: round; }
.screen-trace .tr-tile-g {
  font-family: var(--read);
  font-weight: 700;
  font-size: 64px;
  fill: #efedf7;
  stroke: var(--ink);
  /* the fill covers the inner half of the stroke, so the font's overlapping contours (K M N W X Y Q) stay hidden */
  paint-order: stroke fill;
  stroke-width: 4.8;
  stroke-dasharray: 4.5 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.screen-trace .tr-tile-g.is-done {
  stroke-width: 5;
  stroke-dasharray: none;
  paint-order: stroke fill;
}
.screen-trace .tr-tile.is-done { background: #fffbea; }
.screen-trace .tr-tile-stars {
  position: absolute;
  right: -10px;
  top: -12px;
  display: flex;
  pointer-events: none;
}
.screen-trace .tr-tile-stars .ic { width: 34px; height: 34px; transform: rotate(12deg); filter: drop-shadow(0 2px 0 rgba(35, 32, 61, .35)); }
.screen-trace .tr-tile-stars .tr-star-frei { width: 28px; height: 28px; margin-top: 16px; transform: rotate(-10deg); }
.screen-trace .tr-tile-stars .ic + .tr-star-frei { margin-left: -12px; }
.screen-trace .tr-tile.is-next::after {
  content: "";
  position: absolute;
  inset: -9px;
  border: 5px solid var(--leaf);
  border-radius: 30px;
  pointer-events: none;
  animation: tr-next 1.6s ease-in-out infinite;
}
@keyframes tr-next { 0%, 100% { opacity: .25; transform: scale(.97); } 50% { opacity: 1; transform: scale(1.02); } }
.screen-trace .tr-empty { color: #fff; font-size: 28px; font-weight: 800; text-align: center; grid-column: 1 / -1; }

/* ---------- tracing ---------- */

.screen-trace .tr-play {
  flex: 1;
  min-height: 0;
  display: flex;
  gap: 16px;
  padding-bottom: 6px;
}
.screen-trace .tr-paper {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  min-height: 0;
  border: 4px solid var(--ink);
  border-radius: 30px;
  background: #fffefa;
  box-shadow: 0 7px 0 var(--ink);
  overflow: hidden;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
  cursor: crosshair;
}
.screen-trace .tr-svg { position: absolute; left: 0; top: 0; width: 100%; height: 100%; display: block; touch-action: none; overflow: hidden; }

/* writing paper: Oberlinie, dashed Mittellinie, Grundlinie, Unterlinie, tinted Mittelband */
.screen-trace .tr-band { fill: var(--tr-band); }
.screen-trace .tr-ln { fill: none; stroke: var(--tr-line); stroke-width: 2px; vector-effect: non-scaling-stroke; }
.screen-trace .tr-ln-mid { stroke: #a9cbef; }
.screen-trace .tr-ln-base { stroke: var(--tr-line-strong); stroke-width: 3px; }

/* the glyph as a soft track */
.screen-trace .tr-track-o path,
.screen-trace .tr-track path,
.screen-trace .tr-halo path,
.screen-trace .tr-paint-o path,
.screen-trace .tr-paint path,
.screen-trace .tr-center,
.screen-trace .tr-demo-trail,
.screen-trace .tr-chev path { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.screen-trace .tr-track-o path { stroke: rgba(35, 32, 61, .2); stroke-width: 20.5px; transition: opacity .3s; }
.screen-trace .tr-track path { stroke: var(--tr-track); stroke-width: 17px; transition: opacity .3s, stroke .3s; }
.screen-trace .tr-track path.is-cur { stroke: #dcd8ec; }
.screen-trace .tr-track path.is-later,
.screen-trace .tr-track-o path.is-later { opacity: .45; }
.screen-trace .tr-track path.is-dot { stroke-width: 18px; }

/* current stroke: moving dashed centre line, chevrons, end mark */
.screen-trace .tr-guide { display: none; }
.screen-trace .tr-guide.on { display: inline; }
.screen-trace .tr-center {
  stroke: rgba(35, 32, 61, .42);
  stroke-width: 1.7px;
  stroke-dasharray: 3.2 4.3;
  animation: tr-dash 1.1s linear infinite;
}
@keyframes tr-dash { from { stroke-dashoffset: 15; } to { stroke-dashoffset: 0; } }
.screen-trace .tr-endmark { fill: rgba(35, 32, 61, .3); }
.screen-trace .tr-chev { opacity: 0; transition: opacity .3s; }
.screen-trace .tr-chev.on { opacity: 1; animation: tr-nudge .9s ease-in-out infinite; }
.screen-trace .tr-chev.on.far { opacity: .4; }
.screen-trace .tr-chev-w { stroke: #fff; stroke-width: 5.4px; }
.screen-trace .tr-chev-i { stroke: var(--ink); stroke-width: 2.4px; }
@keyframes tr-nudge { 0%, 100% { transform: translateX(-1.4px); } 50% { transform: translateX(1.8px); } }

/* painted crayon strokes (one ink outline layer under all colours, like a sticker) */
.screen-trace .tr-paint-o path { stroke: var(--ink); stroke-width: 14.5px; }
.screen-trace .tr-paint path { stroke-width: 10.5px; }
.screen-trace .tr-paint path.pop { animation: tr-paint-pop .45s ease-out; }
@keyframes tr-paint-pop { 0% { stroke-width: 10.5px; } 40% { stroke-width: 13px; } 100% { stroke-width: 10.5px; } }

/* numbered start points of later strokes */
.screen-trace .tr-num { display: none; }
.screen-trace .tr-num.on { display: inline; opacity: .55; }
.screen-trace .tr-num circle { fill: #fff; stroke: var(--ink); stroke-width: 1.6px; }
.screen-trace .tr-num text { font-family: var(--read); font-weight: 700; font-size: 8.4px; fill: var(--ink); }

/* the green start dot that follows the reached point */
.screen-trace .tr-head { display: none; pointer-events: none; }
.screen-trace .tr-head.on { display: inline; }
.screen-trace .tr-head-in { transform-box: fill-box; transform-origin: center; transition: transform .18s ease; }
.screen-trace .tr-head-dot { fill: var(--leaf); stroke: var(--ink); stroke-width: 2.3px; }
.screen-trace .tr-head-num {
  font-family: var(--read);
  font-weight: 700;
  font-size: 12.5px;
  fill: #fff;
  stroke: var(--ink);
  stroke-width: 2.6px;
  stroke-linejoin: round;
  paint-order: stroke fill;
}
.screen-trace .tr-head-ring {
  fill: none;
  stroke: var(--leaf);
  stroke-width: 3px;
  transform-box: fill-box;
  transform-origin: center;
  animation: tr-ring 1.5s ease-out infinite;
}
@keyframes tr-ring { from { transform: scale(1); opacity: .95; } to { transform: scale(2.2); opacity: 0; } }
.screen-trace .tr-head.is-active .tr-head-in { transform: scale(.72); }
.screen-trace .tr-head.is-active .tr-head-ring { animation: none; opacity: 0; }
.screen-trace .tr-head.is-pause .tr-head-in { transform: scale(1.12); }
.screen-trace .tr-head.is-pause .tr-head-ring { stroke: var(--sun-deep); animation-duration: .9s; }
.screen-trace .tr-head.is-dot .tr-head-ring { animation-duration: 1.1s; }
.screen-trace .tr-head-in.wob { animation: tr-wob .5s ease; }
@keyframes tr-wob { 0%, 100% { transform: rotate(0) scale(1.1); } 20% { transform: rotate(-16deg) scale(1.25); } 45% { transform: rotate(13deg) scale(1.2); } 70% { transform: rotate(-7deg) scale(1.12); } }

/* demo: a glowing ball shows the way */
.screen-trace .tr-demo { display: none; pointer-events: none; }
.screen-trace .tr-demo.on { display: inline; }
.screen-trace .tr-demo-trail { stroke: rgba(255, 201, 60, .85); stroke-width: 8px; }
.screen-trace .tr-demo-ball { fill: #ffe14a; stroke: var(--ink); stroke-width: 2.2px; }

/* finished glyph glows and hops */
.screen-trace .tr-halo path { stroke: #ffe45c; stroke-width: 32px; opacity: 0; }
.screen-trace .tr-svg.is-glow .tr-halo path { animation: tr-halo 1.4s ease-in-out infinite alternate; }
@keyframes tr-halo { from { opacity: .35; } to { opacity: .95; } }
.screen-trace .tr-glyph { transform-box: fill-box; transform-origin: center; }
.screen-trace .tr-svg.is-hop .tr-glyph { animation: tr-hop .8s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes tr-hop { 0% { transform: scale(1); } 35% { transform: scale(1.07) rotate(-2deg); } 100% { transform: scale(1) rotate(0); } }

/* «Ohne Hilfe»: only the faint track */
.screen-trace .is-frei .tr-guide,
.screen-trace .is-frei .tr-num.on,
.screen-trace .is-frei .tr-head.on { display: none; }
.screen-trace .is-frei .tr-head.on.is-hint { display: inline; animation: tr-hint 1.8s ease both; }
@keyframes tr-hint { 0% { opacity: 0; } 15%, 75% { opacity: 1; } 100% { opacity: 0; } }
.screen-trace .is-frei .tr-track path { stroke: #ebe9f3; }
.screen-trace .is-frei .tr-track path.is-later,
.screen-trace .is-frei .tr-track-o path.is-later { opacity: 1; }
.screen-trace .is-frei .tr-track-o path { stroke: rgba(35, 32, 61, .1); }

/* ---------- side: tools while tracing, Anlaut card when done ---------- */

.screen-trace .tr-side {
  position: relative;
  flex: 0 0 var(--side);
  min-width: 0;
  min-height: 0;
  transition: flex-basis .55s cubic-bezier(.25, 1.1, .4, 1);
}
.screen-trace .is-done .tr-side { flex-basis: var(--side-end); }
.screen-trace .tr-tools,
.screen-trace .tr-end {
  position: absolute;
  display: flex;
  transition: opacity .3s ease, transform .4s cubic-bezier(.3, 1.4, .5, 1), visibility .3s;
}
.screen-trace .tr-tools { inset: 0; flex-direction: column; align-items: center; justify-content: space-between; gap: 12px; }
.screen-trace .tr-end { left: 0; top: 0; flex-direction: column; gap: 12px; opacity: 0; visibility: hidden; pointer-events: none; }
.screen-trace .is-done .tr-tools { opacity: 0; visibility: hidden; pointer-events: none; transform: scale(.9); }
.screen-trace .is-done .tr-end { opacity: 1; visibility: visible; pointer-events: auto; transition-delay: .2s; }

.screen-trace .tr-mid { display: flex; flex-direction: column; align-items: center; gap: 12px; min-width: 0; }
.screen-trace .tr-navs { display: flex; gap: 10px; }
.screen-trace .tr-myst {
  position: relative;
  width: 104px;
  height: 104px;
  flex: none;
  border: 4px solid var(--ink);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 5px 0 var(--ink);
  transform: rotate(-3deg);
}
.screen-trace .tr-myst-e {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 62px;
  line-height: 1;
}
.screen-trace .tr-myst-sil { filter: brightness(0); opacity: .13; }
.screen-trace .tr-myst-col { -webkit-clip-path: inset(100% 0 0 0); clip-path: inset(100% 0 0 0); }

.screen-trace .tr-pips { display: flex; flex-wrap: wrap; justify-content: center; gap: 7px; max-width: 100%; }
.screen-trace .tr-pip {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid var(--ink);
  border-radius: 50%;
  background: #fff;
  font-family: var(--read);
  font-size: 17px;
  font-weight: 700;
  line-height: 1;
  padding-top: 2px;
  opacity: .55;
  transition: background-color .3s, opacity .3s, transform .3s cubic-bezier(.3, 1.8, .5, 1);
}
.screen-trace .tr-pip.is-dot { width: 22px; height: 22px; margin: 6px 0; }
.screen-trace .tr-pip.is-cur { opacity: 1; background: var(--leaf); transform: scale(1.12); box-shadow: 0 0 0 4px rgba(63, 209, 107, .35); }
.screen-trace .tr-pip.is-done { opacity: 1; background: var(--c, var(--sun)); color: #fff; -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; }
.screen-trace .tr-chip {
  display: none;
  align-items: center;
  gap: 4px;
  padding: 4px 12px 4px 6px;
  border: 3px solid var(--ink);
  border-radius: 99px;
  background: var(--sun);
  box-shadow: 0 3px 0 var(--ink);
  font-size: 16px;
  font-weight: 800;
  white-space: nowrap;
}
.screen-trace .tr-chip .ic { width: 26px; height: 26px; }
.screen-trace .is-frei .tr-chip { display: flex; }
.screen-trace .is-frei .tr-pips { display: none; }

.screen-trace .tr-card {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 12px;
  border: 4px solid var(--ink);
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 6px 0 var(--ink);
  overflow: hidden;
}
.screen-trace .is-done .tr-card { animation: tr-card-in .6s .25s cubic-bezier(.3, 1.5, .5, 1) both; }
@keyframes tr-card-in { from { transform: scale(.6) rotate(-6deg); opacity: 0; } to { transform: none; opacity: 1; } }
.screen-trace .tr-pic { display: flex; flex-direction: column; align-items: center; gap: 8px; flex: none; }
.screen-trace .tr-card-emoji { font-size: 104px; line-height: 1.05; }
/* «B b»: capital and small letter, the one just written in red */
.screen-trace .tr-pair {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 3px 14px 0;
  border: 3px solid var(--ink);
  border-radius: 14px;
  background: #fff7d6;
  font-family: var(--read);
  font-weight: 700;
  font-size: 34px;
  line-height: 1.15;
  color: rgba(35, 32, 61, .5);
}
.screen-trace .tr-pair .is-cur { color: #e5322d; }
.screen-trace .is-done .tr-card-emoji { animation: tr-emoji-in .8s .45s cubic-bezier(.3, 1.8, .5, 1) both; }
@keyframes tr-emoji-in { from { transform: scale(.2) rotate(-25deg); } to { transform: none; } }
.screen-trace .tr-word { font-size: 50px; }
.screen-trace .tr-ten {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  padding: 7px;
  border: 3px solid var(--ink);
  border-radius: 14px;
  background: #f1eff8;
}
.screen-trace .tr-cell {
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2.5px solid rgba(35, 32, 61, .35);
  border-radius: 10px;
  background: #fff;
  font-size: 32px;
  line-height: 1;
}
.screen-trace .tr-cell.on { border-color: var(--ink); }
.screen-trace .is-done .tr-cell.on .emoji { display: inline-block; animation: tr-emoji-in .5s cubic-bezier(.3, 1.8, .5, 1) both; animation-delay: inherit; }

.screen-trace .tr-acts { flex: none; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding-bottom: 6px; }
.screen-trace .tr-acts .btn { width: 100%; }
.screen-trace .tr-acts .tr-frei { background: var(--rose); }
.screen-trace .tr-acts .tr-over .lbl { font-family: var(--read); font-size: calc(var(--lbl) * 1.15); letter-spacing: .03em; }
.screen-trace .tr-acts .tr-frei.is-has::after {
  content: "";
  position: absolute;
  right: -8px;
  top: -10px;
  width: 22px;
  height: 22px;
  border: 3px solid var(--ink);
  border-radius: 50%;
  background: var(--leaf) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%2323203d' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 80% no-repeat;
}
.screen-trace .tr-invite { animation: tr-invite 1.6s ease-in-out infinite; }
@keyframes tr-invite { 0%, 100% { transform: none; } 50% { transform: translateY(-3px) scale(1.05); } }

/* ---------- landscape: paper left, side column right ---------- */

@media (orientation: landscape) {
  .screen-trace .tr-play { flex-direction: row; }
  .screen-trace .tr-end { bottom: 0; width: var(--side-end); }
  .screen-trace .tr-over-view { flex-direction: row; gap: 18px; }
  .screen-trace .tr-tabs { flex-direction: column; justify-content: flex-start; padding: 6px 4px 8px 2px; }
  .screen-trace .tr-tab { flex: none; width: 170px; height: 96px; flex-direction: column; gap: 4px; }
  .screen-trace .tr-tab.on { transform: translateX(4px) rotate(-2deg); }
  .screen-trace .tr-scroll { flex: 1; }
}

/* ---------- portrait: paper on top, side row below ---------- */

@media (orientation: portrait) {
  .screen-trace { --side: 112px; --side-end: 316px; --tr-tile: 118px; }
  .screen-trace .tr-play { flex-direction: column; }
  .screen-trace .tr-end { right: 0; height: var(--side-end); }
  .screen-trace .tr-tools { flex-direction: row; padding: 4px 2px 8px; }
  .screen-trace .tr-navs { display: contents; }
  .screen-trace .tr-navs .btn:first-child { order: -1; }
  .screen-trace .tr-mid { flex: 1; flex-direction: row; justify-content: center; gap: 18px; }
  .screen-trace .tr-myst { width: 92px; height: 92px; }
  .screen-trace .tr-myst-e { font-size: 56px; }
  .screen-trace .tr-card { flex-direction: row; gap: 22px; }
  .screen-trace .tr-acts { grid-template-columns: repeat(4, 1fr); }
  .screen-trace .tr-acts.n3 { grid-template-columns: repeat(3, 1fr); }
}

/* phones in portrait */
@media (max-width: 640px) and (orientation: portrait) {
  .screen-trace { --side: 86px; --side-end: 246px; --tr-tile: 74px; }
  .screen-trace .tr-tabs { gap: 10px; padding-bottom: 6px; }
  .screen-trace .tr-tab { height: 64px; flex-direction: column; gap: 2px; border-radius: 20px; padding: 0 6px; }
  .screen-trace .tr-tab-name { font-size: 28px; padding-top: 2px; }
  .screen-trace .tr-tab-prog { font-size: 14px; padding: 1px 7px 1px 2px; }
  .screen-trace .tr-tab-prog .ic { width: 18px; height: 18px; }
  .screen-trace .tr-grid { gap: 12px; }
  .screen-trace .tr-tile { border-radius: 18px; border-width: 3px; box-shadow: 0 4px 0 var(--ink); }
  .screen-trace .tr-tile-stars .ic { width: 26px; height: 26px; }
  .screen-trace .tr-tile-stars .tr-star-frei { width: 22px; height: 22px; margin-top: 12px; }
  .screen-trace .tr-play { gap: 12px; }
  .screen-trace .tr-paper { border-radius: 24px; }
  .screen-trace .tr-tools { gap: 6px; padding: 2px 0 6px; }
  .screen-trace .tr-mid { gap: 10px; }
  .screen-trace .tr-myst { width: 66px; height: 66px; border-radius: 18px; border-width: 3px; box-shadow: 0 4px 0 var(--ink); }
  .screen-trace .tr-myst-e { font-size: 40px; }
  .screen-trace .tr-pips { gap: 5px; }
  .screen-trace .tr-pip { width: 28px; height: 28px; font-size: 14px; border-width: 2.5px; }
  .screen-trace .tr-pip.is-dot { width: 18px; height: 18px; }
  .screen-trace .tr-chip { font-size: 14px; padding: 3px 10px 3px 4px; }
  .screen-trace .tr-card { gap: 14px; padding: 10px; border-radius: 22px; }
  .screen-trace .tr-card-emoji { font-size: 70px; }
  .screen-trace .tr-pair { font-size: 24px; gap: 6px; padding: 2px 10px 0; border-radius: 11px; border-width: 2.5px; }
  .screen-trace .tr-word { font-size: 38px; }
  .screen-trace .tr-card.is-digit { flex-direction: column; gap: 6px; }
  .screen-trace .tr-card.is-digit .tr-word { font-size: 30px; }
  .screen-trace .tr-cell { width: 32px; height: 32px; font-size: 22px; border-radius: 8px; }
  .screen-trace .tr-ten { gap: 4px; padding: 5px; }
  .screen-trace .tr-acts { gap: 8px; }
  .screen-trace .tr-acts .btn { --btn: 74px; --ic: 34px; --lbl: 12px; }
}

/* phones in landscape */
@media (max-height: 520px) and (orientation: landscape) {
  .screen-trace { --side: 112px; --side-end: 300px; --tr-tile: 84px; }
  .screen-trace .tr-over-view { gap: 12px; }
  .screen-trace .tr-tabs { gap: 10px; padding-top: 4px; }
  .screen-trace .tr-tab { width: 112px; height: 76px; border-radius: 20px; gap: 2px; }
  .screen-trace .tr-tab-name { font-size: 28px; }
  .screen-trace .tr-tab-prog { font-size: 14px; }
  .screen-trace .tr-tab-prog .ic { width: 18px; height: 18px; }
  .screen-trace .tr-grid { gap: 12px; }
  .screen-trace .tr-scroll { padding-top: 6px; }
  .screen-trace .tr-tile { border-radius: 18px; border-width: 3px; box-shadow: 0 4px 0 var(--ink); }
  .screen-trace .tr-tile-stars .ic { width: 26px; height: 26px; }
  .screen-trace .tr-tile-stars .tr-star-frei { width: 22px; height: 22px; margin-top: 12px; }
  .screen-trace .tr-play { gap: 12px; padding-bottom: 4px; }
  .screen-trace .tr-paper { border-radius: 22px; border-width: 3px; box-shadow: 0 5px 0 var(--ink); }
  .screen-trace .tr-tools { gap: 6px; padding-bottom: 4px; }
  .screen-trace .tr-mid { gap: 8px; }
  .screen-trace .tr-myst { width: 76px; height: 76px; border-radius: 18px; border-width: 3px; box-shadow: 0 4px 0 var(--ink); }
  .screen-trace .tr-myst-e { font-size: 46px; }
  .screen-trace .tr-pips { gap: 5px; }
  .screen-trace .tr-pip { width: 28px; height: 28px; font-size: 14px; border-width: 2.5px; }
  .screen-trace .tr-pip.is-dot { width: 18px; height: 18px; }
  .screen-trace .tr-navs { gap: 8px; }
  .screen-trace .tr-chip { font-size: 13px; padding: 3px 8px 3px 4px; }
  .screen-trace .tr-chip .ic { width: 22px; height: 22px; }
  .screen-trace .tr-end { gap: 8px; }
  .screen-trace .tr-card { flex-direction: row; gap: 12px; padding: 8px 10px; border-radius: 22px; border-width: 3px; box-shadow: 0 5px 0 var(--ink); }
  .screen-trace .tr-card-emoji { font-size: 56px; }
  .screen-trace .tr-pair { font-size: 22px; gap: 5px; padding: 1px 9px 0; border-radius: 10px; border-width: 2.5px; }
  .screen-trace .tr-word { font-size: 32px; }
  .screen-trace .tr-card.is-digit { flex-direction: column; gap: 4px; }
  .screen-trace .tr-card.is-digit .tr-word { font-size: 26px; }
  .screen-trace .tr-cell { width: 28px; height: 28px; font-size: 19px; border-radius: 7px; border-width: 2px; }
  .screen-trace .tr-ten { gap: 3px; padding: 4px; border-width: 2.5px; }
  .screen-trace .tr-acts { gap: 8px; padding-bottom: 4px; }
  .screen-trace .tr-acts .btn { --btn: 60px; --ic: 28px; --lbl: 11.5px; }
}
