/*
Theme Name: Religion World
Theme URI: https://religionworld.in
Author: Religion World Foundation
Author URI: https://religionworld.in
Description: Premium editorial-style WordPress theme for Religion World — a peer-reviewed interfaith journal inspired by the EAT Forum layout. Features burnt orange/saffron branding, IBM Plex typography, bilingual English/Hindi support, and a full-width article reading experience.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: religion-world
Tags: blog, custom-colors, custom-logo, custom-menu, featured-images, full-width-template, sticky-post, threaded-comments, translation-ready
*/

/* ============================================================
   BASE OVERRIDES (supplements Tailwind CDN)
   ============================================================ */

/* Naming note: brand-green/sage/ochre are saffron/orange shades (not literal greens).
   Names are kept to stay in sync with Tailwind utility classes (text-brand-green etc.). */
:root {
  --brand-green:   #c2410c;
  --brand-sage:    #ea580c;
  --brand-ochre:   #f97316;
  --brand-cream:   #ffffff;
  --brand-charcoal:#1e1b18;
  --brand-card:    #fefce8;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: "IBM Plex Sans", system-ui, sans-serif;
  font-size: 16.5px;
  line-height: 1.65;
  background-color: var(--brand-cream);
  color: var(--brand-charcoal);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 { letter-spacing: -0.01em; }

.rw-post-title { line-height: 2.25rem !important; }

p { font-size: 1.05rem; }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--brand-cream); }
::-webkit-scrollbar-thumb { background: rgba(194,65,12,0.22); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(194,65,12,0.45); }

/* ============================================================
   LANGUAGE TOGGLE
   ============================================================ */
.hi-content { display: none; }
.lang-hi .hi-content { display: block; }
.lang-hi .en-content { display: none; }

/* ============================================================
   ANNOUNCEMENT BAR
   ============================================================ */
.rw-announcement-bar {
  background: var(--brand-green);
  color: var(--brand-cream);
  font-size: 0.7rem;
  font-family: "IBM Plex Mono", monospace;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 0.75rem 1rem;
  text-align: center;
  position: relative;
  z-index: 50;
}

/* ============================================================
   HEADER
   ============================================================ */
.rw-header {
  border-bottom: 1px solid rgba(30,27,24,0.15);
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 40;
}

.rw-logo-text {
  font-family: "IBM Plex Serif", Georgia, serif;
  font-size: 2.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: var(--brand-green);
  line-height: 1;
}

.rw-logo-text span {
  color: var(--brand-ochre);
  font-style: italic;
  font-weight: 400;
}

.rw-logo-tagline {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.625rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: rgba(30,27,24,0.5);
  margin-top: 0.25rem;
}

/* ============================================================
   SECONDARY NAV BAR
   ============================================================ */
.rw-subnav {
  background: var(--brand-card);
  border-top: 1px solid rgba(30,27,24,0.08);
}

.rw-subnav-btn {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.375rem 1rem;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  background: transparent;
  color: rgba(30,27,24,0.65);
  transition: all 0.2s;
  white-space: nowrap;
}

.rw-subnav-btn:hover { background: rgba(30,27,24,0.05); }
.rw-subnav-btn.active {
  background: var(--brand-green);
  color: white;
  font-weight: 700;
}

/* ============================================================
   MOBILE MENU OVERLAY
   ============================================================ */
.rw-mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(30,27,24,0.6);
  backdrop-filter: blur(4px);
  z-index: 60;
  display: none;
  justify-content: flex-end;
}

.rw-mobile-menu-overlay.open { display: flex; }

.rw-mobile-menu-panel {
  width: 100%;
  max-width: 420px;
  background: var(--brand-cream);
  height: 100%;
  padding: 2rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  animation: slideInRight 0.25s ease;
}

@keyframes slideInRight {
  from { transform: translateX(100%); }
  to   { transform: translateX(0); }
}

/* ============================================================
   CARDS & ARTICLE GRID
   ============================================================ */
.rw-article-card {
  background: var(--brand-cream);
  border: 1px solid rgba(30,27,24,0.12);
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: border-color 0.3s, box-shadow 0.3s;
  cursor: pointer;
  padding: 1.25rem;
}

.rw-article-card:hover {
  border-color: rgba(194,65,12,0.4);
  box-shadow: 0 8px 30px rgba(0,0,0,0.08);
}

.rw-article-card .rw-card-image {
  width: 100%;
  aspect-ratio: 16/10;
  overflow: hidden;
  border-radius: 6px;
  background: var(--brand-card);
  margin-bottom: 1rem;
  position: relative;
}

