/* ============================================================
   دفتر التحضير - Stationery Theme & Custom Styling
============================================================ */

/* Smooth Base Rendering */
html {
  scroll-behavior: smooth;
}

/* Custom scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #f1ede4;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Hide scrollbar for step chips */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.animate-fade-in {
  animation: fadeIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.animate-scale-in {
  animation: scaleIn 0.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Stationery Document Paper Shadow & Texture */
.lesson-document {
  box-shadow: 0 4px 20px -2px rgba(26, 54, 93, 0.08), 0 2px 6px -1px rgba(0, 0, 0, 0.04);
  background-color: #ffffff;
}

/* Checkbox pill tag styling */
.pill-tag {
  cursor: pointer;
  user-select: none;
  transition: all 0.15s ease;
}
.pill-tag.selected {
  background-color: #1A365D !important;
  color: #ffffff !important;
  border-color: #1A365D !important;
}

/* ============================================================
   PRINT MEDIA STYLES - A4 Official Page Output
============================================================ */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 11pt;
    padding: 0 !important;
    margin: 0 !important;
  }

  .no-print,
  header,
  #tab-editor,
  #tab-library,
  #templates-modal,
  #toast {
    display: none !important;
  }

  #tab-preview {
    display: block !important;
  }

  .print-container-wrapper {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .lesson-document {
    border: none !important;
    box-shadow: none !important;
    max-width: 100% !important;
    width: 100% !important;
    padding: 10mm 12mm !important;
    margin: 0 !important;
  }

  .print-only {
    display: block !important;
  }

  /* Page break rules */
  table, tr, td, th, .border {
    page-break-inside: avoid;
  }

  @page {
    size: A4 portrait;
    margin: 8mm;
  }
}

.print-only {
  display: none;
}