:root {
  --blue-950: #08244d;
  --blue-850: #0d3470;
  --blue-700: #155bb7;
  --blue-600: #1d6fe8;
  --blue-500: #3a8cff;
  --blue-100: #e8f1ff;
  --blue-050: #f4f8ff;
  --ink: #102033;
  --muted: #63738a;
  --line: #d9e4f2;
  --surface: #ffffff;
  --surface-2: #f7faff;
  --green: #12a87a;
  --amber: #f5a524;
  --red: #e24b5b;
  --violet: #6d5df7;
  --shadow: 0 18px 55px rgba(8, 36, 77, 0.12);
  --shadow-soft: 0 16px 38px rgba(8, 36, 77, 0.08);
  --glass: rgba(255, 255, 255, 0.78);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 18% 8%, rgba(58, 140, 255, 0.16), transparent 28%),
    radial-gradient(circle at 92% 18%, rgba(18, 168, 122, 0.12), transparent 26%),
    linear-gradient(180deg, #f8fbff 0%, #eef5ff 42%, #f7fbff 100%);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(21, 91, 183, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(21, 91, 183, 0.035) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.72), transparent 72%);
  z-index: -1;
}

[hidden] {
  display: none !important;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes soft-pulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.92;
  }
  50% {
    transform: scale(1.04);
    opacity: 1;
  }
}

@keyframes line-flow {
  from {
    background-position: 0 0;
  }
  to {
    background-position: 84px 84px;
  }
}

@keyframes glow-sweep {
  from {
    transform: translateX(-120%);
  }
  to {
    transform: translateX(220%);
  }
}

@keyframes float-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.auth-screen {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 72% 16%, rgba(255, 255, 255, 0.18), transparent 24%),
    linear-gradient(135deg, rgba(8, 36, 77, 0.90), rgba(21, 91, 183, 0.68)),
    url("assets/auth-bg.png") center / cover,
    linear-gradient(180deg, #f4f8ff, #dcecff);
  overflow: hidden;
}

.auth-screen::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 42%;
  background: linear-gradient(180deg, transparent, rgba(8, 36, 77, 0.72));
}

.auth-card {
  position: relative;
  z-index: 1;
  width: min(440px, 100%);
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(16px);
  box-shadow: 0 30px 90px rgba(2, 18, 44, 0.34);
  animation: fade-up 0.55s ease both;
}

.auth-brand {
  margin-bottom: 18px;
  color: var(--ink);
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 16px;
  padding: 4px;
  border-radius: 14px;
  background: rgba(232, 241, 255, 0.8);
}

.auth-tabs button {
  min-height: 38px;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: var(--muted);
  font-weight: 800;
}

.auth-tabs button.active {
  background: white;
  color: var(--blue-850);
  box-shadow: 0 8px 22px rgba(8, 36, 77, 0.08);
}

.auth-form {
  display: grid;
  gap: 12px;
}

.auth-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.auth-form input,
.auth-form select {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.auth-hint {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.auth-error {
  min-height: 20px;
  margin: 12px 0 0;
  color: var(--red);
  font-size: 13px;
  font-weight: 800;
}

.app-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 24px 18px;
  background:
    radial-gradient(circle at 20% 0%, rgba(58, 140, 255, 0.35), transparent 30%),
    linear-gradient(180deg, #071f43 0%, #08244d 58%, #061a36 100%);
  color: white;
  box-shadow: 16px 0 42px rgba(8, 36, 77, 0.14);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brand-logo {
  width: 72px;
  height: auto;
  display: block;
  flex: 0 0 auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.auth-brand .brand-logo {
  width: 104px;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.brand strong,
.brand small {
  display: block;
}

.brand small {
  margin-top: 2px;
  color: #9fbce2;
}

.nav {
  display: grid;
  gap: 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 10px 12px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  color: #dbe9ff;
  text-align: left;
  transition:
    transform 0.18s ease,
    background 0.18s ease,
    color 0.18s ease;
}

.nav-item:hover,
.nav-item.active {
  background: rgba(255, 255, 255, 0.14);
  color: white;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.10);
}

.nav-item.active {
  background: linear-gradient(135deg, rgba(58, 140, 255, 0.42), rgba(255, 255, 255, 0.12));
}

.nav-item:hover {
  transform: translateX(3px);
}

.icon {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  color: #8dccff;
  font-weight: 800;
}

.sidebar-panel {
  margin-top: auto;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.06));
}

.sidebar-panel p,
.sidebar-panel span {
  margin: 0;
  color: #b8cff1;
}

.sidebar-panel strong {
  display: block;
  margin: 4px 0;
  font-size: 20px;
}

.workspace {
  min-width: 0;
  padding: 28px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: -8px -8px 18px;
  padding: 10px 8px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(248, 251, 255, 0.92), rgba(248, 251, 255, 0.76));
  backdrop-filter: blur(16px);
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--blue-600);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.05;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-chip {
  min-height: 44px;
  display: grid;
  align-content: center;
  min-width: 170px;
  padding: 0 12px;
  border: 1px solid rgba(217, 228, 242, 0.8);
  border-radius: 14px;
  background: var(--glass);
  box-shadow: var(--shadow-soft);
}

.user-chip strong,
.user-chip small {
  display: block;
}

.user-chip strong {
  line-height: 1.1;
}

.user-chip small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.search {
  min-width: min(420px, 44vw);
  height: 44px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid rgba(217, 228, 242, 0.8);
  border-radius: 14px;
  background: var(--glass);
  box-shadow: var(--shadow-soft);
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.18s ease;
}

.search:focus-within {
  border-color: rgba(29, 111, 232, 0.42);
  box-shadow: 0 16px 42px rgba(29, 111, 232, 0.13);
  transform: translateY(-1px);
}

.search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
}

select,
input,
textarea {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
  color: var(--ink);
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

select:focus,
input:focus,
textarea:focus {
  border-color: rgba(29, 111, 232, 0.52);
  box-shadow: 0 0 0 4px rgba(29, 111, 232, 0.10);
  outline: none;
}

select {
  min-height: 44px;
  padding: 0 12px;
}

.hero-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  align-items: center;
  gap: 20px;
  margin-bottom: 22px;
  padding: 26px;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 22px;
  background:
    radial-gradient(circle at 88% 26%, rgba(29, 111, 232, 0.24), transparent 28%),
    radial-gradient(circle at 12% 24%, rgba(18, 168, 122, 0.13), transparent 26%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.92) 0%, #e8f2ff 68%, #d9ebff 100%);
  box-shadow: var(--shadow);
}

.hero-band::before,
.landing-dashboard::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 38%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.34), transparent);
  animation: glow-sweep 8s ease-in-out infinite;
  pointer-events: none;
}

.hero-band p,
.hero-band h2 {
  margin: 0;
}

.hero-band p {
  color: var(--blue-700);
  font-weight: 800;
}

.hero-band h2 {
  max-width: 760px;
  margin-top: 8px;
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.12;
}

.robot-visual {
  justify-self: end;
  width: 150px;
  height: 150px;
  display: grid;
  place-items: center;
  border-radius: 22px;
  background: linear-gradient(145deg, #061a36, #0d3470);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.12);
}

.bot-head {
  width: 84px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border-radius: 16px;
  background: white;
}

.bot-head span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--blue-600);
}

.bot-body {
  width: 96px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: -8px;
  border-radius: 14px;
  background: #9bc9ff;
}

