:root {
  --ink: #18231c;
  --body-ink: #2c352f;
  --muted: #68736c;
  --paper: #fffdf7;
  --canvas: #f2eadc;
  --panel: #faf5e9;
  --line: #dfd1bd;
  --green: #0f5f45;
  --green-dark: #083a2e;
  --red: #c64635;
  --amber: #d99b27;
  --teal: #2b8f80;
  --shadow: 0 16px 36px rgba(48, 38, 26, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--body-ink);
  background:
    linear-gradient(90deg, rgba(24, 35, 28, .045) 1px, transparent 1px),
    linear-gradient(180deg, #fbf6eb 0%, #efe4d3 100%);
  background-size: 44px 44px, auto;
  font-family: Inter, Arial, "Microsoft YaHei", sans-serif;
  line-height: 1.62;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 253, 247, .94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}
.nav {
  max-width: 1180px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 900;
  white-space: nowrap;
}
.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  color: #fffaf0;
  background:
    linear-gradient(135deg, var(--green) 0 58%, var(--red) 58% 100%);
  box-shadow: 6px 6px 0 #f1c45f;
  font-weight: 950;
}
.brand-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 6px;
}
.brand-logo.full-logo {
  width: auto;
  max-width: 230px;
  height: 46px;
  border-radius: 0;
}
.links {
  display: flex;
  align-items: center;
  gap: 2px;
  font-size: 14px;
  color: var(--muted);
}
.links a {
  padding: 8px 10px;
  border-radius: 6px;
}
.links a:hover,
.links a.active {
  color: #fffdf7;
  background: var(--green);
}
.lang-switch {
  display: inline-flex;
  gap: 2px;
  margin-left: 8px;
  padding-left: 8px;
  border-left: 1px solid var(--line);
}
.lang-switch a { font-weight: 850; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 10px 15px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
  font-weight: 850;
  cursor: pointer;
  box-shadow: 4px 4px 0 rgba(15, 95, 69, .12);
}
.btn.primary {
  border-color: var(--green);
  background: var(--green);
  color: #fffdf7;
}
.menu-btn { display: none; }

.research-hero {
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(15, 95, 69, .10), transparent 42%),
    linear-gradient(0deg, rgba(198, 70, 53, .08), transparent 46%);
  border-bottom: 1px solid var(--line);
}
.hero-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 60px 20px 46px;
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(340px, .72fr);
  gap: 34px;
  align-items: stretch;
}
.hero-copy {
  min-width: 0;
  padding: 30px 0;
}
.eyebrow,
.badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 28px;
  padding: 5px 10px;
  border: 1px solid rgba(15, 95, 69, .24);
  border-radius: 6px;
  background: #e8f0d9;
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 900;
}
.hero-copy h1 {
  max-width: 840px;
  margin: 18px 0 0;
  color: var(--ink);
  font-size: clamp(44px, 6vw, 82px);
  line-height: .96;
  letter-spacing: 0;
}
.hero-copy p {
  max-width: 720px;
  margin: 22px 0 0;
  color: #4f594f;
  font-size: 18px;
}
.hero-search {
  max-width: 720px;
  margin-top: 28px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 253, 247, .82);
  box-shadow: var(--shadow);
}
.hero-search label {
  display: block;
  margin: 0 0 8px;
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 900;
}
.hero-search div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}
.hero-search input {
  min-height: 42px;
  border: 1px dashed var(--line);
  border-radius: 6px;
  padding: 0 12px;
  background: #fffaf0;
  color: var(--ink);
  font-weight: 850;
}
.keyword-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.keyword-tabs a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 850;
}
.keyword-tabs a:hover {
  border-color: var(--green);
  background: #e8f0d9;
}
.desk-panel {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 14px;
}
.desk-topline {
  position: relative;
  overflow: hidden;
  min-height: 250px;
  padding: 24px;
  border: 1px solid #0b4737;
  border-radius: 6px;
  background:
    linear-gradient(135deg, rgba(255, 253, 247, .06), transparent),
    var(--green-dark);
  color: #fffdf7;
}
.desk-topline::after {
  content: "A  K  Q";
  position: absolute;
  right: -16px;
  bottom: -24px;
  color: rgba(255, 253, 247, .09);
  font-size: 92px;
  font-weight: 950;
  letter-spacing: 0;
}
.desk-topline span {
  color: #f4c96a;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.desk-topline b {
  display: block;
  max-width: 320px;
  margin-top: 10px;
  font-size: 30px;
  line-height: 1.08;
}
.desk-topline p {
  max-width: 340px;
  margin: 14px 0 0;
  color: #d8e5dd;
}
.desk-lines {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
}
.desk-lines div,
.workflow-strip div {
  display: grid;
  grid-template-columns: 42px 1fr auto;
  gap: 12px;
  align-items: center;
  min-height: 52px;
  padding: 10px;
  border-radius: 6px;
  background: #f7eddc;
}
.desk-lines strong,
.workflow-strip b {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 6px;
  background: var(--green);
  color: #fffdf7;
  font-size: 13px;
}
.desk-lines span,
.workflow-strip span {
  color: var(--ink);
  font-weight: 850;
}
.desk-lines em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}
.desk-lines .risk strong { background: var(--red); }

