/* Word-Search.org site styles (pages around the game). Tokens: --ws-* from /assets/theme.css (game, part B) when present;
   the :where() blocks below only supply defaults (zero specificity), so the game's theme.css always wins. */
:where(:root) {
  --ws-bg: #f4e7d1; --ws-bg-image: radial-gradient(125% 95% at 50% -10%, #fdf7ec 0%, #f6e9d5 55%, #eeddc6 100%);
  --ws-accent: #7b4fd0; --ws-accent-d: #5b34a8; --ws-accent-soft: rgba(123, 79, 208, .13);
  --ws-ink: #48412f; --ws-soft: #7c7461; --ws-line: rgba(120, 80, 20, .12);
  --ws-card: #fdfaf3; --ws-shadow: 0 8px 24px rgba(120, 80, 20, .09);
  --ws-btn: #fffdf8; --ws-btn-ink: #6b6350;
  --ws-tooltip: #3b3528; --ws-tooltip-ink: #fffdf8; --ws-scroll-thumb: rgba(0, 0, 0, .18);
  --ws-surface: #fffaf1; --ws-cell-ink: #4a4060; --ws-hint: #2f7d74; --ws-link: #5b34a8;
  --ws-c0: #f7a74a; --ws-c1: #5fb3f0; --ws-c2: #8cc95a; --ws-c3: #f07fa6; --ws-c4: #a98bef;
  --ws-c5: #f5c842; --ws-c6: #4fc9b4; --ws-c7: #ef8a74; --ws-c8: #8aa0ff; --ws-c9: #d9a36a;
  --ws-font-ui: 'Fredoka', 'Nunito', system-ui, sans-serif;
  --ws-font-body: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
:where(html[data-theme="dark"]) {
  color-scheme: dark;
  --ws-bg: #16141d; --ws-bg-image: radial-gradient(125% 95% at 50% -10%, #25222f 0%, #1a1822 50%, #121019 100%);
  --ws-accent: #a07ff0; --ws-accent-d: #8a64e6; --ws-accent-soft: rgba(160, 127, 240, .18);
  --ws-ink: #eeecf4; --ws-soft: #aaa6b9; --ws-line: rgba(255, 255, 255, .09);
  --ws-card: #262330; --ws-shadow: 0 10px 28px rgba(0, 0, 0, .45); --ws-btn: #2a2734; --ws-btn-ink: #d2cfdb;
  --ws-tooltip: #eeecf4; --ws-tooltip-ink: #1c1a24; --ws-scroll-thumb: rgba(255, 255, 255, .22);
  --ws-surface: #2e2a39; --ws-cell-ink: #ebe7f5; --ws-hint: #5cc2b5; --ws-link: #b9a0f5;
}
@media (prefers-color-scheme: dark) {
  :where(html:not([data-theme="light"])) {
    color-scheme: dark;
    --ws-bg: #16141d; --ws-bg-image: radial-gradient(125% 95% at 50% -10%, #25222f 0%, #1a1822 50%, #121019 100%);
    --ws-accent: #a07ff0; --ws-accent-d: #8a64e6; --ws-accent-soft: rgba(160, 127, 240, .18);
    --ws-ink: #eeecf4; --ws-soft: #aaa6b9; --ws-line: rgba(255, 255, 255, .09);
    --ws-card: #262330; --ws-shadow: 0 10px 28px rgba(0, 0, 0, .45); --ws-btn: #2a2734; --ws-btn-ink: #d2cfdb;
    --ws-tooltip: #eeecf4; --ws-tooltip-ink: #1c1a24; --ws-scroll-thumb: rgba(255, 255, 255, .22);
    --ws-surface: #2e2a39; --ws-cell-ink: #ebe7f5; --ws-hint: #5cc2b5; --ws-link: #b9a0f5;
  }
}
/* site-only tokens */
:root { --ws-header-h: 56px; --ws-x: #000; --ws-header-bg: rgba(253, 250, 243, .88); --ws-pop-shadow: 0 18px 48px rgba(50, 30, 8, .22); --ws-glass: rgba(253, 250, 243, .82); }
html[data-theme="dark"] { --ws-x: #e7e9ea; --ws-header-bg: rgba(38, 35, 48, .88); --ws-pop-shadow: 0 18px 48px rgba(0, 0, 0, .55); --ws-glass: rgba(38, 35, 48, .82); }
@media (prefers-color-scheme: dark) { html:not([data-theme="light"]) { --ws-x: #e7e9ea; --ws-header-bg: rgba(38, 35, 48, .88); --ws-pop-shadow: 0 18px 48px rgba(0, 0, 0, .55); --ws-glass: rgba(38, 35, 48, .82); } }
:lang(ru), :lang(uk), :lang(cs), :lang(hu), :lang(pl), :lang(ro), :lang(tr) { --ws-font-ui: var(--ws-font-body); }
@media (min-width: 760px) { :root { --ws-header-h: 64px; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scrollbar-width: thin; scrollbar-color: var(--ws-scroll-thumb) transparent; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--ws-scroll-thumb); border-radius: 999px; }
::-webkit-scrollbar-button { display: none; width: 0; height: 0; }
body {
  margin: 0; min-height: 100vh;
  font-family: var(--ws-font-body); font-size: 16px; line-height: 1.6; color: var(--ws-ink);
  background-color: var(--ws-bg); background-image: var(--ws-bg-image); background-attachment: fixed;
  overflow-x: hidden;
}
img, svg { max-width: 100%; }
a { color: var(--ws-link); }
h1, h2, h3 { font-family: var(--ws-font-ui); color: var(--ws-ink); font-weight: 600; line-height: 1.15; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--ws-accent); outline-offset: 2px; border-radius: 6px; }
.ws-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.ws-skip { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 999px; background: var(--ws-accent-d); color: #fff; font-weight: 700; text-decoration: none; }
.ws-skip:focus { top: 10px; }
.ws-i { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }

/* ---------- header ---------- */
.ws-header { position: sticky; top: 0; z-index: 50; height: var(--ws-header-h); background: var(--ws-header-bg); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--ws-line); }
.ws-header__in { max-width: 1180px; height: 100%; margin: 0 auto; padding: 0 12px; display: flex; align-items: center; gap: 10px; }
.ws-logo { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; color: var(--ws-ink); flex: 0 0 auto; border-radius: 12px; }
.ws-logo svg { width: 34px; height: 34px; display: block; }
.ws-logo__word { font-family: 'Fredoka', var(--ws-font-ui); font-weight: 600; font-size: 24px; letter-spacing: -.3px; line-height: 1; white-space: nowrap; }
.ws-logo__word b { font-weight: 600; color: var(--ws-accent-d); margin-left: .22em; }
html[data-theme="dark"] .ws-logo__word b { color: var(--ws-link); }
@media (prefers-color-scheme: dark) { html:not([data-theme="light"]) .ws-logo__word b { color: var(--ws-link); } }
.ws-nav { display: flex; align-items: center; gap: 2px; margin-left: 14px; }
.ws-nav a { font-family: var(--ws-font-ui); font-weight: 600; font-size: 15.5px; color: var(--ws-soft); text-decoration: none; padding: 8px 13px; border-radius: 999px; white-space: nowrap; transition: color .15s, background .15s; }
.ws-nav a:hover { color: var(--ws-ink); background: var(--ws-accent-soft); }
.ws-nav a[aria-current="page"] { color: var(--ws-link); background: var(--ws-accent-soft); }
.ws-tools { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.ws-iconbtn { position: relative; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--ws-line); background: var(--ws-btn); color: var(--ws-soft); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: 0 2px 7px rgba(120, 80, 20, .08); transition: color .15s, transform .1s, box-shadow .15s; padding: 0; }
.ws-iconbtn:hover { color: var(--ws-ink); box-shadow: 0 5px 14px rgba(120, 80, 20, .16); }
.ws-iconbtn:active { transform: scale(.95); }
.ws-iconbtn .ws-i { width: 20px; height: 20px; }
[data-tip] { position: relative; }
@media (hover: hover) {
  [data-tip]:hover::after, [data-tip]:focus-visible::after { content: attr(data-tip); position: absolute; top: calc(100% + 8px); left: 50%; transform: translateX(-50%); z-index: 60; padding: 6px 10px; border-radius: 9px; background: var(--ws-tooltip); color: var(--ws-tooltip-ink); font: 600 12.5px/1.2 var(--ws-font-body); white-space: nowrap; pointer-events: none; box-shadow: 0 6px 18px rgba(0, 0, 0, .18); }
  .ws-share [data-tip]:hover::after, .ws-share [data-tip]:focus-visible::after { top: 50%; left: calc(100% + 10px); transform: translateY(-50%); }
}
.ws-theme-btn .ws-sun { display: none; }
html[data-theme="dark"] .ws-theme-btn .ws-sun { display: block; }
html[data-theme="dark"] .ws-theme-btn .ws-moon { display: none; }
@media (prefers-color-scheme: dark) { html:not([data-theme="light"]) .ws-theme-btn .ws-sun { display: block; } html:not([data-theme="light"]) .ws-theme-btn .ws-moon { display: none; } }

/* language dropdown */
.ws-lang { position: relative; }
.ws-lang__btn { height: 40px; display: inline-flex; align-items: center; gap: 6px; padding: 0 12px 0 10px; border-radius: 999px; border: 1px solid var(--ws-line); background: var(--ws-btn); color: var(--ws-ink); font-family: var(--ws-font-ui); font-weight: 600; font-size: 14.5px; cursor: pointer; box-shadow: 0 2px 7px rgba(120, 80, 20, .08); }
.ws-lang__btn:hover { box-shadow: 0 5px 14px rgba(120, 80, 20, .16); }
.ws-lang__btn .ws-i { width: 18px; height: 18px; color: var(--ws-soft); }
.ws-lang__btn .ws-chev { width: 16px; height: 16px; transition: transform .15s; }
.ws-lang__btn[aria-expanded="true"] .ws-chev { transform: rotate(180deg); }
.ws-lang__code { text-transform: uppercase; }
.ws-lang__name { display: none; }
@media (min-width: 1040px) { .ws-lang__name { display: inline; } .ws-lang__code { display: none; } }
.ws-lang__menu { position: absolute; right: 0; top: calc(100% + 8px); z-index: 70; width: 230px; max-height: min(70vh, 470px); overflow-y: auto; overscroll-behavior: contain; margin: 0; padding: 6px; list-style: none; border-radius: 16px; background: var(--ws-card); border: 1px solid var(--ws-line); box-shadow: var(--ws-pop-shadow); scrollbar-width: thin; animation: ws-pop .14s ease-out; }
.ws-lang__menu[hidden] { display: none; }
.ws-lang__menu a { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 9px 12px; border-radius: 10px; color: var(--ws-ink); text-decoration: none; font-weight: 600; font-size: 15px; }
.ws-lang__menu a:hover, .ws-lang__menu a:focus { background: var(--ws-accent-soft); outline: none; }
.ws-lang__menu a[aria-current="true"] { color: var(--ws-link); }
.ws-lang__menu a[aria-current="true"]::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--ws-accent); }
.ws-lang__menu small { color: var(--ws-soft); font-weight: 600; text-transform: uppercase; font-size: 11.5px; }
@keyframes ws-pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }

/* mobile menu */
.ws-menu-btn { display: none; }
.ws-mnav { position: absolute; left: 0; right: 0; top: 100%; padding: 8px 12px 14px; background: var(--ws-card); border-bottom: 1px solid var(--ws-line); box-shadow: 0 18px 40px rgba(50, 30, 8, .16); }
.ws-mnav[hidden] { display: none; }
.ws-mnav a { display: block; padding: 12px 14px; border-radius: 12px; color: var(--ws-ink); text-decoration: none; font-family: var(--ws-font-ui); font-weight: 600; font-size: 17px; }
.ws-mnav a[aria-current="page"] { color: var(--ws-link); background: var(--ws-accent-soft); }
@media (max-width: 899px) { .ws-nav { display: none; } .ws-menu-btn { display: inline-flex; } }
@media (max-width: 380px) {
  .ws-logo__word { font-size: 21px; }
  .ws-logo svg { width: 30px; height: 30px; }
  .ws-tools { gap: 4px; }
  .ws-iconbtn { width: 36px; height: 36px; }
  .ws-lang__btn { height: 36px; padding: 0 8px; }
}

/* ---------- game area ---------- */
.ws-stage { position: relative; }
.ws-game { position: relative; width: 100%; height: calc(100vh - var(--ws-header-h)); height: calc(100dvh - var(--ws-header-h)); min-height: 460px; margin: 0 auto; }
@media (min-width: 760px) { .ws-game { max-height: 920px; } }
.ws-game__boot { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; color: var(--ws-soft); font-family: var(--ws-font-ui); font-weight: 600; text-align: center; padding: 20px; }
.ws-game__boot .ws-spin { width: 34px; height: 34px; border-radius: 50%; border: 4px solid var(--ws-line); border-top-color: var(--ws-accent); animation: ws-spin 1s linear infinite; }
@keyframes ws-spin { to { transform: rotate(360deg); } }

/* share buttons */
.ws-share { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; padding: 14px 16px 4px; }
.ws-share__t { flex: 0 0 100%; text-align: center; font-family: var(--ws-font-ui); font-weight: 600; font-size: 14px; color: var(--ws-soft); margin: 0; }
.ws-sbtn { width: 42px; height: 42px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--ws-line); background: var(--ws-btn); color: var(--b, var(--ws-soft)); cursor: pointer; padding: 0; box-shadow: 0 2px 7px rgba(120, 80, 20, .1); transition: background .15s, color .15s, transform .1s; text-decoration: none; }
.ws-sbtn svg { width: 19px; height: 19px; fill: currentColor; display: block; }
.ws-sbtn:hover { background: var(--b, var(--ws-accent)); color: #fff; border-color: transparent; }
.ws-sbtn:active { transform: scale(.94); }
.ws-sbtn--x { --b: var(--ws-x); }
html[data-theme="dark"] .ws-sbtn--x:hover { color: #000; }
@media (prefers-color-scheme: dark) { html:not([data-theme="light"]) .ws-sbtn--x:hover { color: #000; } }
.ws-sbtn--copy .ws-i { width: 19px; height: 19px; }
@media (min-width: 1100px) {
  .ws-share { position: fixed; left: 14px; top: 50%; transform: translateY(-50%); z-index: 40; flex-direction: column; flex-wrap: nowrap; padding: 8px; gap: 8px; border-radius: 999px; background: var(--ws-glass); border: 1px solid var(--ws-line); box-shadow: var(--ws-shadow); }
  .ws-share__t { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .ws-sbtn { width: 38px; height: 38px; box-shadow: none; }
}
.ws-stoast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 90; padding: 10px 18px; border-radius: 999px; background: var(--ws-tooltip); color: var(--ws-tooltip-ink); font-weight: 700; font-size: 14.5px; box-shadow: 0 10px 30px rgba(0, 0, 0, .25); animation: ws-pop .15s ease-out; }

/* ---------- content ---------- */
.ws-site { display: block; }
.ws-content { padding: 8px 0 10px; }
.ws-wrap { max-width: 940px; margin: 0 auto; padding: 0 20px; }
.ws-hero { text-align: center; padding: 30px 20px 8px; max-width: 820px; margin: 0 auto; }
.ws-hero h1 { font-size: clamp(30px, 5.2vw, 42px); line-height: 1.1; letter-spacing: -.5px; margin: 0 0 12px; }
.ws-hero__lead { font-size: 18px; line-height: 1.6; color: var(--ws-soft); max-width: 700px; margin: 0 auto; }
.ws-crumbs { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px 8px; list-style: none; margin: 0 0 14px; padding: 0; font-family: var(--ws-font-ui); font-weight: 600; font-size: 14px; color: var(--ws-soft); }
.ws-crumbs li + li::before { content: '›'; margin-right: 8px; opacity: .6; }
.ws-crumbs a { color: var(--ws-soft); text-decoration: none; }
.ws-crumbs a:hover { color: var(--ws-link); }
.ws-sec { padding: 34px 0; }
.ws-sec + .ws-sec { border-top: 1px solid var(--ws-line); }
.ws-sec--intro { padding-top: 14px; }
.ws-sec--intro + .ws-sec, .ws-sec--cards + .ws-sec { border-top: 0; }
.ws-sec > .ws-wrap > h2 { text-align: center; font-size: clamp(25px, 3.6vw, 30px); letter-spacing: -.3px; margin: 0 auto 18px; max-width: 760px; }
.ws-prose { max-width: 720px; margin: 0 auto; }
.ws-prose > :first-child { margin-top: 0; }
.ws-prose p, .ws-prose li { color: var(--ws-soft); font-size: 17px; line-height: 1.72; }
.ws-prose p { margin: 0 0 16px; }
.ws-prose strong { color: var(--ws-ink); }
.ws-prose a { font-weight: 700; text-decoration: none; }
.ws-prose a:hover { text-decoration: underline; }
.ws-prose h3 { font-size: 21px; margin: 28px 0 10px; }
.ws-prose ul, .ws-prose ol { margin: 0 0 18px; padding-left: 24px; }
.ws-prose li { margin: 0 0 7px; }
.ws-prose li::marker { color: var(--ws-accent); font-weight: 700; }
.ws-prose kbd, .ws-doc kbd { display: inline-block; min-width: 1.6em; padding: 1px 7px; border-radius: 7px; background: var(--ws-surface); border: 1px solid var(--ws-line); box-shadow: 0 2px 0 var(--ws-line); font: 700 .86em/1.5 var(--ws-font-ui); color: var(--ws-ink); text-align: center; }
.ws-prose blockquote { margin: 0 0 18px; padding: 16px 20px; border-radius: 16px; background: var(--ws-accent-soft); border-left: 4px solid var(--ws-accent); }
.ws-prose blockquote p { color: var(--ws-ink); margin: 0 0 8px; }
.ws-prose blockquote p:last-child { margin: 0; }

/* step cards (ol.ws-steps) */
.ws-prose .ws-steps { list-style: none; padding: 0; margin: 8px 0 22px; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; counter-reset: ws-step; }
.ws-prose .ws-steps > li { counter-increment: ws-step; margin: 0; background: var(--ws-card); border-radius: 18px; padding: 20px 18px 18px; box-shadow: var(--ws-shadow); text-align: center; font-size: 15.5px; line-height: 1.6; }
.ws-prose .ws-steps > li::before { content: counter(ws-step); display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; margin: 0 auto 10px; border-radius: 50%; background: var(--ws-accent); color: #fff; font: 700 16px/1 var(--ws-font-ui); box-shadow: 0 3px 0 var(--ws-accent-d); }
.ws-prose .ws-steps h3 { font-size: 18px; margin: 0 0 6px; }
.ws-prose .ws-steps p { font-size: 15.5px; margin: 0 0 8px; }
.ws-prose .ws-steps p:last-child { margin: 0; }
.ws-prose .ws-steps > li > strong:first-child { display: block; font-family: var(--ws-font-ui); font-weight: 600; font-size: 18px; margin-bottom: 4px; }
/* card grid (ul.ws-cards) */
.ws-prose .ws-cards { list-style: none; padding: 0; margin: 8px 0 22px; display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; }
.ws-prose .ws-cards > li { margin: 0; background: var(--ws-card); border-radius: 18px; padding: 20px 22px; box-shadow: var(--ws-shadow); font-size: 15.5px; }
.ws-prose .ws-cards h3 { font-size: 19px; margin: 0 0 8px; }
.ws-prose .ws-cards p { font-size: 15.5px; margin: 0 0 8px; }
.ws-prose .ws-cards p:last-child { margin: 0; }
.ws-prose .ws-cards > li > strong:first-child { display: block; font-family: var(--ws-font-ui); font-weight: 600; font-size: 19px; margin-bottom: 6px; }
/* tip rows (ul.ws-tips) */
.ws-prose .ws-tips { list-style: none; padding: 0; margin: 8px 0 22px; display: grid; gap: 12px; counter-reset: ws-tip; }
.ws-prose .ws-tips > li { counter-increment: ws-tip; position: relative; margin: 0; padding: 16px 18px 16px 60px; background: var(--ws-card); border-radius: 14px; box-shadow: var(--ws-shadow); font-size: 15.5px; line-height: 1.6; }
.ws-prose .ws-tips > li::before { content: counter(ws-tip); position: absolute; left: 18px; top: 16px; width: 28px; height: 28px; border-radius: 8px; background: var(--ws-accent); color: #fff; display: flex; align-items: center; justify-content: center; font: 700 14px/1 var(--ws-font-ui); }
.ws-prose .ws-tips p { font-size: 15.5px; margin: 0 0 6px; }
.ws-prose .ws-tips p:last-child { margin: 0; }

/* tables */
.ws-table { overflow-x: auto; margin: 0 0 20px; border-radius: 16px; background: var(--ws-card); box-shadow: var(--ws-shadow); }
.ws-table table { width: 100%; border-collapse: collapse; font-size: 15.5px; }
.ws-table th, .ws-table td { padding: 11px 16px; text-align: left; border-bottom: 1px solid var(--ws-line); vertical-align: top; }
.ws-table thead th { font-family: var(--ws-font-ui); font-weight: 600; color: var(--ws-ink); background: var(--ws-accent-soft); white-space: nowrap; }
.ws-table td { color: var(--ws-soft); }
.ws-table tr:last-child td, .ws-table tr:last-child th { border-bottom: 0; }

/* printable table */
.ws-ptable th small { display: block; font: 600 12px/1.3 var(--ws-font-body); color: var(--ws-soft); }
.ws-ptable tbody th { font-weight: 700; white-space: nowrap; }
.ws-ptable tbody th a { color: var(--ws-ink); text-decoration: none; }
.ws-ptable tbody th a:hover { color: var(--ws-link); }
.ws-ptable td, .ws-ptable thead th + th { text-align: center; }
.ws-ptable td { padding: 8px 10px; vertical-align: middle; }
.ws-ptable td a { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; background: var(--ws-btn); border: 1px solid var(--ws-line); color: var(--ws-link); font: 600 14px/1.2 var(--ws-font-ui); text-decoration: none; white-space: nowrap; }
.ws-ptable td a:hover { background: var(--ws-accent); color: #fff; border-color: transparent; text-decoration: none; }
.ws-ptable .ws-i { width: 16px; height: 16px; }
@media (max-width: 560px) { .ws-ptable td a { padding: 6px 9px; } .ws-ptable td a .ws-i { display: none; } .ws-ptable th, .ws-ptable td { padding-left: 8px; padding-right: 8px; } }

/* FAQ */
.ws-faqs { display: flex; flex-direction: column; gap: 12px; margin: 0 0 18px; }
.ws-faq { background: var(--ws-card); border-radius: 14px; padding: 2px 20px; box-shadow: var(--ws-shadow); }
.ws-faq summary { cursor: pointer; list-style: none; font-weight: 700; font-size: 17px; line-height: 1.4; padding: 16px 30px 16px 0; position: relative; color: var(--ws-ink); }
.ws-faq summary::-webkit-details-marker { display: none; }
.ws-faq summary::after { content: ''; position: absolute; right: 2px; top: 50%; width: 12px; height: 12px; margin-top: -8px; border-right: 3px solid var(--ws-accent); border-bottom: 3px solid var(--ws-accent); border-radius: 2px; transform: rotate(45deg); transition: transform .18s, margin-top .18s; }
.ws-faq[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.ws-faq > :not(summary) { font-size: 15.5px; }
.ws-faq p:last-child, .ws-faq ul:last-child { margin-bottom: 16px; }

/* mini grids (div.ws-fig) */
.ws-fig { display: flex; justify-content: center; margin: 8px 0 24px; }
.ws-fig__in { display: inline-flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 22px; padding: 16px; border-radius: 20px; background: var(--ws-card); box-shadow: var(--ws-shadow); max-width: 100%; }
.ws-fig__board { --cell: clamp(26px, calc((100vw - 96px) / var(--cols)), 40px); position: relative; padding: 4px; border-radius: 14px; background: var(--ws-surface); box-shadow: inset 0 0 0 1px var(--ws-line); }
.ws-fig__grid { position: relative; display: grid; grid-template-columns: repeat(var(--cols), var(--cell)); grid-auto-rows: var(--cell); }
.ws-fig__grid span { display: flex; align-items: center; justify-content: center; font: 600 calc(var(--cell) * .5)/1 var(--ws-font-ui); color: var(--ws-cell-ink); }
.ws-fig__svg { position: absolute; left: 4px; top: 4px; width: calc(100% - 8px); height: calc(100% - 8px); overflow: visible; }
.ws-fig__cap { stroke: var(--c); stroke-opacity: .55; stroke-width: .8; stroke-linecap: round; }
.ws-fig__sel { stroke: var(--ws-accent); stroke-opacity: .26; stroke-width: .8; stroke-linecap: round; }
.ws-fig__hint { fill: var(--ws-hint); fill-opacity: .22; stroke: var(--ws-hint); stroke-width: .07; }
.ws-fig__list { min-width: 110px; }
.ws-fig__list p { margin: 0 0 6px; font: 600 13px/1.3 var(--ws-font-ui); color: var(--ws-soft); text-transform: uppercase; letter-spacing: .4px; }
.ws-fig__list ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.ws-fig__list li { margin: 0; font: 600 16px/1.3 var(--ws-font-ui); color: var(--ws-ink); letter-spacing: .5px; }
.ws-fig__list li.is-found { text-decoration: line-through; text-decoration-thickness: 2px; opacity: .5; }
@media (max-width: 520px) { .ws-fig__list ul { flex-direction: row; flex-wrap: wrap; gap: 4px 14px; } .ws-fig__list { min-width: 0; text-align: center; } .ws-fig__list ul { justify-content: center; } }

/* theme cards (hub, related themes) */
.ws-tcards { list-style: none; margin: 0 auto; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.ws-tcards li { margin: 0; }
.ws-tcard { display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; padding: 18px 12px 16px; border-radius: 20px; background: var(--ws-card); box-shadow: var(--ws-shadow); text-decoration: none; text-align: center; border: 1px solid transparent; transition: transform .16s, box-shadow .16s, border-color .16s; }
.ws-tcard:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(120, 80, 20, .16); border-color: var(--c); }
.ws-tcard__i { width: 58px; height: 58px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--ws-accent-soft); background: color-mix(in srgb, var(--c) 24%, transparent); color: var(--ws-ink); color: color-mix(in srgb, var(--c) 55%, var(--ws-ink)); margin-bottom: 4px; }
.ws-tcard__i svg { width: 34px; height: 34px; display: block; }
.ws-tcard__t { font-family: var(--ws-font-ui); font-weight: 600; font-size: 17.5px; line-height: 1.2; color: var(--ws-ink); }
.ws-tcard__n { font-size: 13.5px; color: var(--ws-soft); font-weight: 600; }
.ws-tcards--rel { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); max-width: 860px; }
.ws-more { text-align: center; margin: 18px 0 0; }
.ws-more a, .ws-printlink a { display: inline-flex; align-items: center; gap: 6px; font-family: var(--ws-font-ui); font-weight: 600; text-decoration: none; }
.ws-more .ws-i { width: 18px; height: 18px; }
@media (max-width: 420px) { .ws-tcards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .ws-tcard { padding: 14px 8px; } }

/* theme word list */
.ws-prose .ws-wordcols { list-style: none; padding: 16px 20px; margin: 4px 0 16px; columns: 4 140px; column-gap: 20px; background: var(--ws-card); border-radius: 18px; box-shadow: var(--ws-shadow); }
.ws-prose .ws-wordcols li { break-inside: avoid; margin: 0; padding: 3px 0; font-size: 16px; line-height: 1.45; color: var(--ws-ink); font-weight: 600; }
.ws-prose .ws-printlink { text-align: center; }
.ws-printlink .ws-i { width: 18px; height: 18px; }

/* article/legal document card */
.ws-doc { max-width: 820px; margin: 10px auto 0; background: var(--ws-card); border-radius: 22px; padding: 38px 44px; box-shadow: var(--ws-shadow); }
.ws-doc .ws-prose { max-width: none; }
.ws-doc .ws-sec { padding: 0; }
.ws-doc .ws-sec + .ws-sec { border-top: 1px solid var(--ws-line); margin-top: 26px; padding-top: 26px; }
.ws-doc .ws-sec > .ws-wrap { padding: 0; }
.ws-doc .ws-sec > .ws-wrap > h2 { text-align: left; font-size: 24px; margin: 0 0 12px; }
.ws-doc .ws-prose p, .ws-doc .ws-prose li { font-size: 16px; }
@media (max-width: 720px) { .ws-doc { padding: 24px 18px; border-radius: 18px; margin: 6px 12px 0; } .ws-doc .ws-sec > .ws-wrap > h2 { font-size: 21px; } }

/* contact form (shared feedback widget markup) */
.ws-doc .ws-sec--form { border-top: 0; }
.ws-formcard { max-width: 640px; margin: 0 auto; }
[data-feedback-form] { max-width: 100%; text-align: left; }
[data-feedback-form] .fb-row { margin-bottom: 16px; }
[data-feedback-form] label { display: block; margin-bottom: 6px; font-family: var(--ws-font-ui); font-weight: 600; font-size: 15px; color: var(--ws-ink); }
[data-feedback-form] .fb-input { display: block; width: 100%; padding: 12px 14px; font: inherit; font-size: 16px; line-height: 1.5; color: var(--ws-ink); background: var(--ws-btn); border: 1px solid var(--ws-line); border-radius: 12px; outline: 0; box-shadow: inset 0 1px 2px rgba(0, 0, 0, .04); }
[data-feedback-form] .fb-input::placeholder { color: var(--ws-soft); opacity: .8; }
[data-feedback-form] .fb-input:focus { border-color: var(--ws-accent); box-shadow: 0 0 0 3px var(--ws-accent-soft); }
[data-feedback-form] textarea.fb-input { min-height: 150px; resize: vertical; }
[data-feedback-form] input[type=file].fb-input { padding: 9px 12px; }
[data-feedback-form] .fb-btn { display: inline-block; width: 100%; padding: 13px 20px; font: 600 17px/1.2 var(--ws-font-ui); color: #fff; background: var(--ws-accent); border: 0; border-radius: 999px; cursor: pointer; box-shadow: 0 4px 0 var(--ws-accent-d); transition: filter .15s, transform .1s; }
[data-feedback-form] .fb-btn:hover { filter: brightness(1.06); }
[data-feedback-form] .fb-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--ws-accent-d); }
[data-feedback-form] .fb-btn:disabled { opacity: .6; cursor: default; }
[data-feedback-form][data-state=error] [data-feedback-status] { color: #e43f52; }
[data-feedback-form][data-state=sent] [data-feedback-status] { color: #16a34a; }
[data-feedback-form] altcha-widget { --altcha-max-width: 100%; display: block; margin-bottom: 16px; }

/* cross-promo */
.ws-promo { padding: 34px 0 10px; }
.ws-promo h2 { text-align: center; font-size: 25px; margin: 0 0 18px; }
.ws-promo__grid { max-width: 1000px; margin: 0 auto; padding: 0 20px; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.ws-pcard { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 18px; text-decoration: none; background: var(--ws-btn); border: 1px solid var(--ws-line); box-shadow: 0 6px 18px rgba(120, 80, 20, .08); transition: transform .16s, box-shadow .16s, border-color .16s; }
.ws-pcard:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(120, 80, 20, .16); border-color: var(--ws-accent); }
.ws-pcard img { flex: 0 0 auto; width: 52px; height: 52px; object-fit: contain; border-radius: 0; display: block; }
.ws-pcard__b { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.ws-pcard__t { font-family: var(--ws-font-ui); font-weight: 600; font-size: 18px; line-height: 1.15; color: var(--ws-ink); }
.ws-pcard__s { font-size: 14px; color: var(--ws-soft); margin-top: 2px; line-height: 1.35; }
.ws-pcard .ws-i { color: var(--ws-soft); width: 20px; height: 20px; transition: transform .16s; }
.ws-pcard:hover .ws-i { transform: translateX(3px); color: var(--ws-link); }

/* ---------- footer ---------- */
.ws-foot { margin-top: 44px; padding: 40px 20px 30px; color: var(--ws-soft); background: linear-gradient(180deg, var(--ws-accent-soft), transparent 70%); border-top: 1px solid var(--ws-line); font-size: 14.5px; }
.ws-foot__in { max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: minmax(240px, 1.4fr) repeat(3, minmax(130px, 1fr)); gap: 28px 30px; }
.ws-foot__brand .ws-logo__word { font-size: 23px; }
.ws-foot__brand p { margin: 10px 0 0; max-width: 360px; line-height: 1.55; }
.ws-foot h2 { font-size: 15px; margin: 4px 0 10px; color: var(--ws-ink); letter-spacing: .2px; }
.ws-foot ul { list-style: none; margin: 0; padding: 0; }
.ws-foot li { margin: 0 0 4px; }
.ws-foot a { color: var(--ws-soft); text-decoration: none; font-weight: 600; }
.ws-foot a:hover { color: var(--ws-link); text-decoration: underline; }
.ws-foot__langs { max-width: 1080px; margin: 28px auto 0; padding-top: 18px; border-top: 1px solid var(--ws-line); display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 4px; }
.ws-foot__langs a { padding: 4px 9px; border-radius: 999px; font-size: 13.5px; }
.ws-foot__langs a[aria-current="true"] { color: var(--ws-link); background: var(--ws-accent-soft); }
.ws-foot__bottom { max-width: 1080px; margin: 16px auto 0; text-align: center; font-size: 13px; line-height: 1.6; }
.ws-foot__bottom p { margin: 4px 0; }
@media (max-width: 860px) { .ws-foot__in { grid-template-columns: 1fr 1fr; } .ws-foot__brand { grid-column: 1 / -1; } }
@media (max-width: 420px) { .ws-foot__in { gap: 22px 16px; } }

/* language suggestion banner (article pages) */
.ws-lsb { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 80; width: min(560px, calc(100vw - 24px)); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border-radius: 18px; background: var(--ws-card); border: 1px solid var(--ws-line); box-shadow: 0 18px 50px rgba(50, 30, 8, .25); animation: ws-pop .2s ease-out; }
.ws-lsb p { flex: 1 1 200px; margin: 0; font-weight: 700; color: var(--ws-ink); }
.ws-lsb a, .ws-lsb button { border-radius: 999px; padding: 8px 14px; font-weight: 700; font-size: 14.5px; cursor: pointer; text-decoration: none; }
.ws-lsb a { background: var(--ws-accent); color: #fff; }
.ws-lsb button { background: transparent; border: 1px solid var(--ws-line); color: var(--ws-soft); }

/* 404 */
.ws-404 { text-align: center; padding: 50px 20px 10px; max-width: 640px; margin: 0 auto; }
.ws-404 .ws-fig { margin-bottom: 26px; }
.ws-404 h1 { font-size: clamp(30px, 6vw, 44px); margin: 0 0 12px; }
.ws-404 p { color: var(--ws-soft); font-size: 18px; }
.ws-cta { display: inline-flex; align-items: center; gap: 10px; margin-top: 10px; background: var(--ws-accent); color: #fff; font-family: var(--ws-font-ui); font-weight: 600; font-size: 18px; padding: 13px 28px; border-radius: 999px; text-decoration: none; box-shadow: 0 4px 0 var(--ws-accent-d), 0 12px 26px var(--ws-accent-soft); transition: transform .12s; }
.ws-cta:hover { transform: translateY(-2px); color: #fff; }
.ws-404__more { list-style: none; padding: 0; margin: 14px 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 10px; }
.ws-404__more a { display: inline-block; padding: 7px 14px; border-radius: 999px; background: var(--ws-card); box-shadow: var(--ws-shadow); text-decoration: none; font-weight: 700; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
/* Printing a game page prints only the puzzle sheet the game renders (B.10); other pages print their text. */
@media print {
  .ws-header, .ws-share, .ws-foot, .ws-promo, .ws-skip, .ws-lsb, [id^="ezoic-pub-ad-placeholder"] { display: none !important; }
  body { background: #fff; color: #000; }
  .ws-k-game .ws-content { display: none !important; }
  .ws-k-game .ws-game { height: auto; min-height: 0; max-height: none; }
}
