* { margin:0; padding:0; box-sizing:border-box; }

body{
  height:100vh;
  background: radial-gradient(circle at center, #111 0%, #000 100%);
  font-family:'Orbitron',sans-serif;
  overflow:hidden;
  color:#fff;
}

body::before{
  content:"";
  position:absolute;
  width:200%;
  height:200%;
  background:url("https://www.transparenttextures.com/patterns/stardust.png");
  opacity:.15;
  animation:move 80s linear infinite;
}
@keyframes move{ to{ transform:translate(-600px,-600px);} }

.fade-in{ animation:fadeIn .4s ease forwards; }
.fade-out{ animation:fadeOut .5s forwards; }
@keyframes fadeIn{ from{opacity:0; transform:scale(.98)} to{opacity:1} }
@keyframes fadeOut{ to{opacity:0; transform:scale(.96)} }

.center-screen{
  height:100vh;
  display:flex;
  justify-content:center;
  align-items:center;
  letter-spacing:5px;
  position:relative;
  z-index:1;
}

.card{
  background:rgba(255,255,255,0.03);
  border:1px solid rgba(255,255,255,0.08);
  backdrop-filter:blur(12px);
  border-radius:16px;
  box-shadow:0 0 40px rgba(255,255,255,0.05);
}

.navbar{
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  height: 56px;
  padding: 0 22px;
  border-radius: 40px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(14px);
  display: inline-flex;
  align-items: center;
  gap: 22px;
  z-index: 10;
  width: fit-content;
}

.nav-item{
  opacity:.85;
  letter-spacing:3px;
  font-size:12px;
  cursor:pointer;
  padding:10px 10px;
  border-radius:20px;
  transition:.2s;
  text-decoration:none;
  color:inherit;
}
.nav-item:hover{ opacity:1; background:rgba(255,255,255,0.06); }
.nav-item.is-active{ opacity:1; background:rgba(255,255,255,0.08); }

.navbar .spacer{ flex:1; }

.right{
  display:flex;
  align-items:center;
  gap:12px;
}

.profile{
  width:28px; height:28px;
  border-radius:50%;
  border:1px solid rgba(255,255,255,0.4);
}

.btn{
  font-family:'Orbitron',sans-serif;
  background:transparent;
  border:1px solid rgba(255,255,255,0.3);
  color:#fff;
  padding:8px 14px;
  border-radius:20px;
  cursor:pointer;
  letter-spacing:2px;
  font-size:11px;
  transition:.2s;
}
.btn:hover{ background:#fff; color:#000; }

a.btn{
  display:inline-block;
  text-decoration:none;
}

.page{
  position:relative;
  z-index:1;
  height:100vh;
  padding-top:110px;
  overflow:auto;
}

.home-wrap{
  max-width:1200px;
  margin:0 auto;
  padding:0 28px;
}

.grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:28px;
}

.tile{
  height:220px;
  padding:30px;
  border-radius:18px;
  background:rgba(255,255,255,0.03);
  border:1px solid rgba(255,255,255,0.10);
  backdrop-filter:blur(10px);
  transition:.25s;
  cursor:pointer;
  display:flex;
  flex-direction:column;
  justify-content:center;
  text-decoration:none;
  color:inherit;
}

.tile:hover{
  transform:translateY(-8px);
  box-shadow:0 0 28px rgba(255,255,255,0.09);
}

.tile h3{
  font-size:18px;
  letter-spacing:4px;
  margin-bottom:14px;
}

.tile p{
  color:#fff;
  opacity:.9;
  font-size:13px;
  letter-spacing:2px;
  line-height:1.6;
}

/* Home hub: full-viewport grid, centered, large tiles with icons */
.page.page--home{
  display:flex;
  flex-direction:column;
  height:100vh;
  min-height:100vh;
  padding-top:110px;
  padding-bottom:20px;
  box-sizing:border-box;
  overflow:hidden;
}
.page--home .home-wrap{
  flex:1;
  min-height:0;
  max-width:none;
  width:100%;
  margin:0;
  padding:12px clamp(20px,4vw,40px) 24px;
  display:flex;
  align-items:center;
  justify-content:center;
}
.page--home .home-grid{
  width:100%;
  max-width:min(1600px,100%);
  height:100%;
  max-height:min(100%,calc(100vh - 110px - 36px));
  min-height:0;
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  grid-template-rows:repeat(2,minmax(0,1fr));
  gap:clamp(14px,2.2vw,24px);
  align-content:stretch;
}
.page--home .home-grid .tile{
  height:auto;
  min-height:0;
  padding:clamp(20px,3vh,40px) clamp(18px,2.2vw,28px);
  justify-content:center;
  align-items:center;
  text-align:center;
}
.page--home .home-grid .tile h3{
  font-size:clamp(15px,1.5vw+10px,22px);
  margin-bottom:clamp(10px,1.2vh,16px);
}
.page--home .home-grid .tile p{
  font-size:clamp(10px,0.9vw+7px,14px);
  line-height:1.55;
  max-width:32ch;
  margin:0 auto;
}
.page--home .home-grid .tile:hover{
  transform:translateY(-4px) scale(1.01);
}
.tile__icon{
  display:flex;
  align-items:center;
  justify-content:center;
  width:clamp(52px,6.5vh,80px);
  height:clamp(52px,6.5vh,80px);
  margin-bottom:clamp(12px,1.5vh,22px);
  color:rgba(255,255,255,0.92);
  filter:drop-shadow(0 0 12px rgba(255,255,255,0.12));
  flex-shrink:0;
}
.tile__icon svg{
  width:100%;
  height:100%;
  display:block;
}
@media (max-width:1000px){
  .page--home .home-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
    grid-template-rows:repeat(3,minmax(0,1fr));
    max-height:none;
  }
  .page--home{
    overflow:auto;
  }
}
@media (max-width:560px){
  .page--home .home-grid{
    grid-template-columns:1fr;
    grid-template-rows:none;
    grid-auto-rows:minmax(200px,auto);
    height:auto;
  }
}

