/* =================================================================
   KIDSGURU AI TEACHER — 4D VIBRANT KIDS DESIGN SYSTEM (style.css)
   3-Tier Tree Accordion Menu & Mobile Responsive Styles
   ================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;600;700;800;900&display=swap');

:root {
  --bg-gradient: linear-gradient(135deg, #0f172a 0%, #1e1b4b 50%, #311042 100%);
  --surface-card: rgba(255, 255, 255, 0.95);
  --primary-accent: #6366f1;
  --secondary-accent: #ec4899;
  --success-green: #22c55e;
  --warning-yellow: #f59e0b;
  --radius-xl: 24px;
  --radius-lg: 16px;
  --font-family: 'Outfit', -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font-family);
}

body {
  background: var(--bg-gradient);
  min-height: 100vh;
  color: #0f172a;
  overflow-x: hidden;
  width: 100%;
}

/* Top Header Navbar */
.ai-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(16px);
  border-bottom: 2px solid rgba(255, 255, 255, 0.12);
  position: sticky;
  top: 0;
  z-index: 100;
  width: 100%;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #ffffff;
  font-size: 18px;
  font-weight: 900;
}

.brand-logo {
  height: 36px;
  width: auto;
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

.menu-toggle-btn {
  background: linear-gradient(135deg, #ec4899 0%, #a855f7 100%);
  color: #ffffff;
  border: none;
  padding: 8px 14px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(236, 72, 153, 0.4);
  white-space: nowrap;
}

.sound-btn {
  background: rgba(255, 255, 255, 0.15);
  border: 1.5px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
  padding: 7px 12px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
}

.star-badge {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #ffffff;
  padding: 7px 14px;
  border-radius: 20px;
  font-weight: 900;
  font-size: 14px;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.4);
  white-space: nowrap;
}

/* Mobile Slide-Out Drawer Overlay */
.mobile-drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.78);
  backdrop-filter: blur(10px);
  z-index: 9999;
  display: flex;
  justify-content: flex-end;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.mobile-drawer-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.mobile-drawer-content {
  width: 90%;
  max-width: 440px;
  height: 100%;
  background: #1e1b4b;
  border-left: 2px solid rgba(255, 255, 255, 0.2);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  color: #ffffff;
}

.mobile-drawer-overlay.open .mobile-drawer-content {
  transform: translateX(0);
}

.drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid rgba(255, 255, 255, 0.12);
  padding-bottom: 10px;
}

.drawer-header h2 {
  font-size: 17px;
  font-weight: 900;
}

