:root{
  --bg:#0b1020;
  --panel: rgba(255,255,255,.08);
  --panel2: rgba(255,255,255,.10);
  --stroke: rgba(255,255,255,.14);

  --text:#eaf0ff;
  --muted: rgba(234,240,255,.70);

  --primary:#6d5efc;
  --primary2:#9b5cff;
  --ring: rgba(109,94,252,.35);

  --radius:18px;
  --shadow: 0 18px 60px rgba(0,0,0,.45);
}

*{ box-sizing:border-box; }
html,body{ height:100%; }

body{
  margin:0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(900px 450px at 15% 15%, rgba(109,94,252,.35), transparent 60%),
    radial-gradient(850px 420px at 85% 12%, rgba(155,92,255,.28), transparent 55%),
    radial-gradient(1200px 700px at 50% 120%, rgba(0,190,255,.10), transparent 55%),
    linear-gradient(180deg, #070a14, #0b1020);
}

/* page wrapper */
.page{
  max-width: 1120px;
  margin: 0 auto;
  padding: 26px 18px 38px;
}

/* =========================
   WOW TOPBAR
========================= */
.topbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 16px;
  padding: 16px 16px;
  border-radius: 22px;

  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.06));
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.brand{
  display:flex;
  align-items:center;
  gap: 12px;
  min-width: 220px;
}

.logo{
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display:grid;
  place-items:center;

  background: linear-gradient(135deg, var(--primary), var(--primary2));
  box-shadow: 0 14px 30px rgba(109,94,252,.35);
  color: white;
  font-weight: 900;
  letter-spacing: -.02em;
}

.brand-title{
  font-weight: 900;
  letter-spacing: -.02em;
  font-size: 18px;
  line-height: 1.1;
}

.brand-sub{
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px;
}

.topbar-actions{
  display:flex;
  align-items:center;
  gap: 12px;
}

/* search */
.search{
  position: relative;
}

.search input{
  width: min(420px, 52vw);
  padding: 11px 12px 11px 38px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.16);
  outline:none;

  background: rgba(0,0,0,.22);
  color: var(--text);

  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.search input::placeholder{ color: rgba(234,240,255,.45); }

.search::before{
  content:"⌕";
  position:absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(234,240,255,.55);
  font-weight: 800;
}

.search input:focus{
  border-color: rgba(109,94,252,.55);
  box-shadow: 0 0 0 5px var(--ring);
  background: rgba(0,0,0,.30);
}

/* CTA button */
a.cta{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap: 8px;

  padding: 11px 14px;
  border-radius: 14px;
  text-decoration:none;
  color: white;
  font-weight: 900;
  letter-spacing: -.01em;

  background: linear-gradient(135deg, var(--primary), var(--primary2));
  box-shadow: 0 14px 30px rgba(109,94,252,.25);
  border: 1px solid rgba(255,255,255,.16);

  transition: transform .12s ease, filter .12s ease, box-shadow .12s ease;
}

a.cta:hover{
  filter: brightness(1.04);
  box-shadow: 0 18px 38px rgba(109,94,252,.30);
  transform: translateY(-1px);
}
a.cta:active{ transform: translateY(0px); }

/* section title + badge */
.section-title{
  display:flex;
  align-items:center;
  gap: 10px;
  margin: 16px 2px 12px;
  font-weight: 900;
  letter-spacing: -.02em;
  font-size: 14px;
  color: rgba(234,240,255,.90);
}

.badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width: 28px;
  height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  color: rgba(234,240,255,.92);
  background: rgba(109,94,252,.18);
  border: 1px solid rgba(109,94,252,.32);
}

/* =========================
   Cards grid
========================= */
.container{
  display:flex;
  flex-wrap:wrap;
  gap: 12px;
  justify-content:flex-start;
  padding: 0;
  margin: 0;
}

/* class cards */
.class-link{
  width: 270px;
  text-decoration:none;
  color: var(--text);

  padding: 14px 14px;
  border-radius: var(--radius);

  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.06));
  border: 1px solid var(--stroke);
  box-shadow: 0 12px 30px rgba(0,0,0,.28);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);

  font-weight: 900;
  letter-spacing: -.01em;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease, background .15s ease;
}

.class-link:hover{
  transform: translateY(-3px);
  border-color: rgba(109,94,252,.40);
  box-shadow: 0 18px 46px rgba(0,0,0,.36);
}

.class-link:active{ transform: translateY(-1px); }

/* =========================
   Cards (students/jobs)
========================= */
.students-container{
  display:flex;
  flex-wrap:wrap;
  gap: 12px;
  justify-content:flex-start;
}

.student-card{
  width: 270px;
  border-radius: var(--radius);
  overflow:hidden;
  cursor:pointer;

  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.06));
  border: 1px solid var(--stroke);
  box-shadow: 0 12px 30px rgba(0,0,0,.28);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);

  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.student-card:hover{
  transform: translateY(-3px);
  border-color: rgba(109,94,252,.40);
  box-shadow: 0 18px 46px rgba(0,0,0,.36);
}

