/* The site's fennec fox (site-fox.js) */

.site-fox,
.site-search-fox {
  --fox-body: #f7b55e;
}

.site-fox {
  position: relative;
  display: block;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink, #000);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.site-fox:focus-visible {
  outline: 3px solid var(--ink, #000);
  outline-offset: 4px;
  border-radius: 12px;
}

.site-fox-fig {
  display: block;
  transform-origin: 50% 100%;
  filter: drop-shadow(2px 3px 0 var(--ink, #000));
}

.site-fox-svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  stroke: var(--ink, #000);
  stroke-width: 8;
  stroke-linejoin: round;
  stroke-linecap: round;
  /* The cartoon titles draw their stroke under the fill, which would hide
     half of every line on the perched fox. */
  paint-order: normal;
}

/* The head's line again, above the snout so it stays whole (site-fox.js). */
.site-fox-svg .f-line { fill: none; }

/* Each animal brings its own colors on the <svg> (site-fox.js). */
.site-fox-svg .f-body { fill: var(--fox-body); }
.site-fox-svg .f-cream { fill: var(--fox-cream, #fff1d9); stroke: none; }
.site-fox-svg .f-light { fill: var(--fox-cream, #fff1d9); }
.site-fox-svg .f-dark { fill: var(--fox-dark, #3a4050); }
.site-fox-svg .f-patch { fill: var(--fox-dark, #3a4050); stroke: none; }
.site-fox-svg .f-pink { fill: #f6a8b9; stroke: none; }
.site-fox-svg .f-tongue { stroke-width: 3.5; }
.site-fox-svg .f-tooth { fill: #fff; stroke-width: 3.5; }
.site-fox-svg .f-thin { fill: none; stroke-width: 4; }
.site-fox-svg .f-tail-out { fill: none; stroke-width: 11; }
.site-fox-svg .f-tail-in { fill: none; stroke: var(--fox-body); stroke-width: 4; }
.site-fox-svg .f-pupil { fill: var(--ink, #000); stroke: none; }
.site-fox-svg .f-nose { fill: var(--ink, #000); stroke: none; }
.site-fox-svg .f-cap { fill: #3a4050; }

/* The panda: white eyes in its black patches, and a black body. */
.site-fox-svg[data-animal="panda"] .f-pupil { fill: #fff; }
.site-fox-svg[data-animal="panda"] .f-torso { fill: var(--fox-dark); }

.site-fox-svg .fox-pupils {
  transition: transform 0.15s ease-out;
}

/* Blinks by squashing the eyes. */
.site-fox-svg .fox-eyes {
  transform-box: fill-box;
  transform-origin: 50% 50%;
  animation: site-fox-blink 4.6s var(--fox-blink-delay, 0s) infinite;
}

/* The ears turn on their base, the tail on where it meets the body. */
.site-fox-svg .fox-ear,
.site-fox-svg .fox-tail {
  transform-box: fill-box;
}

.site-fox-svg .fox-ear-l { transform-origin: 80% 90%; }
.site-fox-svg .fox-ear-r { transform-origin: 20% 90%; }
.site-fox-svg .fox-tail { transform-origin: 5% 80%; }

/* The dog's ears hang, so they swing from the top. */
.site-fox-svg[data-animal="dog"] .fox-ear-l { transform-origin: 85% 5%; }
.site-fox-svg[data-animal="dog"] .fox-ear-r { transform-origin: 15% 5%; }

@keyframes site-fox-blink {
  0%, 93%, 98%, 100% { transform: none; }
  95.5% { transform: scaleY(0.15); }
}

/* Tapped: a hop with a squash, the ears flop twice and the tail wags. */
.site-fox.is-hop .site-fox-fig {
  animation: site-fox-hop 0.7s ease-in-out;
}

.site-fox.is-hop .fox-ear-l { animation: site-fox-ear-l 0.35s ease-in-out 2; }
.site-fox.is-hop .fox-ear-r { animation: site-fox-ear-r 0.35s ease-in-out 2; }
.site-fox.is-hop .fox-tail { animation: site-fox-wag 0.35s ease-in-out 2; }

/* Somersaulting with the letter under it (site-fox.js) turns on its middle. */
.site-fox.is-flip .site-fox-fig { transform-origin: 50% 50%; }
.site-fox.is-flip .fox-ear-l { animation: site-fox-ear-l 0.42s ease-in-out 2; }
.site-fox.is-flip .fox-ear-r { animation: site-fox-ear-r 0.42s ease-in-out 2; }
.site-fox.is-flip .fox-tail { animation: site-fox-wag 0.42s ease-in-out 2; }

@keyframes site-fox-hop {
  0%, 100% { transform: none; }
  15% { transform: scale(1.12, 0.86); }
  45% { transform: translateY(-22%) scale(0.94, 1.08); }
  75% { transform: scale(1.1, 0.9); }
}

@keyframes site-fox-ear-l {
  50% { transform: rotate(-16deg); }
}

@keyframes site-fox-ear-r {
  50% { transform: rotate(16deg); }
}

@keyframes site-fox-wag {
  50% { transform: rotate(-18deg); }
}

/* Speech bubble */
.site-fox-bubble {
  position: absolute;
  bottom: calc(100% + 12px);
  right: 0;
  width: max-content;
  max-width: min(230px, calc(100vw - 32px));
  padding: 10px 14px;
  border: 3px solid var(--ink, #000);
  border-radius: 16px;
  background: #eaf5ff;
  box-shadow: 4px 5px 0 var(--ink, #000);
  color: var(--ink, #000);
  -webkit-text-fill-color: var(--ink, #000);
  -webkit-text-stroke: 0;
  font-family: var(--font-sans, system-ui, sans-serif);
  font-size: 17px;
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: 0;
  white-space: normal;
  text-align: start;
  text-shadow: none;
  pointer-events: none;
  opacity: 0;
  translate: 0 8px;
  scale: 0.9;
  transform-origin: 85% 100%;
  transition: opacity 0.2s ease, translate 0.2s ease, scale 0.2s ease;
}

.site-fox-bubble::after {
  content: "";
  position: absolute;
  right: 22px;
  bottom: -9px;
  width: 14px;
  height: 14px;
  border-right: 3px solid var(--ink, #000);
  border-bottom: 3px solid var(--ink, #000);
  background: #eaf5ff;
  rotate: 45deg;
}

.site-fox-bubble:empty {
  display: none;
}

.site-fox-bubble.is-on {
  opacity: 1;
  translate: 0 0;
  scale: 1;
}

/* The corner fox. !important: styles.css pins every direct child of body to
   position:relative and z-index:1. Below the mobile menu (150). */
.site-fox-dock {
  position: fixed !important;
  z-index: 140 !important;
  right: max(14px, env(safe-area-inset-right, 0px));
  bottom: max(14px, env(safe-area-inset-bottom, 0px));
  width: 64px;
  transform-origin: 50% 100%;
  transition: opacity 0.3s ease, scale 0.3s ease, translate 0.3s ease, visibility 0s;
}

@media (min-width: 900px) {
  .site-fox-dock {
    right: 22px;
    bottom: 22px;
    width: 76px;
  }
}

.site-fox-dock.is-away {
  opacity: 0;
  scale: 0.4;
  translate: 0 24px;
  visibility: hidden;
  transition: opacity 0.3s ease, scale 0.3s ease, translate 0.3s ease, visibility 0s 0.3s;
}

/* The button that shows the page's guide (site-fox.js), at the bottom of the
   list the fox opens. */
.site-guide-btn {
  flex-shrink: 0;
  align-self: center;
  margin: 14px 0 4px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding-block: 6px;
  padding-inline: 7px 13px;
  font: 900 15px/1.1 var(--font-sans, system-ui, sans-serif);
  color: #000;
  -webkit-text-fill-color: #000;
  -webkit-text-stroke: 0;
  text-shadow: none;
  background: #ffa8cf;
  border: 3px solid var(--ink, #000);
  border-radius: 999px;
  box-shadow: 3px 4px 0 var(--ink, #000);
  cursor: pointer;
}

.site-guide-btn:active {
  translate: 2px 3px;
  box-shadow: 1px 1px 0 var(--ink, #000);
}

.site-guide-btn-icon {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--ink, #000);
  color: #fff;
  -webkit-text-fill-color: #fff;
  font-size: 15px;
}

.eng-runner-open .site-fox-dock,
.eng-viewer-open .site-fox-dock,
.eng-help-open .site-fox-dock,
.cg-open .site-fox-dock,
.lb-open .site-fox-dock,
.adm-info-open .site-fox-dock,
.lesson-player-expanded .site-fox-dock,
.coloring-zoom-open .site-fox-dock,
.in-room .site-fox-dock,
body:has(.modal-overlay:not(.hidden), .lesson-player:not(.hidden), [aria-modal="true"]:not(.hidden, [hidden], .hidden *, [aria-hidden="true"])) .site-fox-dock {
  display: none;
}

/* The big fox perched on the hero title */
.site-fox-perch {
  position: relative;
  display: block;
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
}

.site-fox--hero {
  position: absolute;
  inset-inline-start: 0.06em;
  bottom: calc(100% - 0.18em);
  width: clamp(66px, 1.3em, 146px);
}

/* Sections clip their overflow (clean-site.css); the home one only sideways,
   so the fox can somersault up past its top with the first letter. */
#home.clean-section--hero {
  overflow-x: clip;
  overflow-y: visible;
}

.site-fox-perch--name .site-fox--hero {
  inset-inline-start: 2%;
  bottom: 80%;
  width: clamp(62px, 11vw, 104px);
}

/* Above the fox there is little room under the navbar — so the bubble sits
   beside the fox, over the room left above the title. */
.site-fox--hero .site-fox-bubble {
  top: 50%;
  bottom: auto;
  right: calc(100% + 12px);
  max-width: min(230px, 50vw);
  translate: 8px -50%;
  transform-origin: 100% 50%;
}

.site-fox--hero .site-fox-bubble.is-on {
  translate: 0 -50%;
}

.site-fox--hero .site-fox-bubble::after {
  top: calc(50% - 7px);
  right: -9px;
  bottom: auto;
  border-top: 3px solid var(--ink, #000);
  border-bottom: 0;
}

/* On wide screens a big title's fox stands taller than the room above it,
   and the hero clips its top — the title moves down just enough for the
   whole fox (its height is ~1.1× its width). :where() keeps page rules
   (English page, my room) in charge. */
@media (min-width: 701px) {
  :where(.clean-section--hero:not(#home)) .site-fox-perch--line {
    margin-top: max(0px, calc(min(1.43em, 161px) - 0.18em - 94px));
  }
}

/* On phones the title sits right under the navbar, which would hide the
   fox's ears — the title moves down to make room. */
@media (max-width: 700px) {
  /* The hero section clips its overflow, so a small title still leaves room
     for the whole fox. */
  .site-fox-perch--line {
    margin-top: max(1.05em, 74px);
  }

  .site-fox-perch--name {
    margin-top: 64px;
  }
}

/* Lands on the title once it has come in. */
.site-fox--hero .site-fox-fig {
  animation: site-fox-land 0.8s linear 0.6s backwards;
}

/* Without this, the landing would replay after every hop. */
.site-fox--hero.is-landed:not(.is-hop) .site-fox-fig {
  animation: none;
}

@keyframes site-fox-land {
  0% {
    translate: 0 -160%;
    opacity: 0;
    animation-timing-function: cubic-bezier(0.55, 0, 1, 0.45);
  }
  20% { opacity: 1; }
  55% {
    translate: 0 0;
    scale: 1;
    animation-timing-function: ease-out;
  }
  70% { scale: 1.16 0.84; }
  86% { scale: 0.95 1.06; }
  100% {
    translate: 0 0;
    scale: 1;
    opacity: 1;
  }
}

/* The search the fox opens (site-fox.js). !important: see .site-fox-dock.
   Above the navbar (1000) and its menu button, under the dialogs. */
.site-search {
  position: fixed !important;
  inset: 0;
  z-index: 1100 !important;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: max(16px, env(safe-area-inset-top, 0px)) 16px 16px;
  font-family: var(--font-sans, system-ui, sans-serif);
  color: var(--ink, #000);
}

.site-search[hidden] {
  display: none;
}

.site-search-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
}

.site-search-box {
  position: relative;
  display: flex;
  flex-direction: column;
  width: min(100%, 520px);
  max-height: calc(100dvh - 32px);
  margin-top: min(8vh, 64px);
  padding: 16px 18px 12px;
  background: #b9e2ff;
  border: 3px solid var(--ink, #000);
  border-radius: 24px;
  box-shadow: 6px 8px 0 var(--ink, #000);
}

@media (max-width: 700px) {
  .site-search-box {
    margin-top: 0;
  }
}

/* Fox | title in the middle | X — the two sides the same width, so the title
   sits in the true middle of the box. */
.site-search-head {
  display: grid;
  grid-template-columns: 46px 1fr 46px;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.site-search-head .site-search-close {
  justify-self: end;
}

.site-search-fox {
  flex-shrink: 0;
  width: 46px;
  filter: drop-shadow(2px 3px 0 var(--ink, #000));
}

.site-search-fox .site-fox-svg .fox-eyes {
  animation: none;
}

.site-search-title {
  min-width: 0;
  margin: 0;
  text-align: center;
  font-size: 24px;
  font-weight: 900;
  line-height: 1.2;
  color: #000;
}

.site-search-key {
  padding: 0 0.18em;
  border-radius: 6px;
  background: color-mix(in srgb, var(--memteal, #00e5cc) 45%, #fff);
}

.site-search-close {
  flex-shrink: 0;
  position: relative;
  width: 40px;
  height: 40px;
  padding: 0;
  background: #ff5a5a;
  border: 3px solid var(--ink, #000);
  border-radius: 50%;
  box-shadow: 3px 4px 0 var(--ink, #000);
  cursor: pointer;
}

/* The X */
.site-search-close::before,
.site-search-close::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 3px;
  margin: -1.5px 0 0 -9px;
  border-radius: 2px;
  background: var(--ink, #000);
  rotate: 45deg;
}

.site-search-close::after {
  rotate: -45deg;
}

.site-search-field {
  position: relative;
  display: block;
}

.site-search-icon {
  position: absolute;
  top: 50%;
  inset-inline-start: 14px;
  width: 22px;
  height: 22px;
  translate: 0 -50%;
  fill: none;
  stroke: var(--ink, #000);
  stroke-width: 2.6;
  stroke-linecap: round;
  pointer-events: none;
}

.site-search-input {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  padding-inline-start: 46px;
  font: inherit;
  font-size: 18px;
  font-weight: 700;
  color: #000;
  background: #fff3f8;
  border: 3px solid var(--ink, #000);
  border-radius: 16px;
  box-shadow: 3px 4px 0 var(--ink, #000);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.site-search-input:focus-visible {
  border-color: var(--ink, #000);
  box-shadow: 3px 4px 0 var(--ink, #000), 0 0 0 4px var(--memyellow, #ffe066);
}

.site-search-input::-webkit-search-cancel-button {
  display: none;
}

.site-search-note {
  margin: 12px 4px 0;
  font-size: 16px;
  font-weight: 700;
  color: #333;
}

.site-search-note:empty {
  display: none;
}

.site-search-results {
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.site-search-results:empty {
  display: none;
}

.site-search-results li + li {
  border-top: 2px solid #c9d6e2;
}

.site-search-hit {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 8px;
  border-radius: 10px;
  color: #000;
  text-decoration: none;
}

.site-search-hit:hover,
.site-search-hit:focus-visible {
  background: color-mix(in srgb, var(--memyellow, #ffe066) 55%, #fff);
  outline: none;
}

.site-search-hit-title {
  font-size: 17px;
  font-weight: 800;
  line-height: 1.3;
}

.site-search-hit-kind {
  flex-shrink: 0;
  font-size: 13px;
  font-weight: 700;
  color: #555;
}

html.site-search-open,
html.site-search-open body {
  overflow: hidden;
}

/* The search, or the talk with the fox ("שאלו את השועל", site-fox.js): one
   of the two shows in the box. */
.site-search-view,
.site-chat {
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.site-search.is-chat .site-search-view,
.site-search:not(.is-chat) .site-chat {
  display: none;
}

.site-search-view .site-search-results {
  min-height: 0;
}

/* The bottom row: "AI" (the talk with the fox) beside "הפעלת מדריך". */
.site-search-actions {
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin: 14px 0 4px;
}

.site-search-actions .site-guide-btn {
  margin: 0;
}

/* Same pill as the guide button, in teal. */
.site-ask-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding-block: 6px;
  padding-inline: 7px 14px;
  font: 900 15px/1.1 var(--font-sans, system-ui, sans-serif);
  color: #000;
  -webkit-text-fill-color: #000;
  -webkit-text-stroke: 0;
  text-shadow: none;
  background: color-mix(in srgb, var(--memteal, #00e5cc) 55%, #fff);
  border: 3px solid var(--ink, #000);
  border-radius: 999px;
  box-shadow: 3px 4px 0 var(--ink, #000);
  cursor: pointer;
  transition: scale 0.15s ease;
}

.site-ask-btn:hover,
.site-search-actions .site-guide-btn:hover {
  scale: 1.05;
}

.site-search-actions .site-guide-btn {
  transition: scale 0.15s ease;
}

.site-ask-btn:active,
.site-chat-send:active,
.site-chat-chip:active,
.site-chat-foot button:active {
  translate: 2px 3px;
  box-shadow: 1px 1px 0 var(--ink, #000);
}

.site-ask-btn-icon {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--ink, #000);
}

.site-ask-btn-icon svg {
  width: 15px;
  height: 15px;
  fill: #fff;
}

.site-ask-btn-text {
  direction: ltr;
}

/* Tall enough for a talk, and the same height all along it. */
.site-search.is-chat .site-search-box {
  height: min(660px, calc(100dvh - 32px - min(8vh, 64px)));
}

@media (max-width: 700px) {
  .site-search.is-chat .site-search-box {
    height: calc(100dvh - 32px);
  }
}

.site-chat {
  flex: 1;
}

.site-chat-log {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0;
  padding: 4px 4px 8px;
  list-style: none;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.site-chat-msg {
  position: relative;
  max-width: 88%;
  padding: 10px 14px;
  color: #000;
  border: 3px solid var(--ink, #000);
  border-radius: 18px;
  box-shadow: 3px 4px 0 var(--ink, #000);
}

/* The fox on the start side (right), the reader on the other. */
.site-chat-msg--fox {
  align-self: flex-start;
  background: #fff1d9;
  border-start-start-radius: 6px;
}

.site-chat-msg--me {
  align-self: flex-end;
  background: color-mix(in srgb, var(--memteal, #00e5cc) 35%, #eaf5ff);
  border-start-end-radius: 6px;
}

.site-chat-text {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.4;
}

.site-chat-line {
  display: block;
}

.site-chat-links {
  display: grid;
  gap: 8px;
  margin: 10px 0 2px;
  padding: 0;
  list-style: none;
}

.site-chat-link {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 12px;
  color: #000;
  text-decoration: none;
  background: color-mix(in srgb, var(--memyellow, #ffe066) 55%, #fff);
  border: 2.5px solid var(--ink, #000);
  border-radius: 12px;
  box-shadow: 2px 3px 0 var(--ink, #000);
  transition: scale 0.15s ease;
}

.site-chat-link:hover,
.site-chat-link:focus-visible {
  scale: 1.03;
  outline: none;
}

.site-chat-link:focus-visible {
  box-shadow: 2px 3px 0 var(--ink, #000), 0 0 0 3px var(--memteal, #00e5cc);
}

.site-chat-link-title {
  font-size: 17px;
  font-weight: 900;
  line-height: 1.25;
}

.site-chat-link-kind {
  font-size: 13px;
  font-weight: 700;
  color: #444;
}

.site-chat-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.site-chat-chip {
  padding: 6px 12px;
  font: 800 15px/1.2 var(--font-sans, system-ui, sans-serif);
  color: #000;
  -webkit-text-fill-color: #000;
  background: #ffd6e8;
  border: 2.5px solid var(--ink, #000);
  border-radius: 999px;
  box-shadow: 2px 3px 0 var(--ink, #000);
  cursor: pointer;
  transition: scale 0.15s ease;
}

.site-chat-chip:hover {
  scale: 1.05;
}

/* The fox is writing: three dots. */
.site-chat-typing {
  display: flex;
  gap: 6px;
  padding: 14px 16px;
}

.site-chat-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--ink, #000);
  animation: site-chat-dot 1s ease-in-out infinite;
}

.site-chat-dot:nth-child(2) {
  animation-delay: 0.15s;
}

.site-chat-dot:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes site-chat-dot {
  0%, 60%, 100% { translate: 0 0; opacity: 0.45; }
  30% { translate: 0 -5px; opacity: 1; }
}

.site-chat-form {
  flex-shrink: 0;
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.site-chat-input {
  flex: 1;
  min-width: 0;
  box-sizing: border-box;
  padding: 11px 14px;
  font: inherit;
  font-size: 17px;
  font-weight: 700;
  color: #000;
  background: #fff3f8;
  border: 3px solid var(--ink, #000);
  border-radius: 16px;
  box-shadow: 3px 4px 0 var(--ink, #000);
  outline: none;
}

.site-chat-input:focus-visible {
  box-shadow: 3px 4px 0 var(--ink, #000), 0 0 0 4px var(--memyellow, #ffe066);
}

.site-chat-send {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 52px;
  padding: 0;
  background: color-mix(in srgb, var(--memteal, #00e5cc) 55%, #fff);
  border: 3px solid var(--ink, #000);
  border-radius: 16px;
  box-shadow: 3px 4px 0 var(--ink, #000);
  cursor: pointer;
  transition: scale 0.15s ease;
}

.site-chat-send:hover:not(:disabled) {
  scale: 1.05;
}

.site-chat-send:disabled {
  opacity: 0.5;
  cursor: default;
}

.site-chat-send svg,
.site-chat-back svg {
  fill: none;
  stroke: var(--ink, #000);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.site-chat-send svg {
  width: 26px;
  height: 26px;
}

.site-chat-foot {
  flex-shrink: 0;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
}

.site-chat-foot button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  font: 800 15px/1.2 var(--font-sans, system-ui, sans-serif);
  color: #000;
  -webkit-text-fill-color: #000;
  background: #fff1d9;
  border: 2.5px solid var(--ink, #000);
  border-radius: 999px;
  box-shadow: 2px 3px 0 var(--ink, #000);
  cursor: pointer;
  transition: scale 0.15s ease;
}

.site-chat-foot button:hover {
  scale: 1.04;
}

.site-chat-back svg {
  width: 18px;
  height: 18px;
}

/* The fox in the box's top hops when it answers. */
.site-search-fox.is-talk {
  animation: site-search-fox-talk 0.5s ease-out;
}

@keyframes site-search-fox-talk {
  0%, 100% { translate: 0 0; scale: 1; }
  35% { translate: 0 -8px; scale: 0.96 1.06; }
  70% { translate: 0 0; scale: 1.08 0.92; }
}

@media (prefers-reduced-motion: reduce) {
  .site-chat-dot,
  .site-search-fox.is-talk {
    animation: none;
  }
}

/* The guide (site-fox.js). !important: see .site-fox-dock. Above an open
   lesson, even at full screen (lesson-player.css). */
.site-tour {
  position: fixed !important;
  inset: 0;
  z-index: 6000 !important;
  font-family: var(--font-sans, system-ui, sans-serif);
  color: #000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.site-tour.is-on {
  opacity: 1;
  pointer-events: auto;
}

/* The lit part: everything around it is dark, and a yellow ring glows. */
.site-tour-hole {
  position: absolute;
  border-radius: 18px;
  box-shadow:
    0 0 0 3px var(--memyellow, #ffe066),
    0 0 22px 8px rgba(255, 224, 102, 0.55),
    0 0 0 200vmax rgba(0, 0, 0, 0.62);
  pointer-events: none;
}

.site-tour-hole::after {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: inherit;
  animation: site-tour-pulse 1.6s ease-out infinite;
}

@keyframes site-tour-pulse {
  from { box-shadow: 0 0 0 0 rgba(255, 224, 102, 0.9); }
  to { box-shadow: 0 0 0 14px rgba(255, 224, 102, 0); }
}

.site-tour.is-on .site-tour-hole {
  transition: left 0.3s ease, top 0.3s ease, width 0.3s ease, height 0.3s ease, border-radius 0.3s ease;
}

.site-tour-card {
  position: absolute;
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 4px 12px;
  width: min(360px, calc(100vw - 24px));
  box-sizing: border-box;
  padding: 14px 16px 12px;
  background: #eaf5ff;
  border: 3px solid var(--ink, #000);
  border-radius: 20px;
  box-shadow: 5px 6px 0 var(--ink, #000);
  text-align: start;
  -webkit-text-fill-color: #000;
  -webkit-text-stroke: 0;
  text-shadow: none;
}

.site-tour.is-on .site-tour-card {
  transition: left 0.3s ease, top 0.3s ease;
}

.site-fox--tour {
  align-self: start;
  width: 54px;
  cursor: default;
}

.site-tour-title {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 900;
  line-height: 1.25;
  color: #000;
}

.site-tour-key {
  padding: 0 0.18em;
  border-radius: 6px;
  background: color-mix(in srgb, var(--memteal, #00e5cc) 45%, #fff);
}

.site-tour-text {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.4;
  color: #000;
}

.site-tour-line {
  display: block;
}

.site-tour-foot {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.site-tour-count {
  margin-inline-end: auto;
  font-size: 15px;
  font-weight: 800;
  color: #333;
}

.site-tour-skip,
.site-tour-next {
  font: inherit;
  color: #000;
  cursor: pointer;
}

.site-tour-skip {
  padding: 8px 10px;
  background: none;
  border: 0;
  font-size: 16px;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.site-tour-skip[hidden] {
  display: none;
}

.site-tour-next {
  min-width: 88px;
  padding: 8px 18px;
  background: var(--memteal, #00e5cc);
  border: 3px solid var(--ink, #000);
  border-radius: 14px;
  box-shadow: 3px 4px 0 var(--ink, #000);
  font-size: 17px;
  font-weight: 900;
}

/* The guide puts the focus on "הבא" itself, so no ring around it. */
.site-tour-skip:focus,
.site-tour-next:focus {
  outline: none;
}

@media (prefers-reduced-motion: reduce) {
  .site-fox .site-fox-fig,
  .site-fox .fox-ear,
  .site-fox .fox-tail,
  .site-fox-svg .fox-eyes {
    animation: none !important;
  }
  .site-fox-dock,
  .site-fox-bubble,
  .site-tour,
  .site-tour.is-on .site-tour-hole,
  .site-tour.is-on .site-tour-card {
    transition: none;
  }
  .site-tour-hole::after {
    animation: none;
  }
}

html[data-visual="minimal"] .site-fox .site-fox-fig,
html[data-visual="minimal"] .site-fox .fox-ear,
html[data-visual="minimal"] .site-fox .fox-tail,
html[data-visual="minimal"] .site-fox-svg .fox-eyes {
  animation: none !important;
}

@media print {
  .site-fox-dock,
  .site-fox--hero,
  .site-tour {
    display: none !important;
  }
}
