/* ===========================================
   TEACHERAI - DARK RESULTS PAGE (PHASE 4)
   Professional presentation mode for generated lessons
   Created by: Claude 132
   Updated by: Claude 133 (Color Palette System)
   Date: November 17, 2025
   Philosophy: Hallmark quality mark, not advertisement
   =========================================== */

/* ===========================================
   DARK PAGE BACKGROUND
   Using actual Claude chat charcoal (#343541)
   =========================================== */

.results-page-dark {
  background: #343541;
  min-height: 100vh;
  padding: 40px 24px;
}

/* ===========================================
   WHITE LESSON CARD - ELEVATED & CLEAN
   Professional "finished product" presentation
   =========================================== */

.lesson-card-white {
  max-width: 900px;
  margin: 0 auto;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  position: relative;
  animation: slideUp 0.4s ease-out;
}

/* Slide up animation for card entrance */
@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* ===========================================
   LESSON CARD HEADER
   Subtle purple gradient (strategic splash)
   =========================================== */

.lesson-card-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 32px;
  color: white;
}

.lesson-card-title {
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 16px 0;
  line-height: 1.3;
}

.lesson-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 14px;
  opacity: 0.95;
}

.lesson-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ===========================================
   LESSON CARD BODY
   Clean, readable content area
   =========================================== */

.lesson-card-body {
  padding: 40px;
  color: #212529;
  font-size: 16px;
  line-height: 1.7;
}

.lesson-card-body h2 {
  font-size: 24px;
  font-weight: 600;
  color: #212529;
  margin: 32px 0 16px 0;
  border-bottom: 2px solid #e9ecef;
  padding-bottom: 8px;
}

.lesson-card-body h2:first-child {
  margin-top: 0;
}

.lesson-card-body h3 {
  font-size: 20px;
  font-weight: 600;
  color: #495057;
  margin: 24px 0 12px 0;
}

.lesson-card-body ul,
.lesson-card-body ol {
  margin: 16px 0;
  padding-left: 24px;
}

.lesson-card-body li {
  margin: 8px 0;
}

.lesson-card-body p {
  margin: 16px 0;
}

.lesson-card-body strong {
  font-weight: 600;
  color: #212529;
}

/* ===========================================
   COLOR PALETTE SYSTEM - PHASE 4 REFINEMENT
   Visual recognition for lesson sections
   Claude 133 - November 17, 2025
   =========================================== */

/* Section color coding with left border accents */
.objectives-section {
  border-left: 4px solid #8BC34A;
  padding-left: 16px;
  margin-left: -20px;
}

.standards-section {
  border-left: 4px solid #2196F3;
  padding-left: 16px;
  margin-left: -20px;
}

.materials-section {
  border-left: 4px solid #9C27B0;
  padding-left: 16px;
  margin-left: -20px;
}

/* Fusion badge - MAKE IT POP */
.fusion-badge {
  display: inline-block;
  background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
  color: #744210;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(255, 215, 0, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 8px 0;
}

/* Supply closet item styling - Green recycled tones */
.supply-closet-item {
  background: #f1f8e9;
  padding: 8px 12px;
  margin: 6px 0;
  border-left: 4px solid #8BC34A;
  border-radius: 4px;
}

/* Supply tag - Subtle green, not gold */
.supply-tag {
  display: inline-block;
  background: #8BC34A;
  color: #33691e;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  margin-right: 8px;
}

/* Basic items (not from closet) - Neutral */
.basic-item {
  padding: 4px 0;
}

/* ===========================================
   HALLMARK QUALITY MARK
   Silver, subtle, bottom right corner
   "That's quality right there" branding
   =========================================== */

.quality-mark {
  position: absolute;
  bottom: 16px;
  right: 24px;
  font-size: 11px;
  color: #d0d0d0;
  opacity: 0.7;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 400;
  letter-spacing: 0.3px;
  pointer-events: none;
  user-select: none;
}

/* ===========================================
   ACTION BUTTONS AREA
   Above the card, functional styling
   =========================================== */