.bot-body i {
  width: 10px;
  height: 18px;
  border-radius: 3px;
  background: var(--blue-950);
}

.view {
  display: grid;
  gap: 18px;
}

.landing-dashboard {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.82fr);
  align-items: center;
  gap: 24px;
  min-height: 410px;
  padding: 28px;
  overflow: hidden;
  border-radius: 24px;
  background:
    radial-gradient(circle at 70% 12%, rgba(58, 140, 255, 0.32), transparent 30%),
    linear-gradient(135deg, rgba(8, 36, 77, 0.94), rgba(21, 91, 183, 0.78)),
    linear-gradient(180deg, #dcecff, #ffffff);
  color: white;
  box-shadow: var(--shadow);
  animation: fade-up 0.55s ease both;
}

.landing-copy {
  max-width: 720px;
}

.landing-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
  color: #d9ecff;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.landing-copy h2 {
  margin: 18px 0 0;
  max-width: 780px;
  font-size: clamp(34px, 5vw, 62px);
  line-height: 0.98;
}

.landing-copy p {
  max-width: 620px;
  margin: 18px 0 0;
  color: #d8e8ff;
  font-size: 17px;
  line-height: 1.55;
}

.landing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.network-visual {
  position: relative;
  min-height: 342px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.12), rgba(255,255,255,0.04)),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.12) 0 1px, transparent 1px 42px),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.08) 0 1px, transparent 1px 42px);
  animation: line-flow 18s linear infinite;
  overflow: hidden;
}

.network-node {
  position: absolute;
  z-index: 2;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: white;
  color: var(--blue-950);
  font-weight: 900;
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.22);
  animation: soft-pulse 4.5s ease-in-out infinite;
}

.network-node.hub {
  left: 50%;
  top: 50%;
  width: 98px;
  height: 98px;
  transform: translate(-50%, -50%);
  background: linear-gradient(145deg, #ffffff, #9bc9ff);
  font-size: 28px;
}

.network-node:not(.hub) {
  width: 70px;
  height: 54px;
  font-size: 15px;
}

.network-node.n1 { left: 8%; top: 16%; }
.network-node.n2 { right: 10%; top: 18%; animation-delay: 0.6s; }
.network-node.n3 { left: 13%; bottom: 13%; animation-delay: 1.1s; }
.network-node.n4 { right: 12%; bottom: 16%; animation-delay: 1.7s; }

.network-line {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 38%;
  height: 3px;
  transform-origin: left center;
  background: rgba(255, 255, 255, 0.48);
}

.network-line.l1 { transform: rotate(208deg); }
.network-line.l2 { transform: rotate(330deg); }
.network-line.l3 { transform: rotate(145deg); }
.network-line.l4 { transform: rotate(32deg); }

.landing-panels {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
  gap: 14px;
}

.map-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 16px;
  padding: 18px;
}

.mangystau-map {
  min-height: 320px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background:
    linear-gradient(180deg, #eef7ff, #ffffff);
  border: 1px solid var(--line);
}

.mangystau-map svg {
  width: min(100%, 620px);
  height: auto;
}

.sea {
  fill: #bde4ff;
}

.region {
  fill: #ffffff;
  stroke: #73a9e8;
  stroke-width: 3;
}

.road {
  fill: none;
  stroke: #b7c9de;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 8 9;
}

.map-marker circle:first-child {
  fill: white;
  stroke-width: 4;
}

.map-marker circle:last-child {
  fill: currentColor;
}

.map-marker text {
  fill: var(--ink);
  font-size: 15px;
  font-weight: 900;
  paint-order: stroke;
  stroke: white;
  stroke-width: 4px;
}

.map-marker.active,
.map-dot.active {
  color: var(--green);
  stroke: var(--green);
}

.map-marker.archive,
.map-dot.archive {
  color: var(--red);
  stroke: var(--red);
}

.map-marker.soon,
.map-dot.soon {
  color: var(--amber);
  stroke: var(--amber);
}

.map-marker.neutral,
.map-dot.neutral {
  color: var(--blue-600);
  stroke: var(--blue-600);
}

.branch-list {
  display: grid;
  align-content: start;
  gap: 10px;
}

.branch-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(247, 250, 255, 0.82);
  transition:
    transform 0.18s ease,
    border-color 0.18s ease;
}

.branch-row:hover {
  transform: translateX(3px);
  border-color: rgba(29, 111, 232, 0.34);
}

.map-dot {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 0 5px color-mix(in srgb, currentColor 16%, transparent);
}

.branch-row strong,
.branch-row small {
  display: block;
}

.branch-row small {
  margin-top: 2px;
  color: var(--muted);
}

.landing-metrics-card .card-header {
  border-bottom: 0;
}

.landing-metrics {
  display: grid;
  gap: 12px;
  padding: 0 18px 18px;
}

.landing-metrics div {
  padding: 16px;
  border-radius: 8px;
  background: var(--blue-050);
}

.landing-metrics strong,
.landing-metrics span {
  display: block;
}

.landing-metrics strong {
  color: var(--blue-850);
  font-size: 32px;
  line-height: 1;
}

.landing-metrics span {
  margin-top: 6px;
  color: var(--muted);
  font-weight: 800;
}

.quality-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 14px;
  padding: 18px;
}

.mentor-level {
  display: grid;
  gap: 10px;
  align-content: start;
  padding: 18px;
  border-radius: 8px;
  background: var(--blue-050);
}

.mentor-level span,
.mentor-level small {
  color: var(--muted);
  font-weight: 800;
}

.mentor-level strong {
  font-size: 24px;
}

.level-ring {
  width: 118px;
  height: 118px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, white 0 58%, transparent 59%),
    conic-gradient(var(--green) var(--score), #dce7f5 0);
  color: var(--blue-950);
  font-size: 30px;
  font-weight: 900;
}

