:root {
  color-scheme: light;
  --bg: #f5f7f9;
  --surface: #ffffff;
  --surface-soft: #edf4f7;
  --ink: #172b3a;
  --muted: #667782;
  --line: #d8e1e7;
  --primary: #176b87;
  --primary-dark: #124e63;
  --accent: #2f7d78;
  --gold: #d49a32;
  --good: #23775a;
  --bad: #b7434f;
  --review: #6655a9;
  --warn: #a96f17;
  --night: #173449;
  --shadow: 0 12px 30px rgba(23, 52, 73, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--bg);
}

body {
  margin: 0;
  font-family: Aptos, Inter, "Nirmala UI", "Noto Sans Devanagari", Mangal, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
}

button,
input,
select {
  font: inherit;
}

#app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 13px clamp(16px, 4vw, 48px);
  color: var(--ink);
  background: rgba(244, 250, 252, 0.72);
  border-top: 3px solid rgba(23, 107, 135, 0.82);
  border-bottom: 1px solid rgba(255, 255, 255, 0.82);
  -webkit-backdrop-filter: blur(22px) saturate(145%);
  backdrop-filter: blur(22px) saturate(145%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    0 10px 30px rgba(23, 52, 73, 0.11);
}

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

.brand-logo {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.58);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 6px 16px rgba(23, 52, 73, 0.12);
}

.brand span {
  display: grid;
  gap: 2px;
}

.brand strong {
  color: var(--ink);
  font-size: 1.04rem;
}

.brand small {
  color: var(--muted);
  font-size: 0.78rem;
}

.main-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.34);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.main-nav a {
  position: relative;
  text-decoration: none;
  color: var(--muted);
  padding: 9px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  transition:
    color 150ms ease,
    background-color 150ms ease,
    border-color 150ms ease,
    box-shadow 150ms ease,
    transform 150ms ease;
}

.main-nav a:hover {
  color: var(--primary-dark);
  background: rgba(255, 255, 255, 0.68);
}

.main-nav a.active {
  color: #ffffff;
  border-color: rgba(255, 244, 214, 0.88);
  background: rgba(178, 122, 34, 0.94);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.94),
    0 5px 14px rgba(178, 122, 34, 0.28);
  transform: translateY(-1px);
}

.main-nav a.active::after {
  content: "";
  position: absolute;
  right: 10px;
  bottom: 4px;
  left: 10px;
  height: 2px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.9);
}

.icon-button {
  display: none;
  width: 42px;
  height: 42px;
  margin-left: auto;
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 5px 14px rgba(23, 52, 73, 0.1);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
}

.icon-button span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--ink);
}

main {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  flex: 1;
  padding: 32px 0 48px;
}

main.attempt-mode {
  width: min(1480px, calc(100% - 28px));
  padding-top: 18px;
}

main.attempt-mode + .site-footer {
  display: none;
}

.online-practice {
  padding: 8px 0 28px;
}

.online-practice-title {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
}

.online-practice-title h1,
.online-practice-title h2 {
  margin: 0;
  color: var(--night);
  font-size: clamp(1.55rem, 3vw, 2.1rem);
  line-height: 1.1;
}

.online-practice-title > div {
  display: grid;
  gap: 3px;
}

.online-practice-title p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.practice-kicker {
  color: var(--gold);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.1em;
}

.brain-mark {
  position: relative;
  width: 20px;
  height: 25px;
  border-radius: 5px;
  background: var(--primary);
  box-shadow: none;
}

.brain-mark::before,
.brain-mark::after {
  content: "";
  position: absolute;
  left: 7px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ffffff;
}

.brain-mark::before {
  top: 4px;
}

.brain-mark::after {
  bottom: 4px;
}

.practice-menu {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  min-height: 158px;
}

.practice-menu-item {
  position: relative;
  overflow: hidden;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 11px;
  min-width: 0;
  min-height: 168px;
  padding: 22px 12px 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 5px 16px rgba(23, 52, 73, 0.055);
  text-decoration: none;
  color: var(--ink);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
  appearance: none;
  cursor: pointer;
  font: inherit;
  text-align: center;
}

.practice-menu-item::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  background: var(--primary);
}

.practice-menu-item:nth-child(2)::before {
  background: #3e7fa8;
}

.practice-menu-item:nth-child(3)::before {
  background: #8a6b3f;
}

.practice-menu-item:nth-child(4)::before {
  background: var(--review);
}

.practice-menu-item:hover {
  transform: translateY(-2px);
  border-color: rgba(23, 107, 135, 0.35);
  box-shadow: 0 10px 24px rgba(23, 52, 73, 0.1);
}

.practice-menu-item.inactive {
  opacity: 0.58;
}

.practice-menu-item.inactive:hover {
  transform: none;
  border-color: var(--line);
  box-shadow: 0 5px 16px rgba(23, 52, 73, 0.055);
}

.practice-menu-item strong {
  font-size: 1.06rem;
  font-weight: 800;
}

.practice-menu-item small {
  max-width: 150px;
  color: var(--muted);
  font-size: 0.74rem;
  line-height: 1.35;
}

.menu-visual {
  position: relative;
  width: 68px;
  height: 68px;
  display: grid;
  place-items: center;
  border-radius: 8px;
}

.all-test-visual {
  grid-template-columns: repeat(2, 27px);
  grid-template-rows: repeat(2, 27px);
  gap: 5px;
  background: #eaf2f6;
}

.all-test-visual i {
  display: block;
  width: 27px;
  height: 27px;
  border-radius: 6px;
  background: var(--primary);
}

.all-test-visual i:nth-child(2),
.all-test-visual i:nth-child(3) {
  background: #5c8ba4;
}

.gift-visual {
  color: #3e7fa8;
  background: #edf4f8;
}

.gift-visual i {
  position: absolute;
  bottom: 7px;
  width: 48px;
  height: 40px;
  border: 6px solid currentColor;
  border-radius: 5px;
}

.gift-visual i::before {
  content: "";
  position: absolute;
  top: -16px;
  left: -10px;
  width: 56px;
  height: 10px;
  border-radius: 4px;
  background: currentColor;
}

.gift-visual i::after {
  content: "";
  position: absolute;
  top: -26px;
  left: 8px;
  width: 22px;
  height: 18px;
  border: 6px solid currentColor;
  border-radius: 50% 50% 0 0;
  transform: rotate(-15deg);
}

.gift-visual b {
  position: absolute;
  right: 0;
  top: 5px;
  font-size: 25px;
}

.saved-test-visual {
  color: #8a6b3f;
  background: #f5f1e9;
}

.saved-test-visual i {
  position: absolute;
  inset: 4px 12px 3px;
  border-radius: 7px 7px 3px 3px;
  background: currentColor;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 78%, 0 100%);
}

.saved-test-visual b {
  position: relative;
  z-index: 1;
  color: #ffffff;
  font-size: 24px;
}

.quiz-visual {
  background: #f0eef8;
}

.quiz-visual i {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: var(--review);
  font-style: normal;
  font-size: 2rem;
  font-weight: 900;
  box-shadow: none;
}

.quiz-visual b {
  position: absolute;
  right: 4px;
  bottom: 5px;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border: 3px solid #ffffff;
  border-radius: 50%;
  color: #ffffff;
  background: var(--accent);
  font-size: 0.86rem;
  line-height: 1;
}

.home-overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  margin-top: 4px;
}

.home-section {
  min-width: 0;
  padding: 8px 0 12px;
}

.home-section .section-head.compact {
  align-items: center;
  margin: 0 0 13px;
}

.home-section .section-head.compact h2 {
  font-size: 1.3rem;
}

.home-section .section-head.compact p {
  margin-top: 4px;
  font-size: 0.9rem;
}

.text-link {
  flex: 0 0 auto;
  color: var(--primary);
  font-size: 0.88rem;
  font-weight: 800;
  text-decoration: none;
}

