/* ═══════════ ВАРИАНТЫ «СТЕКЛА» ═══════════
   Общая основа — в 09-theme-glass.css (body.theme-glass). Здесь только отличия трёх тем:
   body.theme-glass-smoke (Дымчатое), body.theme-glass-aurora (Аврора), body.theme-glass-ice (Ледяное). */
body.theme-glass .goals-drawer{ -webkit-backdrop-filter:var(--glass-blur); backdrop-filter:var(--glass-blur); }

/* Заголовок секции — стекло, подсвеченное её цветом: цвет плотный слева и тает вправо, слева цветная грань */
body.theme-glass .section-header{
  background:
    linear-gradient(115deg, rgba(255,255,255,.14) 0%, rgba(255,255,255,0) 38%),
    linear-gradient(100deg, color-mix(in srgb, var(--task-accent) 44%, transparent) 0%, color-mix(in srgb, var(--task-accent) 20%, transparent) 55%, color-mix(in srgb, var(--task-accent) 8%, transparent) 100%) !important;
  box-shadow: inset 3px 0 0 var(--task-accent), var(--glass-shine);
  color:#fff !important;
}

/* ---------- Живой фон: частицы (.gp) ---------- */
#glass-scene .gp{ position:absolute; display:none; pointer-events:none; will-change:transform, opacity; }
@keyframes glassSmokeRise{
  0%{ transform:translate(0,0) scale(.55); opacity:0; }
  14%{ opacity:1; }
  65%{ opacity:.55; }
  100%{ transform:translate(var(--dx,6vw),-135vh) scale(2.3); opacity:0; }
}
@keyframes glassTwinkle{ 0%,100%{ opacity:.12; transform:scale(.6); } 50%{ opacity:1; transform:scale(1.25); } }
@keyframes glassShoot{ 0%,91%{ opacity:0; transform:translate(0,0) rotate(-24deg); } 92%{ opacity:1; } 100%{ opacity:0; transform:translate(-46vw,21vw) rotate(-24deg); } }
@keyframes glassMist{ from{ transform:translateX(-14vw); } to{ transform:translateX(14vw); } }
@keyframes glassAurora1{ 0%{ transform:rotate(-10deg) translateX(-5vmax) scaleY(1); opacity:.20; } 50%{ opacity:.34; } 100%{ transform:rotate(-7deg) translateX(5vmax) scaleY(1.4); opacity:.24; } }
@keyframes glassAurora2{ 0%{ transform:rotate(-16deg) translateX(4vmax) scaleY(1.3); opacity:.26; } 50%{ opacity:.38; } 100%{ transform:rotate(-12deg) translateX(-6vmax) scaleY(1); opacity:.22; } }
@keyframes glassAurora3{ 0%{ transform:rotate(-7deg) translateX(-3vmax) scaleY(1); opacity:.08; } 100%{ transform:rotate(-4deg) translateX(6vmax) scaleY(1.5); opacity:.17; } }