.lesson-checklist {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.criterion {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.criterion strong,
.criterion small {
  display: block;
}

.criterion small {
  margin-top: 5px;
  color: var(--muted);
}

.gamification-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  padding: 0 18px 18px;
}

.gamification-grid section {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.gamification-grid h4 {
  margin: 0 0 10px;
  font-size: 15px;
}

.mission-list,
.achievement-list {
  display: grid;
  gap: 8px;
}

.mission,
.achievement {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.mission > span,
.achievement > span {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #eef3f8;
  color: var(--muted);
  font-weight: 900;
}

.mission.done > span,
.achievement.unlocked > span {
  background: rgba(18, 168, 122, 0.14);
  color: #08785a;
}

.mission strong,
.mission small,
.achievement strong,
.achievement small {
  display: block;
}

.mission small,
.achievement small {
  margin-top: 2px;
  color: var(--muted);
}

.xp-history {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.xp-history > strong {
  font-size: 13px;
}

.xp-history div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.xp-history small {
  color: var(--muted);
}

.xp-plus {
  color: #08785a;
  font-weight: 900;
}

.xp-minus {
  color: #b02c3b;
  font-weight: 900;
}

.parent-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.parent-overview {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
  gap: 14px;
}

.parent-map-layout {
  grid-template-columns: minmax(0, 1fr);
}

.parent-news-card .list-row {
  align-items: start;
  background: #fbfdff;
}

.parent-child-card .profile-summary {
  padding: 0 18px 14px;
}

.family-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  margin-bottom: 14px;
  padding: 24px;
  border: 1px solid rgba(29, 111, 232, 0.18);
  border-radius: 18px;
  background:
    radial-gradient(circle at 86% 14%, rgba(18, 168, 122, 0.18), transparent 30%),
    linear-gradient(135deg, #ffffff, #eaf4ff);
  box-shadow: 0 18px 46px rgba(8, 36, 77, 0.11);
}

.family-hero h2 {
  margin: 10px 0 4px;
  color: var(--blue-950);
  font-size: 38px;
}

.family-hero p {
  margin: 0;
  color: var(--muted);
  font-weight: 850;
}

.family-level-card {
  width: 132px;
  height: 132px;
  display: grid;
  place-items: center;
  align-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-600), var(--green));
  color: white;
}

.family-level-card strong {
  font-size: 42px;
}

.family-level-card small {
  max-width: 92px;
  text-align: center;
  font-weight: 850;
}

.family-grid {
  margin-bottom: 14px;
}

.family-store {
  display: grid;
  gap: 10px;
  padding: 18px;
}

.store-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfdff;
}

.store-item.available {
  border-color: rgba(18, 168, 122, 0.24);
  background: rgba(18, 168, 122, 0.08);
}

.store-item small {
  color: var(--muted);
  font-weight: 850;
}

.child-level-panel,
.program-panel {
  display: grid;
  gap: 10px;
  margin: 0 18px 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(180deg, #ffffff, #f7fbff);
}

.child-level-panel {
  border-color: rgba(29, 111, 232, 0.18);
  background:
    linear-gradient(135deg, rgba(29, 111, 232, 0.10), rgba(18, 168, 122, 0.08)),
    white;
}

.child-level-panel strong,
.child-level-panel small,
.program-panel strong,
.program-panel small {
  display: block;
}

.child-level-panel small,
.program-panel small {
  color: var(--muted);
  font-weight: 800;
}

.program-track {
  display: grid;
  grid-template-columns: repeat(17, minmax(0, 1fr));
  gap: 5px;
}

.program-track span {
  aspect-ratio: 1;
  min-width: 0;
  border-radius: 3px;
  background: #dfe9f6;
}

.program-track span.done {
  background: var(--blue-600);
}

.program-track span.current {
  background: var(--amber);
  box-shadow: 0 0 0 3px rgba(243, 180, 53, 0.18);
}

.parent-review {
  border-color: rgba(18, 168, 122, 0.26);
  background: linear-gradient(180deg, #ffffff, #f2fbf8);
}

.season-pass {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
  padding: 18px;
}

.season-reward {
  display: grid;
  gap: 7px;
  min-height: 132px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
}

.season-reward span {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #e9f1fb;
  color: var(--blue-850);
  font-weight: 900;
}

.season-reward strong,
.season-reward small {
  display: block;
}

.season-reward small {
  color: var(--muted);
  font-weight: 800;
}

.season-reward.unlocked {
  border-color: rgba(18, 168, 122, 0.38);
  background:
    linear-gradient(180deg, rgba(18, 168, 122, 0.10), rgba(240, 251, 246, 0.96)),
    #f0fbf6;
}

.season-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 14px 18px 0;
}

.weekly-pass {
  display: grid;
  gap: 12px;
  padding: 18px 18px 0;
}

.weekly-pass span,
.weekly-pass small {
  display: block;
  color: var(--muted);
  font-weight: 800;
}

.weekly-pass strong {
  display: block;
  margin-top: 4px;
  color: var(--blue-950);
  font-size: 24px;
}

.weekly-meter {
  height: 18px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfe9f6;
  box-shadow: inset 0 0 0 1px rgba(8, 36, 77, 0.06);
}

.weekly-meter span {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue-600), var(--green), var(--amber));
}

.weekly-missions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 18px 0;
}

.stats-grid,
.module-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.module-grid {
  grid-template-columns: 1.3fr 0.9fr;
}

.ops-grid {
  margin-top: 14px;
  grid-template-columns: 1.05fr 0.95fr;
}

.card {
  min-width: 0;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(217, 228, 242, 0.86);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(250, 253, 255, 0.92));
  box-shadow: var(--shadow-soft);
  animation: float-in 0.48s ease both;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--blue-600), var(--green), transparent);
  opacity: 0;
  transition: opacity 0.18s ease;
}

.card:hover {
  transform: translateY(-2px);
  border-color: #b7d6ff;
  box-shadow: 0 18px 42px rgba(8, 36, 77, 0.11);
}

.card:hover::before {
  opacity: 1;
}

.stat {
  padding: 18px;
  background:
    radial-gradient(circle at 82% 18%, rgba(29, 111, 232, 0.12), transparent 34%),
    linear-gradient(180deg, #ffffff, #f8fbff);
}

.stat span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.stat strong {
  display: block;
  margin-top: 8px;
  font-size: 30px;
  letter-spacing: 0;
}

.stat small {
  color: var(--green);
  font-weight: 800;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(217, 228, 242, 0.78);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(247, 250, 255, 0.32));
}

.sub-card-head {
  margin-top: 8px;
  border-top: 1px solid var(--line);
  padding-top: 16px;
}

.card-header h3 {
  margin: 0;
  font-size: 18px;
}

.card-body {
  padding: 18px;
}

.finance-stats,
.schedule-stats {
  margin-bottom: 14px;
}

.finance-pulse-card {
  margin-bottom: 14px;
}

.finance-pulse-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.finance-pulse-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(135deg, #ffffff, #f5faff);
}

.finance-pulse-row strong,
.finance-pulse-row small {
  display: block;
}

.finance-pulse-row small {
  margin-top: 3px;
  color: var(--muted);
  font-weight: 750;
}

.finance-pulse-row > span {
  color: var(--blue-850);
  font-weight: 950;
  white-space: nowrap;
}

.cashbox-card {
  margin: 14px 0;
}

.cashbox-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.forecast-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.forecast-title {
  margin-top: 16px;
}

.forecast-payment-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
}

.forecast-payment-row > div:nth-child(2) {
  text-align: right;
}

.cashbox-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.cashbox-columns section {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(247, 250, 255, 0.74);
}

.compact-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.mini-progress {
  height: 7px;
  max-width: 220px;
  margin-top: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfe9f6;
}

.mini-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue-600), var(--green));
}

.button {
  position: relative;
  overflow: hidden;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 800;
  transition:
    transform 0.16s ease,
    box-shadow 0.16s ease,
    background 0.16s ease;
}

.button::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.38), transparent);
  transform: translateX(-140%);
  transition: transform 0.4s ease;
}

.button:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 24px rgba(8, 36, 77, 0.12);
}

.button:hover::after {
  transform: translateX(140%);
}

.button.primary {
  background: linear-gradient(135deg, var(--blue-600), var(--blue-500));
  color: white;
  box-shadow: 0 12px 28px rgba(29, 111, 232, 0.22);
}

.button.secondary {
  background: var(--blue-100);
  color: var(--blue-850);
}

.button.ghost {
  border-color: var(--line);
  background: white;
  color: var(--ink);
}

.button.danger {
  border-color: rgba(226, 75, 91, 0.24);
  background: rgba(226, 75, 91, 0.10);
  color: #b02c3b;
}

.button.compact {
  min-height: 32px;
  padding: 0 10px;
  font-size: 12px;
}

.table-wrap {
  overflow-x: auto;
  border-radius: 0 0 18px 18px;
}

.row-actions,
.task-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  min-width: 760px;
}

th,
td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f7fbff;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

tbody tr {
  transition:
    background 0.16s ease,
    transform 0.16s ease;
}

tbody tr:hover {
  background: rgba(232, 241, 255, 0.52);
}

