/* ======================================
   Sudoku Online Puzzles — Global Styles
   ====================================== */

/* --- Reset & Base ---- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --primary: #1a73e8;
  --primary-dark: #1558b0;
  --primary-light: #e8f0fe;
  --accent: #ff6d00;
  --accent-dark: #e56200;
  --bg: #f8f9fa;
  --bg-white: #ffffff;
  --text: #202124;
  --text-light: #5f6368;
  --text-lighter: #80868b;
  --border: #dadce0;
  --shadow-sm: 0 1px 3px rgba(0,0,0,.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,.1);
  --shadow-lg: 0 8px 24px rgba(0,0,0,.12);
  --radius: 12px;
  --radius-sm: 8px;
  --max-w: 1200px;
  --transition: .25s ease;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--primary-dark);
}

/* --- Utility --- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 20px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

/* --- Header / Nav --- */
.site-header {
  background: var(--bg-white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text);
}

.logo img {
  width: 36px;
  height: 36px;
}

.logo span {
  color: var(--primary);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
}

.nav-links a {
  display: inline-block;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: .938rem;
  font-weight: 500;
  transition: background var(--transition), color var(--transition);
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  background: var(--primary-light);
  color: var(--primary);
}

/* Language switcher */
.lang-switcher {
  position: relative;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-white);
  cursor: pointer;
  font-size: .875rem;
  font-weight: 500;
  color: var(--text);
  transition: border-color var(--transition);
}

.lang-btn:hover {
  border-color: var(--primary);
}

.lang-btn svg {
  width: 16px;
  height: 16px;
}

.lang-dropdown {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  min-width: 160px;
  z-index: 200;
  overflow: hidden;
}

.lang-switcher:hover .lang-dropdown,
.lang-switcher:focus-within .lang-dropdown {
  display: block;
}

.lang-dropdown a {
  display: block;
  padding: 10px 16px;
  color: var(--text);
  font-size: .875rem;
  transition: background var(--transition);
}

.lang-dropdown a:hover {
  background: var(--primary-light);
  color: var(--primary);
}

.lang-dropdown a.active {
  font-weight: 600;
  color: var(--primary);
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  margin: 5px 0;
  border-radius: 2px;
  transition: var(--transition);
}

/* --- Hero --- */
.hero {
  background: linear-gradient(135deg, #1a73e8 0%, #0d47a1 100%);
  color: #fff;
  padding: 80px 0 70px;
  text-align: center;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  margin-bottom: 16px;
  line-height: 1.2;
}

.hero p {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  opacity: .9;
  max-width: 640px;
  margin: 0 auto 32px;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 1.05rem;
  padding: 14px 32px;
  border-radius: 50px;
  box-shadow: 0 4px 14px rgba(255,109,0,.35);
  transition: background var(--transition), transform var(--transition);
}

.hero-cta:hover {
  background: var(--accent-dark);
  color: #fff;
  transform: translateY(-2px);
}

/* --- Section Headings --- */
.section-title {
  text-align: center;
  margin-bottom: 48px;
}

.section-title h2 {
  font-size: clamp(1.5rem, 3.5vw, 2.15rem);
  font-weight: 700;
  margin-bottom: 10px;
}

.section-title p {
  color: var(--text-light);
  max-width: 560px;
  margin: 0 auto;
  font-size: 1.05rem;
}

/* --- Game Cards Grid --- */
.games-section {
  padding: 72px 0;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.game-card {
  background: var(--bg-white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
}

.game-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.game-card__img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--primary-light);
}

.game-card__body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.game-card__tag {
  display: inline-block;
  background: var(--primary-light);
  color: var(--primary);
  font-size: .75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 50px;
  margin-bottom: 10px;
  width: fit-content;
  text-transform: uppercase;
  letter-spacing: .5px;
}

.game-card__title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.game-card__desc {
  color: var(--text-light);
  font-size: .925rem;
  margin-bottom: 16px;
  flex: 1;
}

.game-card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: .925rem;
  color: var(--primary);
}

.game-card__link:hover {
  gap: 10px;
}

.game-card__link svg {
  width: 18px;
  height: 18px;
  transition: transform var(--transition);
}

.game-card__link:hover svg {
  transform: translateX(3px);
}

/* --- Features / Why Section --- */
.features-section {
  padding: 72px 0;
  background: var(--bg-white);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 32px;
}

.feature-item {
  text-align: center;
  padding: 24px 16px;
}

.feature-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 16px;
  background: var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-icon svg {
  width: 28px;
  height: 28px;
  color: var(--primary);
}

