.num-font {
      font-family: 'Montserrat', sans-serif;
    }
    .timetable-container {
      overflow-x: auto;
      -webkit-overflow-scrolling: touch;
      scrollbar-width: thin;
      scrollbar-color: rgba(156, 163, 175, 0.5) transparent;
    }
    .timetable-container::-webkit-scrollbar {
      height: 8px;
    }
    .timetable-container::-webkit-scrollbar-thumb {
      background-color: rgba(156, 163, 175, 0.5);
      border-radius: 4px;
    }
    .timetable-grid {
      display: grid;
      min-width: 800px; 
      
      grid-template-columns: 60px repeat(var(--loc-count, 1), minmax(180px, 1fr));
      
      grid-template-rows: 50px repeat(22, 40px);
      background-color: #e5e7eb;
      gap: 1px;
      border: 1px solid #e5e7eb;
    }
    .dark .timetable-grid {
      background-color: #334155;
      border-color: #334155;
    }
    .grid-header {
      background-color: #f8fafc;
      font-weight: 700;
      font-size: 0.875rem;
      text-align: center;
      padding: 12px 8px;
      position: sticky;
      top: 0;
      z-index: 10;
      display: flex;
      align-items: center;
      justify-content: center;
      letter-spacing: 0.1em;
      
      box-shadow: 1px 1px 0 0 #e5e7eb;
    }
    .grid-header.time-col {
      left: 0;
      z-index: 20; 
    }
    .dark .grid-header {
      background-color: #0f172a;
      color: #e2e8f0;
      box-shadow: 1px 1px 0 0 #334155;
    }
    .grid-time {
      background-color: #f8fafc;
      text-align: center;
      font-size: 0.75rem;
      color: #64748b;
      padding-top: 4px;
      position: sticky;
      left: 0;
      z-index: 5;
      font-family: 'Montserrat', sans-serif; 
      letter-spacing: 0.05em;
      
      box-shadow: 1px 1px 0 0 #e5e7eb;
    }
    .dark .grid-time {
      background-color: #0f172a;
      color: #94a3b8;
      box-shadow: 1px 1px 0 0 #334155;
    }
    .grid-cell {
      background-color: #ffffff;
      
      background-image: repeating-linear-gradient(
        -45deg,
        transparent,
        transparent 8px,
        rgba(226, 232, 240, 0.4) 8px,
        rgba(226, 232, 240, 0.4) 16px
      );
    }
    .dark .grid-cell {
      background-color: #1e293b;
      
      background-image: repeating-linear-gradient(
        -45deg,
        transparent,
        transparent 8px,
        rgba(51, 65, 85, 0.4) 8px,
        rgba(51, 65, 85, 0.4) 16px
      );
    }
    .grid-cell.hour-line {
      border-top: 1px dashed #94a3b8; 
    }
    .dark .grid-cell.hour-line {
      border-top: 1px dashed #64748b;
    }
    .grid-event {
      margin: 2px 4px;
      padding: 6px 8px;
      border-radius: 4px;
      font-size: 0.875rem;
      overflow: hidden;
      box-shadow: 0 1px 3px rgba(0,0,0,0.1);
      transition: all 0.2s;
      z-index: 2;
      cursor: pointer;
      display: flex;
      flex-direction: column;
      border-left: 4px solid rgba(255,255,255,0.3);
    }
    .grid-event:hover {
      transform: scale(1.02);
      z-index: 3;
      box-shadow: 0 4px 6px rgba(0,0,0,0.15);
    }
    .event-title {
      font-weight: 700;
      margin-bottom: 2px;
      line-height: 1.2;
      display: -webkit-box;
      -webkit-line-clamp: 2;
      -webkit-box-orient: vertical;
      overflow: hidden;
    }
    .event-time {
      font-size: 0.7rem;
      opacity: 0.9;
      font-family: 'Montserrat', sans-serif; 
      letter-spacing: 0.05em;
    }