td strong {
  display: block;
}

td small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  border: 1px solid transparent;
}

.badge.active,
.badge.paid,
.badge.present {
  border-color: rgba(18, 168, 122, 0.24);
  background: rgba(18, 168, 122, 0.12);
  color: #08785a;
}

.badge.trial,
.badge.soon {
  border-color: rgba(245, 165, 36, 0.28);
  background: rgba(245, 165, 36, 0.14);
  color: #9b650d;
}

.badge.pause,
.badge.overdue,
.badge.absent {
  border-color: rgba(226, 75, 91, 0.24);
  background: rgba(226, 75, 91, 0.12);
  color: #b02c3b;
}

.badge.neutral {
  border-color: rgba(217, 228, 242, 0.9);
  background: #eef3f8;
  color: var(--muted);
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.filters {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.list {
  display: grid;
  gap: 10px;
}

.list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(247, 250, 255, 0.86));
  transition:
    transform 0.16s ease,
    border-color 0.16s ease,
    box-shadow 0.16s ease;
}

.list-row:hover {
  transform: translateY(-1px);
  border-color: rgba(29, 111, 232, 0.28);
  box-shadow: 0 10px 24px rgba(8, 36, 77, 0.07);
}

.list-row strong,
.list-row span,
.list-row small {
  display: block;
}

.list-row small {
  margin-top: 3px;
  color: var(--muted);
}

.task-row {
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, var(--surface-2));
  color: inherit;
  text-align: left;
  transition:
    transform 0.16s ease,
    border-color 0.16s ease,
    box-shadow 0.16s ease;
}

.task-row:hover {
  transform: translateY(-1px);
  border-color: rgba(29, 111, 232, 0.28);
  background: white;
  box-shadow: var(--shadow-soft);
}

.task-row strong,
.task-row small {
  display: block;
}

.task-row small {
  margin-top: 3px;
  color: var(--muted);
}

.group-analytics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.group-analytic {
  display: grid;
  gap: 7px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background:
    radial-gradient(circle at 88% 16%, rgba(58, 140, 255, 0.10), transparent 34%),
    linear-gradient(180deg, #ffffff, var(--surface-2));
  transition:
    transform 0.16s ease,
    border-color 0.16s ease;
}

.group-analytic:hover {
  transform: translateY(-1px);
  border-color: rgba(29, 111, 232, 0.26);
}

.group-analytic strong,
.group-analytic span,
.group-analytic small {
  display: block;
}

.group-analytic span,
.group-analytic small {
  color: var(--muted);
}

.group-analytic .risk,
.payment-alert {
  color: #b02c3b;
  font-weight: 800;
}

.payment-alert-row {
  align-items: flex-start;
  border-color: rgba(226, 75, 91, 0.28);
  background: rgba(226, 75, 91, 0.08);
}

.payment-alert-row small {
  color: #8f2530;
  font-weight: 700;
}

.progress {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfe9f6;
  box-shadow: inset 0 1px 2px rgba(8, 36, 77, 0.08);
}

.progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue-600), var(--green));
  box-shadow: 0 0 18px rgba(18, 168, 122, 0.28);
}

.progress-cell {
  width: 132px;
  min-width: 132px;
}

.progress-cell small {
  text-align: right;
}

.learning-shell {
  display: grid;
  gap: 18px;
}

.learning-hero {
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 24px;
  border: 1px solid rgba(47, 111, 237, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(240, 247, 255, 0.96), rgba(255, 255, 255, 0.82)),
    radial-gradient(circle at 90% 20%, rgba(54, 203, 167, 0.22), transparent 32%);
  box-shadow: var(--shadow);
}

.learning-hero h2 {
  margin: 4px 0 8px;
  color: var(--ink);
  font-size: 34px;
  line-height: 1.05;
}

.learning-hero span,
.learning-student-switch {
  color: var(--muted);
  font-weight: 800;
}

.learning-ring {
  width: 132px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at center, #fff 0 58%, transparent 59%),
    conic-gradient(var(--blue-600) var(--progress), rgba(47, 111, 237, 0.12) 0);
}

.learning-ring strong,
.learning-ring small {
  grid-area: 1 / 1;
}

.learning-ring strong {
  margin-top: -12px;
  font-size: 28px;
}

.learning-ring small {
  margin-top: 34px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.learning-student-switch {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.learning-student-switch select {
  min-width: 240px;
}

.learning-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(320px, 0.9fr);
  gap: 18px;
}

.learning-step-list,
.student-checklist,
.lesson-map,
.learning-lesson-list {
  display: grid;
  gap: 10px;
}

.learning-block {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbff;
}

.learning-block span {
  display: block;
  color: var(--blue-700);
  font-size: 12px;
  font-weight: 950;
  text-transform: uppercase;
}

.learning-block p {
  margin: 6px 0 0;
  color: var(--ink);
}

.student-check {
  width: 100%;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.student-check span {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(47, 111, 237, 0.1);
  color: var(--blue-700);
  font-weight: 950;
}

.student-check.done {
  border-color: rgba(18, 168, 122, 0.28);
  background: rgba(18, 168, 122, 0.08);
}

.student-check.done span {
  background: var(--green);
  color: #fff;
}

.lesson-map {
  grid-template-columns: repeat(6, 1fr);
}

.lesson-dot {
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
}

.lesson-dot.done {
  border-color: rgba(18, 168, 122, 0.25);
  background: rgba(18, 168, 122, 0.12);
  color: #08785a;
}

.lesson-dot.current {
  border-color: rgba(47, 111, 237, 0.42);
  background: rgba(47, 111, 237, 0.12);
  color: var(--blue-700);
}

.kanban {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.lane {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.94), rgba(247,250,255,0.9));
  box-shadow: var(--shadow-soft);
}

.lane h3 {
  margin: 0 0 10px;
  font-size: 15px;
}

.feedback-note {
  padding: 12px;
  border-left: 4px solid var(--blue-600);
  border-radius: 14px;
  background: linear-gradient(180deg, #f8fbff, var(--blue-050));
}

.feedback-note p {
  margin: 6px 0 0;
  color: var(--muted);
}

.attendance-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(92px, 1fr));
  gap: 10px;
}

.inline-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.inline-filter select {
  min-width: 170px;
}

.inline-filter input {
  min-width: 150px;
}

.attendance-smart-stats {
  margin-bottom: 14px;
}

.attendance-table {
  min-width: 1040px;
}

.attendance-table th,
.attendance-table td {
  text-align: center;
}

.attendance-table th:first-child,
.attendance-table td:first-child,
.attendance-table th:nth-child(2),
.attendance-table td:nth-child(2) {
  text-align: left;
}

.attendance-warning-row td {
  background: rgba(255, 183, 77, 0.12);
}

.attendance-warning-row td:first-child {
  box-shadow: inset 4px 0 0 var(--amber);
}

.attendance-week-row td:first-child {
  box-shadow: inset 4px 0 0 hsl(var(--week-color) 82% 48%);
}

.attendance-warning-row.attendance-week-row td:first-child {
  box-shadow:
    inset 4px 0 0 var(--amber),
    inset 8px 0 0 hsl(var(--week-color) 82% 48%);
}

.weekly-count-cell {
  min-width: 86px;
}

.weekly-count-cell small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.weekly-attendance-badge {
  min-width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border: 1px solid hsl(var(--week-color) 82% 44% / 0.22);
  border-radius: 999px;
  background: hsl(var(--week-color) 88% 94%);
  color: hsl(var(--week-color) 76% 32%);
  font-weight: 950;
  box-shadow: 0 8px 18px hsl(var(--week-color) 70% 52% / 0.12);
}

