/* ==========================================================================
   APK4Game — Complete Hand-Written CSS (No Tailwind, No Build Tools)
   ==========================================================================
   Organised sections:
   1.  CSS Variables & Reset
   2.  Base Typography
   3.  Layout Utilities
   4.  Spacing Utilities
   5.  Flexbox & Grid
   6.  Sizing
   7.  Colors & Backgrounds
   8.  Borders & Radius
   9.  Typography Classes
   10. Shadow & Effects
   11. Visibility & Overflow
   12. Positioning
   13. Transitions & Animations
   14. Components: Navbar
   15. Components: Footer
   16. Components: Buttons
   17. Components: Cards
   18. Components: TOC
   19. Components: Prose (Markdown content)
   20. Components: FAQ Accordion
   21. Responsive Breakpoints
   ========================================================================== */

/* ── 1. CSS Variables & Reset ─────────────────────────────────────────────── */

:root {
  --primary-50:  #eef2ff;
  --primary-100: #e0e7ff;
  --primary-200: #c7d2fe;
  --primary-300: #a5b4fc;
  --primary-400: #818cf8;
  --primary-500: #6366f1;
  --primary-600: #4f46e5;
  --primary-700: #4338ca;
  --primary-800: #3730a3;
  --primary-900: #312e81;

  --success-50:  #f0fdf4;
  --success-400: #4ade80;
  --success-500: #22c55e;
  --success-600: #16a34a;
  --success-900: #14532d;

  --danger-50:  #fef2f2;
  --danger-100: #fee2e2;
  --danger-500: #ef4444;
  --danger-600: #dc2626;

  --warning-50:  #fffbeb;
  --warning-400: #fbbf24;
  --warning-500: #f59e0b;
  --warning-600: #d97706;

  --slate-50:  #f8fafc;
  --slate-100: #f1f5f9;
  --slate-200: #e2e8f0;
  --slate-300: #cbd5e1;
  --slate-400: #94a3b8;
  --slate-500: #64748b;
  --slate-600: #475569;
  --slate-700: #334155;
  --slate-800: #1e293b;
  --slate-900: #0f172a;

  --purple-50:  #faf5ff;
  --purple-600: #9333ea;
  --purple-700: #7e22ce;

  --font-sans: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --radius-sm:   0.375rem;  /* rounded-lg  */
  --radius-md:   0.75rem;   /* rounded-xl  */
  --radius-lg:   1rem;      /* rounded-2xl */
  --radius-full: 9999px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }
.scroll-smooth { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background-color: var(--slate-50);
  color: var(--slate-900);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  overflow-x: hidden;
}

::selection { background-color: var(--primary-500); color: white; }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; background: transparent; border: none; cursor: pointer; }

/* ── 2. Base Typography ───────────────────────────────────────────────────── */

h1, h2, h3, h4, h5, h6 { font-weight: 700; line-height: 1.2; color: var(--slate-900); }
h1 { font-size: 2.25rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1rem; }
p  { line-height: 1.75; }

/* ── 3. Layout Utilities ─────────────────────────────────────────────────── */

.container   { width: 100%; margin-left: auto; margin-right: auto; }
.mx-auto     { margin-left: auto; margin-right: auto; }
.max-w-sm    { max-width: 24rem; }
.max-w-md    { max-width: 28rem; }
.max-w-xl    { max-width: 36rem; }
.max-w-2xl   { max-width: 42rem; }
.max-w-4xl   { max-width: 56rem; }
.max-w-7xl   { max-width: 80rem; }
.max-w-none  { max-width: none; }
.max-w-\[80px\] { max-width: 80px; }

.w-full   { width: 100%; }
.w-auto   { width: auto; }
.w-10     { width: 2.5rem; }
.w-14     { width: 3.5rem; }
.w-16     { width: 4rem; }
.w-20     { width: 5rem; }
.w-24     { width: 6rem; }

.h-10     { height: 2.5rem; }
.h-14     { height: 3.5rem; }
.h-16     { height: 4rem; }
.h-20     { height: 5rem; }
.h-24     { height: 6rem; }
.h-44     { height: 11rem; }
.h-full   { height: 100%; }