.feature-item h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.feature-item p {
  color: var(--text-light);
  font-size: .925rem;
}

/* --- Quick Links (Printable / Solver / Blog) --- */
.quicklinks-section {
  padding: 72px 0;
}

.quicklinks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

.quicklink-card {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform var(--transition), box-shadow var(--transition);
}

.quicklink-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.quicklink-icon {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
}

.quicklink-icon svg {
  width: 28px;
  height: 28px;
  color: #fff;
}

.quicklink-icon--print {
  background: #34a853;
}

.quicklink-icon--solver {
  background: #ea4335;
}

.quicklink-icon--blog {
  background: #fbbc04;
}

.quicklink-text h3 {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.quicklink-text p {
  color: var(--text-light);
  font-size: .875rem;
}

/* --- SEO Content Block --- */
.seo-content {
  padding: 72px 0;
  background: var(--bg-white);
}

.seo-content__inner {
  max-width: 800px;
  margin: 0 auto;
}

.seo-content h2 {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.seo-content h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-top: 28px;
  margin-bottom: 10px;
}

.seo-content p {
  color: var(--text-light);
  margin-bottom: 14px;
  font-size: 1rem;
  line-height: 1.75;
}

.seo-content ul {
  margin: 0 0 14px 20px;
  color: var(--text-light);
}

.seo-content li {
  margin-bottom: 6px;
  font-size: 1rem;
}

/* --- FAQ Accordion --- */
.faq-section {
  padding: 72px 0;
}

.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
  overflow: hidden;
  background: var(--bg-white);
}

.faq-question {
  width: 100%;
  text-align: left;
  padding: 18px 20px;
  font-size: 1rem;
  font-weight: 600;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text);
  transition: background var(--transition);
}

.faq-question:hover {
  background: var(--primary-light);
}

.faq-question svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform var(--transition);
  color: var(--text-light);
}

.faq-item.active .faq-question svg {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}

.faq-answer__inner {
  padding: 0 20px 18px;
  color: var(--text-light);
  font-size: .95rem;
  line-height: 1.7;
}

.faq-item.active .faq-answer {
  max-height: 500px;
}

/* --- Footer --- */
.site-footer {
  background: #1a1d21;
  color: #ccc;
  padding: 56px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand p {
  font-size: .9rem;
  line-height: 1.7;
  margin-top: 12px;
  color: #9aa0a6;
}

.footer-col h4 {
  font-size: .875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 16px;
  color: #fff;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 10px;
}

.footer-col a {
  color: #9aa0a6;
  font-size: .875rem;
  transition: color var(--transition);
}

.footer-col a:hover {
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid #2d3136;
  padding: 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .8rem;
  color: #9aa0a6;
}

.footer-bottom a {
  color: #9aa0a6;
}

.footer-bottom a:hover {
  color: #fff;
}

/* --- Responsive --- */
@media (max-width: 900px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--bg-white);
    flex-direction: column;
    padding: 16px;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    width: 100%;
    padding: 12px 16px;
  }

  .hero {
    padding: 56px 0 48px;
  }

  .games-grid {
    grid-template-columns: 1fr;
  }

  .quicklinks-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }
}

/* ==========================================
   GAME PAGE LAYOUT
   ========================================== */
.game-hero {
  background: linear-gradient(135deg, #1a73e8 0%, #1558b0 50%, #0d47a1 100%);
  color: #fff;
  padding: 44px 0 36px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.game-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 50%, rgba(255,255,255,.08) 0%, transparent 50%),
              radial-gradient(circle at 80% 20%, rgba(255,255,255,.05) 0%, transparent 40%);
  pointer-events: none;
}

.game-hero h1 {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 800;
  margin-bottom: 8px;
  line-height: 1.2;
  position: relative;
}

.game-hero p {
  font-size: 1.05rem;
  opacity: .9;
  max-width: 580px;
  margin: 0 auto;
  position: relative;
}

/* ---------- Game Area ---------- */
.game-section {
  padding: 40px 0 56px;
  background: var(--bg);
}

.game-layout {
  display: flex;
  gap: 32px;
  align-items: flex-start;
  justify-content: center;
  flex-wrap: wrap;
}

.game-board-area {
  flex: 0 0 auto;
  width: 100%;
  max-width: 480px;
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-lg);
}

/* Difficulty bar */
.difficulty-bar {
  display: flex;
  gap: 6px;
  margin-bottom: 16px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 4px;
}

.diff-btn {
  flex: 1;
  min-width: 0;
  padding: 9px 4px;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: var(--text-light);
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  transition: background .2s ease, color .2s ease, box-shadow .2s ease;
}

