/* Wi-Fi Router Eco-Settings Lesson CSS */
#router-lesson {
  margin-top: 1.5rem;
}

.lesson-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.75rem;
}

.tab-btn {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 0.5rem 0.9rem;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink);
  cursor: pointer;
  transition: all 0.2s ease;
}

.tab-btn:hover {
  background: #e8ecf2;
}

.tab-btn.active {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}

.lesson-panel {
  display: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.75rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 8px rgba(21, 34, 57, 0.04);
}

.lesson-panel.active {
  display: block;
}

.lesson-panel h2 {
  font-size: 1.4rem;
  margin-top: 0;
  margin-bottom: 0.5rem;
  color: var(--ink);
}

.panel-subtitle {
  color: #556987;
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
  line-height: 1.5;
}

/* Chapter 1: Beacon Cards */
.beacon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.beacon-card {
  border: 2px solid var(--line);
  border-radius: 8px;
  padding: 1.25rem;
  background: var(--paper);
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
}

.beacon-card:hover {
  border-color: #a0aec0;
}

.beacon-card.active {
  border-color: var(--blue);
  background: #f0f5ff;
}

.beacon-icon {
  font-size: 2rem;
  display: block;
  margin-bottom: 0.4rem;
}

.beacon-card h3 {
  margin: 0.2rem 0 0.4rem 0;
  font-size: 1.05rem;
  color: var(--ink);
}

.beacon-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  background: #e2e8f0;
  color: #4a5568;
}

.beacon-detail-box {
  background: #0b1320;
  border-radius: 8px;
  padding: 1.5rem;
  color: #fff;
  margin-bottom: 1.5rem;
}

.beacon-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.beacon-stat-card {
  background: #152239;
  border: 1px solid #23395d;
  padding: 0.85rem;
  border-radius: 6px;
}

.readout-label {
  font-size: 0.75rem;
  color: #8da4c4;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.readout-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: #a8f074;
  margin-top: 0.2rem;
}

/* Chapter 2: Router Admin Simulator */
.admin-sim-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

@media (max-width: 860px) {
  .admin-sim-layout {
    grid-template-columns: 1fr;
  }
}

.router-panel-box {
  background: #1e293b;
  border-radius: 8px;
  border: 1px solid #334155;
  padding: 1.25rem;
  color: #fff;
}

.admin-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #334155;
  padding-bottom: 0.75rem;
  margin-bottom: 1rem;
}

.admin-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #a8f074;
}

.admin-row {
  margin-bottom: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-row:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.admin-row-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.4rem;
}

.admin-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #e2e8f0;
}

.admin-badge {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.4rem;
  border-radius: 3px;
  background: #10b981;
  color: #fff;
}

.admin-badge.warn {
  background: #ef4444;
}

.admin-toggle-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}

.admin-btn {
  background: #0f172a;
  border: 2px solid #334155;
  padding: 0.6rem 0.5rem;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

.admin-btn:hover {
  border-color: #64748b;
  color: #fff;
}

.admin-btn.active.eco {
  background: #10b981 !important;
  border-color: #059669 !important;
  color: #fff !important;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
}

.admin-btn.active.max {
  background: #ef4444 !important;
  border-color: #dc2626 !important;
  color: #fff !important;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.4);
}

.router-heatmap-box {
  background: #0b1320;
  border-radius: 8px;
  padding: 1.25rem;
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.heatmap-stage {
  min-height: 200px;
  background: #070d17;
  border: 1px solid #1e3a5f;
  border-radius: 6px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  padding: 1rem;
}

.zone-heat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #152239;
  border: 1px solid #23395d;
  padding: 0.6rem 0.75rem;
  border-radius: 6px;
}

/* Chapter 3: Mesh vs Hardwired */
.mesh-compare-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.mesh-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.25rem;
  background: var(--paper);
}

.mesh-card h3 {
  margin-top: 0;
  font-size: 1.05rem;
  color: var(--ink);
}

/* Chapter 4: Physical Placement */
.placement-tips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.tip-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.25rem;
  background: var(--paper);
}

.tip-card h3 {
  margin-top: 0;
  font-size: 1rem;
  color: var(--ink);
}

/* Chapter 5: Quiz */
.quiz-item {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}

.quiz-question {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.75rem;
  color: var(--ink);
}

.quiz-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.quiz-opt-btn {
  background: #fff;
  border: 1px solid var(--line);
  padding: 0.75rem 1rem;
  border-radius: 6px;
  text-align: left;
  font-family: inherit;
  font-size: 0.9rem;
  color: var(--ink);
  cursor: pointer;
  transition: all 0.2s ease;
}

.quiz-opt-btn:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
}

.quiz-opt-btn.correct {
  background: #dcfce7;
  border-color: #16a34a;
  color: #15803d;
  font-weight: 600;
}

.quiz-opt-btn.incorrect {
  background: #fee2e2;
  border-color: #dc2626;
  color: #991b1b;
}

.quiz-feedback {
  margin-top: 0.75rem;
  padding: 0.75rem;
  border-radius: 6px;
  font-size: 0.88rem;
  line-height: 1.4;
  display: none;
}

.quiz-feedback.show {
  display: block;
}

.feedback-correct {
  background: #dcfce7;
  color: #166534;
}

.feedback-incorrect {
  background: #fee2e2;
  color: #991b1b;
}

/* Nav Controls */
.lesson-nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.callout-box {
  background: #f8fafc;
  border-left: 4px solid var(--blue);
  padding: 1rem 1.25rem;
  border-radius: 0 6px 6px 0;
  margin: 1.25rem 0;
  font-size: 0.92rem;
}
