<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  
  
  <title>Animal Trivia Quiz (10 Questions) | DoQuizzes</title>
  <meta name="description" content="Play Animal Trivia Quiz on DoQuizzes, a 10-question Just For Fun Multiple Choice quiz. Animal trivia awaits! Test your knowledge about fascinating creatures and their behaviors. Ready to discover how much you know?">
  <link rel="canonical" href="https://doquizzes.com/quizzes/multiple-choice/animal-trivia-quiz/">
  

  <!-- Open Graph -->
  <meta property="og:title" content="Animal Trivia Quiz (10 Questions) | DoQuizzes">
  <meta property="og:description" content="Play Animal Trivia Quiz on DoQuizzes, a 10-question Just For Fun Multiple Choice quiz. Animal trivia awaits! Test your knowledge about fascinating creatures and their behaviors. Ready to discover how much you know?">
  <meta property="og:type" content="article">
  <meta property="og:image" content="https://doquizzes.com/static/uploads/quiz-covers/animal-trivia-quiz_l.jpg">
  <meta property="og:url" content="https://doquizzes.com/quizzes/multiple-choice/animal-trivia-quiz/">
  <meta property="og:site_name" content="DoQuizzes">

  <!-- Twitter Card -->
  <meta name="twitter:card" content="summary_large_image">
  <meta name="twitter:site" content="@DoQuizzes">
  <meta name="twitter:title" content="Animal Trivia Quiz (10 Questions) | DoQuizzes">
  <meta name="twitter:description" content="Play Animal Trivia Quiz on DoQuizzes, a 10-question Just For Fun Multiple Choice quiz. Animal trivia awaits! Test your knowledge about fascinating creatures and their behaviors. Ready to discover how much you know?">
  <meta name="twitter:image" content="https://doquizzes.com/static/uploads/quiz-covers/animal-trivia-quiz_l.jpg">
  <meta name="twitter:image:alt" content="Animal Trivia Quiz (10 Questions) | DoQuizzes">
  

  <!-- Resource hints -->
  <link rel="preconnect" href="https://fonts.googleapis.com">
  <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
  <link rel="preconnect" href="https://static.getclicky.com">
  <link rel="dns-prefetch" href="https://pagead2.googlesyndication.com">
  <link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap" media="print" onload="this.media='all'">
  <noscript><link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap"></noscript>

  <link rel="stylesheet" href="/static/css/main.css?v=17775fce">
  

  <!-- Favicons -->
  <link rel="icon" href="/static/favicon.ico?v=3" sizes="any">
  <link rel="icon" type="image/png" sizes="32x32" href="/static/favicon-32.png?v=3">
  <link rel="icon" type="image/png" sizes="16x16" href="/static/favicon-16.png?v=3">
  <link rel="apple-touch-icon" href="/static/apple-touch-icon.png?v=3">
  <meta name="theme-color" content="#f5a100">

  <!-- OG image dimensions (always output — apply to default image too) -->
  <meta property="og:image:width" content="1200">
  <meta property="og:image:height" content="630">
  <meta property="og:locale" content="en_US">

  <!-- Schema.org JSON-LD -->
  <script type="application/ld+json">{"@context":"https://schema.org","@type":"WebSite","name":"DoQuizzes","url":"https://doquizzes.com","description":"Play free trivia and quiz games on DoQuizzes. Sports, Geography, Music, History, Science and thousands more!","potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://doquizzes.com/quizzes/?q={search_term_string}"},"query-input":"required name=search_term_string"}}</script>
  
  <script type="application/ld+json">
  {
    "@context": "https://schema.org",
    "@type": "BreadcrumbList",
    "itemListElement": [
      
      {
        "@type": "ListItem",
        "position": 1,
        "name": "Home",
        "item": "https://doquizzes.com/"
      },
      
      {
        "@type": "ListItem",
        "position": 2,
        "name": "Quizzes",
        "item": "https://doquizzes.com/quizzes/"
      },
      
      {
        "@type": "ListItem",
        "position": 3,
        "name": "Multiple Choice Quizzes",
        "item": "https://doquizzes.com/quizzes/multiple-choice/"
      },
      
      {
        "@type": "ListItem",
        "position": 4,
        "name": "Animal Trivia Quiz",
        "item": "https://doquizzes.com/quizzes/multiple-choice/animal-trivia-quiz/"
      }
      
    ]
  }
  </script>
  
  
<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": ["Quiz", "LearningResource"],
  "name": "Animal Trivia Quiz",
  "description": "Play Animal Trivia Quiz on DoQuizzes, a 10-question Just For Fun Multiple Choice quiz. Animal trivia awaits! Test your knowledge about fascinating creatures and their behaviors. Ready to discover how much you know?",
  "url": "https://doquizzes.com/quizzes/multiple-choice/animal-trivia-quiz/",
  "learningResourceType": "Quiz",
  "interactivityType": "active",
  "datePublished": "2026-04-28",
  "dateModified": "2026-06-08",
  "author": {
    
    "@type": "Person",
    "name": "DoQuizzes Team"
    
  },
  "educationalAlignment": {
    "@type": "AlignmentObject",
    "educationalFramework": "Trivia"
  },
  "about": "Just For Fun",
  "image": "https://doquizzes.com/static/uploads/quiz-covers/animal-trivia-quiz_l.jpg",
  "numberOfQuestions": 10,
  "interactionStatistic": {
    "@type": "InteractionCounter",
    "interactionType": "https://schema.org/PlayAction",
    "userInteractionCount": 5
  },
  
  "breadcrumb": {
    "@type": "BreadcrumbList",
    "itemListElement": [
      {"@type":"ListItem","position":1,"name":"Home","item":"https://doquizzes.com/"},
      {"@type":"ListItem","position":2,"name":"Quizzes","item":"https://doquizzes.com/quizzes/"},
      {"@type":"ListItem","position":3,"name":"Just For Fun","item":"https://doquizzes.com/quizzes/category/just-for-fun/"},
      {"@type":"ListItem","position":4,"name":"Animal Trivia Quiz","item":"https://doquizzes.com/quizzes/multiple-choice/animal-trivia-quiz/"}
      
    ]
  }
}
</script>


  <!-- Analytics & Ads -->
  <script async data-id="101462290" src="//static.getclicky.com/js"></script>
  
  
  <script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-5734292711266667" crossorigin="anonymous" data-overlays="bottom"></script>
  
<!-- Matomo -->
<script>
  var _paq = window._paq = window._paq || [];
  /* tracker methods like "setCustomDimension" should be called before "trackPageView" */
  _paq.push(['trackPageView']);
  _paq.push(['enableLinkTracking']);
  (function() {
    var u="//tracking.doquizzes.com/";
    _paq.push(['setTrackerUrl', u+'matomo.php']);
    _paq.push(['setSiteId', '3619']);
    var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
    g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
  })();
</script>
<!-- End Matomo Code -->
</head>
<body class="has-mob-nav ">

<!-- SVG Icon Sprite (inline for zero HTTP requests) -->
<div style="display:none" aria-hidden="true">

<svg xmlns="http://www.w3.org/2000/svg" style="display:none" aria-hidden="true">
  <symbol id="icon-home" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z"/><polyline points="9 22 9 12 15 12 15 22"/></symbol>
  <symbol id="icon-categories" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="3" width="7" height="7"/><rect x="14" y="3" width="7" height="7"/><rect x="14" y="14" width="7" height="7"/><rect x="3" y="14" width="7" height="7"/></symbol>
  <symbol id="icon-quiz" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"/><line x1="12" y1="17" x2="12.01" y2="17"/></symbol>
  <symbol id="icon-create" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="12" y1="5" x2="12" y2="19"/><line x1="5" y1="12" x2="19" y2="12"/></symbol>
  <symbol id="icon-multiplayer" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"/><circle cx="9" cy="7" r="4"/><path d="M23 21v-2a4 4 0 0 0-3-3.87"/><path d="M16 3.13a4 4 0 0 1 0 7.75"/></symbol>
  <symbol id="icon-search" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="11" cy="11" r="8"/><line x1="21" y1="21" x2="16.65" y2="16.65"/></symbol>
  <symbol id="icon-play" viewBox="0 0 24 24" fill="currentColor"><polygon points="5 3 19 12 5 21 5 3"/></symbol>
  <symbol id="icon-bookmark" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M19 21l-7-5-7 5V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2z"/></symbol>
  <symbol id="icon-star" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polygon points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"/></symbol>
  <symbol id="icon-star-filled" viewBox="0 0 24 24" fill="currentColor" stroke="none"><polygon points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"/></symbol>
  <symbol id="icon-trophy" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="8 21 12 21 16 21"/><line x1="12" y1="17" x2="12" y2="21"/><path d="M7 4H4a2 2 0 0 0-2 2v1a5 5 0 0 0 5 5h.5"/><path d="M17 4h3a2 2 0 0 1 2 2v1a5 5 0 0 1-5 5h-.5"/><path d="M7 4h10v8a5 5 0 0 1-5 5v0a5 5 0 0 1-5-5V4z"/></symbol>
  <symbol id="icon-check" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><polyline points="20 6 9 17 4 12"/></symbol>
  <symbol id="icon-x" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="18" y1="6" x2="6" y2="18"/><line x1="6" y1="6" x2="18" y2="18"/></symbol>
  <symbol id="icon-flag" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M4 15s1-1 4-1 5 2 8 2 4-1 4-1V3s-1 1-4 1-5-2-8-2-4 1-4 1z"/><line x1="4" y1="22" x2="4" y2="15"/></symbol>
  <symbol id="icon-bell" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9"/><path d="M13.73 21a2 2 0 0 1-3.46 0"/></symbol>
  <symbol id="icon-clock" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><polyline points="12 6 12 12 16 14"/></symbol>
  <symbol id="icon-refresh" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="23 4 23 10 17 10"/><path d="M20.49 15a9 9 0 1 1-2.12-9.36L23 10"/></symbol>
  <symbol id="icon-random" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="16 3 21 3 21 8"/><line x1="4" y1="20" x2="21" y2="3"/><polyline points="21 16 21 21 16 21"/><line x1="15" y1="15" x2="21" y2="21"/><line x1="4" y1="4" x2="9" y2="9"/></symbol>
  <symbol id="icon-trending" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="23 6 13.5 15.5 8.5 10.5 1 18"/><polyline points="17 6 23 6 23 12"/></symbol>
  <symbol id="icon-map" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polygon points="1 6 1 22 8 18 16 22 23 18 23 2 16 6 8 2 1 6"/><line x1="8" y1="2" x2="8" y2="18"/><line x1="16" y1="6" x2="16" y2="22"/></symbol>
  <symbol id="icon-table" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="3" width="18" height="18" rx="2"/><line x1="3" y1="9" x2="21" y2="9"/><line x1="3" y1="15" x2="21" y2="15"/><line x1="9" y1="9" x2="9" y2="21"/></symbol>
  <symbol id="icon-brain" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M9.5 2A2.5 2.5 0 0 1 12 4.5v15a2.5 2.5 0 0 1-4.96-.46 2.5 2.5 0 0 1-1.96-3 2.5 2.5 0 0 1-1.32-4.24 3 3 0 0 1 .34-5.58 2.5 2.5 0 0 1 1.32-4.24A2.5 2.5 0 0 1 9.5 2Z"/><path d="M14.5 2A2.5 2.5 0 0 0 12 4.5v15a2.5 2.5 0 0 0 4.96-.46 2.5 2.5 0 0 0 1.96-3 2.5 2.5 0 0 0 1.32-4.24 3 3 0 0 0-.34-5.58 2.5 2.5 0 0 0-1.32-4.24A2.5 2.5 0 0 0 14.5 2Z"/></symbol>
  <symbol id="icon-fire" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M8.5 14.5A2.5 2.5 0 0 0 11 12c0-1.38-.5-2-1-3-1.072-2.143-.224-4.054 2-6 .5 2.5 2 4.9 4 6.5 2 1.6 3 3.5 3 5.5a7 7 0 1 1-14 0c0-1.153.433-2.294 1-3a2.5 2.5 0 0 0 2.5 2.5z"/></symbol>
  <symbol id="icon-lock" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="11" width="18" height="11" rx="2" ry="2"/><path d="M7 11V7a5 5 0 0 1 10 0v4"/></symbol>
  <symbol id="icon-eye" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"/><circle cx="12" cy="12" r="3"/></symbol>
  <symbol id="icon-mail" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"/><polyline points="22,6 12,13 2,6"/></symbol>
  <symbol id="icon-chat" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"/></symbol>
  <symbol id="icon-edit" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"/><path d="M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z"/></symbol>
  <symbol id="icon-trash" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="3 6 5 6 21 6"/><path d="M19 6l-1 14a2 2 0 0 1-2 2H8a2 2 0 0 1-2-2L5 6"/><path d="M10 11v6"/><path d="M14 11v6"/><path d="M9 6V4a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v2"/></symbol>
  <symbol id="icon-chart" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="18" y1="20" x2="18" y2="10"/><line x1="12" y1="20" x2="12" y2="4"/><line x1="6" y1="20" x2="6" y2="14"/><line x1="2" y1="20" x2="22" y2="20"/></symbol>
  <symbol id="icon-lab" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M9 3H5a2 2 0 0 0-2 2v4m6-6h10a2 2 0 0 1 2 2v4M9 3v11l-5 5a2 2 0 0 0 1.41 3.41L12 21l6.59 1.41A2 2 0 0 0 20 19l-5-5V3"/></symbol>
  <symbol id="icon-profile" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2"/><circle cx="12" cy="7" r="4"/></symbol>
  <symbol id="icon-settings" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="3"/><path d="M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 1 1-2.83 2.83l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 1 1-4 0v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 1 1-2.83-2.83l.06-.06A1.65 1.65 0 0 0 4.68 15a1.65 1.65 0 0 0-1.51-1H3a2 2 0 1 1 0-4h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 1 1 2.83-2.83l.06.06A1.65 1.65 0 0 0 9 4.68a1.65 1.65 0 0 0 1-1.51V3a2 2 0 1 1 4 0v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 1 1 2.83 2.83l-.06.06A1.65 1.65 0 0 0 19.4 9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 1 1 0 4h-.09a1.65 1.65 0 0 0-1.51 1z"/></symbol>
  <symbol id="icon-menu" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="3" y1="12" x2="21" y2="12"/><line x1="3" y1="6" x2="21" y2="6"/><line x1="3" y1="18" x2="21" y2="18"/></symbol>
  <symbol id="icon-chevron-right" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="9 18 15 12 9 6"/></symbol>
  <symbol id="icon-chevron-down" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="6 9 12 15 18 9"/></symbol>
  <symbol id="icon-chevron-up" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="18 15 12 9 6 15"/></symbol>
  <symbol id="icon-chevron-left" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="15 18 9 12 15 6"/></symbol>
  <symbol id="icon-arrow-right" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="5" y1="12" x2="19" y2="12"/><polyline points="12 5 19 12 12 19"/></symbol>
  <symbol id="icon-arrow-left" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="19" y1="12" x2="5" y2="12"/><polyline points="12 19 5 12 12 5"/></symbol>
  <symbol id="icon-calendar" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="4" width="18" height="18" rx="2" ry="2"/><line x1="16" y1="2" x2="16" y2="6"/><line x1="8" y1="2" x2="8" y2="6"/><line x1="3" y1="10" x2="21" y2="10"/></symbol>
  <symbol id="icon-image" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="3" width="18" height="18" rx="2" ry="2"/><circle cx="8.5" cy="8.5" r="1.5"/><polyline points="21 15 16 10 5 21"/></symbol>
  <symbol id="icon-users" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"/><circle cx="9" cy="7" r="4"/><path d="M23 21v-2a4 4 0 0 0-3-3.87"/><path d="M16 3.13a4 4 0 0 1 0 7.75"/></symbol>
  <symbol id="icon-award" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="8" r="7"/><polyline points="8.21 13.89 7 23 12 20 17 23 15.79 13.88"/></symbol>
  <symbol id="icon-thumbs-up" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M14 9V5a3 3 0 0 0-3-3l-4 9v11h11.28a2 2 0 0 0 2-1.7l1.38-9a2 2 0 0 0-2-2.3H14z"/><path d="M7 22H4a2 2 0 0 1-2-2v-7a2 2 0 0 1 2-2h3"/></symbol>
  <symbol id="icon-thumbs-down" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M10 15v4a3 3 0 0 0 3 3l4-9V2H5.72a2 2 0 0 0-2 1.7l-1.38 9a2 2 0 0 0 2 2.3H10z"/><path d="M17 2h2.67A2.31 2.31 0 0 1 22 4v7a2.31 2.31 0 0 1-2.33 2H17"/></symbol>
  <symbol id="icon-warning" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"/><line x1="12" y1="9" x2="12" y2="13"/><line x1="12" y1="17" x2="12.01" y2="17"/></symbol>
  <symbol id="icon-info" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><line x1="12" y1="16" x2="12" y2="12"/><line x1="12" y1="8" x2="12.01" y2="8"/></symbol>
  <symbol id="icon-logout" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4"/><polyline points="16 17 21 12 16 7"/><line x1="21" y1="12" x2="9" y2="12"/></symbol>
  <symbol id="icon-share" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="18" cy="5" r="3"/><circle cx="6" cy="12" r="3"/><circle cx="18" cy="19" r="3"/><line x1="8.59" y1="13.51" x2="15.42" y2="17.49"/><line x1="15.41" y1="6.51" x2="8.59" y2="10.49"/></symbol>
  <symbol id="icon-globe" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><line x1="2" y1="12" x2="22" y2="12"/><path d="M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z"/></symbol>
  <symbol id="icon-upload" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="16 16 12 12 8 16"/><line x1="12" y1="12" x2="12" y2="21"/><path d="M20.39 18.39A5 5 0 0 0 18 9h-1.26A8 8 0 1 0 3 16.3"/></symbol>
  <symbol id="icon-list" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="8" y1="6" x2="21" y2="6"/><line x1="8" y1="12" x2="21" y2="12"/><line x1="8" y1="18" x2="21" y2="18"/><line x1="3" y1="6" x2="3.01" y2="6"/><line x1="3" y1="12" x2="3.01" y2="12"/><line x1="3" y1="18" x2="3.01" y2="18"/></symbol>
  <symbol id="icon-sparkle" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 3l1.88 5.76a2 2 0 0 0 1.27 1.27L21 12l-5.85 1.97a2 2 0 0 0-1.27 1.27L12 21l-1.88-5.76a2 2 0 0 0-1.27-1.27L3 12l5.85-1.97a2 2 0 0 0 1.27-1.27L12 3z"/></symbol>
  <symbol id="icon-acrostic" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="3" width="4" height="4"/><rect x="10" y="3" width="4" height="4"/><rect x="17" y="3" width="4" height="4"/><rect x="3" y="10" width="4" height="4"/><rect x="10" y="10" width="4" height="4"/><rect x="3" y="17" width="4" height="4"/><rect x="10" y="17" width="4" height="4"/><rect x="17" y="17" width="4" height="4"/></symbol>
  <symbol id="icon-bug" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="8" y="6" width="8" height="14" rx="4"/><path d="M19 7l-3 2"/><path d="M5 7l3 2"/><path d="M19 12h-3"/><path d="M5 12h3"/><path d="M19 17l-3-2"/><path d="M5 17l3-2"/><path d="M10 6V4h4v2"/></symbol>
  <symbol id="icon-more" viewBox="0 0 24 24" fill="currentColor"><circle cx="5" cy="12" r="2"/><circle cx="12" cy="12" r="2"/><circle cx="19" cy="12" r="2"/></symbol>
  <symbol id="icon-pause" viewBox="0 0 24 24" fill="currentColor"><rect x="6" y="4" width="4" height="16"/><rect x="14" y="4" width="4" height="16"/></symbol>
  <symbol id="icon-volume" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polygon points="11 5 6 9 2 9 2 15 6 15 11 19 11 5"/><path d="M19.07 4.93a10 10 0 0 1 0 14.14"/><path d="M15.54 8.46a5 5 0 0 1 0 7.07"/></symbol>
  <symbol id="icon-lock" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="11" width="18" height="11" rx="2" ry="2"/><path d="M7 11V7a5 5 0 0 1 10 0v4"/></symbol>
  <symbol id="icon-trending" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="22 7 13.5 15.5 8.5 10.5 2 17"/><polyline points="16 7 22 7 22 13"/></symbol>
