:root {
  --background: #f6e6ee;
  --foreground: #5b5b5b;
  --card: #fdedc9;
  --card-foreground: #5b5b5b;
  --popover: #ffffff;
  --popover-foreground: #5b5b5b;
  --primary: #d04f99;
  --primary-foreground: #ffffff;
  --secondary: #8acfd1;
  --secondary-foreground: #333333;
  --muted: #b2e1eb;
  --muted-foreground: #7a7a7a;
  --accent: #fbe2a7;
  --accent-foreground: #333333;
  --destructive: #f96f70;
  --destructive-foreground: #ffffff;
  --border: #d04f99;
  --input: #e4e4e4;
  --ring: #e670ab;
  --chart-1: #e670ab;
  --chart-2: #84d2e2;
  --chart-3: #fbe2a7;
  --chart-4: #f3a0ca;
  --chart-5: #d7488e;
  --sidebar: #f8d8ea;
  --sidebar-foreground: #333333;
  --sidebar-primary: #ec4899;
  --sidebar-primary-foreground: #ffffff;
  --sidebar-accent: #f9a8d4;
  --sidebar-accent-foreground: #333333;
  --sidebar-border: #f3e8ff;
  --sidebar-ring: #ec4899;
  --font-sans: Poppins, sans-serif;
  --font-serif: Lora, serif;
  --font-mono: Fira Code, monospace;
  --radius: 0.4rem;
  --shadow-2xs: 3px 3px 0px 0px hsl(325.7800 58.1800% 56.8600% / 0.50);
  --shadow-xs: 3px 3px 0px 0px hsl(325.7800 58.1800% 56.8600% / 0.50);
  --shadow-sm: 3px 3px 0px 0px hsl(325.7800 58.1800% 56.8600% / 1.00), 3px 1px 2px -1px hsl(325.7800 58.1800% 56.8600% / 1.00);
  --shadow: 3px 3px 0px 0px hsl(325.7800 58.1800% 56.8600% / 1.00), 3px 1px 2px -1px hsl(325.7800 58.1800% 56.8600% / 1.00);
  --shadow-md: 3px 3px 0px 0px hsl(325.7800 58.1800% 56.8600% / 1.00), 3px 2px 4px -1px hsl(325.7800 58.1800% 56.8600% / 1.00);
  --shadow-lg: 3px 3px 0px 0px hsl(325.7800 58.1800% 56.8600% / 1.00), 3px 4px 6px -1px hsl(325.7800 58.1800% 56.8600% / 1.00);
  --shadow-xl: 3px 3px 0px 0px hsl(325.7800 58.1800% 56.8600% / 1.00), 3px 8px 10px -1px hsl(325.7800 58.1800% 56.8600% / 1.00);
  --shadow-2xl: 3px 3px 0px 0px hsl(325.7800 58.1800% 56.8600% / 2.50);
  --tracking-normal: 0em;
  --spacing: 0.25rem;

  --radius-sm: calc(var(--radius) - 4px);
  --radius-md: calc(var(--radius) - 2px);
  --radius-lg: var(--radius);
  --radius-xl: calc(var(--radius) + 4px);
}