.text-link:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

.home-resume-card {
  min-height: 126px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 16px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--primary);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 7px 18px rgba(23, 52, 73, 0.06);
}

.home-card-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #ffffff;
  background: var(--primary);
  font-size: 0.9rem;
}

.home-card-copy {
  min-width: 0;
}

.home-card-copy > span {
  color: var(--primary);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.home-card-copy h3,
.home-new-test h3 {
  margin: 4px 0 5px;
  color: var(--ink);
  font-size: 1rem;
}

.home-card-copy p,
.home-new-test p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.45;
}

.home-empty-state {
  min-height: 126px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 18px;
  border: 1px dashed #bdccd5;
  border-radius: 8px;
  color: var(--muted);
  background: #f9fbfc;
}

.home-empty-state strong {
  color: var(--ink);
}

.home-empty-state a {
  width: fit-content;
  margin-top: 5px;
  color: var(--primary);
  font-weight: 800;
  text-decoration: none;
}

.home-recent-list {
  min-height: 126px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.home-recent-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-height: 72px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}

.home-recent-row:last-child {
  border-bottom: 0;
}

.home-recent-row:hover {
  background: #f6fafb;
}

.recent-score {
  display: grid;
  place-items: center;
  min-height: 42px;
  padding: 6px;
  border-radius: 7px;
  color: var(--primary-dark);
  background: var(--surface-soft);
  font-size: 0.8rem;
  font-weight: 900;
}

.recent-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.recent-copy strong,
.recent-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-copy small {
  color: var(--muted);
}

.recent-arrow {
  color: var(--primary);
  font-size: 1.6rem;
  line-height: 1;
}

.new-tests-section {
  margin-top: 13px;
}

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

.home-new-test {
  min-width: 0;
  min-height: 190px;
  display: grid;
  align-content: start;
  gap: 9px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 7px 18px rgba(23, 52, 73, 0.05);
}

.home-new-test .ghost-button {
  align-self: end;
  width: fit-content;
  margin-top: auto;
}

.pill.new {
  color: #7d520d;
  border-color: #ead29f;
  background: #fff5dc;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(16px, 4vw, 48px);
  border-top: 1px solid #274a60;
  color: #d8e4eb;
  background: var(--night);
  font-size: 0.9rem;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(280px, 0.7fr);
  gap: 24px;
  align-items: stretch;
  padding: clamp(22px, 4vw, 36px) 0 18px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 360px;
}

.eyebrow {
  width: fit-content;
  margin: 0 0 12px;
  padding: 6px 10px;
  border: 1px solid #f3d58d;
  border-radius: 999px;
  color: #79500d;
  background: #fff9e8;
  font-size: 0.8rem;
  font-weight: 700;
}

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

h1 {
  margin: 0;
  font-size: clamp(2.1rem, 5vw, 3.8rem);
  line-height: 1.04;
  letter-spacing: 0;
}

.hero-copy p {
  max-width: 680px;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.18rem);
  line-height: 1.7;
}

.hero-actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.primary-button,
.secondary-button,
.ghost-button,
.danger-button {
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  text-decoration: none;
  cursor: pointer;
  font-weight: 700;
  transition: transform 150ms ease, box-shadow 150ms ease, background-color 150ms ease, border-color 150ms ease;
}

.primary-button {
  background: var(--primary);
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(23, 107, 135, 0.16);
}

.primary-button:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
}

.secondary-button {
  background: #ffffff;
  color: #57488f;
  border-color: #cfc9e7;
}

.ghost-button {
  color: var(--primary-dark);
  background: var(--surface);
  border-color: var(--line);
}

.ghost-button:hover,
.secondary-button:hover {
  border-color: var(--primary);
  box-shadow: 0 5px 14px rgba(21, 58, 54, 0.08);
}

.danger-button {
  color: #ffffff;
  background: var(--bad);
}

.hero-panel {
  min-height: 360px;
  display: grid;
  gap: 14px;
  align-content: center;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  border-top: 4px solid var(--gold);
}

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

.metric {
  min-height: 98px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #f8fbfa;
}

.metric strong {
  font-size: 1.7rem;
}

.metric span {
  color: var(--muted);
  font-size: 0.86rem;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 14px;
  margin: 18px 0 14px;
}

.section-head h2,
.page-title h1 {
  margin: 0;
  font-size: clamp(1.45rem, 3vw, 2rem);
  letter-spacing: 0;
}

.section-head p,
.page-title p {
  color: var(--muted);
  margin: 8px 0 0;
  line-height: 1.6;
}

.grid {
  display: grid;
  gap: 14px;
}

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

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

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

.practice-tool {
  min-height: 220px;
  display: grid;
  align-content: space-between;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 8px 20px rgba(21, 58, 54, 0.05);
}

.practice-tool.daily-tool {
  color: #ffffff;
  background: var(--night);
  border-color: var(--night);
}

.practice-tool h3 {
  margin: 0 0 7px;
  font-size: 1.12rem;
}

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

.practice-tool.daily-tool p {
  color: #cfe3de;
}

.tool-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #ffffff;
  background: var(--primary);
  font-weight: 900;
  box-shadow: none;
}

.bookmark-button {
  min-height: 32px;
  margin-left: auto;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--primary-dark);
  background: #ffffff;
  cursor: pointer;
  font-weight: 700;
  transition: border-color 150ms ease, background-color 150ms ease;
}

.bookmark-button.saved {
  color: #8c5a09;
  border-color: #f3d58d;
  background: #fff7df;
}

.progress-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 14px;
  margin-top: 14px;
}

.accuracy-list,
.history-list {
  display: grid;
  gap: 12px;
}

.accuracy-row {
  display: grid;
  grid-template-columns: minmax(120px, 1fr) minmax(100px, 1fr) 46px;
  gap: 10px;
  align-items: center;
}

.accuracy-row div:first-child,
.history-row div {
  display: grid;
  gap: 3px;
}

.accuracy-row span,
.history-row span {
  color: var(--muted);
  font-size: 0.82rem;
}

.accuracy-track {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfe9e6;
}

.accuracy-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
}

.history-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  box-shadow: 0 8px 22px rgba(21, 58, 54, 0.055);
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

.card h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

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

.category-card,
.test-card {
  display: grid;
  gap: 12px;
  min-height: 170px;
}

.category-card:hover,
.test-card:hover {
  border-color: rgba(8, 127, 115, 0.35);
  box-shadow: 0 12px 28px rgba(21, 58, 54, 0.09);
}

.category-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #ffffff;
  font-weight: 800;
  background: var(--primary);
  box-shadow: none;
}

.category-card:nth-child(2) .category-icon {
  background: var(--accent);
  box-shadow: none;
}

.category-card:nth-child(3) .category-icon {
  background: #2674c8;
  box-shadow: none;
}

.category-card:nth-child(4) .category-icon {
  background: var(--review);
  box-shadow: none;
}

.test-meta,
.result-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  color: var(--muted);
  font-size: 0.9rem;
}

.pill {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.82rem;
  font-weight: 700;
  background: var(--surface-soft);
  color: var(--primary-dark);
}

.pill.free {
  color: var(--good);
  background: #dcf6ea;
}

.pill.review {
  color: var(--review);
  background: #eeebff;
}

.notice,
.empty-state,
.loading-state {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 8px;
  padding: 18px;
  color: var(--muted);
  line-height: 1.6;
}

.notice {
  border-color: #f3d58d;
  border-left: 5px solid var(--gold);
  background: #fff9e8;
  color: #79500d;
}

.page-title {
  margin: 14px 0 18px;
}

.layout-two {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 330px);
  gap: 18px;
  align-items: start;
}

.instruction-list {
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.7;
}

.attempt-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 20px;
  align-items: start;
}