/* ДЫМЧАТОЕ — тёмное графитовое стекло, почти без цвета, тонкие линии */
body.theme-glass-smoke #glass-scene{ background: radial-gradient(90% 70% at 20% 0%, #1a1f30 0%, transparent 60%), radial-gradient(80% 70% at 90% 90%, #141a28 0%, transparent 60%), #050608; }
body.theme-glass-smoke #glass-scene .gb1{ background:#44506e; opacity:.22; } body.theme-glass-smoke #glass-scene .gb2{ background:#30384f; opacity:.20; } body.theme-glass-smoke #glass-scene .gb3{ background:#3a4660; opacity:.16; } body.theme-glass-smoke #glass-scene .gb4, body.theme-glass-smoke #glass-scene .gb5{ display:none; }
body.theme-glass-smoke #glass-scene::before{ opacity:.6; }
body.theme-glass-smoke{
  --glass-sheen: linear-gradient(115deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0) 30%);
  --glass-bg: var(--glass-sheen), linear-gradient(180deg, rgba(255,255,255,0.045), rgba(255,255,255,0.01)), rgba(8,9,14,0.58);
  --glass-line: rgba(255,255,255,0.12); --glass-line-soft: rgba(255,255,255,0.06);
  --glass-blur: blur(24px) saturate(110%);
  --glass-shine: inset 0 1px 0 rgba(255,255,255,0.22);
  --glass-shadow: 0 14px 40px rgba(0,0,0,0.55);
}
body.theme-glass-smoke .section-header{ border-top-color:rgba(255,255,255,.2); }
body.theme-glass-smoke .progress-bar{ background:linear-gradient(90deg,#cfd6e6,#8f9ab5); box-shadow:none; }

/* АВРОРА — ночное небо с лентами сияния, стекло с холодной бирюзово-синей кромкой */
body.theme-glass-aurora #glass-scene{ background: linear-gradient(180deg, #030814 0%, #04101c 60%, #020509 100%); }
body.theme-glass-aurora #glass-scene .gb{ border-radius:50%; filter:blur(46px); animation-duration:38s; }
body.theme-glass-aurora #glass-scene .gb1{ width:110vmax; height:16vmax; left:-20vmax; top:8vmax; background:linear-gradient(90deg,transparent,#22a8b0 30%,#3aa6d8 60%,transparent); opacity:.30; transform:rotate(-10deg); }
body.theme-glass-aurora #glass-scene .gb2{ width:100vmax; height:13vmax; right:-30vmax; top:26vmax; left:auto; background:linear-gradient(90deg,transparent,#7a5cf0 35%,#4a8cf0 70%,transparent); opacity:.36; transform:rotate(-16deg); }
body.theme-glass-aurora #glass-scene .gb3{ width:90vmax; height:12vmax; left:-10vmax; bottom:6vmax; background:linear-gradient(90deg,transparent,#2a9aa6 40%,#5ab4c8 65%,transparent); opacity:.14; transform:rotate(-7deg); }
body.theme-glass-aurora #glass-scene .gb4, body.theme-glass-aurora #glass-scene .gb5{ display:none; }
body.theme-glass-aurora #glass-scene .gb1, body.theme-glass-aurora #glass-scene .gb2, body.theme-glass-aurora #glass-scene .gb3{ animation:none; }
body.theme-glass-aurora #glass-scene::before{ background:
  radial-gradient(circle at 12% 22%, rgba(255,255,255,.8) 0 1px, transparent 1.6px), radial-gradient(circle at 31% 64%, rgba(255,255,255,.6) 0 1px, transparent 1.6px),
  radial-gradient(circle at 47% 12%, rgba(255,255,255,.7) 0 1px, transparent 1.6px), radial-gradient(circle at 63% 48%, rgba(255,255,255,.5) 0 1px, transparent 1.6px),
  radial-gradient(circle at 78% 30%, rgba(255,255,255,.8) 0 1.2px, transparent 1.8px), radial-gradient(circle at 88% 74%, rgba(255,255,255,.6) 0 1px, transparent 1.6px),
  radial-gradient(circle at 22% 86%, rgba(255,255,255,.5) 0 1px, transparent 1.6px), radial-gradient(circle at 56% 82%, rgba(255,255,255,.7) 0 1px, transparent 1.6px),
  radial-gradient(circle at 70% 8%, rgba(255,255,255,.5) 0 1px, transparent 1.6px), radial-gradient(circle at 5% 55%, rgba(255,255,255,.6) 0 1px, transparent 1.6px); }
body.theme-glass-aurora{
  --glass-sheen: linear-gradient(115deg, rgba(185,230,245,0.08) 0%, rgba(255,255,255,0) 30%, rgba(255,255,255,0) 74%, rgba(150,170,255,0.06) 100%);
  --glass-bg: var(--glass-sheen), linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.015)), rgba(3,10,20,0.40);
  --glass-line: rgba(160,220,240,0.22); --glass-line-soft: rgba(160,220,240,0.08);
  --glass-blur: blur(20px) saturate(150%);
  --glass-shine: inset 0 1px 0 rgba(200,238,248,0.50), inset 1px 0 0 rgba(200,238,248,0.13), inset 0 -1px 0 rgba(150,170,255,0.16), inset 0 18px 24px -18px rgba(140,215,240,0.13);
  --glass-shadow: 0 14px 40px rgba(0,0,0,0.5);
}
body.theme-glass-aurora .section-header{ border-top-color:rgba(200,238,248,.40); }
body.theme-glass-aurora .progress-bar{ background:linear-gradient(90deg,#5cc4d8,#7a8cf0); box-shadow:0 0 10px rgba(92,196,216,.40); }

/* ЛЕДЯНОЕ — стекло в палитре Арктики: тёмно-синий лёд, голубые кромки */
body.theme-glass-ice #glass-scene{ background: radial-gradient(120% 80% at 50% 0%, #0a1f38 0%, transparent 62%), radial-gradient(100% 80% at 0% 100%, #05252c 0%, transparent 60%), #040b16; }
body.theme-glass-ice #glass-scene .gb1{ background:#1e6fb0; opacity:.21; } body.theme-glass-ice #glass-scene .gb2{ background:#2a4f9a; opacity:.16; } body.theme-glass-ice #glass-scene .gb3{ background:#1fa89a; opacity:.10; } body.theme-glass-ice #glass-scene .gb4{ background:#60c0f0; opacity:.07; } body.theme-glass-ice #glass-scene .gb5{ display:none; }
body.theme-glass-ice #glass-scene::before{ background:
  linear-gradient(118deg, transparent 0 22%, rgba(160,220,255,.03) 22% 27%, transparent 27% 41%, rgba(160,220,255,.04) 41% 52%, transparent 52% 66%, rgba(160,220,255,.025) 66% 69%, transparent 69%),
  linear-gradient(62deg, transparent 0 55%, rgba(160,220,255,.025) 55% 63%, transparent 63%),
  radial-gradient(circle at 80% 20%, rgba(200,235,255,.05) 0 9vmax, transparent 9.15vmax),
  radial-gradient(circle at 18% 70%, rgba(200,235,255,.035) 0 12vmax, transparent 12.2vmax); }
body.theme-glass-ice{
  --glass-sheen: linear-gradient(115deg, rgba(200,235,255,0.08) 0%, rgba(255,255,255,0) 30%, rgba(255,255,255,0) 74%, rgba(200,235,255,0.05) 100%);
  --glass-bg: var(--glass-sheen), linear-gradient(180deg, rgba(160,215,255,0.06), rgba(160,215,255,0.015)), rgba(4,11,22,0.52);
  --glass-line: rgba(140,205,255,0.22); --glass-line-soft: rgba(140,205,255,0.08);
  --glass-blur: blur(20px) saturate(140%);
  --glass-shine: inset 0 1px 0 rgba(210,240,255,0.44), inset 1px 0 0 rgba(210,240,255,0.12), inset 0 -1px 0 rgba(140,205,255,0.10), inset 0 18px 24px -18px rgba(120,200,255,0.14);
  --glass-shadow: 0 14px 40px rgba(0,6,18,0.5);
  --text:#e0f0ff;
}
body.theme-glass-ice .section-header{ border-top-color:rgba(210,240,255,.38); }
body.theme-glass-ice .progress-bar{ background:linear-gradient(90deg,#4f9fc8,#38b3a0); box-shadow:0 0 8px rgba(96,192,240,.3); }
body.theme-glass-ice .progress-pct{ -webkit-text-fill-color:#bfe6ff; color:#bfe6ff; }

/* Дымчатое: клубы дыма медленно поднимаются снизу */
body.theme-glass-smoke #glass-scene .gp{ display:block; bottom:-34vmax; width:38vmax; height:38vmax; border-radius:50%;
  background:radial-gradient(closest-side, rgba(196,206,230,.17), rgba(196,206,230,.06) 58%, transparent); filter:blur(22px);
  animation:glassSmokeRise linear infinite; }
body.theme-glass-smoke #glass-scene .gp1{ left:-6%;  --dx:9vw;  animation-duration:34s; animation-delay:-4s; }
body.theme-glass-smoke #glass-scene .gp2{ left:16%;  --dx:-5vw; animation-duration:41s; animation-delay:-22s; }
body.theme-glass-smoke #glass-scene .gp3{ left:38%;  --dx:7vw;  animation-duration:30s; animation-delay:-13s; }
body.theme-glass-smoke #glass-scene .gp4{ left:56%;  --dx:-8vw; animation-duration:38s; animation-delay:-30s; }
body.theme-glass-smoke #glass-scene .gp5{ left:74%;  --dx:5vw;  animation-duration:33s; animation-delay:-8s; }
body.theme-glass-smoke #glass-scene .gp6{ left:88%;  --dx:-10vw; animation-duration:44s; animation-delay:-19s; }

/* Аврора: ленты сияния колышутся, звёзды мерцают, изредка падает звезда */
body.theme-glass-aurora #glass-scene .gb1{ animation:glassAurora1 17s ease-in-out infinite alternate; }
body.theme-glass-aurora #glass-scene .gb2{ animation:glassAurora2 23s ease-in-out infinite alternate; }
body.theme-glass-aurora #glass-scene .gb3{ animation:glassAurora3 20s ease-in-out infinite alternate; }
body.theme-glass-aurora #glass-scene .gp{ display:block; width:3px; height:3px; border-radius:50%; background:#fff;
  box-shadow:0 0 8px 2px rgba(200,235,255,.7); animation:glassTwinkle ease-in-out infinite; }
body.theme-glass-aurora #glass-scene .gp1{ left:9%;  top:14%; animation-duration:4.2s; }
body.theme-glass-aurora #glass-scene .gp2{ left:27%; top:38%; animation-duration:5.6s; animation-delay:-2s; }
body.theme-glass-aurora #glass-scene .gp3{ left:52%; top:9%;  animation-duration:3.6s; animation-delay:-1s; }
body.theme-glass-aurora #glass-scene .gp4{ left:69%; top:57%; animation-duration:6.2s; animation-delay:-3s; }
body.theme-glass-aurora #glass-scene .gp5{ left:91%; top:24%; animation-duration:4.8s; animation-delay:-2.5s; }
body.theme-glass-aurora #glass-scene .gp6{ left:84%; top:6%; width:110px; height:1.5px; border-radius:2px; box-shadow:none;
  background:linear-gradient(90deg, rgba(255,255,255,.95), rgba(190,230,255,.35) 40%, transparent); animation:glassShoot 19s linear infinite; }

/* Ледяное: мерцают льдинки, понизу медленно плывёт морозная дымка */
body.theme-glass-ice #glass-scene .gp{ display:block; width:3px; height:3px; border-radius:50%; background:#eaf7ff;
  box-shadow:0 0 9px 2px rgba(130,205,255,.75); animation:glassTwinkle ease-in-out infinite; }