body.dark-mode {
  --background: #12242e;
  --foreground: #f3e3ea;
  --card: #1c2e38;
  --card-foreground: #f3e3ea;
  --popover: #1c2e38;
  --popover-foreground: #f3e3ea;
  --primary: #fbe2a7;
  --primary-foreground: #12242e;
  --secondary: #e4a2b1;
  --secondary-foreground: #12242e;
  --muted: #24272b;
  --muted-foreground: #e4a2b1;
  --accent: #c67b96;
  --accent-foreground: #f3e3ea;
  --destructive: #e35ea4;
  --destructive-foreground: #12242e;
  --border: #324859;
  --input: #20333d;
  --ring: #50afb6;
  --chart-1: #50afb6;
  --chart-2: #e4a2b1;
  --chart-3: #c67b96;
  --chart-4: #175c6c;
  --chart-5: #24272b;
  --sidebar: #101f28;
  --sidebar-foreground: #f3f4f6;
  --sidebar-primary: #ec4899;
  --sidebar-primary-foreground: #ffffff;
  --sidebar-accent: #f9a8d4;
  --sidebar-accent-foreground: #1f2937;
  --sidebar-border: #374151;
  --sidebar-ring: #ec4899;
  --shadow-2xs: 3px 3px 0px 0px hsl(206.1538 28.0576% 27.2549% / 0.50);
  --shadow-xs: 3px 3px 0px 0px hsl(206.1538 28.0576% 27.2549% / 0.50);
  --shadow-sm: 3px 3px 0px 0px hsl(206.1538 28.0576% 27.2549% / 1.00), 3px 1px 2px -1px hsl(206.1538 28.0576% 27.2549% / 1.00);
  --shadow: 3px 3px 0px 0px hsl(206.1538 28.0576% 27.2549% / 1.00), 3px 1px 2px -1px hsl(206.1538 28.0576% 27.2549% / 1.00);
  --shadow-md: 3px 3px 0px 0px hsl(206.1538 28.0576% 27.2549% / 1.00), 3px 2px 4px -1px hsl(206.1538 28.0576% 27.2549% / 1.00);
  --shadow-lg: 3px 3px 0px 0px hsl(206.1538 28.0576% 27.2549% / 1.00), 3px 4px 6px -1px hsl(206.1538 28.0576% 27.2549% / 1.00);
  --shadow-xl: 3px 3px 0px 0px hsl(206.1538 28.0576% 27.2549% / 1.00), 3px 8px 10px -1px hsl(206.1538 28.0576% 27.2549% / 1.00);
  --shadow-2xl: 3px 3px 0px 0px hsl(206.1538 28.0576% 27.2549% / 2.50);
}

body {
    font-family: var(--font-sans);
    margin: 0;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    text-align: center;
    transition: background-color 0.3s, color 0.3s;
    background-color: var(--background);
    color: var(--foreground);
}

.theme-toggle-container {
    position: absolute;
    top: 1rem;
    right: 1rem;
}

.theme-switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--accent);
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
}

input:checked + .slider {
    background-color: var(--primary);
}

input:focus + .slider {
    box-shadow: 0 0 1px var(--primary);
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}

#welcome-container h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--primary);
}

#welcome-container p {
    font-size: 1.2rem;
    line-height: 1.6;
    max-width: 600px;
    margin-bottom: 2rem;
    margin-left: auto;
    margin-right: auto;
}

#start-btn {
    border: none;
    padding: 1rem 2rem;
    font-size: 1.2rem;
    font-weight: bold;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s;
    box-shadow: var(--shadow-md);
    background-color: var(--secondary);
    color: var(--secondary-foreground);
}

#start-btn:hover {
    transform: translateY(-2px);
}

#quiz-container {
    width: 100%;
    max-width: 600px;
    border-radius: var(--radius-xl);
    padding: 2rem;
    box-shadow: var(--shadow-md);
    transition: background-color 0.3s;
    background-color: var(--card);
    color: var(--card-foreground);
    position: relative;
}

#question-container {
    margin-bottom: 2rem;
}

#progress-text {
    position: fixed;
    top: 2rem;
    left: 2rem;
    font-size: 0.9rem;
    color: var(--muted-foreground);
    z-index: 1000;
}

.fake-post {
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    text-align: left;
    border: 1px solid var(--border);
    background-color: var(--muted);
}

.post-header {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 1rem;
    font-size: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.username {
    font-weight: bold;
}

.post-body {
    font-size: 1.1rem;
    line-height: 1.5;
}

#options-container {
    display: grid;
    gap: 1rem;
}

.option-btn {
    display: block;
    width: 100%;
    padding: 1rem;
    font-size: 1rem;
    text-align: left;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    background-color: var(--muted);
    color: var(--muted-foreground);
}

.option-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    background-color: var(--accent);
    color: var(--accent-foreground);
}