.rw-article-card .rw-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

.rw-article-card:hover .rw-card-image img { transform: scale(1.05); }

.rw-category-badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(4px);
  padding: 0.25rem 0.625rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.5625rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--brand-green);
  font-weight: 800;
  border: 1px solid rgba(194,65,12,0.2);
  border-radius: 4px;
}

.rw-bookmark-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  padding: 0.375rem;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(30,27,24,0.1);
  cursor: pointer;
  color: rgba(30,27,24,0.7);
  transition: color 0.2s;
  display: flex;
  align-items: center;
}

.rw-bookmark-btn:hover,
.rw-bookmark-btn.bookmarked { color: var(--brand-ochre); }

.rw-bookmark-btn.bookmarked svg { fill: var(--brand-ochre); }

.rw-card-meta {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.625rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(30,27,24,0.4);
  margin-bottom: 0.5rem;
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.rw-card-title {
  font-family: "IBM Plex Serif", Georgia, serif;
  font-size: 1.0625rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--brand-charcoal);
  transition: color 0.2s;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rw-article-card:hover .rw-card-title { color: var(--brand-green); }

.rw-card-excerpt {
  font-size: 0.75rem;
  color: rgba(30,27,24,0.65);
  margin-top: 0.5rem;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rw-card-footer {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(30,27,24,0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.rw-card-author {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.625rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(30,27,24,0.6);
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.rw-read-link {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand-ochre);
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  transition: transform 0.2s;
}

.rw-article-card:hover .rw-read-link { transform: translateX(4px); }

/* ============================================================
   SIDEBAR
   ============================================================ */
.rw-sidebar-box {
  border: 1px solid rgba(30,27,24,0.1);
  border-radius: 8px;
  padding: 1.5rem;
}

.rw-sidebar-box.bg-card { background: var(--brand-card); }
.rw-sidebar-box.bg-dark { background: var(--brand-green); color: white; }

.rw-popular-item {
  padding: 1rem 0;
  border-bottom: 1px solid rgba(30,27,24,0.1);
  cursor: pointer;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  transition: background 0.2s;
}

.rw-popular-item:last-child { border-bottom: none; }
.rw-popular-item:hover { background: rgba(30,27,24,0.03); border-radius: 4px; padding-left: 8px; margin-left: -8px; }

.rw-popular-num {
  font-family: "IBM Plex Mono", monospace;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--brand-ochre);
  opacity: 0.6;
  line-height: 1;
}

.rw-popular-item:hover .rw-popular-num { opacity: 1; }

/* ============================================================
   ARTICLE SINGLE PAGE
   ============================================================ */
.rw-article-hero {
  width: 100%;
  height: 300px;
  overflow: hidden;
  border-radius: 12px;
  background: var(--brand-card);
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
}

@media (min-width: 640px) { .rw-article-hero { height: 450px; } }
@media (min-width: 768px) { .rw-article-hero { height: 550px; } }

.rw-article-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rw-article-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.6), transparent 60%);
}

.rw-article-hero-caption {
  position: absolute;
  bottom: 1.5rem;
  left: 1.5rem;
  right: 1.5rem;
  z-index: 2;
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.rw-toc {
  background: var(--brand-card);
  border: 1px solid rgba(30,27,24,0.1);
  border-radius: 8px;
  padding: 1.25rem;
  position: sticky;
  top: 8rem;
}

.rw-toc-item {
  display: block;
  width: 100%;
  text-align: left;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.75rem;
  padding: 0.375rem 0.5rem;
  border-radius: 4px;
  transition: all 0.2s;
  color: rgba(30,27,24,0.6);
  cursor: pointer;
  border: none;
  background: none;
  line-height: 1.4;
}

.rw-toc-item:hover { background: rgba(30,27,24,0.05); }
.rw-toc-item.active {
  background: white;
  color: var(--brand-green);
  font-weight: 700;
  border-left: 4px solid var(--brand-ochre);
  padding-left: 0.5rem;
}

.rw-article-body {
  font-family: "IBM Plex Serif", Georgia, serif;
  font-size: 0.9375rem;
  line-height: 1.8;
  color: rgba(30,27,24,0.85);
}

.rw-article-body p { margin-bottom: 1.25rem; }

.rw-article-body h2 {
  font-family: "IBM Plex Serif", Georgia, serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--brand-green);
  margin-bottom: 1.25rem;
  margin-top: 2.5rem;
  letter-spacing: -0.01em;
}

.rw-article-body section:first-child h2 { margin-top: 0; }