.attempt-header {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.attempt-header h1 {
  max-width: 820px;
  color: var(--ink);
  font-size: clamp(1.75rem, 3.2vw, 2.55rem);
  line-height: 1.15;
  font-weight: 750;
}

.attempt-header .test-meta {
  margin-top: 8px;
}

.attempt-header .test-meta span + span::before {
  content: "•";
  margin-right: 8px;
  color: #a4b1b9;
}

.timer {
  display: inline-flex;
  min-width: 118px;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 6px;
  color: #ffffff;
  background: var(--night);
  box-shadow: 0 5px 12px rgba(23, 52, 73, 0.14);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  font-weight: 800;
}

.question-card {
  min-height: 410px;
  padding: 22px;
  border-top: 3px solid var(--primary);
}

.question-card h2 {
  color: var(--ink);
  font-size: 1.22rem;
  line-height: 1.5;
  margin: 14px 0 20px;
  font-weight: 700;
}

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

.numeric-answer-control {
  display: grid;
  gap: 8px;
  max-width: 420px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-soft);
  font-weight: 800;
}

.numeric-answer-control input {
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid var(--border-strong, var(--border));
  border-radius: 10px;
  color: var(--text);
  background: var(--surface);
  font: inherit;
}

.option {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: 100%;
  min-height: 54px;
  padding: 14px 15px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  background: color-mix(in srgb, var(--surface-solid) 92%, var(--bg));
  cursor: pointer;
  line-height: 1.45;
  transition: border-color 140ms ease, background-color 140ms ease;
}

.option:hover {
  border-color: var(--line-strong);
  background: color-mix(in srgb, var(--primary) 10%, var(--surface-solid));
}

.option input {
  margin-top: 3px;
  accent-color: var(--primary);
}

.option.selected {
  border-color: var(--primary);
  background: var(--surface-soft);
  box-shadow: inset 4px 0 0 var(--primary);
}

.option strong,
.option span {
  color: inherit;
}

.option.correct {
  border-color: #86efac;
  background: #f0fdf4;
}

.option.wrong {
  border-color: #fecaca;
  background: #fef2f2;
}

.attempt-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.attempt-sidebar {
  position: sticky;
  top: 96px;
  padding: 18px;
}

.attempt-sidebar h3 {
  margin-bottom: 14px;
  color: var(--ink);
  font-size: 1rem;
}

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

.map-button {
  height: 42px;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  font-weight: 800;
}

.map-button.active {
  outline: 2px solid rgba(23, 107, 135, 0.22);
  border-color: var(--primary);
  box-shadow: inset 0 0 0 1px var(--primary);
}

.map-button.answered {
  color: #ffffff;
  background: var(--good);
  border-color: var(--good);
}

.map-button.review {
  color: #ffffff;
  background: var(--review);
  border-color: var(--review);
}

.legend {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.9rem;
}

.legend span {
  display: flex;
  align-items: center;
  gap: 8px;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: var(--line);
}

.dot.answered {
  background: var(--good);
}

.dot.review {
  background: var(--review);
}

.exam-console {
  overflow: hidden;
  margin-bottom: 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  box-shadow: 0 7px 20px rgba(23, 52, 73, 0.07);
}

.attempt-mode .attempt-header {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin: 0;
  padding: 14px 16px;
  border: 0;
}

.exam-type {
  min-width: 122px;
  padding: 8px 10px;
  border-left: 4px solid var(--primary);
  color: var(--primary-dark);
  background: var(--surface-soft);
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-align: center;
}

.exam-title {
  min-width: 0;
  text-align: center;
}

.attempt-mode .attempt-header h1 {
  max-width: none;
  color: var(--ink);
  font-size: clamp(1.2rem, 2vw, 1.65rem);
  line-height: 1.25;
  font-weight: 800;
}

.attempt-mode .attempt-header .test-meta {
  justify-content: center;
  margin-top: 4px;
  font-size: 0.78rem;
}

.attempt-mode .attempt-header .test-meta span + span::before {
  content: "|";
  margin-right: 8px;
  color: #a4b1b9;
}

.exam-header-actions {
  display: flex;
  align-items: end;
  gap: 10px;
}

.exam-time-panel {
  min-width: 128px;
  display: grid;
  gap: 4px;
  justify-items: center;
}

.exam-time-panel > span {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.08em;
}

.attempt-mode .timer {
  min-width: 108px;
  min-height: 40px;
  padding: 8px 14px;
  border-radius: 4px;
  background: var(--primary-dark);
  box-shadow: none;
}

.header-submit {
  min-height: 40px;
  white-space: nowrap;
}

.exam-command-bar {
  min-height: 48px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 8px 14px;
  border-top: 1px solid var(--line);
  background: #f8fafb;
}

.section-tabs {
  display: flex;
  gap: 6px;
}

.section-tab {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--muted);
  background: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
}

.section-tab.active {
  color: #ffffff;
  border-color: var(--primary);
  background: var(--primary);
}

.exam-counts {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.exam-counts span {
  display: inline-flex;
  gap: 5px;
  align-items: center;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--muted);
  background: #ffffff;
  font-size: 0.76rem;
}

.exam-counts strong {
  color: var(--ink);
  font-size: 0.85rem;
}

.attempt-mode .attempt-shell {
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 14px;
}

.attempt-mode .question-card {
  min-height: 500px;
  overflow: hidden;
  padding: 0;
  border-top: 1px solid var(--line);
  border-radius: 6px;
  box-shadow: 0 7px 20px rgba(23, 52, 73, 0.06);
}

.question-toolbar {
  min-height: 48px;
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: center;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line);
  background: #f7f9fb;
}

.question-number {
  color: var(--primary-dark);
  font-weight: 850;
}

.question-type {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.8rem;
}

.question-content {
  padding: 18px 20px 22px;
}

.attempt-mode .question-card h2 {
  color: var(--ink);
  font-size: 1.1rem;
  line-height: 1.5;
  margin: 0 0 18px;
  font-weight: 700;
}

.attempt-mode .option {
  min-height: 48px;
  padding: 12px 14px;
  border-radius: 4px;
}

.attempt-mode .attempt-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 14px 16px;
  border-top: 1px solid var(--line);
  background: #f8fafb;
}

.attempt-mode .attempt-controls button {
  min-height: 40px;
}

.attempt-mode .attempt-controls .previous-action {
  justify-self: start;
}

.attempt-mode .attempt-controls .review-action {
  justify-self: center;
}

.attempt-mode .attempt-controls .next-action {
  justify-self: end;
}

.attempt-mode .attempt-sidebar {
  position: sticky;
  top: 96px;
  overflow: hidden;
  padding: 0;
  border-radius: 6px;
  box-shadow: 0 7px 20px rgba(23, 52, 73, 0.06);
}

.palette-header {
  min-height: 68px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 12px 14px;
  color: #ffffff;
  background: var(--night);
}

.palette-header span {
  color: #bfd0da;
  font-size: 0.66rem;
  font-weight: 850;
  letter-spacing: 0.07em;
}

.attempt-mode .attempt-sidebar .palette-header h3 {
  margin: 3px 0 0;
  color: #ffffff;
  font-size: 0.92rem;
}

.palette-header > strong {
  min-width: 48px;
  padding: 7px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 4px;
  text-align: center;
  font-size: 0.85rem;
}

.attempt-mode .question-map {
  gap: 9px;
  padding: 16px 14px;
}

.attempt-mode .map-button {
  height: 36px;
  border-radius: 4px;
}

.attempt-mode .map-button.active {
  outline: 2px solid rgba(23, 107, 135, 0.26);
  outline-offset: 1px;
}

.palette-analysis {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
}

.palette-analysis span {
  display: grid;
  gap: 3px;
  padding: 11px 14px;
  color: var(--muted);
  font-size: 0.76rem;
}