</svg>
</div>

  <nav class="navbar" id="mainNav">

  <!-- ── PRIMARY BAR ── -->
  <div class="navbar-primary">
    <div class="container navbar-primary-inner">

      <!-- Hamburger -->
      <button class="nav-hamburger" id="navHamburger" onclick="toggleHamburger()" aria-label="Menu">
        <svg class="icon nav-ham-icon"><use href="#icon-menu"/></svg>
        <svg class="icon nav-ham-close"><use href="#icon-x"/></svg>
        <span class="nav-ham-label">Menu</span>
      </button>

      <!-- Logo -->
      <a href="/" class="nav-logo" aria-label="DoQuizzes home">
        <img src="/static/images/logo_icon.png" alt="" class="nav-logo-img">
        <span class="nav-logo-text">Do<span class="nav-logo-accent">Quizzes</span></span>
      </a>

      <!-- Top-level nav links -->
      <div class="nav-toplinks">
        <a href="/quizzes/" class="nav-toplink">Quizzes</a>
        <a href="/multiplayer/" class="nav-toplink">Multiplayer</a>
        <div class="nav-partner-wrapper" id="partnerMenuWrapper">
          <button class="nav-toplink nav-partner-btn" onclick="togglePartnerMenu(event)" aria-expanded="false" aria-haspopup="true">
            Partner Sites
            <svg width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" style="margin-left:4px;flex-shrink:0"><polyline points="6 9 12 15 18 9"/></svg>
          </button>
          <div class="nav-partner-menu">
            <a href="https://have.you" target="_blank" rel="noopener" class="nav-partner-item">
              <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><circle cx="12" cy="12" r="10"/><path d="M12 8v4l3 3"/></svg>
              <div><div class="nav-partner-name">Have You Ever</div><div class="nav-partner-desc">Discover fun "Have You Ever" questions</div></div>
            </a>
            <a href="https://typingtest.now" target="_blank" rel="noopener" class="nav-partner-item">
              <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="2" y="4" width="20" height="16" rx="2"/><path d="M8 10h8M8 14h4"/></svg>
              <div><div class="nav-partner-name">Typing Test</div><div class="nav-partner-desc">Measure your typing speed and accuracy</div></div>
            </a>
            <a href="https://humanbenchmark.now" target="_blank" rel="noopener" class="nav-partner-item">
              <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><path d="M22 12h-4l-3 9L9 3l-3 9H2"/></svg>
              <div><div class="nav-partner-name">Human Benchmark</div><div class="nav-partner-desc">Test your reaction time and memory</div></div>
            </a>
            <a href="https://minesweeper.now" target="_blank" rel="noopener" class="nav-partner-item">
              <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="3" y="3" width="18" height="18" rx="2"/><circle cx="12" cy="12" r="3"/></svg>
              <div><div class="nav-partner-name">Minesweeper</div><div class="nav-partner-desc">Classic minesweeper game online</div></div>
            </a>
            <a href="https://2048.now" target="_blank" rel="noopener" class="nav-partner-item">
              <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="3" y="3" width="8" height="8" rx="1"/><rect x="13" y="3" width="8" height="8" rx="1"/><rect x="3" y="13" width="8" height="8" rx="1"/><rect x="13" y="13" width="8" height="8" rx="1"/></svg>
              <div><div class="nav-partner-name">2048</div><div class="nav-partner-desc">The addictive number puzzle game</div></div>
            </a>
            <a href="https://sudoku.by" target="_blank" rel="noopener" class="nav-partner-item">
              <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><rect x="3" y="3" width="18" height="18" rx="1"/><line x1="9" y1="3" x2="9" y2="21"/><line x1="15" y1="3" x2="15" y2="21"/><line x1="3" y1="9" x2="21" y2="9"/><line x1="3" y1="15" x2="21" y2="15"/></svg>
              <div><div class="nav-partner-name">Sudoku</div><div class="nav-partner-desc">Free online Sudoku puzzles</div></div>
            </a>
          </div>
        </div>
      </div>

      <!-- Search -->
      <form action="/search/" method="get" class="navbar-search-bar" role="search">
        <svg class="icon navbar-search-icon"><use href="#icon-search"/></svg>
        <input type="text" name="q" placeholder="Search DoQuizzes…"
               value="" autocomplete="off" aria-label="Search DoQuizzes">
        <button type="submit" class="navbar-search-submit" aria-label="Go">
          <svg class="icon"><use href="#icon-arrow-right"/></svg>
        </button>
      </form>

      <!-- Auth -->
      <div class="navbar-primary-actions">
        
        <a href="/premium/" class="nav-premium-btn" onclick="event.preventDefault();openPremiumModal()">⭐ Premium</a>
        
        
          <a href="/auth/login/" class="btn btn-ghost btn-sm nav-signin-btn">Sign In</a>
          <a href="/auth/register/" class="btn btn-primary btn-sm nav-signup-btn">Sign Up Free</a>
        
      </div>

    </div>
  </div>

  <!-- ── SUB-NAV BAR ── -->
  <div class="navbar-sub">
    <div class="container navbar-sub-inner">
      <div class="navbar-sub-links">
        <a href="/quizzes/categories/" class="subnav-link">
          <svg class="icon icon-sm"><use href="#icon-categories"/></svg> Categories
        </a>
        <a href="/quizzes/new/" class="subnav-link">
          <svg class="icon icon-sm"><use href="#icon-sparkle"/></svg> Discover Quizzes
        </a>
        <a href="/quiz-maker/" class="subnav-link subnav-link-create">
          <svg class="icon icon-sm"><use href="#icon-create"/></svg> Create
        </a>
        <a href="/flashcards/" class="subnav-link">
          <svg class="icon icon-sm" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="2" y="4" width="20" height="16" rx="2"/><path d="M12 9v6M9 12h6"/></svg> Generate Flashcards
        </a>
        <a href="/jeopardy/" class="subnav-link">
          <svg class="icon icon-sm" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="3" width="18" height="18" rx="2"/><path d="M3 9h18M9 21V9M15 21V9"/></svg> Jeopardy Quiz
        </a>
        <a href="/quizzes/type/" class="subnav-link">
          <svg class="icon icon-sm"><use href="#icon-list"/></svg> Quizzes by Type
        </a>
        <a href="/acrostic/" class="subnav-link">
          <svg class="icon icon-sm"><use href="#icon-acrostic"/></svg> Acrostic Puzzles
        </a>
        <button class="subnav-btn subnav-more" onclick="toggleHamburger()" aria-label="More">
          <svg class="icon icon-sm"><use href="#icon-more"/></svg>
        </button>
      </div>
      <div class="navbar-sub-actions">
        <a href="/quizzes/random/" class="btn btn-dark btn-sm" rel="nofollow">
          <svg class="icon icon-sm"><use href="#icon-random"/></svg> Random Quiz
        </a>
      </div>
    </div>
  </div>

  <!-- ── HAMBURGER MEGA PANEL ── -->
  <div class="ham-panel" id="hamPanel" aria-hidden="true">
    <div class="container">

      <!-- Mobile-only auth strip -->
      
      <div class="ham-auth-strip">
        <a href="/auth/login/" class="btn btn-outline btn-sm">Sign In</a>
        <a href="/auth/register/" class="btn btn-primary btn-sm">Sign Up Free</a>
        <a href="/premium/" class="nav-premium-btn" style="margin-left:auto" onclick="event.preventDefault();openPremiumModal()">⭐ Premium</a>
      </div>
      

      <!-- Mobile search -->
      <form action="/search/" method="get" class="ham-search-form" role="search">
        <svg class="icon" style="color:var(--gray-400);flex-shrink:0"><use href="#icon-search"/></svg>
        <input type="text" name="q" placeholder="Search quizzes…"
               value="" autocomplete="off" aria-label="Search">
        <button type="submit" aria-label="Go" style="background:var(--primary);border:none;border-radius:8px;padding:6px 14px;cursor:pointer;color:#fff;font-weight:700;font-size:.88rem;flex-shrink:0">Search</button>
      </form>

      <div class="ham-grid">

        <!-- COL 1: Quiz Categories -->
        <div class="ham-col">
          <div class="ham-col-head">
            <svg class="icon icon-sm"><use href="#icon-categories"/></svg> Quiz Categories
          </div>
          <a href="/quizzes/" class="ham-link ham-link-all">All Quizzes</a>
          
          <a href="/quizzes/category/sports/" class="ham-link">Sports</a>
          
          <a href="/quizzes/category/geography/" class="ham-link">Geography</a>
          
          <a href="/quizzes/category/music/" class="ham-link">Music</a>
          
          <a href="/quizzes/category/movies/" class="ham-link">Movies</a>
          
          <a href="/quizzes/category/television/" class="ham-link">Television</a>
          
          <a href="/quizzes/category/just-for-fun/" class="ham-link">Just For Fun</a>
          
          <a href="/quizzes/category/miscellaneous/" class="ham-link">Miscellaneous</a>
          
          <a href="/quizzes/category/history/" class="ham-link">History</a>
          
          <a href="/quizzes/category/literature/" class="ham-link">Literature</a>
          
          <a href="/quizzes/category/language/" class="ham-link">Language</a>
          
          <a href="/quizzes/category/science/" class="ham-link">Science</a>
          
          <a href="/quizzes/category/gaming/" class="ham-link">Gaming</a>
          
          <a href="/quizzes/category/entertainment/" class="ham-link">Entertainment</a>
          
          <a href="/quizzes/category/religion/" class="ham-link">Religion</a>
          
          <a href="/quizzes/category/holiday/" class="ham-link">Holiday</a>
          
          <a href="/quizzes/categories/" class="ham-link ham-link-all">All Quiz Categories</a>
        </div>

        <!-- COL 2: Quiz Lists + Games -->
        <div class="ham-col">
          <div class="ham-col-head">
            <svg class="icon icon-sm"><use href="#icon-list"/></svg> Quiz Lists
          </div>
          <a href="/quizzes/type/" class="ham-link">By Type</a>
          <a href="/quizzes/popular/" class="ham-link">By Popularity</a>
          <a href="/quizzes/top-rated/" class="ham-link">By Rating</a>
          <a href="/quizzes/new/" class="ham-link">Discover</a>
          <a href="/quizzes/trending/" class="ham-link">Trending Today</a>
          <div class="ham-col-head" style="margin-top:22px">
            <svg class="icon icon-sm"><use href="#icon-quiz"/></svg> Games
          </div>
          <a href="/acrostic/" class="ham-link">Acrostic Puzzles</a>
          <a href="/games/live-5/" class="ham-link">Live 5</a>
          <a href="/games/trivia-bingo/" class="ham-link">Trivia Bingo</a>
          <a href="/games/math-test/" class="ham-link">Math Test</a>
        </div>

        <!-- COL 3: Create + Explore -->
        <div class="ham-col">
          <div class="ham-col-head">
            <svg class="icon icon-sm"><use href="#icon-edit"/></svg> Create
          </div>
          <a href="/quiz-maker/" class="ham-link">Create a New Quiz</a>
          <a href="/flashcards/" class="ham-link">Generate Flashcards</a>
          
          <a href="/jeopardy/" class="ham-link">Jeopardy Quiz</a>
          <div class="ham-col-head" style="margin-top:22px">
            <svg class="icon icon-sm"><use href="#icon-globe"/></svg> Explore
          </div>
          <a href="/achievements/" class="ham-link">Badges</a>
          <a href="/leaderboards/" class="ham-link">Leaderboards</a>
          <a href="/quizzes/popular/" class="ham-link">Most Popular</a>
          <a href="/quizzes/top-rated/" class="ham-link">Top Rated</a>
        </div>

        <!-- COL 4: Community -->
        <div class="ham-col">
          <div class="ham-col-head">
            <svg class="icon icon-sm"><use href="#icon-users"/></svg> Community
          </div>
          <a href="/multiplayer/" class="ham-link">Live Multiplayer</a>
          <a href="/achievements/" class="ham-link">Achievements</a>
          <a href="/acrostic/" class="ham-link">Daily Acrostic</a>
          
          <div class="ham-col-head" style="margin-top:22px">
            <svg class="icon icon-sm"><use href="#icon-info"/></svg> About
          </div>
          <a href="/about/" class="ham-link">About DoQuizzes</a>
          <a href="/feedback/" class="ham-link">Feedback</a>
          <a href="/blog/" class="ham-link">Blog</a>
        </div>

        <!-- COL 5: More + Account -->
        <div class="ham-col">
          <div class="ham-col-head">
            <svg class="icon icon-sm"><use href="#icon-more"/></svg> More
          </div>
          <a href="/blog/" class="ham-link">Blog</a>
          <a href="/about/" class="ham-link">About DoQuizzes</a>
          <a href="/feedback/" class="ham-link">Feedback</a>
          <div class="ham-col-head" style="margin-top:22px">
            <svg class="icon icon-sm"><use href="#icon-profile"/></svg>
            Sign In
          </div>
          
          <a href="/auth/login/" class="ham-link">Sign In</a>
          <a href="/auth/register/" class="ham-link" style="color:var(--primary);font-weight:700">Sign Up Free</a>
          
        </div>

      </div>
    </div>
  </div>

  <!-- Backdrop -->
  <div class="navbar-mega-backdrop" id="navMegaBackdrop" onclick="closeHamburger()"></div>

