/**
 * Arabic Lessons Stylesheet
 * Loaded only on arabic-class single posts.
 * All rules scoped under .arabic-lesson to avoid theme conflicts.
 */

/* === Theme overrides: reset minimal-design.css styles inside lesson area === */
.arabic-lesson,
.arabic-lesson * {
  box-sizing: border-box;
}

.arabic-lesson {
  font-family: 'Nunito', sans-serif !important;
  background: var(--hf-light) !important;
  color: var(--hf-dark) !important;
  line-height: 1.7 !important;
  overflow-x: hidden;
  padding: 0 !important;
  margin: 0 !important;
  max-width: none !important;
}

.arabic-lesson h1,
.arabic-lesson h2,
.arabic-lesson h3,
.arabic-lesson h4,
.arabic-lesson h5,
.arabic-lesson h6 {
  color: inherit !important;
  font-weight: inherit !important;
  line-height: inherit !important;
  margin: inherit !important;
}

.arabic-lesson p {
  color: inherit !important;
  margin: 0 0 15px 0 !important;
}

.arabic-lesson a {
  color: inherit;
}

.arabic-lesson ul,
.arabic-lesson ol {
  color: inherit;
}

.arabic-lesson img {
  display: inline;
}

.arabic-lesson table {
  border-collapse: separate;
}

.arabic-lesson blockquote {
  border-left: none;
  padding-left: 0;
  font-style: normal;
}

/* === Lesson Variables === */
.arabic-lesson {
  --hf-blue: #1a73c7;
  --hf-yellow: #ffe066;
  --hf-yellow-deep: #ffc800;
  --hf-green: #27ae60;
  --hf-red: #e74c3c;
  --hf-orange: #f39c12;
  --hf-purple: #8e44ad;
  --hf-pink: #ff6b9d;
  --hf-dark: #2c3e50;
  --hf-light: #f8f4e8;
  --hf-paper: #fffef5;
  --hf-pencil: #555;
  --hf-sketch: #888;
  --arabic-gold: #c8a951;
  --quran-green: #1a6b3c;
  --hadith-blue: #1a4b8c;
}

/* === Arabic Text === */
.arabic-lesson .arabic {
  font-family: 'Scheherazade New', 'Amiri', serif;
  direction: rtl;
  font-size: 1.4em;
  line-height: 2;
  color: var(--hf-dark);
}

.arabic-lesson .arabic-large {
  font-family: 'Scheherazade New', serif;
  font-size: 2.2em;
  direction: rtl;
  color: var(--quran-green);
  line-height: 1.8;
}

.arabic-lesson .arabic-highlight {
  background: linear-gradient(180deg, transparent 60%, var(--hf-yellow) 60%);
  padding: 0 4px;
  font-weight: 700;
}

/* === Hero Section === */
.arabic-lesson .hero {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  padding: 2rem;
}

.arabic-lesson .hero::before {
  content: 'ا س م';
  font-family: 'Scheherazade New', serif;
  font-size: 30vw;
  position: absolute;
  opacity: 0.04;
  color: white;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  white-space: nowrap;
}

.arabic-lesson .hero-badge {
  background: var(--hf-red);
  color: white;
  font-family: 'Bangers', cursive;
  font-size: 1.1rem;
  padding: 6px 24px;
  border-radius: 30px;
  letter-spacing: 2px;
  transform: rotate(-3deg);
  margin-bottom: 1.5rem;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.3);
}

.arabic-lesson .hero h1 {
  font-family: 'Bangers', cursive !important;
  font-size: clamp(3rem, 8vw, 6rem) !important;
  color: white !important;
  letter-spacing: 3px;
  text-shadow: 4px 4px 0 rgba(0,0,0,0.3);
  margin-bottom: 0.5rem !important;
}

.arabic-lesson .hero .arabic-title {
  font-family: 'Scheherazade New', serif;
  font-size: clamp(3rem, 7vw, 5.5rem);
  color: var(--arabic-gold);
  direction: rtl;
  margin-bottom: 1rem;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.4);
}

.arabic-lesson .hero-sub {
  font-family: 'Patrick Hand', cursive;
  font-size: 1.4rem;
  color: rgba(255,255,255,0.8);
  max-width: 600px;
  margin: 0 auto;
}