.rw-article-body section {
  padding-top: 1rem;
  border-top: 1px solid rgba(30,27,24,0.05);
  margin-top: 2.5rem;
}

.rw-article-body section:first-child { border-top: none; margin-top: 0; }

.rw-drop-cap::first-letter {
  float: left;
  font-size: 3.75rem;
  font-weight: 800;
  font-family: "IBM Plex Serif", Georgia, serif;
  margin-right: 0.75rem;
  color: var(--brand-ochre);
  line-height: 1;
}

.rw-pullquote {
  border-left: 4px solid var(--brand-ochre);
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
  background: var(--brand-card);
  border-radius: 0 8px 8px 0;
  font-style: italic;
  font-size: 0.9375rem;
  color: rgba(194,65,12,0.9);
}

/* ============================================================
   HERO SECTION (Homepage)
   ============================================================ */
.rw-hero-search {
  background: var(--brand-card);
  padding: 1.25rem;
  border-radius: 8px;
  border: 1px solid rgba(30,27,24,0.1);
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  position: relative;
  overflow: hidden;
}

.rw-search-input {
  width: 100%;
  background: white;
  border: 1px solid rgba(30,27,24,0.2);
  border-radius: 4px;
  padding: 0.625rem 2.5rem 0.625rem 0.875rem;
  font-size: 0.875rem;
  outline: none;
  transition: all 0.2s;
}

.rw-search-input:focus {
  border-color: var(--brand-green);
  box-shadow: 0 0 0 2px rgba(194,65,12,0.1);
}

.rw-quiz-cta {
  background: var(--brand-green);
  color: white;
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid rgba(249,115,22,0.3);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1.5rem;
}

.rw-highlight-panel {
  background: var(--brand-green);
  color: white;
  padding: 2.5rem;
  border-radius: 8px;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--brand-green);
  box-shadow: 0 10px 40px rgba(0,0,0,0.15);
}

/* ============================================================
   BUTTONS
   ============================================================ */
.rw-btn-primary,
.rw-btn-ochre {
  color: white;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  border-radius: 4px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s;
  text-decoration: none;
}

.rw-btn-primary {
  background: var(--brand-green);
  padding: 0.625rem 1.25rem;
}

.rw-btn-primary:hover { background: rgba(194,65,12,0.9); color: white; }

.rw-btn-ochre {
  background: var(--brand-ochre);
  padding: 0.75rem 1.25rem;
}

.rw-btn-ochre:hover { background: var(--brand-sage); }

/* ============================================================
   PAGE CONTENT (entry-content / Gutenberg blocks)
   ============================================================ */
.entry-content { max-width: 100%; }
.entry-content > * + * { margin-top: 1.5rem; }
.entry-content figure { margin: 0; }
.entry-content img { max-width: 100%; height: auto; }
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 { font-family: "IBM Plex Serif", Georgia, serif; font-weight: 700; color: var(--brand-charcoal); line-height: 1.3; }
.entry-content h1 { font-size: 2rem; }
.entry-content h2 { font-size: 1.5rem; }
.entry-content h3 { font-size: 1.25rem; }
.entry-content p  { font-size: 1rem; line-height: 1.75; color: rgba(30,27,24,0.85); }
.entry-content ul,
.entry-content ol { padding-left: 1.5rem; }
.entry-content li { margin-bottom: 0.4rem; line-height: 1.7; }
.entry-content a  { color: var(--brand-green); text-decoration: underline; }
.entry-content a:hover { color: var(--brand-ochre); }
.entry-content .wp-block-columns { display: flex; gap: 2rem; flex-wrap: wrap; }
.entry-content .wp-block-column { flex: 1; min-width: 200px; }
.entry-content .wp-block-button__link {
  background: var(--brand-green);
  color: white;
  padding: 0.6rem 1.25rem;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 600;
  display: inline-block;
}
.entry-content .wp-block-button__link:hover { background: var(--brand-sage); color: white; }

/* ============================================================
   FEATURED ARTICLES (category top-3)
   ============================================================ */