.diff-btn:hover {
  background: var(--bg-white);
  color: var(--primary);
}

.diff-btn.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(26,115,232,.35);
}

/* Game info bar (timer, mistakes) */
.game-info-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  padding: 8px 12px;
  background: linear-gradient(135deg, #e8f0fe 0%, #f0e6ff 100%);
  border-radius: var(--radius-sm);
}

.game-info-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: .875rem;
  color: var(--text-light);
  font-weight: 500;
}

.game-info-item svg {
  width: 18px;
  height: 18px;
  min-width: 18px;
  flex-shrink: 0;
}

.game-info-item strong {
  color: var(--text);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

/* ---------- Sudoku Grid ---------- */
#sudoku-grid {
  display: grid;
  grid-template-columns: repeat(9, 1fr);
  width: 100%;
  max-width: 480px;
  aspect-ratio: 1;
  background: #8ba4c4;
  gap: 1px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(26,115,232,.18);
  border: 2px solid #5a7db5;
  user-select: none;
  -webkit-user-select: none;
}

#sudoku-grid .cell {
  background: #f7f9fc;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  font-size: clamp(1.1rem, 3.5vw, 1.6rem);
  transition: background .12s ease;
}

#sudoku-grid .cell.bt { border-top: 2.5px solid #3a6298; }
#sudoku-grid .cell.bl { border-left: 2.5px solid #3a6298; }
#sudoku-grid .cell.bb { border-bottom: 2.5px solid #3a6298; }
#sudoku-grid .cell.br { border-right: 2.5px solid #3a6298; }

#sudoku-grid .cell.related {
  background: #e8f0fe;
}

#sudoku-grid .cell.selected {
  background: #bbdefb;
  box-shadow: inset 0 0 0 2px var(--primary);
}

#sudoku-grid .cell.highlighted {
  background: #dcedc8;
}

#sudoku-grid .cell.given .cell-value {
  font-weight: 700;
  color: #1a2a3a;
}

#sudoku-grid .cell:not(.given) .cell-value {
  color: var(--primary);
  font-weight: 600;
}

#sudoku-grid .cell.wrong .cell-value,
#sudoku-grid .cell.conflict:not(.given) .cell-value {
  color: #d32f2f;
}

/* Notes inside cells */
.cell-notes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  width: 100%;
  height: 100%;
  padding: 2px;
}

.cell-notes .note {
  font-size: clamp(.5rem, 1.4vw, .7rem);
  color: #7a8aa0;
  display: flex;
  align-items: center;
  justify-content: center;
  visibility: hidden;
  font-weight: 500;
  line-height: 1;
}

.cell-notes .note.visible {
  visibility: visible;
}

/* ---------- Controls (below grid) ---------- */
.game-controls {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.numpad {
  display: grid;
  grid-template-columns: repeat(9, 1fr);
  gap: 6px;
}

.num-btn {
  aspect-ratio: 1;
  border: none;
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, #eef3fb 0%, #dce5f4 100%);
  font-size: clamp(1rem, 3vw, 1.35rem);
  font-weight: 700;
  color: #2a4a7f;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease, color .2s ease, transform .15s ease, box-shadow .2s ease;
}

.num-btn:hover {
  background: linear-gradient(180deg, #d6e4f7 0%, #c0d4f0 100%);
  color: var(--primary);
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(26,115,232,.2);
}

.num-btn:active {
  transform: translateY(0);
}

.num-btn.completed {
  opacity: .25;
  pointer-events: none;
}

/* Action buttons (undo, erase, pencil, hint) */
.action-btns {
  display: flex;
  gap: 8px;
}

.action-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 4px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-white);
  font-size: .72rem;
  font-weight: 600;
  color: var(--text-light);
  cursor: pointer;
  transition: background .2s ease, color .2s ease, border-color .2s ease, transform .15s ease;
}

.action-btn svg {
  width: 22px;
  height: 22px;
  min-width: 22px;
  flex-shrink: 0;
}

.action-btn:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

.action-btn.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 2px 8px rgba(26,115,232,.3);
}

.action-btn.active svg {
  color: #fff;
}

.new-game-btn {
  width: 100%;
  padding: 13px;
  border: none;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--accent) 0%, #ff8a30 100%);
  color: #fff;
  font-size: .95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background .2s ease, box-shadow .2s ease, transform .15s ease;
  box-shadow: 0 2px 8px rgba(255,109,0,.25);
  letter-spacing: .3px;
}