main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 34px 20px 70px;
}
main > section {
  margin-top: 34px;
}
.download-band {
  padding: 22px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 18px;
  align-items: center;
  background:
    linear-gradient(135deg, rgba(217, 78, 63, .10), rgba(245, 212, 105, .28)),
    var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 18px 45px rgba(16, 47, 38, .08);
}
.download-copy h2 {
  margin: 10px 0 8px;
  color: var(--ink);
  font-size: clamp(26px, 3vw, 38px);
  line-height: 1.08;
}
.download-copy p,
.download-action p,
.download-card p {
  color: var(--muted);
}
.download-action {
  display: grid;
  gap: 10px;
  justify-items: start;
}
.download-action p {
  margin: 0;
  font-size: 13px;
}
.download-btn {
  min-width: 180px;
  justify-content: center;
}
.download-card {
  margin: 32px 0 8px;
  padding: 22px;
  background: linear-gradient(135deg, rgba(16, 47, 38, .06), rgba(245, 212, 105, .24));
  border: 1px solid var(--line);
  border-radius: 8px;
}
.download-card h2 {
  margin: 10px 0 8px;
  color: var(--ink);
}
.download-card .btn {
  margin-top: 8px;
}
.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}
.section-head h2,
.content h2,
.side-panel h3,
.panel h3 {
  margin: 8px 0 0;
  color: var(--ink);
  font-size: clamp(26px, 3vw, 42px);
  line-height: 1.08;
  letter-spacing: 0;
}
.section-head p {
  max-width: 720px;
  margin: 10px 0 0;
  color: var(--muted);
}
.matrix-board {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.matrix-row {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  box-shadow: 6px 6px 0 rgba(24, 35, 28, .06);
}
.matrix-row:hover,
.guide-card:hover,
.topic-tile:hover,
.article-card:hover,
.card:hover {
  transform: translateY(-2px);
}
.matrix-row span,
.guide-card span {
  color: var(--red);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}
.matrix-row strong {
  display: block;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.18;
}
.matrix-row p {
  grid-column: 2 / 3;
  margin: 2px 0 0;
  color: var(--muted);
}
.matrix-row em {
  grid-column: 3;
  grid-row: 1 / span 2;
  justify-self: end;
  color: var(--green);
  font-style: normal;
  font-weight: 950;
}
.matrix-row.alert {
  background: #fff4e7;
}
.workflow-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
.workflow-strip div {
  grid-template-columns: 40px 1fr;
  background: #e8f0d9;
}

.guide-lanes,
.topic-grid,
.article-grid,
.grid-3,
.grid-4 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.guide-card,
.topic-tile,
.article-card,
.card,
.panel,
.content {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  box-shadow: 5px 5px 0 rgba(15, 95, 69, .08);
}
.guide-card,
.topic-tile,
.article-card,
.card {
  min-height: 190px;
  padding: 20px;
  transition: transform .18s ease, box-shadow .18s ease;
}
.guide-card h3,
.topic-tile h3,
.article-card h3,
.card h3 {
  margin: 10px 0 0;
  color: var(--ink);
  font-size: 22px;
  line-height: 1.16;
}
.guide-card p,
.topic-tile p,
.article-card p,
.card p {
  margin: 10px 0 0;
  color: var(--muted);
}
.badge.gold {
  background: #fff0bd;
  color: #7d5411;
  border-color: #e6c267;
}
.topic-band {
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 253, 247, .56);
}
.checklist-layout,
.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 18px;
  align-items: start;
}
.content,
.panel-pad,
.side-panel {
  padding: 26px;
}
.content h1,
.content h2,
.content h3 {
  color: var(--ink);
  line-height: 1.16;
  letter-spacing: 0;
}
.content h1 {
  margin-top: 0;
  font-size: clamp(34px, 4vw, 54px);
}
.content h2 {
  padding-top: 8px;
  border-top: 1px solid var(--line);
}
.content h3 {
  margin-top: 24px;
  font-size: 22px;
}
.content p,
.content li {
  color: #3d4740;
}
.content a {
  color: var(--green);
  font-weight: 850;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.content table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  background: #fffaf0;
}
.content th,
.content td {
  padding: 12px;
  border: 1px solid var(--line);
  text-align: left;
}
.content th {
  background: #e8f0d9;
}
.side-panel {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--green-dark);
  color: #fffdf7;
}
.side-panel h3,
.side-panel b {
  color: #fffdf7;
}
.side-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}
.side-list a {
  display: block;
  padding: 13px;
  border: 1px solid rgba(255, 253, 247, .18);
  border-radius: 6px;
  background: rgba(255, 253, 247, .06);
}
.side-list span {
  display: block;
  margin-top: 4px;
  color: #d9e2d8;
  font-size: 13px;
}