.palette-analysis span + span {
  border-left: 1px solid var(--line);
}

.palette-analysis strong {
  color: var(--ink);
  font-size: 1.05rem;
}

.attempt-mode .legend {
  margin: 0;
  padding: 13px 14px 16px;
  border-top: 1px solid var(--line);
  background: #f8fafb;
  font-size: 0.82rem;
}

.score-panel {
  display: grid;
  gap: 14px;
}

.score-value {
  font-size: clamp(2.5rem, 8vw, 4.2rem);
  font-weight: 900;
  line-height: 1;
  color: var(--primary);
}

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

.result-box {
  min-height: 96px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.result-box:nth-child(1) {
  border-top: 4px solid var(--primary);
}

.result-box:nth-child(2) {
  border-top: 4px solid var(--good);
}

.result-box:nth-child(3) {
  border-top: 4px solid var(--bad);
}

.result-box:nth-child(4) {
  border-top: 4px solid var(--gold);
}

.result-box strong {
  font-size: 1.8rem;
}

.result-box span {
  color: var(--muted);
}

.solution-list {
  display: grid;
  gap: 14px;
}

.explanation {
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.6;
  border-left: 4px solid var(--primary);
  padding-left: 12px;
}

.content-page {
  max-width: 820px;
}

.content-page .card {
  line-height: 1.72;
  color: var(--muted);
}

.content-page h2 {
  color: var(--ink);
  margin-top: 0;
}

.content-page ul {
  padding-left: 20px;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(12, 35, 33, 0.58);
}

.submit-modal {
  width: min(100%, 430px);
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 24px 70px rgba(12, 35, 33, 0.24);
  padding: 20px;
  border-top: 5px solid var(--gold);
}

.submit-modal h2 {
  margin: 0 0 10px;
  font-size: 1.35rem;
}

.submit-modal p {
  color: var(--muted);
  line-height: 1.55;
}

@media (max-width: 900px) {
  .hero,
  .layout-two,
  .attempt-shell {
    grid-template-columns: 1fr;
  }

  .attempt-mode .attempt-shell {
    grid-template-columns: 1fr;
  }

  .hero-copy,
  .hero-panel {
    min-height: auto;
  }

  .grid.categories,
  .grid.tests,
  .practice-tools,
  .progress-layout,
  .result-grid,
  .home-new-tests {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .attempt-sidebar {
    order: -1;
    position: static;
  }

  .attempt-mode .attempt-sidebar {
    order: initial;
    position: static;
  }
}

@media (max-width: 720px) {
  .topbar {
    flex-wrap: wrap;
  }

  .icon-button {
    display: inline-flex;
  }

  .main-nav {
    display: none;
    width: 100%;
    margin-left: 0;
    flex-direction: column;
    align-items: stretch;
  }

  .main-nav.open {
    display: flex;
  }

  .main-nav a {
    padding: 12px;
  }

  .site-footer {
    flex-direction: column;
  }

  .grid.categories,
  .grid.tests,
  .practice-tools,
  .metric-grid,
  .result-grid,
  .home-overview-grid,
  .home-new-tests {
    grid-template-columns: 1fr;
  }

  .home-resume-card {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .home-resume-card .primary-button {
    grid-column: 1 / -1;
    width: 100%;
  }

  main {
    width: min(100% - 24px, 1180px);
    padding-top: 18px;
  }

  main.attempt-mode {
    width: calc(100% - 16px);
    padding-top: 10px;
  }

  h1 {
    font-size: clamp(2rem, 13vw, 3.2rem);
  }

  .section-head,
  .attempt-header {
    align-items: stretch;
    flex-direction: column;
  }

  .timer {
    width: 100%;
  }

  .attempt-mode .attempt-header {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 12px;
  }

  .attempt-mode .exam-type {
    display: none;
  }

  .attempt-mode .exam-title {
    text-align: left;
  }

  .attempt-mode .attempt-header .test-meta {
    justify-content: flex-start;
  }

  .attempt-mode .exam-time-panel {
    min-width: 96px;
  }

  .exam-header-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .attempt-mode .timer {
    width: auto;
    min-width: 96px;
  }

  .exam-command-bar {
    align-items: stretch;
    flex-direction: column;
    gap: 8px;
  }

  .exam-counts {
    justify-content: flex-start;
  }

  .question-type {
    width: 100%;
    margin-left: 0;
  }

  .attempt-mode .attempt-controls {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
  }

  .attempt-mode .attempt-controls button {
    width: 100%;
    min-width: 0;
    padding-inline: 6px;
    font-size: 0.78rem;
    white-space: normal;
  }

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

  .practice-menu-item:nth-child(3) {
    border: 1px solid var(--line);
  }

  .practice-menu-item:nth-child(4) {
    border: 1px solid var(--line);
  }

  .accuracy-row {
    grid-template-columns: 1fr 48px;
  }

  .accuracy-track {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}

/* ================================================================
   MYMOCK LIQUID GLASS SYSTEM
   Balanced by default, enhanced on large desktops, reduced on mobile.
   ================================================================ */
:root {
  color-scheme: dark;
  --bg: #060a1c;
  --surface: rgba(17, 25, 58, 0.72);
  --surface-soft: rgba(112, 142, 255, 0.12);
  --surface-solid: #121a3a;
  --ink: #f7f9ff;
  --muted: #aab6d4;
  --line: rgba(180, 198, 255, 0.18);
  --line-strong: rgba(198, 212, 255, 0.32);
  --primary: #7b8cff;
  --primary-dark: #5e72f2;
  --accent: #4edcff;
  --gold: #ffc86b;
  --good: #45d9a0;
  --bad: #ff6b88;
  --review: #a98cff;
  --warn: #f8b84f;
  --night: #080f2c;
  --glass-blur: 18px;
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --shadow: 0 28px 80px rgba(0, 4, 24, 0.34);
  --shadow-soft: 0 14px 40px rgba(0, 4, 24, 0.22);
  --ease-premium: cubic-bezier(0.2, 0.75, 0.25, 1);
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #eff4ff;
  --surface: rgba(255, 255, 255, 0.72);
  --surface-soft: rgba(77, 104, 220, 0.08);
  --surface-solid: #f8faff;
  --ink: #121a38;
  --muted: #5d6884;
  --line: rgba(62, 81, 145, 0.14);
  --line-strong: rgba(62, 81, 145, 0.25);
  --primary: #4d63e8;
  --primary-dark: #354bc9;
  --accent: #058db8;
  --gold: #b87506;
  --good: #16855c;
  --bad: #c73455;
  --review: #7458d5;
  --warn: #9c650f;
  --night: #111c45;
  --shadow: 0 28px 80px rgba(42, 55, 111, 0.16);
  --shadow-soft: 0 14px 40px rgba(42, 55, 111, 0.12);
}

html {
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 14% 8%, rgba(72, 107, 255, 0.24), transparent 31rem),
    radial-gradient(circle at 86% 22%, rgba(65, 220, 255, 0.15), transparent 28rem),
    radial-gradient(circle at 58% 86%, rgba(139, 93, 255, 0.16), transparent 34rem),
    linear-gradient(145deg, var(--bg), color-mix(in srgb, var(--bg) 86%, #17275d));
  background-attachment: fixed;
}

body::before,
body::after {
  content: "";
  position: fixed;
  z-index: 0;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 48% 52% 62% 38% / 43% 44% 56% 57%;
  pointer-events: none;
  filter: blur(1px);
  box-shadow: inset 16px 18px 36px rgba(255, 255, 255, 0.05), 0 24px 80px rgba(0, 5, 28, 0.18);
}

body::before {
  top: 17%;
  right: -7rem;
  width: 20rem;
  height: 20rem;
  background: linear-gradient(135deg, rgba(119, 148, 255, 0.12), rgba(69, 225, 255, 0.025));
  transform: rotate(18deg);
}

body::after {
  bottom: 8%;
  left: -5rem;
  width: 13rem;
  height: 13rem;
  background: linear-gradient(145deg, rgba(179, 120, 255, 0.1), rgba(255, 255, 255, 0.015));
  transform: rotate(-24deg);
}

#app-shell {
  position: relative;
  z-index: 1;
}

::selection {
  color: #fff;
  background: rgba(94, 114, 242, 0.78);
}

.skip-link,
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.skip-link:focus {
  z-index: 100;
  top: 10px;
  left: 10px;
  width: auto;
  height: auto;
  clip: auto;
  padding: 10px 14px;
  border-radius: 10px;
  color: #fff;
  background: var(--primary-dark);
}

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 72%, white);
  outline-offset: 3px;
}

.topbar {
  top: 10px;
  width: min(1380px, calc(100% - 24px));
  margin: 0 auto;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  color: var(--ink);
  background: linear-gradient(110deg, rgba(255, 255, 255, 0.1), transparent 42%), color-mix(in srgb, var(--surface) 90%, transparent);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
  backdrop-filter: blur(24px) saturate(150%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 18px 52px rgba(0, 5, 30, 0.24);
}

.brand-logo {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  border-color: rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.26), 0 10px 24px rgba(4, 8, 30, 0.2);
}

.brand strong,
.brand small {
  color: var(--ink);
}

.brand strong {
  letter-spacing: 0.04em;
}

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

.main-nav {
  gap: 3px;
  padding: 4px;
  border-color: var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.045);
}

.main-nav a {
  padding: 9px 10px;
  border-radius: 10px;
  color: var(--muted);
  font-size: 0.86rem;
}

.main-nav a:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.main-nav a.active {
  color: #fff;
  border-color: rgba(188, 205, 255, 0.34);
  background: linear-gradient(135deg, rgba(123, 140, 255, 0.92), rgba(81, 98, 221, 0.86));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.34), 0 8px 24px rgba(70, 83, 205, 0.32);
}