.new-game-btn:hover {
  background: linear-gradient(135deg, var(--accent-dark) 0%, var(--accent) 100%);
  box-shadow: 0 4px 12px rgba(255,109,0,.35);
  transform: translateY(-1px);
}

/* ---------- Completion Message ---------- */
.game-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 300;
  backdrop-filter: blur(3px);
}

.game-overlay.visible { display: block; }

.game-message {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 310;
  background: var(--bg-white);
  border-radius: var(--radius);
  padding: 40px 32px;
  text-align: center;
  box-shadow: 0 12px 40px rgba(0,0,0,.2);
  max-width: 380px;
  width: 90%;
  border-top: 4px solid var(--primary);
}

.game-message.visible { display: block; }

.game-message h3 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 8px;
  background: linear-gradient(135deg, var(--primary) 0%, #6a4fc7 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.game-message p {
  color: var(--text-light);
  margin-bottom: 6px;
}

.game-message .time-result {
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
  margin: 12px 0 20px;
}

.game-message .msg-btns {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.game-message .msg-btn {
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .9rem;
  cursor: pointer;
  border: none;
  transition: background .2s ease, transform .15s ease;
}

.game-message .msg-btn--primary {
  background: linear-gradient(135deg, var(--primary) 0%, #4a90e8 100%);
  color: #fff;
  box-shadow: 0 2px 8px rgba(26,115,232,.3);
}

.game-message .msg-btn--primary:hover {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  transform: translateY(-1px);
}

.game-message .msg-btn--secondary {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
}

.game-message .msg-btn--secondary:hover {
  background: var(--border);
}

/* ---------- Article under game ---------- */
.game-article {
  padding: 64px 0;
  background: var(--bg-white);
}

.game-article__inner {
  max-width: 800px;
  margin: 0 auto;
}

.game-article h2 {
  font-size: 1.65rem;
  font-weight: 800;
  margin-bottom: 18px;
  padding-left: 16px;
  border-left: 4px solid var(--primary);
  color: var(--text);
}

.game-article h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-top: 36px;
  margin-bottom: 12px;
  color: var(--primary);
}

.game-article p {
  color: var(--text-light);
  margin-bottom: 14px;
  font-size: 1rem;
  line-height: 1.78;
}

.game-article ul, .game-article ol {
  margin: 0 0 16px 24px;
  color: var(--text-light);
}

.game-article li {
  margin-bottom: 6px;
  font-size: 1rem;
  line-height: 1.7;
}

.game-article a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.game-article a:hover {
  color: var(--primary-dark);
}

/* Article callout boxes */
.article-callout {
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 24px 0;
  position: relative;
  border-left: 4px solid;
  font-size: .95rem;
  line-height: 1.7;
}

.article-callout__title {
  display: block;
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 6px;
}

.article-callout p {
  margin-bottom: 0;
  color: inherit;
}

.article-callout--tip {
  background: linear-gradient(135deg, #e8f5e9 0%, #f1f8f3 100%);
  border-left-color: #43a047;
  color: #2e5c30;
}

.article-callout--tip .article-callout__title {
  color: #2e7d32;
}

.article-callout--fact {
  background: linear-gradient(135deg, #ede7f6 0%, #f5f0ff 100%);
  border-left-color: #7c4dff;
  color: #42327d;
}

.article-callout--fact .article-callout__title {
  color: #5e35b1;
}

.article-callout--strategy {
  background: linear-gradient(135deg, #fff3e0 0%, #fffaf2 100%);
  border-left-color: var(--accent);
  color: #7a4200;
}

.article-callout--strategy .article-callout__title {
  color: #e65100;
}

/* ---------- Game page responsive ---------- */
@media (max-width: 520px) {
  .game-board-area {
    max-width: 100%;
    padding: 16px;
    border-radius: 0;
    box-shadow: none;
  }

  .game-section {
    padding: 20px 0 40px;
  }

  #sudoku-grid .cell {
    font-size: clamp(.95rem, 5vw, 1.3rem);
  }

  .numpad {
    gap: 4px;
  }

  .action-btns {
    gap: 4px;
  }

  .action-btn {
    padding: 8px 2px;
    font-size: .65rem;
  }

  .action-btn svg {
    width: 18px;
    height: 18px;
    min-width: 18px;
  }

  .difficulty-bar {
    gap: 3px;
    padding: 3px;
  }

  .diff-btn {
    padding: 7px 2px;
    font-size: .75rem;
  }

  .game-info-bar {
    padding: 6px 8px;
  }

  .game-article__inner {
    padding: 0 8px;
  }

  .article-callout {
    padding: 16px 18px;
    margin: 20px 0;
  }
}