.mark {
  min-width: 30px;
  height: 30px;
  padding: 0 8px;
  display: inline-grid;
  place-items: center;
  border: 0;
  border-radius: 10px;
  font-weight: 900;
  transition:
    transform 0.14s ease,
    outline-color 0.14s ease;
}

.mark:hover {
  transform: translateY(-1px);
}

.mark.present {
  background: rgba(18, 168, 122, 0.12);
  color: #08785a;
}

.mark.absent {
  background: rgba(226, 75, 91, 0.12);
  color: #b02c3b;
}

.event-feed {
  display: grid;
  gap: 10px;
}

.event-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
}

.event-row strong,
.event-row small {
  display: block;
}

.event-row small,
.event-row time {
  color: var(--muted);
  font-size: 12px;
}

.event-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: var(--muted);
  box-shadow: 0 0 0 5px rgba(124, 139, 160, 0.12);
}

.event-dot.active,
.event-dot.paid {
  background: var(--green);
  box-shadow: 0 0 0 5px rgba(18, 168, 122, 0.13);
}

.event-dot.soon {
  background: var(--amber);
  box-shadow: 0 0 0 5px rgba(255, 183, 77, 0.16);
}

.event-dot.overdue {
  background: var(--red);
  box-shadow: 0 0 0 5px rgba(233, 67, 67, 0.13);
}

.attention-row {
  border-left: 4px solid rgba(29, 111, 232, 0.24);
}

.mark.missed {
  background: #eef3f8;
  color: #8a9aaf;
}

.mark:hover {
  outline: 2px solid #9bc9ff;
  outline-offset: 2px;
}

.subscription-badge {
  min-width: 76px;
  display: inline-grid;
  gap: 2px;
  padding: 8px 10px;
  border-radius: 12px;
  background: rgba(18, 168, 122, 0.12);
  color: #08785a;
  font-weight: 900;
}

.subscription-badge strong,
.subscription-badge small {
  display: block;
}

.subscription-badge small {
  color: inherit;
  font-weight: 800;
}

.subscription-badge.expired {
  background: rgba(226, 75, 91, 0.12);
  color: #b02c3b;
}

.subscription-badge.warning {
  background: rgba(255, 183, 77, 0.18);
  color: #8a5600;
  box-shadow: inset 0 0 0 1px rgba(255, 183, 77, 0.36);
}

.attendance-history-row .badge {
  white-space: nowrap;
}

.qr-card,
.message-templates {
  display: grid;
  gap: 12px;
}

.qr-card {
  justify-items: center;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f8fbff;
  text-align: center;
}

.qr-card img {
  width: 220px;
  max-width: 100%;
  border-radius: 12px;
  background: white;
  padding: 10px;
  box-shadow: var(--shadow-soft);
}

.unified-qr-card img {
  width: 260px;
}

.qr-scan-note {
  display: grid;
  gap: 4px;
  align-self: end;
  padding: 12px;
  border: 1px solid rgba(29, 111, 232, 0.18);
  border-radius: 14px;
  background: linear-gradient(135deg, #eef6ff, #f7fbff);
}

.qr-scan-note small {
  color: var(--muted);
  font-weight: 750;
  line-height: 1.45;
}

.message-template {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfdff;
}

.message-template p {
  margin: 0;
  color: var(--muted);
  font-weight: 750;
}

.learning-addons {
  margin-top: 14px;
}

.homework-row.done {
  border-color: rgba(18, 168, 122, 0.22);
  background: linear-gradient(180deg, rgba(240, 255, 249, 0.92), rgba(247, 250, 255, 0.86));
}

.photo-report-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.photo-report-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fbfdff;
}

.photo-report-card img,
.photo-placeholder {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: linear-gradient(135deg, var(--blue-600), var(--green));
}

.photo-placeholder {
  display: grid;
  place-items: center;
  color: white;
  font-size: 34px;
  font-weight: 950;
}

.photo-report-card > div {
  display: grid;
  gap: 7px;
  padding: 12px;
}

.photo-report-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
  font-weight: 750;
}

.certificate-list {
  display: grid;
  gap: 10px;
}

.inventory-layout {
  grid-template-columns: 1.15fr 0.85fr;
}

.inventory-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.inventory-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.inventory-card strong,
.inventory-card small {
  display: block;
}

.inventory-card strong {
  margin-top: 8px;
  color: var(--blue-950);
  font-size: 17px;
}

.inventory-card small,
.inventory-card p {
  color: var(--muted);
}

.inventory-card p {
  margin: 8px 0 0;
  line-height: 1.45;
}

.inventory-barcode {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
}

.inventory-qr {
  width: 96px;
  height: 96px;
  border-radius: 8px;
  background: white;
}

.label-print-modal {
  padding: 18px;
}

.print-label-pages {
  display: grid;
  gap: 18px;
  padding: 14px;
  background: #edf4ff;
}

.print-label-sheet {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(5, minmax(0, 1fr));
  gap: 8px;
  width: min(100%, 794px);
  aspect-ratio: 210 / 297;
  margin: 0 auto;
  padding: 30px;
  background: white;
  box-shadow: 0 18px 42px rgba(8, 36, 77, 0.12);
}

.barcode-label {
  min-height: 0;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 4px;
  padding: 6px;
  border: 1px dashed #9fb4cf;
  border-radius: 8px;
  page-break-inside: avoid;
  text-align: center;
}

.barcode-label .inventory-qr {
  width: 82px;
  height: 82px;
}

.barcode-label strong,
.barcode-label small {
  max-width: 100%;
  overflow-wrap: anywhere;
}

.barcode-label strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--blue-950);
  font-size: 11px;
  line-height: 1.15;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.barcode-label small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  line-height: 1.2;
}

.inventory-scan {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.inventory-scan-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  border: 1px solid rgba(29, 111, 232, 0.18);
  border-radius: 18px;
  background: linear-gradient(135deg, #ffffff, #eef6ff);
}

.inventory-scan-hero h3,
.inventory-scan-hero p {
  margin: 6px 0 0;
}

.inventory-scan-hero strong {
  min-width: 130px;
  padding: 12px;
  border-radius: 14px;
  background: var(--blue-950);
  color: white;
  text-align: center;
}

#inventoryVideo {
  width: 100%;
  max-height: 330px;
  border-radius: 16px;
  background: #071f43;
  object-fit: cover;
}

.scan-status {
  padding: 10px 12px;
  border: 1px solid rgba(29, 111, 232, 0.18);
  border-radius: 12px;
  background: #eef6ff;
  color: var(--blue-950);
  font-size: 13px;
  font-weight: 850;
}

.writeoff-selected {
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid rgba(233, 67, 67, 0.22);
  border-radius: 14px;
  background: #fff5f5;
}

.writeoff-selected strong {
  color: var(--blue-950);
}

.writeoff-selected small {
  color: var(--muted);
}

.compact-form {
  grid-template-columns: minmax(0, 1fr) auto;
  padding: 0;
}

.scan-note {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.scan-note textarea {
  min-height: 82px;
  padding: 10px;
}

.certificate-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border: 1px solid rgba(29, 111, 232, 0.18);
  border-radius: 16px;
  background: linear-gradient(135deg, #ffffff, #eef6ff);
}

.certificate-row > div:first-child {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 3px 10px;
  align-items: center;
}

.certificate-row small {
  grid-column: 2;
  color: var(--muted);
  font-weight: 750;
}

.certificate-seal {
  grid-row: span 3;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-600), var(--green));
  color: white;
  font-weight: 950;
}