.main-nav a.active::after {
  display: none;
}

.theme-toggle,
.icon-button {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.07);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14);
  cursor: pointer;
}

.theme-toggle {
  display: grid;
  place-items: center;
  font-size: 1.2rem;
}

.theme-toggle:hover,
.icon-button:hover {
  border-color: color-mix(in srgb, var(--primary) 72%, white);
  background: var(--surface-soft);
}

.icon-button span {
  background: var(--ink);
}

main {
  width: min(1240px, calc(100% - 36px));
  padding: 52px 0 70px;
}

.notice {
  margin-bottom: 18px;
  border: 1px solid color-mix(in srgb, var(--gold) 48%, transparent);
  border-left: 4px solid var(--gold);
  border-radius: var(--radius-sm);
  color: color-mix(in srgb, var(--gold) 74%, var(--ink));
  background: color-mix(in srgb, var(--gold) 10%, var(--surface));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.liquid-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(340px, 0.75fr);
  gap: clamp(28px, 5vw, 76px);
  min-height: 520px;
  align-items: center;
  padding: clamp(34px, 6vw, 74px);
  border: 1px solid var(--line-strong);
  border-radius: 34px;
  background:
    linear-gradient(125deg, rgba(255, 255, 255, 0.11), transparent 30%),
    radial-gradient(circle at 80% 20%, rgba(67, 221, 255, 0.14), transparent 28%),
    linear-gradient(135deg, color-mix(in srgb, var(--surface) 96%, #2742a2), color-mix(in srgb, var(--surface) 92%, #331c74));
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(145%);
  backdrop-filter: blur(var(--glass-blur)) saturate(145%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.24), inset 0 -1px 0 rgba(255, 255, 255, 0.06), var(--shadow);
}

.liquid-hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  right: -10%;
  bottom: -45%;
  width: 58%;
  aspect-ratio: 1;
  border-radius: 46% 54% 64% 36% / 52% 38% 62% 48%;
  background: linear-gradient(145deg, rgba(123, 140, 255, 0.32), rgba(70, 220, 255, 0.04));
  filter: blur(8px);
  box-shadow: inset 24px 18px 42px rgba(255, 255, 255, 0.08);
}

.hero-copy {
  min-height: auto;
}

.eyebrow {
  margin-bottom: 14px;
  padding: 7px 11px;
  border: 1px solid color-mix(in srgb, var(--accent) 42%, transparent);
  border-radius: 999px;
  color: color-mix(in srgb, var(--accent) 82%, var(--ink));
  background: color-mix(in srgb, var(--accent) 9%, transparent);
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.1em;
}

.liquid-hero h1 {
  max-width: 750px;
  font-size: clamp(2.8rem, 6vw, 5.35rem);
  line-height: 0.98;
  letter-spacing: -0.055em;
}

.liquid-hero h1 span {
  color: transparent;
  background: linear-gradient(100deg, #fff 8%, #8fe9ff 44%, #a7b2ff 78%);
  -webkit-background-clip: text;
  background-clip: text;
}

:root[data-theme="light"] .liquid-hero h1 span {
  background-image: linear-gradient(100deg, #354bc9, #0485ad 55%, #684bd2);
}

.liquid-hero .hero-copy > p {
  max-width: 650px;
  margin: 24px 0 28px;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.18rem);
  line-height: 1.75;
}

.hero-trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 26px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
}

.hero-trust-row span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.hero-trust-row i,
.connection-indicator i,
.readiness-badge i,
.live-indicator i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--good);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--good) 15%, transparent), 0 0 14px color-mix(in srgb, var(--good) 64%, transparent);
}

.hero-insight {
  position: relative;
  overflow: hidden;
  min-height: 390px;
  display: grid;
  align-content: space-between;
  padding: 24px;
  border: 1px solid rgba(220, 230, 255, 0.25);
  border-radius: 26px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.045));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), inset 14px 0 36px rgba(255, 255, 255, 0.025), 0 24px 60px rgba(2, 6, 30, 0.25);
}

.hero-insight-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.09em;
}

.hero-insight-head b {
  color: var(--good);
  letter-spacing: 0;
}

.hero-score-orb {
  position: relative;
  z-index: 1;
  width: 178px;
  height: 178px;
  display: grid;
  place-content: center;
  justify-items: center;
  justify-self: center;
  border: 1px solid rgba(220, 231, 255, 0.28);
  border-radius: 50% 48% 52% 46%;
  background: radial-gradient(circle at 32% 24%, rgba(255, 255, 255, 0.24), transparent 32%), linear-gradient(145deg, rgba(109, 132, 255, 0.3), rgba(49, 201, 255, 0.08));
  box-shadow: inset 12px 14px 30px rgba(255, 255, 255, 0.08), 0 24px 60px rgba(7, 9, 38, 0.3);
}

.hero-score-orb strong {
  font-size: 2.6rem;
  font-variant-numeric: tabular-nums;
}

.hero-score-orb span {
  color: var(--muted);
  font-size: 0.72rem;
}

.hero-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.hero-metric-grid div {
  display: grid;
  gap: 3px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.055);
}

.hero-metric-grid strong {
  font-size: 1.1rem;
  font-variant-numeric: tabular-nums;
}

.hero-metric-grid span {
  color: var(--muted);
  font-size: 0.7rem;
}

.hero-ambient i {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.045);
  box-shadow: inset 4px 4px 10px rgba(255, 255, 255, 0.08);
}

.hero-ambient i:nth-child(1) { top: 22%; right: 9%; width: 38px; height: 38px; }
.hero-ambient i:nth-child(2) { bottom: 30%; left: 8%; width: 20px; height: 20px; }
.hero-ambient i:nth-child(3) { top: 43%; left: 15%; width: 11px; height: 11px; }