.page-hero {
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(15, 95, 69, .12), transparent 45%),
    #f8f0e1;
}
.page-hero-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 54px 20px 38px;
}
.breadcrumb {
  color: var(--red);
  font-size: 13px;
  font-weight: 900;
}
.page-hero h1 {
  max-width: 920px;
  margin: 12px 0 0;
  color: var(--ink);
  font-size: clamp(38px, 5vw, 66px);
  line-height: .98;
  letter-spacing: 0;
}
.page-hero p {
  max-width: 760px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 18px;
}
.page-main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 34px 20px 70px;
}
.page-main .content {
  max-width: 860px;
}

.search-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  margin-bottom: 22px;
}
.search-form input,
.ask-input input {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 12px;
  background: #fffaf0;
  color: var(--ink);
}
.article-list,
.qa-feed {
  display: grid;
  gap: 14px;
}
.article-row {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  box-shadow: 5px 5px 0 rgba(15, 95, 69, .08);
}
.article-row h2 {
  margin: 0;
  color: var(--ink);
  font-size: 24px;
  line-height: 1.15;
}
.article-row p {
  margin: 8px 0 0;
  color: var(--muted);
}
.date {
  display: grid;
  place-items: center;
  min-height: 70px;
  border-radius: 6px;
  background: #e8f0d9;
  color: var(--green-dark);
  font-weight: 950;
  text-align: center;
}
.article-thumb {
  width: 86px;
  height: 70px;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fffaf0;
}
.qa-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 18px;
  align-items: start;
}
.ask-box,
.question-thread,
.sidebar-card {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  box-shadow: 5px 5px 0 rgba(15, 95, 69, .08);
}
.ask-box {
  padding: 16px;
}
.ask-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}
.avatar {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--green);
  color: #fffdf7;
  font-weight: 950;
}
.qa-tabs,
.topic-list,
.answer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.qa-tab,
.topic-pill,
.action-chip,
.topic-list a {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f7eddc;
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 850;
}
.qa-tab.active {
  background: var(--green);
  border-color: var(--green);
  color: #fffdf7;
}
.question-thread {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  gap: 16px;
  padding: 18px;
}
.question-main h2 {
  margin: 10px 0 0;
  color: var(--ink);
  font-size: 24px;
  line-height: 1.15;
}
.question-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
}
.answer-card {
  padding: 16px;
  border-radius: 6px;
  background: #fffaf0;
}
.answer-card p:first-child {
  margin-top: 0;
}
.sidebar-card {
  padding: 18px;
  margin-bottom: 14px;
}
.sidebar-card h3 {
  margin: 0 0 10px;
  color: var(--ink);
}
.contributor-note {
  color: var(--muted);
}
.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}
.pagination a {
  min-width: 40px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
  text-align: center;
  font-weight: 800;
}
.pagination a.active {
  background: var(--green);
  border-color: var(--green);
  color: #fffdf7;
}