.results-actions-bar {
  max-width: 900px;
  margin: 0 auto 24px auto;
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.results-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Primary action - Generate Another (strategic purple splash) */
.results-btn-primary {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.results-btn-primary:hover {
  box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
  transform: translateY(-2px);
}

/* Secondary actions - Neutral functional buttons */
.results-btn-secondary {
  background: white;
  color: #495057;
  border: 2px solid #dee2e6;
}

.results-btn-secondary:hover {
  background: #f8f9fa;
  border-color: #adb5bd;
  transform: translateY(-1px);
}

/* Save button - Success green */
.results-btn-save {
  background: #51cf66;
  color: white;
}

.results-btn-save:hover {
  background: #40c057;
  transform: translateY(-1px);
}

/* ===========================================
   RESPONSIVE DESIGN
   Mobile-friendly adjustments
   =========================================== */

@media (max-width: 768px) {
  .results-page-dark {
    padding: 24px 16px;
  }

  .lesson-card-white {
    border-radius: 8px;
  }

  .lesson-card-header {
    padding: 24px;
  }

  .lesson-card-title {
    font-size: 24px;
  }

  .lesson-card-body {
    padding: 24px;
  }

  .lesson-card-body h2 {
    font-size: 20px;
  }

  .results-actions-bar {
    margin-bottom: 16px;
  }

  .results-btn {
    flex: 1 1 100%;
    justify-content: center;
  }

  .quality-mark {
    font-size: 10px;
    bottom: 12px;
    right: 16px;
  }
}

/* ===========================================
   PRINT STYLES
   Quality mark STAYS on printed lessons
   Dark theme adjusts for paper
   =========================================== */

@media print {
  .results-page-dark {
    background: white;
    padding: 0;
  }

  .lesson-card-white {
    box-shadow: none;
    border: 1px solid #dee2e6;
    page-break-inside: avoid;
  }

  .lesson-card-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  /* CRITICAL: Quality mark prints with lesson */
  .quality-mark {
    opacity: 1;
    color: #999999;
  }

  /* Hide action buttons when printing */
  .results-actions-bar {
    display: none !important;
  }

  /* Optimize content for print */
  .lesson-card-body {
    padding: 32px;
  }

  /* Ensure page breaks don't split sections awkwardly */
  .lesson-card-body h2,
  .lesson-card-body h3 {
    page-break-after: avoid;
  }

  .lesson-card-body ul,
  .lesson-card-body ol {
    page-break-inside: avoid;
  }
}

/* ===========================================
   UTILITY CLASSES
   =========================================== */

.hidden {
  display: none;
}

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

/* ===========================================
   END PHASE 4 DARK RESULTS PAGE
   Strategic purple splash, not flood
   Hallmark quality mark, not advertisement
   Color palette system for visual recognition
   =========================================== */

/* ===========================================
   LESSON WORKBENCH STYLES
   Extracted from page-lesson-results.php inline <style>
   Claude 137 - Phase 1B Cleanup (Lines 45-542)
   =========================================== */

/* Container & Layout Grid */
.workbench-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, sans-serif;
}

.workbench-grid {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 30px;
    margin-top: 20px;
}

/* Sidebar Placeholder */
.workbench-sidebar {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    min-height: 400px;
}

.sidebar-placeholder {
    color: #6c757d;
    font-size: 14px;
    font-style: italic;
}

/* Main Content Area */
.workbench-main {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    overflow: hidden;
}

/* Lesson Header */
/* ===========================================
   ENHANCED HERO SECTION
   Claude 140 - Professional, Impactful Design
   November 20, 2025
   =========================================== */

.lesson-header-workbench {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px;
    border-radius: 8px 8px 0 0;
    position: relative;
    overflow: hidden;
}

/* Subtle pattern overlay */
.lesson-header-workbench::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.05) 0%, transparent 50%),
                      radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