.certificate-paper {
  padding: 34px;
  border: 8px solid #e5f0ff;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(29, 111, 232, 0.08), transparent 36%),
    #ffffff;
  text-align: center;
  box-shadow: var(--shadow-soft);
}

.certificate-top,
.certificate-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted);
  font-weight: 850;
}

.certificate-top img {
  width: 72px;
}

.certificate-kicker {
  margin: 22px 0 6px;
  color: var(--blue-600);
  font-weight: 900;
  text-transform: uppercase;
}

.certificate-paper h2 {
  margin: 0 0 18px;
  color: var(--blue-950);
  font-size: 34px;
}

.certificate-name {
  display: block;
  margin: 10px 0;
  color: var(--blue-950);
  font-size: 40px;
}

.certificate-paper small {
  display: block;
  max-width: 620px;
  margin: 16px auto 30px;
  color: var(--muted);
  line-height: 1.55;
}

.certificate-actions {
  margin-top: 14px;
}

.day-cell {
  min-height: 112px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
  box-shadow: 0 10px 24px rgba(8, 36, 77, 0.05);
}

.day-cell strong {
  display: block;
  margin-bottom: 8px;
}

.lesson-launch-card,
.lesson-report-card {
  margin-bottom: 14px;
}

.active-lesson-banner {
  position: sticky;
  top: 12px;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
  padding: 14px 16px;
  border: 1px solid rgba(18, 168, 122, 0.24);
  border-radius: 18px;
  background:
    radial-gradient(circle at 8% 10%, rgba(18, 168, 122, 0.16), transparent 28%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(236, 248, 255, 0.98));
  box-shadow: 0 18px 44px rgba(8, 36, 77, 0.13);
  backdrop-filter: blur(12px);
}

.active-lesson-banner.ended {
  border-color: rgba(226, 75, 91, 0.26);
  background: linear-gradient(135deg, #ffffff, #fff3f4);
}

.active-lesson-banner strong {
  display: block;
  margin-top: 4px;
  color: var(--blue-950);
  font-size: 18px;
}

.active-lesson-banner small {
  color: var(--muted);
  font-weight: 800;
}

.lesson-timer {
  min-width: 110px;
  padding: 10px 14px;
  border-radius: 14px;
  background: var(--blue-950);
  color: white;
  font-size: 24px;
  font-weight: 950;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.lesson-launch-list {
  display: grid;
  gap: 10px;
  padding: 16px 18px 18px;
}

.lesson-launch-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(29, 111, 232, 0.16);
  border-radius: 16px;
  background: linear-gradient(135deg, #ffffff, #f1f7ff);
}

.lesson-launch-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-weight: 750;
}

.schedule-board-card {
  margin-bottom: 14px;
}

.schedule-table-wrap {
  overflow-x: auto;
}

.schedule-table {
  min-width: 1180px;
  border-collapse: separate;
  border-spacing: 0;
}

.schedule-table th,
.schedule-table td {
  vertical-align: top;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
}

.schedule-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f8fbff;
}

.schedule-table th:first-child {
  width: 86px;
  color: var(--blue-950);
  font-weight: 950;
}

.schedule-table .today {
  background: rgba(29, 111, 232, 0.06);
}

.schedule-cell {
  min-height: 148px;
  display: grid;
  align-content: start;
  gap: 8px;
}

.schedule-lesson-top,
.schedule-lesson-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.schedule-lesson-card {
  display: grid;
  gap: 8px;
  padding: 11px;
  border: 1px solid rgba(29, 111, 232, 0.14);
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, #f8fbff);
  box-shadow: 0 10px 24px rgba(8, 36, 77, 0.05);
}

.schedule-lesson-card h4 {
  margin: 0;
  color: var(--blue-950);
  font-size: 20px;
}

.schedule-lesson-card small {
  color: var(--muted);
  font-weight: 750;
}

.schedule-load {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfe9f6;
}

.schedule-load span {
  display: block;
  width: var(--load);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue-600), var(--green));
}

.schedule-slots {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}

.schedule-slots span {
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px dashed #bfd2e8;
  border-radius: 8px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
}

.schedule-slots span.filled {
  border-style: solid;
  border-color: rgba(18, 168, 122, 0.28);
  background: rgba(18, 168, 122, 0.10);
  color: #08785a;
}

.schedule-empty {
  padding: 10px;
  border: 1px dashed var(--line);
  border-radius: 12px;
  color: var(--muted);
  text-align: center;
  font-weight: 750;
}

.schedule-add-slot {
  width: 100%;
  min-height: 36px;
  border: 1px dashed rgba(29, 111, 232, 0.32);
  border-radius: 12px;
  background: rgba(232, 241, 255, 0.58);
  color: var(--blue-850);
  font-weight: 900;
}

.slot-manager {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.slot-summary,
.slot-layout {
  display: grid;
  gap: 12px;
}

.slot-summary {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.slot-layout {
  grid-template-columns: 0.9fr 1.1fr;
}

.slot-bank,
.slot-board {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(247, 250, 255, 0.76);
}

.slot-list,
.slot-grid {
  display: grid;
  gap: 9px;
  margin-top: 10px;
}

.slot-student {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 2px 10px;
  align-items: center;
  width: 100%;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
  text-align: left;
}

.slot-student span {
  grid-row: span 2;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--blue-100);
  color: var(--blue-850);
  font-weight: 950;
}

.slot-student small,
.slot-seat small {
  color: var(--muted);
  font-weight: 750;
}

.slot-seat {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: 3px 10px;
  align-items: center;
  padding: 10px;
  border: 1px dashed var(--line);
  border-radius: 14px;
  background: white;
}

.slot-seat.filled {
  border-style: solid;
  border-color: rgba(29, 111, 232, 0.18);
  background: linear-gradient(135deg, #ffffff, #f1f7ff);
}

.slot-seat > span {
  grid-row: span 2;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--blue-950);
  color: white;
  font-weight: 900;
}

.slot-seat .button {
  grid-row: span 2;
}

.lesson-archive-card {
  margin-top: 14px;
}

.lesson-archive-list {
  display: grid;
  gap: 10px;
}

.lesson-archive-row {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(135deg, #ffffff, #f8fbff);
  text-align: left;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.lesson-archive-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-weight: 750;
}

.lesson-archive-row:hover {
  border-color: rgba(29, 111, 232, 0.28);
  box-shadow: 0 12px 28px rgba(8, 36, 77, 0.08);
  transform: translateY(-1px);
}

.lesson-mode {
  display: grid;
  gap: 16px;
}

.lesson-mode-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px;
  border: 1px solid rgba(29, 111, 232, 0.18);
  border-radius: 20px;
  background:
    radial-gradient(circle at 92% 12%, rgba(18, 168, 122, 0.16), transparent 28%),
    linear-gradient(135deg, #ffffff, #eef6ff);
}

.lesson-mode-hero h3 {
  margin: 10px 0 4px;
  color: var(--blue-950);
  font-size: 26px;
}

.lesson-mode-hero p {
  margin: 0;
  color: var(--muted);
  font-weight: 800;
}

.lesson-mode-score {
  width: 112px;
  height: 112px;
  display: grid;
  place-items: center;
  align-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-600), var(--green));
  color: white;
  box-shadow: 0 16px 36px rgba(29, 111, 232, 0.22);
}