.online-rummy-hero {
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(15, 95, 69, .16), transparent 46%),
    linear-gradient(180deg, #fff8e9 0%, #e8f0d9 100%);
}
.online-rummy-hero-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 54px 20px 38px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: stretch;
}
.online-rummy-copy h1 {
  max-width: 820px;
  margin: 18px 0 0;
  color: var(--ink);
  font-size: clamp(42px, 5vw, 72px);
  line-height: .98;
}
.online-rummy-copy p {
  max-width: 720px;
  margin: 18px 0 0;
  color: #4f594f;
  font-size: 18px;
}
.online-rummy-score {
  display: grid;
  align-content: center;
  min-height: 250px;
  padding: 24px;
  border: 1px solid #0b4737;
  border-radius: 6px;
  background: var(--green-dark);
  color: #fffdf7;
  box-shadow: var(--shadow);
}
.online-rummy-score span {
  color: #f4c96a;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.online-rummy-score strong {
  display: block;
  margin-top: 10px;
  font-size: 30px;
  line-height: 1.1;
}
.online-rummy-score p {
  margin: 12px 0 0;
  color: #d7eadf;
}
.online-rummy-page {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
}
.online-rummy-page > * {
  min-width: 0;
}
.practice-table {
  position: relative;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  box-shadow: 5px 5px 0 rgba(15, 95, 69, .08);
}
.game-close {
  display: none;
}
.game-reopen {
  display: none !important;
  padding: 20px;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fffaf0;
}
.game-reopen h2 {
  margin: 8px 0 0;
  color: var(--ink);
}
.game-reopen p {
  margin: 6px 0 0;
  color: var(--muted);
}
.game-fab {
  position: fixed;
  z-index: 80;
  right: 18px;
  bottom: 18px;
  min-width: 116px;
  min-height: 48px;
  padding: 0 18px;
  border: 1px solid rgba(255, 230, 128, .82);
  border-radius: 999px;
  background: linear-gradient(135deg, #ffe680, #ff9d2e);
  color: #42130e;
  cursor: pointer;
  font: inherit;
  font-weight: 950;
  box-shadow: 0 10px 22px rgba(60, 18, 8, .28), 0 0 0 5px rgba(255, 230, 128, .2);
}
.game-fab:hover {
  transform: translateY(-1px);
}
.game-start-overlay {
  position: absolute;
  z-index: 20;
  inset: 0;
  padding: 22px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background:
    radial-gradient(circle at 50% 34%, rgba(255, 255, 255, .12), transparent 28%),
    rgba(39, 43, 48, .82);
  backdrop-filter: blur(6px);
}
.game-start-overlay.is-hidden {
  opacity: 0;
  pointer-events: none;
  transition: opacity .35s ease;
}
.game-start-panel {
  width: min(480px, 100%);
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 10px;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, .12), transparent 38%),
    linear-gradient(180deg, rgba(70, 76, 84, .96), rgba(28, 31, 36, .98));
  color: #fffdf7;
  text-align: center;
  box-shadow: 0 18px 34px rgba(0, 0, 0, .34), 0 0 0 7px rgba(255, 255, 255, .08);
}
.game-start-panel h2 {
  margin: 12px 0 0;
  color: #fffdf7;
  font-size: 34px;
  line-height: 1.08;
}
.game-start-panel p {
  margin: 12px auto 18px;
  max-width: 390px;
  color: #d7eadf;
}
.game-loading {
  margin-top: 18px;
}
.loading-meta {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  color: #d7dde5;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.loading-meta strong {
  min-width: 34px;
  color: #fffdf7;
  font-size: 22px;
  line-height: 1;
}
.loading-track {
  height: 12px;
  margin-top: 9px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 999px;
  background: rgba(0, 0, 0, .22);
}
.loading-track span {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #f5f7fa, #aeb8c5, #22d1ad);
  transition: width .95s linear;
}
.practice-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
}
.practice-toolbar h2 {
  margin: 10px 0 0;
  color: var(--ink);
  font-size: 30px;
}
.practice-toolbar p {
  margin: 6px 0 0;
  color: var(--muted);
}
.practice-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}
.rummy-felt {
  margin-top: 18px;
  padding: 66px 120px 32px;
  position: relative;
  overflow: hidden;
  border: 1px solid #7c1f13;
  border-radius: 10px;
  background:
    radial-gradient(circle at 18% 22%, rgba(255, 213, 76, .22) 0 2px, transparent 3px),
    radial-gradient(circle at 68% 34%, rgba(255, 213, 76, .18) 0 2px, transparent 3px),
    radial-gradient(circle at 42% 76%, rgba(255, 213, 76, .16) 0 2px, transparent 3px),
    linear-gradient(135deg, #7e160d 0%, #b92b16 45%, #6f120d 100%);
  box-shadow: inset 0 0 60px rgba(0, 0, 0, .3), 0 22px 42px rgba(69, 25, 13, .22);
}
.game-table::before {
  content: "";
  position: absolute;
  left: 7%;
  right: 7%;
  top: 70px;
  bottom: 74px;
  border: 14px solid #2d3442;
  border-radius: 46% / 38%;
  background:
    radial-gradient(ellipse at center, rgba(255, 255, 255, .18), transparent 48%),
    linear-gradient(135deg, #15b49c 0%, #28c6a9 48%, #05876f 100%);
  box-shadow:
    inset 0 0 0 5px rgba(255, 255, 255, .2),
    inset 0 0 40px rgba(0, 0, 0, .28),
    0 16px 34px rgba(0, 0, 0, .34);
}
.game-table::after {
  content: "365";
  position: absolute;
  left: 50%;
  top: 43%;
  transform: translate(-50%, -50%);
  color: rgba(2, 92, 76, .26);
  font-size: 56px;
  font-weight: 950;
  letter-spacing: 1px;
}
.table-topbar {
  position: absolute;
  z-index: 4;
  left: 18px;
  right: 18px;
  top: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #ffe680;
}
.table-topbar strong {
  margin-right: auto;
  margin-left: 8px;
  color: #fff8d5;
  font-size: 13px;
  letter-spacing: 0;
  text-transform: uppercase;
}
.round-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 2px solid #ffe680;
  border-radius: 999px;
  background: radial-gradient(circle at 35% 25%, #ff6b35, #8b160e 72%);
  color: #ffe680;
  font-weight: 950;
  box-shadow: 0 4px 0 rgba(65, 10, 6, .65);
}
.table-host {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: 25px;
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  gap: 5px;
  color: #fff8d5;
  font-size: 12px;
  font-weight: 900;
}
.dealer-avatar {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 3px solid #ffe680;
  border-radius: 999px;
  background: linear-gradient(135deg, #1a63c6, #e63e37);
  color: #fff;
  box-shadow: 0 8px 16px rgba(0, 0, 0, .3);
}
.opponent-seat,
.player-seat {
  position: absolute;
  z-index: 5;
  display: grid;
  align-items: center;
  gap: 5px;
  color: #fffdf7;
}
.opponent-seat {
  width: 98px;
  padding: 8px;
  border: 2px solid #ffd95c;
  border-radius: 12px;
  background: linear-gradient(180deg, #8e1b28, #4e1320);
  box-shadow: 0 9px 0 rgba(59, 12, 12, .75), 0 14px 20px rgba(0, 0, 0, .32);
}
.seat-left-top { left: 26px; top: 92px; }
.seat-left-bottom { left: 24px; bottom: 120px; }
.seat-right-top { right: 26px; top: 108px; }
.seat-right-bottom { right: 24px; bottom: 126px; }
.player-avatar {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #ffc94f, #d6332a);
  color: #42130e;
  font-size: 15px;
  font-weight: 950;
}
.player-avatar.active {
  width: 58px;
  height: 58px;
  border: 4px solid #ffe680;
  background: linear-gradient(135deg, #23b79e, #ffcc55);
}
.opponent-seat strong,
.player-seat strong {
  font-size: 12px;
  line-height: 1;
}
.opponent-seat em,
.player-seat em {
  color: #ffe680;
  font-size: 11px;
  font-style: normal;
  line-height: 1;
}
.opponent-seat small {
  position: absolute;
  right: -8px;
  bottom: -8px;
  min-width: 30px;
  padding: 3px 7px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #10131a;
  color: #fff;
  text-align: center;
  font-weight: 950;
}
.table-center {
  position: relative;
  z-index: 3;
  min-height: 210px;
  display: grid;
  grid-template-columns: minmax(120px, 170px) minmax(120px, 170px) minmax(120px, 170px);
  justify-content: center;
  align-items: center;
  gap: 18px;
}
.card-stack,
.discard-pile,
.table-meter {
  min-height: 122px;
  padding: 14px;
  border: 2px solid rgba(255, 230, 128, .7);
  border-radius: 8px;
  color: #fffdf7;
  background: rgba(4, 58, 49, .78);
  box-shadow: 0 18px 26px rgba(0, 0, 0, .22);
}
.card-stack,
.discard-pile {
  cursor: pointer;
  font: inherit;
  text-align: left;
}
.stock-stack {
  position: relative;
  overflow: hidden;
}
.stock-stack::before,
.stock-stack::after {
  content: "";
  position: absolute;
  inset: 18px 20px;
  border: 2px solid rgba(244, 201, 106, .55);
  border-radius: 8px;
  transform: rotate(-7deg);
}
.stock-stack::after {
  transform: rotate(7deg);
}
.card-stack span,
.discard-pile span,
.table-meter span {
  position: relative;
  z-index: 1;
  display: block;
  color: #f4c96a;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.card-stack strong,
.discard-pile strong,
.table-meter strong {
  position: relative;
  z-index: 1;
  display: block;
  margin-top: 18px;
  font-size: 28px;
  line-height: 1;
}
.discard-pile strong.red {
  color: #ffb2a7;
}
.discard-pile strong.black {
  color: #fffdf7;
}
.meld-zone {
  position: relative;
  z-index: 3;
  min-height: 76px;
  margin: 8px auto 20px;
  padding: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  align-items: center;
  border: 1px dashed rgba(255, 253, 247, .28);
  border-radius: 8px;
  color: #d7eadf;
  background: rgba(0, 0, 0, .1);
}
.meld-zone p {
  margin: 0;
}
.meld-chip {
  min-width: 150px;
  padding: 9px 10px;
  border: 1px solid rgba(244, 201, 106, .45);
  border-radius: 7px;
  background: rgba(255, 253, 247, .1);
}
.meld-chip span {
  display: block;
  color: #f4c96a;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}
.meld-cards {
  display: flex;
  align-items: center;
  margin-top: 6px;
  padding-left: 2px;
}
.mini-card {
  width: 30px;
  height: 42px;
  margin-left: -5px;
  position: relative;
  display: grid;
  place-items: center;
  border: 1px solid rgba(24, 35, 28, .24);
  border-radius: 5px;
  background: #fffdf7;
  color: #18231c;
  box-shadow: 0 4px 8px rgba(0, 0, 0, .18);
  font-style: normal;
}
.mini-card:first-child {
  margin-left: 0;
}
.mini-card.red {
  color: var(--red);
}
.mini-card b {
  position: absolute;
  left: 4px;
  top: 3px;
  font-size: 10px;
  line-height: 1;
}
.mini-card em {
  font-style: normal;
  font-size: 18px;
  line-height: 1;
}
.rummy-hand {
  position: relative;
  z-index: 6;
  display: grid;
  grid-template-columns: repeat(13, minmax(58px, 1fr));
  gap: 8px;
  min-height: 128px;
  padding: 14px;
  border-radius: 12px;
  background: rgba(17, 16, 18, .25);
}
.playing-card {
  position: relative;
  aspect-ratio: 2.5 / 3.5;
  min-width: 0;
  padding: 7px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(24, 35, 28, .25);
  border-radius: 8px;
  background: #fffdf7;
  color: #18231c;
  box-shadow: 0 8px 16px rgba(0, 0, 0, .16);
  cursor: pointer;
  font: inherit;
  font-weight: 950;
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.playing-card.red {
  color: var(--red);
}
.playing-card:hover,
.playing-card.selected {
  border-color: #f4c96a;
  transform: translateY(-10px);
  box-shadow: 0 18px 24px rgba(0, 0, 0, .24), 0 0 0 3px rgba(244, 201, 106, .28);
}
.playing-card strong {
  display: grid;
  place-items: center;
  line-height: 1;
  font-size: clamp(22px, 3vw, 36px);
}
.playing-card span {
  position: absolute;
  left: 7px;
  top: 7px;
  line-height: 1;
  font-size: 14px;
}
.playing-card span:last-child {
  inset: auto 7px 7px auto;
  transform: rotate(180deg);
}
.player-seat {
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  grid-template-columns: auto auto;
  padding: 8px 14px 8px 8px;
  border: 2px solid #ffe680;
  border-radius: 999px;
  background: linear-gradient(180deg, #17584f, #102d31);
  box-shadow: 0 9px 0 rgba(20, 22, 28, .7), 0 14px 20px rgba(0, 0, 0, .34);
}
.practice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}
.practice-grid article {
  min-height: 150px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fffaf0;
}
.practice-grid h3 {
  margin: 0 0 8px;
  color: var(--ink);
}
.practice-grid p {
  margin: 0;
  color: var(--muted);
}
.practice-playbar {
  margin-top: 14px;
  padding: 14px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fffaf0;
}
.practice-playbar span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}
.practice-playbar strong {
  display: block;
  color: var(--ink);
  font-size: 22px;
  line-height: 1.1;
}
.online-download {
  margin-top: 0;
}
.online-guide {
  max-width: none;
}

footer {
  border-top: 1px solid var(--line);
  background: #18231c;
  color: #fffdf7;
}
.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 34px 20px;
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: 22px;
}
footer h3,
footer h4 {
  margin: 0 0 10px;
  color: #fffdf7;
}
footer p,
footer a {
  color: #d7ded1;
}
footer a {
  display: block;
  margin: 7px 0;
}
.footer-note {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px 28px;
  color: #c8d0c3;
  font-size: 13px;
}

@media (max-width: 920px) {
  .nav { align-items: flex-start; }
  .links {
    display: none;
    position: absolute;
    left: 20px;
    right: 20px;
    top: 66px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--paper);
    box-shadow: var(--shadow);
    flex-direction: column;
    align-items: stretch;
  }
  .links.open { display: flex; }
  .menu-btn { display: inline-flex; }
  .hero-grid,
  .download-band,
  .checklist-layout,
  .layout,
  .online-rummy-hero-inner {
    grid-template-columns: 1fr;
  }
  .matrix-board,
  .guide-lanes,
  .topic-grid,
  .article-grid,
  .grid-3,
  .grid-4,
  .workflow-strip,
  .footer-inner,
  .qa-shell,
  .question-thread,
  .practice-grid {
    grid-template-columns: 1fr;
  }
  .practice-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }
  .practice-actions,
  .practice-playbar {
    justify-content: flex-start;
  }
  .practice-playbar {
    align-items: flex-start;
    flex-direction: column;
  }
  .table-center {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .rummy-felt {
    padding-left: 22px;
    padding-right: 22px;
  }
  .game-table::before {
    left: 3%;
    right: 3%;
  }
  .opponent-seat {
    position: relative;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
    display: inline-grid;
    width: auto;
    min-width: 94px;
    margin: 4px;
  }
  .seat-left-top,
  .seat-left-bottom,
  .seat-right-top,
  .seat-right-bottom {
    transform: none;
  }
  .table-host {
    top: 46px;
  }
  .table-topbar {
    position: relative;
    left: auto;
    right: auto;
    top: auto;
    margin-bottom: 52px;
  }
  .rummy-hand {
    grid-template-columns: repeat(7, minmax(48px, 1fr));
  }
  .matrix-row {
    grid-template-columns: 1fr;
  }
  .matrix-row p,
  .matrix-row em {
    grid-column: auto;
    grid-row: auto;
    justify-self: start;
  }
}

@media (max-width: 560px) {
  .nav { padding: 10px 14px; }
  .hero-grid { padding: 42px 14px 34px; }
  main,
  .page-main { padding-left: 14px; padding-right: 14px; }
  .hero-copy h1,
  .page-hero h1 { font-size: 42px; }
  .hero-search div { grid-template-columns: 1fr; }
  .search-form,
  .article-row,
  .ask-row { grid-template-columns: 1fr; }
  .online-rummy-hero-inner {
    padding: 34px 14px 24px;
    gap: 16px;
  }
  .online-rummy-copy h1 {
    font-size: 36px;
    line-height: 1.04;
  }
  .online-rummy-copy p {
    font-size: 16px;
  }
  .online-rummy-score {
    min-height: 160px;
    padding: 18px;
  }
  .online-rummy-score strong {
    font-size: 24px;
  }
  .practice-table { padding: 12px; }
  .online-rummy-page {
    gap: 16px;
  }
  .practice-table {
    position: fixed;
    z-index: 90;
    inset: 10px;
    width: auto;
    height: auto;
    max-height: calc(100svh - 20px);
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow: hidden;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 14px;
    background: #fffdf7;
    box-shadow: 0 22px 60px rgba(0, 0, 0, .34);
  }
  .practice-table.is-closed {
    display: none;
  }
  .game-close {
    position: absolute;
    z-index: 40;
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .44);
    border-radius: 999px;
    background: rgba(27, 31, 36, .82);
    color: #fff;
    cursor: pointer;
    font-size: 24px;
    font-weight: 900;
    line-height: 1;
    box-shadow: 0 5px 12px rgba(0, 0, 0, .24);
  }
  .game-reopen {
    grid-template-columns: 1fr;
    margin-top: 0;
    padding: 18px;
  }
  .game-fab {
    right: 14px;
    bottom: 14px;
    min-width: 108px;
    min-height: 44px;
    padding: 0 15px;
    font-size: 14px;
  }
  .game-start-overlay {
    padding: 12px;
    border-radius: 14px;
  }
  .game-start-panel {
    padding: 18px;
  }
  .game-start-panel h2 {
    font-size: 26px;
  }
  .practice-toolbar h2 {
    font-size: 24px;
  }
  .practice-toolbar {
    gap: 8px;
  }
  .practice-toolbar > div:first-child {
    display: none;
  }
  .practice-toolbar p {
    display: none;
  }
  .practice-actions {
    width: 100%;
    gap: 6px;
    padding-right: 40px;
  }
  .practice-actions .btn {
    flex: 1 1 0;
    justify-content: center;
    min-height: 38px;
    font-size: 12px;
    padding: 8px 9px;
  }
  .rummy-felt {
    flex: 1 1 auto;
    min-height: 0;
    padding: 10px;
    border-radius: 8px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto auto minmax(98px, .8fr) auto minmax(86px, .7fr) auto;
    gap: 8px;
  }
  .game-table::after,
  .table-host {
    display: none;
  }
  .game-table::before {
    display: block;
    left: 10px;
    right: 10px;
    top: 226px;
    bottom: 144px;
    border-width: 8px;
    border-radius: 36px;
    opacity: .96;
  }
  .table-topbar {
    grid-column: 1 / -1;
    margin-bottom: 10px;
    flex-wrap: wrap;
    padding: 0 2px;
  }
  .table-topbar strong {
    order: 5;
    width: 100%;
    margin-left: 0;
    color: #fff8d5;
    font-size: 12px;
  }
  .round-icon {
    width: 30px;
    height: 30px;
    border-width: 2px;
    box-shadow: 0 3px 0 rgba(65, 10, 6, .55);
  }
  .opponent-seat {
    position: relative;
    width: auto;
    min-width: 0;
    min-height: 48px;
    grid-template-columns: 34px 1fr;
    align-items: center;
    padding: 6px;
    border-radius: 10px;
    margin: 0;
    border-width: 1px;
    background: linear-gradient(180deg, rgba(125, 21, 35, .96), rgba(60, 13, 24, .98));
    box-shadow: 0 5px 0 rgba(58, 10, 12, .65), 0 8px 14px rgba(0, 0, 0, .22);
  }
  .player-avatar {
    width: 34px;
    height: 34px;
    font-size: 14px;
  }
  .opponent-seat strong,
  .opponent-seat em {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .opponent-seat small {
    right: -5px;
    bottom: -5px;
    min-width: 26px;
    padding: 2px 6px;
  }
  .table-center {
    grid-column: 1 / -1;
    min-height: 116px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
    margin: 4px 6px 0;
    padding: 22px 8px 12px;
    border: 7px solid #293341;
    border-radius: 34px;
    background:
      radial-gradient(ellipse at center, rgba(255, 255, 255, .2), transparent 46%),
      linear-gradient(135deg, #18b79d 0%, #20c7a9 48%, #087965 100%);
    box-shadow:
      inset 0 0 0 3px rgba(255, 255, 255, .18),
      inset 0 0 28px rgba(0, 0, 0, .24),
      0 12px 22px rgba(0, 0, 0, .28);
  }
  .card-stack,
  .discard-pile,
  .table-meter {
    min-height: 58px;
    padding: 8px;
    border-color: rgba(255, 230, 128, .78);
    background: rgba(5, 58, 49, .88);
    box-shadow: 0 7px 12px rgba(0, 0, 0, .24);
  }
  .card-stack span,
  .discard-pile span,
  .table-meter span {
    font-size: 10px;
  }
  .card-stack strong,
  .discard-pile strong,
  .table-meter strong {
    margin-top: 9px;
    font-size: 17px;
  }
  .stock-stack::before,
  .stock-stack::after {
    inset: 16px 14px;
  }
  .meld-zone {
    grid-column: 1 / -1;
    min-height: 54px;
    margin: 0 0 4px;
    padding: 8px;
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    font-size: 12px;
    background: rgba(82, 8, 6, .38);
  }
  .meld-zone::-webkit-scrollbar {
    height: 5px;
  }
  .meld-zone::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: rgba(255, 230, 128, .62);
  }
  .meld-chip {
    flex: 0 0 auto;
    min-width: 112px;
    padding: 7px;
    scroll-snap-align: start;
  }
  .mini-card {
    width: 25px;
    height: 36px;
    margin-left: -6px;
  }
  .mini-card b {
    left: 3px;
    top: 3px;
    font-size: 9px;
  }
  .mini-card em {
    font-size: 15px;
  }
  .rummy-hand {
    grid-column: 1 / -1;
    display: flex;
    min-height: 86px;
    padding: 8px 8px 12px;
    gap: 6px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    border: 1px solid rgba(255, 230, 128, .28);
    background: linear-gradient(180deg, rgba(17, 16, 18, .28), rgba(17, 16, 18, .42));
  }
  .rummy-hand::-webkit-scrollbar {
    height: 5px;
  }
  .rummy-hand::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: rgba(255, 230, 128, .62);
  }
  .playing-card {
    flex: 0 0 50px;
    height: 76px;
    padding: 5px;
    scroll-snap-align: start;
  }
  .playing-card strong {
    font-size: 22px;
  }
  .playing-card span {
    left: 5px;
    top: 5px;
    font-size: 13px;
  }
  .playing-card span:last-child {
    inset: auto 5px 5px auto;
  }
  .playing-card:hover,
  .playing-card.selected {
    transform: translateY(-6px);
  }
  .player-seat {
    grid-column: 1 / -1;
    position: relative;
    left: auto;
    bottom: auto;
    transform: none;
    width: fit-content;
    margin: 0 auto;
    padding: 6px 12px 6px 6px;
    box-shadow: 0 5px 0 rgba(20, 22, 28, .62), 0 9px 14px rgba(0, 0, 0, .26);
  }
  .player-avatar.active {
    width: 40px;
    height: 40px;
    border-width: 3px;
  }
  .practice-grid article {
    min-height: 0;
    padding: 14px;
  }
  .practice-grid {
    display: none;
  }
  .practice-playbar {
    padding: 8px;
    margin-top: 0;
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 8px;
    align-items: center;
  }
  .practice-playbar strong {
    font-size: 15px;
  }
  .practice-playbar .practice-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding-right: 0;
  }
  .practice-playbar .practice-actions .btn {
    min-height: 34px;
    padding: 7px 5px;
    font-size: 11px;
  }
  .topic-band { padding: 16px; }
  .content,
  .panel-pad,
  .side-panel { padding: 20px; }
}