.primary-button,
.secondary-button,
.ghost-button,
.danger-button {
  min-height: 46px;
  padding: 11px 17px;
  border-radius: 12px;
  font-weight: 800;
  transition: transform 180ms var(--ease-premium), box-shadow 180ms var(--ease-premium), border-color 180ms ease, background 180ms ease;
}

.primary-button {
  color: #fff;
  border-color: rgba(200, 211, 255, 0.28);
  background: linear-gradient(135deg, #7c8eff, #5266e6 60%, #4357d6);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.32), 0 12px 28px rgba(69, 84, 210, 0.32);
}

.primary-button:hover {
  background: linear-gradient(135deg, #8798ff, #5c70ed 60%, #4d60dc);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.36), 0 16px 34px rgba(69, 84, 210, 0.4);
  transform: translateY(-2px);
}

.ghost-button,
.secondary-button {
  color: var(--ink);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.ghost-button:hover,
.secondary-button:hover {
  border-color: color-mix(in srgb, var(--primary) 68%, white);
  background: var(--surface-soft);
  box-shadow: 0 10px 24px rgba(5, 8, 34, 0.15);
}

.danger-button {
  color: #fff;
  background: linear-gradient(135deg, #f45d80, #c9335a);
  box-shadow: 0 10px 24px rgba(201, 51, 90, 0.26);
}

.primary-button.disabled,
.primary-button[aria-disabled="true"] {
  opacity: 0.45;
  cursor: not-allowed;
  filter: saturate(0.4);
  transform: none;
}

.online-practice {
  padding: 54px 0 22px;
}

.online-practice-title h1,
.online-practice-title h2,
.section-head h2,
.page-title h1 {
  color: var(--ink);
  letter-spacing: -0.035em;
}

.brain-mark {
  border-radius: 8px 12px 8px 12px;
  background: linear-gradient(145deg, var(--accent), var(--primary));
  box-shadow: 0 8px 22px color-mix(in srgb, var(--primary) 32%, transparent);
}

.practice-menu {
  min-height: auto;
}

.practice-menu-item,
.home-resume-card,
.home-recent-list,
.home-new-test,
.home-empty-state,
.card,
.result-box,
.notice,
.empty-state,
.loading-state,
.test-filter-bar,
.exam-console {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  color: var(--ink);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.085), transparent 44%), var(--surface);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(135%);
  backdrop-filter: blur(var(--glass-blur)) saturate(135%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16), inset 0 -1px 0 rgba(255, 255, 255, 0.035), var(--shadow-soft);
}

.practice-menu-item {
  min-height: 178px;
  border-radius: 20px;
}

.practice-menu-item::before {
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  box-shadow: 0 0 18px color-mix(in srgb, var(--accent) 35%, transparent);
}

.practice-menu-item:nth-child(2)::before,
.practice-menu-item:nth-child(3)::before,
.practice-menu-item:nth-child(4)::before {
  background: linear-gradient(90deg, var(--primary), var(--accent));
}

.menu-visual,
.all-test-visual,
.gift-visual,
.saved-test-visual,
.quiz-visual {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-soft);
}

.gift-visual { color: var(--accent); }
.saved-test-visual { color: var(--gold); }
.quiz-visual i { background: linear-gradient(135deg, var(--review), var(--primary)); }

.home-overview-grid {
  gap: 22px;
}

.home-section {
  padding-top: 18px;
}

.home-resume-card {
  border-left: 1px solid var(--line);
}

.home-card-icon,
.category-icon,
.tool-icon {
  border-radius: 13px;
  background: linear-gradient(145deg, var(--accent), var(--primary));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 10px 24px color-mix(in srgb, var(--primary) 28%, transparent);
}

.home-recent-row,
.history-row {
  border-color: var(--line);
}

.home-recent-row:hover {
  background: var(--surface-soft);
}

.recent-score,
.pill,
.eyebrow {
  border: 1px solid var(--line);
}

.recent-score,
.pill {
  color: color-mix(in srgb, var(--primary) 58%, var(--ink));
  background: var(--surface-soft);
}

.pill.free {
  color: var(--good);
  border-color: color-mix(in srgb, var(--good) 26%, transparent);
  background: color-mix(in srgb, var(--good) 11%, transparent);
}

.pill.review {
  color: color-mix(in srgb, var(--review) 78%, white);
  background: color-mix(in srgb, var(--review) 12%, transparent);
}

.page-title {
  margin: 8px 0 24px;
}

.page-title .eyebrow {
  display: inline-flex;
}

.page-title h1 {
  font-size: clamp(2.35rem, 5vw, 4.4rem);
}

.page-title p,
.section-head p,
.card p,
.home-card-copy p,
.home-new-test p {
  color: var(--muted);
}

.card {
  padding: 20px;
}

.category-card,
.test-card {
  min-height: 205px;
  border-radius: 20px;
}

.category-card:hover,
.test-card:hover,
.practice-menu-item:hover,
.home-new-test:hover {
  border-color: color-mix(in srgb, var(--primary) 58%, transparent);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 24px 60px rgba(2, 6, 30, 0.3);
}

.test-filter-bar {
  position: sticky;
  z-index: 5;
  top: 88px;
  display: grid;
  grid-template-columns: minmax(230px, 1fr) repeat(3, minmax(150px, auto)) auto;
  gap: 9px;
  padding: 12px;
  margin-bottom: 12px;
}

.test-filter-bar label {
  min-width: 0;
}

.test-filter-bar input,
.test-filter-bar select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 10px 12px;
  color: var(--ink);
  background: color-mix(in srgb, var(--surface-solid) 74%, transparent);
  outline: none;
}

.test-filter-bar input:focus,
.test-filter-bar select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent);
}

.filter-search {
  position: relative;
}

.filter-search input {
  padding-right: 38px;
}

.filter-search > i {
  position: absolute;
  top: 50%;
  right: 14px;
  color: var(--muted);
  font-size: 1.2rem;
  font-style: normal;
  transform: translateY(-50%);
}

.view-switcher {
  display: flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
}

.view-switcher button,
.solution-filters button,
.filter-summary button,
.palette-toggle {
  border: 1px solid transparent;
  border-radius: 9px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}

.view-switcher button {
  width: 36px;
  font-size: 1.05rem;
}

.view-switcher button.active,
.solution-filters button.active {
  color: #fff;
  border-color: rgba(207, 217, 255, 0.24);
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: 0 7px 18px color-mix(in srgb, var(--primary) 28%, transparent);
}

.filter-summary {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 0 2px 16px;
  color: var(--muted);
  font-size: 0.85rem;
}

.filter-summary strong {
  color: var(--ink);
}

.filter-summary button {
  color: var(--accent);
  font-weight: 800;
}

.grid.tests.list-view {
  grid-template-columns: 1fr;
}

.grid.tests.list-view .test-card {
  min-height: auto;
  grid-template-columns: minmax(180px, 0.7fr) minmax(260px, 1.6fr) auto auto;
  align-items: center;
}

.readiness-badge,
.connection-indicator {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border: 1px solid color-mix(in srgb, var(--good) 25%, transparent);
  border-radius: 999px;
  color: var(--good);
  background: color-mix(in srgb, var(--good) 10%, transparent);
  font-size: 0.72rem;
  font-weight: 800;
}

.instruction-facts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin: 18px 0;
}

.instruction-facts span {
  display: grid;
  gap: 3px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.7rem;
}

.instruction-facts strong {
  color: var(--ink);
  font-size: 1rem;
}

.agreement-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--muted);
  background: var(--surface-soft);
  font-size: 0.82rem;
  line-height: 1.45;
}

.agreement-row input {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  accent-color: var(--primary);
}

.instruction-list li {
  padding: 3px 0;
}

main.attempt-mode {
  width: min(1500px, calc(100% - 24px));
}