.student-card h2{
  margin: 12px 12px 6px;
  font-size: 16px;
  font-weight: 950;
  letter-spacing: -.02em;
}

.student-card p{
  margin: 0 12px 14px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

/* =========================
   Modal
========================= */
.modal{
  display:none;
  position:fixed;
  inset:0;
  z-index:999;
  background: rgba(0,0,0,.58);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.modal-content{
  width: min(760px, 92vw);
  margin: 8vh auto;
  padding: 16px;

  border-radius: 22px;
  background: rgba(15,18,36,.72);
  border: 1px solid rgba(255,255,255,.14);
  box-shadow: 0 24px 80px rgba(0,0,0,.55);

  color: var(--text);
}

.modal-content a{ color: #b8b2ff; font-weight: 900; }
.modal-content hr{ border:0; height:1px; background: rgba(255,255,255,.12); margin: 12px 0; }

.close{
  position:absolute;
  right: 18px;
  top: 12px;
  font-size: 28px;
  font-weight: 900;
  color: rgba(234,240,255,.55);
  cursor:pointer;
  user-select:none;
}
.close:hover{ color: rgba(234,240,255,.95); }

/* =========================
   Forms
========================= */
.form-container{
  width: 900px;
  max-width: 95vw;
  margin: 34px auto;
  padding: 18px;

  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.06));
  border: 1px solid var(--stroke);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.form-container h1{
  text-align:center;
  margin: 6px 0 14px;
  font-size: 28px;
  letter-spacing: -.02em;
  font-weight: 1000;
}

.form-grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 12px;
}
.form-grid .full{ grid-column: 1 / -1; }

.form-container input[type="text"],
.form-container input[type="tel"],
.form-container input[type="email"],
.form-container textarea,
.form-container select{
  width:100%;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(0,0,0,.18);
  color: var(--text);
  outline:none;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.form-container textarea{ min-height: 110px; resize: vertical; }

.form-container input:focus,
.form-container textarea:focus,
.form-container select:focus{
  border-color: rgba(109,94,252,.55);
  box-shadow: 0 0 0 5px var(--ring);
  background: rgba(0,0,0,.26);
}

.back-btn{
  background: rgba(255,255,255,.10);
  color: var(--text);
  border: 1px solid rgba(255,255,255,.14);
  padding: 10px 14px;
  border-radius: 14px;
  cursor:pointer;
  box-shadow:none;
}
.back-btn:hover{ background: rgba(255,255,255,.14); }

button, .button, .save-btn{
  border:none;
  border-radius: 14px;
  padding: 11px 14px;
  font-weight: 950;
  color: #fff;
  cursor:pointer;

  background: linear-gradient(135deg, var(--primary), var(--primary2));
  box-shadow: 0 14px 30px rgba(109,94,252,.25);
}
button:hover, .button:hover, .save-btn:hover{ filter: brightness(1.04); }

/* =========================
   Responsive
========================= */
@media (max-width: 860px){
  .topbar{ flex-direction: column; align-items: stretch; }
  .topbar-actions{ width:100%; justify-content: space-between; }
  .search input{ width: 100%; }
  .container{ justify-content:center; }
  .class-link, .student-card{ width: min(520px, 100%); }
  .form-grid{ grid-template-columns: 1fr; }
}

@media (max-width: 420px){
  a.cta{ width:100%; }
  .brand{ min-width: 0; }
  .brand-sub{ display:none; }
}
/* =========================
   class.html header fix (desktop + mobile)
========================= */

/* якщо у class.html є елементи з id */
#class-title{
  display:inline-block;
  font-size: clamp(26px, 4vw, 44px);
  font-weight: 1000;
  letter-spacing: -.03em;
  margin: 6px 0 0;
}

/* якщо у тебе кнопка "на головну" має клас back-btn — ок.
   якщо це просто button — теж підхопить нижче */
.class-header,
.class-top,
.header-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 14px;
  margin: 18px 0 14px;
}

/* універсально: перший великий блок зверху (коли стоїть h1 + кнопка) */
.page > h1 + button,
.page > button + h1{
  margin: 0;
}

/* кнопка "на головну" в цій сторінці */
.back-btn,
#backToMain,
#backBtn{
  white-space: nowrap;
}

/* картки на сторінці розділу */
.students-container{
  padding-top: 6px;
}

/* Mobile layout */
@media (max-width: 860px){
  .class-header,
  .class-top,
  .header-row{
    flex-direction: column;
    align-items: stretch;
  }

  /* заголовок по центру, щоб гарно виглядало */
  #class-title{
    text-align:center;
    width:100%;
  }

  /* кнопка на всю ширину */
  .back-btn,
  #backToMain,
  #backBtn,
  button{
    width: 100%;
  }

  /* картки щоб не були вузькі */
  .student-card{
    width: min(560px, 100%);
  }
}
.notes-box{
  white-space: pre-wrap;
  background: #ffffff;
  color: #111827;
  padding: 12px;
  border-radius: 12px;
  line-height: 1.5;
}