.drawer-close-btn {
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: #ffffff;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 16px;
  font-weight: 900;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.drawer-search-wrapper {
  width: 100%;
}

.drawer-search-input {
  width: 100%;
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
  outline: none;
}

.drawer-footer-badge {
  text-align: center;
  font-size: 12px;
  color: #cbd5e1;
  font-weight: 700;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* =================================================================
   3-TIER TREE ACCORDION STYLES
   ================================================================= */
.three-tier-accordion-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.tier1-item {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.08);
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  border-radius: 14px;
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.tier1-item.expanded {
  border-color: #818cf8;
}

.tier1-header {
  padding: 12px 14px;
  font-size: 14px;
  font-weight: 800;
  color: #ffffff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  user-select: none;
  background: rgba(255, 255, 255, 0.05);
}

.tier1-header:hover {
  background: rgba(255, 255, 255, 0.15);
}

.tier-arrow {
  font-size: 12px;
  transition: transform 0.2s ease;
  color: #cbd5e1;
}

.tier1-item.expanded > .tier1-header > .tier-arrow {
  transform: rotate(90deg);
  color: #818cf8;
}

.tier2-container {
  display: none;
  padding: 8px 12px 12px;
  flex-direction: column;
  gap: 8px;
  background: rgba(15, 23, 42, 0.4);
}

.tier1-item.expanded > .tier2-container {
  display: flex;
}

.tier2-item {
  display: flex;
  flex-direction: column;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.tier2-header {
  padding: 9px 12px;
  font-size: 13px;
  font-weight: 800;
  color: #a7f3d0;
  background: rgba(16, 185, 129, 0.15);
  border-left: 3px solid #10b981;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.tier2-header:hover {
  background: rgba(16, 185, 129, 0.25);
}

.tier2-item.expanded > .tier2-header > .tier-arrow {
  transform: rotate(90deg);
  color: #10b981;
}

.tier3-container {
  display: none;
  padding: 8px 10px;
  flex-direction: column;
  gap: 6px;
  background: rgba(0, 0, 0, 0.3);
}

.tier2-item.expanded > .tier3-container {
  display: flex;
}

.tier3-item {
  background: #ffffff;
  color: #0f172a;
  border: 1.5px solid #cbd5e1;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
  width: 100%;
}

.tier3-item:hover {
  border-color: #6366f1;
  background: #f8fafc;
  transform: translateX(4px);
}

.tier3-item.active-lesson {
  background: linear-gradient(135deg, #6366f1 0%, #4338ca 100%);
  color: #ffffff;
  border-color: #818cf8;
}

/* Main Container Layout */
.teacher-app-container {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 20px;
  max-width: 1240px;
  margin: 16px auto;
  padding: 0 16px;
  width: 100%;
}

/* Desktop Accordion Box */
.desktop-accordion-box {
  background: rgba(255, 255, 255, 0.08);
  border: 2px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(16px);
  border-radius: var(--radius-xl);
  padding: 16px;
  color: #ffffff;
}

.desktop-box-title {
  font-size: 14px;
  font-weight: 800;
  color: #e2e8f0;
  margin-bottom: 12px;
}

/* Main Classroom Stage */
.classroom-main {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.classroom-banner {
  background: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
  border-radius: var(--radius-xl);
  padding: 16px 20px;
  color: #ffffff;
  box-shadow: 0 10px 25px rgba(168, 85, 247, 0.3);
}

.banner-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}

.banner-title {
  font-size: 22px;
  font-weight: 900;
}

.change-topic-btn {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #ffffff;
  padding: 6px 12px;
  border-radius: 14px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  white-space: nowrap;
}

.banner-sub {
  font-size: 13px;
  font-weight: 600;
  opacity: 0.9;
}

/* Lesson Stage Container & Teacher Message Formatting */
.lesson-stage-wrapper {
  background: #ffffff;
  border-radius: var(--radius-xl);
  border: 3px solid #e2e8f0;
  padding: 24px 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  min-height: 320px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  overflow-wrap: break-word;
  word-break: break-word;
}

/* SEMANTIC PROMPT HTML TAGS AND STYLING */
.teacher-message {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.teacher-message h2 {
  font-size: clamp(20px, 5vw, 26px);
  font-weight: 900;
  color: #1e1b4b;
  line-height: 1.2;
}

.lesson-title {
  font-size: clamp(15px, 3.8vw, 18px);
  font-weight: 800;
  color: #4338ca;
  background: #e0e7ff;
  padding: 6px 12px;
  border-radius: 12px;
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  line-height: 1.4;
}

.example {
  background: #f8fafc;
  border-left: 5px solid #6366f1;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: clamp(14px, 3.5vw, 17px);
  font-weight: 700;
  color: #1e293b;
  line-height: 1.5;
  width: 100%;
}

.question {
  background: #fdf4ff;
  border: 2px dashed #d946ef;
  padding: 14px;
  border-radius: 16px;
  text-align: center;
  width: 100%;
}

.question h3 {
  font-size: clamp(17px, 4vw, 20px);
  font-weight: 900;
  color: #86198f;
  margin-bottom: 6px;
}

.question p {
  font-size: clamp(15px, 3.8vw, 18px);
  font-weight: 800;
  color: #0f172a;
  line-height: 1.4;
}

.quiz {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 6px;
  width: 100%;
}

.option {
  background: linear-gradient(180deg, #ffffff 0%, #f1f5f9 100%);
  border: 2.5px solid #cbd5e1;
  color: #0f172a;
  padding: 12px 18px;
  border-radius: 14px;
  font-size: clamp(16px, 4vw, 20px);
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 4px 0 #94a3b8;
  transition: all 0.15s ease;
  min-width: 75px;
  touch-action: manipulation;
}

.option:hover {
  transform: translateY(-2px);
  border-color: #6366f1;
}

.option:active {
  transform: translateY(2px);
}

.option.correct-choice {
  background: linear-gradient(180deg, #4ade80 0%, #16a34a 100%) !important;
  color: #ffffff !important;
  border-color: #15803d !important;
}

.option.wrong-choice {
  background: linear-gradient(180deg, #fca5a5 0%, #dc2626 100%) !important;
  color: #ffffff !important;
  border-color: #991b1b !important;
}

.reward {
  background: #dcfce7;
  border: 2px solid #22c55e;
  padding: 12px 14px;
  border-radius: 12px;
  text-align: center;
  font-size: 15px;
  font-weight: 800;
  color: #15803d;
  animation: popIn 0.3s ease;
  width: 100%;
}

.hint {
  background: #fef3c7;
  border: 2px solid #f59e0b;
  padding: 10px 12px;
  border-radius: 12px;
  text-align: center;
  font-size: 14px;
  font-weight: 800;
  color: #b45309;
  width: 100%;
}

/* =================================================================
   LOADING STATE — Animated Spinner
   ================================================================= */
.loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 48px 20px;
  text-align: center;
  min-height: 320px;
}

.loading-spinner {
  position: relative;
  width: 80px;
  height: 80px;
  display: grid;
  place-items: center;
}

.spinner-ring {
  position: absolute;
  inset: 0;
  border: 4px solid #e2e8f0;
  border-top-color: #6366f1;
  border-right-color: #ec4899;
  border-radius: 50%;
  animation: spinnerRotate 1s linear infinite;
}

.spinner-emoji {
  font-size: 32px;
  animation: spinnerPulse 1.5s ease-in-out infinite;
}

@keyframes spinnerRotate {
  to { transform: rotate(360deg); }
}

@keyframes spinnerPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

.loading-title {
  font-size: clamp(18px, 4.5vw, 22px);
  font-weight: 900;
  color: #1e1b4b;
}

.loading-sub {
  font-size: clamp(13px, 3.5vw, 15px);
  font-weight: 700;
  color: #6366f1;
}

.loading-dots {
  display: flex;
  gap: 6px;
  font-size: 28px;
  font-weight: 900;
  color: #a855f7;
}

.loading-dots span {
  animation: dotBounce 1.4s ease-in-out infinite;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes dotBounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40% { transform: translateY(-10px); opacity: 1; }
}

/* =================================================================
   TEACHER LESSON CONTENT — Premium Teaching Style
   ================================================================= */

/* Fade-in for lesson content */
.teacher-message {
  animation: fadeSlideIn 0.5s ease-out;
}

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Welcome Section */
.welcome-section {
  background: linear-gradient(135deg, #ede9fe 0%, #fce7f3 50%, #dbeafe 100%);
  border-radius: 20px;
  padding: 20px 18px;
  text-align: center;
  border: 2px solid #c4b5fd;
  position: relative;
  overflow: hidden;
}

.welcome-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.06) 0%, transparent 70%);
  animation: shimmerBg 4s ease-in-out infinite;
}

@keyframes shimmerBg {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(5%, 5%); }
}

.welcome-section h2 {
  position: relative;
  font-size: clamp(22px, 5.5vw, 30px) !important;
  background: linear-gradient(135deg, #6366f1, #ec4899, #f59e0b);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.3;
}

/* Teaching Step Cards */
.teach-step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #ffffff;
  border: 2px solid #e2e8f0;
  border-radius: 18px;
  padding: 16px;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
  animation: stepFadeIn 0.4s ease-out both;
}

.teach-step:nth-child(odd) {
  border-left: 5px solid #6366f1;
}

.teach-step:nth-child(even) {
  border-left: 5px solid #ec4899;
}

.teach-step:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.12);
  border-color: #a5b4fc;
}

@keyframes stepFadeIn {
  from { opacity: 0; transform: translateX(-12px); }
  to { opacity: 1; transform: translateX(0); }
}

.teach-step:nth-child(1) { animation-delay: 0.05s; }
.teach-step:nth-child(2) { animation-delay: 0.1s; }
.teach-step:nth-child(3) { animation-delay: 0.15s; }
.teach-step:nth-child(4) { animation-delay: 0.2s; }
.teach-step:nth-child(5) { animation-delay: 0.25s; }
.teach-step:nth-child(6) { animation-delay: 0.3s; }
.teach-step:nth-child(7) { animation-delay: 0.35s; }
.teach-step:nth-child(8) { animation-delay: 0.4s; }
.teach-step:nth-child(9) { animation-delay: 0.45s; }
.teach-step:nth-child(10) { animation-delay: 0.5s; }
.teach-step:nth-child(11) { animation-delay: 0.55s; }
.teach-step:nth-child(12) { animation-delay: 0.6s; }

/* Number / Step Badge */
.step-number-badge {
  min-width: 52px;
  height: 52px;
  background: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
  color: #ffffff;
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 22px;
  font-weight: 900;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.teach-step:nth-child(even) .step-number-badge {
  background: linear-gradient(135deg, #ec4899 0%, #f43f5e 100%);
  box-shadow: 0 4px 12px rgba(236, 72, 153, 0.3);
}

.teach-step:nth-child(3n) .step-number-badge {
  background: linear-gradient(135deg, #f59e0b 0%, #ef4444 100%);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

/* Step Content */
.step-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.step-content h3 {
  font-size: clamp(17px, 4vw, 22px);
  font-weight: 900;
  color: #1e1b4b;
  line-height: 1.2;
}

.step-content p {
  font-size: clamp(14px, 3.5vw, 16px);
  font-weight: 600;
  color: #334155;
  line-height: 1.5;
}

/* Emoji Visual Display */
.emoji-visual {
  font-size: clamp(28px, 7vw, 42px);
  letter-spacing: 4px;
  padding: 12px 16px;
  background: linear-gradient(135deg, #fef3c7 0%, #fce7f3 50%, #dbeafe 100%);
  border-radius: 16px;
  text-align: center;
  border: 2px dashed #d4d4d8;
  line-height: 1.4;
  animation: emojiPop 0.5s ease-out;
}

@keyframes emojiPop {
  from { transform: scale(0.85); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* Fun Fact Box */
.fun-fact {
  background: linear-gradient(135deg, #ecfdf5 0%, #f0fdf4 100%);
  border: 2px solid #86efac;
  border-left: 5px solid #22c55e;
  border-radius: 14px;
  padding: 10px 14px;
  font-size: clamp(13px, 3.2vw, 15px);
  font-weight: 700;
  color: #166534;
  display: flex;
  align-items: center;
  gap: 8px;
}

.fun-fact::before {
  content: '💡';
  font-size: 18px;
  flex-shrink: 0;
}

/* Hindi Translation Lines */
.hindi-line {
  font-size: 0.88em !important;
  color: #4338ca !important;
  font-weight: 700 !important;
  font-style: italic;
  padding-left: 4px;
  border-left: 3px solid #c4b5fd;
  margin-top: 2px;
}

/* Quiz Section */
.quiz-section {
  background: linear-gradient(135deg, #fdf4ff 0%, #fce7f3 100%);
  border: 3px solid #e879f9;
  border-radius: 20px;
  padding: 20px 16px;
  text-align: center;
  margin-top: 8px;
}

.quiz-section .question h3 {
  font-size: clamp(18px, 4.5vw, 24px);
  background: linear-gradient(135deg, #a855f7, #ec4899);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* =================================================================
   SIDEBAR AVATAR CARD
   ================================================================= */
.teacher-avatar-card {
  text-align: center;
  padding: 20px 16px;
  margin-bottom: 14px;
}

.teacher-avatar-glow {
  width: 72px;
  height: 72px;
  margin: 0 auto 10px;
  background: linear-gradient(135deg, #a855f7, #ec4899);
  border-radius: 50%;
  display: grid;
  place-items: center;
  box-shadow: 0 0 24px rgba(168, 85, 247, 0.4);
}

.teacher-emoji {
  font-size: 36px;
}

.teacher-name {
  color: #ffffff;
  font-size: 16px;
  font-weight: 900;
}

.teacher-tagline {
  color: #cbd5e1;
  font-size: 12px;
  font-weight: 700;
  margin-top: 4px;
}

.teacher-badge {
  display: inline-block;
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
  padding: 4px 12px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 800;
  margin-top: 8px;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* Live OpenRouter AI Input Row Styles */
.ai-input-wrapper {
  display: flex;
  gap: 8px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  padding: 8px;
  border-radius: var(--radius-xl);
  border: 2px solid rgba(255, 255, 255, 0.2);
  width: 100%;
}

.ai-chat-input {
  flex: 1;
  background: #ffffff;
  border: 2px solid #cbd5e1;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
  outline: none;
  width: 100%;
}

.ai-chat-input:focus {
  border-color: #6366f1;
}

.ai-send-btn {
  background: linear-gradient(135deg, #a855f7 0%, #6366f1 100%);
  color: #ffffff;
  border: none;
  padding: 0 16px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(168, 85, 247, 0.4);
  white-space: nowrap;
}

/* Classroom Controls */
.classroom-controls {
  display: flex;
  gap: 8px;
  justify-content: center;
  width: 100%;
}

.control-btn {
  border: none;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  flex: 1;
  text-align: center;
  transition: transform 0.15s ease;
}

.control-btn:hover {
  transform: translateY(-2px);
}

.control-btn:active {
  transform: translateY(1px);
}

.prev-btn {
  background: #e2e8f0;
  color: #334155;
  box-shadow: 0 4px 0 #cbd5e1;
}

.next-btn {
  background: linear-gradient(180deg, #f59e0b 0%, #d97706 100%);
  color: #ffffff;
  box-shadow: 0 4px 0 #b45309;
}

.voice-btn {
  background: linear-gradient(180deg, #ec4899 0%, #be185d 100%);
  color: #ffffff;
  box-shadow: 0 4px 0 #9d174d;
}

/* Overlay Celebration Canvas */
#celebrationCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 99999;
}

@keyframes popIn {
  0% { transform: scale(0.9); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

/* =================================================================
   ULTRA MOBILE RESPONSIVE LAYOUT (< 900px PHONES & TABLETS)
   ================================================================= */
@media (max-width: 900px) {
  /* Hide static sidebar on mobile */
  .desktop-sidebar-only {
    display: none !important;
  }

  .ai-header {
    padding: 10px 14px;
  }

  .brand-title {
    display: none;
  }

  .brand-logo {
    height: 32px;
  }

  .header-tools {
    gap: 6px;
  }

  .sound-btn {
    padding: 6px 10px;
    font-size: 12px;
  }

  .star-badge {
    padding: 6px 10px;
    font-size: 12px;
  }

  .menu-toggle-btn {
    padding: 6px 12px;
    font-size: 13px;
  }

  .teacher-app-container {
    grid-template-columns: 1fr;
    margin: 10px auto;
    padding: 0 10px;
  }

  .classroom-banner {
    padding: 12px 14px;
    border-radius: 14px;
  }

  .banner-title {
    font-size: 17px;
  }

  .banner-sub {
    font-size: 11px;
  }

  .lesson-stage-wrapper {
    padding: 16px 12px;
    border-radius: 16px;
    min-height: 280px;
  }

  /* Teach steps stack vertically on mobile */
  .teach-step {
    flex-direction: column;
    gap: 10px;
    padding: 14px;
  }

  .step-number-badge {
    min-width: 44px;
    height: 44px;
    font-size: 18px;
    border-radius: 12px;
  }

  .emoji-visual {
    font-size: clamp(24px, 6vw, 34px);
    padding: 10px 12px;
    letter-spacing: 2px;
  }

  .welcome-section {
    padding: 16px 14px;
  }

  .quiz-section {
    padding: 14px 12px;
  }

  .quiz {
    flex-direction: column;
    width: 100%;
  }

  .option {
    width: 100%;
    padding: 12px;
    font-size: 17px;
  }

  .ai-input-wrapper {
    flex-direction: row;
    padding: 6px;
  }

  .ai-chat-input {
    padding: 8px 12px;
    font-size: 13px;
  }

  .ai-send-btn {
    padding: 0 14px;
    font-size: 12px;
  }

  .classroom-controls {
    flex-direction: row;
    gap: 6px;
  }

  .control-btn {
    padding: 10px 8px;
    font-size: 13px;
  }
}