main.attempt-mode::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: color-mix(in srgb, var(--bg) 94%, #10183a);
}

.exam-console,
.attempt-mode .question-card,
.attempt-mode .attempt-sidebar {
  border-radius: 16px;
  background: color-mix(in srgb, var(--surface-solid) 94%, transparent);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.attempt-mode .attempt-header,
.exam-command-bar,
.question-toolbar,
.attempt-mode .attempt-controls,
.attempt-mode .legend {
  border-color: var(--line);
  background: color-mix(in srgb, var(--surface-solid) 94%, transparent);
}

.exam-type {
  border-left-color: var(--accent);
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 9%, transparent);
}

.attempt-mode .attempt-header h1,
.attempt-mode .question-card h2,
.question-number,
.palette-analysis strong {
  color: var(--ink);
}

.attempt-mode .attempt-header .test-meta,
.question-type,
.exam-time-panel > span,
.palette-analysis span,
.attempt-mode .legend {
  color: var(--muted);
}

.connection-indicator {
  padding: 6px 8px;
}

.connection-indicator.offline {
  color: var(--bad);
  border-color: color-mix(in srgb, var(--bad) 32%, transparent);
  background: color-mix(in srgb, var(--bad) 10%, transparent);
}

.connection-indicator.offline i {
  background: var(--bad);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--bad) 15%, transparent);
}

.attempt-mode .timer {
  border: 1px solid rgba(174, 196, 255, 0.25);
  border-radius: 10px;
  background: linear-gradient(135deg, #172653, #101a3d);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.timer.critical {
  border-color: color-mix(in srgb, var(--bad) 60%, transparent);
  color: #fff;
  background: linear-gradient(135deg, #a9254a, #6d1936);
  animation: timer-glow 1.8s ease-in-out infinite;
}

@keyframes timer-glow {
  50% { box-shadow: 0 0 0 5px color-mix(in srgb, var(--bad) 11%, transparent), 0 0 26px color-mix(in srgb, var(--bad) 24%, transparent); }
}

.fullscreen-action {
  min-width: 42px;
  padding: 8px;
}

.exam-counts span,
.section-tab {
  border-color: var(--line);
  border-radius: 9px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.045);
}

.section-tab.active {
  color: #fff;
  border-color: var(--primary);
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
}

.autosave-status i {
  color: var(--good);
  font-style: normal;
}

.palette-toggle {
  display: none;
  padding: 6px 9px;
  border-color: var(--line);
}

.attempt-mode .option {
  border-color: var(--line);
  border-radius: 11px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.035);
}

.attempt-mode .option:hover {
  border-color: var(--line-strong);
  background: var(--surface-soft);
}

.attempt-mode .option.selected {
  border-color: var(--primary);
  background: color-mix(in srgb, var(--primary) 12%, transparent);
  box-shadow: inset 4px 0 0 var(--primary), 0 8px 24px rgba(4, 7, 30, 0.15);
}

.question-secondary-actions {
  display: flex;
  gap: 8px;
}

.palette-header {
  background: linear-gradient(135deg, #111d47, #0a1233);
}

.attempt-mode .map-button {
  border-color: var(--line);
  border-radius: 9px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.045);
}

.attempt-mode .map-button.answered {
  color: #071c18;
  border-color: var(--good);
  background: var(--good);
}

.attempt-mode .map-button.review {
  color: #fff;
  border-color: var(--review);
  background: var(--review);
}

.result-hero-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: clamp(24px, 5vw, 60px);
  align-items: center;
  padding: clamp(26px, 5vw, 52px);
}

.result-score-ring {
  width: clamp(190px, 23vw, 260px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--accent) var(--score-progress), rgba(255, 255, 255, 0.08) 0);
  box-shadow: 0 24px 70px rgba(2, 6, 30, 0.28), 0 0 50px color-mix(in srgb, var(--accent) 12%, transparent);
}

.result-score-ring::before {
  content: "";
  position: absolute;
}

.result-score-ring > div {
  width: calc(100% - 18px);
  height: calc(100% - 18px);
  display: grid;
  place-content: center;
  justify-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface-solid);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.result-score-ring strong {
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1;
}

.result-score-ring span {
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.8rem;
}

.result-hero-copy h2 {
  max-width: 680px;
  margin: 18px 0 12px;
  font-size: clamp(1.7rem, 4vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.result-hero-copy .button-row {
  margin-top: 24px;
}

.result-box {
  border-top-width: 1px !important;
}

.result-box strong {
  font-variant-numeric: tabular-nums;
}

.solution-toolbar {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  margin-bottom: 18px;
}

.solution-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--surface);
}

.solution-filters button {
  min-height: 36px;
  padding: 7px 11px;
  font-weight: 750;
}

.option.correct {
  color: var(--ink);
  border-color: color-mix(in srgb, var(--good) 50%, transparent);
  background: color-mix(in srgb, var(--good) 11%, var(--surface-solid));
}

.option.wrong {
  color: var(--ink);
  border-color: color-mix(in srgb, var(--bad) 50%, transparent);
  background: color-mix(in srgb, var(--bad) 11%, var(--surface-solid));
}

.explanation {
  border-left-color: var(--accent);
  color: var(--muted);
}

.accuracy-track {
  background: rgba(255, 255, 255, 0.08);
}

.accuracy-track i {
  background: linear-gradient(90deg, var(--primary), var(--accent));
}

.submit-modal {
  border: 1px solid var(--line-strong);
  border-top: 3px solid var(--gold);
  border-radius: 20px;
  color: var(--ink);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), transparent 40%), var(--surface-solid);
  box-shadow: var(--shadow);
}

.modal-backdrop {
  background: rgba(2, 5, 20, 0.72);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.site-footer {
  align-items: center;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: rgba(5, 9, 27, 0.78);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.site-footer > div {
  display: grid;
  gap: 3px;
  color: var(--ink);
}

.site-footer > div span {
  color: var(--muted);
  font-size: 0.74rem;
}

.site-footer nav {
  display: flex;
  gap: 12px;
}

.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--accent);
}

.app-toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 120;
  max-width: min(380px, calc(100% - 40px));
  padding: 13px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  color: var(--ink);
  background: color-mix(in srgb, var(--surface-solid) 94%, transparent);
  box-shadow: var(--shadow-soft);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.app-toast.visible {
  opacity: 1;
  transform: translateY(0);
}

.customize-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.75fr);
  gap: 20px;
  align-items: start;
}

.custom-builder-card,
.custom-preview-card {
  padding: clamp(20px, 3vw, 30px);
}

.custom-preview-card {
  position: sticky;
  top: 102px;
}

.custom-card-heading {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 24px;
}

.custom-card-heading h2,
.custom-card-heading p {
  margin: 0;
}

.custom-card-heading p {
  margin-top: 5px;
  line-height: 1.55;
}

.custom-step {
  display: grid;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--primary) 42%, var(--line));
  border-radius: 13px;
  color: var(--accent);
  background: color-mix(in srgb, var(--primary) 12%, var(--surface));
  font-size: 0.78rem;
  font-weight: 850;
}

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

.custom-field {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.custom-field > span {
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 800;
}

.custom-field input,
.custom-field select {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  outline: none;
  color: var(--ink);
  background: color-mix(in srgb, var(--surface-solid) 80%, transparent);
}

.custom-field input:focus,
.custom-field select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent);
}

.custom-field select:disabled {
  opacity: 0.58;
}

.custom-field small,
.custom-switch small {
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.4;
}

.custom-switch {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: color-mix(in srgb, var(--surface-soft) 76%, transparent);
  cursor: pointer;
}

.custom-switch input {
  width: 19px;
  height: 19px;
  accent-color: var(--primary);
}

.custom-switch span {
  display: grid;
  gap: 3px;
}

.custom-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.custom-form-actions .primary-button {
  min-width: 190px;
}