.rw-featured-article {
  display: block;
  background: var(--brand-cream);
  border: 1px solid rgba(30,27,24,0.1);
  border-radius: 8px;
  padding: 1.25rem;
  text-decoration: none;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.rw-featured-article:hover {
  border-color: rgba(194,65,12,0.35);
  box-shadow: 0 4px 16px rgba(194,65,12,0.08);
  transform: translateY(-2px);
}

.rw-featured-num {
  font-family: "IBM Plex Mono", monospace;
  font-size: 1.5rem;
  font-weight: 800;
  color: rgba(194,65,12,0.15);
  line-height: 1;
  margin-top: 0.1rem;
  letter-spacing: -0.03em;
  min-width: 2rem;
}

.rw-featured-title {
  font-family: "IBM Plex Serif", Georgia, serif;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--brand-charcoal);
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.rw-featured-excerpt {
  font-size: 0.75rem;
  color: rgba(30,27,24,0.6);
  line-height: 1.6;
  margin-top: 0.5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============================================================
   TAG CLOUD
   ============================================================ */
.rw-tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.rw-tag-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  font-family: "IBM Plex Mono", monospace;
  font-weight: 600;
  text-decoration: none;
  border: 1.5px solid rgba(194,65,12,0.25);
  background: #fff;
  color: var(--brand-charcoal);
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.15s;
  white-space: nowrap;
}

.rw-tag-pill:hover {
  background: var(--brand-green);
  border-color: var(--brand-green);
  color: #fff;
  transform: translateY(-1px);
}

/* Size variants — larger count = bigger pill */
.rw-tag-lg {
  font-size: 0.72rem;
  padding: 0.35rem 0.9rem;
  border-width: 2px;
  border-color: rgba(194,65,12,0.45);
  color: var(--brand-green);
  font-weight: 700;
}

.rw-tag-md {
  font-size: 0.65rem;
  padding: 0.28rem 0.75rem;
}

.rw-tag-sm {
  font-size: 0.58rem;
  padding: 0.22rem 0.6rem;
  color: rgba(30,27,24,0.65);
}

/* ============================================================
   PAGINATION
   ============================================================ */
.rw-pagination {
  display: flex;
  justify-content: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(30,27,24,0.1);
  margin-bottom: 2rem;
}

.rw-pagination ul.page-numbers {
  list-style: none !important;
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem;
  margin: 0 !important;
  padding: 0 !important;
}

.rw-pagination ul.page-numbers li {
  display: inline-flex !important;
  float: none !important;
}

.rw-pagination .page-numbers a,
.rw-pagination .page-numbers span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  height: 2.25rem;
  padding: 0 0.625rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 4px;
  border: 1px solid rgba(30,27,24,0.15);
  background: var(--brand-cream);
  color: var(--brand-charcoal);
  text-decoration: none;
  transition: all 0.2s;
}

.rw-pagination .page-numbers a:hover {
  background: var(--brand-card);
  border-color: var(--brand-green);
  color: var(--brand-green);
}

.rw-pagination .page-numbers span.current {
  background: var(--brand-green);
  border-color: var(--brand-green);
  color: white;
}

.rw-pagination .page-numbers .dots {
  border-color: transparent;
  background: transparent;
  color: rgba(30,27,24,0.4);
  pointer-events: none;
}

.rw-pagination .page-numbers .prev,
.rw-pagination .page-numbers .next {
  padding: 0 0.875rem;
  background: var(--brand-charcoal);
  border-color: var(--brand-charcoal);
  color: white;
}

.rw-pagination .page-numbers .prev:hover,
.rw-pagination .page-numbers .next:hover {
  background: var(--brand-green);
  border-color: var(--brand-green);
  color: white;
}

/* also style pagination on archive.php (uses same paginate_links) */
.flex.justify-center.gap-2 ul.page-numbers {
  list-style: none !important;
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.375rem;
  margin: 0 !important;
  padding: 0 !important;
}

.flex.justify-center.gap-2 ul.page-numbers li {
  display: inline-flex !important;
  float: none !important;
}

.flex.justify-center.gap-2 .page-numbers a,
.flex.justify-center.gap-2 .page-numbers span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  height: 2.25rem;
  padding: 0 0.625rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: 4px;
  border: 1px solid rgba(30,27,24,0.15);
  background: var(--brand-cream);
  color: var(--brand-charcoal);
  text-decoration: none;
  transition: all 0.2s;
}

.flex.justify-center.gap-2 .page-numbers a:hover {
  background: var(--brand-card);
  border-color: var(--brand-green);
  color: var(--brand-green);
}

.flex.justify-center.gap-2 .page-numbers span.current {
  background: var(--brand-green);
  border-color: var(--brand-green);
  color: white;
}

.flex.justify-center.gap-2 .page-numbers .dots {
  border-color: transparent;
  background: transparent;
  color: rgba(30,27,24,0.4);
  pointer-events: none;
}