.arabic-lesson .scroll-hint {
  position: absolute;
  bottom: 2rem;
  animation: hf-bounce 2s infinite;
  color: rgba(255,255,255,0.5);
  font-size: 2rem;
}

@keyframes hf-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(12px); }
}

/* === Main Content Container === */
.arabic-lesson .container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* === Brain Section === */
.arabic-lesson .brain-section {
  background: var(--hf-paper);
  border: 3px dashed var(--hf-sketch);
  border-radius: 12px;
  padding: 2rem 2.5rem;
  margin: 3rem 0;
  position: relative;
}

.arabic-lesson .brain-section::before {
  content: '🧠';
  font-size: 2.5rem;
  position: absolute;
  top: -20px;
  left: 20px;
}

.arabic-lesson .brain-section h2 {
  font-family: 'Bangers', cursive !important;
  font-size: 1.8rem !important;
  color: var(--hf-blue) !important;
  letter-spacing: 1px;
  margin-bottom: 1rem !important;
}

/* === Thought Bubble === */
.arabic-lesson .thought-bubble {
  background: white;
  border-radius: 30px;
  padding: 1.5rem 2rem;
  margin: 2rem auto;
  max-width: 500px;
  position: relative;
  box-shadow: 0 4px 15px rgba(0,0,0,0.08);
  border: 2px solid #e0ddd3;
  text-align: center;
}

.arabic-lesson .thought-bubble::after {
  content: '';
  position: absolute;
  bottom: -30px;
  left: 60px;
  width: 0;
  height: 0;
  border: 15px solid transparent;
  border-top-color: white;
}

.arabic-lesson .thought-bubble .label {
  font-family: 'Patrick Hand', cursive;
  color: var(--hf-sketch);
  font-size: 0.95rem;
  margin-bottom: 0.3rem;
}