.lesson-header-workbench h1 {
    margin: 0 0 24px 0;
    font-size: 36px;
    font-weight: 700;
    line-height: 1.2;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Premium Lesson Badge */
.premium-lesson-badge {
    display: inline-block;
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: #744210;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
    box-shadow: 0 2px 8px rgba(255, 215, 0, 0.3);
}

/* Meta Information Grid */
.lesson-meta-workbench {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    position: relative;
    z-index: 1;
}

.lesson-meta-workbench span {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.lesson-meta-workbench span:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Standards count badge (if present) */
.standards-count {
    background: rgba(255, 255, 255, 0.3);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    margin-left: 8px;
}

/* Anonymous Warning Banner */
.anonymous-warning-workbench {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 15px 20px;
    margin: 20px 30px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.anonymous-warning-workbench strong {
    color: #856404;
}

/* Lesson Content Frame */
.lesson-content-workbench {
    padding: 30px;
    line-height: 1.8;
    color: #333;
}

.lesson-content-workbench h2 {
    color: #667eea;
    font-size: 24px;
    margin: 30px 0 15px 0;
    font-weight: 600;
}

.lesson-content-workbench h3 {
    color: #764ba2;
    font-size: 20px;
    margin: 25px 0 12px 0;
    font-weight: 600;
}

.lesson-content-workbench ul {
    margin: 15px 0;
    padding-left: 25px;
}

.lesson-content-workbench li {
    margin: 8px 0;
}

.lesson-content-workbench p {
    margin: 12px 0;
}

/* Action Buttons Area */
.workbench-actions {
    background: #f8f9fa;
    padding: 25px 30px;
    border-top: 1px solid #e9ecef;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

/* Button Styles */
.btn-workbench {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-workbench:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.btn-workbench:active {
    transform: translateY(0);
}

.btn-save {
    background: #28a745;
    color: white;
}

.btn-save:hover {
    background: #218838;
}

.btn-delete {
    background: #dc3545;
    color: white;
}

.btn-delete:hover {
    background: #c82333;
}

.btn-edit {
    background: #ffc107;
    color: #212529;
}

.btn-edit:hover {
    background: #e0a800;
}

.btn-print {
    background: #17a2b8;
    color: white;
}

.btn-print:hover {
    background: #138496;
}

.btn-upgrade {
    background: #dc3545;
    color: white;
}

.btn-reactivate {
    background: #6c757d;
    color: white;
}

/* Action Status Messages */
.action-status-workbench {
    width: 100%;
    padding: 12px;
    border-radius: 4px;
    margin-top: 10px;
    font-size: 14px;
}

.status-loading {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.status-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* No Lesson Found */
.no-lesson-workbench {
    text-align: center;
    padding: 60px 20px;
}

.no-lesson-workbench h1 {
    color: #667eea;
    margin-bottom: 15px;
}

.no-lesson-workbench a {
    display: inline-block;
    margin-top: 20px;
    padding: 12px 24px;
    background: #667eea;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.6);
    z-index: 9998;
}

.modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 12px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    z-index: 9999;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

.modal-header h2 {
    color: #667eea;
    margin: 0 0 10px 0;
}

.modal-subtitle {
    color: #6c757d;
    margin: 0 0 20px 0;
}

.benefits-section, .upgrade-benefits {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
}

.benefits-section h3, .upgrade-benefits h3 {
    color: #667eea;
    margin: 0 0 15px 0;
}

.benefits-section ul, .upgrade-benefits ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.benefits-section li, .upgrade-benefits li {
    padding: 8px 0;
    border-bottom: 1px solid #e9ecef;
}

.benefits-section li:last-child, .upgrade-benefits li:last-child {
    border-bottom: none;
}

.form-group {
    margin: 20px 0;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 15px;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 25px;
}

.form-actions button {
    flex: 1;
    padding: 14px;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
}

.form-actions button[type="submit"] {
    background: #667eea;
    color: white;
}

.form-actions button[type="button"] {
    background: #6c757d;
    color: white;
}

.modal-footer {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
    text-align: center;
    color: #6c757d;
    font-size: 13px;
}

.pricing-section {
    margin: 20px 0;
}

.pricing-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 25px;
    border-radius: 8px;
    text-align: center;
}

.pricing-card h4 {
    margin: 0 0 15px 0;
    font-size: 20px;
}

.price {
    font-size: 48px;
    font-weight: 700;
    margin: 10px 0;
}

.period {
    font-size: 20px;
    font-weight: 400;
}

/* Print Styles for Workbench */
@media print {
    header,
    nav,
    footer,
    .site-header,
    .site-navigation,
    .site-footer,
    #masthead,
    #site-navigation,
    #colophon,
    .workbench-sidebar,
    .workbench-actions,
    .anonymous-warning-workbench {
        display: none !important;
    }
    
    .workbench-container {
        max-width: 100%;
        padding: 0;
        margin: 0;
    }
    
    .workbench-grid {
        grid-template-columns: 1fr;
        gap: 0;
        margin: 0;
    }
    
    .lesson-header-workbench {
        background: #667eea !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        page-break-after: avoid;
        border-radius: 0;
        margin: 0;
    }
    
    .workbench-main {
        box-shadow: none;
        border-radius: 0;
        margin: 0;
        padding: 0;
    }
    
    .lesson-content-workbench {
        padding: 20px 30px;
        page-break-inside: avoid;
    }
    
    .lesson-content-workbench h2,
    .lesson-content-workbench h3 {
        page-break-after: avoid;
    }
    
    .lesson-content-workbench ul,
    .lesson-content-workbench ol {
        page-break-inside: avoid;
    }
}

/* Mobile Responsive for Workbench */
@media (max-width: 768px) {
    .workbench-grid {
        grid-template-columns: 1fr;
    }
    
    .workbench-sidebar {
        display: none;
    }
    
    .lesson-header-workbench {
        padding: 30px 24px;
    }
    
    .lesson-header-workbench h1 {
        font-size: 28px;
    }
    
    .lesson-meta-workbench {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .lesson-meta-workbench span {
        font-size: 14px;
        padding: 10px 14px;
    }
    
    .workbench-actions {
        flex-direction: column;
    }
    
    .btn-workbench {
        width: 100%;
        justify-content: center;
    }
}

/* ===========================================
   END WORKBENCH STYLES EXTRACTION
   =========================================== */
   /* ===========================================
   ENHANCED SIDEBAR WITH TEACHING TOOLS
   Claude 138 - Phase 1B Results Page
   November 20, 2025
   =========================================== */

/* Enhanced sidebar container */
.results-sidebar-enhanced {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px;
    border-radius: 8px;
    color: white;
}

/* Section titles */
.sidebar-section-title {
    font-size: 14px;
    font-weight: 700;
    color: white;
    margin: 0 0 15px 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Sidebar action buttons */
.sidebar-action-btn {
    width: 100%;
    padding: 12px 16px;
    background: white;
    color: #667eea;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sidebar-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Sidebar divider */
.sidebar-divider {
    border: none;
    border-top: 2px solid rgba(255, 255, 255, 0.2);
    margin: 20px 0;
}

/* Teaching tools section */
.teaching-tools-section {
    margin: 20px 0;
}

.tools-hint {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    margin: 0 0 12px 0;
    font-style: italic;
}

/* Tool display items */
.tool-button-display {
    width: 100%;
    padding: 12px 16px;
    background: white;
    color: #667eea;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tool-icon {
    font-size: 18px;
}

.tool-name {
    flex: 1;
}

.tool-status {
    font-size: 12px;
    color: #51cf66;
}

/* Quick navigation links */
.quick-nav-section {
    margin: 20px 0 0 0;
}

.sidebar-nav-link {
    display: block;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 13px;
    margin-bottom: 8px;
    transition: all 0.2s ease;
}

.sidebar-nav-link:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(4px);
}

/* Mobile responsive */
@media (max-width: 768px) {
    .results-sidebar-enhanced {
        padding: 15px;
    }
    
    .sidebar-action-btn,
    .tool-button-display {
        font-size: 13px;
        padding: 10px 14px;
    }
}

/* Print styles - hide sidebar */
@media print {
    .results-sidebar-enhanced {
        display: none !important;
    }
}

/* ===========================================
   END ENHANCED SIDEBAR STYLES
   =========================================== */