.flex.justify-center.gap-2 .page-numbers .prev,
.flex.justify-center.gap-2 .page-numbers .next {
  padding: 0 0.875rem;
  background: var(--brand-charcoal);
  border-color: var(--brand-charcoal);
  color: white;
}

.flex.justify-center.gap-2 .page-numbers .prev:hover,
.flex.justify-center.gap-2 .page-numbers .next:hover {
  background: var(--brand-green);
  border-color: var(--brand-green);
  color: white;
}

/* ============================================================
   FOOTER
   ============================================================ */
.rw-footer {
  background: var(--brand-charcoal);
  color: white;
  border-top: 1px solid rgba(194,65,12,0.3);
  margin-top: 5rem;
}

/* ============================================================
   FORMS
   ============================================================ */
.rw-form-input {
  width: 100%;
  background: white;
  border: 1px solid rgba(30,27,24,0.2);
  border-radius: 4px;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
  outline: none;
  transition: all 0.2s;
}

.rw-form-input:focus {
  border-color: var(--brand-green);
  box-shadow: 0 0 0 2px rgba(194,65,12,0.1);
}

.rw-form-label {
  display: block;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.625rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(30,27,24,0.6);
  margin-bottom: 0.25rem;
}

textarea.rw-form-input { resize: vertical; min-height: 120px; }

/* ============================================================
   CATEGORY PAGE
   ============================================================ */
.rw-category-header {
  border: 1px solid rgba(30,27,24,0.15);
  background: var(--brand-card);
  padding: 3rem;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .rw-category-header { flex-direction: row; justify-content: space-between; align-items: center; }
}

.rw-category-title {
  font-family: "IBM Plex Serif", Georgia, serif;
  font-size: 3rem;
  font-weight: 800;
  color: var(--brand-green);
  letter-spacing: -0.02em;
}

.rw-category-stats {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.75rem;
  color: rgba(30,27,24,0.6);
  background: white;
  padding: 1rem;
  border-radius: 6px;
  border: 1px solid rgba(30,27,24,0.1);
  min-width: 180px;
}

.rw-category-stats div {
  display: flex;
  justify-content: space-between;
  padding-bottom: 0.25rem;
  margin-bottom: 0.25rem;
  border-bottom: 1px solid rgba(30,27,24,0.05);
}

.rw-category-stats div:last-child { border-bottom: none; margin-bottom: 0; }

/* ============================================================
   QUIZ PAGE
   ============================================================ */
.rw-quiz-container {
  max-width: 760px;
  margin: 0 auto;
}

.rw-quiz-progress {
  height: 4px;
  background: rgba(30,27,24,0.08);
  border-radius: 2px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.rw-quiz-progress-bar {
  height: 100%;
  background: var(--brand-ochre);
  border-radius: 2px;
  transition: width 0.4s ease;
}

.rw-quiz-option {
  width: 100%;
  text-align: left;
  background: white;
  border: 2px solid rgba(30,27,24,0.12);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  font-family: "IBM Plex Serif", Georgia, serif;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.rw-quiz-option:hover:not(:disabled) { border-color: var(--brand-ochre); }
.rw-quiz-option.selected { border-color: var(--brand-ochre); background: rgba(249,115,22,0.05); }
.rw-quiz-option.correct { border-color: #16a34a; background: rgba(22,163,74,0.05); }
.rw-quiz-option.incorrect { border-color: #dc2626; background: rgba(220,38,38,0.05); }
.rw-quiz-option:disabled { cursor: default; }

.rw-quiz-option-letter {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: rgba(30,27,24,0.06);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ============================================================
   UTILITIES
   ============================================================ */
.font-serif { font-family: "IBM Plex Serif", Georgia, serif !important; }
.font-mono  { font-family: "IBM Plex Mono", monospace !important; }
.text-brand-green   { color: var(--brand-green) !important; }
.text-brand-ochre   { color: var(--brand-ochre) !important; }
.text-brand-sage    { color: var(--brand-sage) !important; }
.text-brand-cream   { color: var(--brand-cream) !important; }
.text-brand-charcoal{ color: var(--brand-charcoal) !important; }
.bg-brand-green     { background-color: var(--brand-green) !important; }
.bg-brand-ochre     { background-color: var(--brand-ochre) !important; }
.bg-brand-card      { background-color: var(--brand-card) !important; }
.bg-brand-charcoal  { background-color: var(--brand-charcoal) !important; }

.scrollbar-none { scrollbar-width: none; }
.scrollbar-none::-webkit-scrollbar { display: none; }

.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;
}

.pulse { animation: pulse 2s infinite; }
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.5; }
}