body.theme-glass-ice #glass-scene .gp1{ left:12%; top:22%; animation-duration:5.2s; }
body.theme-glass-ice #glass-scene .gp2{ left:34%; top:61%; animation-duration:6.8s; animation-delay:-2s; }
body.theme-glass-ice #glass-scene .gp3{ left:61%; top:17%; animation-duration:4.4s; animation-delay:-1.5s; }
body.theme-glass-ice #glass-scene .gp4{ left:83%; top:46%; animation-duration:7.4s; animation-delay:-4s; }
body.theme-glass-ice #glass-scene .gp5{ left:-10%; top:auto; bottom:4vmax; width:120vw; height:16vmax; border-radius:50%; box-shadow:none;
  background:linear-gradient(90deg, transparent, rgba(150,210,245,.11) 30%, rgba(200,235,255,.08) 60%, transparent); filter:blur(26px);
  animation:glassMist 46s ease-in-out infinite alternate; }
body.theme-glass-ice #glass-scene .gp6{ left:-10%; top:20vmax; width:120vw; height:10vmax; border-radius:50%; box-shadow:none;
  background:linear-gradient(90deg, transparent, rgba(120,190,235,.07) 40%, rgba(170,225,255,.06) 70%, transparent); filter:blur(30px);
  animation:glassMist 62s ease-in-out infinite alternate-reverse; }

/* Телефон: движение фона выключено, чтобы прокрутка оставалась плавной (звёзды и льдинки просто светятся) */
@media (max-width: 768px){
  #glass-scene .gp, body.theme-glass-aurora #glass-scene .gb{ animation:none !important; }
  body.theme-glass-smoke #glass-scene .gp, body.theme-glass-aurora #glass-scene .gp6{ display:none; }
  body.theme-glass-aurora #glass-scene .gp, body.theme-glass-ice #glass-scene .gp{ opacity:.7; }
}
@media (prefers-reduced-motion: reduce){ #glass-scene .gp, #glass-scene .gb{ animation:none !important; } }