</nav>

<style>
.nav-premium-btn {
  display: inline-flex; align-items: center; gap: 5px;
  background: linear-gradient(135deg, #f5a100, #e08e00);
  color: #fff; font-weight: 800; font-size: .82rem;
  padding: 7px 14px; border-radius: 8px; text-decoration: none;
  white-space: nowrap; transition: filter .15s; letter-spacing: .01em;
}
.nav-premium-btn:hover { filter: brightness(1.08); color: #fff; }
.nav-partner-wrapper { position: relative; }
.nav-partner-btn { background: none; border: none; cursor: pointer; display: inline-flex; align-items: center; padding: 0; font-family: inherit; }
.nav-partner-menu {
  display: none; position: absolute; top: calc(100% + 14px); left: 50%; transform: translateX(-50%);
  background: #fff; border: 1px solid var(--gray-200); border-radius: 14px;
  box-shadow: 0 8px 32px rgba(0,0,0,.12); min-width: 280px; padding: 8px; z-index: 9000;
}
.nav-partner-wrapper.open .nav-partner-menu { display: block; }
.nav-partner-menu::before {
  content: ''; position: absolute; top: -6px; left: 50%; transform: translateX(-50%);
  width: 12px; height: 12px; background: #fff; border-left: 1px solid var(--gray-200);
  border-top: 1px solid var(--gray-200); rotate: 45deg;
}
.nav-partner-item {
  display: flex; align-items: flex-start; gap: 12px; padding: 10px 12px;
  border-radius: 9px; text-decoration: none; color: var(--gray-700);
  transition: background .12s; cursor: pointer;
}
.nav-partner-item:hover { background: var(--gray-50); color: var(--primary); }
.nav-partner-item svg { flex-shrink: 0; margin-top: 2px; opacity: .6; }
.nav-partner-name { font-size: .86rem; font-weight: 700; color: var(--gray-900); line-height: 1.3; }
.nav-partner-desc { font-size: .76rem; color: var(--gray-400); line-height: 1.35; margin-top: 1px; }
.nav-partner-item:hover .nav-partner-name { color: var(--primary); }
.ham-search-form {
  display: flex; align-items: center; gap: 10px;
  background: var(--gray-100); border-radius: 10px; padding: 8px 14px;
  margin-bottom: 20px;
}
.ham-search-form input {
  flex: 1; border: none; outline: none; background: transparent;
  font-size: .95rem; color: var(--gray-900); font-family: inherit;
}
.ham-search-form input::placeholder { color: var(--gray-400); }
</style>

<script>
(function() {
  var open = false;

  function openHamburger() {
    document.getElementById('hamPanel').classList.add('open');
    document.getElementById('navMegaBackdrop').classList.add('open');
    document.getElementById('navHamburger').classList.add('active');
    open = true;
  }

  function closeHamburger() {
    document.getElementById('hamPanel').classList.remove('open');
    document.getElementById('navMegaBackdrop').classList.remove('open');
    document.getElementById('navHamburger').classList.remove('active');
    open = false;
  }

  window.toggleHamburger = function() { if (open) closeHamburger(); else openHamburger(); };
  window.closeHamburger = closeHamburger;

  document.addEventListener('keydown', function(e) { if (e.key === 'Escape') closeHamburger(); });
})();

// ── User dropdown (click-to-toggle, no hover gap issue) ──────────────────────
(function() {
  var wrapper = document.getElementById('userMenuWrapper');
  if (!wrapper) return;

  window.toggleUserMenu = function(e) {
    e.stopPropagation();
    var isOpen = wrapper.classList.toggle('open');
    wrapper.querySelector('button').setAttribute('aria-expanded', isOpen);
  };

  // Close when clicking anywhere outside
  document.addEventListener('click', function(e) {
    if (wrapper && !wrapper.contains(e.target)) {
      wrapper.classList.remove('open');
      var btn = wrapper.querySelector('button');
      if (btn) btn.setAttribute('aria-expanded', 'false');
    }
  });

  // Close on Escape
  document.addEventListener('keydown', function(e) {
    if (e.key === 'Escape' && wrapper.classList.contains('open')) {
      wrapper.classList.remove('open');
      wrapper.querySelector('button').focus();
    }
  });
})();

// ── Partner Sites dropdown ──────────────────────────────────────────────────
(function() {
  var pw = document.getElementById('partnerMenuWrapper');
  if (!pw) return;
  window.togglePartnerMenu = function(e) {
    e.stopPropagation();
    pw.classList.toggle('open');
    pw.querySelector('button').setAttribute('aria-expanded', pw.classList.contains('open'));
  };
  document.addEventListener('click', function(e) {
    if (pw && !pw.contains(e.target)) pw.classList.remove('open');
  });
  document.addEventListener('keydown', function(e) {
    if (e.key === 'Escape') pw.classList.remove('open');
  });
})();
</script>

  

  

  



<!-- Hero -->
<div class="qd-hero">
  
  <div class="qd-hero-bg">
    <img src="/static/uploads/quiz-covers/animal-trivia-quiz.jpg"
         srcset="/static/uploads/quiz-covers/animal-trivia-quiz_s.jpg 480w, /static/uploads/quiz-covers/animal-trivia-quiz_m.jpg 800w, /static/uploads/quiz-covers/animal-trivia-quiz_l.jpg 1200w" sizes="100vw"
         alt="Animal Trivia Quiz"
         fetchpriority="high"
         decoding="async"
         width="1200" height="400">
  </div>
  <div class="qd-hero-overlay"></div>
  <div class="container qd-hero-inner">
    <div class="qd-hero-content">
      <nav class="breadcrumb breadcrumb-light">
        <a href="/">Home</a>
        <span class="breadcrumb-sep">›</span>
        <a href="/quizzes/category/just-for-fun/">Just For Fun</a><span class="breadcrumb-sep">›</span>
        <span>Animal Trivia Quiz</span>
      </nav>
      
      <h1 class="qd-hero-title">Animal Trivia Quiz</h1>
      <p class="qd-hero-desc">Animal trivia awaits! Test your knowledge about fascinating creatures and their behaviors. Ready to discover how much you know?</p>
      
      <div class="qd-meta-row">
        
        <a href="/quizzes/category/just-for-fun/" class="qd-meta-chip qd-meta-cat">
          <svg class="icon icon-sm"><use href="#icon-categories"/></svg> Just For Fun
        </a>
        
        <a href="/quizzes/multiple-choice/" class="qd-meta-chip qd-meta-type">
          
          <img src="/static/images/quiz-types/multiple_choice.png" alt="" width="14" height="14" style="object-fit:contain;vertical-align:middle;margin-right:3px">
          
          Multiple Choice
        </a>
        <span class="qd-meta-chip">
          <svg class="icon icon-sm"><use href="#icon-play"/></svg> 5 plays
        </span>
        <span class="qd-meta-chip">
          <svg class="icon icon-sm"><use href="#icon-list"/></svg> 10 questions
        </span>
        
        
        
        <span class="qd-meta-chip" title="Estimated time to complete">
          <svg class="icon icon-sm"><use href="#icon-clock"/></svg> ~2 min
        </span>
        
        
        
      </div>
    </div>
    <div class="qd-hero-cta">
      
      <a href="/quizzes/multiple-choice/animal-trivia-quiz/play/" class="btn btn-primary btn-lg qd-play-btn">
        <svg class="icon"><use href="#icon-play"/></svg>
        Play Now
      </a>
      <div class="qd-cta-actions">
        <button id="saveBtn" class="btn btn-ghost btn-sm qd-action-btn" onclick="toggleSave(573, false)">
          <svg class="icon icon-sm"><use href="#icon-bookmark"/></svg>
          <span id="saveBtnLabel">Save</span>
        </button>
        <button class="btn btn-ghost btn-sm qd-action-btn" onclick="openEmbedModal()">
          <svg class="icon icon-sm" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2"><polyline points="16 18 22 12 16 6"/><polyline points="8 6 2 12 8 18"/></svg> Embed
        </button>
        <button class="btn btn-ghost btn-sm qd-action-btn" onclick="openReportModal(573)">
          <svg class="icon icon-sm"><use href="#icon-flag"/></svg> Report
        </button>
      </div>

      <!-- Embed Modal -->
      <div id="embedModal" style="display:none;position:fixed;inset:0;background:rgba(0,0,0,.5);z-index:10000;align-items:center;justify-content:center;padding:20px" onclick="if(event.target===this)this.style.display='none'">
        <div style="background:#fff;border-radius:16px;padding:28px;max-width:520px;width:100%">
          <div style="display:flex;justify-content:space-between;align-items:center;margin-bottom:16px">
            <div class="modal-title-text" style="font-size:1.1rem;font-weight:800;margin:0">Embed This Quiz</div>
            <button onclick="document.getElementById('embedModal').style.display='none'" style="background:none;border:none;font-size:1.4rem;cursor:pointer;color:var(--gray-500)">×</button>
          </div>
          <p style="font-size:.85rem;color:var(--gray-500);margin-bottom:14px">Paste this code into any webpage to embed a live version of this quiz.</p>
          <textarea id="embedCode" readonly style="width:100%;font-family:monospace;font-size:.78rem;background:var(--gray-50);border:1.5px solid var(--gray-100);border-radius:8px;padding:12px;resize:none;height:90px;line-height:1.5"></textarea>
          <div style="display:flex;gap:10px;margin-top:12px">
            <button onclick="copyEmbed()" class="btn btn-primary" style="flex:1">Copy Code</button>
            <a id="embedPreviewLink" href="#" target="_blank" rel="noopener" class="btn btn-outline" style="flex:1;text-align:center">Preview</a>
          </div>
          <p id="embedCopyMsg" style="display:none;font-size:.82rem;color:var(--success);margin-top:8px;text-align:center">Copied to clipboard!</p>
        </div>
      </div>

      <!-- Report Modal -->
      <div id="reportModal" style="display:none;position:fixed;inset:0;background:rgba(0,0,0,.5);z-index:10000;align-items:center;justify-content:center" onclick="if(event.target===this)closeReportModal()">
        <div style="background:#fff;border-radius:16px;padding:28px;max-width:440px;width:92%;position:relative">
          <button onclick="closeReportModal()" style="position:absolute;top:12px;right:14px;background:none;border:none;font-size:1.4rem;cursor:pointer;color:var(--gray-400)">×</button>
          <div class="modal-title-text" style="font-size:1.1rem;font-weight:800;margin-bottom:6px">Report this quiz</div>
          <p style="font-size:.83rem;color:var(--gray-500);margin-bottom:16px">Let us know what's wrong and we'll review it.</p>
          <div style="margin-bottom:12px">
            <label style="font-size:.8rem;font-weight:700;color:var(--gray-600);display:block;margin-bottom:6px">Reason</label>
            <select id="reportReason" style="width:100%;padding:9px 12px;border:1.5px solid var(--gray-200);border-radius:8px;font-size:.88rem;outline:none">
              <option value="wrong_answer">Wrong answer</option>
              <option value="inappropriate">Inappropriate content</option>
              <option value="spam">Spam</option>
              <option value="copyright">Copyright issue</option>
              <option value="other">Other</option>
            </select>
          </div>
          <div style="margin-bottom:16px">
            <label style="font-size:.8rem;font-weight:700;color:var(--gray-600);display:block;margin-bottom:6px">Details <span style="font-weight:400;color:var(--gray-400)">(optional)</span></label>
            <textarea id="reportDetails" rows="3" placeholder="Tell us more…" style="width:100%;padding:9px 12px;border:1.5px solid var(--gray-200);border-radius:8px;font-size:.88rem;resize:vertical;outline:none;font-family:inherit;box-sizing:border-box"></textarea>
          </div>
          <div id="reportMsg" style="font-size:.8rem;min-height:16px;margin-bottom:10px"></div>
          <div style="display:flex;gap:10px;justify-content:flex-end">
            <button onclick="closeReportModal()" class="btn btn-ghost btn-sm">Cancel</button>
            <button onclick="submitReport()" class="btn btn-sm" style="background:#ef4444;color:#fff;border:none">Submit Report</button>
          </div>
        </div>
      </div>
      <!-- Share Panel -->
      <div class="qd-share-panel">
        <div class="qd-share-label">Share this quiz</div>
        <div class="qd-share-grid">
          <a id="share-wa" href="#" target="_blank" rel="noopener" class="qd-share-btn" style="background:#25D366" title="WhatsApp">
            <svg width="18" height="18" viewBox="0 0 24 24" fill="white"><path d="M17.472 14.382c-.297-.149-1.758-.867-2.03-.967-.273-.099-.471-.148-.67.15-.197.297-.767.966-.94 1.164-.173.199-.347.223-.644.075-.297-.15-1.255-.463-2.39-1.475-.883-.788-1.48-1.761-1.653-2.059-.173-.297-.018-.458.13-.606.134-.133.298-.347.446-.52.149-.174.198-.298.298-.497.099-.198.05-.371-.025-.52-.075-.149-.669-1.612-.916-2.207-.242-.579-.487-.5-.669-.51-.173-.008-.371-.01-.57-.01-.198 0-.52.074-.792.372-.272.297-1.04 1.016-1.04 2.479 0 1.462 1.065 2.875 1.213 3.074.149.198 2.096 3.2 5.077 4.487.709.306 1.262.489 1.694.625.712.227 1.36.195 1.871.118.571-.085 1.758-.719 2.006-1.413.248-.694.248-1.289.173-1.413-.074-.124-.272-.198-.57-.347m-5.421 7.403h-.004a9.87 9.87 0 01-5.031-1.378l-.361-.214-3.741.982.998-3.648-.235-.374a9.86 9.86 0 01-1.51-5.26c.001-5.45 4.436-9.884 9.888-9.884 2.64 0 5.122 1.03 6.988 2.898a9.825 9.825 0 012.893 6.994c-.003 5.45-4.437 9.884-9.885 9.884m8.413-18.297A11.815 11.815 0 0012.05 0C5.495 0 .16 5.335.157 11.892c0 2.096.547 4.142 1.588 5.945L.057 24l6.305-1.654a11.882 11.882 0 005.683 1.448h.005c6.554 0 11.89-5.335 11.893-11.893a11.821 11.821 0 00-3.48-8.413z"/></svg>
          </a>
          <a id="share-tg" href="#" target="_blank" rel="noopener" class="qd-share-btn" style="background:#0088cc" title="Telegram">
            <svg width="18" height="18" viewBox="0 0 24 24" fill="white"><path d="M11.944 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0a12 12 0 0 0-.056 0zm4.962 7.224c.1-.002.321.023.465.14a.506.506 0 0 1 .171.325c.016.093.036.306.02.472-.18 1.898-.962 6.502-1.36 8.627-.168.9-.499 1.201-.82 1.23-.696.065-1.225-.46-1.9-.902-1.056-.693-1.653-1.124-2.678-1.8-1.185-.78-.417-1.21.258-1.91.177-.184 3.247-2.977 3.307-3.23.007-.032.014-.15-.056-.212s-.174-.041-.249-.024c-.106.024-1.793 1.14-5.061 3.345-.48.33-.913.49-1.302.48-.428-.008-1.252-.241-1.865-.44-.752-.245-1.349-.374-1.297-.789.027-.216.325-.437.893-.663 3.498-1.524 5.83-2.529 6.998-3.014 3.332-1.386 4.025-1.627 4.476-1.635z"/></svg>
          </a>
          <a id="share-x" href="#" target="_blank" rel="noopener" class="qd-share-btn" style="background:#000" title="X (Twitter)">
            <svg width="16" height="16" viewBox="0 0 24 24" fill="white"><path d="M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-4.714-6.231-5.401 6.231H2.744l7.73-8.835L1.254 2.25H8.08l4.253 5.622 5.911-5.622zm-1.161 17.52h1.833L7.084 4.126H5.117z"/></svg>
          </a>
          <a id="share-reddit" href="#" target="_blank" rel="noopener" class="qd-share-btn" style="background:#ff4500" title="Reddit">
            <svg width="18" height="18" viewBox="0 0 24 24" fill="white"><path d="M12 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0zm5.01 4.744c.688 0 1.25.561 1.25 1.249a1.25 1.25 0 0 1-2.498.056l-2.597-.547-.8 3.747c1.824.07 3.48.632 4.674 1.488.308-.309.73-.491 1.207-.491.968 0 1.754.786 1.754 1.754 0 .716-.435 1.333-1.01 1.614a3.111 3.111 0 0 1 .042.52c0 2.694-3.13 4.87-7.004 4.87-3.874 0-7.004-2.176-7.004-4.87 0-.183.015-.366.043-.534A1.748 1.748 0 0 1 4.028 12c0-.968.786-1.754 1.754-1.754.463 0 .898.196 1.207.49 1.207-.883 2.878-1.43 4.744-1.487l.885-4.182a.342.342 0 0 1 .14-.197.35.35 0 0 1 .238-.042l2.906.617a1.214 1.214 0 0 1 1.108-.701zM9.25 12C8.561 12 8 12.562 8 13.25c0 .687.561 1.248 1.25 1.248.687 0 1.248-.561 1.248-1.249 0-.688-.561-1.249-1.249-1.249zm5.5 0c-.687 0-1.248.561-1.248 1.25 0 .687.561 1.248 1.249 1.248.688 0 1.249-.561 1.249-1.249 0-.687-.562-1.249-1.25-1.249zm-5.466 3.99a.327.327 0 0 0-.231.094.33.33 0 0 0 0 .463c.842.842 2.484.913 2.961.913.477 0 2.105-.056 2.961-.913a.361.361 0 0 0 .029-.463.33.33 0 0 0-.464 0c-.547.533-1.684.73-2.512.73-.828 0-1.979-.196-2.512-.73a.326.326 0 0 0-.232-.095z"/></svg>
          </a>
          <a id="share-fb" href="#" target="_blank" rel="noopener" class="qd-share-btn" style="background:#1877f2" title="Facebook">
            <svg width="18" height="18" viewBox="0 0 24 24" fill="white"><path d="M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z"/></svg>
          </a>
          <a id="share-ig" href="#" class="qd-share-btn" style="background:radial-gradient(circle at 30% 107%,#fdf497 0%,#fd5949 45%,#d6249f 60%,#285AEB 90%)" title="Instagram" onclick="shareInstagram(event)">
            <svg width="18" height="18" viewBox="0 0 24 24" fill="white"><path d="M12 2.163c3.204 0 3.584.012 4.85.07 3.252.148 4.771 1.691 4.919 4.919.058 1.265.069 1.645.069 4.849 0 3.205-.012 3.584-.069 4.849-.149 3.225-1.664 4.771-4.919 4.919-1.266.058-1.644.07-4.85.07-3.204 0-3.584-.012-4.849-.07-3.26-.149-4.771-1.699-4.919-4.92-.058-1.265-.07-1.644-.07-4.849 0-3.204.013-3.583.07-4.849.149-3.227 1.664-4.771 4.919-4.919 1.266-.057 1.645-.069 4.849-.069zm0-2.163c-3.259 0-3.667.014-4.947.072-4.358.2-6.78 2.618-6.98 6.98-.059 1.281-.073 1.689-.073 4.948 0 3.259.014 3.668.072 4.948.2 4.358 2.618 6.78 6.98 6.98 1.281.058 1.689.072 4.948.072 3.259 0 3.668-.014 4.948-.072 4.354-.2 6.782-2.618 6.979-6.98.059-1.28.073-1.689.073-4.948 0-3.259-.014-3.667-.072-4.947-.196-4.354-2.617-6.78-6.979-6.98-1.281-.059-1.69-.073-4.949-.073zm0 5.838c-3.403 0-6.162 2.759-6.162 6.162S8.597 18.163 12 18.163s6.162-2.759 6.162-6.162S15.403 5.838 12 5.838zm0 10.162c-2.209 0-4-1.79-4-4 0-2.209 1.791-4 4-4s4 1.791 4 4c0 2.21-1.791 4-4 4zm6.406-11.845c-.796 0-1.441.645-1.441 1.44s.645 1.44 1.441 1.44c.795 0 1.439-.645 1.439-1.44s-.644-1.44-1.439-1.44z"/></svg>
          </a>
        </div>
        <button onclick="copyQuizLink(this)" class="qd-share-copy-btn">
          <svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><rect x="9" y="9" width="13" height="13" rx="2"/><path d="M5 15H4a2 2 0 01-2-2V4a2 2 0 012-2h9a2 2 0 012 2v1"/></svg>
          Copy Link
        </button>
      </div>
      <div class="qd-creator-row">
        
        by <span class="qd-creator-link">
          <img src="https://ui-avatars.com/api/?name=seed_user&amp;background=6366f1&amp;color=fff&amp;size=128" alt="DoQuizzes Team" class="qd-creator-avatar">
          DoQuizzes Team
        </span>
        
      </div>
    </div>
  </div>
</div>

<!-- Full-width Play CTA strip -->
<div class="qd-top-play-strip">
  <div class="container">
    <a href="/quizzes/multiple-choice/animal-trivia-quiz/play/" class="qd-top-play-btn">
      <svg class="icon" width="22" height="22"><use href="#icon-play"/></svg>
      Play Now
    </a>
  </div>
</div>

<!-- Body -->
<div class="container qd-layout">

  <!-- Main column -->
  <div class="qd-col-main">

    

    
    <div class="qd-card qd-body-card">
      <div class="quiz-body-content"><p>Animal trivia is a fun way to challenge your knowledge about the diverse world of wildlife. Whether you're a budding zoologist or just a casual animal lover, this quiz will put your understanding of fascinating creatures and their behaviors to the test. From the mighty African elephant to the elusive snow leopard, discover how well you really know the <a href="/quizzes/classic/animals-quiz/" class="ql-link">animal kingdom</a>!</p>
<h2>What are some interesting facts about different animals?</h2>
<p>Animals are incredibly diverse, exhibiting unique adaptations and behaviors. For instance, did you know that <strong>octopuses</strong> have three hearts and blue blood? Or that a <a href="/quizzes/clickable/animal-groups-quiz/" class="ql-link">group of flamingos</a> is called a <strong>flamboyance</strong>? Many animals possess extraordinary abilities that help them survive in their environments, whether it's the <a href="/quizzes/order-up/animals-by-speed/" class="ql-link">incredible speed</a> of a cheetah or the unique camouflage of a chameleon. Understanding these traits not only enriches our appreciation for wildlife but also informs conservation efforts aimed at protecting endangered species.</p>
<h2>How can I learn more about animal trivia?</h2>
<p>If you're curious about the animal world, quizzes like this one are a perfect way to gain new insights and fun facts. Engaging with trivia not only tests your memory but also encourages learning about various species and their ecosystems. From mammals to birds, insects to reptiles, each category holds a treasure trove of knowledge waiting to be discovered. Explore the connections between animals and their habitats, and expand your understanding of the planet's biodiversity.</p>
<p>Now it's your turn! <a href="/quizzes/multiple-choice/easy-quiz/" class="ql-link">Test your knowledge</a> of animal trivia and see how many questions you can answer correctly. <strong>Take the quiz</strong> and discover your score!</p></div>
    </div>
    

    <div class="qd-card qd-explore-card">
      <div class="qd-card-head"><h2 style="margin:0;font-size:inherit;font-weight:inherit;display:inline-flex;align-items:center;gap:6px;line-height:inherit"><svg class="icon icon-sm"><use href="#icon-categories"/></svg> Explore More Like This</h2></div>
      <div class="qd-explore-links">
        
        
        <a href="/quizzes/category/just-for-fun/">
          <strong>Just For Fun Quizzes</strong>
          <span>Browse the main just for fun quiz hub</span>
        </a>
        <a href="/quizzes/category/just-for-fun/newest/">
          <strong>Newest Just For Fun Quizzes</strong>
          <span>Freshly published quizzes in this category</span>
        </a>
        <a href="/quizzes/category/just-for-fun/alltime/">
          <strong>Most Popular Just For Fun Quizzes</strong>
          <span>All-time play-count rankings</span>
        </a>
        
        <a href="/quizzes/multiple-choice/">
          <strong>Multiple Choice Quizzes</strong>
          <span>More quizzes in this format</span>
        </a>
      </div>
    </div>

    <!-- Play Now CTA -->
    <div class="qd-play-now-cta">
      <div class="qd-pnc-text">
        <div class="qd-pnc-title">Ready to play?</div>
        <div class="qd-pnc-sub">10 questions</div>
      </div>
      <a href="/quizzes/multiple-choice/animal-trivia-quiz/play/" class="btn btn-primary btn-lg qd-pnc-btn">
        <svg class="icon"><use href="#icon-play"/></svg>
        Play Now
      </a>
    </div>

    
    <!-- Question Preview -->
    <div class="qd-preview">
      <div class="qd-preview-label">Question 1 of 10 — Preview</div>
      <div class="qd-preview-prompt">What is the fastest land animal in the world?</div>
      
      <div class="qd-preview-answers">
        
        <div class="qd-preview-ans">
          Cheetah
          
          <div class="qd-preview-overlay">
            <svg class="icon icon-sm" style="stroke:var(--gray-600)"><use href="#icon-lock"/></svg> Play to answer
          </div>
          
        </div>
        
        <div class="qd-preview-ans">
          Lion
          
        </div>
        
        <div class="qd-preview-ans">
          Springbok
          
        </div>
        
        <div class="qd-preview-ans">
          Pronghorn
          
        </div>
        
      </div>
      
      <a href="/quizzes/multiple-choice/animal-trivia-quiz/play/" class="btn btn-primary btn-sm" style="margin-top:14px">
        <svg class="icon icon-sm"><use href="#icon-play"/></svg> Play &amp; Answer
      </a>
    </div>
    

    <!-- Star Rating -->
    <div class="qd-card qd-rating-card">
      <div class="qd-card-head"><svg class="icon icon-sm"><use href="#icon-star-filled"/></svg> Rate This Quiz</div>
      
      <p class="qd-rating-hint" style="padding:16px 18px">
        <a href="/auth/login/">Sign in</a> to rate this quiz.
        
      </p>
      
    </div>

    <!-- Comments -->
    <div class="qd-card" id="commentsSection">
      <div class="qd-card-head">
        <h2 style="margin:0;font-size:inherit;font-weight:inherit;display:inline-flex;align-items:center;gap:6px;line-height:inherit">
          <svg class="icon icon-sm"><use href="#icon-chat"/></svg>
          Comments <span class="qd-card-head-sub" id="commentCountBadge">0</span>
        </h2>
        <div class="qd-card-head-actions">
          <select id="commentSort" onchange="reloadComments()" class="form-control form-control-sm">
            <option value="newest">Newest</option>
            <option value="oldest">Oldest</option>
            <option value="top">Top Rated</option>
          </select>
          <button onclick="toggleComments()" class="btn btn-ghost btn-sm" id="toggleCommentsBtn">Hide</button>
        </div>
      </div>

      <div id="commentsBody">
        
        <div class="qd-login-prompt">
          <a href="/auth/login/">Sign in</a> to join the discussion.
        </div>
        

        <div id="commentList">
          
          <p class="qd-no-comments">No comments yet. Be the first!</p>
          
        </div>
      </div>
    </div>
  </div>

  <!-- Sidebar -->
  <aside class="qd-col-side">

    <!-- Stats -->
    <div class="qd-card qd-stats-card">
      <div class="qd-card-head"><h2 style="margin:0;font-size:inherit;font-weight:inherit;display:inline-flex;align-items:center;gap:6px;line-height:inherit"><svg class="icon icon-sm"><use href="#icon-chart"/></svg> Quiz Stats</h2></div>
      <div class="qd-stat-row"><span>Questions</span><strong>10</strong></div>
      <div class="qd-stat-row"><span>Total Plays</span><strong>5</strong></div>
      <div class="qd-stat-row"><span>Avg Score</span><strong>0%</strong></div>
      <div class="qd-stat-row"><span>Completion</span><strong>0.0%</strong></div>
      
    </div>

    <!-- Creator -->
    <div class="qd-card qd-creator-card">
      <div class="qd-card-head"><svg class="icon icon-sm"><use href="#icon-profile"/></svg> Creator</div>
      
      <span class="qd-creator-profile">
        <img src="https://ui-avatars.com/api/?name=seed_user&amp;background=6366f1&amp;color=fff&amp;size=128" alt="DoQuizzes Team" class="qd-creator-profile-img">
        <div>
          <div class="qd-creator-name">DoQuizzes Team</div>
          <div class="qd-creator-sub">None XP</div>
        </div>
      </span>
      
    </div>

    <!-- Related -->
    <!-- Create CTA -->
    <div style="background:linear-gradient(160deg,#0f172a,#1e3a2f);border-radius:14px;padding:20px;margin-bottom:16px;text-align:center">
      <div style="font-size:1.3rem;margin-bottom:6px">✏️</div>
      <div style="font-weight:800;color:#fff;font-size:.95rem;margin-bottom:4px">Make a Quiz Like This</div>
      <div style="font-size:.8rem;color:#94a3b8;margin-bottom:14px">9 quiz types. Free. No coding needed.</div>
      <a href="/quiz-maker/" class="btn" style="background:#16a34a;color:#fff;font-weight:700;padding:9px 20px;border-radius:30px;font-size:.85rem;border:none;width:100%;display:block">
        + Create a Quiz
      </a>
    </div>

    

    
    <div class="qd-card">
      <div class="qd-card-head"><h2 style="margin:0;font-size:inherit;font-weight:inherit;display:inline-flex;align-items:center;gap:6px;line-height:inherit"><svg class="icon icon-sm"><use href="#icon-quiz"/></svg> Related Quizzes</h2></div>
      
      <a href="/quizzes/multiple-choice/am-i-black-quiz/" class="qd-related-item">
        <div class="qd-related-thumb">
          
          <img src="/static/uploads/quiz-covers/am-i-black-quiz.jpg" srcset="/static/uploads/quiz-covers/am-i-black-quiz_s.jpg 480w, /static/uploads/quiz-covers/am-i-black-quiz_m.jpg 800w, /static/uploads/quiz-covers/am-i-black-quiz_l.jpg 1200w" sizes="80px" alt="Am I Black Quiz" loading="lazy">
          
        </div>
        <div class="qd-related-info">
          <div class="qd-related-title">Am I Black Quiz</div>
          <div class="qd-related-meta">56 plays</div>
        </div>
      </a>
      
      <a href="/quizzes/multiple-choice/does-my-coworker-like-me-quiz/" class="qd-related-item">
        <div class="qd-related-thumb">
          
          <img src="/static/uploads/quiz-covers/does-my-coworker-like-me-quiz.jpg" srcset="/static/uploads/quiz-covers/does-my-coworker-like-me-quiz_s.jpg 480w, /static/uploads/quiz-covers/does-my-coworker-like-me-quiz_m.jpg 800w, /static/uploads/quiz-covers/does-my-coworker-like-me-quiz_l.jpg 1200w" sizes="80px" alt="Does My Coworker Like Me Quiz" loading="lazy">
          
        </div>
        <div class="qd-related-info">
          <div class="qd-related-title">Does My Coworker Like Me Quiz</div>
          <div class="qd-related-meta">37 plays</div>
        </div>
      </a>
      
      <a href="/quizzes/multiple-choice/should-i-get-fat-quiz/" class="qd-related-item">
        <div class="qd-related-thumb">
          
          <img src="/static/uploads/quiz-covers/should-i-get-fat-quiz.jpg" srcset="/static/uploads/quiz-covers/should-i-get-fat-quiz_s.jpg 480w, /static/uploads/quiz-covers/should-i-get-fat-quiz_m.jpg 800w, /static/uploads/quiz-covers/should-i-get-fat-quiz_l.jpg 1200w" sizes="80px" alt="Should I Get Fat Quiz" loading="lazy">
          
        </div>
        <div class="qd-related-info">
          <div class="qd-related-title">Should I Get Fat Quiz</div>
          <div class="qd-related-meta">30 plays</div>
        </div>
      </a>
      
      <a href="/quizzes/picture/flags-quiz/" class="qd-related-item">
        <div class="qd-related-thumb">
          
          <img src="/static/uploads/quiz-covers/flags-quiz.jpg" srcset="/static/uploads/quiz-covers/flags-quiz_s.jpg 480w, /static/uploads/quiz-covers/flags-quiz_m.jpg 800w, /static/uploads/quiz-covers/flags-quiz_l.jpg 1200w" sizes="80px" alt="Identify the Country by Its Flag" loading="lazy">
          
        </div>
        <div class="qd-related-info">
          <div class="qd-related-title">Identify the Country by Its Flag</div>
          <div class="qd-related-meta">27 plays</div>
        </div>
      </a>
      
      <a href="/quizzes/classic/how-black-are-you-quiz/" class="qd-related-item">
        <div class="qd-related-thumb">
          
          <img src="/static/uploads/quiz-covers/how-black-are-you-quiz.jpg" srcset="/static/uploads/quiz-covers/how-black-are-you-quiz_s.jpg 480w, /static/uploads/quiz-covers/how-black-are-you-quiz_m.jpg 800w, /static/uploads/quiz-covers/how-black-are-you-quiz_l.jpg 1200w" sizes="80px" alt="How Black Are You Quiz" loading="lazy">
          
        </div>
        <div class="qd-related-info">
          <div class="qd-related-title">How Black Are You Quiz</div>
          <div class="qd-related-meta">23 plays</div>
        </div>
      </a>
      
      <a href="/quizzes/multiple-choice/do-i-like-women-quiz/" class="qd-related-item">
        <div class="qd-related-thumb">
          
          <img src="/static/uploads/quiz-covers/do-i-like-women-quiz.jpg" srcset="/static/uploads/quiz-covers/do-i-like-women-quiz_s.jpg 480w, /static/uploads/quiz-covers/do-i-like-women-quiz_m.jpg 800w, /static/uploads/quiz-covers/do-i-like-women-quiz_l.jpg 1200w" sizes="80px" alt="Do I Like Women Quiz" loading="lazy">
          
        </div>
        <div class="qd-related-info">
          <div class="qd-related-title">Do I Like Women Quiz</div>
          <div class="qd-related-meta">20 plays</div>
        </div>
      </a>
      
    </div>
    

  </aside>
</div>

<style>
.qd-hero {
  position: relative;
  min-height: 400px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: #1a1a2e;
}
.qd-hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  transform: scale(1.05);
}
.qd-hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(6px) brightness(.45);
}
.qd-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(26,26,46,.85) 0%, rgba(245,161,0,.25) 100%);
}
.qd-hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 32px;
  align-items: center;
  padding-top: 40px;
  padding-bottom: 40px;
  flex-wrap: wrap;
}
.qd-hero-content { flex: 1; min-width: 280px; color: #fff; }
.qd-hero-title { font-size: 2rem; font-weight: 900; line-height: 1.2; margin: 10px 0; }
.qd-hero-desc { opacity: .95; font-size: 1.05rem; font-weight: 400; line-height: 1.65; margin-bottom: 14px; }
.breadcrumb-light, .breadcrumb-light a { color: rgba(255,255,255,.65); font-size: .82rem; }
.breadcrumb-light a:hover { color: #fff; }
.qd-badge-featured {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  padding: 2px 10px;
  border-radius: 20px;
  margin-bottom: 6px;
}
.qd-meta-row { display: flex; flex-wrap: wrap; gap: 8px; }
.qd-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255,255,255,.12);
  color: rgba(255,255,255,.85);
  border-radius: 20px;
  padding: 3px 10px;
  font-size: .8rem;
}
.qd-meta-cat { background: rgba(245,161,0,.25); color: #ffd166; }
.qd-meta-type { background: rgba(99,102,241,.3); color: #c7d2fe; text-decoration: none; }
.qd-meta-type:hover { background: rgba(99,102,241,.5); color: #fff; }
.qd-star { color: rgba(255,255,255,.3); }
.qd-star-on { color: #ffd166; }
.qd-difficulty { font-weight: 700; letter-spacing: .03em; }
.qd-difficulty-easy   { background: rgba(16,185,129,.25); color: #6ee7b7; }
.qd-difficulty-medium { background: rgba(245,161,0,.25);  color: #fcd34d; }
.qd-difficulty-hard   { background: rgba(239,68,68,.25);  color: #fca5a5; }
.qd-hero-cta {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.15);
  backdrop-filter: blur(8px);
  border-radius: 16px;
  padding: 24px;
  min-width: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  color: #fff;
}
.qd-best-score { text-align: center; }
.qd-best-val { font-size: 2.4rem; font-weight: 900; color: var(--primary); display: block; line-height: 1; }
.qd-best-lbl { font-size: .75rem; opacity: .7; text-transform: uppercase; letter-spacing: .06em; }
.qd-play-btn { width: 100%; justify-content: center; font-size: 1rem; }
.qd-cta-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.qd-action-btn { color: rgba(255,255,255,.75) !important; border-color: rgba(255,255,255,.35) !important; background: rgba(255,255,255,.08) !important; }
.qd-action-btn:hover { color: #fff !important; border-color: #fff !important; background: rgba(255,255,255,.22) !important; }
.qd-creator-row { font-size: .8rem; opacity: .65; }
.qd-creator-link { color: #fff !important; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.qd-creator-avatar { width: 20px; height: 20px; border-radius: 50%; object-fit: cover; }

/* Top play strip */
.qd-top-play-strip { background: #fff; border-bottom: 1px solid var(--gray-100); padding: 14px 0; }
.qd-top-play-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  background: var(--primary);
  color: #fff;
  font-size: 1.1rem;
  font-weight: 800;
  border-radius: 10px;
  padding: 16px 24px;
  text-decoration: none;
  transition: background .15s, transform .1s;
  letter-spacing: .01em;
}
.qd-top-play-btn:hover { background: #e08e00; transform: translateY(-1px); color: #fff; }

/* Layout */
.qd-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 24px;
  padding-top: 28px;
  padding-bottom: 60px;
  align-items: start;
}
@media(max-width:768px) { .qd-layout { grid-template-columns: 1fr; } }

/* Cards */
.qd-card {
  background: #fff;
  border: 1px solid var(--gray-100);
  border-radius: 12px;
  margin-bottom: 20px;
  overflow: hidden;
}
.qd-card-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 18px;
  font-size: .9rem;
  font-weight: 700;
  border-bottom: 1px solid var(--gray-100);
  background: var(--gray-50);
}
.qd-card-head-sub { color: var(--gray-400); font-weight: 400; font-size: .82rem; margin-left: 4px; }
.quiz-body-content { padding: 20px 22px; font-size: .95rem; line-height: 1.75; color: var(--gray-700); }
.quiz-body-content h2 { font-size: 1.15rem; font-weight: 700; margin: 20px 0 8px; color: var(--gray-800); }
.quiz-body-content p { margin: 0 0 14px; }
.quiz-body-content a { color: var(--primary); text-decoration: underline; }
.quiz-body-content ul { margin: 0 0 14px 20px; }
.quiz-body-content li { margin-bottom: 4px; }
.qd-card-head-actions { margin-left: auto; display: flex; gap: 8px; align-items: center; }

/* Playlist */
.qd-pl-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 18px;
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid var(--gray-50);
  transition: background .15s;
}
.qd-pl-item:hover { background: var(--gray-50); }
.qd-pl-item-active { background: #fff8ec; }
.qd-pl-num { font-size: .75rem; font-weight: 700; color: var(--gray-400); width: 18px; flex-shrink: 0; }
.qd-pl-thumb {
  width: 36px; height: 36px; border-radius: 6px;
  background: var(--gray-100); overflow: hidden; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.qd-pl-thumb img { width: 100%; height: 100%; object-fit: cover; }
.qd-pl-title { font-size: .85rem; font-weight: 600; line-height: 1.3; }
.qd-pl-meta { font-size: .75rem; color: var(--gray-500); }
.qd-pl-now {
  font-size: .65rem; background: var(--primary); color: #fff;
  border-radius: 4px; padding: 1px 6px; flex-shrink: 0; font-weight: 700;
}

/* Rating */
.qd-rating-card .star-rating { display: flex; gap: 6px; padding: 16px 18px; }
.star-btn { background: none; border: none; cursor: pointer; color: var(--gray-200); font-size: 1.6rem; padding: 0; transition: color .15s, transform .1s; }
.star-btn:hover, .star-btn.active { color: #fbbf24; transform: scale(1.15); }
.qd-rating-hint { font-size: .82rem; color: var(--gray-400); padding: 0 18px 16px; margin: 0; }

/* Comments */
.qd-comment-form { display: flex; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--gray-100); }
.qd-comment-input-wrap { flex: 1; }
.qd-comment-form-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; flex-wrap: wrap; gap: 8px; }
.qd-spoiler-check { display: flex; align-items: center; gap: 6px; font-size: .82rem; color: var(--gray-600); cursor: pointer; }
.qd-comment-form-actions { display: flex; align-items: center; gap: 10px; }
.qd-char-count { font-size: .78rem; color: var(--gray-400); }
.qd-login-prompt { padding: 14px 18px; font-size: .9rem; color: var(--gray-600); border-bottom: 1px solid var(--gray-100); }
.qd-comment { display: flex; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--gray-50); }
.qd-comment:last-child { border-bottom: none; }
.qd-comment-avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.qd-comment-body { flex: 1; min-width: 0; }
.qd-comment-header { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 5px; font-size: .88rem; }
.qd-comment-date { color: var(--gray-400); font-weight: 400; font-size: .78rem; }
.qd-comment-text { font-size: .9rem; color: var(--gray-700); margin: 0 0 8px; line-height: 1.6; }
.qd-comment-votes { display: flex; align-items: center; gap: 8px; }
.qd-vote-count { font-size: .8rem; color: var(--gray-400); }
.qd-no-comments { text-align: center; padding: 32px; color: var(--gray-400); font-size: .9rem; margin: 0; }

/* Vote buttons */
.vote-btn { background: none; border: 1px solid var(--gray-200); border-radius: 6px; padding: 2px 8px; font-size: .8rem; cursor: pointer; color: var(--gray-500); transition: all .15s; display: inline-flex; align-items: center; gap: 3px; }
.vote-btn:hover { border-color: var(--primary); color: var(--primary); }
.vote-btn.active-up { border-color: var(--success); color: var(--success); background: #ecfdf5; }
.vote-down-btn.active-down { border-color: var(--danger); color: var(--danger); background: #fef2f2; }

/* Spoiler */
.spoiler-warning { background: var(--gray-100); border: 1px solid var(--gray-300); border-radius: 8px; padding: 8px 14px; font-size: .85rem; color: var(--gray-600); cursor: pointer; user-select: none; display: inline-flex; align-items: center; gap: 6px; }
.spoiler-warning:hover { background: var(--gray-200); }

/* Share panel */
.qd-share-panel { width: 100%; border-top: 1px solid rgba(255,255,255,.12); padding-top: 12px; }
.qd-share-label { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; opacity: .55; margin-bottom: 8px; text-align: center; }
.qd-share-grid { display: flex; gap: 7px; justify-content: center; flex-wrap: wrap; margin-bottom: 8px; }
.qd-share-btn { width: 36px; height: 36px; border-radius: 8px; display: flex; align-items: center; justify-content: center; text-decoration: none; transition: opacity .15s, transform .1s; flex-shrink: 0; }
.qd-share-btn:hover { opacity: .82; transform: translateY(-2px); }
.qd-share-copy-btn { width: 100%; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.2); color: rgba(255,255,255,.85); border-radius: 8px; padding: 7px 12px; font-size: .82rem; cursor: pointer; transition: background .15s; display: flex; align-items: center; justify-content: center; gap: 6px; }
.qd-share-copy-btn:hover { background: rgba(255,255,255,.18); }

/* Play Now CTA */
.qd-play-now-cta { background: linear-gradient(135deg, #fff8ec 0%, #fff 100%); border: 2px solid var(--primary); border-radius: 12px; padding: 18px 22px; margin-bottom: 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.qd-pnc-title { font-weight: 700; font-size: 1rem; margin-bottom: 3px; color: var(--gray-800); }
.qd-pnc-sub { font-size: .83rem; color: var(--gray-500); }
.qd-pnc-btn { white-space: nowrap; }
@media(max-width:640px) { .qd-play-now-cta { flex-direction: column; text-align: center; } .qd-pnc-btn { width: 100%; justify-content: center; } }

.qd-explore-card { overflow: hidden; }
.qd-explore-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 18px 18px;
}
.qd-explore-links a {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 76px;
  padding: 13px 14px;
  border: 1px solid var(--gray-100);
  border-radius: 8px;
  background: #fff;
  color: inherit;
  text-decoration: none;
}
.qd-explore-links a:hover { border-color: var(--primary); background: #fffaf0; }
.qd-explore-links strong { color: var(--gray-900); font-size: .88rem; line-height: 1.3; }
.qd-explore-links span { color: var(--gray-500); font-size: .78rem; line-height: 1.4; }
@media(max-width:640px) {
  .qd-explore-links { grid-template-columns: 1fr; padding: 12px 14px 14px; gap: 8px; }
  .qd-explore-links a { min-height: 0; }
}

/* Mobile */
@media(max-width: 600px) {
  .qd-hero { min-height: auto; }
  .qd-hero-inner { padding: 18px 12px !important; gap: 14px; }
  .qd-hero-content { min-width: 0; }
  .qd-hero-title { font-size: 1.35rem; margin: 6px 0; }
  .qd-hero-desc { font-size: .93rem; margin-bottom: 10px; }
  .qd-hero-cta { min-width: 0; width: 100%; border-radius: 10px; padding: 14px 16px; gap: 10px; }
  .qd-best-val { font-size: 1.8rem; }
  .qd-share-btn { width: 40px; height: 40px; }
  .qd-layout { padding: 12px 12px 40px !important; }
  .qd-card { margin-bottom: 14px; border-radius: 10px; }
  .qd-play-now-cta { padding: 14px 16px; gap: 12px; margin-bottom: 14px; }
  .qd-comment-form { padding: 12px 14px; gap: 8px; }
  .qd-comment-avatar, .qd-comment-form > img { width: 28px; height: 28px; }
  .qd-comment { padding: 10px 14px; }
  .qd-card-head { padding: 12px 14px; font-size: .85rem; }
  .quiz-body-content { padding: 14px 16px; }
  .qd-meta-row { gap: 6px; }
  .qd-meta-chip { font-size: .75rem; padding: 2px 8px; }
}

/* Sidebar cards */
.qd-stats-card .qd-stat-row { display: flex; justify-content: space-between; padding: 10px 18px; border-bottom: 1px solid var(--gray-50); font-size: .88rem; }
.qd-stats-card .qd-stat-row span { color: var(--gray-500); }
.qd-stats-card .qd-stat-row:last-child { border-bottom: none; }
.qd-creator-profile { display: flex; align-items: center; gap: 12px; padding: 14px 18px; text-decoration: none; color: inherit; }
.qd-creator-profile-img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.qd-creator-name { font-weight: 700; font-size: .9rem; }
.qd-creator-sub { font-size: .78rem; color: var(--gray-500); }
.qd-related-item { display: flex; gap: 12px; align-items: center; padding: 10px 18px; text-decoration: none; color: inherit; border-bottom: 1px solid var(--gray-50); transition: background .15s; }
.qd-related-item:hover { background: var(--gray-50); }
.qd-related-item:last-child { border-bottom: none; }
.qd-related-thumb { width: 44px; height: 44px; border-radius: 8px; background: var(--gray-100); overflow: hidden; flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.qd-related-thumb img { width: 100%; height: 100%; object-fit: cover; }
.qd-related-title { font-size: .85rem; font-weight: 600; line-height: 1.3; }
.qd-related-meta { font-size: .75rem; color: var(--gray-500); }
</style>

<script>
let commentsHidden = false;

function updateCharCount(el) {
  const count = el.value.length;
  const span = document.getElementById('charCount');
  span.textContent = `${count.toLocaleString()} / 2,048`;
  span.style.color = count > 1900 ? 'var(--danger)' : 'var(--gray-400)';
}

function toggleComments() {
  commentsHidden = !commentsHidden;
  document.getElementById('commentsBody').style.display = commentsHidden ? 'none' : '';
  document.getElementById('toggleCommentsBtn').textContent = commentsHidden ? 'Show' : 'Hide';
}

function reloadComments() {
  const sort = document.getElementById('commentSort').value;
  const url = new URL(window.location.href);
  url.searchParams.set('comment_sort', sort);
  window.location.href = url.toString();
}

const IS_AUTH = false;

async function toggleSave(quizId, isSaved) {
  if (!IS_AUTH) {
    openAuthPrompt('Save this quiz', 'Create a free account to save quizzes and pick up where you left off.', '🔖', window.location.pathname);
    return;
  }
  const btn = document.getElementById('saveBtn');
  const lbl = document.getElementById('saveBtnLabel');
  const url = `/api/quiz/${quizId}/${isSaved ? 'unsave' : 'save'}`;
  btn.disabled = true;
  const res = await fetch(url, {method:'POST', headers:{'X-CSRFToken':getCSRF()}});
  btn.disabled = false;
  const data = await res.json();
  if (data.saved) {
    lbl.textContent = 'Saved';
    btn.setAttribute('onclick', `toggleSave(${quizId}, true)`);
  } else {
    lbl.textContent = 'Save';
    btn.setAttribute('onclick', `toggleSave(${quizId}, false)`);
  }
}

async function rateQuiz(val) {
  const stars = document.querySelectorAll('.star-btn');
  stars.forEach((s, i) => s.classList.toggle('active', i < val));
  const res = await fetch(`/api/quiz/573/rate`, {
    method:'POST',
    headers:{'Content-Type':'application/json','X-CSRFToken':getCSRF()},
    body: JSON.stringify({rating: val})
  });
  const data = await res.json();
  if (data.average) {
    document.getElementById('ratingHint').textContent = `Avg ${data.average}/5 from ${data.count} ratings`;
  }
}

async function postComment(quizId) {
  const bodyEl = document.getElementById('commentBody');
  const body = bodyEl.value.trim();
  if (!body) return;
  const has_spoilers = document.getElementById('spoilerCheck').checked;
  const res = await fetch('/api/comment', {
    method:'POST',
    headers:{'Content-Type':'application/json','X-CSRFToken':getCSRF()},
    body: JSON.stringify({body, quiz_id: quizId, has_spoilers})
  });
  const data = await res.json();
  if (data.id) {
    bodyEl.value = '';
    document.getElementById('charCount').textContent = '0 / 2,048';
    document.getElementById('spoilerCheck').checked = false;
    const list = document.getElementById('commentList');
    const noMsg = list.querySelector('.qd-no-comments');
    if (noMsg) noMsg.remove();

    const div = document.createElement('div');
    div.className = 'qd-comment';
    div.dataset.id = data.id;
    const spoilerBadge = data.has_spoilers ? `<span class="badge badge-gray">Spoiler</span>` : '';
    const bodyHtml = data.has_spoilers
      ? `<div class="spoiler-wrap"><div class="spoiler-warning" onclick="this.nextElementSibling.style.display='block';this.style.display='none'">Click to reveal spoiler</div><p class="qd-comment-text" style="display:none">${escHtml(data.body)}</p></div>`
      : `<p class="qd-comment-text">${escHtml(data.body)}</p>`;
    div.innerHTML = `
      <img src="${data.avatar}" alt="${escHtml(data.username)}" class="qd-comment-avatar">
      <div class="qd-comment-body">
        <div class="qd-comment-header">
          <strong>${escHtml(data.username)}</strong>
          <span class="qd-comment-date">just now</span>${spoilerBadge}
        </div>
        ${bodyHtml}
        <div class="qd-comment-votes">
          <button onclick="voteComment(${data.id}, 1, this)" class="vote-btn">▲ <span class="vote-up-count">0</span></button>
          <button onclick="voteComment(${data.id}, -1, this)" class="vote-btn vote-down-btn">▼ <span class="vote-down-count">0</span></button>
        </div>
      </div>`;

    const sort = document.getElementById('commentSort')?.value || 'newest';
    if (sort === 'newest') list.prepend(div); else list.appendChild(div);

    const badge = document.getElementById('commentCountBadge');
    badge.textContent = parseInt(badge.textContent || '0') + 1;
  }
}

async function voteComment(commentId, vote, btn) {
  const res = await fetch(`/api/comment/${commentId}/vote`, {
    method:'POST',
    headers:{'Content-Type':'application/json','X-CSRFToken':getCSRF()},
    body: JSON.stringify({vote})
  });
  const data = await res.json();
  if (data.upvotes === undefined) return;
  const item = btn.closest('.qd-comment');
  item.querySelector('.vote-up-count').textContent = data.upvotes;
  item.querySelector('.vote-down-count').textContent = data.downvotes;
  item.querySelector('.vote-btn:not(.vote-down-btn)').classList.toggle('active-up', data.user_vote === 1);
  item.querySelector('.vote-down-btn').classList.toggle('active-down', data.user_vote === -1);
}

let _reportQuizId = null;

function openReportModal(quizId) {
  if (!IS_AUTH) {
    openAuthPrompt('Sign in to report', 'You need an account to report quiz issues. It only takes a moment to sign up.', '🚩', window.location.pathname);
    return;
  }
  _reportQuizId = quizId;
  document.getElementById('reportReason').value = 'wrong_answer';
  document.getElementById('reportDetails').value = '';
  document.getElementById('reportMsg').textContent = '';
  const modal = document.getElementById('reportModal');
  modal.style.display = 'flex';
  document.body.style.overflow = 'hidden';
}

function closeReportModal() {
  document.getElementById('reportModal').style.display = 'none';
  document.body.style.overflow = '';
}

async function submitReport() {
  const reason = document.getElementById('reportReason').value;
  const details = document.getElementById('reportDetails').value.trim();
  const msg = document.getElementById('reportMsg');
  msg.style.color = 'var(--gray-500)';
  msg.textContent = 'Submitting…';
  try {
    const res = await fetch(`/api/quiz/${_reportQuizId}/report`, {
      method: 'POST',
      headers: {'Content-Type':'application/json','X-CSRFToken':getCSRF()},
      body: JSON.stringify({reason, details})
    });
    if (res.ok) {
      msg.style.color = '#16a34a';
      msg.textContent = '✅ Report submitted — thank you!';
      setTimeout(closeReportModal, 1800);
    } else {
      msg.style.color = 'var(--danger)';
      msg.textContent = 'Something went wrong. Try again.';
    }
  } catch {
    msg.style.color = 'var(--danger)';
    msg.textContent = 'Network error. Try again.';
  }
}

async function copyQuizLink(btn) {
  try {
    await navigator.clipboard.writeText(window.location.href);
    const orig = btn.innerHTML;
    btn.innerHTML = '<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5"><polyline points="20 6 9 17 4 12"/></svg> Copied!';
    btn.style.background = 'rgba(16,185,129,.35)';
    setTimeout(() => { btn.innerHTML = orig; btn.style.background = ''; }, 2200);
  } catch {
    prompt('Copy this link:', window.location.href);
  }
}

function getCSRF() {
  return document.querySelector('meta[name="csrf-token"]')?.content || '';
}

function openEmbedModal() {
  const typeSlug = "multiple-choice";
  const slug = "animal-trivia-quiz";
  const embedUrl = window.location.origin + '/quizzes/embed/' + typeSlug + '/' + slug;
  const code = `<iframe src="${embedUrl}" width="100%" height="540" frameborder="0" allow="fullscreen" style="border-radius:12px;border:1px solid #e5e7eb;max-width:640px"></iframe>`;
  document.getElementById('embedCode').value = code;
  document.getElementById('embedPreviewLink').href = embedUrl;
  document.getElementById('embedModal').style.display = 'flex';
}

function copyEmbed() {
  const ta = document.getElementById('embedCode');
  ta.select();
  navigator.clipboard.writeText(ta.value).catch(() => document.execCommand('copy'));
  const msg = document.getElementById('embedCopyMsg');
  msg.style.display = 'block';
  setTimeout(() => msg.style.display = 'none', 2500);
}

function escHtml(s) {
  return s.replace(/&/g,'&amp;').replace(/</g,'&lt;').replace(/>/g,'&gt;').replace(/"/g,'&quot;');
}

window.addEventListener('DOMContentLoaded', () => {
  const params = new URLSearchParams(window.location.search);
  const sort = params.get('comment_sort');
  if (sort) { const sel = document.getElementById('commentSort'); if (sel) sel.value = sort; }

  const enc = encodeURIComponent;
  const quizTitle = "Animal Trivia Quiz";
  const quizUrl = window.location.href;
  const wa = document.getElementById('share-wa');
  if (wa) wa.href = `https://wa.me/?text=${enc(quizTitle + ' ' + quizUrl)}`;
  const tg = document.getElementById('share-tg');
  if (tg) tg.href = `https://t.me/share/url?url=${enc(quizUrl)}&text=${enc(quizTitle)}`;
  const xb = document.getElementById('share-x');
  if (xb) xb.href = `https://twitter.com/intent/tweet?url=${enc(quizUrl)}&text=${enc(quizTitle)}`;
  const rd = document.getElementById('share-reddit');
  if (rd) rd.href = `https://reddit.com/submit?url=${enc(quizUrl)}&title=${enc(quizTitle)}`;
  const fb = document.getElementById('share-fb');
  if (fb) fb.href = `https://www.facebook.com/sharer/sharer.php?u=${enc(quizUrl)}`;
});

function shareInstagram(e) {
  e.preventDefault();
  const url = window.location.href;
  const isMobile = /Android|iPhone|iPad|iPod/i.test(navigator.userAgent);
  navigator.clipboard.writeText(url).catch(()=>{});
  if (isMobile) {
    window.location.href = 'instagram://';
    setTimeout(() => {
      const btn = document.getElementById('share-ig');
      if (btn) { btn.title = 'Link copied — paste in Instagram!'; }
    }, 400);
  } else {
    const btn = document.getElementById('share-ig');
    if (btn) {
      const orig = btn.title;
      btn.title = 'Link copied! Open Instagram and paste it.';
      setTimeout(() => { btn.title = orig; }, 2500);
    }
    const tip = document.createElement('div');
    tip.textContent = 'Link copied! Open Instagram and paste it.';
    tip.style.cssText = 'position:fixed;bottom:24px;left:50%;transform:translateX(-50%);background:#333;color:#fff;padding:10px 18px;border-radius:8px;font-size:.85rem;z-index:9999;pointer-events:none;';
    document.body.appendChild(tip);
    setTimeout(() => tip.remove(), 2800);
  }
}
</script>



  <footer class="footer">
  <div class="container">
    <div class="footer-grid">

      <!-- Brand -->
      <div class="footer-brand">
        <a href="/" class="footer-logo-wrap">
          <img src="/static/images/logo_icon_dark.svg" alt="DoQuizzes" class="footer-logo-img">
          <span class="footer-logo-text">Do<span>Quizzes</span></span>
        </a>
        <p>The free quiz and trivia platform. Play, create, and share quizzes on Sports, Geography, Music, History, Science, and thousands more topics.</p>
        <div class="footer-social">
          <a href="https://twitter.com/intent/tweet?url=https%3A//doquizzes.com/quizzes/multiple-choice/animal-trivia-quiz/&text=Check%20out%20DoQuizzes%20-%20free%20trivia%20and%20quiz%20games%21" target="_blank" rel="noopener" aria-label="Share on X" class="footer-social-btn" title="Share on X">
            <svg width="16" height="16" viewBox="0 0 24 24" fill="currentColor"><path d="M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-4.714-6.231-5.401 6.231H2.744l7.73-8.835L1.254 2.25H8.08l4.253 5.622 5.911-5.622zm-1.161 17.52h1.833L7.084 4.126H5.117z"/></svg>
          </a>
          <a href="https://www.facebook.com/sharer/sharer.php?u=https%3A//doquizzes.com/quizzes/multiple-choice/animal-trivia-quiz/" target="_blank" rel="noopener" aria-label="Share on Facebook" class="footer-social-btn" title="Share on Facebook">
            <svg width="16" height="16" viewBox="0 0 24 24" fill="currentColor"><path d="M24 12.073c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.99 4.388 10.954 10.125 11.854v-8.385H7.078v-3.47h3.047V9.43c0-3.007 1.792-4.669 4.533-4.669 1.312 0 2.686.235 2.686.235v2.953H15.83c-1.491 0-1.956.925-1.956 1.874v2.25h3.328l-.532 3.47h-2.796v8.385C19.612 23.027 24 18.062 24 12.073z"/></svg>
          </a>
          <a href="https://reddit.com/submit?url=https%3A//doquizzes.com/quizzes/multiple-choice/animal-trivia-quiz/&title=DoQuizzes%20-%20Free%20Trivia%20and%20Quiz%20Games" target="_blank" rel="noopener" aria-label="Share on Reddit" class="footer-social-btn" title="Share on Reddit">
            <svg width="16" height="16" viewBox="0 0 24 24" fill="currentColor"><path d="M12 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0zm5.01 4.744c.688 0 1.25.561 1.25 1.249a1.25 1.25 0 0 1-2.498.056l-2.597-.547-.8 3.747c1.824.07 3.48.632 4.674 1.488.308-.309.73-.491 1.207-.491.968 0 1.754.786 1.754 1.754 0 .716-.435 1.333-1.01 1.614a3.111 3.111 0 0 1 .042.52c0 2.694-3.13 4.87-7.004 4.87-3.874 0-7.004-2.176-7.004-4.87 0-.183.015-.366.043-.534A1.748 1.748 0 0 1 4.028 12c0-.968.786-1.754 1.754-1.754.463 0 .898.196 1.207.49 1.207-.883 2.878-1.43 4.744-1.487l.885-4.182a.342.342 0 0 1 .14-.197.35.35 0 0 1 .238-.042l2.906.617a1.214 1.214 0 0 1 1.108-.701zM9.25 12C8.561 12 8 12.562 8 13.25c0 .687.561 1.248 1.25 1.248.687 0 1.248-.561 1.248-1.249 0-.688-.561-1.249-1.249-1.249zm5.5 0c-.687 0-1.248.561-1.248 1.25 0 .687.561 1.248 1.249 1.248.688 0 1.249-.561 1.249-1.249 0-.687-.562-1.249-1.25-1.249zm-5.466 3.99a.327.327 0 0 0-.231.094.33.33 0 0 0 0 .463c.842.842 2.484.913 2.961.913.477 0 2.105-.056 2.961-.913a.361.361 0 0 0 .029-.463.33.33 0 0 0-.464 0c-.547.533-1.684.73-2.512.73-.828 0-1.979-.196-2.512-.73a.326.326 0 0 0-.232-.095z"/></svg>
          </a>
        </div>
      </div>

      <!-- Play -->
      <div class="footer-col">
        <div class="footer-heading">Quiz Types</div>
        <a href="/quizzes/classic/">Classic Quizzes</a>
        <a href="/quizzes/multiple-choice/">Multiple Choice</a>
        <a href="/quizzes/map/">Map Quizzes</a>
        <a href="/quizzes/picture/">Picture Quizzes</a>
        <a href="/quizzes/slideshow/">Slideshow Quizzes</a>
        <a href="/quizzes/table/">Table Quizzes</a>
        <a href="/quizzes/type/">All Formats →</a>
      </div>

      <!-- Categories -->
      <div class="footer-col">
        <div class="footer-heading">Categories</div>
        
        <a href="/quizzes/category/sports/">Sports</a>
        
        <a href="/quizzes/category/geography/">Geography</a>
        
        <a href="/quizzes/category/music/">Music</a>
        
        <a href="/quizzes/category/movies/">Movies</a>
        
        <a href="/quizzes/category/television/">Television</a>
        
        <a href="/quizzes/category/just-for-fun/">Just For Fun</a>
        
        <a href="/quizzes/category/miscellaneous/">Miscellaneous</a>
        
        <a href="/quizzes/categories/">All Categories →</a>
      </div>

      <!-- Explore -->
      <div class="footer-col">
        <div class="footer-heading">Explore</div>
        <a href="/quizzes/">All Quizzes</a>
        <a href="/quizzes/popular/">Most Popular</a>
        <a href="/quizzes/new/">Discover Quizzes</a>
        <a href="/quizzes/trending/">Trending Today</a>
        <a href="/quizzes/random/" rel="nofollow">Random Quiz</a>
        <a href="/leaderboards/">Leaderboards</a>
        <a href="/multiplayer/">Multiplayer</a>
        <a href="/jeopardy/">Jeopardy Quiz</a>
        <a href="/flashcards/">Flashcard Generator</a>
      </div>

      <!-- Company -->
      <div class="footer-col">
        <div class="footer-heading">Company</div>
        <a href="/about/">About Us</a>
        <a href="/blog/">Blog</a>
        <a href="/quiz-maker/">AI Quiz Maker</a>
        <a href="/jeopardy/create/">Create Jeopardy Game</a>
        <a href="/help/">Help Center</a>
        <a href="/help/how-to-revise-effectively/">How to Revise</a>
        <a href="/help/how-to-play-jeopardy/">How to Play Jeopardy</a>
        <a href="/contact/">Contact</a>
        <a href="/achievements/">Achievements</a>
      </div>

      <!-- Partner Sites -->
      <div class="footer-col">
        <div class="footer-heading">Partner Sites</div>
        <a href="https://have.you" target="_blank" rel="noopener nofollow">Have You Ever</a>
        <a href="https://typingtest.now" target="_blank" rel="noopener nofollow">Typing Test</a>
        <a href="https://humanbenchmark.now" target="_blank" rel="noopener nofollow">Human Benchmark</a>
        <a href="https://minesweeper.now" target="_blank" rel="noopener nofollow">Minesweeper</a>
        <a href="https://2048.now" target="_blank" rel="noopener nofollow">2048 Game</a>
        <a href="https://sudoku.by" target="_blank" rel="noopener nofollow">Sudoku</a>
      </div>

    </div>

    <div class="footer-bottom">
      <span>© 2026 DoQuizzes.com — Play, Learn, Compete</span>
      <div class="footer-bottom-links">
        <a href="/privacy/">Privacy Policy</a>
        <a href="/terms/">Terms of Service</a>
        <a href="/dmca/">DMCA</a>
      </div>
    </div>
  </div>
</footer>

  <!-- Mobile Drawer -->
  <div class="mobile-drawer" id="mobileDrawer">
    <div class="drawer-overlay" onclick="closeMobileMenu()"></div>
    <div class="drawer-panel">
      <div class="drawer-header">
        <a href="/" class="nav-logo" onclick="closeMobileMenu()">Do<span>Quizzes</span></a>
        <button class="drawer-close" onclick="closeMobileMenu()">✕</button>
      </div>
      <div class="drawer-section">
        <form action="/search/" method="get">
          <input type="text" name="q" class="form-control" placeholder="Search quizzes...">
        </form>
      </div>
      <div class="drawer-section">
        <div class="drawer-section-heading">Categories</div>
        
        <a href="/quizzes/category/sports/" class="drawer-link">⚽ Sports</a>
        
        <a href="/quizzes/category/geography/" class="drawer-link">🌍 Geography</a>
        
        <a href="/quizzes/category/music/" class="drawer-link">🎵 Music</a>
        
        <a href="/quizzes/category/movies/" class="drawer-link">🎬 Movies</a>
        
        <a href="/quizzes/category/television/" class="drawer-link">📺 Television</a>
        
        <a href="/quizzes/category/just-for-fun/" class="drawer-link">😄 Just For Fun</a>
        
        <a href="/quizzes/category/miscellaneous/" class="drawer-link">🎲 Miscellaneous</a>
        
        <a href="/quizzes/category/history/" class="drawer-link">📜 History</a>
        
        <a href="/quizzes/category/literature/" class="drawer-link">📚 Literature</a>
        
        <a href="/quizzes/category/language/" class="drawer-link">🗣️ Language</a>
        
        <a href="/quizzes/category/science/" class="drawer-link">🔬 Science</a>
        
        <a href="/quizzes/category/gaming/" class="drawer-link">🎮 Gaming</a>
        
        <a href="/quizzes/category/entertainment/" class="drawer-link">🎭 Entertainment</a>
        
        <a href="/quizzes/category/religion/" class="drawer-link">🕊️ Religion</a>
        
        <a href="/quizzes/category/holiday/" class="drawer-link">🎉 Holiday</a>
        
      </div>
      <div class="drawer-section">
        <div class="drawer-section-heading">Quick Links</div>
        <a href="/quizzes/trending/" class="drawer-link">🔥 Trending Today</a>
        <a href="/quizzes/popular/" class="drawer-link">⭐ Most Popular</a>
        <a href="/quizzes/random/" class="drawer-link" rel="nofollow">🎲 Random Quiz</a>
        <a href="/multiplayer/" class="drawer-link">🎮 Multiplayer</a>
        <a href="/quiz-maker/" class="drawer-link">✏️ Create a Quiz</a>
        <a href="/blog/" class="drawer-link">📝 Blog</a>
      </div>
      
      <div class="drawer-section" style="display:flex;gap:10px;flex-direction:column">
        <a href="/auth/login/" class="btn btn-outline btn-block">Log In</a>
        <a href="/auth/register/" class="btn btn-primary btn-block">Sign Up Free</a>
      </div>
      
    </div>
  </div>

  <!-- ── Auth Prompt Modal ── -->
  <div id="authPromptModal" style="display:none;position:fixed;inset:0;background:rgba(0,0,0,.5);z-index:10000;align-items:center;justify-content:center" onclick="if(event.target===this)closeAuthPrompt()">
    <div style="background:#fff;border-radius:20px;padding:32px 28px;max-width:420px;width:92%;position:relative;text-align:center;box-shadow:0 20px 60px rgba(0,0,0,.18)">
      <button onclick="closeAuthPrompt()" style="position:absolute;top:14px;right:16px;background:none;border:none;font-size:1.4rem;cursor:pointer;color:var(--gray-400);line-height:1">×</button>
      <div id="authPromptIcon" style="font-size:2.2rem;margin-bottom:12px">🔐</div>
      <div id="authPromptTitle" class="modal-title-text" style="font-size:1.25rem;font-weight:900;color:var(--gray-900);margin-bottom:8px">Sign in to continue</div>
      <p id="authPromptMsg" style="font-size:.9rem;color:var(--gray-500);margin-bottom:24px;line-height:1.5">Create a free account to access this feature.</p>
      <div style="display:flex;flex-direction:column;gap:10px">
        <a id="authPromptSignup" href="/auth/register/" class="btn btn-primary btn-block" style="font-size:.95rem;padding:12px">Sign Up Free</a>
        <a id="authPromptLogin" href="/auth/login/" class="btn btn-ghost btn-block" style="font-size:.9rem">Already have an account? Sign In</a>
      </div>
    </div>
  </div>

  <!-- ── Premium Upgrade Modal ── -->
  <div id="premiumModal" style="display:none;position:fixed;inset:0;background:rgba(0,0,0,.6);z-index:10001;align-items:center;justify-content:center;padding:16px" onclick="if(event.target===this)closePremiumModal()">
    <div style="background:#fff;border-radius:20px;max-width:480px;width:100%;position:relative;overflow:hidden;box-shadow:0 24px 80px rgba(0,0,0,.25)">
      <!-- Header -->
      <div style="background:linear-gradient(135deg,#111827,#1f2937);padding:28px 28px 24px;text-align:center;position:relative">
        <button onclick="closePremiumModal()" style="position:absolute;top:14px;right:16px;background:rgba(255,255,255,.1);border:none;border-radius:50%;width:30px;height:30px;font-size:1.1rem;cursor:pointer;color:#fff;display:flex;align-items:center;justify-content:center;line-height:1">×</button>
        <div style="width:52px;height:52px;background:rgba(245,161,0,.2);border-radius:50%;display:flex;align-items:center;justify-content:center;margin:0 auto 14px">
          <svg width="26" height="26" viewBox="0 0 24 24" fill="#f5a100"><path d="M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z"/></svg>
        </div>
        <div class="modal-title-text" style="color:#fff;font-size:1.4rem;font-weight:900;margin:0 0 6px">Upgrade to Premium</div>
        <p id="pmModalReason" style="color:rgba(255,255,255,.6);font-size:.88rem;margin:0;line-height:1.5">Unlock unlimited AI quizzes, more flashcard sets, and bigger multiplayer rooms.</p>
      </div>
      <!-- Body -->
      <div style="padding:24px 28px">
        <!-- Billing toggle -->
        <div style="display:flex;background:#f3f4f6;border-radius:10px;padding:3px;margin-bottom:20px">
          <button id="pmBtnMonthly" onclick="pmSetBilling('monthly')" style="flex:1;padding:8px;border:none;border-radius:8px;font-size:.85rem;font-weight:700;cursor:pointer;background:transparent;color:#6b7280;transition:all .15s">Monthly</button>
          <button id="pmBtnYearly" onclick="pmSetBilling('yearly')" style="flex:1;padding:8px;border:none;border-radius:8px;font-size:.85rem;font-weight:700;cursor:pointer;background:#f5a100;color:#fff;transition:all .15s">Yearly <span style="font-size:.72rem;opacity:.85">Save 17%</span></button>
        </div>
        <!-- Price -->
        <div style="text-align:center;margin-bottom:16px">
          <div style="display:flex;align-items:baseline;justify-content:center;gap:3px">
            <span style="font-size:2.6rem;font-weight:900;color:#111827" id="pmPrice">$4.17</span>
            <span style="font-size:.95rem;color:#9ca3af;font-weight:600">/mo</span>
          </div>
          <div id="pmBilled" style="font-size:.8rem;color:#9ca3af;margin-top:2px">Billed $49.99/year &mdash; Best value</div>
        </div>
        <!-- Features -->
        <ul style="list-style:none;padding:0;margin:0 0 20px;display:flex;flex-direction:column;gap:8px">
          <li style="display:flex;align-items:center;gap:10px;font-size:.875rem;color:#374151"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#f5a100" stroke-width="2.5"><polyline points="20 6 9 17 4 12"/></svg>15 AI quizzes per day (vs 1 free)</li>
          <li style="display:flex;align-items:center;gap:10px;font-size:.875rem;color:#374151"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#f5a100" stroke-width="2.5"><polyline points="20 6 9 17 4 12"/></svg>15 flashcard sets per day (vs 3 free)</li>
          <li style="display:flex;align-items:center;gap:10px;font-size:.875rem;color:#374151"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#f5a100" stroke-width="2.5"><polyline points="20 6 9 17 4 12"/></svg>Up to 20 players in multiplayer rooms</li>
          <li style="display:flex;align-items:center;gap:10px;font-size:.875rem;color:#374151"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#f5a100" stroke-width="2.5"><polyline points="20 6 9 17 4 12"/></svg>5 hints per quiz (vs 1 free)</li>
          <li style="display:flex;align-items:center;gap:10px;font-size:.875rem;color:#374151"><svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="#f5a100" stroke-width="2.5"><polyline points="20 6 9 17 4 12"/></svg>Ad-free experience</li>
        </ul>
        <!-- CTA -->
        
        <form method="POST" action="/premium/guest-checkout/">
          <input type="hidden" name="plan" id="pmPlanGuest" value="yearly">
          <button type="submit" style="width:100%;padding:14px;background:#f5a100;color:#fff;border:none;border-radius:11px;font-size:1rem;font-weight:800;cursor:pointer;transition:background .15s" onmouseover="this.style.background='#e09000'" onmouseout="this.style.background='#f5a100'">
            Get Premium &rarr;
          </button>
        </form>
        <p style="text-align:center;font-size:.78rem;color:#9ca3af;margin-top:10px">No account needed &mdash; we&apos;ll email you a code</p>
        
        <p style="text-align:center;font-size:.75rem;color:#d1d5db;margin-top:12px">Cancel any time &bull; Secure checkout via Stripe</p>
      </div>
    </div>
  </div>

  <!-- ── Feedback Modal ── -->
  <div id="feedbackBackdrop" style="display:none;position:fixed;inset:0;background:rgba(0,0,0,.45);z-index:9999;align-items:center;justify-content:center">
    <div style="background:#fff;border-radius:16px;padding:28px 32px;max-width:460px;width:90%;position:relative">
      <button onclick="closeFeedback()" style="position:absolute;top:14px;right:16px;background:none;border:none;font-size:1.4rem;cursor:pointer;color:var(--gray-400)">×</button>
      <div class="modal-title-text" style="font-size:1.2rem;font-weight:800;margin-bottom:6px">💬 Send Feedback</div>
      <p style="font-size:.85rem;color:var(--gray-500);margin-bottom:18px">Found a bug? Have a suggestion? Let us know.</p>
      
      <div style="text-align:center;padding:20px 0">
        <p style="color:var(--gray-600);margin-bottom:16px">You need to be signed in to send feedback.</p>
        <a href="/auth/login/" class="btn btn-primary">Sign In</a>
        <a href="/auth/register/" class="btn btn-outline" style="margin-left:8px">Sign Up Free</a>
      </div>
      
    </div>
  </div>

  <script>
    function openMobileMenu() { document.getElementById('mobileDrawer').classList.add('open'); document.body.style.overflow='hidden'; }
    function closeMobileMenu() { document.getElementById('mobileDrawer').classList.remove('open'); document.body.style.overflow=''; }
    // Flash close
    document.querySelectorAll('.alert-close').forEach(btn => btn.addEventListener('click', () => btn.closest('.alert').remove()));

    function openFeedback() {
      const el = document.getElementById('feedbackBackdrop');
      el.style.display = 'flex';
      document.body.style.overflow = 'hidden';
    }
    function closeFeedback() {
      document.getElementById('feedbackBackdrop').style.display = 'none';
      document.body.style.overflow = '';
      const msg = document.getElementById('feedbackMsg');
      if (msg) msg.textContent = '';
    }
    async function submitFeedback(e) {
      e.preventDefault();
      const text = document.getElementById('feedbackText').value.trim();
      const type = document.getElementById('feedbackType').value;
      const msg  = document.getElementById('feedbackMsg');
      if (!text) { msg.style.color = 'var(--danger)'; msg.textContent = 'Please enter your feedback.'; return; }
      msg.style.color = 'var(--gray-500)'; msg.textContent = 'Sending…';
      try {
        const res = await fetch('/feedback/', {
          method: 'POST',
          headers: {'Content-Type':'application/json','X-CSRFToken': document.querySelector('meta[name="csrf-token"]')?.content || document.cookie.split('; ').find(r => r.startsWith('csrf_token='))?.split('=')[1] || ''},
          body: JSON.stringify({type, text, page: window.location.pathname})
        });
        if (res.ok) {
          msg.style.color = '#16a34a'; msg.textContent = '✅ Thank you! Feedback received.';
          document.getElementById('feedbackText').value = '';
          setTimeout(closeFeedback, 1800);
        } else { msg.style.color = 'var(--danger)'; msg.textContent = 'Something went wrong. Try again.'; }
      } catch { msg.style.color = 'var(--danger)'; msg.textContent = 'Network error. Try again.'; }
    }
    document.getElementById('feedbackBackdrop').addEventListener('click', function(e) {
      if (e.target === this) closeFeedback();
    });

    function openPremiumModal(reason) {
      const el = document.getElementById('premiumModal');
      if (reason) document.getElementById('pmModalReason').textContent = reason;
      el.style.display = 'flex';
      document.body.style.overflow = 'hidden';
    }
    function closePremiumModal() {
      document.getElementById('premiumModal').style.display = 'none';
      document.body.style.overflow = '';
    }
    function pmSetBilling(mode) {
      const isYearly = mode === 'yearly';
      document.getElementById('pmBtnYearly').style.cssText = 'flex:1;padding:8px;border:none;border-radius:8px;font-size:.85rem;font-weight:700;cursor:pointer;transition:all .15s;background:' + (isYearly ? '#f5a100' : 'transparent') + ';color:' + (isYearly ? '#fff' : '#6b7280');
      document.getElementById('pmBtnMonthly').style.cssText = 'flex:1;padding:8px;border:none;border-radius:8px;font-size:.85rem;font-weight:700;cursor:pointer;transition:all .15s;background:' + (!isYearly ? '#f5a100' : 'transparent') + ';color:' + (!isYearly ? '#fff' : '#6b7280');
      document.getElementById('pmPrice').textContent = isYearly ? '$4.17' : '$4.99';
      document.getElementById('pmBilled').textContent = isYearly ? 'Billed $49.99/year — Best value' : 'Billed monthly — Cancel any time';
      const planAuth = document.getElementById('pmPlanAuth');
      if (planAuth) planAuth.value = mode;
      const planGuest = document.getElementById('pmPlanGuest');
      if (planGuest) planGuest.value = mode;
    }

    function openAuthPrompt(title, msg, icon, next) {
      document.getElementById('authPromptTitle').textContent = title || 'Sign in to continue';
      document.getElementById('authPromptMsg').textContent = msg || 'Create a free account to access this feature.';
      document.getElementById('authPromptIcon').textContent = icon || '🔐';
      const nextParam = next ? '?next=' + encodeURIComponent(next) : '';
      document.getElementById('authPromptSignup').href = '/auth/register/' + nextParam;
      document.getElementById('authPromptLogin').href = '/auth/login/' + nextParam;
      const modal = document.getElementById('authPromptModal');
      modal.style.display = 'flex';
      document.body.style.overflow = 'hidden';
    }
    function closeAuthPrompt() {
      document.getElementById('authPromptModal').style.display = 'none';
      document.body.style.overflow = '';
    }
  </script>
  
  <script>
  (function(){
    var sel='.fq-thumb,.cc-thumb,.qc-thumb,.qt-item-thumb';
    document.querySelectorAll(sel).forEach(function(el){
      var img=el.querySelector('img');
      if(!img)return;
      el.classList.add('img-sk');
      function done(){el.classList.remove('img-sk');}
      if(img.complete)done();
      else{img.addEventListener('load',done);img.addEventListener('error',done);}
    });
  })();
  </script>

  <!-- Mobile Bottom Navigation -->
  <nav class="mob-bottom-nav" aria-label="Mobile navigation">
    <a href="/" class="mob-nav-item">
      <svg class="icon"><use href="#icon-home"/></svg>
      <span>Home</span>
    </a>
    <a href="/search/" class="mob-nav-item">
      <svg class="icon"><use href="#icon-search"/></svg>
      <span>Search</span>
    </a>
    <a href="/quizzes/random/" class="mob-nav-item mob-nav-play" rel="nofollow">
      <svg class="icon"><use href="#icon-play"/></svg>
      <span>Play</span>
    </a>
    <a href="/leaderboards/" class="mob-nav-item">
      <svg class="icon"><use href="#icon-trophy"/></svg>
      <span>Top</span>
    </a>
    
    <a href="/auth/login/" class="mob-nav-item">
      <svg class="icon"><use href="#icon-profile"/></svg>
      <span>Sign In</span>
    </a>
    
  </nav>
<script>
(function(){
  var nav = document.querySelector('.mob-bottom-nav');
  if (!nav) return;
  nav.style.bottom = '0';
  document.body.style.paddingBottom = '';
})();
</script>
</body>
</html>