 * {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
      user-select: none;
    }

    body {
      background: linear-gradient(145deg, #ffffff 0%, #ffffff 100%);
      font-family: 'Segoe UI', 'Poppins', 'Google Sans', system-ui, -apple-system, 'Roboto', sans-serif;
      min-height: 100vh;
      display: flex;
      flex-direction: column;
    }

    /* ========== HEADER STYLES (as provided) ========== */
    .site-header {
      background: #0f2b3d;
      color: white;
      padding: 1rem 2rem;
      box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
      border-bottom: 3px solid #4caf7f;
    }

    .header-container {
      max-width: 1300px;
      margin: 0 auto;
      display: flex;
      flex-wrap: wrap;
      align-items: baseline;
      justify-content: space-between;
      gap: 1rem;
    }

    .logo h1 {
      font-size: 1.8rem;
      letter-spacing: 1px;
      font-weight: 600;
      background: linear-gradient(135deg, #fff, #b9fbc0);
      background-clip: text;
      -webkit-background-clip: text;
      color: transparent;
    }

    .nav-links {
      display: flex;
      gap: 1.8rem;
      flex-wrap: wrap;
    }

    .nav-btn {
      background: transparent;
      border: none;
      font-size: 1.2rem;
      font-weight: 600;
      padding: 0.5rem 1rem;
      cursor: pointer;
      color: #eef4ff;
      border-radius: 40px;
      transition: all 0.25s ease;
      font-family: inherit;
    }

    .nav-btn:hover {
      background: rgba(76, 175, 127, 0.25);
      color: white;
      transform: translateY(-2px);
    }

    .nav-btn.active {
      background: #4caf7f;
      color: #0f2b3d;
      box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    }

    /* ========== MAIN CONTENT (GAME AREA) ========== */
    .main-game-wrapper {
      flex: 1;
      display: flex;
      justify-content: center;
      align-items: center;
      padding: 2rem 1.5rem;
    }

    .game-card {
      max-width: 780px;
      width: 100%;
      background: rgba(30, 30, 35, 0.85);
      backdrop-filter: blur(4px);
      border-radius: 3rem;
      box-shadow: 0 25px 45px rgba(0, 0, 0, 0.5), 0 0 0 2px rgba(255, 215, 100, 0.3);
      overflow: hidden;
      transition: transform 0.2s ease;
    }

    /* game inner header */
    .game-header {
      background: #202124;
      padding: 1rem 2rem;
      display: flex;
      flex-wrap: wrap;
      align-items: baseline;
      justify-content: space-between;
      border-bottom: 3px solid #fbbc04;
    }

    .logo-area {
      display: flex;
      align-items: center;
      gap: 12px;
    }

    .snake-icon {
      font-size: 2.2rem;
      filter: drop-shadow(2px 2px 0 #3c8c40);
    }

    .game-title h2 {
      font-size: 1.5rem;
      background: linear-gradient(135deg, #f9f9f9, #fbbc04);
      background-clip: text;
      -webkit-background-clip: text;
      color: transparent;
    }

    .score-panel {
      background: #2c2f36;
      padding: 0.5rem 1.2rem;
      border-radius: 60px;
      display: flex;
      gap: 1.5rem;
    }

    .score-box, .best-box {
      text-align: center;
    }

    .score-label {
      font-size: 0.7rem;
      font-weight: 500;
      color: #fbbc04;
      text-transform: uppercase;
    }

    .score-value {
      font-size: 1.8rem;
      font-weight: 800;
      color: white;
      line-height: 1;
      font-family: monospace;
    }

    /* game content */
    .game-content {
      padding: 1.8rem 1.8rem 2rem;
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 1.4rem;
    }

    .canvas-wrapper {
      background: #0f1a0b;
      border-radius: 28px;
      padding: 12px;
      box-shadow: inset 0 0 8px #00000044, 0 12px 24px rgba(0,0,0,0.3);
    }

    canvas {
      background-color: #1e2b1a;
      display: block;
      margin: 0 auto;
      border-radius: 20px;
      box-shadow: 0 0 0 3px #fbbc04, 0 0 0 6px #2c2f24;
      cursor: pointer;
      width: 100%;
      height: auto;
    }

    .info-area {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      align-items: center;
      gap: 1rem;
      width: 100%;
    }

    .status {
      background: #101418cc;
      backdrop-filter: blur(8px);
      padding: 0.5rem 1.4rem;
      border-radius: 40px;
      font-weight: bold;
      font-size: 1.2rem;
      color: #f0f0f0;
      border-left: 4px solid #fbbc04;
    }

    .restart-btn {
      background: #fbbc04;
      border: none;
      font-weight: bold;
      font-size: 1rem;
      padding: 0.5rem 1.5rem;
      border-radius: 40px;
      display: inline-flex;
      align-items: center;
      gap: 8px;
      cursor: pointer;
      transition: all 0.2s;
      font-family: inherit;
      box-shadow: 0 2px 6px black;
    }

    .restart-btn:hover {
      background: #ffcf4a;
      transform: scale(1.02);
    }

    .direction-pad {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 6px;
      margin-top: 6px;
    }

    .dir-row {
      display: flex;
      gap: 16px;
      justify-content: center;
    }

    .dir-btn {
      background: #2b2e36;
      border: none;
      font-size: 1.8rem;
      padding: 6px 18px;
      border-radius: 32px;
      color: #fbbc04;
      cursor: pointer;
      transition: 0.1s linear;
      font-weight: bold;
      box-shadow: 0 3px 0 #121212;
    }

    .dir-btn:active {
      transform: translateY(2px);
      box-shadow: none;
    }

    .key-hint {
      color: #cfcfcf;
      background: #00000066;
      padding: 4px 12px;
      border-radius: 30px;
      font-size: 0.75rem;
    }

    /* ========== FOOTER STYLES (as provided) ========== */
    .site-footer {
      background: #0f2b3d;
      color: #cfdfec;
      padding: 1.6rem 2rem;
      margin-top: 2rem;
      border-top: 2px solid #2f5e4a;
    }

    .footer-container {
      max-width: 1200px;
      margin: 0 auto;
      display: flex;
      flex-wrap: wrap;
      justify-content: space-between;
      align-items: center;
      gap: 1rem;
    }

    .footer-copyright {
      font-size: 0.85rem;
      letter-spacing: 0.3px;
    }

    .footer-links {
      display: flex;
      gap: 2rem;
    }

    .footer-links span {
      cursor: default;
      font-size: 0.85rem;
      transition: 0.2s;
    }

    .footer-links span:hover {
      color: #FFFFFF;
    }

    @media (max-width: 680px) {
      .header-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
      }
      .nav-links {
        justify-content: center;
      }
      .game-header {
        flex-direction: column;
        align-items: center;
        gap: 12px;
      }
      .score-panel {
        gap: 1rem;
      }
      .game-content {
        padding: 1rem;
      }
      .dir-btn {
        padding: 4px 14px;
        font-size: 1.4rem;
      }
      .footer-container {
        flex-direction: column;
        text-align: center;
      }
       .footer-links {
            display: flex;
            gap: 2rem;
            justify-content: center;
            align-items: center;
            padding: 1.5rem;
            background: linear-gradient(135deg, #1a1a2e 50%, #FFFFFF 100%);
            border-radius: 12px;
            font-family: 'Arial', sans-serif;
        }

        .footer-links a {
            text-decoration: none;
            font-size: 1.2rem;
            font-weight: 600;
            padding: 0.5rem 1rem;
            border-radius: 25px;
            transition: all 0.3s ease;
            display: inline-flex;
            align-items: center;
            gap: 0.5rem;
        }

        /* Individual colors for each link */
        .footer-links a:nth-child(1) {
            color: #FFFFFF;
            background: rgba(255, 107, 107, 0.1);
            border: 1px solid rgba(255, 107, 107, 0.3);
        }

        .footer-links a:nth-child(1):hover {
            background: #FFFFFF;
            color: white;
            transform: translateY(-3px);
            box-shadow: 0 5px 15px rgba(255, 107, 107, 0.4);
        }

        .footer-links a:nth-child(2) {
            color: #FFFFFF;
            background: rgba(81, 207, 102, 0.1);
            border: 1px solid rgba(81, 207, 102, 0.3);
        }

        .footer-links a:nth-child(2):hover {
            background: #FFFFFF;
            color: white;
            transform: translateY(-3px);
            box-shadow: 0 5px 15px rgba(81, 207, 102, 0.4);
        }

        .footer-links a:nth-child(3) {
            color: #FFFFFF;
            background: rgba(255, 217, 61, 0.1);
            border: 1px solid rgba(255, 217, 61, 0.3);
        }

        .footer-links a:nth-child(3):hover {
            background: #FFFFFF;
            color: #1a1a2e;
            transform: translateY(-3px);
            box-shadow: 0 5px 15px rgba(255, 217, 61, 0.4);
        }

        /* Optional: responsive design */
        @media (max-width: 768px) {
            .footer-links {
                flex-direction: column;
                gap: 1rem;
            }
  
    }
  

/* ===== Article/content styles ===== */

    * {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
      user-select: none;
    }

    body {
      background: #ffffff;
      font-family: 'Segoe UI', 'Poppins', sans-serif;
      min-height: 100vh;
      display: flex;
      flex-direction: column;
      color: #222;
      line-height: 1.7;
    }

    /* HEADER */
    .site-header {
      background: #0f2b3d;
      color: white;
      padding: 1rem 2rem;
      box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
      border-bottom: 3px solid #4caf7f;
    }

    .header-container {
      max-width: 1300px;
      margin: 0 auto;
      display: flex;
      flex-wrap: wrap;
      align-items: baseline;
      justify-content: space-between;
      gap: 1rem;
    }

    .logo h1 {
      font-size: 1.8rem;
      letter-spacing: 1px;
      font-weight: 600;
      background: linear-gradient(135deg, #fff, #b9fbc0);
      background-clip: text;
      -webkit-background-clip: text;
      color: transparent;
    }

    .nav-links {
      display: flex;
      gap: 1.8rem;
      flex-wrap: wrap;
    }

    /* ARTICLE SECTION */
    .content-wrapper {
      max-width: 1100px;
      margin: 0 auto;
      padding: 3rem 1.5rem;
      flex: 1;
    }

    .hero-box {
      background: linear-gradient(135deg, #0f2b3d, #1f4b63);
      color: white;
      padding: 3rem 2rem;
      border-radius: 24px;
      margin-bottom: 3rem;
      text-align: center;
      box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    }

    .hero-box h1 {
      font-size: 3rem;
      margin-bottom: 1rem;
      color: #fbbc04;
    }

    .hero-box p {
      font-size: 1.2rem;
      max-width: 850px;
      margin: 0 auto;
    }

    .article-content {
      background: #fff;
      padding: 2rem;
      border-radius: 20px;
      box-shadow: 0 5px 20px rgba(0,0,0,0.06);
    }

    .article-content h2 {
      color: #0f2b3d;
      margin-top: 2rem;
      margin-bottom: 1rem;
      font-size: 2rem;
      border-left: 6px solid #4caf7f;
      padding-left: 14px;
    }

    .article-content h3 {
      margin-top: 1.5rem;
      color: #1f4b63;
      font-size: 1.4rem;
    }

    .article-content p {
      margin-bottom: 1rem;
      font-size: 1.05rem;
    }

    .article-content ul {
      padding-left: 1.5rem;
      margin-bottom: 1rem;
    }

    .article-content li {
      margin-bottom: 0.6rem;
    }

    .highlight-box {
      background: #f6fff8;
      border-left: 5px solid #4caf7f;
      padding: 1.2rem;
      border-radius: 14px;
      margin: 1.5rem 0;
    }

    /* FOOTER */
    .site-footer {
      background: #0f2b3d;
      color: #cfdfec;
      padding: 1.6rem 2rem;
      margin-top: 2rem;
      border-top: 2px solid #2f5e4a;
    }

    .footer-container {
      max-width: 1200px;
      margin: 0 auto;
      display: flex;
      flex-wrap: wrap;
      justify-content: space-between;
      align-items: center;
      gap: 1rem;
    }

    .footer-links {
      display: flex;
      gap: 2rem;
    }

    @media(max-width:768px){
      .hero-box h1{
        font-size:2rem;
      }

      .article-content{
        padding:1.2rem;
      }
    }
  

/* ===== Shared component defaults ===== */
html { scroll-behavior: smooth; }
img { max-width: 100%; height: auto; }
button, a { -webkit-tap-highlight-color: transparent; }
a { transition: opacity .2s ease, background .2s ease, transform .2s ease; }

.site-header { position: sticky; top: 0; z-index: 1000; }
.header-container { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.nav-links a { text-decoration: none; color: inherit; }
.nav-btn { text-decoration: none; }

/* Content pages */
.content-wrapper { width: min(1000px, calc(100% - 32px)); margin: 0 auto; }
.article-content { overflow-wrap: anywhere; }
.hero-box { overflow: hidden; }

/* Move formerly inline presentation into classes */
.canvas-responsive { width: 100%; height: auto; max-width: 600px; aspect-ratio: 1 / 1; }
.info-heading { margin-bottom: 1rem; color: #fbbc04; }
.info-paragraph { line-height: 1.5; margin-bottom: 1.2rem; }
.close-info-btn { background: #4caf7f; border: none; padding: 8px 24px; border-radius: 40px; cursor: pointer; font-weight: bold; }

/* Mobile-first usability */
@media (max-width: 768px) {
  .header-container { width: min(100% - 20px, 1180px); padding: 10px 0; }
  .site-header { position: sticky; }
  .logo h1 { font-size: 1.35rem; }
  .nav-links { gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
  .nav-btn { padding: 8px 10px; font-size: .82rem; }
  .main-game-wrapper { padding: 16px 10px; }
  .game-card { width: 100%; }
  .game-header { flex-wrap: wrap; gap: 10px; }
  .game-content { padding: 12px; }
  .score-panel { min-width: 0; }
  .direction-pad { margin-top: 10px; }
  .dir-btn { min-width: 52px; min-height: 52px; }
  .content-wrapper { width: min(100% - 20px, 1000px); }
  .hero-box { padding: 22px 16px; }
  .article-content { padding: 18px 14px; }
  .article-content h2 { font-size: 1.45rem; line-height: 1.25; }
  .article-content h3 { font-size: 1.15rem; }
  .site-footer { margin-top: 24px; }
  .footer-container { width: min(100% - 20px, 1180px); padding: 18px 0; flex-direction: column; gap: 10px; text-align: center; }
  .footer-links { flex-wrap: wrap; justify-content: center; gap: 10px 16px; }
}
@media (max-width: 480px) {
  .logo h1 { font-size: 1.15rem; }
  .nav-links { width: 100%; justify-content: center; }
  .game-title h2 { font-size: 1.05rem; }
  .score-value { font-size: 1.25rem; }
  .dir-btn { min-width: 48px; min-height: 48px; }
}


/* ===== Footer links: all three buttons white ===== */
.footer-links a,
.footer-links a:link,
.footer-links a:visited,
.footer-links a:hover,
.footer-links a:active {
    color: #FFFFFF !important;
}