.lesson-mode-score strong {
  font-size: 30px;
}

.lesson-mode-score small {
  font-size: 11px;
  font-weight: 850;
}

.lesson-report-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 0 18px;
}

.lesson-report-summary div {
  padding: 13px;
  border: 1px solid rgba(29, 111, 232, 0.16);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #f5f9ff);
}

.lesson-report-summary strong,
.lesson-report-summary small {
  display: block;
}

.lesson-report-summary strong {
  color: var(--blue-950);
  font-size: 24px;
}

.lesson-report-summary small {
  color: var(--muted);
  font-weight: 800;
}

.lesson-check-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.lesson-check-strip span {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f8fbff;
  color: var(--muted);
  text-align: center;
  font-weight: 850;
}

.lesson-check-strip .done {
  border-color: rgba(18, 168, 122, 0.22);
  background: rgba(18, 168, 122, 0.10);
  color: #08785a;
}

.lesson-mode-section {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fbfdff;
}

.section-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--blue-950);
}

.section-title small {
  max-width: 520px;
  color: var(--muted);
  font-weight: 750;
  line-height: 1.45;
}

.lesson-attendance-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.lesson-feedback-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.lesson-student-row,
.lesson-feedback-row {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
}

.lesson-feedback-row {
  grid-template-columns: minmax(0, 1fr) 180px;
  border-color: rgba(29, 111, 232, 0.14);
  background: linear-gradient(180deg, #ffffff, #f8fbff);
}

.lesson-status-choice {
  display: grid;
  grid-template-columns: repeat(3, minmax(42px, 1fr));
  gap: 4px;
  padding: 4px;
  border-radius: 13px;
  background: #edf4ff;
}

.lesson-status-choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.lesson-status-choice label {
  min-height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 950;
  cursor: pointer;
  transition:
    background 0.16s ease,
    color 0.16s ease,
    box-shadow 0.16s ease;
}

.lesson-status-choice input:checked + label {
  background: white;
  color: var(--blue-950);
  box-shadow: 0 8px 18px rgba(8, 36, 77, 0.10);
}

.lesson-status-choice input[value="present"]:checked + label {
  color: #08785a;
}

.lesson-status-choice input[value="absent"]:checked + label {
  color: #b02c3b;
}

.lesson-student-row.payment {
  border-color: rgba(245, 165, 36, 0.32);
  background: rgba(245, 165, 36, 0.08);
}

.lesson-student-row.absence {
  border-color: rgba(226, 75, 91, 0.28);
  background: rgba(226, 75, 91, 0.08);
}

.lesson-student-row small,
.lesson-feedback-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-weight: 750;
}

.lesson-pill {
  display: block;
  margin-top: 6px;
  padding: 7px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--blue-100), #dff0ff);
  color: var(--blue-850);
  font-size: 12px;
  font-weight: 800;
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.task-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.method-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.method-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.task-lane {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(247,250,255,0.9));
  box-shadow: var(--shadow-soft);
}

.task-lane-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.task-lane-head h3 {
  margin: 0;
  font-size: 16px;
}

.team-task {
  display: grid;
  gap: 9px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, var(--surface-2));
  transition:
    transform 0.16s ease,
    border-color 0.16s ease;
}

.team-task:hover {
  transform: translateY(-1px);
  border-color: rgba(29, 111, 232, 0.28);
}

.team-task p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.task-topline,
.task-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.task-topline small,
.task-footer small {
  color: var(--muted);
}

.task-footer select {
  min-height: 34px;
  max-width: 132px;
  padding: 0 8px;
  font-size: 13px;
}

.profile-delete {
  margin-top: 14px;
  width: 100%;
}

.profile {
  padding: 16px;
}

.avatar {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 16px;
  background: linear-gradient(145deg, var(--blue-100), #d9ecff);
  color: var(--blue-850);
  font-weight: 900;
}

.profile h3,
.profile p {
  margin: 0;
}

.profile p {
  margin-top: 6px;
  color: var(--muted);
}

.mini-metrics {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: 14px;
}

.mini-metrics span {
  padding: 10px;
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff, var(--surface-2));
  color: var(--muted);
  font-size: 12px;
}

.mini-metrics strong {
  display: block;
  color: var(--ink);
  font-size: 18px;
}