.option-btn.correct {
    color: var(--secondary-foreground);
    background-color: var(--secondary);
    border-color: var(--secondary);
}

.option-btn.incorrect {
    color: var(--destructive-foreground);
    animation: shake 0.3s;
    background-color: var(--destructive);
    border-color: var(--destructive);
}

.option-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

@keyframes shake {
    0% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    50% { transform: translateX(5px); }
    75% { transform: translateX(-5px); }
    100% { transform: translateX(0); }
}

#feedback-container {
    margin-top: 2rem;
    padding: 1.5rem;
    border-radius: var(--radius-xl);
    display: none; /* Hidden by default */
    text-align: left;
    border: 1px solid var(--border);
}

#feedback-container.correct {
    background-color: var(--card);
    border-color: var(--secondary);
}

#fallacy-name {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

#fallacy-description {
    font-size: 1rem;
    line-height: 1.6;
}

#fallacy-examples {
    margin-top: 1.5rem;
}

#fallacy-examples h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

#fallacy-examples ul {
    list-style-type: none;
    padding-left: 0;
}

#fallacy-examples li {
    padding: 0.75rem;
    border-radius: var(--radius-md);
    margin-bottom: 0.5rem;
    font-style: italic;
    background-color: var(--muted);
}

#next-btn {
    width: 100%;
    padding: 1rem;
    font-size: 1.1rem;
    font-weight: bold;
    border: none;
    border-radius: var(--radius-lg);
    cursor: pointer;
    margin-top: 2rem;
    transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s;
    box-shadow: var(--shadow-md);
    background-color: var(--primary);
    color: var(--primary-foreground);
}

#next-btn:hover {
    transform: translateY(-2px);
}

#donation-footer {
    margin-top: 2rem;
    text-align: center;
}

#donation-footer img {
    max-width: 150px;
    margin-bottom: 1rem;
}

#donation-footer p {
    font-size: 0.9rem;
    word-break: break-all;
}

#start-btn:active,
.option-btn:active:not(:disabled),
#next-btn:active {
    transform: scale(0.98);
}

/* Styles for the new quiz complete card */
.quiz-complete-card {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background-color: var(--background); /* blueShades.midnight */
    position: absolute; /* Position over the quiz container */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10; /* Ensure it's on top */
    flex-direction: column; /* To center content vertically */
}

.quiz-complete-card .card-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.quiz-complete-card .award-icon {
    font-size: 5rem; /* Equivalent to w-20 h-20 */
    margin: 0 auto 1rem; /* mx-auto mb-4 */
    color: var(--primary); /* steelBlue */
    display: block;
}

.quiz-complete-card .card-title {
    font-size: 2.5rem; /* text-3xl */
    color: var(--foreground); /* ice */
    margin-bottom: 0.5rem;
}

.quiz-complete-card .card-description {
    font-size: 1.25rem; /* text-xl */
    color: var(--muted-foreground); /* powder */
}

.quiz-complete-card .card-content {
    text-align: center;
}

.quiz-complete-card .message-text {
    margin-bottom: 1.5rem; /* mb-6 */
    font-size: 1.125rem; /* text-lg */
    color: var(--primary); /* steelBlue */
}

.quiz-complete-card .space-y-4 > * + * {
    margin-top: 1rem; /* space-y-4 */
}

.quiz-complete-card .auto-refresh-text {
    font-size: 0.875rem; /* text-sm */
    color: var(--muted-foreground); /* slate */
}

.quiz-complete-card .restart-button {
    background-color: var(--primary); /* royal */
    color: var(--primary-foreground); /* ice */
    border: none;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: bold;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: background-color 0.2s, box-shadow 0.2s, transform 0.2s;
    box-shadow: var(--shadow-md);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.quiz-complete-card .restart-button:hover {
    transform: translateY(-2px);
}

.quiz-complete-card .rotate-icon {
    margin-right: 0.5rem; /* mr-2 */
    font-size: 1rem; /* w-4 h-4 */
}