.custom-preview-orb {
  width: 152px;
  height: 152px;
  display: grid;
  place-content: center;
  margin: 10px auto 24px;
  border: 1px solid color-mix(in srgb, var(--accent) 46%, var(--line));
  border-radius: 50%;
  text-align: center;
  background:
    radial-gradient(circle at 34% 26%, rgba(255, 255, 255, 0.18), transparent 30%),
    color-mix(in srgb, var(--primary) 14%, var(--surface));
  box-shadow: inset 0 0 0 9px color-mix(in srgb, var(--primary) 8%, transparent), 0 18px 45px color-mix(in srgb, var(--primary) 18%, transparent);
}

.custom-preview-orb strong {
  color: var(--ink);
  font-size: 2.7rem;
  line-height: 1;
}

.custom-preview-orb span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.09em;
}

.custom-summary {
  display: grid;
  gap: 0;
  margin: 0;
}

.custom-summary div {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.custom-summary dt {
  color: var(--muted);
}

.custom-summary dd {
  margin: 0;
  color: var(--ink);
  text-align: right;
  font-weight: 800;
}

.custom-ready-note,
.custom-empty-note {
  margin: 18px 0 0;
  padding: 12px 13px;
  border: 1px solid color-mix(in srgb, var(--good) 32%, var(--line));
  border-radius: 12px;
  color: var(--good) !important;
  background: color-mix(in srgb, var(--good) 9%, transparent);
  font-size: 0.82rem;
  font-weight: 750;
}

.custom-ready-note i {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--good);
  box-shadow: 0 0 12px color-mix(in srgb, var(--good) 70%, transparent);
}

.custom-empty-note {
  border-color: color-mix(in srgb, var(--warn) 34%, var(--line));
  color: var(--warn) !important;
  background: color-mix(in srgb, var(--warn) 9%, transparent);
}

.custom-preset-section,
.custom-generated-section {
  padding-top: 38px;
}

.custom-preset-editor {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.custom-preset-editor button {
  min-height: 48px;
}

.custom-preset-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.custom-preset-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.custom-preset-item > div:first-child {
  display: grid;
  gap: 5px;
}

.custom-preset-item span {
  color: var(--muted);
  font-size: 0.8rem;
}

.custom-delete-button {
  color: var(--bad);
}

:root[data-theme="light"] body {
  background:
    radial-gradient(circle at 14% 8%, rgba(72, 107, 255, 0.18), transparent 31rem),
    radial-gradient(circle at 86% 22%, rgba(65, 220, 255, 0.14), transparent 28rem),
    linear-gradient(145deg, #f8fbff, #e8efff);
}

:root[data-theme="light"] .liquid-hero,
:root[data-theme="light"] .practice-menu-item,
:root[data-theme="light"] .home-resume-card,
:root[data-theme="light"] .home-recent-list,
:root[data-theme="light"] .home-new-test,
:root[data-theme="light"] .card,
:root[data-theme="light"] .result-box,
:root[data-theme="light"] .test-filter-bar {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 18px 50px rgba(61, 76, 140, 0.13);
}

:root[data-theme="light"] .site-footer {
  background: rgba(236, 242, 255, 0.86);
}

@media (hover: hover) and (min-width: 1100px) {
  .practice-menu-item:hover,
  .home-new-test:hover,
  .category-card:hover,
  .test-card:hover {
    transform: translateY(-5px);
  }
}

@media (min-width: 1400px) {
  :root { --glass-blur: 22px; }
  .hero-insight { transform: perspective(1000px) rotateY(-2deg) rotateX(1deg); }
}

@media (max-width: 1040px) {
  .topbar { width: calc(100% - 18px); }
  .brand small { display: none; }
  .main-nav a { padding-inline: 8px; font-size: 0.8rem; }
  .liquid-hero { grid-template-columns: 1fr; }
  .hero-insight { min-height: 340px; }
  .test-filter-bar { grid-template-columns: minmax(200px, 1fr) repeat(2, minmax(145px, auto)) auto; }
  .test-filter-bar > label:nth-child(4) { grid-column: 1 / 2; }
  .grid.tests.list-view .test-card { grid-template-columns: 1fr 1.5fr auto; }
  .grid.tests.list-view .test-card > .pill { display: none; }
}

@media (max-width: 900px) {
  .customize-layout { grid-template-columns: 1fr; }
  .custom-preview-card { position: static; }
  .attempt-mode .attempt-sidebar { display: none; }
  .attempt-mode .attempt-sidebar.open { display: block; }
  .palette-toggle { display: inline-flex; align-items: center; }
  .result-hero-card { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .result-hero-copy .result-meta,
  .result-hero-copy .button-row { justify-content: center; }
  .solution-toolbar { align-items: stretch; flex-direction: column; }
}

@media (max-width: 720px) {
  :root { --glass-blur: 10px; }
  body::before,
  body::after { display: none; }
  .topbar { top: 6px; padding: 8px; border-radius: 15px; }
  .brand { flex: 1 1 auto; }
  .icon-button { order: 2; margin-left: 0; }
  .theme-toggle { order: 3; }
  .main-nav { order: 4; border-radius: 12px; background: color-mix(in srgb, var(--surface-solid) 92%, transparent); }
  .main-nav a { padding: 11px 12px; }
  main { width: min(100% - 20px, 1240px); padding-top: 34px; }
  .liquid-hero { min-height: auto; padding: 30px 20px; border-radius: 24px; }
  .liquid-hero h1 { font-size: clamp(2.55rem, 13vw, 4rem); }
  .hero-insight { min-height: 320px; padding: 18px; }
  .hero-score-orb { width: 145px; height: 145px; }
  .hero-score-orb strong { font-size: 2.1rem; }
  .online-practice { padding-top: 38px; }
  .practice-menu-item { min-height: 150px; }
  .page-title h1 { font-size: clamp(2.1rem, 11vw, 3.1rem); }
  .test-filter-bar { position: static; grid-template-columns: 1fr; }
  .custom-form-grid,
  .custom-preset-editor { grid-template-columns: 1fr; }
  .custom-switch { grid-column: auto; }
  .custom-preset-editor button { width: 100%; }
  .test-filter-bar > label:nth-child(4) { grid-column: auto; }
  .view-switcher { justify-self: stretch; }
  .view-switcher button { flex: 1; min-height: 38px; }
  .grid.tests.list-view .test-card { grid-template-columns: 1fr; }
  .instruction-facts { grid-template-columns: repeat(2, 1fr); }
  .attempt-mode .attempt-controls { grid-template-columns: 1fr 1.35fr 1fr; }
  .question-secondary-actions { display: grid; gap: 5px; }
  .question-secondary-actions button { width: 100%; }
  .exam-header-actions { align-items: center; flex-wrap: wrap; }
  .connection-indicator { order: 3; }
  .fullscreen-action { display: none; }
  .result-grid { grid-template-columns: repeat(2, 1fr); }
  .result-score-ring { width: 190px; }
  .solution-filters { display: grid; grid-template-columns: repeat(2, 1fr); }
  .solution-toolbar .button-row > * { flex: 1; }
  .site-footer { align-items: flex-start; }
  .site-footer nav { flex-wrap: wrap; }
}

@media (max-width: 460px) {
  .brand span { display: none; }
  .practice-menu { grid-template-columns: 1fr 1fr; }
  .hero-metric-grid { gap: 5px; }
  .hero-metric-grid div { padding: 9px; }
  .hero-trust-row { gap: 10px; }
  .result-grid { grid-template-columns: 1fr 1fr; }
  .attempt-mode .attempt-controls { grid-template-columns: 0.85fr 1.4fr 0.85fr; padding-inline: 8px; }
  .custom-preset-item { align-items: stretch; flex-direction: column; }
  .custom-preset-item .button-row > * { flex: 1; }
}

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