/* === Character Box === */
.arabic-lesson .character-box {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  margin: 2rem 0;
  padding: 1.5rem;
  background: white;
  border-radius: 12px;
  border-left: 5px solid var(--hf-blue);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.arabic-lesson .character-box.scholar { border-left-color: var(--hf-purple); }

.arabic-lesson .character-avatar {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  flex-shrink: 0;
}

.arabic-lesson .character-avatar.student { background: #dbeafe; }
.arabic-lesson .character-avatar.teacher { background: #fde68a; }
.arabic-lesson .character-avatar.scholar-av { background: #e9d5ff; }

.arabic-lesson .character-text {
  font-family: 'Patrick Hand', cursive;
  font-size: 1.15rem;
  color: var(--hf-pencil);
  line-height: 1.6;
}

.arabic-lesson .character-text strong {
  color: var(--hf-dark);
  font-family: 'Nunito', sans-serif;
  font-weight: 900;
}

/* === Sticky Notes === */
.arabic-lesson .sticky-note {
  background: var(--hf-yellow);
  padding: 1.5rem 2rem;
  margin: 2rem 0;
  transform: rotate(-1.5deg);
  box-shadow: 4px 4px 8px rgba(0,0,0,0.15);
  font-family: 'Patrick Hand', cursive;
  font-size: 1.15rem;
  line-height: 1.7;
  position: relative;
  max-width: 420px;
}

.arabic-lesson .sticky-note.right { margin-left: auto; transform: rotate(1.5deg); }
.arabic-lesson .sticky-note.green { background: #a8e6cf; }
.arabic-lesson .sticky-note.pink { background: #ffb3ba; }
.arabic-lesson .sticky-note.blue { background: #bae1ff; }

.arabic-lesson .sticky-note .pin {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.5rem;
}

/* === Key Concept === */
.arabic-lesson .key-concept {
  background: white;
  border: 3px solid var(--hf-dark);
  border-radius: 0;
  padding: 2rem 2.5rem;
  margin: 2.5rem 0;
  position: relative;
}

.arabic-lesson .key-concept::before {
  content: 'KEY CONCEPT';
  font-family: 'Bangers', cursive;
  background: var(--hf-dark);
  color: white;
  padding: 4px 18px;
  position: absolute;
  top: -16px;
  left: 20px;
  font-size: 0.95rem;
  letter-spacing: 2px;
}

.arabic-lesson .key-concept h3 {
  font-family: 'Bangers', cursive !important;
  font-size: 1.5rem !important;
  color: var(--hf-blue) !important;
  margin-bottom: 0.8rem !important;
  letter-spacing: 1px;
}

/* === Sign Cards === */
.arabic-lesson .sign-card {
  background: white;
  border-radius: 16px;
  overflow: hidden;
  margin: 2.5rem 0;
  box-shadow: 0 6px 20px rgba(0,0,0,0.1);
  border: 2px solid #e8e4d9;
}

.arabic-lesson .sign-card-header {
  padding: 1.2rem 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.arabic-lesson .sign-number {
  font-family: 'Bangers', cursive;
  font-size: 2.5rem;
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.2);
}

.arabic-lesson .sign-card-header h3 {
  font-family: 'Bangers', cursive !important;
  font-size: 1.6rem !important;
  letter-spacing: 1px;
}

.arabic-lesson .sign-card-header .arabic-sign-name {
  font-family: 'Scheherazade New', serif;
  font-size: 1.8rem;
  direction: rtl;
  margin-left: auto;
}

.arabic-lesson .sign-card-body { padding: 1.5rem 2rem 2rem; }

.arabic-lesson .sign1 .sign-card-header { background: linear-gradient(135deg, #667eea, #764ba2); }
.arabic-lesson .sign1 .sign-number { background: #764ba2; }
.arabic-lesson .sign1 .sign-card-header h3,
.arabic-lesson .sign1 .sign-card-header .arabic-sign-name { color: white !important; }

.arabic-lesson .sign2 .sign-card-header { background: linear-gradient(135deg, #f093fb, #f5576c); }
.arabic-lesson .sign2 .sign-number { background: #f5576c; }
.arabic-lesson .sign2 .sign-card-header h3,
.arabic-lesson .sign2 .sign-card-header .arabic-sign-name { color: white !important; }

.arabic-lesson .sign3 .sign-card-header { background: linear-gradient(135deg, #4facfe, #00f2fe); }
.arabic-lesson .sign3 .sign-number { background: #0984e3; }
.arabic-lesson .sign3 .sign-card-header h3,
.arabic-lesson .sign3 .sign-card-header .arabic-sign-name { color: white !important; }

.arabic-lesson .sign4 .sign-card-header { background: linear-gradient(135deg, #43e97b, #38f9d7); }
.arabic-lesson .sign4 .sign-number { background: #27ae60; }
.arabic-lesson .sign4 .sign-card-header h3,
.arabic-lesson .sign4 .sign-card-header .arabic-sign-name { color: white !important; }

.arabic-lesson .sign5 .sign-card-header { background: linear-gradient(135deg, #fa709a, #fee140); }
.arabic-lesson .sign5 .sign-number { background: #e74c3c; }
.arabic-lesson .sign5 .sign-card-header h3,
.arabic-lesson .sign5 .sign-card-header .arabic-sign-name { color: white !important; }

.arabic-lesson .sign6 .sign-card-header { background: linear-gradient(135deg, #a18cd1, #fbc2eb); }
.arabic-lesson .sign6 .sign-number { background: #8e44ad; }
.arabic-lesson .sign6 .sign-card-header h3,
.arabic-lesson .sign6 .sign-card-header .arabic-sign-name { color: white !important; }

/* === Quran Box === */
.arabic-lesson .quran-box {
  background: linear-gradient(135deg, #f0fdf4, #ecfdf5);
  border: 2px solid var(--quran-green);
  border-radius: 12px;
  padding: 1.5rem 2rem;
  margin: 1.5rem 0;
  position: relative;
}

.arabic-lesson .quran-box::before {
  content: '📖 QUR\'AN EXAMPLE';
  font-family: 'Bangers', cursive;
  font-size: 0.85rem;
  letter-spacing: 2px;
  color: var(--quran-green);
  position: absolute;
  top: -12px;
  left: 16px;
  background: #ecfdf5;
  padding: 0 8px;
}

.arabic-lesson .quran-box .ayah {
  font-family: 'Scheherazade New', serif;
  font-size: 1.8rem;
  text-align: center;
  direction: rtl;
  color: var(--quran-green) !important;
  margin: 0.8rem 0 !important;
  line-height: 2.2;
}

.arabic-lesson .quran-box .reference {
  font-family: 'Patrick Hand', cursive;
  text-align: center;
  color: #555 !important;
  font-size: 0.95rem;
}

.arabic-lesson .quran-box .translation {
  font-style: italic;
  text-align: center;
  color: #444 !important;
  font-size: 0.95rem;
  margin-top: 0.5rem;
  border-top: 1px dashed #ccc;
  padding-top: 0.5rem;
}

.arabic-lesson .quran-box .breakdown {
  background: rgba(255,255,255,0.7);
  border-radius: 8px;
  padding: 1rem;
  margin-top: 1rem;
  font-family: 'Patrick Hand', cursive;
  font-size: 1.05rem;
  color: var(--hf-pencil) !important;
}

/* === Hadith Box === */
.arabic-lesson .hadith-box {
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  border: 2px solid var(--hadith-blue);
  border-radius: 12px;
  padding: 1.5rem 2rem;
  margin: 1.5rem 0;
  position: relative;
}

.arabic-lesson .hadith-box::before {
  content: '📜 HADITH EXAMPLE';
  font-family: 'Bangers', cursive;
  font-size: 0.85rem;
  letter-spacing: 2px;
  color: var(--hadith-blue);
  position: absolute;
  top: -12px;
  left: 16px;
  background: #dbeafe;
  padding: 0 8px;
}

.arabic-lesson .hadith-box .hadith-text {
  font-family: 'Scheherazade New', serif;
  font-size: 1.5rem;
  text-align: center;
  direction: rtl;
  color: var(--hadith-blue) !important;
  margin: 0.8rem 0 !important;
  line-height: 2;
}

.arabic-lesson .hadith-box .reference {
  font-family: 'Patrick Hand', cursive;
  text-align: center;
  color: #555 !important;
  font-size: 0.95rem;
}

.arabic-lesson .hadith-box .translation {
  font-style: italic;
  text-align: center;
  color: #444 !important;
  font-size: 0.95rem;
  margin-top: 0.5rem;
}

/* === Scholar Box === */
.arabic-lesson .scholar-box {
  background: linear-gradient(135deg, #faf5ff, #f3e8ff);
  border: 2px solid var(--hf-purple);
  border-radius: 12px;
  padding: 1.5rem 2rem;
  margin: 1.5rem 0;
  position: relative;
}

.arabic-lesson .scholar-box::before {
  content: '🎓 SCHOLAR\'S WORDS';
  font-family: 'Bangers', cursive;
  font-size: 0.85rem;
  letter-spacing: 2px;
  color: var(--hf-purple);
  position: absolute;
  top: -12px;
  left: 16px;
  background: #f3e8ff;
  padding: 0 8px;
}

.arabic-lesson .scholar-box .scholar-text {
  font-family: 'Scheherazade New', serif;
  font-size: 1.4rem;
  text-align: center;
  direction: rtl;
  color: #5b21b6 !important;
  margin: 0.8rem 0 !important;
  line-height: 2;
}

.arabic-lesson .scholar-box .scholar-name {
  font-family: 'Patrick Hand', cursive;
  text-align: center;
  color: var(--hf-purple) !important;
  font-weight: 700;
  font-size: 1rem;
}

.arabic-lesson .scholar-box .translation {
  font-style: italic;
  text-align: center;
  color: #444 !important;
  font-size: 0.95rem;
  margin-top: 0.5rem;
}

/* === Doodle Note === */
.arabic-lesson .doodle-note {
  font-family: 'Caveat', cursive;
  font-size: 1.3rem;
  color: var(--hf-red) !important;
  transform: rotate(-4deg);
  margin: 1rem 0 1rem 2rem;
  display: inline-block;
}

.arabic-lesson .doodle-note.right-note {
  transform: rotate(3deg);
  margin-left: auto;
  display: block;
  text-align: right;
  padding-right: 2rem;
}

/* === Exercise Box === */
.arabic-lesson .exercise-box {
  background: repeating-linear-gradient(0deg, transparent, transparent 28px, #d4e0f7 28px, #d4e0f7 29px);
  background-color: white;
  border: 2px solid var(--hf-blue);
  border-radius: 12px;
  padding: 2rem 2.5rem;
  margin: 2.5rem 0;
  position: relative;
}

.arabic-lesson .exercise-box::before {
  content: '✏️ EXERCISE';
  font-family: 'Bangers', cursive;
  font-size: 0.95rem;
  letter-spacing: 2px;
  color: var(--hf-blue);
  position: absolute;
  top: -12px;
  left: 16px;
  background: white;
  padding: 0 8px;
}

.arabic-lesson .exercise-box h3 {
  font-family: 'Bangers', cursive !important;
  color: var(--hf-blue) !important;
  font-size: 1.3rem !important;
  letter-spacing: 1px;
  margin-bottom: 1rem !important;
}

.arabic-lesson .exercise-item {
  margin: 0.8rem 0;
  padding: 0.5rem 0;
  border-bottom: 1px dashed #ccc;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.arabic-lesson .exercise-item .arabic { font-size: 1.6rem; }

.arabic-lesson .answer-reveal {
  background: var(--hf-dark);
  color: var(--hf-dark);
  padding: 2px 14px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s;
  font-family: 'Patrick Hand', cursive;
  font-size: 1rem;
  user-select: none;
  text-decoration: none;
}

.arabic-lesson .answer-reveal:hover,
.arabic-lesson .answer-reveal.revealed {
  background: transparent;
  color: var(--hf-blue) !important;
}

/* === Fireside Chat === */
.arabic-lesson .fireside {
  background: #fefce8;
  border-radius: 16px;
  padding: 2rem 2.5rem;
  margin: 2.5rem 0;
  border: 2px solid var(--hf-yellow-deep);
  position: relative;
}

.arabic-lesson .fireside::before {
  content: '🔥 FIRESIDE CHAT';
  font-family: 'Bangers', cursive;
  font-size: 0.95rem;
  letter-spacing: 2px;
  color: var(--hf-orange);
  position: absolute;
  top: -12px;
  left: 16px;
  background: #fefce8;
  padding: 0 8px;
}

.arabic-lesson .fireside-q {
  font-family: 'Nunito', sans-serif;
  font-weight: 900;
  color: var(--hf-dark) !important;
  margin: 1rem 0 0.3rem !important;
}

.arabic-lesson .fireside-a {
  font-family: 'Patrick Hand', cursive;
  font-size: 1.1rem;
  color: var(--hf-pencil) !important;
  margin-bottom: 0.8rem !important;
  padding-left: 1rem;
  border-left: 3px solid var(--hf-yellow-deep);
}

/* === Comparison Table === */
.arabic-lesson .compare-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 2rem 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.arabic-lesson .compare-table th {
  background: var(--hf-dark);
  color: white !important;
  font-family: 'Bangers', cursive;
  font-size: 1.2rem;
  letter-spacing: 1px;
  padding: 1rem;
  text-align: center;
}

.arabic-lesson .compare-table td {
  padding: 1rem;
  text-align: center;
  border-bottom: 1px solid #e8e4d9;
  background: white;
}

.arabic-lesson .compare-table tr:nth-child(even) td { background: #fafaf5; }

/* === Summary Box === */
.arabic-lesson .summary-box {
  background: linear-gradient(135deg, #1a1a2e, #16213e);
  color: white !important;
  border-radius: 16px;
  padding: 2.5rem;
  margin: 3rem 0;
}

.arabic-lesson .summary-box h2 {
  font-family: 'Bangers', cursive !important;
  font-size: 2rem !important;
  color: var(--arabic-gold) !important;
  letter-spacing: 2px;
  margin-bottom: 1.5rem !important;
}

.arabic-lesson .summary-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin: 1rem 0;
  padding: 0.8rem;
  background: rgba(255,255,255,0.05);
  border-radius: 8px;
}

.arabic-lesson .summary-check {
  background: var(--hf-green);
  color: white !important;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-weight: 700;
}

.arabic-lesson .summary-text {
  font-family: 'Patrick Hand', cursive;
  font-size: 1.15rem;
  line-height: 1.5;
  color: white !important;
}

.arabic-lesson .summary-text strong {
  color: white !important;
}

/* === Watch It / Note === */
.arabic-lesson .watch-it {
  background: #fff5f5;
  border-left: 5px solid var(--hf-red);
  padding: 1.2rem 1.5rem;
  margin: 1.5rem 0;
  border-radius: 0 8px 8px 0;
}

.arabic-lesson .watch-it::before {
  content: '⚠️ WATCH IT!';
  font-family: 'Bangers', cursive;
  color: var(--hf-red) !important;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 0.3rem;
}

.arabic-lesson .note-box {
  background: #f0f9ff;
  border-left: 5px solid var(--hf-blue);
  padding: 1.2rem 1.5rem;
  margin: 1.5rem 0;
  border-radius: 0 8px 8px 0;
}

.arabic-lesson .note-box::before {
  content: '📝 NOTE';
  font-family: 'Bangers', cursive;
  color: var(--hf-blue) !important;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 0.3rem;
}

/* === Section Dividers === */
.arabic-lesson .section-break {
  text-align: center;
  margin: 4rem 0 3rem;
  position: relative;
}

.arabic-lesson .section-break::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 2px;
  background: repeating-linear-gradient(90deg, var(--hf-sketch) 0, var(--hf-sketch) 8px, transparent 8px, transparent 16px);
}

.arabic-lesson .section-break span {
  background: var(--hf-light);
  padding: 0 1.5rem;
  position: relative;
  font-family: 'Bangers', cursive;
  font-size: 1.8rem;
  color: var(--hf-dark) !important;
  letter-spacing: 2px;
}

/* === Lesson Footer === */
.arabic-lesson .lesson-footer {
  text-align: center;
  padding: 3rem 1rem;
  font-family: 'Patrick Hand', cursive;
  color: var(--hf-sketch) !important;
  font-size: 1.1rem;
  border-top: 2px dashed #ddd;
  margin-top: 4rem;
}

/* === Full-width content area on arabic-class pages (sidebar stays) === */
body.single-arabic-class .wp-site-blocks > .wp-block-group,
body.single-arabic-class .wp-site-blocks > .wp-block-post-content,
body.single-arabic-class .wp-site-blocks > .entry-content,
body.single-arabic-class .wp-block-post-content {
  padding-left: 0 !important;
  padding-right: 0 !important;
  max-width: none !important;
}

/* === Sidebar toggle button === */
.sidebar-toggle-btn {
  position: fixed;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1001;
  background: #8b0000;
  color: #fff;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  transition: background 0.2s, transform 0.2s;
}

.sidebar-toggle-btn:hover {
  background: #c00;
}

/* Sidebar hidden state */
body.single-arabic-class {
  transition: padding-left 0.3s ease;
}

body.single-arabic-class .minimal-header {
  transition: transform 0.3s ease;
}

body.single-arabic-class.sidebar-hidden {
  padding-left: 0 !important;
}

body.single-arabic-class.sidebar-hidden .minimal-header {
  transform: translateX(-100%);
}

body.single-arabic-class.sidebar-hidden .sidebar-toggle-btn {
  right: auto;
  left: 20px;
}

/* === PDF Download Button === */
.lesson-pdf-btn {
  position: fixed;
  right: 20px;
  bottom: 30px;
  z-index: 1001;
  background: #8b0000;
  color: #fff !important;
  border: none;
  padding: 10px 18px;
  border-radius: 24px;
  cursor: pointer;
  font-family: 'Nunito', sans-serif;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.25);
  transition: background 0.2s, transform 0.15s;
}

.lesson-pdf-btn:hover {
  background: #a00;
  color: #fff !important;
  transform: translateY(-2px);
  text-decoration: none;
}

body.single-arabic-class.sidebar-hidden .lesson-pdf-btn {
  right: 20px;
}

/* === Print: hide non-content elements === */
@media print {
  .sidebar-toggle-btn,
  .lesson-pdf-btn,
  .minimal-header {
    display: none !important;
  }
}

/* === Responsive === */
@media (max-width: 640px) {
  .arabic-lesson .character-box { flex-direction: column; align-items: center; text-align: center; }
  .arabic-lesson .sign-card-header { flex-wrap: wrap; justify-content: center; text-align: center; }
  .arabic-lesson .sign-card-header .arabic-sign-name { margin-left: 0; }
  .arabic-lesson .sticky-note { max-width: 100%; }
  .arabic-lesson .quran-box .ayah,
  .arabic-lesson .hadith-box .hadith-text,
  .arabic-lesson .scholar-box .scholar-text { font-size: 1.3rem; }
}