.min-w-0  { min-width: 0; }

/* ── 4. Spacing Utilities ────────────────────────────────────────────────── */

/* Padding */
.p-0   { padding: 0; }
.p-1   { padding: 0.25rem; }
.p-2   { padding: 0.5rem; }
.p-3   { padding: 0.75rem; }
.p-4   { padding: 1rem; }
.p-5   { padding: 1.25rem; }
.p-6   { padding: 1.5rem; }
.p-8   { padding: 2rem; }
.p-10  { padding: 2.5rem; }
.p-12  { padding: 3rem; }

.px-2  { padding-left: 0.5rem;  padding-right: 0.5rem; }
.px-3  { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4  { padding-left: 1rem;    padding-right: 1rem; }
.px-5  { padding-left: 1.25rem; padding-right: 1.25rem; }
.px-6  { padding-left: 1.5rem;  padding-right: 1.5rem; }
.px-8  { padding-left: 2rem;    padding-right: 2rem; }

.py-0\.5 { padding-top: 0.125rem; padding-bottom: 0.125rem; }
.py-1    { padding-top: 0.25rem;  padding-bottom: 0.25rem; }
.py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
.py-2    { padding-top: 0.5rem;   padding-bottom: 0.5rem; }
.py-3    { padding-top: 0.75rem;  padding-bottom: 0.75rem; }
.py-3\.5 { padding-top: 0.875rem; padding-bottom: 0.875rem; }
.py-4    { padding-top: 1rem;     padding-bottom: 1rem; }
.py-12   { padding-top: 3rem;     padding-bottom: 3rem; }
.py-16   { padding-top: 4rem;     padding-bottom: 4rem; }
.py-24   { padding-top: 6rem;     padding-bottom: 6rem; }

.pt-0    { padding-top: 0; }
.pt-3    { padding-top: 0.75rem; }
.pt-4    { padding-top: 1rem; }
.pt-8    { padding-top: 2rem; }
.pt-10   { padding-top: 2.5rem; }

.pb-5    { padding-bottom: 1.25rem; }
.pb-6    { padding-bottom: 1.5rem; }
.pr-6    { padding-right: 1.5rem; }

/* Margin */
.m-0     { margin: 0; }
.mb-0\.5 { margin-bottom: 0.125rem; }
.mb-1    { margin-bottom: 0.25rem; }
.mb-2    { margin-bottom: 0.5rem; }
.mb-3    { margin-bottom: 0.75rem; }
.mb-4    { margin-bottom: 1rem; }
.mb-6    { margin-bottom: 1.5rem; }
.mb-8    { margin-bottom: 2rem; }
.mb-10   { margin-bottom: 2.5rem; }
.mb-12   { margin-bottom: 3rem; }

.mt-0\.5 { margin-top: 0.125rem; }
.mt-1    { margin-top: 0.25rem; }
.mt-1\.5 { margin-top: 0.375rem; }
.mt-2    { margin-top: 0.5rem; }
.mt-4    { margin-top: 1rem; }
.mt-8    { margin-top: 2rem; }
.mt-12   { margin-top: 3rem; }
.mt-16   { margin-top: 4rem; }
.mt-20   { margin-top: 5rem; }
.mt-auto { margin-top: auto; }

.my-10   { margin-top: 2.5rem; margin-bottom: 2.5rem; }

/* ── 5. Flexbox & Grid ───────────────────────────────────────────────────── */

.flex        { display: flex; }
.inline-flex { display: inline-flex; }
.grid        { display: grid; }
.block       { display: block; }
.hidden      { display: none; }

.flex-col    { flex-direction: column; }
.flex-wrap   { flex-wrap: wrap; }
.flex-1      { flex: 1 1 0%; }
.grow        { flex-grow: 1; }
.shrink-0    { flex-shrink: 0; }

.items-center { align-items: center; }
.items-start  { align-items: flex-start; }

.justify-center  { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-start   { justify-content: flex-start; }

.gap-1   { gap: 0.25rem; }
.gap-1\.5{ gap: 0.375rem; }
.gap-2   { gap: 0.5rem; }
.gap-3   { gap: 0.75rem; }
.gap-3\.5{ gap: 0.875rem; }
.gap-4   { gap: 1rem; }
.gap-5   { gap: 1.25rem; }
.gap-6   { gap: 1.5rem; }
.gap-7   { gap: 1.75rem; }
.gap-8   { gap: 2rem; }

.space-y-1 > * + * { margin-top: 0.25rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.space-y-4 > * + * { margin-top: 1rem; }
.space-y-5 > * + * { margin-top: 1.25rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }
.space-y-8 > * + * { margin-top: 2rem; }

.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.col-span-2  { grid-column: span 2 / span 2; }
.col-span-3  { grid-column: span 3 / span 3; }

.divide-y > * + * { border-top: 1px solid; }
.divide-slate-100 > * + * { border-color: var(--slate-100, #f1f5f9); }

/* ── 6. Typography Classes ───────────────────────────────────────────────── */

.text-xs   { font-size: 0.75rem;  line-height: 1rem; }
.text-sm   { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem;     line-height: 1.5rem; }
.text-lg   { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl   { font-size: 1.25rem;  line-height: 1.75rem; }
.text-2xl  { font-size: 1.5rem;   line-height: 2rem; }
.text-3xl  { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl  { font-size: 2.25rem;  line-height: 2.5rem; }
.text-\[10px\] { font-size: 10px; }

.font-medium    { font-weight: 500; }
.font-semibold  { font-weight: 600; }
.font-bold      { font-weight: 700; }
.font-extrabold { font-weight: 800; }
.font-black     { font-weight: 900; }
.font-mono      { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; }

.leading-relaxed { line-height: 1.625; }
.leading-snug    { line-height: 1.375; }
.leading-tight   { line-height: 1.25; }

.tracking-wide   { letter-spacing: 0.025em; }
.tracking-widest { letter-spacing: 0.1em; }
.tracking-tight  { letter-spacing: -0.025em; }

.uppercase     { text-transform: uppercase; }
.antialiased   { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
.font-sans     { font-family: var(--font-sans); }

.text-center { text-align: center; }
.text-left   { text-align: left; }
.text-right  { text-align: right; }

.truncate      { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.line-clamp-2  { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-3  { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* Colours */
.text-white         { color: #ffffff !important; }
.text-slate-300     { color: var(--slate-300); }
.text-slate-400     { color: var(--slate-400); }
.text-slate-500     { color: var(--slate-500); }
.text-slate-600     { color: var(--slate-600); }
.text-slate-700     { color: var(--slate-700); }
.text-slate-900     { color: var(--slate-900); }
.text-green-400     { color: #4ade80; }
.text-green-600     { color: var(--success-600); }
.text-amber-600     { color: #d97706; }
.text-yellow-500    { color: var(--warning-500); }
.text-yellow-700    { color: var(--warning-600); }
.text-red-600       { color: var(--danger-600); }
.text-purple-400    { color: #c084fc; }
.text-purple-600    { color: #9333ea; }
.text-purple-700    { color: #7e22ce; }

.hover\:text-white:hover         { color: #ffffff; }
.hover\:text-primary-400:hover   { color: var(--primary-400); }
.hover\:text-purple-700:hover    { color: #7e22ce; }
.hover\:underline:hover          { text-decoration: underline; }
.hover\:underline { text-decoration: none; }

/* ── 7. Backgrounds ──────────────────────────────────────────────────────── */

.bg-white        { background-color: #ffffff; }
.bg-slate-50     { background-color: var(--slate-50); }
.bg-slate-100    { background-color: #f1f5f9; }
.bg-slate-900    { background-color: var(--slate-900); }
.bg-green-50     { background-color: var(--success-50); }
.bg-amber-50     { background-color: var(--warning-50); }
.bg-red-50       { background-color: var(--danger-50); }
.bg-red-500      { background-color: var(--danger-500); }
.bg-purple-50    { background-color: var(--purple-50); }
.bg-yellow-50    { background-color: #fefce8; }

/* ── 8. Borders ──────────────────────────────────────────────────────────── */

.border          { border: 1px solid var(--slate-200); }
.border-2        { border: 2px solid; }
.border-b        { border-bottom: 1px solid var(--slate-200); }
.border-t        { border-top: 1px solid var(--slate-200); }
.border-white    { border-color: #ffffff; }
.border-slate-100{ border-color: #f1f5f9; }
.border-slate-200{ border-color: var(--slate-200); }
.border-slate-800{ border-color: var(--slate-800); }
.border-purple-100{ border-color: #ede9fe; }

.rounded-lg   { border-radius: var(--radius-sm); }
.rounded-xl   { border-radius: var(--radius-md); }
.rounded-2xl  { border-radius: var(--radius-lg); }
.rounded-full { border-radius: var(--radius-full); }
.rounded-bl-xl { border-bottom-left-radius: var(--radius-md); }

/* ── 9. Shadows ──────────────────────────────────────────────────────────── */

.shadow-sm  { box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); }
.shadow-md  { box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); }
.shadow-lg  { box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); }
.shadow-2xl { box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25); }

/* ── 10. Positioning ─────────────────────────────────────────────────────── */

.relative  { position: relative; }
.absolute  { position: absolute; }
.fixed     { position: fixed; }
.sticky    { position: sticky; }
.inset-0   { inset: 0; }
.inset-x-0 { left: 0; right: 0; }
.top-0     { top: 0; }
.top-16    { top: 4rem; }
.left-0    { left: 0; }
.right-0   { right: 0; }
.-top-40   { top: -10rem; }

.z-0   { z-index: 0; }
.z-40  { z-index: 40; }
.z-50  { z-index: 50; }
.-z-0  { z-index: 0; }

/* ── 11. Overflow ────────────────────────────────────────────────────────── */

.overflow-hidden { overflow: hidden; }
.object-cover    { object-fit: cover; }

/* ── 12. Visibility ──────────────────────────────────────────────────────── */

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

/* ── 13. Transitions & Animations ────────────────────────────────────────── */

.transition-all       { transition: all 0.2s ease; }
.transition-colors    { transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease; }
.transition-transform { transition: transform 0.2s ease; }
.duration-200         { transition-duration: 0.2s; }
.duration-300         { transition-duration: 0.3s; }

.blur-3xl { filter: blur(64px); }
.backdrop-blur-md { backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.backdrop-blur-sm { backdrop-filter: blur(4px);  -webkit-backdrop-filter: blur(4px); }

.brightness-110 { filter: brightness(1.1); }

.cursor-pointer { cursor: pointer; }
.list-none      { list-style: none; }

/* ── Group hover support ─────────────────────────────────────────────────── */
.group:hover .group-hover\:bg-purple-600 { background-color: #9333ea; }
.group:hover .group-hover\:text-white    { color: #ffffff; }
.group:hover .group-hover\:text-purple-700 { color: #7e22ce; }
.group:hover .group-hover\:scale-105     { transform: scale(1.05); }
.group:hover .group-hover\:translate-x-1 { transform: translateX(0.25rem); }
.group:hover .group-hover\:stroke-purple-500 { stroke: #a855f7; }

/* ── Hover effects ───────────────────────────────────────────────────────── */
.hover\:-translate-y-0\.5:hover { transform: translateY(-2px); }
.hover\:shadow-lg:hover  { box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); }
.hover\:shadow-md:hover  { box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); }
.hover\:border-purple-300:hover { border-color: #d8b4fe; }
.hover\:bg-slate-50:hover { background-color: var(--slate-50); }
.hover\:bg-slate-800:hover { background-color: var(--slate-800); }
.hover\:scale-105:hover   { transform: scale(1.05); }

.active\:scale-95:active  { transform: scale(0.95); }

/* ── 14. Component: Navbar ───────────────────────────────────────────────── */

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--slate-300);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-link:hover { color: #ffffff; }
.nav-link.active { color: var(--primary-400); }

#mobile-menu { transition: opacity 0.25s ease, transform 0.25s ease; }
#mobile-menu.hidden-menu { opacity: 0; transform: translateY(-8px); pointer-events: none; }
#mobile-backdrop { transition: opacity 0.25s ease; }
#mobile-backdrop.hidden-menu { opacity: 0; pointer-events: none; }

.bg-slate-900\/95 { background-color: rgba(15,23,42,0.95); }
.bg-black\/40     { background-color: rgba(0,0,0,0.4); }

/* ── 15. Component: Buttons ──────────────────────────────────────────────── */

.btn-primary {
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 0.5rem; background-color: var(--primary-600);
  padding: 0.75rem 1.5rem; font-size: 0.875rem; font-weight: 600;
  color: white; box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  transition: all 0.2s; text-decoration: none; border: none; cursor: pointer;
  white-space: nowrap;
}
.btn-primary:hover { background-color: var(--primary-500); transform: translateY(-2px); color: white; }
.btn-primary:active { transform: translateY(0); }

.btn-secondary {
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 0.5rem; background-color: #f1f5f9;
  padding: 0.75rem 1.5rem; font-size: 0.875rem; font-weight: 600;
  color: var(--slate-900); transition: all 0.2s; text-decoration: none; border: none; cursor: pointer;
  white-space: nowrap;
}
.btn-secondary:hover { background-color: var(--slate-200); transform: translateY(-2px); color: var(--slate-900); }
.btn-secondary:active { transform: translateY(0); }

/* ── 16. Component: Cards (generic shared styles) ───────────────────────── */

/* App card */
.app-card-wrapper {
  text-decoration: none; display: block; height: 100%;
}
.app-card {
  position: relative; border-radius: var(--radius-lg); padding: 1.25rem;
  height: 100%; display: flex; flex-direction: column; gap: 1rem;
  background: #ffffff; border: 1px solid var(--slate-200);
  transition: box-shadow 0.3s, transform 0.3s, border-color 0.3s;
  overflow: hidden;
}
.app-card:hover {
  box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  transform: translateY(-2px); border-color: #d8b4fe;
}

/* ── 17. Component: Table of Contents ────────────────────────────────────── */

.toc-wrapper {
  background: var(--slate-50); border: 1px solid var(--slate-200);
  border-radius: var(--radius-md); padding: 1.25rem 1.5rem; margin-bottom: 2rem;
}
.toc-wrapper h4 {
  font-size: 0.75rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--slate-500); margin: 0 0 0.75rem 0;
}
.toc-wrapper ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.25rem; }
.toc-wrapper li a {
  font-size: 0.875rem; color: var(--slate-600); text-decoration: none;
  display: block; padding: 0.2rem 0; transition: color 0.15s;
}
.toc-wrapper li a:hover { color: var(--primary-600); }
.toc-wrapper li.toc-h3 { padding-left: 1rem; }
.toc-wrapper li.toc-h3 a { font-size: 0.8rem; color: var(--slate-500); }
.not-prose { /* override prose inheritance on toc */ max-width: none; }

/* ── 18. Component: Anchor Offset (sticky nav) ───────────────────────────── */

.anchor-offset {
  display: block; position: relative; top: -80px;
  visibility: hidden; pointer-events: none;
}

/* ── 19. Component: Prose (Markdown Content) ─────────────────────────────── */

.prose {
  color: var(--slate-800);
  font-size: 1rem;
  line-height: 1.75;
  max-width: 65ch;
}
.prose.max-w-none { max-width: none; }

.prose h1 { font-size: 2.25em; margin-top: 0; margin-bottom: 0.9em; line-height: 1.1; font-weight: 800; color: var(--slate-900); }
.prose h2 { font-size: 1.5em; margin-top: 2em; margin-bottom: 1em; line-height: 1.35; font-weight: 700; color: var(--slate-900); }
.prose h3 { font-size: 1.25em; margin-top: 1.6em; margin-bottom: 0.6em; line-height: 1.6; font-weight: 700; color: var(--slate-900); }
.prose h4 { font-size: 1em; margin-top: 1.5em; margin-bottom: 0.5em; line-height: 1.5; font-weight: 600; color: var(--slate-900); }

.prose p { margin-top: 1.25em; margin-bottom: 1.25em; }
.prose strong { color: var(--slate-900); font-weight: 700; }
.prose em { font-style: italic; }

.prose a { color: var(--primary-600) !important; text-decoration: underline; font-weight: 500; }
.prose a:hover { color: var(--primary-500) !important; }

.prose ul { list-style-type: disc; margin: 1.25em 0; padding-left: 1.625em; }
.prose ol { list-style-type: decimal; margin: 1.25em 0; padding-left: 1.625em; }
.prose li { margin: 0.5em 0; padding-left: 0.375em; }
.prose ul > li::marker { color: var(--primary-500); }
.prose ol > li::marker { color: var(--slate-500); font-weight: 400; }

.prose blockquote {
  font-weight: 500; font-style: italic; color: var(--slate-600);
  border-left: 4px solid var(--primary-500);
  margin: 1.6em 0; padding: 0.9rem 1.25rem;
  background: var(--slate-50); border-radius: 0 0.5rem 0.5rem 0;
}
.prose blockquote p { margin: 0; font-style: normal; }

.prose code {
  color: var(--primary-600); font-weight: 600; font-size: 0.875em;
  background: var(--primary-50); padding: 0.15em 0.4em; border-radius: 0.25em;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
}
.prose pre {
  color: #e2e8f0; background-color: var(--slate-800); overflow-x: auto;
  font-size: 0.875em; line-height: 1.7; margin: 1.7em 0;
  border-radius: var(--radius-md); padding: 1.14em 1.7em;
}
.prose pre code { background: none; color: inherit; font-size: inherit; padding: 0; }

.prose hr { border: none; border-top: 1px solid var(--slate-200); margin: 3em 0; }

.prose img {
  margin: 2em auto; border-radius: var(--radius-lg);
  max-width: 100%; height: auto; display: block;
}

/* prose-lg */
.prose-lg { font-size: 1.125rem; line-height: 1.78; }
.prose-lg p { margin-top: 1.33em; margin-bottom: 1.33em; }
.prose-lg h2 { font-size: 1.56em; }
.prose-lg h3 { font-size: 1.33em; }

/* prose modifier passthrough classes */
.prose-headings\:font-bold h1,
.prose-headings\:font-bold h2,
.prose-headings\:font-bold h3,
.prose-headings\:font-bold h4 { font-weight: 700; }

.prose-headings\:tracking-tight h1,
.prose-headings\:tracking-tight h2,
.prose-headings\:tracking-tight h3,
.prose-headings\:tracking-tight h4 { letter-spacing: -0.025em; }

.prose-img\:rounded-2xl img { border-radius: var(--radius-lg); }
.prose-img\:shadow-sm img   { box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); }
.prose-a\:text-purple-700 a { color: #7e22ce !important; }

/* ── Prose tables ── */
.prose table {
  width: 100% !important; border-collapse: collapse !important;
  font-size: 0.875rem; margin: 1.25rem 0;
}
.prose table thead, .prose table th { display: none !important; }
.prose table tbody tr:nth-child(odd)  td { background-color: #f4f4f4; }
.prose table tbody tr:nth-child(even) td { background-color: #ffffff; }
.prose table td {
  padding: 8px 10px; color: var(--slate-800);
  vertical-align: middle; line-height: 1.5; word-break: break-word;
  border: none;
}
.prose table td:first-child { font-weight: 700; width: 40%; }
.prose table td:last-child  { color: var(--slate-700); }

/* ── Prose image limit on desktop ── */
@media (min-width: 768px) {
  .prose img {
    max-height: 480px; width: auto; object-fit: contain;
    margin-left: auto; margin-right: auto;
  }
}

/* ── 20. Component: FAQ Accordion ────────────────────────────────────────── */

details { border-radius: var(--radius-md); overflow: hidden; }
details summary { list-style: none; }
details summary::-webkit-details-marker { display: none; }
details[open] summary span svg { transform: rotate(180deg); }
details summary span svg { transition: transform 0.2s ease; }

/* ── 21. Lead paragraph ──────────────────────────────────────────────────── */
.lead { font-size: 1.25rem; line-height: 1.75; color: var(--slate-600); }

/* ── 22. Responsive Breakpoints ─────────────────────────────────────────── */

/* sm: 640px */
@media (min-width: 640px) {
  .sm\:flex        { display: flex; }
  .sm\:flex-row    { flex-direction: row; }
  .sm\:hidden      { display: none; }
  .sm\:inline-flex { display: inline-flex; }
  .sm\:items-start { align-items: flex-start; }
  .sm\:justify-start { justify-content: flex-start; }
  .sm\:text-left   { text-align: left; }
  .sm\:text-right  { text-align: right; }
  .sm\:text-2xl    { font-size: 1.5rem; line-height: 2rem; }
  .sm\:text-3xl    { font-size: 1.875rem; line-height: 2.25rem; }
  .sm\:text-4xl    { font-size: 2.25rem; line-height: 2.5rem; }
  .sm\:text-6xl    { font-size: 3.75rem; line-height: 1; }
  .sm\:w-32        { width: 8rem; }
  .sm\:h-32        { height: 8rem; }
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .sm\:gap-12      { gap: 3rem; }
  .sm\:p-8         { padding: 2rem; }
  .sm\:p-10        { padding: 2.5rem; }
  .sm\:px-6        { padding-left: 1.5rem; padding-right: 1.5rem; }
  .sm\:py-16       { padding-top: 4rem; padding-bottom: 4rem; }
  .sm\:py-20       { padding-top: 5rem; padding-bottom: 5rem; }
  .sm\:py-32       { padding-top: 8rem; padding-bottom: 8rem; }
  .sm\:-top-80     { top: -20rem; }
  .prose table td  { padding: 10px 14px; }
  .prose table td:first-child { width: 30%; white-space: nowrap; }
  .prose table { font-size: 0.95rem; }
}

/* md: 768px */
@media (min-width: 768px) {
  .md\:flex         { display: flex; }
  .md\:hidden       { display: none; }
  .md\:block        { display: block; }
  .md\:grid-cols-2  { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .md\:grid-cols-4  { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .md\:col-span-1   { grid-column: span 1 / span 1; }
  .md\:col-span-3   { grid-column: span 3 / span 3; }
  .md\:text-5xl     { font-size: 3rem; line-height: 1; }
  .md\:bg-white     { background-color: #ffffff; }
  .md\:border       { border: 1px solid var(--slate-200); }
  .md\:border-slate-200 { border-color: var(--slate-200); }
  .md\:shadow-sm    { box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05); }
  .md\:p-10         { padding: 2.5rem; }
  .md\:px-6         { padding-left: 1.5rem; padding-right: 1.5rem; }
}

/* lg: 1024px */
@media (min-width: 1024px) {
  .lg\:block        { display: block; }
  .lg\:grid-cols-3  { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lg\:px-8         { padding-left: 2rem; padding-right: 2rem; }
  .lg\:text-7xl     { font-size: 4.5rem; line-height: 1; }
  .container        { padding-left: 2rem; padding-right: 2rem; }
}

/* ── Additions to match Next.js version ─────────────────────────────────── */

.glass {
  background-color: rgba(255,255,255,0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(226,232,240,0.5);
  box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  transition: all 0.2s;
}

.rounded-3xl  { border-radius: 1.5rem; }
.grid-cols-3  { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.border-l     { border-left: 1px solid var(--slate-200); }
.border-r     { border-right: 1px solid var(--slate-200); }
.italic       { font-style: italic; }

.text-primary-400 { color: var(--primary-400); }
.text-primary-500 { color: var(--primary-500); }
.text-primary-600 { color: var(--primary-600); }

.group:hover .group-hover\:text-primary-500 { color: var(--primary-500); }

.prose-a\:text-primary-600 a { color: var(--primary-600) !important; }

@media (min-width: 768px) {
  .md\:p-8 { padding: 2rem; }
}