.profile-modal {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.profile-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.profile-summary .stat {
  box-shadow: none;
}

.profile-sections {
  grid-template-columns: 0.85fr 1.15fr;
}

.modal-root {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(8, 36, 77, 0.58);
  backdrop-filter: blur(10px);
}

.modal-root[hidden] {
  display: none;
}

.modal {
  width: min(720px, 100%);
  max-height: min(760px, 92vh);
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 30px 90px rgba(2, 18, 44, 0.32);
  animation: float-in 0.28s ease both;
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.modal-head h2 {
  margin: 0;
  font-size: 22px;
}

.modal-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 18px;
}

.modal-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.modal-form input,
.modal-form select,
.modal-form textarea {
  width: 100%;
  min-height: 42px;
  padding: 9px 10px;
}

.modal-form textarea {
  min-height: 110px;
  resize: vertical;
}

.family-config-form textarea {
  min-height: 132px;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 12px;
  line-height: 1.45;
}

.form-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.form-alert {
  grid-column: 1 / -1;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(226, 75, 91, 0.12);
  color: #b02c3b;
  font-size: 13px;
  font-weight: 800;
}

.empty {
  padding: 34px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

@media (max-width: 1080px) {
  .app-shell {
    grid-template-columns: 104px minmax(0, 1fr);
  }

  .brand div:not(.brand-logo),
  .nav-item span:last-child,
  .sidebar-panel {
    display: none;
  }

  .brand {
    justify-content: center;
  }

  .nav-item {
    justify-content: center;
  }

  .brand-logo {
    width: 62px;
    padding: 5px;
  }

  .stats-grid,
  .team-grid,
  .task-board,
  .method-grid,
  .parent-grid,
  .finance-pulse-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .group-analytics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .module-grid,
  .learning-grid,
  .kanban,
  .cashbox-grid,
  .cashbox-columns,
  .slot-summary,
  .slot-layout,
  .inventory-layout,
  .profile-sections,
  .quality-layout,
  .parent-overview {
    grid-template-columns: 1fr;
  }

  .profile-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lesson-checklist,
  .inventory-grid,
  .schedule-board,
  .gamification-grid,
  .season-summary,
  .lesson-report-summary,
  .weekly-missions,
  .season-pass,
  .photo-report-grid,
  .lesson-check-strip,
  .lesson-attendance-list,
  .lesson-feedback-list,
  .active-lesson-banner {
    grid-template-columns: 1fr;
  }

  .lesson-launch-row,
  .lesson-archive-row,
  .finance-pulse-row,
  .lesson-mode-hero,
  .family-hero,
  .store-item,
  .section-title,
  .lesson-student-row,
  .lesson-feedback-row {
    grid-template-columns: 1fr;
  }

  .learning-side {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .lesson-mode-hero,
  .family-hero,
  .section-title {
    display: grid;
  }
}

@media print {
  @page {
    size: A4 portrait;
    margin: 8mm;
  }

  body * {
    visibility: hidden;
  }

  .certificate-paper,
  .certificate-paper *,
  .print-label-pages,
  .print-label-pages *,
  .print-label-sheet,
  .print-label-sheet * {
    visibility: visible;
  }

  .certificate-paper {
    position: fixed;
    inset: 18mm;
    box-shadow: none;
  }

  .print-label-pages {
    position: absolute;
    inset: 0;
    display: block;
    padding: 0;
    background: white;
  }

  .print-label-sheet {
    position: relative;
    width: 194mm;
    height: 281mm;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(5, 1fr);
    gap: 3mm;
    padding: 0;
    background: white;
    box-shadow: none;
    page-break-after: always;
  }

  .print-label-sheet:last-child {
    page-break-after: auto;
  }

  .barcode-label {
    border: 1px dashed #777;
    border-radius: 0;
    padding: 2mm;
  }

  .barcode-label .inventory-qr {
    width: 26mm;
    height: 26mm;
  }

  .barcode-label strong {
    font-size: 8.5pt;
  }

  .barcode-label small {
    font-size: 7.5pt;
  }

  .certificate-actions,
  .label-print-modal > .form-actions,
  .modal-head {
    display: none;
  }
}

@media (max-width: 760px) {
  html {
    min-width: 0;
  }

  body {
    background:
      radial-gradient(circle at 50% -10%, rgba(58, 140, 255, 0.18), transparent 34%),
      linear-gradient(180deg, #f8fbff, #eef5ff);
  }

  .app-shell {
    display: block;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 30;
    height: auto;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 10px;
    overflow-x: auto;
    padding: 10px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 16px 34px rgba(8, 36, 77, 0.18);
  }

  .brand-logo {
    width: 52px;
  }

  .learning-hero {
    align-items: flex-start;
    flex-direction: column;
  }

  .learning-hero h2 {
    font-size: 28px;
  }

  .learning-side {
    grid-template-columns: 1fr;
  }

  .lesson-map {
    grid-template-columns: repeat(4, 1fr);
  }

  .brand {
    min-width: 58px;
    justify-content: flex-start;
  }

  .brand div {
    display: none;
  }

  .nav {
    display: flex;
    gap: 7px;
    overflow-x: auto;
    padding-bottom: 2px;
    scroll-snap-type: x proximity;
  }

  .nav-item {
    flex: 0 0 auto;
    justify-content: flex-start;
    scroll-snap-align: start;
    min-height: 40px;
    padding: 9px 10px;
    border-radius: 999px;
  }

  .nav-item span:last-child {
    display: inline;
    max-width: 112px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 13px;
  }

  .icon {
    width: 18px;
    height: 18px;
    font-size: 13px;
  }

  .sidebar-panel {
    display: none;
  }

  .workspace {
    padding: 14px 10px 22px;
  }

  .topbar,
  .topbar-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
  }

  .topbar {
    position: static;
    margin: 0 0 12px;
    padding: 0;
    background: transparent;
    backdrop-filter: none;
  }

  .topbar h1 {
    font-size: 28px;
  }

  .eyebrow {
    font-size: 11px;
  }

  .event-row {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .event-row time {
    grid-column: 2;
  }

  .toolbar,
  .filters {
    align-items: stretch;
    flex-direction: column;
    width: 100%;
  }

  .toolbar > *,
  .filters > *,
  .filters .button,
  .toolbar .button,
  .inline-filter,
  .inline-filter select {
    width: 100%;
  }

  .search {
    min-width: 100%;
  }

  .user-chip {
    min-width: 100%;
  }

  .hero-band {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 16px;
    border-radius: 18px;
  }

  .hero-band h2 {
    font-size: 22px;
  }

  .robot-visual {
    display: none;
  }

  .landing-dashboard {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 18px;
    border-radius: 18px;
  }

  .landing-copy h2 {
    font-size: 32px;
    line-height: 1.02;
  }

  .landing-copy p {
    font-size: 15px;
  }

  .landing-actions .button {
    width: 100%;
  }

  .network-visual {
    min-height: 220px;
  }

  .stats-grid,
  .team-grid,
  .task-board,
  .method-grid,
  .parent-grid,
  .inventory-grid,
  .cashbox-grid,
  .cashbox-columns,
  .slot-summary,
  .slot-layout,
  .inventory-layout,
  .finance-pulse-grid,
  .parent-overview,
  .weekly-missions,
  .season-pass,
  .group-analytics,
  .attendance-grid,
  .profile-summary,
  .landing-panels,
  .map-layout,
  .quality-layout,
  .lesson-checklist,
  .gamification-grid,
  .kanban,
  .profile-sections {
    grid-template-columns: 1fr;
  }

  .forecast-payment-row {
    grid-template-columns: 1fr;
    align-items: flex-start;
  }

  .forecast-payment-row > div:nth-child(2) {
    text-align: left;
  }

  .stats-grid {
    gap: 10px;
  }

  .stat,
  .card-body,
  .card-header {
    padding: 14px;
  }

  .card {
    border-radius: 16px;
  }

  .card:hover,
  .list-row:hover,
  .task-row:hover,
  .team-task:hover,
  .group-analytic:hover {
    transform: none;
  }

  .mangystau-map {
    min-height: 250px;
  }

  .program-track {
    grid-template-columns: repeat(17, minmax(8px, 1fr));
    gap: 4px;
  }

  .season-pass {
    padding: 14px;
  }

  .weekly-missions {
    padding: 12px 14px 0;
  }

  .table-wrap {
    margin: 0 -1px;
    border-radius: 0 0 16px 16px;
    -webkit-overflow-scrolling: touch;
  }

  table {
    min-width: 680px;
  }

  .attendance-table {
    min-width: 860px;
  }

  th,
  td {
    padding: 11px 10px;
  }

  .list-row,
  .task-topline,
  .task-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .task-footer select {
    max-width: none;
    width: 100%;
  }

  .progress-cell {
    width: 100%;
    min-width: 0;
  }

  .progress-cell small {
    text-align: left;
  }

  .profile-modal {
    padding: 12px;
  }

  .modal-root {
    align-items: end;
    padding: 8px;
  }

  .modal {
    width: 100%;
    max-height: 92vh;
    border-radius: 18px;
  }

  .modal-head {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 14px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
  }

  .modal-head h2 {
    font-size: 18px;
  }

  .modal-form {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .form-actions {
    flex-direction: column-reverse;
  }

  .form-actions .button {
    width: 100%;
  }
}

@media (max-width: 520px) {
  .auth-screen {
    padding: 14px;
  }

  .auth-card {
    padding: 18px;
    border-radius: 18px;
  }

  .auth-brand .brand-logo {
    width: 86px;
  }

  .sidebar {
    grid-template-columns: 44px minmax(0, 1fr);
  }

  .brand-logo {
    width: 42px;
  }

  .nav-item {
    gap: 6px;
    padding: 8px 9px;
  }

  .nav-item span:last-child {
    max-width: 86px;
    font-size: 12px;
  }

  .workspace {
    padding-inline: 8px;
  }

  .topbar h1 {
    font-size: 25px;
  }

  .landing-copy h2 {
    font-size: 28px;
  }

  .network-visual {
    display: none;
  }

  .map-layout {
    padding: 12px;
  }

  .mangystau-map {
    min-height: 210px;
  }

  .card-header {
    align-items: stretch;
    flex-direction: column;
  }

  .stat strong {
    font-size: 26px;
  }

  table {
    min-width: 620px;
  }

  .attendance-table {
    min-width: 780px;
  }

  .mini-metrics {
    grid-template-columns: 1fr;
  }

  .program-track {
    grid-template-columns: repeat(12, minmax(8px, 1fr));
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}
