.dashboard-student-grid .star-card-top span,.dashboard-student-grid .star-card-top b{display:none}.dashboard-student-grid .star-card-top:after{content:attr(data-rank);width:24px;height:24px;display:grid;place-items:center;border-radius:50%;background:#f2f1f7;color:#aaa8b3;font-size:11px;font-weight:900}.dashboard-student-grid .student-card:first-child .star-card-top:after{background:linear-gradient(145deg,#ffd767,#ffad42);color:#fff}.top-rank .rank-avatar{width:66px;height:66px;margin:auto;padding:4px;border:6px solid #f6e8ff;border-radius:50%;background:#fff;box-shadow:0 5px 15px rgba(150,100,190,.15);overflow:hidden}.top-rank.first .rank-avatar{width:82px;height:82px;border-color:#ffdda4}.top-rank .rank-avatar .avatar{width:100%;height:100%;border:0}.dashboard-student-grid .mini-badges span:after{content:"◎ " attr(data-coins);font-size:10px}
body[data-theme] .main-nav .nav-item.active,body[data-theme] .main-nav .nav-item:hover,body[data-theme] .sidebar-groups button.active{background:linear-gradient(135deg,var(--theme-2),var(--theme))!important;box-shadow:0 9px 20px var(--theme-shadow)!important}body[data-theme] .strawberry-logo{background:linear-gradient(145deg,var(--theme-2),var(--theme))!important}body[data-theme] .dashboard-student-grid .progress-track i{background:linear-gradient(90deg,var(--theme),var(--theme-2))!important}body[data-theme] .featured-info p b,body[data-theme] .featured-score strong,body[data-theme] .top-rank span,body[data-theme] .side-rank-row b:last-child{color:var(--theme)!important}
@media(min-width:1451px){.dashboard-view{grid-template-columns:230px minmax(0,1fr) 410px}.right-panel{align-self:start;grid-template-rows:540px 170px}.dashboard-student-grid{max-height:416px;overflow-y:auto;overscroll-behavior:contain;padding-right:5px;scrollbar-width:thin;scrollbar-color:#f4c9d8 transparent}.dashboard-student-grid::-webkit-scrollbar{width:5px}.dashboard-student-grid::-webkit-scrollbar-thumb{background:#f4c9d8;border-radius:999px}}
.strawberry-logo{padding:0;overflow:hidden}.strawberry-logo img{width:100%;height:100%;object-fit:contain}.class-mode{display:flex;align-items:center;gap:7px}.class-mode svg,.main-nav svg{width:20px;height:20px;flex:none}.main-nav .nav-item{display:flex;align-items:center;justify-content:center;gap:7px}.dashboard-search svg{position:absolute;right:16px;top:12px;width:19px;height:19px}.notice-button{display:grid;place-items:center}.notice-button svg{width:25px;height:25px}.teacher-avatar{padding:3px;overflow:hidden}.teacher-avatar img{width:100%;height:100%;object-fit:cover;border-radius:50%}.summary-mascot{padding:3px}.summary-mascot img{width:100%;height:100%;object-fit:contain}.sidebar-groups button span svg{width:23px;height:23px}.school-illustration{padding:5px;background:transparent}.school-illustration img{width:100%;max-height:150px;object-fit:contain}.featured-avatar-area:before{display:none}.featured-crown{position:absolute;z-index:5;top:-1px;left:50%;width:70px;height:58px;object-fit:contain;transform:translateX(-70%) rotate(-9deg)}.featured-avatar .generated-avatar,.rank-avatar .generated-avatar,.dashboard-student-grid .generated-avatar{width:100%;height:100%;object-fit:contain}.featured-tags span{display:flex;align-items:center;gap:5px}.featured-tags svg{width:17px;height:17px}.score-platform{display:none}.score-platform-img{display:block;width:180px;height:75px;margin:8px auto 0;object-fit:contain}.widget-title h3{display:flex;align-items:center;gap:6px}.widget-title h3 svg{width:22px;height:22px}.energy-gauge>img{position:absolute;left:23px;bottom:-4px;width:60px;height:60px;object-fit:contain}.energy-gauge>span{display:none}.dashboard-student-grid .avatar{background:linear-gradient(145deg,#fff,#fff4f7)!important}.dashboard-student-grid .generated-avatar{transform:scale(1.05)}.rank-avatar .generated-avatar{transform:scale(1.08)}.student-profile .generated-avatar{width:100%;height:100%;object-fit:contain}
.student-section-head h2,.daily-tip{display:flex;align-items:center;gap:7px}.student-section-head h2 svg{width:24px;height:24px}.daily-tip svg{width:18px;height:18px;flex:none}
.gauge-arc{
  border:0;
  background:conic-gradient(from 270deg at 50% 100%,#bf52ef 0deg 91.8deg,#f1e1f5 91.8deg 180deg,transparent 180deg 360deg);
  -webkit-mask:radial-gradient(circle at 50% 100%,transparent 0 71px,#000 72px 89px,transparent 90px);
  mask:radial-gradient(circle at 50% 100%,transparent 0 71px,#000 72px 89px,transparent 90px);
}
.gauge-arc:after{display:none}

/* Student-stage layout: keep the side information compact and give the class grid priority. */
@media(min-width:1121px){
  .dashboard-main{padding:20px 22px 28px}
  .dashboard-view{
    max-width:1800px;
    grid-template-columns:150px minmax(0,1fr) 250px;
    align-items:start;
    gap:16px;
  }
  .left-panel,.right-panel{
    position:sticky;
    top:118px;
    align-self:start;
    height:max-content;
    min-height:0;
  }
  .left-panel{
    overflow:hidden;
    border:1px solid rgba(255,226,236,.72);
    border-radius:22px;
    background:linear-gradient(180deg,#fff6fa 0%,#fff 63%,#fff9f2 100%);
    box-shadow:0 12px 28px rgba(226,159,183,.11);
  }
  .class-summary{padding:22px 10px 15px}
  .summary-mascot{width:68px;height:68px;margin-bottom:10px}
  .class-summary strong{margin:6px 0 2px;font-size:35px}
  .class-summary p{margin:7px 0 0;font-size:10px}
  .sidebar-groups{gap:7px;padding:0 9px 12px}
  .sidebar-groups button{
    height:43px;
    grid-template-columns:25px 1fr auto;
    padding:0 13px;
    font-size:12px;
  }
  .sidebar-groups button span svg{width:19px;height:19px}
  .school-illustration{
    position:relative;
    inset:auto;
    display:flex;
    min-height:102px;
    margin:1px 6px 7px;
    padding:2px 3px 5px;
  }
  .school-illustration img{width:100%;max-height:105px}
  .right-panel{
    display:flex;
    flex-direction:column;
    gap:14px;
  }
  .ranking-widget,.energy-widget{
    flex:none;
    padding:14px;
    border-radius:17px;
    box-shadow:0 10px 25px rgba(218,169,187,.11);
  }
  .widget-title h3{font-size:15px}
  .widget-title h3 svg{width:19px;height:19px}
  .top-three{gap:2px;margin:15px 0 13px}
  .top-rank .rank-avatar{width:52px;height:52px;border-width:4px}
  .top-rank.first .rank-avatar{width:65px;height:65px}
  .top-rank b{margin-top:5px;font-size:11px}
  .top-rank span{font-size:12px}
  .side-ranking{gap:4px}
  .side-rank-row{height:25px;padding:0 8px;font-size:10px}
  .energy-widget{padding:13px 14px 14px;overflow:hidden}
  .energy-gauge{height:72px}
  .gauge-arc{
    top:3px;
    width:150px;
    height:75px;
    transform:none;
    -webkit-mask:radial-gradient(circle at 50% 100%,transparent 0 58px,#000 59px 74px,transparent 75px);
    mask:radial-gradient(circle at 50% 100%,transparent 0 58px,#000 59px 74px,transparent 75px);
  }
  .energy-gauge strong{font-size:24px}
  .energy-gauge small{font-size:10px}
  .energy-gauge>img{left:10px;bottom:-1px;width:46px;height:46px}
  .energy-bottom{gap:7px}
  .energy-bottom p{margin:0;line-height:1.35;font-size:9px}
  .energy-bottom button{flex:none;padding:7px 12px;white-space:nowrap;font-size:10px}

  .featured-student{
    height:150px;
    grid-template-columns:165px minmax(0,1fr) 175px;
    border-radius:19px;
  }
  .featured-avatar{width:112px;height:112px;padding:5px;box-shadow:0 0 0 7px #fff1f5,0 10px 24px rgba(255,105,153,.22)}
  .featured-crown{top:0;width:55px;height:45px}
  .featured-info h2{margin-bottom:7px;font-size:22px}
  .featured-info p{margin:0;font-size:13px}
  .featured-tags{gap:7px;margin-top:12px}
  .featured-tags span{padding:6px 9px;font-size:10px}
  .featured-tags svg{width:14px;height:14px}
  .featured-score strong{font-size:48px}
  .featured-score span{font-size:12px}
  .score-platform-img{width:128px;height:48px;margin:2px auto 0}
  .student-section-head{margin:15px 3px 11px}
  .student-section-head h2{font-size:19px}
  .student-controls select,.student-controls button{height:36px}

  .dashboard-student-grid{
    max-height:none;
    overflow:visible;
    padding-right:0;
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:14px!important;
  }
  .dashboard-student-grid .student-card{
    min-height:225px!important;
    padding:17px 13px 12px!important;
    border:1px solid rgba(249,211,224,.78)!important;
    border-radius:21px!important;
    background:
      radial-gradient(circle at 88% 10%,rgba(255,224,235,.8) 0 3px,transparent 4px),
      radial-gradient(circle at 80% 18%,rgba(255,239,185,.75) 0 2px,transparent 3px),
      linear-gradient(155deg,#fff 0%,#fffafd 56%,#fff7f1 100%)!important;
    box-shadow:0 8px 20px rgba(192,142,162,.11),inset 0 0 0 1px rgba(255,255,255,.72)!important;
    transition:transform .2s ease,box-shadow .2s ease,border-color .2s ease!important;
  }
  .dashboard-student-grid .student-card:hover{
    transform:translateY(-4px)!important;
    border-color:#ffc8da!important;
    box-shadow:0 16px 30px rgba(221,132,167,.18),inset 0 0 0 1px #fff!important;
  }
  .dashboard-student-grid .star-card-top{left:10px;top:9px}
  .dashboard-student-grid .star-card-top:after{
    width:25px;height:25px;
    box-shadow:0 3px 8px rgba(120,100,110,.08);
  }
  .dashboard-student-grid .avatar-wrap{
    float:none;
    width:92px!important;
    height:92px!important;
    margin:1px auto 7px!important;
    padding:4px!important;
    background:linear-gradient(145deg,#ffb5cf,#ffe6ef 46%,#fff)!important;
    box-shadow:0 0 0 4px rgba(255,235,242,.9),0 8px 17px rgba(230,129,165,.15)!important;
  }
  .dashboard-student-grid .generated-avatar{transform:scale(1.08)}
  .dashboard-student-grid h3{
    margin:7px 0 4px!important;
    text-align:center;
    color:#38252c;
    font-size:16px!important;
  }
  .dashboard-student-grid .honor-title{
    display:block;
    width:max-content;
    max-width:100%;
    margin:0 auto 6px!important;
    padding:3px 8px!important;
    overflow:hidden;
    color:#d04e7d;
    font-size:9px!important;
    text-overflow:ellipsis;
    white-space:nowrap;
  }
  .dashboard-student-grid .score-line{
    clear:none;
    justify-content:space-between!important;
    align-items:baseline;
    gap:5px!important;
    padding-top:1px;
    font-size:9px!important;
  }
  .dashboard-student-grid .score-line b{color:#ee5488!important;font-size:22px!important}
  .dashboard-student-grid .progress-track{height:7px!important;margin:7px 0 7px!important}
  .dashboard-student-grid .mini-badges{min-height:24px;padding-top:6px!important}
  .dashboard-student-grid .mini-badges i{width:18px;height:18px}
  .dashboard-student-grid .mini-badges span:after{font-size:9px}
  .daily-tip{margin-top:18px;margin-bottom:2px}
}

@media(min-width:1300px) and (max-width:1599px){
  .dashboard-student-grid{grid-template-columns:repeat(5,minmax(0,1fr))!important}
  .dashboard-student-grid .student-card{padding-inline:10px!important}
  .dashboard-student-grid .avatar-wrap{width:88px!important;height:88px!important}
}

@media(min-width:1451px){
  .dashboard-view{grid-template-columns:155px minmax(0,1fr) 270px;gap:18px}
}

@media(min-width:1600px){
  .dashboard-view{grid-template-columns:160px minmax(0,1fr) 280px}
  .dashboard-student-grid{grid-template-columns:repeat(6,minmax(0,1fr))!important}
}

/* Theme-aware classroom atmosphere inspired by the original points site. */
html{background:var(--theme-page,#fff7fb)}
body{
  background-color:var(--theme-page,#fff7fb)!important;
  background-image:
    radial-gradient(circle at 8% 24%,var(--theme-glow) 0,transparent 32%),
    radial-gradient(circle at 92% 18%,var(--theme-glow-2) 0,transparent 28%),
    radial-gradient(circle at 82% 78%,var(--theme-glow) 0,transparent 34%),
    radial-gradient(circle at 18% 82%,var(--theme-soft-2) 0,transparent 22%),
    linear-gradient(180deg,#fff 0,#fff 92px,var(--theme-page) 210px,var(--theme-soft) 68%,var(--theme-page) 100%)!important;
  background-attachment:scroll;
  background-repeat:no-repeat;
  background-size:100% 100%;
}
.dashboard-app{
  min-height:100vh;
  background:
    linear-gradient(180deg,rgba(255,255,255,.3) 0,transparent 250px),
    transparent!important;
}
.dashboard-main{position:relative}
.dashboard-main:before,.dashboard-main:after{
  content:"";
  position:fixed;
  z-index:0;
  width:300px;
  height:300px;
  border-radius:50%;
  filter:blur(2px);
  pointer-events:none;
  opacity:.42;
}
.dashboard-main:before{
  left:-155px;
  top:34vh;
  background:radial-gradient(circle,var(--theme-glow),transparent 70%);
}
.dashboard-main:after{
  right:-145px;
  bottom:-75px;
  background:radial-gradient(circle,var(--theme-glow-2),transparent 70%);
}
.dashboard-view,.overlay-page{position:relative;z-index:1}
.left-panel,.featured-student,.ranking-widget,.energy-widget,.dashboard-student-grid .student-card{
  backdrop-filter:blur(10px);
  -webkit-backdrop-filter:blur(10px);
}
.left-panel,.ranking-widget,.energy-widget{
  background-color:rgba(255,255,255,.88);
}
.featured-student{
  background:
    radial-gradient(circle at 88% 16%,var(--theme-soft-2) 0,transparent 25%),
    linear-gradient(110deg,rgba(255,255,255,.95),var(--theme-soft) 55%,rgba(255,255,255,.9));
}

/* Layered collectible-card finish for student cards only. */
.dashboard-student-grid .growth-star-card{
  isolation:isolate;
  border:2px solid var(--theme-border)!important;
  background:
    radial-gradient(circle at 86% 10%,var(--theme-soft-2) 0 4px,transparent 5px),
    radial-gradient(circle at 78% 19%,rgba(255,236,176,.68) 0 2px,transparent 3px),
    linear-gradient(152deg,rgba(255,255,255,.98) 0%,var(--theme-soft) 58%,rgba(255,255,255,.94) 100%)!important;
  box-shadow:
    0 2px 0 rgba(255,255,255,.95) inset,
    0 0 0 5px var(--theme-soft-2),
    0 14px 30px var(--theme-shadow),
    0 24px 46px rgba(120,72,92,.08)!important;
}
.dashboard-student-grid .growth-star-card:nth-child(n){
  border-color:var(--theme-border)!important;
}
.dashboard-student-grid .growth-star-card::before{
  content:"";
  position:absolute;
  inset:7px;
  z-index:0;
  border:1px solid rgba(255,255,255,.82);
  border-radius:17px;
  background:
    linear-gradient(180deg,rgba(255,255,255,.62),transparent 42%),
    radial-gradient(circle at 50% 0,var(--theme-soft-2),transparent 58%);
  pointer-events:none;
}
.dashboard-student-grid .growth-star-card::after{
  content:"";
  position:absolute;
  left:18px;
  right:18px;
  bottom:9px;
  z-index:-1;
  height:24px;
  border-radius:999px;
  background:var(--theme);
  filter:blur(18px);
  opacity:.16;
  pointer-events:none;
}
.dashboard-student-grid .growth-star-card>*{
  position:relative;
  z-index:1;
}
.dashboard-student-grid .growth-star-card:hover{
  border-color:var(--theme-2)!important;
  box-shadow:
    0 2px 0 rgba(255,255,255,.98) inset,
    0 0 0 6px var(--theme-soft-2),
    0 18px 38px var(--theme-shadow),
    0 30px 54px rgba(120,72,92,.1)!important;
}
.dashboard-student-grid .growth-star-card .star-card-top{
  z-index:3;
}
.dashboard-student-grid .growth-star-card .star-card-top::after,
.dashboard-student-grid .growth-star-card:first-child .star-card-top::after{
  color:#fff;
  border:1px solid rgba(255,255,255,.85);
  background:linear-gradient(145deg,var(--theme-2),var(--theme))!important;
  box-shadow:
    0 0 0 4px var(--theme-soft),
    0 9px 18px var(--theme-shadow)!important;
}
.dashboard-student-grid .growth-star-card .avatar-wrap{
  background:
    linear-gradient(#fff,#fff) padding-box,
    conic-gradient(from 210deg,var(--theme),var(--theme-2),var(--theme-soft-2),var(--theme),var(--theme-2)) border-box!important;
  border:5px solid transparent;
  box-shadow:
    0 0 0 5px rgba(255,255,255,.9),
    0 0 0 9px var(--theme-soft),
    0 13px 26px var(--theme-shadow),
    inset 0 2px 4px rgba(255,255,255,.85)!important;
}
.dashboard-student-grid .growth-star-card .avatar{
  border:4px solid #fff!important;
  background:
    radial-gradient(circle at 50% 18%,#fff 0,rgba(255,255,255,.92) 44%,var(--theme-soft) 100%)!important;
  box-shadow:inset 0 -8px 14px rgba(148,93,117,.06);
}
.dashboard-student-grid .growth-star-card .level-chip,
.dashboard-student-grid .growth-star-card .honor-title{
  border-color:var(--theme-border)!important;
  background:linear-gradient(180deg,#fff,var(--theme-soft))!important;
  color:var(--theme-text)!important;
  box-shadow:0 5px 12px var(--theme-shadow);
}
.dashboard-student-grid .growth-star-card h3{
  color:#38252c;
  text-shadow:0 1px 0 rgba(255,255,255,.9);
}
.dashboard-student-grid .growth-star-card .score-line b{
  color:var(--theme)!important;
}
.dashboard-student-grid .growth-star-card .progress-track{
  background:rgba(226,232,240,.62)!important;
  box-shadow:inset 0 1px 3px rgba(100,116,139,.13);
}
.dashboard-student-grid .growth-star-card .progress-track i{
  background:linear-gradient(90deg,var(--theme),var(--theme-2))!important;
  box-shadow:0 0 10px var(--theme-shadow)!important;
}
.dashboard-student-grid .growth-star-card .mini-badges i{
  border:1px solid var(--theme-border);
  background:linear-gradient(180deg,#fff,var(--theme-soft));
  color:var(--theme);
  box-shadow:0 4px 10px var(--theme-shadow);
}
.dashboard-student-grid .growth-star-card .mini-badges span::after{
  color:var(--theme-text);
}

/* Remove deleted widget gaps and make the remaining classroom chrome follow the active theme. */
.right-panel{
  grid-template-rows:auto!important;
}
.ranking-widget{
  height:max-content;
}
.dashboard-header svg,
#classroom svg,
.daily-tip svg{
  color:var(--theme)!important;
}
.dashboard-header svg [fill]:not([fill="none"]),
#classroom svg [fill]:not([fill="none"]),
.daily-tip svg [fill]:not([fill="none"]){
  fill:currentColor!important;
}
.dashboard-header svg [stroke],
#classroom svg [stroke],
.daily-tip svg [stroke]{
  stroke:currentColor!important;
}
.dashboard-header svg [fill="none"],
#classroom svg [fill="none"],
.daily-tip svg [fill="none"]{
  fill:none!important;
}
.dashboard-header{
  border-bottom-color:var(--theme-border)!important;
  box-shadow:0 9px 28px var(--theme-shadow)!important;
}
.class-mode,
.dashboard-search input,
.notice-button{
  border-color:var(--theme-border)!important;
  background:var(--theme-soft)!important;
  color:var(--theme-text)!important;
}
.dashboard-search input::placeholder{
  color:color-mix(in srgb,var(--theme-text) 48%,#94a3b8);
}
.notice-button{
  box-shadow:0 5px 14px var(--theme-shadow)!important;
}
.left-panel{
  border-color:var(--theme-border)!important;
  background:linear-gradient(180deg,var(--theme-soft) 0%,rgba(255,255,255,.92) 63%,var(--theme-page) 100%)!important;
  box-shadow:0 12px 28px var(--theme-shadow)!important;
}
.summary-mascot{
  background:radial-gradient(circle,#fff 30%,var(--theme-soft-2))!important;
  box-shadow:0 7px 18px var(--theme-shadow)!important;
}
.class-summary strong small{
  color:var(--theme-text)!important;
}
.sidebar-groups button{
  color:var(--theme-text)!important;
}

/* Starlight class plate: the sidebar uses data and atmosphere instead of mascot art. */
.left-panel{
  isolation:isolate;
  background:
    radial-gradient(circle at 18% 7%,var(--theme-glow) 0,transparent 27%),
    radial-gradient(circle at 90% 34%,var(--theme-glow-2) 0,transparent 32%),
    linear-gradient(180deg,rgba(255,255,255,.95),var(--theme-soft) 54%,rgba(255,255,255,.9))!important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.95),0 14px 32px var(--theme-shadow)!important;
}

.left-panel::before,
.left-panel::after{
  content:"";
  position:absolute;
  z-index:-1;
  border-radius:50%;
  pointer-events:none;
}

.left-panel::before{
  width:120px;
  height:120px;
  right:-54px;
  top:76px;
  border:1px solid color-mix(in srgb,var(--theme-border) 58%,transparent);
  box-shadow:0 0 0 17px color-mix(in srgb,var(--theme-soft-2) 33%,transparent);
}

.left-panel::after{
  width:6px;
  height:6px;
  left:18px;
  top:26px;
  background:var(--theme-2);
  box-shadow:20px 14px 0 -1px var(--theme-border),101px 6px 0 -1px var(--theme-2),112px 29px 0 -2px var(--theme-border);
  opacity:.72;
}

.class-summary{
  position:relative;
  padding:24px 12px 18px!important;
  text-align:center;
}

.summary-heading{
  display:grid;
  justify-items:center;
  gap:5px;
}

.summary-heading span{
  color:var(--theme)!important;
  font-size:7px;
  font-weight:950;
  letter-spacing:.19em;
}

.summary-heading b{
  color:#433139;
  font-size:13px;
  font-weight:950;
}

.class-summary strong{
  margin:10px 0 5px!important;
  color:var(--theme-text)!important;
  font-size:38px!important;
  font-variant-numeric:tabular-nums;
  letter-spacing:-.05em;
  text-shadow:0 5px 16px var(--theme-shadow);
}

.class-summary strong small{
  margin-left:5px!important;
  font-size:12px!important;
  letter-spacing:0;
}

.summary-divider{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  margin:5px auto 7px;
}

.summary-divider i{
  width:27px;
  height:1px;
  background:linear-gradient(90deg,transparent,var(--theme-border));
}

.summary-divider i:last-child{transform:scaleX(-1)}
.summary-divider svg{width:11px;height:11px;color:var(--theme)}

.class-summary p{
  margin:0!important;
  color:#8790a6!important;
  font-size:9px!important;
  font-weight:700;
  white-space:nowrap;
}

.sidebar-groups{
  position:relative;
  z-index:1;
}

.sidebar-groups button{
  border:1px solid rgba(255,255,255,.86)!important;
  background:rgba(255,255,255,.72)!important;
  box-shadow:0 4px 12px rgba(71,38,50,.035)!important;
}

.sidebar-groups button:hover{
  border-color:var(--theme-border)!important;
  background:rgba(255,255,255,.96)!important;
  transform:translateY(-1px);
}

.sidebar-groups button.active{
  border-color:transparent!important;
  color:#fff!important;
  background:linear-gradient(135deg,var(--theme-2),var(--theme))!important;
  box-shadow:0 9px 20px var(--theme-shadow)!important;
}

.class-growth-card{
  position:relative;
  z-index:1;
  margin:8px 9px 10px;
  padding:12px 10px 10px;
  overflow:hidden;
  border:1px solid color-mix(in srgb,var(--theme-border) 78%,white);
  border-radius:17px;
  background:linear-gradient(145deg,rgba(255,255,255,.94),color-mix(in srgb,var(--theme-soft) 72%,white));
  box-shadow:inset 0 1px 0 #fff,0 8px 20px color-mix(in srgb,var(--theme-shadow) 62%,transparent);
}

.class-growth-card::after{
  content:"✦";
  position:absolute;
  right:-2px;
  top:-14px;
  color:var(--theme-2);
  font-size:52px;
  opacity:.09;
  transform:rotate(15deg);
}

.growth-card-head{
  display:flex;
  align-items:center;
  gap:7px;
  color:var(--theme-text);
  font-size:10px;
}

.growth-card-head span{
  width:24px;
  height:24px;
  display:grid;
  place-items:center;
  border-radius:9px;
  color:#fff;
  background:linear-gradient(135deg,var(--theme-2),var(--theme));
  box-shadow:0 5px 12px var(--theme-shadow);
}

.growth-card-head svg{width:13px;height:13px}

.growth-card-stats{
  display:grid;
  grid-template-columns:1fr 1px 1fr;
  align-items:center;
  margin-top:11px;
}

.growth-card-stats>div{display:grid;justify-items:center;gap:2px}
.growth-card-stats>i{width:1px;height:27px;background:var(--theme-border)}
.growth-card-stats strong{color:#382c31;font-size:16px;font-weight:950;font-variant-numeric:tabular-nums}
.growth-card-stats small{color:#9ba2b1;font-size:7px;font-weight:800}

.class-growth-card p{
  margin:9px 0 0;
  padding-top:8px;
  border-top:1px dashed var(--theme-border);
  color:#8c91a1;
  font-size:7px;
  font-weight:700;
  text-align:center;
  white-space:nowrap;
}

.class-growth-card.is-empty .growth-card-stats strong{color:#b6bac5}

@media(max-width:760px){
  .class-growth-card{display:none}
}
.student-section-head{
  margin-top:0!important;
}
.student-section-head h2,
.daily-tip{
  color:var(--theme-text)!important;
}
.student-controls select,
.student-controls button{
  border-color:var(--theme-border)!important;
  background:rgba(255,255,255,.92)!important;
  color:var(--theme-text)!important;
  box-shadow:0 5px 14px var(--theme-shadow)!important;
}
.daily-tip{
  border-color:var(--theme-border)!important;
  background:linear-gradient(135deg,#fff,var(--theme-soft))!important;
  box-shadow:0 6px 16px var(--theme-shadow)!important;
}
.ranking-widget{
  border-color:var(--theme-border)!important;
  box-shadow:0 11px 26px var(--theme-shadow)!important;
}
.widget-title h3{
  color:var(--theme-text)!important;
}
.widget-title button,
.widget-title span{
  color:var(--theme-text)!important;
}
.top-rank .rank-avatar{
  border-color:var(--theme-soft-2)!important;
  box-shadow:0 5px 15px var(--theme-shadow)!important;
}
.top-rank.first .rank-avatar{
  border-color:var(--theme-border)!important;
}
.top-rank span,
.side-rank-row b:last-child{
  color:var(--theme)!important;
}
.side-rank-row{
  background:var(--theme-soft)!important;
}
.batch-bar .score-main{
  background:linear-gradient(135deg,var(--theme),var(--theme-2))!important;
  box-shadow:0 7px 17px var(--theme-shadow)!important;
}

@media(min-width:1121px){
  .right-panel{
    gap:0!important;
  }
  .ranking-widget{
    padding:14px!important;
  }
}

/* Reference-style pet-card shell: simple thick border, soft tinted surface, same-color shadow. */
.dashboard-student-grid .growth-star-card{
  border:2px solid var(--theme-border)!important;
  border-radius:24px!important;
  background:
    linear-gradient(180deg,var(--theme-soft) 0%,var(--theme-soft) 100%)!important;
  box-shadow:
    0 10px 15px -3px var(--theme-border),
    0 4px 6px -4px var(--theme-border)!important;
  overflow:hidden!important;
}
.dashboard-student-grid .growth-star-card::before{
  content:none!important;
}
.dashboard-student-grid .growth-star-card::after{
  content:none!important;
}
.dashboard-student-grid .growth-star-card:hover{
  border-color:var(--theme-border)!important;
  transform:translateY(-4px)!important;
  box-shadow:
    0 18px 24px -8px var(--theme-border),
    0 8px 12px -8px var(--theme-border)!important;
}
.dashboard-student-grid .growth-star-card .star-card-top::after,
.dashboard-student-grid .growth-star-card:first-child .star-card-top::after{
  color:var(--theme-text)!important;
  border:1px solid rgba(255,255,255,.5)!important;
  background:rgba(255,255,255,.8)!important;
  box-shadow:0 1px 2px rgba(0,0,0,.05)!important;
  backdrop-filter:blur(10px);
  -webkit-backdrop-filter:blur(10px);
}
.dashboard-student-grid .growth-star-card .avatar-wrap{
  border:0!important;
  padding:0!important;
  background:transparent!important;
  box-shadow:none!important;
}
.dashboard-student-grid .growth-star-card .avatar{
  border:0!important;
  background:transparent!important;
  box-shadow:none!important;
}
.dashboard-student-grid .growth-star-card .level-chip{
  display:none!important;
}
.dashboard-student-grid .growth-star-card .honor-title{
  border:1px solid rgba(255,255,255,.5)!important;
  background:rgba(255,255,255,.78)!important;
  color:var(--theme-text)!important;
  box-shadow:0 1px 2px rgba(0,0,0,.05)!important;
  backdrop-filter:blur(10px);
  -webkit-backdrop-filter:blur(10px);
}
.dashboard-student-grid .growth-star-card .progress-track{
  height:8px!important;
  background:rgba(255,255,255,.68)!important;
  box-shadow:inset 0 1px 2px rgba(100,116,139,.08)!important;
}
.dashboard-student-grid .growth-star-card .mini-badges i{
  border:1px solid rgba(255,255,255,.5)!important;
  background:rgba(255,255,255,.78)!important;
  box-shadow:0 1px 2px rgba(0,0,0,.05)!important;
}

/* Top taskbar styles moved to topbar.css. */
/* Batch mode polish: themed selection marks and action buttons. */
body.batch-mode .dashboard-student-grid .growth-star-card .select-mark{
  display:grid!important;
  position:absolute!important;
  top:auto!important;
  bottom:16px!important;
  left:auto!important;
  right:14px!important;
  z-index:6!important;
  width:34px!important;
  height:34px!important;
  place-items:center!important;
  border:2px solid var(--theme-border)!important;
  border-radius:999px!important;
  background:rgba(255,255,255,.92)!important;
  color:transparent!important;
  box-shadow:0 6px 14px var(--theme-shadow),inset 0 0 0 4px rgba(255,255,255,.55)!important;
  font-size:17px!important;
  font-weight:950!important;
  transition:transform .18s ease,background .18s ease,border-color .18s ease,box-shadow .18s ease!important;
}
body.batch-mode .dashboard-student-grid .growth-star-card .star-card-top{
  z-index:4!important;
}
body.batch-mode .dashboard-student-grid .growth-star-card .star-card-top::after,
body.batch-mode .dashboard-student-grid .growth-star-card:first-child .star-card-top::after{
  box-shadow:0 5px 12px rgba(15,23,42,.08)!important;
}
body.batch-mode .dashboard-student-grid .growth-star-card.selected{
  border-color:var(--theme)!important;
  outline:0!important;
  transform:translateY(-3px)!important;
  box-shadow:0 18px 26px -10px var(--theme-shadow),0 0 0 4px var(--theme-soft-2)!important;
}
body.batch-mode .dashboard-student-grid .growth-star-card.selected .select-mark{
  border-color:transparent!important;
  background:linear-gradient(135deg,var(--theme-2),var(--theme))!important;
  color:#fff!important;
  transform:scale(1.08)!important;
  box-shadow:0 9px 18px var(--theme-shadow),0 0 0 5px var(--theme-soft-2)!important;
}
.batch-bar{
  border-color:var(--theme-border)!important;
  background:linear-gradient(135deg,rgba(255,255,255,.98),var(--theme-soft) 58%,rgba(255,255,255,.95))!important;
  box-shadow:0 -14px 30px var(--theme-shadow)!important;
}
.batch-bar button{
  min-height:42px!important;
  border:1px solid var(--theme-border)!important;
  border-radius:16px!important;
  background:linear-gradient(180deg,#fff,var(--theme-soft))!important;
  color:var(--theme-text)!important;
  box-shadow:0 5px 12px rgba(15,23,42,.06)!important;
  font-weight:950!important;
  transition:transform .16s ease,box-shadow .16s ease,background .16s ease,color .16s ease,border-color .16s ease!important;
}
.batch-bar button:hover,
.batch-bar button:focus-visible{
  transform:translateY(-2px)!important;
  border-color:var(--theme)!important;
  box-shadow:0 10px 18px var(--theme-shadow),0 0 0 3px var(--theme-soft-2)!important;
  outline:0!important;
}
.batch-bar button:active,
.batch-bar button.batch-active,
.batch-bar button.batch-pulse{
  transform:translateY(0) scale(.97)!important;
}
.batch-bar button.is-active,
.batch-bar .danger-soft,
.batch-bar .score-main{
  border-color:transparent!important;
  background:linear-gradient(135deg,var(--theme-2),var(--theme))!important;
  color:#fff!important;
  box-shadow:0 10px 22px var(--theme-shadow)!important;
}
.batch-bar .danger-soft.batch-active,
.batch-bar .score-main.batch-active{
  filter:saturate(1.18) brightness(.98)!important;
  box-shadow:0 0 0 4px var(--theme-soft-2),0 12px 24px var(--theme-shadow)!important;
}
.batch-bar button.batch-shake{
  animation:batchShake .38s ease both;
  border-color:var(--theme)!important;
  box-shadow:0 0 0 4px var(--theme-soft-2),0 10px 20px var(--theme-shadow)!important;
}
@keyframes batchShake{
  0%,100%{transform:translateX(0)}
  20%{transform:translateX(-5px)}
  40%{transform:translateX(5px)}
  60%{transform:translateX(-3px)}
  80%{transform:translateX(3px)}
}

/* Score feedback: pressed option, card glow, floating score, and number pop. */
.score-option{
  position:relative!important;
  overflow:hidden!important;
  transition:transform .16s ease,box-shadow .16s ease,border-color .16s ease,background .16s ease,opacity .16s ease!important;
}
.score-option::after{
  content:"";
  position:absolute;
  inset:0;
  border-radius:inherit;
  background:radial-gradient(circle at 50% 50%,rgba(255,255,255,.92),transparent 58%);
  opacity:0;
  transform:scale(.35);
  pointer-events:none;
}
.score-option:hover,
.score-option:focus-visible{
  transform:translateY(-2px)!important;
  border-color:var(--theme)!important;
  box-shadow:0 12px 24px var(--theme-shadow),0 0 0 4px var(--theme-soft-2)!important;
  outline:0!important;
}
.score-option:active,
.score-option.score-option-picked{
  transform:translateY(1px) scale(.97)!important;
  border-color:var(--theme)!important;
  background:linear-gradient(135deg,var(--theme-soft),rgba(255,255,255,.96))!important;
  box-shadow:inset 0 2px 8px rgba(15,23,42,.08),0 0 0 5px var(--theme-soft-2)!important;
}
.score-option.score-option-picked::after{
  animation:scoreRipple .42s ease-out both;
}
.score-option.score-option-picked b{
  animation:scoreBadgePop .35s ease both;
}
.dashboard-student-grid .growth-star-card{
  position:relative!important;
}
.dashboard-student-grid .growth-star-card.score-fx-card{
  animation:scoreCardLift .88s cubic-bezier(.2,.9,.2,1) both;
}
.dashboard-student-grid .growth-star-card.score-fx-positive{
  border-color:var(--theme)!important;
  box-shadow:0 18px 34px -14px var(--theme-shadow),0 0 0 5px var(--theme-soft-2),inset 0 1px 0 rgba(255,255,255,.95)!important;
}
.dashboard-student-grid .growth-star-card.score-fx-negative{
  border-color:#fb7185!important;
  box-shadow:0 18px 34px -14px rgba(244,63,94,.28),0 0 0 5px rgba(251,113,133,.14),inset 0 1px 0 rgba(255,255,255,.95)!important;
}
.score-float{
  --fx-delay:0s;
  position:absolute;
  top:88px;
  right:26px;
  z-index:20;
  min-width:64px;
  padding:7px 13px 8px;
  border-radius:999px;
  color:#fff;
  font-size:24px;
  font-weight:1000;
  line-height:1;
  letter-spacing:.02em;
  text-align:center;
  pointer-events:none;
  transform:translate3d(0,0,0) scale(.72);
  opacity:0;
  animation:scoreFloatUp 1.18s cubic-bezier(.18,.9,.2,1) var(--fx-delay) both;
}
.score-float::before,
.score-float::after{
  content:"✦";
  position:absolute;
  color:inherit;
  font-size:13px;
  text-shadow:0 2px 8px rgba(255,255,255,.75);
}
.score-float::before{
  left:-12px;
  top:-8px;
}
.score-float::after{
  right:-10px;
  bottom:-8px;
  font-size:10px;
}
.score-float-positive{
  background:linear-gradient(135deg,var(--theme-2),var(--theme));
  box-shadow:0 12px 22px var(--theme-shadow),0 0 0 5px var(--theme-soft-2);
}
.score-float-negative{
  background:linear-gradient(135deg,#fb7185,#f43f5e);
  box-shadow:0 12px 22px rgba(244,63,94,.24),0 0 0 5px rgba(251,113,133,.14);
  animation-name:scoreFloatDown;
}
.score-particles{
  position:absolute;
  z-index:18;
  left:50%;
  top:34%;
  width:1px;
  height:1px;
  pointer-events:none;
}
.score-particles i{
  position:absolute;
  width:8px;
  height:8px;
  border-radius:2px 70% 2px 70%;
  background:var(--theme);
  box-shadow:0 0 9px var(--theme-shadow);
  opacity:0;
  transform:translate(0,0) rotate(0) scale(.4);
  animation:scoreParticleBurst .82s cubic-bezier(.18,.8,.25,1) var(--particle-delay) both;
}
.score-particles i:nth-child(3n){width:5px;height:5px;border-radius:50%;background:#facc15}
.score-particles i:nth-child(4n){width:7px;height:7px;background:#fff;box-shadow:0 0 11px var(--theme)}
.score-particles-negative i{background:#fb7185;box-shadow:0 0 8px rgba(244,63,94,.3);animation-name:scoreParticleFall}
.score-particles-negative i:nth-child(3n){background:#fecdd3}
.dashboard-student-grid .growth-star-card .avatar-wrap.score-avatar-ring::before{
  content:""!important;
  position:absolute!important;
  inset:-13px!important;
  display:block!important;
  border:3px solid var(--theme)!important;
  border-radius:50%!important;
  opacity:0;
  pointer-events:none;
  animation:scoreAvatarRing .8s ease-out both!important;
}
.dashboard-student-grid .growth-star-card.score-fx-negative .avatar-wrap.score-avatar-ring::before{
  border-color:#fb7185!important;
  animation-name:scoreAvatarRingNegative!important;
}
.profile-score-actions{
  display:flex;
  justify-content:center;
  gap:12px;
  margin-top:4px;
}
.profile-score-actions button{
  min-width:112px;
}
.profile-subtract-button{
  border:1px solid #fecdd3;
  border-radius:999px;
  background:#fff1f2;
  color:#e11d48;
  padding:9px 15px;
  font-weight:850;
}
.profile-custom-score-button{
  border:1px solid var(--theme-border);
  border-radius:999px;
  background:var(--theme-soft);
  color:var(--theme);
  padding:9px 15px;
  font-weight:850;
}
.profile-custom-score-button:hover{transform:translateY(-1px);box-shadow:0 7px 16px var(--theme-shadow)}
.custom-score-panel h2{color:var(--dark);font-size:24px}
.custom-score-panel .modal-sub{margin-bottom:20px}
.custom-score-quick>span,.custom-score-fields label>span{
  display:block;
  margin-bottom:8px;
  color:#64748b;
  font-size:12px;
  font-weight:850;
}
.custom-score-quick>div{display:grid;grid-template-columns:repeat(8,1fr);gap:7px}
.custom-score-quick button{
  min-height:44px;
  border-radius:14px;
  font-size:15px;
  font-weight:950;
  transition:.16s ease;
}
.custom-score-positive{border:1px solid #86efac;background:#f0fdf4;color:#047857}
.custom-score-negative{border:1px solid #fecdd3;background:#fff1f2;color:#be123c}
.custom-score-quick button:hover,.custom-score-quick button.active{transform:translateY(-2px);box-shadow:0 7px 16px var(--theme-shadow)}
.custom-score-positive.active{border-color:#10b981;background:#10b981;color:#fff}
.custom-score-negative.active{border-color:#f43f5e;background:#f43f5e;color:#fff}
.custom-score-fields{display:grid;grid-template-columns:180px minmax(0,1fr);gap:12px;margin-top:18px}
.custom-score-fields input{
  width:100%;
  height:48px;
  border:1px solid #dbe3ef;
  border-radius:15px;
  outline:0;
  background:#f8fafc;
  color:#334155;
  padding:0 14px;
  font-weight:750;
}
.custom-score-fields input:focus{border-color:var(--theme-border);background:#fff;box-shadow:0 0 0 3px var(--theme-soft)}
.custom-score-tip{margin:13px 0 0;color:#94a3b8;font-size:11px}
.custom-score-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}
.custom-score-actions button{min-width:104px;border-radius:999px;padding:10px 17px;font-weight:850}
.custom-score-actions button:first-child{border:1px solid #e2e8f0;background:#fff;color:#64748b}
@media(max-width:620px){
  .profile-score-actions{flex-wrap:wrap}.profile-score-actions button{min-width:96px;flex:1}
  .custom-score-quick>div{grid-template-columns:repeat(4,1fr)}
  .custom-score-fields{grid-template-columns:1fr}
}
.dashboard-student-grid .score-line b.score-number-pop{
  display:inline-block;
  transform-origin:center bottom;
  animation:scoreNumberPop .72s cubic-bezier(.18,1.25,.2,1) both;
}
@keyframes scoreRipple{
  0%{opacity:.8;transform:scale(.25)}
  100%{opacity:0;transform:scale(1.7)}
}
@keyframes scoreBadgePop{
  0%{transform:scale(.86)}
  58%{transform:scale(1.16)}
  100%{transform:scale(1)}
}
@keyframes scoreCardLift{
  0%{transform:translateY(0) scale(1)}
  38%{transform:translateY(-7px) scale(1.018)}
  100%{transform:translateY(0) scale(1)}
}
.dashboard-student-grid .growth-star-card.score-fx-negative{
  animation-name:scoreCardPenalty!important;
}
@keyframes scoreFloatUp{
  0%{opacity:0;transform:translate3d(0,12px,0) scale(.68)}
  16%{opacity:1;transform:translate3d(0,-2px,0) scale(1.04)}
  72%{opacity:1;transform:translate3d(0,-42px,0) scale(1)}
  100%{opacity:0;transform:translate3d(0,-64px,0) scale(.92)}
}
@keyframes scoreFloatDown{
  0%{opacity:0;transform:translate3d(0,-10px,0) scale(.68)}
  18%{opacity:1;transform:translate3d(0,2px,0) scale(1.03)}
  70%{opacity:1;transform:translate3d(0,34px,0) scale(1)}
  100%{opacity:0;transform:translate3d(0,52px,0) scale(.9)}
}
@keyframes scoreNumberPop{
  0%{transform:translateY(0) scale(1);filter:brightness(1)}
  42%{transform:translateY(-3px) scale(1.2);filter:brightness(1.2)}
  100%{transform:translateY(0) scale(1);filter:brightness(1)}
}
@keyframes scoreCardPenalty{
  0%,100%{transform:translateX(0) scale(1)}
  18%{transform:translateX(-4px) scale(1.006)}
  36%{transform:translateX(4px) scale(1.006)}
  54%{transform:translateX(-2px)}
  72%{transform:translateX(2px)}
}
@keyframes scoreParticleBurst{
  0%{opacity:0;transform:translate(0,0) rotate(0) scale(.25)}
  20%{opacity:1}
  75%{opacity:1;transform:translate(var(--particle-x),var(--particle-y)) rotate(var(--particle-rotate)) scale(1)}
  100%{opacity:0;transform:translate(var(--particle-x),var(--particle-y)) rotate(var(--particle-rotate)) scale(.35)}
}
@keyframes scoreParticleFall{
  0%{opacity:0;transform:translate(0,-8px) rotate(0) scale(.35)}
  25%{opacity:.9}
  100%{opacity:0;transform:translate(var(--particle-x),var(--particle-y)) rotate(var(--particle-rotate)) scale(.45)}
}
@keyframes scoreAvatarRing{
  0%{opacity:0;transform:scale(.65)}
  25%{opacity:.9}
  100%{opacity:0;transform:scale(1.35)}
}
@keyframes scoreAvatarRingNegative{
  0%{opacity:0;transform:scale(.8)}
  35%{opacity:.75}
  100%{opacity:0;transform:scale(1.15)}
}

/* Full-screen level-up celebration, adapted from the reference recording. */
body.level-up-open{overflow:hidden}
.level-up-celebration{
  position:fixed;
  inset:0;
  z-index:1000;
  display:grid;
  place-items:center;
  overflow:hidden;
  cursor:pointer;
  background:rgba(27,22,42,.62);
  -webkit-backdrop-filter:blur(8px) saturate(.82);
  backdrop-filter:blur(8px) saturate(.82);
  opacity:0;
  transition:opacity .22s ease;
}
.level-up-celebration.show{opacity:1}
.level-up-celebration.leaving{opacity:0}
.level-up-radiance{
  position:absolute;
  left:50%;
  top:48%;
  width:min(720px,86vw);
  aspect-ratio:1;
  border-radius:50%;
  background:
    repeating-conic-gradient(from 0deg,rgba(255,244,183,.14) 0 7deg,transparent 7deg 15deg),
    radial-gradient(circle,rgba(255,218,92,.5) 0,rgba(255,193,61,.19) 27%,rgba(255,196,66,.05) 49%,transparent 70%);
  transform:translate(-50%,-50%) scale(.5) rotate(-8deg);
  opacity:0;
  animation:levelRadiance 2.2s ease-out .05s both;
}
.level-up-particles{position:absolute;inset:0;pointer-events:none}
.level-up-particles i{
  position:absolute;
  left:var(--x);
  top:var(--y);
  width:7px;
  height:7px;
  border-radius:2px 70%;
  background:#ffe68b;
  box-shadow:0 0 13px #ffc83d;
  opacity:0;
  animation:levelParticle 1.6s ease-out var(--delay) both;
}
.level-up-particles i:nth-child(3n){width:4px;height:4px;border-radius:50%;background:#fff}
.level-up-particles i:nth-child(4n){background:var(--theme-2);box-shadow:0 0 11px var(--theme)}
.level-up-card{
  position:relative;
  z-index:2;
  width:min(520px,90vw);
  min-height:510px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  color:#fff9db;
  text-align:center;
  text-shadow:0 4px 18px rgba(83,49,0,.48);
  transform:translateY(22px) scale(.86);
  opacity:0;
  animation:levelCardEnter .6s cubic-bezier(.18,1.18,.28,1) .08s both;
}
.level-up-kicker{
  margin-bottom:12px;
  padding:6px 14px;
  border:1px solid rgba(255,236,153,.75);
  border-radius:999px;
  background:rgba(115,72,5,.34);
  color:#ffe682;
  font-size:12px;
  font-weight:950;
  letter-spacing:.22em;
}
.level-up-avatar-stage{position:relative;width:205px;height:205px;display:grid;place-items:center;margin:4px 0 8px}
.level-up-old-ring{
  position:absolute;
  inset:23px;
  border:7px solid var(--level-c);
  border-radius:50%;
  box-shadow:0 0 0 8px rgba(255,255,255,.22),0 0 34px var(--level-shadow);
  animation:oldFrameAway .55s ease-in .08s both;
}
.level-up-avatar.avatar-wrap{
  width:154px!important;
  height:154px!important;
  margin:0!important;
  padding:7px!important;
  float:none!important;
  transform:scale(.35) rotate(-8deg);
  opacity:0;
  animation:newFrameReveal .72s cubic-bezier(.15,1.24,.28,1) .34s both;
}
.level-up-avatar .avatar{width:100%;height:100%;border-radius:50%;overflow:hidden;background:#fff}
.level-up-card h2{margin:5px 0 0;color:#fff;font-size:38px;font-weight:1000;letter-spacing:.06em}
.level-up-card>strong{margin-top:7px;color:#ffe681;font-size:24px;font-weight:1000;letter-spacing:.08em}
.level-up-card>p{margin:13px 0 0;color:#fff;font-size:20px;font-weight:900}
.level-up-card>p b{margin:0 13px;color:#ffd84e;font-size:24px}
.level-up-card>small{margin-top:22px;color:rgba(255,255,255,.68);font-size:11px;text-shadow:none}
.level-up-group-card{width:min(720px,94vw);min-height:500px}
.level-up-group-card h2{font-size:32px}
.level-up-group-grid{width:100%;display:flex;justify-content:center;flex-wrap:wrap;gap:22px;margin:30px 0 19px}
.level-up-group-grid>div{width:92px;display:grid;justify-items:center;gap:7px;color:#fff}
.level-up-mini-avatar.avatar-wrap{width:76px!important;height:76px!important;margin:0!important;padding:4px!important;float:none!important;animation:groupAvatarPop .55s cubic-bezier(.18,1.2,.28,1) calc(.18s + var(--group-delay,0s)) both}
.level-up-mini-avatar .avatar{width:100%;height:100%;border-radius:50%;overflow:hidden;background:#fff}
.level-up-group-grid b{font-size:14px}.level-up-group-grid small{color:#ffe681;font-size:10px;font-weight:900}
.level-up-group-card>p{font-size:13px}.level-up-group-card>strong{font-size:19px}
@keyframes levelRadiance{0%{opacity:0;transform:translate(-50%,-50%) scale(.4) rotate(-12deg)}28%{opacity:1}100%{opacity:.38;transform:translate(-50%,-50%) scale(1.1) rotate(8deg)}}
@keyframes levelParticle{0%{opacity:0;transform:translate(0,42px) scale(.2) rotate(0)}20%{opacity:1}100%{opacity:0;transform:translate(var(--drift),-150px) scale(1.2) rotate(240deg)}}
@keyframes levelCardEnter{0%{opacity:0;transform:translateY(22px) scale(.86)}100%{opacity:1;transform:translateY(0) scale(1)}}
@keyframes oldFrameAway{0%{opacity:.9;transform:scale(1)}100%{opacity:0;transform:scale(.45) rotate(-18deg)}}
@keyframes newFrameReveal{0%{opacity:0;transform:scale(.35) rotate(-8deg)}64%{opacity:1;transform:scale(1.1) rotate(2deg)}100%{opacity:1;transform:scale(1) rotate(0)}}
@keyframes groupAvatarPop{0%{opacity:0;transform:translateY(18px) scale(.55)}100%{opacity:1;transform:translateY(0) scale(1)}}

@media(max-width:680px){
  .level-up-card{min-height:430px}.level-up-avatar-stage{width:170px;height:170px}.level-up-avatar.avatar-wrap{width:128px!important;height:128px!important}.level-up-card h2{font-size:30px}.level-up-card>strong{font-size:20px}.level-up-group-grid{gap:13px}.level-up-group-grid>div{width:76px}.level-up-mini-avatar.avatar-wrap{width:64px!important;height:64px!important}
}
@media(prefers-reduced-motion:reduce){
  .score-particles,.level-up-particles,.level-up-radiance{display:none!important}.score-float,.score-number-pop,.score-fx-card,.level-up-card,.level-up-avatar,.level-up-old-ring{animation-duration:.01ms!important;animation-delay:0s!important}.level-up-celebration{transition-duration:.01ms!important}
}

/* 10-level soft growth avatar frames. */
.frame-level-1{--level-a:#bdeecb;--level-b:#e7fff0;--level-c:#74d897;--level-shadow:rgba(116,216,151,.18)}
.frame-level-2{--level-a:#9ee7b7;--level-b:#dffbe9;--level-c:#4fc879;--level-shadow:rgba(79,200,121,.2)}
.frame-level-3{--level-a:#b8ddff;--level-b:#edf7ff;--level-c:#74bdf3;--level-shadow:rgba(116,189,243,.2)}
.frame-level-4{--level-a:#aebdff;--level-b:#f0edff;--level-c:#9b8af4;--level-shadow:rgba(155,138,244,.22)}
.frame-level-5{--level-a:#ffb7a8;--level-b:#fff0ea;--level-c:#ff8d78;--level-shadow:rgba(255,141,120,.22)}
.frame-level-6{--level-a:#ffc1d8;--level-b:#fff2d7;--level-c:#f4b65f;--level-shadow:rgba(244,182,95,.23)}
.frame-level-7{--level-a:#f6d37a;--level-b:#fff6d7;--level-c:#dba83d;--level-shadow:rgba(219,168,61,.25)}
.frame-level-8{--level-a:#f8e7ad;--level-b:#ffffff;--level-c:#c8b26a;--level-shadow:rgba(200,178,106,.24)}
.frame-level-9{--level-a:#d8c4ff;--level-b:#f8f2ff;--level-c:#a98df5;--level-shadow:rgba(169,141,245,.24)}
.frame-level-10{--level-a:#ffc4df;--level-b:#fff2c7;--level-c:#a8d8ff;--level-shadow:rgba(236,128,180,.26)}
.avatar-wrap[class*="frame-level-"],
.rank-avatar[class*="frame-level-"]{
  position:relative;
  background:
    linear-gradient(#fff,#fff) padding-box,
    conic-gradient(from 210deg,var(--level-a),var(--level-b),var(--level-c),var(--level-a),var(--level-b)) border-box!important;
  border:5px solid transparent!important;
  box-shadow:
    0 0 0 4px rgba(255,255,255,.92),
    0 0 0 8px color-mix(in srgb,var(--level-a) 24%,transparent),
    0 10px 22px var(--level-shadow)!important;
}
.dashboard-student-grid .growth-star-card .avatar-wrap[class*="frame-level-"]{
  background:
    linear-gradient(#fff,#fff) padding-box,
    conic-gradient(from 210deg,var(--level-a),var(--level-b),var(--level-c),var(--level-a),var(--level-b)) border-box!important;
  border:5px solid transparent!important;
  box-shadow:
    0 0 0 4px rgba(255,255,255,.92),
    0 0 0 8px color-mix(in srgb,var(--level-a) 22%,transparent),
    0 12px 24px var(--level-shadow)!important;
}
.student-profile .avatar-wrap[class*="frame-level-"]{
  background:
    linear-gradient(#fff,#fff) padding-box,
    conic-gradient(from 210deg,var(--level-a),var(--level-b),var(--level-c),var(--level-a),var(--level-b)) border-box!important;
  border:6px solid transparent!important;
  box-shadow:
    0 0 0 5px rgba(255,255,255,.92),
    0 0 0 10px color-mix(in srgb,var(--level-a) 24%,transparent),
    0 14px 28px var(--level-shadow)!important;
}
.mini-avatar[class*="frame-level-"]{
  position:relative;
  border:3px solid transparent!important;
  background:
    linear-gradient(#fff,#fff) padding-box,
    conic-gradient(from 210deg,var(--level-a),var(--level-b),var(--level-c),var(--level-a)) border-box!important;
  color:var(--level-c)!important;
  box-shadow:0 4px 10px var(--level-shadow)!important;
}
#rankingList .mini-avatar[class*="frame-level-"]{overflow:visible}
#rankingList .mini-avatar-inner{
  width:100%;
  height:100%;
  display:grid;
  place-items:center;
  overflow:hidden;
  border-radius:50%;
  background:#fff;
}
#rankingList .mini-avatar-inner>img{width:100%;height:100%;border-radius:50%;object-fit:cover}
#rankingList .mini-avatar-inner>.generated-avatar{object-fit:contain;transform:scale(1.08)}
#rankingList .mini-avatar-inner>.toon-avatar{width:100%;height:100%}
#rankingList .mini-avatar-inner>.name-emblem{font-size:13px;line-height:1;letter-spacing:0}
#ranking .podium-card .name-emblem{font-size:21px;line-height:1;letter-spacing:0;white-space:nowrap}
#rankingList .mini-avatar[class*="frame-level-"]::after{
  right:-3px;
  top:-3px;
  width:7px;
  height:7px;
  box-shadow:0 0 0 2px rgba(255,255,255,.9),0 0 8px var(--level-shadow);
}
.frame-level-2::after,
.frame-level-4::after,
.frame-level-6::after,
.frame-level-8::after,
.frame-level-9::after,
.frame-level-10::after{
  content:"";
  position:absolute;
  right:3px;
  top:9px;
  width:10px;
  height:10px;
  border-radius:50%;
  background:var(--level-c);
  box-shadow:0 0 0 4px rgba(255,255,255,.75),0 0 12px var(--level-shadow);
  opacity:.8;
  pointer-events:none;
}
.dashboard-student-grid .growth-star-card .avatar-wrap[class*="frame-level-"]::before,
.dashboard-student-grid .growth-star-card .avatar-wrap[class*="frame-level-"]::after{
  display:block!important;
}
.dashboard-student-grid .growth-star-card .avatar-wrap.frame-level-10,
.student-profile .avatar-wrap.frame-level-10,
.rank-avatar.frame-level-10{
  box-shadow:
    0 0 0 4px rgba(255,255,255,.94),
    0 0 0 9px rgba(255,196,223,.22),
    0 14px 30px rgba(236,128,180,.24),
    0 0 18px rgba(168,216,255,.18)!important;
}

/* Teacher settings: show the 10 avatar-frame levels next to the editable thresholds. */
.stage-frame-grid{
  grid-template-columns:repeat(5,minmax(0,1fr))!important;
  gap:13px!important;
}
.stage-frame-grid .stage-card{
  display:grid!important;
  grid-template-columns:auto 1fr;
  align-items:center;
  gap:10px 12px!important;
  padding:12px!important;
  border:1px solid rgba(148,163,184,.22);
  border-radius:16px;
  background:
    linear-gradient(180deg,rgba(255,255,255,.98),rgba(248,250,252,.88)) padding-box,
    linear-gradient(135deg,rgba(255,255,255,.7),rgba(148,163,184,.18)) border-box;
  box-shadow:0 8px 18px rgba(15,23,42,.045);
}
.stage-frame-grid .stage-card:hover{
  transform:translateY(-1px);
  box-shadow:0 12px 24px rgba(15,23,42,.07);
}
.stage-frame-preview{
  position:relative;
  width:46px;
  height:46px;
  display:grid;
  place-items:center;
  border:4px solid transparent;
  border-radius:50%;
  background:
    linear-gradient(#fff,#fff) padding-box,
    conic-gradient(from 210deg,var(--level-a),var(--level-b),var(--level-c),var(--level-a)) border-box;
  box-shadow:
    0 0 0 3px rgba(255,255,255,.94),
    0 7px 15px var(--level-shadow);
}
.stage-frame-preview i{
  width:28px;
  height:28px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:linear-gradient(180deg,#fff,rgba(248,250,252,.92));
  color:var(--level-c);
  font-style:normal;
  font-size:12px;
  font-weight:950;
  box-shadow:inset 0 0 0 1px rgba(148,163,184,.13);
}
.stage-meta{
  display:grid;
  gap:2px;
  min-width:0;
}
.stage-meta b{
  color:#64748b;
  font-size:11px;
  font-weight:950;
  line-height:1;
}
.stage-meta em{
  color:#334155;
  font-size:13px;
  font-style:normal;
  font-weight:950;
  line-height:1.2;
  white-space:nowrap;
}
.stage-frame-grid .stage-card input{
  grid-column:1/-1;
  height:40px;
  padding:7px 10px!important;
  border-radius:12px!important;
  font-size:16px;
  font-weight:850;
  background:rgba(255,255,255,.86)!important;
}
.stage-frame-grid .stage-card input:focus{
  border-color:var(--theme)!important;
  box-shadow:0 0 0 3px var(--theme-soft)!important;
}
.stage-frame-grid .stage-card input:disabled,
.stage-frame-grid .stage-card input[readonly]{
  background:#f1f5f9!important;
  color:#94a3b8!important;
}

@media(max-width:900px){
  .stage-frame-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
}

/* Stable SVG score item icons for teacher settings, scoring dialogs and projection screens. */
.score-svg-icon{
  width:22px;
  height:22px;
  display:inline-block;
  flex:0 0 auto;
  vertical-align:middle;
  fill:currentColor;
  color:currentColor;
}
.score-emoji-icon{
  display:inline-grid;
  place-items:center;
  font-size:20px;
  line-height:1;
}
.setting-icon{
  width:34px;
  height:34px;
  display:grid!important;
  place-items:center;
  border-radius:12px;
  background:rgba(241,245,249,.78);
  color:#64748b;
}
.positive-head + .settings-score-list .setting-icon{
  background:#ecfdf5;
  color:#059669;
}
.negative-head + .settings-score-list .setting-icon{
  background:#fff1f2;
  color:#e11d48;
}
.score-option-name{
  display:flex;
  align-items:center;
  gap:10px;
  min-width:0;
  color:#475569;
  font-weight:900;
}
.score-option-name .score-svg-icon{
  width:26px;
  height:26px;
  color:var(--theme);
  filter:drop-shadow(0 3px 6px rgba(100,116,139,.12));
}
.score-add-row{
  grid-template-columns:54px 1fr 100px 100px!important;
  align-items:center;
}
.score-icon-current{
  width:54px;
  height:48px;
  display:grid;
  place-items:center;
  color:var(--theme)!important;
  background:linear-gradient(180deg,#fff,var(--theme-soft))!important;
  border-color:var(--theme-border)!important;
  box-shadow:0 8px 18px var(--theme-shadow);
}
.score-icon-current .score-svg-icon{
  width:26px;
  height:26px;
}
.score-icon-popover{
  position:relative;
  z-index:80;
  grid-column:1/-1;
  max-height:430px;
  overflow:auto;
  margin-top:10px;
  padding:14px;
  border:1px solid var(--theme-border);
  border-radius:20px;
  background:linear-gradient(180deg,#fff,rgba(248,250,252,.96));
  box-shadow:0 18px 45px rgba(15,23,42,.16),0 0 0 4px var(--theme-soft);
}
.score-icon-popover-head{
  position:sticky;
  top:-14px;
  z-index:2;
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin:-14px -14px 12px;
  padding:12px 14px;
  border-bottom:1px solid #eef2f7;
  background:rgba(255,255,255,.96);
  backdrop-filter:blur(12px);
}
.score-icon-popover-head b{
  color:#334155;
  font-size:14px;
  font-weight:950;
}
.score-icon-popover-head button{
  width:30px;
  height:30px;
  border:0;
  border-radius:50%;
  background:#f1f5f9;
  color:#64748b;
  font-weight:950;
}
.score-icon-popover section+section{
  margin-top:15px;
}
.score-icon-popover h4{
  margin:0 0 9px;
  color:#64748b;
  font-size:12px;
  font-weight:950;
}
.score-icon-picker-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(58px,1fr));
  gap:9px;
}
.score-icon-choice{
  min-height:58px;
  display:grid;
  place-items:center;
  border:1px solid #e2e8f0;
  border-radius:15px;
  background:#fff;
  color:#64748b;
  transition:.16s;
}
.score-icon-choice:hover,
.score-icon-choice.active{
  border-color:var(--theme);
  color:var(--theme);
  background:var(--theme-soft);
  box-shadow:0 8px 18px var(--theme-shadow);
  transform:translateY(-1px);
}
.score-icon-choice .score-svg-icon{
  width:27px;
  height:27px;
}
.score-icon-choice.minus-icon{
  color:#e11d48;
}
.score-edit-icon-button{
  min-height:54px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  border:1px solid var(--theme-border);
  border-radius:15px;
  background:linear-gradient(180deg,#fff,var(--theme-soft));
  color:var(--theme);
  font-weight:900;
}
.score-edit-icon-button .score-svg-icon{
  width:26px;
  height:26px;
}

@media(max-width:700px){
  .score-add-row{grid-template-columns:48px 1fr 78px!important;}
  .score-add-row button:last-child{grid-column:1/-1;}
  .score-icon-picker-grid{grid-template-columns:repeat(4,minmax(0,1fr));}
}

/* Group management panel. */
.group-config-form{
  gap:16px!important;
}
.group-manager,
.group-assign-list{
  display:grid;
  gap:10px;
  padding:14px;
  border:1px solid #e2e8f0;
  border-radius:18px;
  background:linear-gradient(180deg,#fff,rgba(248,250,252,.86));
}
.group-manager h3,
.group-assign-list h3{
  margin:0 0 4px;
  color:#475569;
  font-size:13px;
  font-weight:950;
}
.group-edit-list{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:9px;
}
.group-edit-row{
  display:grid;
  grid-template-columns:1fr 64px;
  gap:8px;
  align-items:center;
}
.group-edit-row input,
.add-group-row input{
  min-width:0;
}
.group-edit-row input[readonly]{
  background:#f8fafc;
  color:#94a3b8;
}
.group-edit-row button,
.add-group-row button{
  border:1px solid #e2e8f0;
  border-radius:12px;
  background:#fff;
  color:#64748b;
  padding:10px;
  font-weight:900;
}
.group-edit-row button:not(:disabled){
  border-color:#fecdd3;
  color:#e11d48;
}
.group-edit-row button:disabled{
  opacity:.45;
  cursor:not-allowed;
}
.add-group-row{
  display:grid;
  grid-template-columns:1fr 120px;
  gap:9px;
}
.add-group-row button{
  border:0;
  background:linear-gradient(135deg,var(--theme),var(--theme-2));
  color:#fff;
  box-shadow:0 8px 18px var(--theme-shadow);
}
.group-assign-list label{
  display:grid;
  grid-template-columns:1fr 150px;
  gap:10px;
  align-items:center;
}
.group-assign-list label span{
  color:#475569;
  font-weight:850;
}

@media(max-width:700px){
  .group-edit-list{grid-template-columns:1fr;}
  .group-assign-list label,
  .add-group-row{grid-template-columns:1fr;}
}

/* Honor roll tabs and group ranking */
.ranking-tabs button{
  cursor:pointer;
}
.ranking-tabs button.active{
  color:var(--theme)!important;
}
.ranking-tabs button:focus-visible{
  outline:3px solid var(--theme-soft-2);
  outline-offset:2px;
}
.group-rank-emblem{
  width:104px;
  height:104px;
  display:grid;
  place-items:center;
  margin:7px auto 12px;
  border:7px solid color-mix(in srgb,var(--theme-border) 72%,white);
  border-radius:50%;
  background:linear-gradient(145deg,#fff,var(--theme-soft));
  color:var(--theme);
  box-shadow:0 0 0 5px color-mix(in srgb,var(--theme-soft) 78%,white),0 10px 24px var(--theme-shadow);
}
.group-rank-emblem svg{
  width:48px;
  height:48px;
  fill:currentColor;
}
.group-rank-emblem.small{
  width:40px;
  height:40px;
  margin:0;
  border-width:3px;
  box-shadow:0 0 0 2px var(--theme-soft),0 5px 12px var(--theme-shadow);
}
.group-rank-emblem.small svg{
  width:20px;
  height:20px;
}
.group-member-count{
  display:block;
  margin:3px 0;
  color:#94a3b8;
  font-size:12px;
  font-weight:800;
}
.group-rank-row small{
  display:block;
  color:#9aa1b1;
}

/* Theme-aware class manager */
.modal-panel.class-manager-modal{
  width:min(680px,100%);
  max-height:92vh;
  padding:30px;
  border:1px solid color-mix(in srgb,var(--theme-border) 70%,white);
  background:linear-gradient(180deg,#fff,color-mix(in srgb,var(--theme-soft) 24%,white));
  box-shadow:0 30px 80px rgba(30,41,59,.28),0 0 0 1px rgba(255,255,255,.7);
}
.class-manager{
  display:grid;
  gap:18px;
}
.class-manager-heading{
  min-height:64px;
  display:flex;
  align-items:center;
  gap:13px;
  padding-right:48px;
  border-bottom:1px solid #eef2f7;
}
.class-manager-heading>svg{
  width:30px;
  height:30px;
  color:var(--theme);
}
.class-manager-heading h2,
.class-manager-heading p{
  margin:0;
}
.class-manager-heading h2{
  color:#1e293b;
  font-size:23px;
  font-weight:950;
}
.class-manager-heading p{
  margin-top:3px;
  color:#94a3b8;
  font-size:12px;
  font-weight:750;
}
.class-manager-list{
  max-height:430px;
  display:grid;
  gap:12px;
  overflow:auto;
  padding:2px 4px 2px 2px;
}
.class-manager-card{
  min-height:94px;
  display:grid;
  grid-template-columns:58px minmax(0,1fr) auto auto;
  align-items:center;
  gap:14px;
  padding:14px 17px;
  border:2px solid #e2e8f0;
  border-radius:19px;
  background:rgba(255,255,255,.94);
  box-shadow:0 5px 14px rgba(100,116,139,.05);
  transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease,background .18s ease;
}
.class-manager-card[data-switch-class]{cursor:pointer}
.class-manager-card[data-switch-class]:hover{
  transform:translateY(-2px);
  border-color:var(--theme-border);
  background:var(--theme-soft);
  box-shadow:0 10px 24px var(--theme-shadow);
}
.class-manager-card.current{
  border-color:var(--theme);
  background:linear-gradient(135deg,#fff,var(--theme-soft));
  box-shadow:0 9px 23px var(--theme-shadow);
}
.class-manager-badge{
  width:54px;
  height:54px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:var(--theme-soft-2);
  color:var(--theme-text);
  font-size:22px;
  font-weight:950;
}
.class-manager-card.current .class-manager-badge{
  color:#fff;
  background:linear-gradient(135deg,var(--theme-2),var(--theme));
  box-shadow:0 7px 16px var(--theme-shadow);
}
.class-manager-info{
  min-width:0;
}
.class-manager-info b,
.class-manager-info span{
  display:block;
}
.class-manager-info b{
  overflow:hidden;
  color:#334155;
  font-size:17px;
  font-weight:950;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.class-manager-info span{
  margin-top:5px;
  color:#94a3b8;
  font-size:12px;
  font-weight:750;
}
.current-class-tag{
  padding:7px 11px;
  border-radius:10px;
  background:var(--theme-soft-2);
  color:var(--theme-text);
  font-size:11px;
  font-style:normal;
  font-weight:950;
  white-space:nowrap;
}
.class-manager-actions{
  display:flex;
  gap:5px;
}
.class-manager-actions button{
  width:auto;
  min-width:46px;
  height:38px;
  display:grid;
  place-items:center;
  padding:0 10px;
  border:0;
  border-radius:11px;
  background:transparent;
  color:#94a3b8;
  font-size:12px;
  font-weight:900;
}
.class-manager-actions button:hover{
  background:var(--theme-soft);
  color:var(--theme);
}
.class-manager-actions .delete-class-button:hover{
  background:#fff1f2;
  color:#e11d48;
}
.create-class-button{
  min-height:66px;
  border:1px solid var(--theme-border);
  border-radius:18px;
  background:var(--theme-soft);
  color:var(--theme-text);
  font-size:16px;
  font-weight:950;
  transition:transform .18s ease,box-shadow .18s ease,background .18s ease;
}
.create-class-button:hover{
  transform:translateY(-2px);
  background:var(--theme-soft-2);
  box-shadow:0 10px 22px var(--theme-shadow);
}
.class-manager-editor,
.class-delete-confirm{
  padding:18px;
  border:1px solid var(--theme-border);
  border-radius:18px;
  background:var(--theme-soft);
}
.class-manager-editor h3,
.class-manager-editor p,
.class-delete-confirm h3,
.class-delete-confirm p{
  margin:0;
}
.class-manager-editor h3,
.class-delete-confirm h3{
  color:#334155;
  font-size:16px;
  font-weight:950;
}
.class-manager-editor p,
.class-delete-confirm p{
  margin-top:5px;
  color:#7c8ba1;
  font-size:12px;
}
.class-manager-editor input{
  width:100%;
  height:48px;
  margin:15px 0 12px;
  padding:0 15px;
  border:1px solid var(--theme-border);
  border-radius:13px;
  outline:0;
  background:#fff;
  color:#334155;
  font-weight:850;
}
.class-manager-editor input:focus{
  border-color:var(--theme);
  box-shadow:0 0 0 3px var(--theme-soft-2);
}
.class-manager-editor>div,
.class-delete-confirm footer{
  display:flex;
  justify-content:flex-end;
  gap:9px;
}
.class-manager-editor button,
.class-delete-confirm button{
  min-height:40px;
  padding:0 17px;
  border:1px solid var(--theme-border);
  border-radius:12px;
  background:#fff;
  color:#64748b;
  font-weight:900;
}
.class-manager-editor .class-confirm-button{
  border:0;
  background:linear-gradient(135deg,var(--theme-2),var(--theme));
  color:#fff;
  box-shadow:0 8px 17px var(--theme-shadow);
}
.class-delete-confirm{
  display:grid;
  grid-template-columns:46px 1fr;
  gap:13px;
  border-color:#fecdd3;
  background:#fff7f8;
}
.class-delete-icon{
  width:42px;
  height:42px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:#ffe4e6;
  color:#e11d48;
  font-size:20px;
  font-weight:950;
}
.class-delete-confirm footer{
  grid-column:1/-1;
  margin-top:4px;
}
.class-delete-confirm .class-delete-confirm-button{
  border:0;
  background:#e11d48;
  color:#fff;
  box-shadow:0 8px 17px rgba(225,29,72,.2);
}

@media(max-width:620px){
  .modal-panel.class-manager-modal{padding:22px 16px}
  .class-manager-card{grid-template-columns:48px minmax(0,1fr) auto;gap:10px;padding:12px}
  .class-manager-badge{width:46px;height:46px;font-size:18px}
  .current-class-tag{display:none}
  .class-manager-actions{grid-column:3;grid-row:1}
}

/* 小卖部：商品列表、兑换记录与商品管理 */
#rewards{
  width:min(1380px,calc(100% - 28px));
  max-width:1380px;
  min-height:680px;
  padding:30px;
  border-color:var(--theme-border);
  background:rgba(255,255,255,.94);
  box-shadow:0 22px 58px var(--theme-shadow);
}
#rewards .store-heading{margin-bottom:8px}
#rewards .store-heading h2{color:#243047;font-size:28px}
.store-tabs{
  display:flex;
  width:max-content;
  margin:0 0 28px;
  padding:5px;
  border-radius:16px;
  background:#f1f5f9;
}
.store-tabs button{
  min-height:42px;
  padding:0 20px;
  border:0;
  border-radius:12px;
  background:transparent;
  color:#7c8ba1;
  font-size:14px;
  font-weight:900;
  transition:.18s ease;
}
.store-tabs button:hover{color:var(--theme-text);background:var(--theme-soft)}
.store-tabs button.active{
  background:#fff;
  color:var(--theme-text);
  box-shadow:0 5px 14px rgba(51,65,85,.1),inset 0 -2px 0 var(--theme);
}
#rewards .reward-grid{
  display:grid;
  width:100%;
  max-width:1172px;
  grid-template-columns:repeat(auto-fit,minmax(190px,220px));
  gap:18px;
  align-items:start;
  justify-content:start;
}
#rewards .reward-card{
  --reward-accent:#7c3aed;
  --reward-soft:#eef2ff;
  position:relative;
  min-height:285px;
  display:flex;
  flex-direction:column;
  padding:18px 16px 16px;
  overflow:hidden;
  border:2px solid rgba(255,255,255,.9);
  border-radius:24px;
  background:var(--reward-soft);
  box-shadow:0 12px 28px color-mix(in srgb,var(--reward-accent) 18%,transparent),inset 0 0 0 1px color-mix(in srgb,var(--reward-accent) 20%,transparent);
  transition:transform .2s ease,box-shadow .2s ease;
}
#rewards .reward-card:hover{transform:translateY(-4px);box-shadow:0 18px 36px color-mix(in srgb,var(--reward-accent) 24%,transparent),inset 0 0 0 1px color-mix(in srgb,var(--reward-accent) 28%,transparent)}
[data-reward-color="violet"]{--reward-accent:#6366f1!important;--reward-soft:#eef2ff!important}
[data-reward-color="purple"]{--reward-accent:#9333ea!important;--reward-soft:#f5eaff!important}
[data-reward-color="orange"]{--reward-accent:#f97316!important;--reward-soft:#fff1df!important}
[data-reward-color="rose"]{--reward-accent:#ec4899!important;--reward-soft:#fceaf3!important}
[data-reward-color="sky"]{--reward-accent:#0ea5e9!important;--reward-soft:#e5f6fd!important}
[data-reward-color="yellow"]{--reward-accent:#d99a00!important;--reward-soft:#fff9cf!important}
[data-reward-color="mint"]{--reward-accent:#10b981!important;--reward-soft:#e5faf3!important}
[data-reward-color="pink"]{--reward-accent:#f472b6!important;--reward-soft:#fdf0f7!important}
[data-reward-color="slate"]{--reward-accent:#64748b!important;--reward-soft:#edf2f7!important}
[data-reward-color="coral"]{--reward-accent:#f46f6f!important;--reward-soft:#fff0ee!important}
#rewards .reward-card .reward-icon{
  width:60px;
  height:60px;
  margin:8px auto 12px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:rgba(255,255,255,.82);
  color:var(--reward-accent);
  box-shadow:0 8px 20px color-mix(in srgb,var(--reward-accent) 13%,transparent),inset 0 0 0 1px rgba(255,255,255,.9);
}
#rewards .reward-card .reward-icon .reward-svg-icon{width:28px;height:28px;display:block}
#rewards .reward-card h3{margin:0 0 5px;color:color-mix(in srgb,var(--reward-accent) 68%,#243047);font-size:16px;text-align:center}
#rewards .reward-card p{min-height:34px;margin:0;color:#8290a5;font-size:11px;line-height:1.55;text-align:center}
.reward-stock-badge{
  position:absolute;
  top:12px;
  right:12px;
  z-index:2;
  padding:6px 10px;
  border-radius:999px;
  background:#fbbf24;
  color:#fff;
  box-shadow:0 7px 15px rgba(245,158,11,.25);
  font-size:10px;
  font-weight:950;
}
.reward-stock-badge.sold-out{background:#94a3b8;box-shadow:none}
#rewards .reward-foot{margin-top:auto;padding-top:14px}
#rewards .reward-foot .coin{color:#64748b;font-size:11px}
#rewards .reward-foot button{
  min-width:92px;
  min-height:36px;
  border:0;
  border-radius:12px;
  background:var(--reward-accent);
  color:#fff;
  box-shadow:0 8px 17px color-mix(in srgb,var(--reward-accent) 25%,transparent);
}
#rewards .reward-foot button:disabled{cursor:not-allowed;background:#cbd5e1;box-shadow:none}
#rewards .reward-manage-card{min-height:305px;background:#fff;border:2px dashed color-mix(in srgb,var(--reward-accent) 35%,#dbe3ee)}
.reward-manage-stock{display:grid;grid-template-columns:1fr 34px 42px 34px;align-items:center;margin-top:auto;border:1px solid #e5eaf1;border-radius:12px;overflow:hidden;color:#7c8ba1;font-size:11px;font-weight:850}
.reward-manage-stock span{padding-left:10px}.reward-manage-stock button,.reward-manage-stock b{height:34px;display:grid;place-items:center;border:0;border-left:1px solid #e5eaf1;background:#fff;color:#64748b}.reward-manage-stock button:hover{background:var(--reward-soft);color:var(--reward-accent)}.reward-manage-stock button:disabled{opacity:.4}
.reward-manage-actions{display:grid;grid-template-columns:1fr 52px;gap:8px;margin-top:8px}.reward-manage-actions button{min-height:36px;border:1px solid #e2e8f0;border-radius:11px;background:#fff;color:#64748b;font-weight:900}.reward-manage-actions button:hover{border-color:var(--reward-accent);color:var(--reward-accent)}.reward-manage-actions .reward-delete-button:hover{border-color:#fecdd3;background:#fff1f2;color:#e11d48}
.add-reward-card{min-height:305px;display:grid;place-content:center;justify-items:center;gap:9px;border:3px dashed #d7e0eb;border-radius:24px;background:rgba(248,250,252,.7);color:#94a3b8}.add-reward-card:hover{border-color:var(--theme-border);background:var(--theme-soft);color:var(--theme-text)}.add-reward-card span{width:64px;height:64px;display:grid;place-items:center;border-radius:50%;background:#fff;box-shadow:0 8px 20px rgba(100,116,139,.1);font-size:32px;font-weight:300}.add-reward-card b{font-size:16px}.add-reward-card small{font-size:11px}
#rewardGrid[data-store-view="records"]{display:block}
.store-record-table{overflow:hidden;border:1px solid var(--theme-border);border-radius:20px;background:#fff;box-shadow:0 10px 28px rgba(100,116,139,.08)}
.store-record-head,.store-record-row{display:grid;grid-template-columns:150px minmax(110px,1fr) minmax(190px,1.5fr) 90px 90px;align-items:center;gap:12px;padding:14px 18px;border-bottom:1px solid #edf1f6}.store-record-head{background:var(--theme-soft);color:#7c8ba1;font-size:11px;font-weight:900}.store-record-row{color:#536176;font-size:13px}.store-record-row:last-child{border-bottom:0}.store-record-row strong{color:#f59e0b}.store-record-row em{width:max-content;padding:4px 9px;border-radius:999px;background:#ecfdf5;color:#059669;font-style:normal;font-size:10px;font-weight:900}.store-record-row.undone{opacity:.58}.store-record-row.undone em{background:#f1f5f9;color:#64748b}.store-record-product{display:flex;align-items:center;gap:9px;font-weight:850}.store-record-product i,.store-redeem-title>i{--reward-accent:#6366f1;--reward-soft:#eef2ff;width:38px;height:38px;display:grid;place-items:center;flex:0 0 auto;border-radius:12px;background:var(--reward-soft);color:var(--reward-accent)}.store-record-product .reward-svg-icon,.store-redeem-title .reward-svg-icon{width:22px;height:22px}
.store-empty{grid-column:1/-1;min-height:350px;display:grid;place-content:center;justify-items:center;color:#94a3b8;text-align:center}.store-empty span{width:70px;height:70px;display:grid;place-items:center;border-radius:50%;background:var(--theme-soft);color:var(--theme);font-size:30px}.store-empty b{margin-top:15px;color:#64748b}.store-empty p{margin:5px 0 0;font-size:12px}
.store-redeem-title{display:flex;align-items:center;gap:13px;margin-bottom:18px}.store-redeem-title h2,.store-redeem-title p{margin:0}.store-redeem-title>i{width:50px;height:50px}.store-redeem-title .reward-svg-icon{width:28px;height:28px}
.modal-panel.reward-editor-modal{display:block;width:min(780px,calc(100vw - 28px));height:auto;max-height:92vh;padding:28px;overflow:auto}.modal-panel.reward-editor-modal #modalContent{display:block;height:auto}.reward-editor h2{font-size:23px}.reward-product-form{display:grid;grid-template-columns:1fr 170px 150px;gap:17px;margin-top:22px}.reward-field{display:grid;gap:8px}.reward-field span,.reward-palette-picker legend,.reward-icon-picker legend{color:#7c8ba1;font-size:11px;font-weight:900}.reward-field input,.reward-field textarea{width:100%;border:1px solid #dbe3ee;border-radius:13px;outline:0;background:#fff;color:#334155;padding:12px 14px;font-weight:750}.reward-field input{height:48px}.reward-field textarea{min-height:94px;resize:vertical;line-height:1.6}.reward-field input:focus,.reward-field textarea:focus{border-color:var(--theme);box-shadow:0 0 0 3px var(--theme-soft)}.reward-desc-field{grid-column:1/-1}.reward-palette-picker,.reward-icon-picker{grid-column:1/-1;margin:0;padding:0;border:0}.reward-palette-picker{display:flex;align-items:center;gap:10px;padding-bottom:18px;border-bottom:1px solid #edf1f6}.reward-palette-picker legend{width:100%;margin-bottom:12px}.reward-palette-picker button{width:38px;height:38px;padding:4px;border:2px solid transparent;border-radius:50%;background:transparent}.reward-palette-picker button i{--reward-accent:#6366f1;display:block;width:100%;height:100%;border-radius:50%;background:var(--reward-accent)}.reward-palette-picker button.active{border-color:var(--reward-accent);box-shadow:0 0 0 3px color-mix(in srgb,var(--reward-accent) 14%,transparent)}
.reward-icon-categories{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0}.reward-icon-categories button{min-height:35px;padding:0 14px;border:1px solid #e2e8f0;border-radius:10px;background:#fff;color:#64748b;font-size:11px;font-weight:900}.reward-icon-categories button.active{border-color:var(--theme);background:var(--theme-soft);color:var(--theme-text)}.reward-icon-options{display:none;grid-template-columns:repeat(8,1fr);gap:9px}.reward-icon-options.active{display:grid}.reward-icon-options button{height:52px;display:grid;place-items:center;border:1px solid #e2e8f0;border-radius:13px;background:#fff;color:#8290a5}.reward-icon-options button:hover,.reward-icon-options button.active{border-color:var(--theme);background:var(--theme-soft);color:var(--theme);box-shadow:0 5px 13px var(--theme-shadow)}.reward-icon-options .reward-svg-icon{width:26px;height:26px}
.reward-editor-actions{grid-column:1/-1;display:flex;justify-content:flex-end;gap:10px;padding-top:6px}.reward-editor-actions button{min-width:110px;min-height:43px;border:1px solid #e2e8f0;border-radius:12px;background:#fff;color:#64748b;font-weight:900}.reward-editor-actions .primary-button{border:0;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 8px 18px var(--theme-shadow)}
.reward-delete-confirm{text-align:center}.reward-delete-confirm>span{width:54px;height:54px;margin:0 auto 13px;display:grid;place-items:center;border-radius:50%;background:#ffe4e6;color:#e11d48;font-size:25px;font-weight:950}.reward-delete-confirm h2{font-size:21px}.reward-delete-confirm p{margin:8px 0 22px;color:#7c8ba1;font-size:13px}.reward-delete-confirm>div{display:flex;justify-content:center;gap:10px}.reward-delete-confirm button{min-width:120px;min-height:42px;border:1px solid #e2e8f0;border-radius:12px;background:#fff;color:#64748b;font-weight:900}.reward-delete-confirm .reward-confirm-delete{border:0;background:#e11d48;color:#fff}

@media(max-width:980px){#rewards{padding:22px}.store-record-head,.store-record-row{grid-template-columns:115px 1fr 1.4fr 70px}.store-record-head span:last-child,.store-record-row em{display:none}.reward-icon-options{grid-template-columns:repeat(6,1fr)}}
@media(max-width:680px){#rewards{width:calc(100% - 16px);min-height:0;padding:18px 13px}.store-tabs{width:100%}.store-tabs button{flex:1;padding:0 8px;font-size:12px}#rewards .reward-grid{grid-template-columns:1fr}.store-record-table{overflow-x:auto}.store-record-head,.store-record-row{min-width:590px}.reward-product-form{grid-template-columns:1fr 1fr}.reward-name-field,.reward-desc-field{grid-column:1/-1}.reward-icon-options{grid-template-columns:repeat(5,1fr)}.reward-editor-actions button{flex:1;min-width:0}}

/* Only the portrait inside main student cards breathes; level frames stay still. */
.dashboard-student-grid .growth-star-card{
  --student-avatar-breathe-delay:0s;
  content-visibility:auto;
  contain-intrinsic-size:auto 300px;
}
.dashboard-student-grid .growth-star-card:nth-child(8n+2){--student-avatar-breathe-delay:-.4s}
.dashboard-student-grid .growth-star-card:nth-child(8n+3){--student-avatar-breathe-delay:-.8s}
.dashboard-student-grid .growth-star-card:nth-child(8n+4){--student-avatar-breathe-delay:-1.2s}
.dashboard-student-grid .growth-star-card:nth-child(8n+5){--student-avatar-breathe-delay:-1.6s}
.dashboard-student-grid .growth-star-card:nth-child(8n+6){--student-avatar-breathe-delay:-2s}
.dashboard-student-grid .growth-star-card:nth-child(8n+7){--student-avatar-breathe-delay:-2.4s}
.dashboard-student-grid .growth-star-card:nth-child(8n+8){--student-avatar-breathe-delay:-2.8s}
.dashboard-student-grid .growth-star-card.avatar-breathe-visible:not(.name-only) .avatar>img,
.dashboard-student-grid .growth-star-card.avatar-breathe-visible:not(.name-only) .avatar>.toon-avatar{
  --student-avatar-breathe-base:1;
  --student-avatar-breathe-peak:1.06;
  transform-origin:50% 58%;
  animation:studentAvatarBreathe 3.2s ease-in-out var(--student-avatar-breathe-delay) infinite;
}
.dashboard-student-grid .growth-star-card:not(.name-only) .avatar>.generated-avatar{
  --student-avatar-breathe-base:1.08;
  --student-avatar-breathe-peak:1.145;
}
.dashboard-student-grid .growth-star-card.score-fx-card .avatar>img,
.dashboard-student-grid .growth-star-card.score-fx-card .avatar>.toon-avatar{
  animation-play-state:paused;
}
body.modal-open .dashboard-student-grid .growth-star-card .avatar>img,
body.modal-open .dashboard-student-grid .growth-star-card .avatar>.toon-avatar{
  animation-play-state:paused!important;
  will-change:auto!important;
}
body.student-page-scrolling .dashboard-student-grid .growth-star-card .avatar>img,
body.student-page-scrolling .dashboard-student-grid .growth-star-card .avatar>.toon-avatar{
  animation:none!important;
  transform:scale(var(--student-avatar-breathe-base,1))!important;
  will-change:auto!important;
}
body.modal-open #modal:not(.hidden){
  background:rgba(71,85,105,.48);
  -webkit-backdrop-filter:none;
  backdrop-filter:none;
}
html.modal-open,
body.modal-open{
  overflow:hidden!important;
  overscroll-behavior:none;
}
#modal{
  overscroll-behavior:none;
}
.settings-panel .settings-section,
.settings-panel .settings-student-list>div{
  content-visibility:visible;
  contain-intrinsic-size:none;
}
@keyframes studentAvatarBreathe{
  0%,100%{transform:scale(var(--student-avatar-breathe-base))}
  50%{transform:scale(var(--student-avatar-breathe-peak))}
}
@media(prefers-reduced-motion:reduce){
  .dashboard-student-grid .growth-star-card .avatar>img,
  .dashboard-student-grid .growth-star-card .avatar>.toon-avatar{animation:none!important}
}

/* Group configuration center — isolated from the rest of teacher settings. */
.modal-panel.group-center-modal{
  width:min(1260px,calc(100vw - 36px));
  height:min(88vh,820px);
  max-height:88vh;
  padding:0;
  overflow:hidden;
  border:1px solid rgba(255,255,255,.9);
  border-radius:24px;
  background:#f8fafc;
}
.group-center-modal>.modal-close{display:none}
.group-center-modal #modalContent{width:100%;height:100%;min-height:0;display:block}
.group-center{position:relative;height:100%;display:flex;flex-direction:column;color:#334155;background:#f8fafc}
.group-center button,.group-center input{font:inherit}
.group-center-head{position:relative;flex:0 0 auto;padding:23px 28px 18px;border-bottom:1px solid #e6ebf2;background:#f8fafc}
.group-center-head h2{margin:0;color:#1e293b;font-size:24px;font-weight:950;letter-spacing:-.02em}
.group-center-head p{margin:4px 0 0;color:#8290a5;font-size:13px;font-weight:700}
.group-center-head nav{display:flex;gap:10px;margin-top:18px}
.group-center-head nav button{height:43px;display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:0 17px;border:1px solid #dbe3ee;border-radius:999px;background:#fff;color:#526174;font-size:14px;font-weight:900;transition:.18s ease}
.group-center-head nav button svg{width:20px;height:20px;flex:none}
.group-center-head nav button:hover{border-color:var(--theme-border);background:var(--theme-soft);color:var(--theme);transform:translateY(-1px)}
.group-center-head nav button.active{border-color:transparent;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 8px 18px var(--theme-shadow)}
.group-center-close{position:absolute;top:23px;right:26px;width:38px;height:38px;display:grid;place-items:center;border:0;border-radius:50%;background:transparent;color:#64748b;font-size:28px;font-weight:300;line-height:1}
.group-center-close:hover{background:#eef2f7;color:#334155}
.group-center-body{flex:1;min-height:0;padding:26px 28px;overflow:hidden;background:#fff}
.group-center-body.single-panel{overflow:auto}
.group-assign-layout{height:100%;display:grid;grid-template-columns:330px minmax(0,1fr);gap:18px}
.group-student-list,.group-pick-panel,.group-manage-left,.group-member-panel{min-height:0;border:1px solid #dbe4f0;border-radius:16px;background:#fff;overflow:hidden}
.group-student-list{display:flex;flex-direction:column}
.group-search{height:72px;display:flex;align-items:center;gap:10px;flex:0 0 auto;margin:0;padding:13px 14px;border-bottom:1px solid #e8edf4;background:#f8fafc;color:#94a3b8}
.group-search svg{width:21px;height:21px;flex:none;margin-left:3px}
.group-search input{width:100%;height:44px;border:1px solid #dbe3ee;border-radius:11px;outline:0;background:#fff;color:#334155;padding:0 12px;font-weight:750}
.group-search input:focus{border-color:var(--theme);box-shadow:0 0 0 3px var(--theme-soft)}
#groupStudentRows{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain}
#groupStudentRows::-webkit-scrollbar,.group-edit-list-wide::-webkit-scrollbar,.group-member-list::-webkit-scrollbar{width:8px}
#groupStudentRows::-webkit-scrollbar-thumb,.group-edit-list-wide::-webkit-scrollbar-thumb,.group-member-list::-webkit-scrollbar-thumb{border:2px solid #fff;border-radius:999px;background:#cbd5e1}
.group-student-row{width:100%;min-height:54px;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:0 15px;border:0;border-bottom:1px solid #edf1f6;background:#fff;color:#334155;text-align:left;transition:.15s}
.group-student-row b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:14px;font-weight:900}
.group-student-row em{max-width:150px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:5px 9px;border-radius:999px;background:#f1f5f9;color:#7c8ba1;font-size:10px;font-style:normal;font-weight:850}
.group-student-row:hover{background:var(--theme-soft)}
.group-student-row.active{background:var(--theme-soft-2);color:var(--theme-text)}
.group-student-row.active em{background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff}
.group-pick-panel{display:flex;flex-direction:column;border-color:var(--theme-border);background:color-mix(in srgb,var(--theme-soft) 55%,#fff)}
.group-pick-title{flex:0 0 auto;padding:22px 20px;border-bottom:1px solid var(--theme-border);background:color-mix(in srgb,var(--theme-soft) 72%,#fff)}
.group-pick-title b{display:block;color:var(--theme-text);font-size:20px;font-weight:950}
.group-pick-title p{margin:7px 0 0;color:var(--theme);font-size:12px;line-height:1.6}
.group-check-grid{display:grid;grid-template-columns:repeat(3,minmax(150px,1fr));gap:12px;align-content:start;padding:20px;overflow:auto}
.group-check-card{min-height:64px;display:flex;align-items:center;gap:11px;padding:13px 15px;border:1px solid var(--theme-border);border-radius:13px;background:#fff;color:#334155;cursor:pointer;transition:.16s}
.group-check-card:hover{transform:translateY(-1px);box-shadow:0 7px 16px var(--theme-shadow)}
.group-check-card input{position:absolute;opacity:0;pointer-events:none}
.fake-check{width:23px;height:23px;display:grid;place-items:center;flex:none;border:2px solid #aab4c2;border-radius:4px;background:#fff;color:transparent;font-size:15px;font-weight:950}
.group-check-card.checked{border-color:var(--theme);background:#fff;box-shadow:0 0 0 1px var(--theme-border),0 7px 16px var(--theme-shadow)}
.group-check-card.checked .fake-check{border-color:var(--theme);background:var(--theme);color:#fff}
.group-check-card b{font-size:14px;font-weight:900}
.group-choice-icon{width:24px;height:24px;display:grid;place-items:center;flex:none;border-radius:7px;background:var(--theme-soft);color:var(--theme)}
.group-choice-icon svg{width:16px;height:16px;display:block;fill:currentColor}
.group-dot{width:11px;height:11px;display:block;flex:none;border-radius:50%;background:#ef4444}
.group-dot.dot-1{background:#f97316}.group-dot.dot-2{background:#eab308}.group-dot.dot-3{background:#22c55e}.group-dot.dot-4{background:#06b6d4}.group-dot.dot-5{background:#3b82f6}.group-dot.dot-6{background:#8b5cf6}.group-dot.dot-7{background:#ec4899}
.group-center-footer{min-height:66px;display:flex;align-items:center;justify-content:flex-end;gap:10px;flex:0 0 auto;padding:12px 28px;border-top:1px solid #e6ebf2;background:#f8fafc}
.group-center-footer>span{margin-right:auto;color:#64748b;font-size:12px;font-weight:800}
.group-center-footer button{min-width:86px;height:42px;border:1px solid #dbe3ee;border-radius:11px;background:#fff;color:#526174;font-weight:900}
.group-center-footer .primary-button{min-width:150px;border:0;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 7px 16px var(--theme-shadow)}
.group-center-footer .group-finish-button{border:0;background:var(--theme-soft);color:var(--theme-text)}
.group-manage-layout{min-height:100%;display:grid;grid-template-columns:470px minmax(0,1fr);gap:18px}
.group-manage-left{display:flex;flex-direction:column;padding:18px}
.group-create-card{flex:0 0 auto;padding:2px 1px 17px;border-bottom:1px solid #edf1f6}
.group-create-card>b,.group-list-heading>b{color:#475569;font-size:14px;font-weight:950}
.group-create-card p{margin:5px 0 13px;color:#8290a5;font-size:11px;line-height:1.55}
.group-create-card .add-group-row{display:grid;grid-template-columns:minmax(0,1fr) 94px;gap:9px}
.group-create-card input{height:43px;border:1px solid #dbe3ee;border-radius:10px;outline:0;padding:0 12px;color:#334155;font-weight:750}
.group-create-card input:focus{border-color:var(--theme);box-shadow:0 0 0 3px var(--theme-soft)}
.group-create-card button{border:0;border-radius:10px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-weight:900;box-shadow:0 7px 15px var(--theme-shadow)}
.group-list-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 1px 10px}
.group-list-heading span{color:#94a3b8;font-size:10px}
.group-edit-list-wide{display:grid!important;grid-template-columns:1fr!important;grid-auto-rows:max-content;align-content:start;gap:0!important;flex:1;min-height:0;overflow:auto;border:1px solid #e2e8f0;border-radius:12px}
.group-edit-list-wide .group-edit-row{min-height:58px;display:grid;grid-template-columns:24px minmax(72px,1fr) 42px repeat(5,30px);gap:6px;align-items:center;padding:8px 10px;border-bottom:1px solid #edf1f6;background:#fff;cursor:pointer}
.group-edit-list-wide .group-edit-row:last-child{border-bottom:0}
.group-edit-list-wide .group-edit-row.active{background:var(--theme-soft)}
.group-row-icon{width:24px;height:24px;display:grid;place-items:center;border-radius:7px;background:color-mix(in srgb,var(--theme-soft) 80%,#fff);color:var(--theme)}
.group-row-icon svg{width:16px;height:16px;display:block;fill:currentColor}
.group-row-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#334155;font-size:14px;font-weight:950}
.group-edit-list-wide .group-edit-row em{color:var(--theme);font-size:10px;font-style:normal;font-weight:900;text-align:center}
.group-edit-list-wide .group-edit-row button{width:30px;height:30px;display:grid;place-items:center;padding:0!important;border:0!important;border-radius:8px!important;background:transparent!important;color:#718198!important;font-size:13px!important}
.group-edit-list-wide .group-edit-row button svg{width:18px;height:18px;display:block;pointer-events:none}
.group-edit-list-wide .group-edit-row button:hover:not(:disabled){background:#fff!important;color:var(--theme)!important;box-shadow:0 3px 10px rgba(100,116,139,.12)}
.group-edit-list-wide .group-edit-row button:disabled{opacity:.28}
.group-edit-list-wide .group-edit-row .group-icon-button{color:var(--theme)!important}
.group-edit-list-wide .group-edit-row .group-edit-button{color:var(--theme)!important}
.group-edit-list-wide .group-edit-row .group-delete-button{color:#e11d48!important}
.group-edit-list-wide .group-edit-row.editing{display:block;min-height:66px;padding:9px;background:var(--theme-soft);cursor:default}
.group-edit-inline{display:grid;grid-template-columns:minmax(0,1fr) 76px 62px;gap:9px;align-items:center}
.group-edit-inline input{width:100%;height:46px;min-width:0;border:1px solid var(--theme);border-radius:11px;outline:0;background:#fff;color:#334155;padding:0 13px;font-size:14px;font-weight:900;box-shadow:0 0 0 3px var(--theme-soft)}
.group-edit-list-wide .group-edit-row .group-edit-inline button{width:100%!important;height:46px!important;border-radius:11px!important;font-size:13px!important;font-weight:950!important}
.group-edit-list-wide .group-edit-row .group-edit-inline .group-rename-confirm{background:linear-gradient(135deg,var(--theme-2),var(--theme))!important;color:#fff!important;box-shadow:0 7px 15px var(--theme-shadow)}
.group-edit-list-wide .group-edit-row .group-edit-inline .group-rename-cancel{background:#f1f5f9!important;color:#475569!important}
.group-icon-picker-backdrop{position:absolute;inset:0;z-index:30;display:grid;place-items:center;padding:22px;background:rgba(30,41,59,.38);backdrop-filter:blur(5px)}
.group-icon-picker{width:min(570px,calc(100% - 24px));overflow:hidden;border:1px solid rgba(255,255,255,.9);border-radius:22px;background:#fff;box-shadow:0 26px 70px rgba(30,41,59,.3)}
.group-icon-picker header{min-height:82px;display:flex;align-items:center;justify-content:space-between;gap:18px;padding:17px 21px;border-bottom:1px solid #e8edf4;background:linear-gradient(135deg,#fff,var(--theme-soft))}
.group-icon-picker header b{display:block;color:#1e293b;font-size:19px;font-weight:950}
.group-icon-picker header p{margin:4px 0 0;color:var(--theme);font-size:12px;font-weight:850}
.group-icon-picker header button{width:38px;height:38px;display:grid;place-items:center;flex:none;border:0;border-radius:50%;background:#fff;color:#8290a5;font-size:25px;line-height:1;box-shadow:0 4px 12px rgba(100,116,139,.1)}
.group-icon-picker-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px;padding:20px}
.group-icon-picker-grid button{height:78px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:7px;min-width:0;border:1px solid var(--theme-border);border-radius:14px;background:#fff;color:var(--theme);transition:.16s ease}
.group-icon-picker-grid button svg{width:26px;height:26px;display:block;fill:currentColor;pointer-events:none}
.group-icon-picker-grid button span{color:#64748b;font-size:11px;font-weight:850;pointer-events:none}
.group-icon-picker-grid button:hover{transform:translateY(-2px);background:var(--theme-soft);box-shadow:0 8px 18px var(--theme-shadow)}
.group-icon-picker-grid button.active{border-color:transparent;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 8px 18px var(--theme-shadow)}
.group-icon-picker-grid button.active span{color:#fff}
.sidebar-groups button span svg{width:22px;height:22px;display:block;fill:currentColor}
.group-member-panel{display:flex;flex-direction:column}
.group-member-title{min-height:84px;display:flex;align-items:center;gap:12px;padding:16px 18px;border-bottom:1px solid #e8edf4;background:#fff}
.group-member-title>svg{width:25px;height:25px;flex:none;color:var(--theme)}
.group-member-title b{font-size:15px;font-weight:950}
.group-member-title p{margin:5px 0 0;color:#8290a5;font-size:11px;line-height:1.5}
.group-member-list{flex:1;min-height:0;overflow:auto}
.group-member-list>div:not(.group-empty-state){min-height:52px;display:flex;align-items:center;justify-content:space-between;gap:15px;padding:0 18px;border-bottom:1px solid #edf1f6}
.group-member-list b{font-size:13px;font-weight:900}
.group-member-list em{padding:5px 9px;border-radius:999px;background:#f1f5f9;color:#718198;font-size:10px;font-style:normal;font-weight:850}
.group-random-panel{display:grid;gap:18px}
.group-random-warning{display:flex;gap:14px;padding:22px;border:1px solid #fecdd3;border-radius:16px;background:#fff1f2;color:#be123c}
.group-random-warning>span{width:27px;height:27px;display:grid;place-items:center;flex:none;border:2px solid #f43f5e;border-radius:50%;font-weight:950}
.group-random-warning b{font-size:15px;font-weight:950}
.group-random-warning p{margin:6px 0 0;font-size:12px;line-height:1.7}
.group-random-control{min-height:94px;display:flex;align-items:center;gap:12px;padding:17px 20px;border-radius:15px;background:#fff;box-shadow:0 5px 18px rgba(100,116,139,.07)}
.group-random-control>div{margin-right:auto}
.group-random-control b{font-size:14px;font-weight:950}
.group-random-control p{margin:5px 0 0;color:#94a3b8;font-size:11px}
.group-random-control label{display:flex;align-items:center;gap:8px;color:#526174;font-weight:900}
.group-random-control input{width:92px;height:44px;border:1px solid #fecdd3;border-radius:10px;outline:0;padding:0 12px;color:#334155;font-weight:900}
.group-random-control button{height:44px;padding:0 18px;border:0;border-radius:10px;background:#e11d48;color:#fff;font-weight:900;box-shadow:0 7px 15px rgba(225,29,72,.2)}
.group-random-control button:disabled{opacity:.45;cursor:not-allowed}
.group-empty-state{padding:40px 20px;color:#94a3b8;text-align:center;font-size:12px}
@media(max-width:900px){.modal-panel.group-center-modal{width:calc(100vw - 20px);height:92vh;max-height:92vh}.group-center-head{padding:18px 20px 14px}.group-center-body{padding:16px}.group-assign-layout{grid-template-columns:260px minmax(0,1fr)}.group-check-grid{grid-template-columns:repeat(2,minmax(130px,1fr));padding:14px}.group-manage-layout{grid-template-columns:390px minmax(0,1fr)}.group-center-footer{padding:10px 18px}}
@media(max-width:680px){.group-center-head nav{gap:6px}.group-center-head nav button{height:39px;padding:0 10px;font-size:12px}.group-center-head nav button svg{width:17px;height:17px}.group-center-body{overflow:auto}.group-assign-layout,.group-manage-layout{height:auto;grid-template-columns:1fr}.group-student-list{height:250px}.group-pick-panel{min-height:330px}.group-check-grid{grid-template-columns:1fr}.group-manage-left{min-height:510px}.group-member-panel{min-height:300px}.group-center-footer>span{display:none}.group-random-control{align-items:stretch;flex-direction:column}.group-random-control>div{margin:0}.group-random-control label{justify-content:flex-end}.group-random-control button{width:100%}.group-icon-picker-backdrop{padding:10px}.group-icon-picker{width:100%}.group-icon-picker-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:7px;padding:14px}.group-icon-picker-grid button{height:70px}}

/* 真人头像管理：仅头像相关界面 */
.default-student-avatar{width:100%;height:100%;display:grid;place-items:center;border-radius:50%;overflow:hidden;background:linear-gradient(145deg,#f8fafc,#e2e8f0);color:#94a3b8;text-shadow:none}
.default-student-avatar svg{width:68%;height:68%;display:block;fill:currentColor}
.avatar>.default-student-avatar,.mini-avatar-inner>.default-student-avatar{width:100%;height:100%}
.student-photo{width:100%;height:100%;display:block;border-radius:50%;object-fit:cover}

.avatar-manager-toolbar{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:18px 20px;border-bottom:1px solid var(--theme-border);background:linear-gradient(135deg,var(--theme-soft),rgba(255,255,255,.96))}
.avatar-manager-toolbar b{display:block;color:#334155;font-size:16px;font-weight:950}
.avatar-manager-toolbar p{margin:5px 0 0;color:#8492a6;font-size:12px}
.avatar-batch-upload{height:42px;display:inline-flex;align-items:center;justify-content:center;flex:none;padding:0 18px;border:1px solid var(--theme-border);border-radius:13px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-size:13px;font-weight:900;box-shadow:0 8px 18px var(--theme-shadow);cursor:pointer}
.avatar-batch-upload input,.avatar-row-actions input{display:none!important}
.avatar-student-row{grid-template-columns:56px minmax(120px,1fr) 128px 210px 130px 92px!important;gap:14px;min-height:72px;padding:10px 18px!important}
.avatar-manager-preview{width:48px;height:48px;border:2px solid #fff;box-shadow:0 0 0 1px var(--theme-border),0 5px 12px rgba(100,116,139,.12)}
.avatar-student-name{min-width:0}
.avatar-student-name b,.avatar-student-name small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.avatar-student-name b{color:#334155;font-size:14px;font-weight:900}
.avatar-student-name small{margin-top:3px;color:#94a3b8;font-size:11px}
.avatar-status{width:max-content;max-width:100%;padding:6px 9px;border-radius:999px;background:#f1f5f9;color:#7c8ba1;font-size:10px;font-weight:850;white-space:nowrap}
.avatar-status.uploaded{background:var(--theme-soft);color:var(--theme-text)}
.avatar-row-actions{display:flex;align-items:center;gap:8px}
.avatar-row-actions .upload-label,.avatar-remove-button{height:34px;display:inline-flex;align-items:center;justify-content:center;padding:0 12px;border:1px solid var(--theme-border);border-radius:10px;background:#fff;color:var(--theme-text);font-size:11px;font-weight:900;cursor:pointer}
.avatar-row-actions .upload-label:hover{background:var(--theme-soft)}
.avatar-remove-button{border-color:#fecdd3;color:#e11d48}
.avatar-remove-button:disabled{border-color:#e2e8f0;background:#f8fafc;color:#cbd5e1;cursor:not-allowed}
.avatar-level-label{color:#6f7e93;font-size:11px;font-weight:850;white-space:nowrap}
.avatar-student-row .row-action{color:var(--theme-text);font-size:11px;font-weight:850;white-space:nowrap}

.modal-panel.avatar-crop-modal{width:min(540px,calc(100vw - 28px));padding:28px 32px;overflow:hidden}
.avatar-cropper{text-align:center}
.avatar-cropper header h2{font-size:22px}
.avatar-cropper header p{margin:5px 0 18px;color:#94a3b8;font-size:13px}
.avatar-crop-stage{position:relative;width:286px;height:286px;margin:0 auto;display:grid;place-items:center;border-radius:50%;background:repeating-conic-gradient(from 0deg,#f8fafc 0 12deg,#eef2f7 12deg 24deg);box-shadow:0 0 0 10px var(--theme-soft),0 0 0 12px var(--theme-border),0 16px 35px rgba(51,65,85,.16);overflow:hidden}
.avatar-crop-stage canvas{width:286px;height:286px;display:block;cursor:grab;touch-action:none}
.avatar-crop-stage canvas:active{cursor:grabbing}
.avatar-crop-stage i{position:absolute;inset:0;border:3px solid rgba(255,255,255,.9);border-radius:50%;box-shadow:inset 0 0 0 1px var(--theme-border);pointer-events:none}
.avatar-zoom-control{display:grid;grid-template-columns:44px 1fr 48px;align-items:center;gap:10px;margin:28px 0 0;color:#64748b;font-size:12px;font-weight:850}
.avatar-zoom-control input{width:100%;accent-color:var(--theme)}
.avatar-zoom-control b{color:var(--theme-text);text-align:right}
.avatar-crop-tip{margin:12px 0 20px;color:#94a3b8;font-size:11px}
.avatar-crop-actions,.batch-avatar-manager footer{display:flex;justify-content:flex-end;gap:10px}
.avatar-crop-actions button,.batch-avatar-manager footer button{height:42px;padding:0 18px;border:1px solid #e2e8f0;border-radius:12px;background:#fff;color:#64748b;font-weight:900}
.avatar-crop-actions .primary-button,.batch-avatar-manager footer .primary-button{border-color:transparent;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 8px 18px var(--theme-shadow)}

.modal-panel.avatar-batch-modal{width:min(980px,calc(100vw - 30px));height:min(760px,90vh);padding:0;overflow:hidden}
.avatar-batch-modal #modalContent{height:100%}
.batch-avatar-manager{height:100%;display:flex;flex-direction:column}
.batch-avatar-manager>header{padding:24px 28px 18px;border-bottom:1px solid #edf1f6}
.batch-avatar-manager>header h2{font-size:22px}
.batch-avatar-manager>header p{margin:6px 0 0;color:#8a98ac;font-size:12px}
.batch-avatar-list{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;padding:14px 22px;background:#f8fafc}
.batch-avatar-row{display:grid;grid-template-columns:62px minmax(150px,1fr) minmax(150px,210px) 92px 36px;align-items:center;gap:13px;min-height:82px;margin-bottom:9px;padding:10px 12px;border:1px solid #e2e8f0;border-radius:16px;background:#fff}
.batch-avatar-row.has-error{border-color:#fda4af;background:#fff7f7}
.batch-avatar-row>img{width:58px;height:58px;border-radius:50%;object-fit:cover;box-shadow:0 0 0 2px #fff,0 0 0 3px var(--theme-border)}
.batch-avatar-row>div{min-width:0}
.batch-avatar-row b,.batch-avatar-row small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.batch-avatar-row b{color:#334155;font-size:13px}
.batch-avatar-row small{margin-top:4px;color:#94a3b8;font-size:10px}
.batch-avatar-row.has-error small{color:#e11d48}
.batch-avatar-row.picker-open{position:relative;z-index:20;border-color:var(--theme-border);box-shadow:0 8px 22px var(--theme-shadow)}
.batch-student-picker{position:relative;min-width:0}
.batch-student-trigger{width:100%;height:40px;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:0 11px;border:1px solid #dbe3ee;border-radius:11px;background:#fff;color:#475569;outline:0;font-size:12px;font-weight:800;cursor:pointer}
.batch-student-trigger span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.batch-student-trigger svg{width:16px;height:16px;flex:0 0 auto;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;transition:transform .18s ease}
.batch-student-picker.open .batch-student-trigger{border-color:var(--theme);box-shadow:0 0 0 3px var(--theme-soft);color:var(--theme-text)}
.batch-student-picker.open .batch-student-trigger svg{transform:rotate(180deg)}
.batch-student-menu{position:absolute;top:calc(100% + 7px);right:0;z-index:40;width:max(100%,240px);display:none;padding:9px;border:1px solid var(--theme-border);border-radius:14px;background:#fff;box-shadow:0 16px 36px rgba(51,65,85,.18),0 6px 18px var(--theme-shadow)}
.batch-student-picker.open .batch-student-menu{display:block}
.batch-student-picker.open-up .batch-student-menu{top:auto;bottom:calc(100% + 7px)}
.batch-student-search{height:38px;display:flex;align-items:center;gap:7px;padding:0 10px;border:1px solid #e2e8f0;border-radius:10px;background:#f8fafc}
.batch-student-search:focus-within{border-color:var(--theme);background:#fff;box-shadow:0 0 0 3px var(--theme-soft)}
.batch-student-search svg{width:15px;height:15px;flex:0 0 auto;fill:none;stroke:var(--theme);stroke-width:2;stroke-linecap:round}
.batch-student-search input{width:100%;min-width:0;border:0;outline:0;background:transparent;color:#334155;font-size:12px;font-weight:750}
.batch-student-search input::placeholder{color:#a8b3c2}
.batch-student-options{max-height:220px;overflow:auto;margin-top:7px;padding-right:2px}
.batch-student-option{width:100%;min-height:36px;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:0 10px;border:0;border-radius:9px;background:transparent;color:#475569;font-size:12px;font-weight:800;text-align:left;cursor:pointer}
.batch-student-option:hover:not(:disabled),.batch-student-option.selected{background:var(--theme-soft);color:var(--theme-text)}
.batch-student-option em{color:var(--theme);font-size:9px;font-style:normal}
.batch-student-option:disabled{color:#b8c1ce;cursor:not-allowed}
.batch-student-option:disabled em{color:#b8c1ce}
.batch-student-option[hidden]{display:none}
.batch-student-empty{margin:16px 0;color:#9aa7b8;font-size:11px;text-align:center}
.batch-student-empty[hidden]{display:none}
.batch-student-clear{width:100%;height:34px;margin-top:7px;border:0;border-top:1px solid #edf1f6;background:#fff;color:var(--theme-text);font-size:11px;font-weight:850;cursor:pointer}
.batch-student-clear:hover{background:var(--theme-soft)}
.batch-avatar-row>button{height:38px;border:1px solid var(--theme-border);border-radius:10px;background:var(--theme-soft);color:var(--theme-text);font-size:11px;font-weight:900}
.batch-avatar-row .batch-avatar-remove{width:36px;padding:0;border-color:#fecdd3;background:#fff1f2;color:#e11d48;font-size:19px}
.batch-avatar-manager footer{padding:15px 24px;border-top:1px solid #e8edf4;background:#fff}

@media(max-width:900px){
  .avatar-student-row{grid-template-columns:52px minmax(110px,1fr) 118px 190px 85px!important}.avatar-level-label{display:none}.avatar-student-row .row-action{display:block!important}
  .batch-avatar-row{grid-template-columns:58px minmax(120px,1fr) 170px 78px 34px}
}
@media(max-width:680px){
  .avatar-manager-toolbar{align-items:flex-start;padding:15px}.avatar-manager-toolbar p{max-width:220px}.avatar-batch-upload{height:38px;padding:0 12px}
  .avatar-student-row{grid-template-columns:46px minmax(90px,1fr) 92px!important;gap:10px;min-height:106px}.avatar-manager-preview{width:42px;height:42px}.avatar-status{font-size:9px}.avatar-row-actions{grid-column:2/4;display:flex!important}.avatar-row-actions .upload-label,.avatar-remove-button{height:31px;padding:0 9px}.avatar-level-label,.avatar-student-row .row-action{display:none!important}
  .modal-panel.avatar-crop-modal{padding:24px 18px}.avatar-crop-stage,.avatar-crop-stage canvas{width:240px;height:240px}
  .modal-panel.avatar-batch-modal{height:92vh}.batch-avatar-manager>header{padding:20px 18px 14px}.batch-avatar-list{padding:10px}.batch-avatar-row{grid-template-columns:52px minmax(0,1fr) 34px;gap:9px}.batch-avatar-row>img{width:48px;height:48px}.batch-student-picker{grid-column:2/4}.batch-student-menu{width:min(280px,calc(100vw - 52px))}.batch-avatar-row>button:not(.batch-avatar-remove){grid-column:2/3}.batch-avatar-manager footer{padding:12px}
}

/* 课堂工具与随机点名 */
.modal-panel.tool-center-modal,.modal-panel.random-picker-modal,.modal-panel.countdown-timer-modal,.modal-panel.task-checkin-modal,.modal-panel.sound-reactive-modal{padding:0!important;overflow:hidden!important;border-color:color-mix(in srgb,var(--theme-border) 70%,white);background:#fff}
.modal-panel.tool-center-modal{width:min(690px,calc(100vw - 30px));height:min(820px,calc(100dvh - 36px));max-height:calc(100dvh - 36px)}
.modal-panel.random-picker-modal,.modal-panel.countdown-timer-modal,.modal-panel.task-checkin-modal,.modal-panel.sound-reactive-modal{width:min(960px,calc(100vw - 30px));height:min(780px,92vh);max-height:92vh}
.tool-center-modal #modalContent,.random-picker-modal #modalContent,.countdown-timer-modal #modalContent,.task-checkin-modal #modalContent,.sound-reactive-modal #modalContent{height:100%;min-height:0}
.tool-center-modal .modal-close,.random-picker-modal .modal-close,.countdown-timer-modal .modal-close,.task-checkin-modal .modal-close,.sound-reactive-modal .modal-close{z-index:5;top:18px;right:18px;background:rgba(255,255,255,.18);color:#fff;box-shadow:inset 0 0 0 1px rgba(255,255,255,.22)}
.tool-center{height:100%;min-height:0;display:flex;flex-direction:column;overflow:hidden;background:linear-gradient(180deg,var(--theme-soft),#fff 52%)}
.tool-center-head,.random-picker-head{min-height:142px;display:flex;align-items:center;gap:17px;padding:25px 76px 25px 32px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff}
.tool-center-mark{width:68px;height:68px;display:grid;place-items:center;flex:0 0 auto;border-radius:21px;background:rgba(255,255,255,.2);box-shadow:inset 0 0 0 1px rgba(255,255,255,.12);font-size:34px;font-weight:950}
.tool-center-head h2,.random-picker-head h2{margin:0!important;color:#fff!important;font-size:28px}
.tool-center-head p,.random-picker-head p{margin:6px 0 0;color:rgba(255,255,255,.78);font-size:13px;font-weight:750}
.tool-center-list{flex:1;min-height:0;display:grid;gap:14px;overflow-x:hidden;overflow-y:auto;padding:32px;overscroll-behavior:contain}
.tool-center-card{width:100%;min-height:112px;display:grid;grid-template-columns:72px minmax(0,1fr) auto;align-items:center;gap:20px;padding:18px 22px;border:1px solid color-mix(in srgb,var(--theme-border) 62%,#e2e8f0);border-radius:22px;background:rgba(255,255,255,.92);color:#334155;text-align:left;box-shadow:0 8px 22px rgba(51,65,85,.06);transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease}
button.tool-center-card:hover{transform:translateY(-2px);border-color:var(--theme);box-shadow:0 13px 28px var(--theme-shadow)}
.tool-card-icon{width:70px;height:70px;display:grid;place-items:center;border-radius:20px;color:#fff;font-size:34px;font-weight:950;box-shadow:0 9px 19px var(--theme-shadow)}
.random-icon,.timer-icon,.task-checkin-icon,.sound-reactive-icon{background:linear-gradient(145deg,var(--theme-2),var(--theme))}
.tool-center-card b,.tool-center-card small{display:block}.tool-center-card b{font-size:19px}.tool-center-card small{margin-top:7px;color:#94a3b8;font-size:12px;font-weight:700}.tool-center-card>i{color:var(--theme);font-size:30px;font-style:normal}.tool-center-card>em{padding:6px 10px;border-radius:999px;background:#f1f5f9;color:#94a3b8;font-size:10px;font-style:normal;font-weight:900}
.desktop-seating-tool-card{grid-template-columns:72px minmax(0,1fr) auto auto}.seating-icon{background:linear-gradient(145deg,var(--theme-2),var(--theme))}
.tool-card-coming{opacity:.68}.tool-center-card:disabled{cursor:not-allowed;opacity:.55}
.random-picker-shell{height:100%;display:flex;flex-direction:column;background:linear-gradient(180deg,#fff,var(--theme-soft))}
.random-picker-head{min-height:116px;padding-block:19px}.random-picker-head .tool-center-mark{width:62px;height:62px;border-radius:19px;font-size:30px}
.random-picker-body{flex:1;min-height:0;overflow:auto;padding:24px 32px 18px;overscroll-behavior:contain}
.random-count-control{width:max-content;max-width:100%;min-height:66px;display:flex;align-items:center;gap:13px;margin:0 auto 20px;padding:10px 15px 10px 19px;border:1px solid var(--theme-border);border-radius:20px;background:#fff;box-shadow:0 7px 20px rgba(51,65,85,.06);color:#64748b;font-weight:900}
.random-count-control button{width:42px;height:42px;border:1px solid #e2e8f0;border-radius:50%;background:#fff;color:var(--theme-text);font-size:22px;font-weight:900}.random-count-control button:not(:disabled):hover{border-color:var(--theme);background:var(--theme-soft)}.random-count-control button:disabled{color:#cbd5e1;cursor:not-allowed}.random-count-control>b{min-width:26px;color:var(--theme);font-size:24px;text-align:center}.random-count-control small{color:#a3afbf;font-size:10px}
.random-pick-stage{min-height:390px;display:grid;place-items:center;padding:24px;border:1px solid var(--theme-border);border-radius:34px;background:radial-gradient(circle at 50% 46%,var(--theme-soft-2),#fff 58%);box-shadow:inset 0 0 50px rgba(255,255,255,.75);text-align:center}
.random-pick-placeholder{display:grid;justify-items:center;color:#94a3b8}.random-pick-placeholder>span{width:110px;height:110px;display:grid;place-items:center;border-radius:32px;background:linear-gradient(145deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 17px 34px var(--theme-shadow);font-size:52px}.random-pick-placeholder b{margin-top:25px;color:#64748b;font-size:20px}.random-pick-placeholder p{margin:7px 0 0;font-size:13px}
.random-results-grid{width:100%;display:grid;grid-template-columns:repeat(auto-fit,minmax(145px,1fr));align-items:center;justify-content:center;gap:20px}.random-results-grid.single-result{max-width:310px;margin:auto;grid-template-columns:1fr}
.random-student-result{min-width:0;display:grid;justify-items:center;align-content:center;padding:18px;border:1px solid var(--theme-border);border-radius:28px;background:rgba(255,255,255,.94);box-shadow:0 15px 34px var(--theme-shadow);animation:randomReveal .42s cubic-bezier(.2,.8,.2,1)}
.random-student-result.is-rolling{animation:randomRolling .18s ease-in-out infinite alternate;box-shadow:0 9px 24px rgba(51,65,85,.1)}
.random-result-avatar{width:142px;height:142px;display:grid;place-items:center;overflow:hidden;border:7px solid #fff;border-radius:32px;background:var(--theme-soft);box-shadow:0 0 0 5px var(--theme),0 13px 27px var(--theme-shadow)}.random-result-avatar img,.random-result-avatar .generated-avatar,.random-result-avatar .student-photo{width:100%;height:100%;object-fit:cover}.random-student-result>strong{max-width:100%;margin-top:18px;overflow:hidden;color:var(--theme-text);font-size:24px;text-overflow:ellipsis;white-space:nowrap}.random-student-result>small{margin-top:5px;color:#94a3b8;font-size:11px;font-weight:800}
.random-student-result.name-result{min-height:205px;background:linear-gradient(145deg,#fff,var(--theme-soft))}.random-student-result.name-result>span{color:var(--theme);font-size:11px;font-weight:900;letter-spacing:.18em}.random-student-result.name-result>strong{margin-top:13px;font-size:clamp(28px,5vw,52px);white-space:normal;overflow-wrap:anywhere}
.random-result-message{grid-column:1/-1;width:max-content;max-width:100%;margin:20px auto 0;padding:10px 22px;border:1px solid var(--theme-border);border-radius:999px;background:#fff;color:var(--theme-text);font-size:14px;font-weight:900}
.random-picker-footer{min-height:88px;display:flex;align-items:center;justify-content:center;gap:12px;padding:15px 24px calc(15px + env(safe-area-inset-bottom,0px));border-top:1px solid #e8edf4;background:rgba(255,255,255,.96)}.random-picker-footer button{min-width:140px;min-height:46px;border-radius:14px;font-weight:900}.random-back-button{border:1px solid #dbe3ee;background:#fff;color:#64748b}.random-start-button{border:0;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 10px 22px var(--theme-shadow)}.random-start-button:disabled{opacity:.6;cursor:wait}
.tool-fullscreen-button{border:1px solid var(--theme-border)!important;background:var(--theme-soft)!important;color:var(--theme-text)!important}.tool-fullscreen-button:hover{border-color:var(--theme)!important;box-shadow:0 7px 16px var(--theme-shadow)}.tool-fullscreen-button[aria-pressed="true"]{border-color:var(--theme)!important;background:var(--theme-soft)!important;color:var(--theme-text)!important}
@keyframes randomReveal{from{opacity:0;transform:translateY(18px) scale(.88)}to{opacity:1;transform:none}}@keyframes randomRolling{from{transform:translateY(-3px) scale(.98)}to{transform:translateY(3px) scale(1.02)}}

/* 任务打卡消消乐：仅保存在当前标签页内存，不触碰班级或云端数据。 */
.task-checkin-shell{height:100%;display:grid;grid-template-rows:auto minmax(0,1fr) auto;background:linear-gradient(180deg,#fff,var(--theme-soft));color:#334155}
.task-checkin-head{min-height:116px;display:flex;align-items:center;gap:17px;padding:19px 76px 19px 32px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff}.task-checkin-head .tool-center-mark{width:62px;height:62px;border-radius:19px;font-size:30px}.task-checkin-head h2{margin:0!important;color:#fff!important;font-size:28px}.task-checkin-head p{margin:6px 0 0;color:rgba(255,255,255,.8);font-size:13px;font-weight:750}
.task-checkin-body{min-height:0;display:grid;grid-template-rows:auto minmax(0,1fr);gap:16px;padding:20px 26px 18px;overflow:hidden}
.task-checkin-summary{display:grid;grid-template-columns:150px 150px minmax(220px,1fr);align-items:stretch;gap:12px}.task-checkin-summary>div{min-width:0;display:flex;align-items:baseline;justify-content:center;gap:6px;padding:14px 16px;border:1px solid var(--theme-border);border-radius:18px;background:rgba(255,255,255,.94);box-shadow:0 7px 18px rgba(51,65,85,.055)}.task-checkin-summary span{color:#64748b;font-size:12px;font-weight:900}.task-checkin-summary strong{color:var(--theme);font-size:27px;line-height:1}.task-checkin-summary small{color:#94a3b8;font-size:10px;font-weight:800}
.task-checkin-summary .task-checkin-progress{display:grid;align-content:center;gap:9px}.task-checkin-progress>span{display:flex;align-items:center;justify-content:space-between}.task-checkin-progress b{color:#64748b;font-size:12px}.task-checkin-progress em{color:var(--theme);font-size:13px;font-style:normal;font-weight:950}.task-checkin-progress>div{height:9px;overflow:hidden;border-radius:999px;background:var(--theme-soft-2)}.task-checkin-progress i{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,var(--theme-2),var(--theme));box-shadow:0 0 12px var(--theme-shadow);transition:width .24s ease}
.task-checkin-stage{min-height:0;overflow:auto;padding:18px;border:1px solid var(--theme-border);border-radius:28px;background:radial-gradient(circle at 50% 38%,var(--theme-soft),#fff 66%);overscroll-behavior:contain;scrollbar-gutter:stable}.task-checkin-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));align-content:start;gap:14px}.task-checkin-name{width:100%;min-width:0;aspect-ratio:1;display:grid;place-items:center;padding:13px;border:1.5px solid color-mix(in srgb,var(--theme-border) 82%,white);border-radius:50%;background:linear-gradient(145deg,#fff,var(--theme-soft));color:var(--theme-text);box-shadow:0 9px 21px var(--theme-shadow);cursor:pointer;transition:transform .18s ease,border-color .18s ease,box-shadow .18s ease}.task-checkin-name:hover{transform:translateY(-3px) scale(1.02);border-color:var(--theme);box-shadow:0 13px 27px var(--theme-shadow)}.task-checkin-name:focus-visible{outline:3px solid color-mix(in srgb,var(--theme) 34%,transparent);outline-offset:3px}.task-checkin-name>span{max-width:100%;display:-webkit-box;overflow:hidden;color:inherit;font-size:clamp(14px,1.45vw,20px);font-weight:950;line-height:1.22;text-align:center;overflow-wrap:anywhere;-webkit-box-orient:vertical;-webkit-line-clamp:2}.task-checkin-name.is-removing{pointer-events:none;animation:taskCheckinRemove .26s ease forwards}
.task-checkin-complete{min-height:100%;display:grid;place-content:center;justify-items:center;color:#64748b;text-align:center}.task-checkin-complete>span{width:104px;height:104px;display:grid;place-items:center;border-radius:50%;background:linear-gradient(145deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 17px 34px var(--theme-shadow);font-size:48px;font-weight:950;animation:taskCheckinComplete .5s cubic-bezier(.2,.8,.2,1)}.task-checkin-complete strong{margin-top:22px;color:var(--theme-text);font-size:27px}.task-checkin-complete p{margin:7px 0 0;color:#94a3b8;font-size:13px}
.task-checkin-footer{min-height:88px;display:flex;align-items:center;justify-content:center;gap:10px;padding:15px 24px calc(15px + env(safe-area-inset-bottom,0px));border-top:1px solid #e8edf4;background:rgba(255,255,255,.96)}.task-checkin-footer button{min-width:138px;min-height:46px;padding:0 16px;border:1px solid #dbe3ee;border-radius:14px;background:#fff;color:#64748b;font-weight:900}.task-checkin-footer button:hover:not(:disabled){border-color:var(--theme);background:var(--theme-soft);color:var(--theme-text)}.task-checkin-footer button:disabled{opacity:.45;cursor:not-allowed}.task-checkin-footer .task-checkin-reset{border-color:#fecdd3;color:#e11d48}.task-checkin-footer .task-checkin-reset:hover:not(:disabled){border-color:#fb7185;background:#fff1f2;color:#be123c}
@keyframes taskCheckinRemove{0%{opacity:1;transform:scale(1)}55%{opacity:.78;transform:scale(1.08)}100%{opacity:0;transform:scale(.25) rotate(8deg)}}@keyframes taskCheckinComplete{from{opacity:0;transform:scale(.55) rotate(-12deg)}to{opacity:1;transform:none}}
@media(min-width:1400px){.task-checkin-grid{grid-template-columns:repeat(8,minmax(0,1fr));gap:12px}.task-checkin-name>span{font-size:clamp(13px,1vw,17px)}}
@media(min-width:681px) and (max-width:1100px){.task-checkin-grid{grid-template-columns:repeat(5,minmax(0,1fr))}}

/* 朗读与安静自习：仅分析本机麦克风音量，不录音、不保存、不上传。 */
.sound-reactive-shell{height:100%;display:grid;grid-template-rows:auto minmax(0,1fr) auto;background:linear-gradient(180deg,#fff,var(--theme-soft));color:#334155}
.sound-reactive-head{min-height:116px;display:flex;align-items:center;gap:17px;padding:19px 76px 19px 32px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff}.sound-reactive-head .tool-center-mark{width:62px;height:62px;border-radius:19px;font-size:30px}.sound-reactive-head h2{margin:0!important;color:#fff!important;font-size:28px}.sound-reactive-head p{margin:6px 0 0;color:rgba(255,255,255,.8);font-size:13px;font-weight:750}
.sound-reactive-body{min-height:0;display:grid;grid-template-columns:minmax(0,1.55fr) minmax(270px,.7fr);gap:16px;padding:18px 20px;overflow:hidden}
.sound-reactive-stage{position:relative;min-width:0;min-height:0;overflow:hidden;border:1px solid var(--theme-border);border-radius:28px;background:radial-gradient(circle at 50% 32%,#fff,var(--theme-soft) 72%);box-shadow:inset 0 0 55px rgba(255,255,255,.72)}.sound-reactive-stage canvas{width:100%;height:100%;display:block}.sound-reactive-banner{position:absolute;top:20px;left:50%;max-width:calc(100% - 42px);transform:translateX(-50%);padding:9px 18px;border:1px solid var(--theme-border);border-radius:999px;background:rgba(255,255,255,.9);color:var(--theme-text);box-shadow:0 8px 22px rgba(51,65,85,.08);font-size:12px;font-weight:900;text-align:center;backdrop-filter:blur(8px);transition:.2s}.sound-reactive-banner.alert{border-color:#fb7185;background:#fff1f2;color:#e11d48;box-shadow:0 8px 24px rgba(244,63,94,.18);transform:translateX(-50%) scale(1.04)}.sound-reactive-state{position:absolute;right:17px;bottom:15px;display:flex;align-items:center;gap:7px;padding:7px 11px;border-radius:999px;background:rgba(255,255,255,.88);color:#64748b;font-size:10px;box-shadow:0 6px 16px rgba(51,65,85,.08)}.sound-reactive-state b{font-size:10px}.sound-state-dot{width:9px;height:9px;border-radius:50%;background:#cbd5e1}.sound-reactive-shell.is-listening .sound-state-dot{background:#22c55e;box-shadow:0 0 0 4px rgba(34,197,94,.12)}.sound-reactive-shell.is-paused .sound-state-dot{background:#f59e0b}
.sound-reactive-controls{min-height:0;overflow:auto;display:grid;align-content:start;gap:13px;padding:15px;border:1px solid var(--theme-border);border-radius:24px;background:rgba(255,255,255,.94);overscroll-behavior:contain}.sound-mode-tabs{display:grid;grid-template-columns:1fr 1fr;gap:7px;padding:5px;border-radius:15px;background:#f1f5f9}.sound-mode-tabs button{min-height:43px;border:0;border-radius:11px;background:transparent;color:#64748b;font-weight:900}.sound-mode-tabs button.active,.sound-mode-tabs button[aria-selected="true"]{background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 6px 15px var(--theme-shadow)}.sound-mode-description{min-height:39px;padding:9px 10px;border-radius:12px;background:var(--theme-soft);color:var(--theme-text);font-size:10px;font-weight:800;line-height:1.55}
.sound-threshold-control,.sound-live-meter,.sound-prompt-control{display:grid;gap:8px}.sound-threshold-control>span,.sound-live-meter>span{display:flex;align-items:center;justify-content:space-between;color:#64748b;font-size:11px}.sound-threshold-control b,.sound-live-meter b{font-size:11px}.sound-threshold-control output,.sound-live-meter output{min-width:34px;padding:3px 7px;border-radius:999px;background:var(--theme-soft);color:var(--theme-text);font-size:11px;font-weight:950;text-align:center}.sound-threshold-control input{width:100%;height:24px;margin:0;accent-color:var(--theme);cursor:pointer}.sound-live-meter>div{height:12px;overflow:hidden;border-radius:999px;background:#e8edf4}.sound-live-meter i{display:block;width:0;height:100%;border-radius:inherit;background:linear-gradient(90deg,var(--theme-2),var(--theme));box-shadow:0 0 12px var(--theme-shadow);transition:width .08s linear}.sound-live-meter>div.over i{background:linear-gradient(90deg,#fb923c,#f43f5e)}.sound-prompt-control>span{color:#64748b;font-size:11px;font-weight:900}.sound-prompt-control input{width:100%;height:42px;padding:0 11px;border:1px solid #dbe3ee;border-radius:12px;background:#fff;color:#334155;font:inherit;font-size:12px;outline:0}.sound-prompt-control input:focus{border-color:var(--theme);box-shadow:0 0 0 3px var(--theme-soft)}.sound-privacy-note{display:grid;grid-template-columns:34px minmax(0,1fr);align-items:center;gap:9px;padding:10px;border:1px solid var(--theme-border);border-radius:13px;background:linear-gradient(135deg,var(--theme-soft),#fff)}.sound-privacy-note>span{width:32px;height:32px;display:grid;place-items:center;border-radius:10px;background:#fff;color:var(--theme);box-shadow:0 4px 10px rgba(51,65,85,.07)}.sound-privacy-note p,.sound-privacy-note b,.sound-privacy-note small{display:block;margin:0}.sound-privacy-note b{color:var(--theme-text);font-size:10px}.sound-privacy-note small{margin-top:3px;color:#94a3b8;font-size:9px;font-weight:700;line-height:1.45}.sound-error-message{display:none;margin:0;padding:9px 10px;border-radius:11px;background:#fff1f2;color:#e11d48;font-size:10px;font-weight:800;line-height:1.45}.sound-error-message.show{display:block}
.sound-reactive-footer{min-height:88px;display:flex;align-items:center;justify-content:center;gap:10px;padding:15px 24px calc(15px + env(safe-area-inset-bottom,0px));border-top:1px solid #e8edf4;background:rgba(255,255,255,.96)}.sound-reactive-footer button{min-width:140px;min-height:46px;padding:0 15px;border-radius:14px;font-weight:900}.sound-primary-button{min-width:170px!important;border:0;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 10px 22px var(--theme-shadow)}.sound-primary-button:disabled{opacity:.62;cursor:wait}

.countdown-timer-shell{height:100%;display:flex;flex-direction:column;background:linear-gradient(180deg,#fff,var(--theme-soft))}
.countdown-timer-head{min-height:116px;display:flex;align-items:center;gap:17px;padding:19px 76px 19px 32px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff}.countdown-timer-head .tool-center-mark{width:62px;height:62px;border-radius:19px;font-size:30px}.countdown-timer-head h2{margin:0!important;color:#fff!important;font-size:28px}.countdown-timer-head p{margin:6px 0 0;color:rgba(255,255,255,.8);font-size:13px;font-weight:750}
.countdown-timer-body{flex:1;min-height:0;overflow:auto;display:grid;align-content:center;justify-items:center;gap:19px;padding:22px 32px;overscroll-behavior:contain}
.timer-presets{display:flex;flex-wrap:wrap;justify-content:center;gap:10px}.timer-presets button{min-width:105px;height:45px;border:1px solid var(--theme-border);border-radius:14px;background:#fff;color:#64748b;font-size:13px;font-weight:900;box-shadow:0 5px 14px rgba(51,65,85,.05)}.timer-presets button:hover:not(:disabled),.timer-presets button.active{border-color:var(--theme);background:var(--theme-soft);color:var(--theme-text);box-shadow:0 7px 17px var(--theme-shadow)}.timer-presets button:disabled{opacity:.5;cursor:not-allowed}
.countdown-clock{--timer-progress:100;position:relative;width:290px;height:290px;display:grid;place-content:center;justify-items:center;border-radius:50%;background:conic-gradient(var(--theme) calc(var(--timer-progress)*1%),var(--theme-soft-2) 0);box-shadow:0 16px 42px var(--theme-shadow);isolation:isolate;transition:background .2s linear}.countdown-clock:before{content:"";position:absolute;inset:13px;z-index:-1;border-radius:50%;background:radial-gradient(circle at 50% 42%,#fff,var(--theme-soft));box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--theme-border) 55%,white)}.countdown-clock:after{content:"";position:absolute;inset:-10px;z-index:-2;border:1px solid var(--theme-border);border-radius:50%;opacity:.55}.countdown-clock strong{color:var(--theme-text);font-size:68px;font-variant-numeric:tabular-nums;letter-spacing:.02em;line-height:1}.countdown-clock span{margin-top:12px;color:#94a3b8;font-size:12px;font-weight:900}.countdown-clock.is-running strong{animation:timerBreath 1.5s ease-in-out infinite}.countdown-clock.is-finished{background:conic-gradient(#f43f5e 100%,#ffe4e6 0);box-shadow:0 16px 45px rgba(244,63,94,.25)}.countdown-clock.is-finished strong,.countdown-clock.is-finished span{color:#e11d48}.countdown-clock.is-finished:after{border-color:#fda4af;animation:timerFinished 1s ease-in-out 3}
.timer-custom{display:grid;grid-template-columns:112px 20px 112px;align-items:center;gap:10px}.timer-custom>i{color:var(--theme);font-size:36px;font-style:normal;font-weight:950;text-align:center}.timer-stepper{display:grid;grid-template-columns:42px 1fr 42px;align-items:center;justify-items:center;gap:5px}.timer-stepper button{width:42px;height:42px;grid-row:1;border:1px solid var(--theme-border);border-radius:13px;background:#fff;color:var(--theme-text);font-size:20px;font-weight:950}.timer-stepper button:first-child{grid-column:1}.timer-stepper b{grid-column:2;grid-row:1;color:#334155;font-size:36px;font-variant-numeric:tabular-nums}.timer-stepper button:nth-of-type(2){grid-column:3}.timer-stepper small{grid-column:1/-1;grid-row:2;color:#94a3b8;font-size:11px;font-weight:900}.timer-stepper button:hover:not(:disabled){border-color:var(--theme);background:var(--theme-soft)}.timer-stepper button:disabled{opacity:.45;cursor:not-allowed}
.countdown-timer-footer{min-height:88px;display:flex;align-items:center;justify-content:center;gap:10px;padding:15px 24px calc(15px + env(safe-area-inset-bottom,0px));border-top:1px solid #e8edf4;background:rgba(255,255,255,.96)}.countdown-timer-footer button{min-width:118px;min-height:46px;border:1px solid #dbe3ee;border-radius:14px;background:#fff;color:#64748b;font-weight:900}.countdown-timer-footer button:disabled{opacity:.45;cursor:not-allowed}.countdown-timer-footer .timer-primary{min-width:170px;border:0;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 10px 22px var(--theme-shadow)}
@keyframes timerBreath{50%{transform:scale(1.025)}}@keyframes timerFinished{50%{transform:scale(1.04);opacity:1}}

@media(max-width:680px){
  .modal-panel.tool-center-modal,.modal-panel.random-picker-modal,.modal-panel.countdown-timer-modal,.modal-panel.task-checkin-modal,.modal-panel.sound-reactive-modal{width:calc(100vw - 12px)!important;height:calc(100dvh - 12px)!important;max-height:calc(100dvh - 12px)!important;border-radius:22px!important}
  .tool-center{min-height:100%;background:linear-gradient(180deg,var(--theme-soft),#fff)}
  .tool-center-head,.random-picker-head{min-height:104px;padding:16px 62px 16px 18px}.tool-center-mark,.random-picker-head .tool-center-mark{width:54px;height:54px;border-radius:17px;font-size:27px}.tool-center-head h2,.random-picker-head h2{font-size:22px}.tool-center-list{padding:18px 14px;gap:11px}.tool-center-card{min-height:98px;grid-template-columns:58px minmax(0,1fr) auto;gap:13px;padding:14px}.tool-card-icon{width:56px;height:56px;border-radius:17px;font-size:28px}.tool-center-card b{font-size:16px}.tool-center-card small{font-size:11px}.tool-center-card>em{display:none}
  .random-picker-body{padding:15px 12px 12px}.random-count-control{min-height:58px;margin-bottom:12px;gap:9px;padding:7px 10px 7px 13px}.random-count-control button{width:40px;height:40px}.random-count-control small{display:none}.random-pick-stage{min-height:calc(100dvh - 300px);padding:16px 10px;border-radius:24px}.random-pick-placeholder>span{width:88px;height:88px;border-radius:26px;font-size:42px}.random-pick-placeholder b{margin-top:20px;font-size:18px}
  .random-results-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.random-results-grid.single-result{max-width:250px;grid-template-columns:1fr}.random-student-result{padding:13px 8px;border-radius:21px}.random-result-avatar{width:105px;height:105px;border-width:5px;border-radius:25px;box-shadow:0 0 0 4px var(--theme),0 10px 20px var(--theme-shadow)}.random-student-result>strong{margin-top:13px;font-size:19px}.random-student-result.name-result{min-height:150px}.random-student-result.name-result>strong{font-size:30px}.random-result-message{margin-top:13px;padding:8px 13px;font-size:12px;white-space:normal}
  .random-picker-footer{min-height:76px;display:grid;grid-template-columns:1fr 1fr;padding:10px 12px calc(10px + env(safe-area-inset-bottom,0px))}.random-picker-footer button{min-width:0;min-height:46px}.random-back-button{width:auto}.random-start-button{grid-column:1/-1;width:100%}
  .countdown-timer-head{min-height:104px;padding:16px 62px 16px 18px}.countdown-timer-head .tool-center-mark{width:54px;height:54px;border-radius:17px;font-size:27px}.countdown-timer-head h2{font-size:22px}.countdown-timer-body{align-content:start;gap:14px;padding:15px 12px 12px}.timer-presets{display:grid;grid-template-columns:repeat(4,1fr);width:100%;gap:6px}.timer-presets button{min-width:0;height:42px;padding:0 5px;font-size:11px}.countdown-clock{width:min(235px,62vw);height:min(235px,62vw)}.countdown-clock strong{font-size:50px}.countdown-clock span{margin-top:8px}.timer-custom{grid-template-columns:104px 15px 104px;gap:5px}.timer-stepper{grid-template-columns:38px 1fr 38px}.timer-stepper button{width:38px;height:38px}.timer-stepper b{font-size:30px}.timer-custom>i{font-size:30px}.countdown-timer-footer{min-height:76px;display:grid;grid-template-columns:1fr 1fr;gap:7px;padding:10px 10px calc(10px + env(safe-area-inset-bottom,0px))}.countdown-timer-footer button{min-width:0;min-height:46px;padding:0 8px}.countdown-timer-footer .timer-primary{min-width:0;width:100%}
  .task-checkin-head{min-height:104px;padding:16px 62px 16px 18px}.task-checkin-head .tool-center-mark{width:54px;height:54px;border-radius:17px;font-size:27px}.task-checkin-head h2{font-size:21px}.task-checkin-head p{font-size:11px}.task-checkin-body{gap:10px;padding:11px 10px 9px}.task-checkin-summary{grid-template-columns:1fr 1fr;gap:7px}.task-checkin-summary>div{padding:10px 8px;border-radius:14px}.task-checkin-summary strong{font-size:22px}.task-checkin-summary .task-checkin-progress{grid-column:1/-1;padding:10px 12px}.task-checkin-stage{padding:12px 9px;border-radius:21px}.task-checkin-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:9px}.task-checkin-name{padding:9px}.task-checkin-name>span{font-size:clamp(13px,3.8vw,17px)}.task-checkin-complete>span{width:82px;height:82px;font-size:38px}.task-checkin-complete strong{margin-top:17px;font-size:22px}.task-checkin-footer{min-height:126px;display:grid;grid-template-columns:1fr 1fr;gap:7px;padding:9px 10px calc(9px + env(safe-area-inset-bottom,0px))}.task-checkin-footer button{min-width:0;min-height:44px;padding:0 7px;font-size:12px}
  .sound-reactive-head{min-height:96px;padding:14px 60px 14px 16px}.sound-reactive-head .tool-center-mark{width:52px;height:52px;border-radius:16px;font-size:25px}.sound-reactive-head h2{font-size:20px}.sound-reactive-head p{font-size:10px}.sound-reactive-body{grid-template-columns:1fr;grid-template-rows:minmax(190px,1fr) auto;gap:9px;padding:9px;overflow:auto}.sound-reactive-stage{min-height:220px;border-radius:21px}.sound-reactive-banner{top:12px;max-width:calc(100% - 24px);padding:7px 12px;font-size:10px}.sound-reactive-state{right:10px;bottom:9px}.sound-reactive-controls{overflow:visible;gap:10px;padding:11px;border-radius:19px}.sound-mode-tabs button{min-height:40px;font-size:12px}.sound-mode-description{min-height:0;padding:8px 9px}.sound-threshold-control input{height:20px}.sound-prompt-control input{height:40px}.sound-privacy-note{padding:8px}.sound-reactive-footer{min-height:126px;display:grid;grid-template-columns:1fr 1fr;gap:7px;padding:9px 10px calc(9px + env(safe-area-inset-bottom,0px))}.sound-reactive-footer button{min-width:0;min-height:44px;padding:0 7px;font-size:12px}.sound-primary-button{grid-column:1/-1;width:100%;min-width:0!important}
}
@media(max-width:360px){.timer-presets{grid-template-columns:repeat(2,1fr)}.countdown-clock{width:205px;height:205px}.countdown-clock strong{font-size:43px}.countdown-timer-body{gap:10px;padding-top:10px}.timer-custom{transform:scale(.92)}.task-checkin-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.task-checkin-name>span{font-size:15px}.sound-reactive-stage{min-height:185px}.sound-reactive-body{grid-template-rows:minmax(175px,.8fr) auto}.sound-privacy-note{display:none}}
@media(prefers-reduced-motion:reduce){.random-student-result,.random-student-result.is-rolling,.countdown-clock.is-running strong,.countdown-clock.is-finished:after,.task-checkin-name.is-removing,.task-checkin-complete>span{animation:none}}

/* Desktop-only temporary smart seating tool. It is isolated from class and cloud data. */
.modal-panel.seating-tool-modal{width:calc(100vw - 34px)!important;height:calc(100dvh - 34px)!important;max-width:1780px!important;max-height:1040px!important;padding:0!important;overflow:hidden!important;border:1px solid color-mix(in srgb,var(--theme-border) 70%,white);border-radius:28px;background:#fff;box-shadow:0 28px 80px rgba(30,41,59,.28)}
.seating-tool-modal #modalContent{height:100%}.seating-tool-modal>.modal-close{z-index:8;top:18px;right:18px;width:42px;height:42px;background:rgba(255,255,255,.18);color:#fff;box-shadow:inset 0 0 0 1px rgba(255,255,255,.24)}
.seating-tool-shell{position:relative;height:100%;display:flex;flex-direction:column;background:linear-gradient(145deg,var(--theme-soft),#fff 44%);color:#334155}
.seating-tool-head{min-height:94px;display:flex;align-items:center;gap:16px;padding:15px 72px 15px 24px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff}.seating-tool-head .tool-center-mark{width:60px;height:60px;border-radius:19px;font-size:29px}.seating-tool-head h2{margin:0!important;color:#fff!important;font-size:27px}.seating-tool-head p{margin:5px 0 0;color:rgba(255,255,255,.82);font-size:12px;font-weight:750}.seating-tool-head>button{margin-left:auto;min-height:42px;padding:0 16px;border:1px solid rgba(255,255,255,.3);border-radius:13px;background:rgba(255,255,255,.15);color:#fff;font-weight:900}.seating-tool-head>button:hover{background:rgba(255,255,255,.24)}
.seating-tool-head-actions{margin-left:auto;display:flex;align-items:center;gap:8px}.seating-tool-head-actions button{min-height:42px;padding:0 16px;border:1px solid rgba(255,255,255,.3);border-radius:13px;background:rgba(255,255,255,.15);color:#fff;font-weight:900;white-space:nowrap}.seating-tool-head-actions button:hover{background:rgba(255,255,255,.24)}.seating-tool-head-actions .tool-fullscreen-button{border-color:rgba(255,255,255,.3)!important;background:rgba(255,255,255,.15)!important;color:#fff!important}.seating-tool-head-actions .tool-fullscreen-button:hover{background:rgba(255,255,255,.24)!important}.seating-tool-head-actions .seating-tool-close{width:42px;min-width:42px;padding:0;border-radius:50%;font-size:24px;line-height:1}
.seating-tool-body{flex:1;min-height:0;display:grid;grid-template-columns:322px minmax(0,1fr)}
.seating-controls{min-height:0;overflow:auto;padding:18px;border-right:1px solid color-mix(in srgb,var(--theme-border) 65%,#e2e8f0);background:rgba(255,255,255,.9);overscroll-behavior:contain}.seating-controls section{margin-bottom:13px;padding:14px;border:1px solid color-mix(in srgb,var(--theme-border) 65%,#e2e8f0);border-radius:17px;background:#fff;box-shadow:0 6px 18px rgba(51,65,85,.045)}.seating-controls h3{margin:0 0 11px;color:var(--theme-text);font-size:14px}.seating-controls p{margin:9px 0 0;color:#94a3b8;font-size:10px;font-weight:700;line-height:1.55}
.seating-field{display:grid;gap:6px;margin-top:9px}.seating-field>span{color:#64748b;font-size:11px;font-weight:900}.seating-field>small{color:#94a3b8;font-size:9px;font-weight:700;line-height:1.45}.seating-field input,.seating-field select,.seating-sheet-choice select{width:100%;height:40px;padding:0 11px;border:1px solid #dbe3ee;border-radius:11px;background:#fff;color:#334155;font:inherit;font-size:12px;outline:0}.seating-field input:focus,.seating-field select:focus,.seating-sheet-choice select:focus{border-color:var(--theme);box-shadow:0 0 0 3px var(--theme-soft)}
.seating-privacy{margin-top:10px;padding:9px 10px;border-radius:11px;background:var(--theme-soft);color:var(--theme-text);font-size:10px;font-weight:800;line-height:1.5}.seating-list-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}.seating-list-actions button{min-height:42px;border-radius:12px;font-weight:900}.seating-download-button{border:1px solid var(--theme-border);background:#fff;color:var(--theme-text)}.seating-download-button:hover{border-color:var(--theme);background:var(--theme-soft)}.seating-import-button{border:0;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 7px 15px var(--theme-shadow)}.seating-import-button:hover{filter:saturate(1.08) brightness(1.02)}.seating-list-help{margin-top:8px!important;color:#64748b!important}.seating-import-report{overflow-wrap:anywhere}.seating-sheet-choice{display:grid;gap:8px;margin-top:10px;padding:10px;border-radius:12px;background:#f8fafc}.seating-sheet-choice label{display:grid;gap:6px;color:#64748b;font-size:10px;font-weight:900}.seating-sheet-choice button{min-height:38px;border:0;border-radius:10px;background:var(--theme);color:#fff;font-weight:900}
.seating-template-layer{position:absolute;inset:0;z-index:20;display:grid;place-items:center;padding:24px;background:rgba(30,41,59,.56);backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px)}.seating-template-card{position:relative;width:min(540px,calc(100vw - 56px));padding:28px;border:1px solid var(--theme-border);border-radius:24px;background:#fff;box-shadow:0 28px 75px rgba(30,41,59,.3);text-align:center}.seating-template-close{position:absolute;top:14px;right:14px;width:38px;height:38px;border:0;border-radius:50%;background:#f1f5f9;color:#64748b;font-size:22px}.seating-template-mark{display:grid;place-items:center;width:58px;height:58px;margin:0 auto 12px;border-radius:18px;background:linear-gradient(145deg,var(--theme-2),var(--theme));color:#fff;font-size:30px;font-weight:950;box-shadow:0 10px 22px var(--theme-shadow)}.seating-template-card h3{margin:0!important;color:var(--theme-text)!important;font-size:24px!important}.seating-template-card>p{margin:9px 0 18px;color:#64748b;font-size:12px;font-weight:700}.seating-template-options{display:grid;gap:10px}.seating-template-options a{display:grid;gap:3px;padding:14px 17px;border:1px solid var(--theme-border);border-radius:14px;background:#fff;color:#334155;text-align:left;text-decoration:none;transition:.18s}.seating-template-options a:hover{transform:translateY(-1px);border-color:var(--theme);background:var(--theme-soft);box-shadow:0 8px 18px var(--theme-shadow)}.seating-template-options b{color:var(--theme-text);font-size:15px}.seating-template-options small{color:#94a3b8;font-size:10px;font-weight:700}.seating-template-done{min-width:112px;min-height:40px;margin-top:18px;border:0;border-radius:12px;background:#e2e8f0;color:#475569;font-weight:900}
.seating-step-row{display:grid;grid-template-columns:1fr 36px 32px 36px;align-items:center;gap:5px;color:#64748b;font-size:11px;font-weight:900}.seating-step-row button{width:36px;height:36px;border:1px solid #dbe3ee;border-radius:10px;background:#fff;color:var(--theme-text);font-size:18px;font-weight:950}.seating-step-row b{text-align:center;color:var(--theme);font-size:18px}.seating-settings-confirm{width:100%;min-height:40px;margin-top:11px;border:0;border-radius:11px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-size:12px;font-weight:950;box-shadow:0 8px 18px var(--theme-shadow)}.seating-settings-confirm:hover{filter:saturate(1.08) brightness(1.02)}.seating-mode-grid{display:grid;grid-template-columns:1fr 1fr;gap:7px}.seating-mode-grid button,.seating-output-actions button{min-height:40px;padding:0 9px;border:1px solid var(--theme-border);border-radius:11px;background:#fff;color:#64748b;font-size:11px;font-weight:900}.seating-mode-grid button:hover,.seating-output-actions button:hover:not(:disabled){border-color:var(--theme);background:var(--theme-soft);color:var(--theme-text)}.seating-mode-grid button.selected{border-color:transparent;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 7px 16px var(--theme-shadow)}.seating-mode-confirm{width:100%;min-height:40px;margin-top:9px;border:0;border-radius:11px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-size:12px;font-weight:950;box-shadow:0 8px 18px var(--theme-shadow)}.seating-mode-confirm:hover{filter:saturate(1.08) brightness(1.02)}.seating-output-actions{display:grid;grid-template-columns:1fr 1fr;gap:7px}.seating-output-actions h3{grid-column:1/-1}.seating-export-privacy{grid-column:1/-1;min-height:54px;display:grid;grid-template-columns:34px minmax(0,1fr);align-items:center;gap:9px;padding:8px 10px;border:1px solid var(--theme-border);border-radius:12px;background:linear-gradient(135deg,var(--theme-soft),#fff);cursor:pointer}.seating-export-privacy input{width:32px;height:20px;margin:0;accent-color:var(--theme);cursor:pointer}.seating-export-privacy span,.seating-export-privacy b,.seating-export-privacy small{display:block;min-width:0}.seating-export-privacy b{color:var(--theme-text);font-size:11px}.seating-export-privacy small{margin-top:2px;color:#94a3b8;font-size:9px;font-weight:750}.seating-output-actions button:disabled{opacity:.45;cursor:not-allowed}
.seating-workspace{min-width:0;min-height:0;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto minmax(0,1fr) auto;padding:18px 20px 15px}.seating-workspace-title{display:flex;align-items:center;justify-content:space-between;gap:15px;padding:0 2px 13px}.seating-workspace-title b,.seating-workspace-title small{display:block}.seating-workspace-title b{max-width:680px;overflow:hidden;color:var(--theme-text);font-size:20px;text-overflow:ellipsis;white-space:nowrap}.seating-workspace-title small{margin-top:3px;color:#94a3b8;font-size:10px;font-weight:800}.seating-workspace-title>span{padding:7px 11px;border-radius:999px;background:var(--theme-soft);color:var(--theme-text);font-size:10px;font-weight:850}
.seating-board-scroll{min-width:0;min-height:0;overflow:auto;border:1px solid color-mix(in srgb,var(--theme-border) 70%,#e2e8f0);border-radius:22px;background:rgba(255,255,255,.78);overscroll-behavior:contain}.seating-board{min-width:780px;display:grid;gap:9px;padding:17px}.seating-platform{width:min(360px,42%);margin:0 auto 7px;padding:10px;border-radius:12px;background:linear-gradient(135deg,var(--theme-soft-2),var(--theme-soft));color:var(--theme-text);font-size:14px;font-weight:950;letter-spacing:.4em;text-align:center;box-shadow:inset 0 0 0 1px var(--theme-border)}
.seating-row{display:grid;grid-template-columns:48px minmax(0,1fr);align-items:center;gap:8px}.seating-row>em{color:#94a3b8;font-size:9px;font-style:normal;font-weight:900;text-align:center;writing-mode:vertical-rl}.seating-row-groups{width:max-content;min-width:100%;display:flex;align-items:stretch;gap:9px}.seating-seat-group{min-width:0;flex:1;display:grid;grid-template-columns:repeat(var(--seating-segment),minmax(112px,1fr));gap:6px}.seating-aisle{width:30px;display:grid;place-items:center;flex:0 0 30px;border-radius:9px;background:repeating-linear-gradient(135deg,transparent 0 6px,var(--theme-soft) 6px 12px);color:#a3afbf;font-size:8px;font-style:normal;letter-spacing:.12em;writing-mode:vertical-rl}
.seating-seat{position:relative;min-width:112px;min-height:68px;display:grid;align-content:center;justify-items:center;padding:10px 7px 7px;border:1.5px solid var(--theme-border);border-radius:13px;background:#fff;color:#334155;text-align:center;box-shadow:0 4px 12px rgba(51,65,85,.045);cursor:pointer}.seating-seat:hover{transform:translateY(-1px);border-color:var(--theme);box-shadow:0 7px 16px var(--theme-shadow)}.seating-seat>span{position:absolute;top:5px;left:7px;color:#b0bac8;font-size:8px;font-weight:900}.seating-seat>b{max-width:100%;overflow:hidden;font-size:13px;text-overflow:ellipsis;white-space:nowrap}.seating-seat>small{max-width:100%;margin-top:3px;overflow:hidden;color:#94a3b8;font-size:8px;text-overflow:ellipsis;white-space:nowrap}.seating-seat.empty{border-style:dashed;background:#fafcff;color:#a3afbf}.seating-seat.gender-male,.seating-unassigned button.gender-male{border-color:#60a5fa;box-shadow:0 4px 12px rgba(59,130,246,.12)}.seating-seat.gender-female,.seating-unassigned button.gender-female{border-color:#f472b6;box-shadow:0 4px 12px rgba(236,72,153,.12)}.seating-seat.selected,.seating-unassigned button.selected{border-color:var(--theme);background:var(--theme-soft);box-shadow:0 0 0 3px color-mix(in srgb,var(--theme) 18%,transparent),0 8px 18px var(--theme-shadow)}
.seating-unassigned{min-width:0;max-width:100%;min-height:76px;margin-top:12px;padding:10px 12px;border:1px solid color-mix(in srgb,var(--theme-border) 60%,#e2e8f0);border-radius:16px;background:rgba(255,255,255,.9)}.seating-unassigned header{display:flex;align-items:center;justify-content:space-between;color:#64748b;font-size:11px}.seating-unassigned header span{color:var(--theme);font-weight:900}.seating-unassigned>div{width:100%;min-width:0;max-width:100%;display:flex;gap:7px;margin-top:7px;overflow-x:auto;padding-bottom:2px}.seating-unassigned button{min-width:112px;min-height:44px;padding:6px 9px;border:1px solid #dbe3ee;border-radius:11px;background:#fff;color:#334155;text-align:left}.seating-unassigned button b,.seating-unassigned button small{display:block;max-width:94px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.seating-unassigned button b{font-size:11px}.seating-unassigned button small{margin-top:2px;color:#94a3b8;font-size:8px}.seating-unassigned p{margin:3px 0;color:#94a3b8;font-size:10px}
@media(max-width:1100px),(pointer:coarse){.desktop-seating-tool-card{display:grid!important;grid-template-columns:58px minmax(0,1fr) auto auto}.desktop-seating-tool-card>em{display:inline-block;padding:5px 7px;font-size:9px}.modal-panel.seating-tool-modal{display:none!important}}
@media(max-height:760px) and (min-width:1101px){.seating-tool-head{min-height:76px;padding-block:9px}.seating-tool-head .tool-center-mark{width:52px;height:52px}.seating-controls{padding:12px}.seating-controls section{padding:11px;margin-bottom:9px}.seating-workspace{padding:12px 15px}.seating-seat{min-height:60px}}

/* Desktop-only temporary smart duty tool. It reads the active class roster but never persists its settings or result. */
.desktop-duty-tool-card{grid-template-columns:72px minmax(0,1fr) auto auto}.duty-icon{background:linear-gradient(145deg,var(--theme-2),var(--theme))}
.modal-panel.duty-tool-modal{width:calc(100vw - 34px)!important;height:calc(100dvh - 34px)!important;max-width:1780px!important;max-height:1040px!important;padding:0!important;overflow:hidden!important;border:1px solid color-mix(in srgb,var(--theme-border) 70%,white);border-radius:28px;background:#fff;box-shadow:0 28px 80px rgba(30,41,59,.28)}
.duty-tool-modal #modalContent{height:100%}.duty-tool-modal>.modal-close{z-index:8;top:18px;right:18px;width:42px;height:42px;background:rgba(255,255,255,.18);color:#fff;box-shadow:inset 0 0 0 1px rgba(255,255,255,.24)}
.duty-tool-shell{position:relative;height:100%;display:flex;flex-direction:column;background:linear-gradient(145deg,var(--theme-soft),#fff 44%);color:#334155}
.duty-tool-head{min-height:94px;display:flex;align-items:center;gap:16px;padding:15px 72px 15px 24px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff}.duty-tool-head .tool-center-mark{width:60px;height:60px;border-radius:19px;font-size:23px}.duty-tool-head h2{margin:0!important;color:#fff!important;font-size:27px}.duty-tool-head p{margin:5px 0 0;color:rgba(255,255,255,.82);font-size:12px;font-weight:750}.duty-tool-head-actions{margin-left:auto;display:flex;align-items:center;gap:8px}.duty-tool-head-actions button{min-height:42px;padding:0 16px;border:1px solid rgba(255,255,255,.3);border-radius:13px;background:rgba(255,255,255,.15);color:#fff;font-weight:900;white-space:nowrap}.duty-tool-head-actions button:hover{background:rgba(255,255,255,.24)}.duty-tool-head-actions .duty-tool-close{width:42px;min-width:42px;padding:0;border-radius:50%;font-size:24px;line-height:1}
.duty-tool-body{flex:1;min-height:0;display:grid;grid-template-columns:350px minmax(0,1fr)}
.duty-controls{min-height:0;overflow:auto;padding:18px;border-right:1px solid color-mix(in srgb,var(--theme-border) 65%,#e2e8f0);background:rgba(255,255,255,.9);overscroll-behavior:contain}
.duty-progress{position:relative;display:grid;grid-template-columns:repeat(3,1fr);margin:1px 2px 17px}.duty-progress:before{content:"";position:absolute;top:17px;left:16.66%;right:16.66%;height:2px;background:#e2e8f0}.duty-progress>div{position:relative;z-index:1;display:grid;justify-items:center;gap:6px;color:#94a3b8}.duty-progress span{width:35px;height:35px;display:grid;place-items:center;border-radius:50%;background:#e2e8f0;color:#64748b;font-size:13px;font-weight:950}.duty-progress b{font-size:10px;white-space:nowrap}.duty-progress .active span{background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 6px 14px var(--theme-shadow)}.duty-progress .active b{color:var(--theme-text)}.duty-progress .done span{background:#22c55e;color:#fff}.duty-progress .done b{color:#16a34a}
.duty-step-panel{padding:16px;border:1px solid color-mix(in srgb,var(--theme-border) 65%,#e2e8f0);border-radius:18px;background:#fff;box-shadow:0 7px 19px rgba(51,65,85,.05)}.duty-section-title{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.duty-section-title h3{margin:0!important;color:var(--theme-text)!important;font-size:17px!important}.duty-section-title p{margin:5px 0 0;color:#94a3b8;font-size:10px;font-weight:750}.duty-section-title>span{padding:5px 9px;border-radius:999px;background:var(--theme-soft);color:var(--theme-text);font-size:10px;font-weight:950;white-space:nowrap}
.duty-roster-toolbar{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:7px;margin-top:14px}.duty-roster-toolbar label{position:relative;min-width:0}.duty-roster-toolbar label>span{position:absolute;left:10px;top:50%;transform:translateY(-50%);color:#94a3b8;font-size:17px;font-weight:900;pointer-events:none}.duty-roster-toolbar input{width:100%;height:38px;padding:0 10px 0 31px;border:1px solid #dbe3ee;border-radius:11px;background:#fff;color:#334155;font:inherit;font-size:11px;font-weight:800;outline:0}.duty-roster-toolbar input:focus{border-color:var(--theme);box-shadow:0 0 0 3px var(--theme-soft)}.duty-roster-toolbar>button{min-height:38px;padding:0 10px;border:1px solid var(--theme-border);border-radius:11px;background:var(--theme-soft);color:var(--theme-text);font-size:9px;font-weight:900;white-space:nowrap}
.duty-roster-list{max-height:405px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;margin:9px 0 14px;overflow:auto;padding:10px;border:1px solid #e2e8f0;border-radius:14px;background:#f8fafc;overscroll-behavior:contain}.duty-roster-item{min-width:0;display:grid;grid-template-columns:minmax(0,1fr) 25px;align-items:center;gap:5px;padding:6px 6px 6px 9px;border:1px solid color-mix(in srgb,var(--theme) 25%,#dbe3ee);border-radius:10px;background:var(--theme-soft);color:var(--theme-text)}.duty-roster-item b{min-width:0;overflow:hidden;font-size:11px;font-weight:900;text-overflow:ellipsis;white-space:nowrap}.duty-roster-item button{width:25px;height:25px;padding:0;border:1px solid color-mix(in srgb,var(--theme) 24%,#fecdd3);border-radius:7px;background:rgba(255,255,255,.72);color:var(--theme-text);font-size:13px;font-weight:950}.duty-roster-item button:hover{border-color:#fb7185;background:#fff1f2;color:#e11d48}.duty-roster-empty{grid-column:1/-1;margin:24px 0;padding:0 8px;color:#94a3b8;font-size:10px;font-weight:800;text-align:center}
.duty-primary-button{border:0!important;background:linear-gradient(135deg,var(--theme-2),var(--theme))!important;color:#fff!important;box-shadow:0 8px 18px var(--theme-shadow)}.duty-step-panel>.duty-primary-button{width:100%;min-height:43px;border-radius:12px;font-weight:950}
.duty-add-row{display:grid;grid-template-columns:minmax(0,1fr) 88px;gap:7px;margin:14px 0 10px}.duty-add-row input,.duty-title-field input{width:100%;height:41px;padding:0 11px;border:1px solid #dbe3ee;border-radius:11px;background:#fff;color:#334155;font:inherit;font-size:11px;outline:0}.duty-add-row input:focus,.duty-title-field input:focus{border-color:var(--theme);box-shadow:0 0 0 3px var(--theme-soft)}.duty-add-row button{border:0;border-radius:11px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-size:11px;font-weight:950}
.duty-item-list{display:grid;gap:7px}.duty-item-row{min-width:0;display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"name actions" "count count";align-items:center;gap:8px;padding:9px 10px;border:1px solid #e2e8f0;border-radius:13px;background:#fff}.duty-item-row>b{grid-area:name;min-width:0;overflow:hidden;color:#334155;font-size:11px;text-overflow:ellipsis;white-space:nowrap}.duty-item-actions{grid-area:actions;display:flex;align-items:center;gap:4px}.duty-item-row label{grid-area:count;min-width:0;display:grid;grid-template-columns:minmax(0,1fr) 29px 39px 29px;align-items:center;gap:4px;padding-top:7px;border-top:1px solid #f1f5f9}.duty-item-row label>span{color:#94a3b8;font-size:9px;font-weight:850;white-space:nowrap}.duty-item-row label button,.duty-item-actions button{width:29px;height:29px;padding:0;border:1px solid #dbe3ee;border-radius:8px;background:#fff;color:var(--theme-text);font-size:14px;font-weight:950}.duty-item-row label input{width:39px;height:29px;padding:0 2px;border:1px solid #dbe3ee;border-radius:8px;background:#fff;color:#334155;font:inherit;font-size:11px;font-weight:900;text-align:center}.duty-item-row label input::-webkit-inner-spin-button{display:none}.duty-item-actions .duty-delete-item{border-color:#fecdd3;background:#fff1f2;color:#e11d48}.duty-item-actions .duty-delete-item:hover{border-color:#fb7185;background:#ffe4e6}.duty-order-item:disabled{cursor:not-allowed;opacity:.34}
.duty-step-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:13px}.duty-step-actions button{min-height:42px;border:1px solid #dbe3ee;border-radius:11px;background:#fff;color:#64748b;font-size:11px;font-weight:950}
.duty-title-field{display:grid;gap:6px;margin-top:15px}.duty-title-field>span,.duty-day-controls>b{color:#64748b;font-size:10px;font-weight:900}.duty-day-controls{display:grid;gap:7px;margin-top:13px}.duty-day-controls>div,.duty-week-card>div{display:grid;grid-template-columns:repeat(4,1fr);gap:6px}.duty-day-controls button,.duty-week-card button{min-width:0;height:35px;border:1px solid #dbe3ee;border-radius:10px;background:#fff;color:#64748b;font-size:10px;font-weight:900}.duty-day-controls button.selected,.duty-week-card button.selected{border-color:transparent;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 5px 12px var(--theme-shadow)}.duty-week-card button:disabled{cursor:default;opacity:.72}.duty-week-card button.selected:disabled{opacity:1}.duty-generation-summary{display:grid;grid-template-columns:1fr 1fr;gap:7px;margin-top:13px}.duty-generation-summary span{padding:9px;border-radius:10px;background:#f8fafc;color:#94a3b8;font-size:9px;font-weight:850}.duty-generation-summary b{color:var(--theme-text);font-size:12px}
.duty-generated-panel{display:grid;justify-items:center;text-align:center}.duty-success-mark{width:54px;height:54px;display:grid;place-items:center;border-radius:50%;background:#dcfce7;color:#16a34a;font-size:27px;font-weight:950}.duty-generated-panel h3{margin:13px 0 0!important;color:#334155!important;font-size:19px!important}.duty-generated-panel>p{margin:6px 0 0;color:#94a3b8;font-size:10px;font-weight:750}.duty-generated-panel ul{width:100%;display:grid;gap:7px;margin:15px 0;padding:0;list-style:none;text-align:left}.duty-generated-panel li{padding:8px 10px;border-radius:10px;background:#f8fafc;color:#64748b;font-size:10px;font-weight:850}.duty-generated-panel li:before{content:"✓";margin-right:7px;color:#22c55e}.duty-generated-panel>button{width:100%;min-height:40px;border:1px solid #dbe3ee;border-radius:11px;background:#fff;color:#64748b;font-size:11px;font-weight:900}.duty-export-actions{width:100%;display:grid;grid-template-columns:1fr 1fr;gap:7px;margin-top:8px}.duty-export-actions button{min-height:42px;border:0;border-radius:11px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-size:11px;font-weight:950;box-shadow:0 7px 16px var(--theme-shadow)}.duty-export-actions button:disabled{opacity:.55;cursor:wait}
.duty-privacy{margin-top:12px;padding:9px 10px;border-radius:11px;background:var(--theme-soft);color:var(--theme-text);font-size:9px;font-weight:800;line-height:1.5}
.duty-workspace{min-width:0;min-height:0;display:grid;grid-template-rows:auto minmax(310px,1fr) minmax(180px,.55fr);gap:13px;overflow:auto;padding:17px 19px;overscroll-behavior:contain}.duty-week-card,.duty-preview-card,.duty-stats-card{min-width:0;border:1px solid color-mix(in srgb,var(--theme-border) 67%,#e2e8f0);border-radius:19px;background:rgba(255,255,255,.93);box-shadow:0 7px 20px rgba(51,65,85,.045)}.duty-week-card{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:17px;padding:12px 16px}.duty-week-card h3,.duty-preview-card h3,.duty-stats-card h3{margin:0!important;color:#334155!important;font-size:14px!important}.duty-week-card>div{max-width:620px;grid-template-columns:repeat(7,minmax(58px,1fr))}
.duty-preview-card,.duty-stats-card{min-height:0;display:flex;flex-direction:column;overflow:hidden}.duty-preview-card>header,.duty-stats-card>header{min-height:48px;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 15px;border-bottom:1px solid #e8edf4}.duty-preview-card>header span,.duty-stats-card>header span{color:#94a3b8;font-size:9px;font-weight:800}.duty-schedule-scroll{flex:1;min-width:0;min-height:0;overflow:auto;overscroll-behavior:contain}.duty-empty-state{min-width:100%;min-height:100%;display:grid;place-content:center;justify-items:center;padding:30px;color:#94a3b8;text-align:center}.duty-empty-state>span{width:62px;height:62px;display:grid;place-items:center;border-radius:19px;background:var(--theme-soft);color:var(--theme);font-size:28px}.duty-empty-state>b{margin-top:13px;color:#64748b;font-size:12px}.duty-empty-state>p{margin:5px 0 0;font-size:9px;font-weight:750}
.duty-schedule-table{width:max(820px,100%);border-collapse:collapse;table-layout:fixed}.duty-schedule-table th,.duty-schedule-table td{border:1px solid #e2e8f0;padding:9px;text-align:center}.duty-schedule-table thead th{position:sticky;top:0;z-index:2;height:45px;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-size:11px;font-weight:950}.duty-schedule-table thead th:first-child{width:132px}.duty-schedule-table tbody th{position:sticky;left:0;z-index:1;background:var(--theme-soft);color:var(--theme-text);font-size:10px;font-weight:950}.duty-schedule-table td{min-height:54px;background:#fff}.duty-schedule-table td>div{display:flex;flex-wrap:wrap;justify-content:center;gap:5px}.duty-schedule-table td button{max-width:100%;min-height:28px;padding:5px 8px;border:1px solid color-mix(in srgb,var(--theme) 28%,#dbe3ee);border-radius:999px;background:var(--theme-soft);color:var(--theme-text);font-size:9px;font-weight:900;overflow-wrap:anywhere}.duty-schedule-table td button:hover{border-color:var(--theme);box-shadow:0 4px 10px var(--theme-shadow)}
.duty-stats-card{min-height:180px}.duty-stats-grid{flex:1;min-height:0;display:grid;grid-template-columns:repeat(6,minmax(105px,1fr));gap:8px;overflow:auto;padding:11px;overscroll-behavior:contain}.duty-stats-grid article{min-width:0;display:grid;grid-template-columns:34px minmax(0,1fr) auto;align-items:center;gap:8px;padding:9px;border-radius:13px;background:linear-gradient(135deg,var(--theme-soft),#fff);border:1px solid color-mix(in srgb,var(--theme) 18%,#e2e8f0)}.duty-stats-grid article>span{width:34px;height:34px;display:grid;place-items:center;border-radius:50%;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-size:12px;font-weight:950}.duty-stats-grid article>b{min-width:0;overflow:hidden;color:#334155;font-size:10px;text-overflow:ellipsis;white-space:nowrap}.duty-stats-grid strong{color:var(--theme);font-size:17px}.duty-stats-grid small{margin-left:2px;color:#94a3b8;font-size:8px}
.duty-replace-layer{position:absolute;inset:0;z-index:25;display:grid;place-items:center;padding:24px;background:rgba(30,41,59,.58);backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px)}.duty-replace-card{position:relative;width:min(620px,calc(100vw - 58px));max-height:min(720px,calc(100dvh - 70px));display:flex;flex-direction:column;padding:25px;border:1px solid var(--theme-border);border-radius:24px;background:#fff;box-shadow:0 28px 75px rgba(30,41,59,.3)}.duty-replace-card>button:first-child{position:absolute;top:14px;right:14px;width:38px;height:38px;border:0;border-radius:50%;background:#f1f5f9;color:#64748b;font-size:22px}.duty-replace-card h3{margin:0;padding-right:42px;color:var(--theme-text);font-size:22px}.duty-replace-card>p{margin:7px 0 15px;color:#64748b;font-size:11px;font-weight:750}.duty-replacement-list{min-height:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;overflow:auto;padding:2px;overscroll-behavior:contain}.duty-replacement-list>button{min-width:0;display:grid;grid-template-columns:36px minmax(0,1fr);align-items:center;gap:2px 8px;padding:9px;border:1px solid #dbe3ee;border-radius:13px;background:#fff;color:#334155;text-align:left}.duty-replacement-list>button:hover{border-color:var(--theme);background:var(--theme-soft)}.duty-replacement-list span{width:36px;height:36px;grid-row:1/3;display:grid;place-items:center;border-radius:50%;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;font-size:12px;font-weight:950}.duty-replacement-list b{min-width:0;overflow:hidden;font-size:11px;text-overflow:ellipsis;white-space:nowrap}.duty-replacement-list small{color:#94a3b8;font-size:8px;font-weight:750}.duty-replacement-list>p{grid-column:1/-1;margin:30px 0;color:#94a3b8;text-align:center}.duty-replace-cancel{min-height:41px;margin-top:13px;border:1px solid #dbe3ee!important;border-radius:11px!important;background:#fff!important;color:#64748b!important;font-size:11px!important;font-weight:900}
@media(max-width:1100px),(pointer:coarse){.desktop-duty-tool-card{display:grid!important;grid-template-columns:58px minmax(0,1fr) auto auto}.desktop-duty-tool-card>em{display:inline-block;padding:5px 7px;font-size:9px}.modal-panel.duty-tool-modal{display:none!important}}
@media(max-height:760px) and (min-width:1101px){.duty-tool-head{min-height:76px;padding-block:9px}.duty-tool-head .tool-center-mark{width:52px;height:52px}.duty-controls{padding:12px}.duty-step-panel{padding:12px}.duty-roster-list{max-height:320px}.duty-workspace{grid-template-rows:auto minmax(270px,1fr) minmax(150px,.45fr);padding:12px 15px}.duty-stats-grid{grid-template-columns:repeat(5,minmax(105px,1fr))}}

.modal-panel.random-picker-modal:fullscreen,.modal-panel.countdown-timer-modal:fullscreen,.modal-panel.task-checkin-modal:fullscreen,.modal-panel.sound-reactive-modal:fullscreen,.modal-panel.seating-tool-modal:fullscreen{width:100vw!important;height:100vh!important;max-width:none!important;max-height:none!important;margin:0!important;border:0!important;border-radius:0!important;background:#fff}
.modal-panel.random-picker-modal:-webkit-full-screen,.modal-panel.countdown-timer-modal:-webkit-full-screen,.modal-panel.task-checkin-modal:-webkit-full-screen,.modal-panel.sound-reactive-modal:-webkit-full-screen,.modal-panel.seating-tool-modal:-webkit-full-screen{width:100vw!important;height:100vh!important;max-width:none!important;max-height:none!important;margin:0!important;border:0!important;border-radius:0!important;background:#fff}

/* Online devices: compact account session panel shared by desktop and touch layouts. */
.modal-panel.cloud-device-modal{
  width:min(590px,calc(100vw - 28px));
  max-height:min(720px,calc(100dvh - 32px));
  padding:0!important;
  overflow:hidden;
  border:1px solid color-mix(in srgb,var(--theme-border) 68%,#e2e8f0);
  border-radius:25px;
  background:#fff;
  box-shadow:0 26px 72px rgba(30,41,59,.25),0 8px 24px var(--theme-shadow);
}
.cloud-device-modal>.modal-close{
  z-index:5;
  top:19px;
  right:19px;
  width:42px;
  height:42px;
  display:grid;
  place-items:center;
  border:0;
  background:#f1f5f9;
  color:#64748b;
  font-size:26px;
}
.cloud-device-modal>.modal-close:hover{background:var(--theme-soft);color:var(--theme-text)}
.cloud-device-modal #modalContent{min-width:0}
.cloud-device-panel{max-height:min(720px,calc(100dvh - 32px));display:flex;flex-direction:column;background:linear-gradient(180deg,var(--theme-soft),#fff 115px)}
.cloud-device-panel>header{flex:0 0 auto;padding:25px 76px 20px 27px;border-bottom:1px solid #e8edf4;background:rgba(255,255,255,.8)}
.cloud-device-panel>header h2{margin:0!important;color:#1e293b!important;font-size:24px!important;font-weight:950;letter-spacing:-.02em}
.cloud-device-panel>header p{margin:5px 0 0;color:#94a3b8;font-size:12px;font-weight:750}
.cloud-device-list{flex:1;min-height:0;display:grid;align-content:start;gap:11px;overflow:auto;padding:18px 22px;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
.cloud-device-row{min-width:0;min-height:88px;display:grid;grid-template-columns:48px minmax(0,1fr) auto;align-items:center;gap:14px;padding:13px 14px;border:1px solid #dce5f0;border-radius:17px;background:#fff;box-shadow:0 5px 15px rgba(51,65,85,.035)}
.cloud-device-row.is-current{border-color:color-mix(in srgb,var(--theme) 45%,#dbeafe);background:linear-gradient(135deg,#fff,var(--theme-soft))}
.cloud-device-icon{width:46px;height:46px;display:grid;place-items:center;border-radius:14px;background:#f1f5f9;color:#64748b}
.cloud-device-row.is-current .cloud-device-icon{background:var(--theme-soft-2);color:var(--theme)}
.cloud-device-icon svg{width:25px;height:25px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.cloud-device-info{min-width:0;display:grid;gap:5px}
.cloud-device-info b{min-width:0;overflow:hidden;color:#334155;font-size:16px;font-weight:950;text-overflow:ellipsis;white-space:nowrap}
.cloud-device-info small{min-width:0;overflow:hidden;color:#94a3b8;font-size:11px;font-weight:750;text-overflow:ellipsis;white-space:nowrap}
.cloud-device-state{display:flex;align-items:center;justify-content:flex-end;gap:7px}
.device-status{display:inline-flex;align-items:center;justify-content:center;min-height:26px;padding:4px 9px;border-radius:999px;font-size:10px;font-weight:950;white-space:nowrap}
.device-status.current{background:#dbeafe;color:#2563eb}.device-status.active{background:#dcfce7;color:#15803d}.device-status.offline{background:#fef3c7;color:#b45309}.device-status.removed{background:#f1f5f9;color:#94a3b8}
.cloud-device-state button{min-width:50px;height:34px;border:1px solid #fecdd3;border-radius:10px;background:#fff1f2;color:#e11d48;font-size:11px;font-weight:900}
.cloud-device-state button:hover{border-color:#fb7185;background:#ffe4e6}
.cloud-device-empty{min-height:190px;display:grid;place-content:center;justify-items:center;gap:9px;color:#94a3b8}.cloud-device-empty span{width:58px;height:58px;display:grid;place-items:center;border-radius:18px;background:var(--theme-soft);color:var(--theme);font-size:26px}.cloud-device-empty b{font-size:13px}
.cloud-device-actions{flex:0 0 auto;display:flex;justify-content:flex-end;gap:10px;padding:14px 22px calc(14px + env(safe-area-inset-bottom,0px));border-top:1px solid #e8edf4;background:#fff}
.cloud-device-actions button{min-width:118px;min-height:43px;border:1px solid #dbe3ee;border-radius:13px;background:#fff;color:#64748b;font-size:12px;font-weight:900}
.cloud-device-actions button:not(:disabled):hover{border-color:var(--theme-border);background:var(--theme-soft);color:var(--theme-text)}
.cloud-device-actions button:disabled{opacity:.45;cursor:not-allowed}
.cloud-device-actions .primary-button{border:0;background:linear-gradient(135deg,var(--theme-2),var(--theme));color:#fff;box-shadow:0 8px 18px var(--theme-shadow)}

/* Task check-in and sound-reactive classroom tool refinements. */
.task-checkin-body{gap:9px;padding:10px 14px 9px}
.task-checkin-summary{grid-template-columns:110px 110px minmax(180px,1fr);gap:8px}
.task-checkin-summary>div{padding:8px 11px;border-radius:14px}
.task-checkin-summary strong{font-size:22px}
.task-checkin-summary .task-checkin-progress{gap:5px}
.task-checkin-stage{padding:9px;overflow:auto}
.task-checkin-grid{
  --task-checkin-columns:8;
  --task-checkin-card-size:100px;
  --task-checkin-gap:8px;
  --task-checkin-font-size:17px;
  width:max-content;
  max-width:none;
  min-height:100%;
  display:grid;
  grid-template-columns:repeat(var(--task-checkin-columns),var(--task-checkin-card-size));
  grid-auto-rows:var(--task-checkin-card-size);
  gap:var(--task-checkin-gap);
  align-content:center;
  justify-content:center;
  margin:0 auto;
}
.task-checkin-stage.needs-scroll .task-checkin-grid{min-height:auto;align-content:start}
.task-checkin-name{width:var(--task-checkin-card-size);height:var(--task-checkin-card-size);aspect-ratio:auto;padding:clamp(5px,1vw,12px)}
.task-checkin-name>span{font-size:var(--task-checkin-font-size)}
.sound-reactive-body{
  grid-template-columns:1fr;
  grid-template-rows:auto minmax(0,1fr);
  gap:9px;
  padding:9px 14px;
  overflow:hidden;
}
.sound-reactive-toolbar{
  min-width:0;
  display:grid;
  grid-template-columns:minmax(240px,.9fr) minmax(190px,.7fr) minmax(170px,.65fr) minmax(220px,1fr);
  gap:8px 14px;
  align-items:end;
  padding:9px 14px;
  border:1px solid var(--theme-border);
  border-radius:18px;
  background:rgba(255,255,255,.94);
  box-shadow:0 6px 18px rgba(51,65,85,.05);
}
.sound-reactive-toolbar .sound-mode-tabs{min-width:0}
.sound-reactive-stage{min-height:0;width:100%}
.sound-reactive-banner{top:clamp(42px,12%,92px);font-size:clamp(16px,2vw,26px);padding:12px 24px;transition:opacity .18s ease,transform .18s ease}
.sound-reactive-banner.is-hidden{opacity:0;transform:translate(-50%,-8px) scale(.96);pointer-events:none}
.sound-reactive-banner.is-status{top:16px;padding:7px 12px;font-size:11px}
.sound-reactive-banner.alert{transform:translateX(-50%) scale(1.04)}
.sound-toolbar-meta{
  grid-column:1/-1;
  min-width:0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  color:#94a3b8;
  font-size:9px;
  font-weight:750;
}
.sound-privacy-inline{white-space:nowrap}
.sound-reactive-toolbar .sound-error-message{grid-column:1/-1}
@media(max-width:1100px){
  .sound-reactive-toolbar{grid-template-columns:repeat(2,minmax(0,1fr))}
  .sound-reactive-toolbar .sound-mode-tabs,.sound-toolbar-meta,.sound-reactive-toolbar .sound-error-message{grid-column:1/-1}
}
@media(max-width:680px){
  .task-checkin-body{gap:6px;padding:7px 8px 6px}
  .task-checkin-summary{grid-template-columns:74px 74px minmax(0,1fr);gap:5px}
  .task-checkin-summary>div{padding:6px 5px}
  .task-checkin-summary .task-checkin-progress{grid-column:auto;padding:6px 7px}
  .task-checkin-summary span,.task-checkin-progress b{font-size:9px}
  .task-checkin-summary strong{font-size:19px}
  .task-checkin-progress em{font-size:10px}
  .task-checkin-progress>div{height:6px}
  .task-checkin-stage{padding:6px}
  .task-checkin-name{padding:5px}
  .sound-reactive-body{grid-template-columns:1fr;grid-template-rows:auto minmax(180px,1fr);gap:6px;padding:7px;overflow:hidden}
  .sound-reactive-toolbar{grid-template-columns:1fr 1fr;gap:6px;padding:7px;border-radius:15px}
  .sound-reactive-toolbar .sound-mode-tabs{grid-column:1/-1}
  .sound-reactive-toolbar .sound-prompt-control{grid-column:1/-1}
  .sound-toolbar-meta{display:none}
  .sound-reactive-toolbar .sound-error-message{grid-column:1/-1}
  .sound-reactive-stage{min-height:0;border-radius:19px}
  .sound-reactive-banner{top:12%;max-width:calc(100% - 22px);font-size:clamp(15px,5vw,21px);padding:9px 14px}
  .sound-reactive-banner.is-status{top:9px;font-size:9px;padding:6px 9px}
}
@media(max-width:360px){
  .task-checkin-summary{grid-template-columns:62px 62px minmax(0,1fr)}
  .sound-threshold-control>span,.sound-live-meter>span,.sound-prompt-control>span{font-size:9px}
  .sound-prompt-control input{height:36px;font-size:10px}
}