.page-head{
  max-width:1200px;
  margin:0 auto;
  padding:0 28px 20px;
}

.panel{
  max-width:1200px;
  margin:0 auto;
  padding:0 28px;
}

.small-link{
  display:inline-block;
  margin-top:18px;
  letter-spacing:2px;
  font-size:12px;
  cursor:pointer;
  color:inherit;
  text-decoration:none;
}
a.small-link:hover{ opacity:.85; }

.quiz-here-link{
  text-decoration:underline;
  cursor:pointer;
  letter-spacing:2px;
}
.quiz-here-link:hover{ opacity:.85; }

.quiz-page{
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:calc(100vh - 110px);
  padding:24px 28px 48px;
}
.quiz-center-wrap{
  width:100%;
  max-width:520px;
  margin:0 auto;
  text-align:center;
}
.quiz-meta{
  font-size:11px;
  letter-spacing:3px;
  opacity:.75;
  margin-bottom:10px;
}
.quiz-progress{
  height:3px;
  border-radius:2px;
  background:rgba(255,255,255,.08);
  margin-bottom:24px;
  overflow:hidden;
}
.quiz-progress-fill{
  height:100%;
  background:rgba(255,255,255,.35);
  transition:width .25s ease;
}
.quiz-card{
  padding:34px 28px 36px;
  text-align:left;
}
.quiz-body{
  margin-bottom:6px;
}
.quiz-q{
  font-size:15px;
  letter-spacing:2px;
  line-height:1.5;
  margin-bottom:22px;
  font-weight:600;
}
.quiz-opts{
  display:flex;
  flex-direction:column;
  gap:10px;
  margin-bottom:24px;
}
.quiz-opt{
  font-family:'Orbitron',sans-serif;
  width:100%;
  text-align:left;
  padding:14px 16px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.12);
  background:rgba(255,255,255,.04);
  color:#fff;
  font-size:11px;
  letter-spacing:2px;
  cursor:pointer;
  transition:.2s;
}
.quiz-opt:hover{
  background:rgba(255,255,255,.08);
  border-color:rgba(255,255,255,.2);
}
.quiz-opt--on{
  border-color:rgba(255,255,255,.35);
  background:rgba(255,255,255,.1);
  box-shadow:0 0 18px rgba(255,255,255,.06);
}
.quiz-actions{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  margin-top:32px;
  padding-top:26px;
  border-top:1px solid rgba(255,255,255,.08);
}
.quiz-actions .btn:disabled{
  opacity:.35;
  cursor:not-allowed;
  pointer-events:none;
}
.quiz-backstep{ visibility:visible; }
.quiz-backstep.is-hidden{ visibility:hidden; }
.quiz-backlink{ margin-top:22px; }

