/* ====== 수행평가 / 클래스 페이지 ====== */

.tasks-page{
    max-width: 720px;
  }
  
  /* 캘린더 카드 */
  .calendar-card{
    padding: 14px 14px 18px;
    background: #F8F8F8;
    border-radius: 10px;
  }
  
  .cal-head{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 8px;
  }
  
  .cal-title{
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.3px;
  }
  .cal-title #calYear{ opacity:.85; }
  
  .cal-nav{
    width: 40px; height: 40px;
    border: 0;
    background: none;
    cursor: pointer;
    font-size: 20px; line-height: 1;
    display: grid; place-items: center;
  }
  
  .cal-weekdays{
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    gap: 6px;
    padding: 8px 6px;
    color: #777;
    font-size: 12px;
  }
  
  .cal-grid{
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
    padding: 6px;
  }
  
  .cal-grid .pad{
    height: 44px;
  }
  
  .day{
    position: relative;
    height: 44px;
    border: 0;
    border-radius: 5px;
    background: none;
    cursor: pointer;
    display: grid;
    grid-template-rows: auto 1fr;
    align-items: start;
    text-align: center;
    padding: 6px 4px 4px;
    transition: filter .15s ease, background .15s ease;
  }
  .day:hover{ filter: brightness(.98); }
  .day.active{ background: #BDBDBD; }
  
  .day .num{
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
  }
  .day .dots{
    display: flex; gap: 3px; justify-content: center; align-items: center;
    margin-top: 4px;
  }
  
  /* 점(범례/달력공통) */
  .dot{
    width: 8px; height: 8px; border-radius: 50%;
    display: inline-block;
  }
  .dot.red{    background: #F56565; }
  .dot.yellow{ background: #F6C84C; }
  .dot.green{  background: #3CC59D; }
  .dot.blue{   background: #0D63ED; }
  
  /* 범례 */
  .legend{
    display: flex; flex-wrap: wrap; gap: 14px 18px; align-items: center;
    font-size: 14px; color: #666;
    margin: 10px 4px 14px;
  }
  .legend .dot{ margin-right: 6px; }
  
  /* 탭/정렬 바 */
  .toolbar{
    display: flex; align-items: center; justify-content: space-between;
    margin: 4px 2px 10px;
  }
  
  .seg{
    background: #FFF;
    border-radius: 10px;
    padding: 0px;
    display: inline-flex;
    gap: 2px;
    border:1px solid #0D63ED;
  }
  .seg-btn{
    min-width: 74px;
    padding: 8px 0px;
    border: 0; border-radius: 8px;
    background: transparent;
    cursor: pointer;
    font-size: 14px;
  }
  .seg-btn.active{
    background: #0D63ED; color: #fff;
  }
  
  .sort{
    display: inline-flex; align-items: center; gap: 6px;
    /* border:1px solid #DADDE3; border-radius: 10px; */
    border:0px;
    background: #fff; padding: 8px 12px; cursor: pointer;
    font-size: 14px; color: #444;
  }
  .sort .chev{ width: 10px; height: 10px; }
  
  /* 리스트 */
  .list-wrap{ margin-top: 4px; }
  .task-list{ list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
  
  .task-row{
    background: #F8F8FA;
    border-radius: 16px;
    padding: 14px 16px;
  }
  .task-row .tag{
    display: inline-block;
    font-size: 13px;
    margin-bottom: 6px;
    font-weight: 600;
  }
  .tag.red{    color: #F56565; }
  .tag.yellow{ color: #E6AD1F; }
  .tag.green{  color: #29B286; }
  .tag.blue{   color: #0D63ED; }
  
  .task-row .title{
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 4px;
  }
  .task-row .date{
    font-size: 14px; color: #666;
  }
  
  .task-list .empty{
    background: #fff;
    border: 1px dashed #DFE3EA;
    color: #888; text-align: center;
    border-radius: 10px; padding: 18px;
  }
  
  /* 플로팅 버튼 */
  .fab{
    position: fixed;
    right: 22px;
    bottom: calc(20px + env(safe-area-inset-bottom, 0px));
    width: 64px; height: 64px;
    border-radius: 50%;
    display: grid; place-items: center;
    text-decoration: none;
    background: #0D63ED; color: #fff;
    font-size: 44px; line-height: 1;
    box-shadow: 0 10px 24px rgba(13,99,237,.25);
  }
  
  /* 반응형 */
  @media (max-width: 420px){
    .day{ height: 42px; }
    .cal-weekdays{ font-size: 11px; }
    .task-row .title{ font-size: 17px; }
  }
  