.quiz-slider-value{
  font-size:22px;
  letter-spacing:3px;
  margin-bottom:16px;
  text-align:center;
}
.quiz-slider{
  width:100%;
  accent-color:rgba(255,255,255,.75);
  margin-top:8px;
}
.quiz-year-row{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  flex-wrap:wrap;
  margin-bottom:8px;
}
.quiz-year-prefix{
  font-size:20px;
  letter-spacing:4px;
  opacity:.95;
}
.quiz-year-input{
  width:4.2em;
  max-width:100%;
  padding:12px 10px;
  text-align:center;
  font-family:'Orbitron',sans-serif;
  font-size:16px;
  letter-spacing:3px;
  background:rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.12);
  border-radius:10px;
  color:#fff;
}
.quiz-year-input::placeholder{
  color:rgba(255,255,255,.28);
}
.quiz-input,
.quiz-textarea{
  width:100%;
  margin-top:10px;
  padding:14px 14px;
  font-family:'Orbitron',sans-serif;
  font-size:11px;
  letter-spacing:2px;
  line-height:1.5;
  background:rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.12);
  border-radius:10px;
  color:#fff;
  resize:vertical;
  min-height:48px;
}
.quiz-textarea{ min-height:100px; }
.quiz-follow{
  margin-top:18px;
  margin-bottom:4px;
  padding-top:18px;
  border-top:1px solid rgba(255,255,255,.08);
}
.quiz-follow-label{
  display:block;
  font-size:11px;
  letter-spacing:2px;
  opacity:.85;
  margin-bottom:8px;
}
.quiz-yn-row{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
}
.quiz-opt-yn{ text-align:center; }
.quiz-select{
  width:100%;
  margin-top:10px;
  padding:12px 12px;
  font-family:'Orbitron',sans-serif;
  font-size:11px;
  letter-spacing:2px;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.14);
  border-radius:10px;
  color:#fff;
}
.quiz-select option{ background:#111; color:#fff; }

/* -------- Course outline (View page) -------- */
.course-outline{
  position:relative;
  padding:8px 8px 8px 36px;
  max-width:820px;
}
.course-outline__item{
  position:relative;
  padding-bottom:36px;
}
/* Spine segments stop at hollow dots (no line through ring interior) */
.course-outline__item:not(:first-child)::before{
  content:"";
  position:absolute;
  left:8px;
  top:0;
  width:1px;
  height:4px;
  transform:translateX(-50%);
  background:rgba(255,255,255,.16);
  pointer-events:none;
}
.course-outline__item:not(:last-child)::after{
  content:"";
  position:absolute;
  left:8px;
  top:21px;
  width:1px;
  bottom:0;
  transform:translateX(-50%);
  background:linear-gradient(180deg,rgba(255,255,255,.18),rgba(255,255,255,.08));
  pointer-events:none;
}
.course-outline__item:last-child{
  padding-bottom:0;
}
.course-outline__row{
  display:flex;
  align-items:flex-start;
  gap:16px;
}
.course-outline__dot{
  flex-shrink:0;
  width:16px;
  height:16px;
  margin-top:4px;
  border-radius:50%;
  border:2px solid rgba(255,255,255,.42);
  background:transparent;
  box-shadow:0 0 0 3px rgba(0,0,0,.35);
  position:relative;
  z-index:2;
}
.course-outline__dot--complete{
  border-color:rgba(94,207,122,.9);
  box-shadow:
    0 0 0 3px rgba(0,0,0,.35),
    0 0 14px rgba(80,200,110,.28);
}
.course-outline__main{
  flex:1;
  min-width:0;
}
.course-outline__name{
  font-size:13px;
  font-weight:600;
  letter-spacing:3px;
  margin-bottom:6px;
  line-height:1.35;
}
.course-outline__hint{
  font-size:11px;
  letter-spacing:2px;
  line-height:1.55;
  opacity:.78;
}
.course-outline__branch{
  list-style:none;
  margin:14px 0 0 32px;
  padding:0 0 0 18px;
  border-left:1px solid rgba(255,255,255,.14);
}
.course-outline__branch li{
  position:relative;
  font-size:10px;
  letter-spacing:1.5px;
  line-height:1.55;
  opacity:.82;
  padding:8px 0 8px 4px;
}
.course-outline__branch li::before{
  content:"";
  position:absolute;
  left:-18px;
  top:50%;
  width:12px;
  height:1px;
  background:rgba(255,255,255,.14);
  transform:translateY(-50%);
}
.course-outline__bracket{
  display:inline-block;
  margin-top:2px;
  font-size:10px;
  letter-spacing:2px;
  opacity:.45;
  user-select:none;
}
.course-view-foot{
  margin-top:28px;
  padding-top:22px;
  border-top:1px solid rgba(255,255,255,.08);
}

/* -------- Locked mode (Start page) -------- */
.course-outline--locked .course-outline__item.is-locked::before,
.course-outline--locked .course-outline__item.is-locked::after{
  background:rgba(150,150,150,.12);
}
.course-outline--locked .course-outline__item.is-locked .course-outline__dot{
  border-color:rgba(165,165,165,.42);
  box-shadow:0 0 0 3px rgba(0,0,0,.35);
}
.course-outline--locked .course-outline__item.is-locked .course-outline__name,
.course-outline--locked .course-outline__item.is-locked .course-outline__hint,
.course-outline--locked .course-outline__item.is-locked .course-outline__branch li,
.course-outline--locked .course-outline__item.is-locked .course-outline__bracket{
  color:rgba(190,190,190,.55);
  opacity:.55;
}
.course-outline__lock{
  display:inline-block;
  margin-top:8px;
  font-size:10px;
  letter-spacing:2px;
  opacity:.65;
}
.course-outline__open{
  display:block;
  text-decoration:none;
  color:inherit;
}
.course-outline__open:hover{
  opacity:.9;
}

/* -------- Start path layout -------- */
.path-layout{
  max-width:1200px;
  margin:0 auto;
  min-height:calc(100vh - 140px);
  padding:14px 28px 38px;
  display:grid;
  grid-template-columns:minmax(180px,240px) minmax(360px,560px) minmax(180px,240px);
  gap:30px;
  align-items:center;
}
.path-col{
  align-self:center;
}
.path-col--side{
  justify-self:stretch;
}
.path-side-title{
  font-size:11px;
  letter-spacing:2px;
  opacity:.7;
  margin-bottom:14px;
}
.path-list{
  list-style:none;
  padding:0;
  margin:0;
  display:flex;
  flex-direction:column;
  gap:10px;
}
.path-pill{
  border:1px solid rgba(255,255,255,.1);
  background:rgba(255,255,255,.03);
  border-radius:12px;
  padding:10px 12px;
  font-size:10px;
  letter-spacing:1.8px;
  opacity:.82;
}
.path-pill--past{
  border-color:rgba(88,201,116,.4);
}
.path-pill--upcoming{
  border-color:rgba(160,160,160,.24);
  opacity:.56;
}
.path-center{
  text-align:center;
}
.path-main-card{
  width:min(100%,520px);
  margin:0 auto;
  min-height:340px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:12px;
  letter-spacing:2px;
  opacity:.85;
}
.path-main-note{
  margin-top:18px;
  font-size:11px;
  letter-spacing:2px;
  opacity:.72;
  line-height:1.6;
}
.path-nav{
  margin-top:28px;
  display:flex;
  justify-content:center;
  gap:18px;
}
.path-arrow{
  appearance:none;
  width:42px;
  height:42px;
  border-radius:50%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  text-decoration:none;
  font-size:18px;
  line-height:1;
  color:#fff;
  border:1px solid rgba(255,255,255,.26);
  background:rgba(255,255,255,.04);
  transition:.2s;
}
.path-arrow:hover{
  background:rgba(255,255,255,.12);
}
.path-arrow:disabled{
  opacity:.35;
  cursor:not-allowed;
}
