@font-face {
  font-family: "Titillium Web";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../font/titillium-web-400.woff2") format("woff2");
}

@font-face {
  font-family: "Titillium Web";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../font/titillium-web-600.woff2") format("woff2");
}

@font-face {
  font-family: "Titillium Web";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../font/titillium-web-700.woff2") format("woff2");
}

:root {
  --ocean-deep: #14213d;
  --ocean-mid: #1c2f5c;
  --ocean-teal: #2447c6;
  --ocean-mist: #9aa6bd;

  --shell-bg: #f6f7f9;
  --shell-border: #c9cfd8;

  --sidebar-bg: #14213d;
  --sidebar-border: rgba(255, 255, 255, 0.12);
  --sidebar-text: #eef1f6;
  --sidebar-muted: #9aa6bd;
  --sidebar-active-bg: rgba(255, 255, 255, 0.1);
  --sidebar-active-border: #6f8df0;

  --bg-page: #e9ecef;
  --bg-surface: #ffffff;
  --bg-surface-solid: #ffffff;
  --bg-elevated: #ffffff;
  --bg-subtle: #eef1f4;

  --text-primary: #14213d;
  --text-secondary: #44506a;
  --text-muted: #5e6a82;

  --border-color: #d5dae1;
  --border-strong: #8a93a3;

  --brand-primary: #2447c6;
  --brand-primary-hover: #1c3aa6;
  --brand-cyan: #2447c6;
  --brand-cyan-soft: rgba(36, 71, 198, 0.12);
  --brand-soft: rgba(36, 71, 198, 0.08);
  --brand-text: #1f3dae;

  --accent-warm: #2447c6;
  --accent-warm-hover: #1c3aa6;
  --accent-warm-soft: rgba(36, 71, 198, 0.12);

  --success: #1e7b4f;
  --success-soft: rgba(30, 123, 79, 0.12);
  --danger: #c8102e;
  --danger-soft: rgba(200, 16, 46, 0.1);
  --warning: #8a5a00;
  --warning-soft: rgba(255, 225, 74, 0.38);

  --shadow-sm: 0 1px 2px rgba(20, 33, 61, 0.06);
  --shadow-md: 0 6px 18px rgba(20, 33, 61, 0.08);
  --shadow-lg: 0 18px 44px rgba(20, 33, 61, 0.14);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 14px;
  --radius-xl: 16px;

  --font-sans: "Titillium Web", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: var(--font-sans);
  --font-mono: var(--font-sans);
}

[data-theme="dark"] {
  --shell-bg: #111a2e;
  --shell-border: #2a3550;

  --sidebar-bg: #0b1222;
  --sidebar-border: #222c44;

  --bg-page: #0a0f1c;
  --bg-surface: #172038;
  --bg-surface-solid: #172038;
  --bg-elevated: #1c2743;
  --bg-subtle: #212c4a;

  --text-primary: #eef1f6;
  --text-secondary: #b3bcd0;
  --text-muted: #8f9ab3;

  --border-color: #2c3857;
  --border-strong: #6a7798;

  --brand-primary: #3d5fdb;
  --brand-primary-hover: #5273e8;
  --brand-cyan: #7c96f5;
  --brand-cyan-soft: rgba(124, 150, 245, 0.18);
  --brand-soft: rgba(124, 150, 245, 0.12);
  --brand-text: #a9bbff;

  --accent-warm: #3d5fdb;
  --accent-warm-hover: #5273e8;
  --accent-warm-soft: rgba(124, 150, 245, 0.18);

  --success: #4cc38a;
  --success-soft: rgba(76, 195, 138, 0.16);
  --danger: #ff7a8a;
  --danger-soft: rgba(255, 122, 138, 0.16);
  --warning: #f2c744;
  --warning-soft: rgba(242, 199, 68, 0.16);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 22px rgba(0, 0, 0, 0.34);
  --shadow-lg: 0 20px 48px rgba(0, 0, 0, 0.5);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

/* =========================================================
   INTERACTIVE SEARCH BAR, DROPDOWN & POPOVERS
   ========================================================= */
.search-wrapper {
  position: relative;
  flex: 1;
  max-width: 390px;
  min-width: 220px;
}

.topbar-search-input-box {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.42rem 0.9rem;
  border-radius: 999px;
  background: var(--bg-surface);
  border: 1.5px solid var(--border-color);
  color: var(--text-primary);
  font-size: 0.83rem;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.12s ease, box-shadow 0.12s ease;
}

.topbar-search-input-box:focus-within {
  border-color: var(--brand-cyan);
  box-shadow: 0 0 0 3px var(--brand-cyan-soft);
  background: var(--bg-elevated);
}

.topbar-search-input {
  border: none;
  background: transparent;
  outline: none;
  width: 100%;
  font-size: 0.83rem;
  color: var(--text-primary);
}

.topbar-search-input::placeholder {
  color: var(--text-muted);
}

.search-kbd-badge {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  padding: 0.1rem 0.4rem;
  border-radius: 5px;
  background: var(--bg-subtle);
  color: var(--text-secondary);
  flex-shrink: 0;
}

.search-results-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  min-width: 340px;
  max-height: 420px;
  overflow-y: auto;
  z-index: 95;
  background: var(--bg-surface-solid);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 0.55rem;
}

.search-result-item {
  width: 100%;
  text-align: left;
  padding: 0.65rem 0.75rem;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
  border-bottom: 1px solid var(--border-color);
  transition: background-color 0.1s ease;
}

.search-result-item:last-child {
  border-bottom: none;
}

.search-result-item:hover {
  background: var(--brand-cyan-soft);
}

.search-result-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--brand-text);
}

.search-result-question {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* TOPBAR DROPDOWN ESAME & POPOVER NOTIFICHE */
.dropdown-anchor {
  position: relative;
}

.floating-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 265px;
  z-index: 95;
  background: var(--bg-surface-solid);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 0.5rem;
}

.floating-menu-item {
  width: 100%;
  text-align: left;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-primary);
  transition: background-color 0.1s ease;
}

.floating-menu-item:hover,
.floating-menu-item.active {
  background: var(--brand-cyan-soft);
  color: var(--brand-text);
}

/* STREAK PILL & NOTIFICATION BELL */
.streak-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.38rem 0.75rem;
  border-radius: 999px;
  background: var(--warning-soft);
  border: 1px solid rgba(138, 90, 0, 0.45);
  color: var(--warning);
  font-weight: 800;
  font-size: 0.78rem;
}

[data-theme="dark"] .streak-pill {
  color: var(--warning);
}

.notif-btn-wrap {
  position: relative;
}

.notif-dot {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--danger);
  border: 2px solid var(--bg-surface-solid);
}

/* DUOLINGO-STYLE DAILY STREAK & GOAL BANNER */
.duolingo-streak-bar {
  background: var(--brand-soft);
  border: 1px solid rgba(36, 71, 198, 0.38);
  border-radius: var(--radius-md);
  padding: 0.95rem 1.25rem;
  margin-bottom: 1.15rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.streak-bar-left {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.streak-flame-badge {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: #b45309;
  color: #ffffff;
  font-size: 1.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  flex-shrink: 0;
}

.streak-goal-progress-wrap {
  min-width: 220px;
  flex: 1;
  max-width: 340px;
}

/* CUSTOM GLASS DATE PICKER (PRESETS + MODERN SELECTOR) */
.custom-date-picker-box {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.date-presets-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.date-preset-chip {
  padding: 0.36rem 0.75rem;
  border-radius: 999px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text-secondary);
  transition: all 0.12s ease;
}

.date-preset-chip:hover,
.date-preset-chip.active {
  background: var(--brand-cyan);
  border-color: var(--brand-cyan);
  color: #ffffff;
}

.date-selects-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.glass-select {
  padding: 0.42rem 0.68rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--bg-elevated);
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.82rem;
}

/* ACHIEVEMENTS / TRAGUARDI GRID */
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 0.95rem;
  margin-top: 1rem;
}

.achievement-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.15rem;
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  opacity: 0.55;
  filter: grayscale(0.65);
  transition: transform 0.12s ease, border-color 0.12s ease;
}

.achievement-card.unlocked {
  opacity: 1;
  filter: none;
  border-color: rgba(30, 123, 79, 0.55);
  background: var(--bg-elevated);
  box-shadow: var(--shadow-sm);
}

.achievement-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--brand-cyan-soft);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

/* SETTINGS FORM CONTROLS */
.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1rem;
}

.settings-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--border-color);
}

.settings-row:last-child {
  border-bottom: none;
}

.toggle-pill-btn {
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  background: var(--bg-subtle);
  color: var(--text-secondary);
  border: 1px solid var(--border-strong);
}

.toggle-pill-btn.on {
  background: var(--success-soft);
  color: var(--success);
  border-color: var(--success);
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-page);
  color: var(--text-primary);
  line-height: 1.5;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 1.15rem 1.15rem 4.2rem;
}

@media (max-width: 900px) {
  body {
    padding: 0.5rem 0.5rem 4.8rem;
  }
}

button, input, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

a {
  color: var(--brand-text);
  text-decoration: none;
}

.hidden {
  display: none !important;
}

.tabular {
  font-variant-numeric: tabular-nums;
}

/* =========================================================
   ADMIN V2 GLASSMORPHISM SHELL (SIDEBAR + MAIN STAGE)
   ========================================================= */
.admin-shell {
  max-width: 1380px;
  width: 100%;
  margin: 0 auto;
  min-height: calc(100dvh - 5.6rem);
  border-radius: var(--radius-xl);
  background: var(--shell-bg);
  border: 1px solid var(--shell-border);
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 260px 1fr;
  overflow: hidden;
}

@media (max-width: 980px) {
  .admin-shell {
    grid-template-columns: 1fr;
    border-radius: var(--radius-lg);
  }
}

/* SIDEBAR SINISTRA SCURA TRASLUCIDA */
.admin-sidebar {
  background: var(--sidebar-bg);
  border-right: 1px solid var(--sidebar-border);
  color: var(--sidebar-text);
  padding: 1.35rem 1rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1.25rem;
}

.sidebar-brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0.4rem 1rem;
  border-bottom: 1px solid var(--sidebar-border);
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 800;
  font-size: 1.08rem;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: #3d5fdb;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1rem;
  box-shadow: 0 4px 12px rgba(124, 150, 245, 0.35);
  flex-shrink: 0;
}

.sidebar-section-label {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--sidebar-muted);
  padding: 0.6rem 0.65rem 0.35rem;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0.28rem;
}

.sidebar-nav-item {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.62rem 0.78rem;
  border-radius: var(--radius-sm);
  color: var(--sidebar-text);
  font-size: 0.86rem;
  font-weight: 500;
  text-align: left;
  border: 1px solid transparent;
  transition: all 0.18s ease;
}

.sidebar-nav-item:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #ffffff;
}

.sidebar-nav-item.active {
  background: var(--sidebar-active-bg);
  border-color: var(--sidebar-active-border);
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(36, 71, 198, 0.18);
}

.sidebar-nav-left {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}

.sidebar-icon {
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  opacity: 0.88;
  font-size: 0.92rem;
}

.sidebar-pill-count {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.12);
  color: #c9d4ff;
}

.sidebar-footer-card {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(157, 178, 255, 0.25);
  border-radius: var(--radius-md);
  padding: 0.95rem;
  color: #eef1f6;
}

.sidebar-footer-title {
  display: block;
  font-size: 0.84rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.sidebar-footer-card p {
  font-size: 0.74rem;
  color: #c9d4ff;
  line-height: 1.38;
  margin-bottom: 0.65rem;
}

@media (max-width: 980px) {
  .admin-sidebar {
    padding: 0.85rem 1rem;
    gap: 0.65rem;
    min-width: 0;
    overflow: hidden;
  }
  .sidebar-nav {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 0.25rem;
    scrollbar-width: none;
    max-width: 100%;
  }
  .sidebar-nav-item {
    width: auto;
    white-space: nowrap;
    flex-shrink: 0;
    padding: 0.48rem 0.7rem;
    font-size: 0.8rem;
  }
  .sidebar-section-label,
  .sidebar-footer-card {
    display: none;
  }
  .sidebar-brand-row {
    padding-bottom: 0.5rem;
  }
}

/* AREA PRINCIPALE DESTRA (STAGE FROSTED GLASS) */
.admin-stage {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* TOPBAR INTERNA ALLO STAGE */
.topbar {
  padding: 0.9rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
  background: var(--shell-bg);
}

[data-theme="dark"] .topbar {
  background: rgba(9, 25, 38, 0.38);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

/* SEARCH / COMMAND PILL COME NEL VIDEO */
.topbar-search-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.82rem;
  min-width: 240px;
  box-shadow: var(--shadow-sm);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.exam-switcher-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.44rem 0.85rem;
  border-radius: 999px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  box-shadow: var(--shadow-sm);
  transition: transform 0.16s ease, border-color 0.16s ease;
}

.exam-switcher-btn:hover {
  transform: translateY(-1px);
  border-color: var(--brand-cyan);
}

.badge-pro-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.8rem;
  border-radius: 4px;
  font-size: 0.74rem;
  font-weight: 700;
}

.badge-pro-pill.is-free {
  background: rgba(36, 71, 198, 0.14);
  color: var(--brand-text);
  border: 1px solid rgba(36, 71, 198, 0.4);
}

.badge-pro-pill.is-pro {
  background: var(--success-soft);
  color: var(--success);
  border: 1px solid var(--success);
}

.user-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.3rem 0.7rem 0.3rem 0.35rem;
  border-radius: 999px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  font-size: 0.8rem;
  font-weight: 600;
}

.user-avatar-dot {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--brand-primary);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border-color);
  background: var(--bg-surface);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  box-shadow: var(--shadow-sm);
  transition: all 0.15s ease;
}

.icon-btn:hover {
  background: var(--bg-elevated);
  color: var(--text-primary);
  transform: translateY(-1px);
}

/* MAIN CONTAINER INTERNO ALLO STAGE */
.app-container {
  padding: 1.5rem 1.65rem 2.2rem;
  flex: 1;
}

@media (max-width: 680px) {
  .app-container {
    padding: 1rem;
  }
  .topbar-search-pill {
    display: none;
  }
}

/* =========================================================
   GLASS CARDS & HOVER LIFT (COME NEL CODICE DEL VIDEO)
   ========================================================= */
.glass-card,
.exam-card,
.readiness-card,
.kpi-box,
.mode-card,
.subjects-panel,
.question-card,
.outcome-banner,
.review-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: transform 0.11s ease-out, box-shadow 0.11s ease-out, border-color 0.11s ease-out;
}

.exam-card:hover,
.kpi-box:hover,
.mode-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: rgba(36, 71, 198, 0.55);
}

/* =========================================================
   ONBOARDING / EXAM SELECTOR
   ========================================================= */
.hero-onboarding {
  max-width: 1000px;
  margin: 0.25rem auto 1rem;
}

.eyebrow-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  border-radius: 4px;
  background: var(--brand-cyan-soft);
  color: var(--brand-text);
  font-size: 0.74rem;
  font-weight: 700;
  margin-bottom: 0.7rem;
}

.hero-title {
  font-size: clamp(1.55rem, 3vw, 2.2rem);
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.hero-subtitle {
  font-size: 0.96rem;
  color: var(--text-secondary);
  max-width: 68ch;
  margin-bottom: 1.35rem;
}

.exam-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.exam-card {
  padding: 1.3rem;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
  cursor: pointer;
}

.exam-card.selected {
  border: 2px solid var(--brand-cyan);
  background: var(--bg-elevated);
  box-shadow: 0 12px 30px rgba(36, 71, 198, 0.16);
}

.exam-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.exam-card-code {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.22rem 0.55rem;
  border-radius: 6px;
  background: var(--bg-subtle);
  color: var(--text-secondary);
}

.exam-card-title {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  margin: 0.5rem 0 0.3rem;
}

.exam-card-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.44;
}

.exam-card-specs {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border-color);
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.exam-card-specs li {
  display: flex;
  justify-content: space-between;
}

.exam-card-specs strong {
  color: var(--text-primary);
}

.onboarding-date-bar {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.date-input-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.date-input-group label {
  font-size: 0.88rem;
  font-weight: 600;
}

.input-date {
  padding: 0.46rem 0.8rem;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 0.86rem;
}

/* =========================================================
   PULSANTI (PILL / ROUNDED GLASS STYLE)
   ========================================================= */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.68rem 1.3rem;
  border-radius: var(--radius-sm);
  background: var(--brand-primary);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.88rem;
  box-shadow: none;
  transition: all 0.18s ease;
}

[data-theme="dark"] .btn-primary {
  background: var(--brand-primary);
}

.btn-primary:hover {
  transform: translateY(-1px);
  filter: brightness(1.08);
}

.btn-warm {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.72rem 1.35rem;
  border-radius: var(--radius-sm);
  background: var(--accent-warm);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.9rem;
  box-shadow: 0 8px 22px rgba(36, 71, 198, 0.3);
  transition: all 0.18s ease;
}

.btn-warm:hover {
  transform: translateY(-1px);
  filter: brightness(1.08);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.6rem 1.05rem;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.86rem;
  transition: all 0.16s ease;
}

.btn-secondary:hover {
  background: var(--bg-subtle);
}

/* =========================================================
   DASHBOARD STUDENTE — BENTO GRID "ADMIN V2"
   ========================================================= */
.dashboard-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.dashboard-greeting-tag {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.15rem;
}

.dashboard-exam-title {
  font-size: clamp(1.35rem, 2.4vw, 1.75rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text-primary);
}

.dashboard-exam-meta {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-top: 0.15rem;
}

.dashboard-header-right {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.countdown-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.48rem 0.9rem;
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
}

/* HERO ROW: SPLINE AREA CHART (SINISTRA) + DONUT GOAL CARD (DESTRA) */
.bento-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: 1rem;
  margin-bottom: 1rem;
}

@media (max-width: 1240px) {
  .bento-hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.chart-glass-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.35rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  min-width: 0;
  overflow: hidden;
}

.chart-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}

.chart-card-title {
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--text-primary);
}

.chart-card-sub {
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.chart-big-metric {
  font-family: var(--font-mono);
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--brand-text);
}

.spline-svg-wrap {
  width: 100%;
  height: 138px;
  margin-top: 0.25rem;
}

.spline-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.chart-axis-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  color: var(--text-muted);
  padding-top: 0.35rem;
  border-top: 1px solid var(--border-color);
}

/* DONUT / READINESS GOAL CARD (DESTRA) */
.readiness-card {
  padding: 1.25rem 1.35rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.85rem;
}

.readiness-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.readiness-body-row {
  display: flex;
  align-items: center;
  gap: 1.15rem;
}

.gauge-wrap {
  position: relative;
  width: 112px;
  height: 112px;
  flex-shrink: 0;
}

.gauge-svg {
  width: 112px;
  height: 112px;
  transform: rotate(-90deg);
}

.gauge-bg {
  fill: none;
  stroke: var(--bg-subtle);
  stroke-width: 10;
}

.gauge-fill {
  fill: none;
  stroke: var(--brand-primary);
  stroke-width: 10;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.5s ease, stroke 0.3s ease;
}

.gauge-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.gauge-value {
  font-family: var(--font-mono);
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
}

.gauge-label {
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-top: 0.22rem;
}

.readiness-info h2 {
  font-size: 0.98rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.readiness-status-badge {
  display: inline-block;
  padding: 0.18rem 0.55rem;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
}

.readiness-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.38;
}

/* 4 STAT CARDS ROW (COME NEL CODICE FRAMER MOTION DEL VIDEO) */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.9rem;
  margin-bottom: 1.4rem;
}

@media (max-width: 900px) {
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.kpi-box {
  padding: 1.05rem 1.15rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.55rem;
}

.kpi-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.kpi-title {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.kpi-trend-pill {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
  background: var(--brand-cyan-soft);
  color: var(--brand-text);
}

.kpi-num {
  font-family: var(--font-mono);
  font-size: 1.55rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.1;
}

.kpi-mini-bar {
  width: 100%;
  height: 5px;
  border-radius: 999px;
  background: var(--bg-subtle);
  overflow: hidden;
}

.kpi-mini-bar-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--brand-primary);
}

/* 4 MODALITA DI STUDIO RAPIDE */
.section-heading {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}

.modes-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.95rem;
  margin-bottom: 1.5rem;
}

@media (max-width: 680px) {
  .modes-grid {
    grid-template-columns: 1fr;
  }
}

.mode-card {
  padding: 1.2rem 1.25rem;
  text-align: left;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.85rem;
}

.mode-card.mode-primary {
  border-color: rgba(36, 71, 198, 0.55);
  background: var(--bg-surface);
}

.mode-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
}

.mode-tag {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  background: var(--bg-subtle);
  color: var(--text-secondary);
}

.mode-tag.tag-urgent {
  background: var(--danger-soft);
  color: var(--danger);
}

.mode-tag.tag-warn {
  background: var(--warning-soft);
  color: var(--warning);
}

.mode-title {
  font-size: 1.06rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  margin-top: 0.35rem;
  margin-bottom: 0.25rem;
}

.mode-desc {
  font-size: 0.84rem;
  color: var(--text-secondary);
  line-height: 1.42;
}

.mode-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.65rem;
  border-top: 1px solid var(--border-color);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--brand-text);
}

/* SUBJECT PROGRESS BARS */
.subjects-panel {
  padding: 1.2rem 1.35rem;
  margin-bottom: 1.25rem;
}

.subject-row {
  padding: 0.72rem 0;
  border-bottom: 1px solid var(--border-color);
}

.subject-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.subject-row-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.42rem;
  flex-wrap: wrap;
}

.subject-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-primary);
}

.subject-stats {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.progress-track {
  width: 100%;
  height: 7px;
  background: var(--bg-subtle);
  border-radius: 999px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background: var(--brand-primary);
  border-radius: 999px;
  transition: width 0.35s ease;
}

.btn-train-subject {
  padding: 0.28rem 0.68rem;
  border-radius: 999px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--brand-text);
  transition: all 0.15s ease;
}

.btn-train-subject:hover {
  background: var(--brand-cyan);
  border-color: var(--brand-cyan);
  color: #ffffff;
}

/* =========================================================
   QUIZ / SIMULATION RUNNER (GLASS EDITION)
   ========================================================= */
.quiz-shell {
  max-width: 840px;
  margin: 0 auto;
}

.quiz-topbar {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.15rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
  box-shadow: var(--shadow-sm);
}

.quiz-mode-badge {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--brand-text);
}

.quiz-timer {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.78rem;
  border-radius: 999px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 0.92rem;
  color: var(--text-primary);
}

.quiz-timer.timer-warning {
  background: var(--danger-soft);
  border-color: var(--danger);
  color: var(--danger);
}

.question-nav-strip {
  display: flex;
  gap: 0.38rem;
  overflow-x: auto;
  padding: 0.3rem 0.1rem 0.75rem;
  scrollbar-width: thin;
}

.q-dot {
  min-width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid var(--border-color);
  background: var(--bg-surface);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.q-dot.current {
  border-color: var(--brand-cyan);
  border-width: 2px;
  color: var(--text-primary);
  transform: translateY(-2px);
}

.q-dot.answered {
  background: var(--brand-cyan-soft);
  border-color: var(--brand-cyan);
  color: var(--brand-text);
}

.q-dot.correct {
  background: var(--success-soft);
  border-color: var(--success);
  color: var(--success);
}

.q-dot.wrong {
  background: var(--danger-soft);
  border-color: var(--danger);
  color: var(--danger);
}

.question-card {
  padding: 1.45rem;
  margin-bottom: 1rem;
}

.question-meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.9rem;
}

.question-subject-pill {
  font-size: 0.73rem;
  font-weight: 700;
  padding: 0.24rem 0.65rem;
  border-radius: 4px;
  background: var(--brand-cyan-soft);
  color: var(--brand-text);
}

.question-diff-pill {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.22rem 0.58rem;
  border-radius: 4px;
  background: var(--bg-subtle);
  color: var(--text-secondary);
}

.question-diff-pill.diff-3 {
  background: var(--warning-soft);
  color: var(--warning);
}

.question-text {
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.48;
  color: var(--text-primary);
  margin-bottom: 1.25rem;
}

.options-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.option-btn {
  width: 100%;
  text-align: left;
  padding: 0.9rem 1.05rem;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border-color);
  background: var(--bg-elevated);
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  transition: all 0.15s ease;
}

.option-btn:hover:not(:disabled) {
  border-color: var(--brand-cyan);
  transform: translateX(3px);
}

.option-letter {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--bg-subtle);
  border: 1px solid var(--border-strong);
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 0.82rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 0.05rem;
}

.option-content {
  font-size: 0.94rem;
  line-height: 1.44;
  color: var(--text-primary);
}

.option-btn.selected {
  border-color: var(--brand-cyan);
  background: var(--brand-cyan-soft);
}

.option-btn.selected .option-letter {
  background: var(--brand-cyan);
  border-color: var(--brand-cyan);
  color: #ffffff;
}

.option-btn.is-correct {
  border-color: var(--success);
  background: var(--success-soft);
}

.option-btn.is-correct .option-letter {
  background: var(--success);
  border-color: var(--success);
  color: #ffffff;
}

.option-btn.is-wrong {
  border-color: var(--danger);
  background: var(--danger-soft);
}

.option-btn.is-wrong .option-letter {
  background: var(--danger);
  border-color: var(--danger);
  color: #ffffff;
}

/* EXPLANATION BOX */
.explanation-box {
  margin-top: 1.15rem;
  padding: 1.1rem;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border-left: 4px solid var(--brand-cyan);
}

.explanation-title {
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--brand-text);
  margin-bottom: 0.38rem;
}

.explanation-text {
  font-size: 0.9rem;
  color: var(--text-primary);
  line-height: 1.5;
  margin-bottom: 0.75rem;
}

.memory-trick-box {
  padding: 0.65rem 0.85rem;
  border-radius: 10px;
  background: var(--brand-cyan-soft);
  border: 1px dashed var(--brand-cyan);
  font-size: 0.86rem;
  color: var(--text-primary);
}

.memory-trick-box strong {
  color: var(--brand-text);
}

.quiz-actions-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 1.1rem;
}

/* =========================================================
   RESULTS & PAYWALL CONVERSION TRAP
   ========================================================= */
.results-shell {
  max-width: 900px;
  margin: 0 auto;
}

.outcome-banner {
  padding: 1.5rem;
  margin-bottom: 1.35rem;
  border-width: 2px;
}

.outcome-banner.idoneo {
  border-color: var(--success);
}

.outcome-banner.non-idoneo {
  border-color: var(--danger);
}

.outcome-stamp {
  display: inline-block;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 800;
  margin-bottom: 0.65rem;
}

.outcome-banner.idoneo .outcome-stamp {
  background: var(--success-soft);
  color: var(--success);
}

.outcome-banner.non-idoneo .outcome-stamp {
  background: var(--danger-soft);
  color: var(--danger);
}

.outcome-score-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.outcome-big-score {
  font-family: var(--font-mono);
  font-size: clamp(1.85rem, 4vw, 2.5rem);
  font-weight: 800;
}

.review-card {
  padding: 1.3rem;
  margin-bottom: 1rem;
  position: relative;
  overflow: hidden;
}

.review-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.65rem;
}

.free-sample-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.22rem 0.6rem;
  border-radius: 4px;
  background: var(--success-soft);
  color: var(--success);
}

.locked-sample-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.22rem 0.6rem;
  border-radius: 4px;
  background: var(--brand-cyan-soft);
  color: var(--brand-text);
}

.paywall-blur-wrapper {
  position: relative;
  margin-top: 0.85rem;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border-strong);
  min-height: 195px;
}

.paywall-blurred-content {
  padding: 1rem;
  background: var(--bg-elevated);
  filter: blur(6px);
  user-select: none;
  pointer-events: none;
  opacity: 0.62;
}

.paywall-overlay-cta {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(13, 38, 56, 0.08) 0%, var(--bg-surface-solid) 90%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1.15rem;
  gap: 0.65rem;
}

.paywall-overlay-cta p {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-primary);
  max-width: 54ch;
}

/* MODAL CHECKOUT PASS PRO */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(10, 15, 28, 0.62);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-card {
  background: var(--bg-surface-solid);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  max-width: 520px;
  width: 100%;
  padding: 1.65rem;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg-subtle);
  font-weight: 700;
}

.price-box {
  background: var(--brand-cyan-soft);
  border: 1.5px solid var(--brand-cyan);
  border-radius: var(--radius-md);
  padding: 1rem 1.15rem;
  margin: 1rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.price-amount {
  font-family: var(--font-mono);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-primary);
}

.benefits-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin: 1rem 0 1.35rem;
  font-size: 0.9rem;
}

.benefits-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
}

/* DISCRETE DEVELOPER / DEMO TOGGLE BAR */
.dev-demo-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 60;
  background: #0b1222;
  border-top: 1px solid rgba(157, 178, 255, 0.22);
  padding: 0.48rem 1rem;
  color: #eef1f6;
}

.dev-demo-inner {
  max-width: 1360px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.78rem;
}

.dev-toggle-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.32rem 0.78rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(157, 178, 255, 0.3);
  color: #eef1f6;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.dev-toggle-switch:hover {
  background: rgba(255, 255, 255, 0.18);
}

.dev-toggle-switch.active {
  background: rgba(30, 123, 79, 0.25);
  border-color: var(--success);
  color: var(--success);
}

/* =========================================================
   MOTION.DEV SPRING EFFECTS & KOMBAI MOBILE DASHBOARD UX
   ========================================================= */
.xp-float-pill {
  position: fixed;
  z-index: 150;
  pointer-events: none;
  padding: 0.28rem 0.68rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 800;
  box-shadow: var(--shadow-md);
}

.xp-float-pill.xp-pos {
  background: #1e7b4f;
  color: #ffffff;
}

.xp-float-pill.xp-neg {
  background: #c8102e;
  color: #ffffff;
}

.motion-confetti-dot {
  position: fixed;
  width: 8px;
  height: 8px;
  border-radius: 2px;
  z-index: 160;
  pointer-events: none;
}

/* KOMBAI SEGMENTED SUBJECT FILTER PILLS */
.kombai-filter-strip {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  overflow-x: auto;
  padding: 0.2rem 0.1rem 0.85rem;
  scrollbar-width: none;
}

.kombai-filter-pill {
  padding: 0.42rem 0.85rem;
  border-radius: 999px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-secondary);
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.12s ease;
}

.kombai-filter-pill:hover,
.kombai-filter-pill.active {
  background: var(--brand-cyan);
  border-color: var(--brand-cyan);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(36, 71, 198, 0.25);
}

/* QUIZ PROGRESS BAR + COMBO PILL + KEYBOARD HINT */
.quiz-progress-line-track {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: var(--bg-subtle);
  overflow: hidden;
  margin-bottom: 0.75rem;
}

.quiz-progress-line-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--brand-primary);
  transition: width 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.combo-streak-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.24rem 0.65rem;
  border-radius: 999px;
  background: var(--warning-soft);
  border: 1px solid rgba(138, 90, 0, 0.45);
  color: var(--warning);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 800;
}

[data-theme="dark"] .combo-streak-pill {
  color: var(--warning);
}

.kbd-shortcut-hint {
  font-size: 0.74rem;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.kbd-key {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.1rem 0.38rem;
  border-radius: 5px;
  background: var(--bg-subtle);
  border: 1px solid var(--border-strong);
  color: var(--text-primary);
}

/* KOMBAI MOBILE FLOATING DOCK NAVIGATION */
.kombai-mobile-dock {
  display: none;
}

@media (max-width: 780px) {
  .dev-demo-inner > div:first-child {
    display: none !important;
  }

  .dev-demo-bar {
    padding: 0.35rem 0.6rem;
  }

  .dev-toggle-switch {
    font-size: 0.7rem;
    padding: 0.25rem 0.55rem;
  }

  .kombai-mobile-dock {
    position: fixed;
    bottom: 2.55rem;
    left: 0.5rem;
    right: 0.5rem;
    z-index: 65;
    background: #0b1222;
    border: 1px solid rgba(157, 178, 255, 0.32);
    border-radius: var(--radius-lg);
    padding: 0.28rem 0.35rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.15rem;
    box-shadow: var(--shadow-lg);
  }

  .dock-btn {
    flex: 1;
    justify-content: center;
    padding: 0.38rem 0.3rem;
    border-radius: 999px;
    color: #c9d4ff;
    font-size: 0.68rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 0.22rem;
    white-space: nowrap;
  }

  .dock-btn.active {
    background: var(--brand-primary);
    color: #ffffff;
  }
}

/* =========================================================
   BASE: FOCUS, PRESSIONE, NUMERI, MOVIMENTO RIDOTTO
   ========================================================= */
body {
  font-variant-numeric: tabular-nums;
}

h1, h2, h3 {
  text-wrap: balance;
}

:focus-visible {
  outline: 2px solid var(--brand-cyan);
  outline-offset: 2px;
}

.salta-contenuto {
  position: fixed;
  top: 0.5rem;
  left: 0.5rem;
  z-index: 200;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-sm);
  background: var(--bg-surface-solid);
  color: var(--text-primary);
  font-weight: 700;
  transform: translateY(-200%);
}

.salta-contenuto:focus-visible {
  transform: none;
}

main[tabindex="-1"]:focus {
  outline: none;
}

button:active:not(:disabled) {
  transform: translateY(1px);
}

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

/* =========================================================
   FINESTRA DI CONFERMA
   ========================================================= */
.confirm-card {
  max-width: 420px;
}

.confirm-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.45rem;
}

.confirm-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
  margin-top: 1.25rem;
  flex-wrap: wrap;
}

.confirm-actions button {
  min-height: 44px;
}

.btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.15rem;
  border-radius: var(--radius-sm);
  background: #c8102e;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.88rem;
}

.btn-danger:hover {
  background: #a50d26;
}

body.senza-barra-demo {
  padding-bottom: 1.15rem;
}

/* =========================================================
   SCHERMATA D'ESAME: BERSAGLI AL TOCCO E MODALITÀ CONCENTRATA
   ========================================================= */
.option-btn {
  min-height: 52px;
  font-size: 1rem;
  line-height: 1.4;
}

.q-dot {
  min-width: 40px;
  height: 40px;
}

.quiz-topbar .icon-btn,
.quiz-topbar .btn-secondary {
  min-width: 44px;
  min-height: 44px;
}

.question-text {
  max-width: 62ch;
}

@media (max-width: 980px) {
  body.in-quiz .admin-sidebar,
  body.in-quiz .topbar,
  body.in-quiz .kombai-mobile-dock {
    display: none;
  }

  body.in-quiz .app-container {
    padding: 0.75rem;
  }

  .quiz-topbar {
    flex-wrap: wrap;
    padding: 0.7rem 0.85rem;
  }

  .quiz-topbar > div:first-child {
    flex: 1 1 100%;
  }

  .quiz-topbar > div:last-child {
    flex: 1 1 100%;
    justify-content: space-between;
  }

  .question-card {
    padding: 1rem;
  }

  .question-text {
    font-size: 1.05rem;
  }

  .kbd-shortcut-hint {
    display: none;
  }

  .quiz-actions-bar {
    position: sticky;
    bottom: 2.6rem;
    z-index: 5;
    background: var(--bg-surface-solid);
    border-top: 1px solid var(--border-color);
    margin: 1rem -1rem -1rem;
    padding: 0.65rem 1rem;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    gap: 0.6rem;
  }

  body.senza-barra-demo .quiz-actions-bar {
    bottom: 0;
  }

  .quiz-actions-bar > button {
    flex: 1;
    min-height: 48px;
  }
}


/* =========================================================
   ICONE, PIANI DI ABBONAMENTO, NOTE
   ========================================================= */
.ic {
  flex-shrink: 0;
  vertical-align: -3px;
}

.nota-fonte {
  font-size: 0.82rem;
  color: var(--text-muted);
  max-width: 62ch;
  margin-top: 0.5rem;
}

.paywall-card {
  max-width: 480px;
}

.paywall-title {
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.4rem;
  padding-right: 2.2rem;
}

.paywall-context {
  font-size: 0.93rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.plans-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.6rem;
  margin: 1rem 0;
}

.plan-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.2rem;
  text-align: left;
  padding: 0.85rem 0.9rem;
  min-height: 108px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border-strong);
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.plan-card.selected {
  border-color: var(--brand-cyan);
  background: var(--brand-soft);
  box-shadow: inset 0 0 0 1px var(--brand-cyan);
}

.plan-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.plan-price {
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.15;
}

.plan-price small {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.plan-note {
  font-size: 0.76rem;
  color: var(--text-secondary);
}

.paywall-cta {
  width: 100%;
  min-height: 48px;
  font-size: 1rem;
}

.paywall-legal {
  font-size: 0.76rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 0.6rem;
  line-height: 1.4;
}

@media (max-width: 420px) {
  .plans-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .plan-card {
    min-height: 0;
  }
}

@media (max-width: 780px) {
  #btn-user-profile {
    display: none;
  }
}

/* Avviso via email nel paywall */
.paywall-avviso {
  margin-top: 0.4rem;
  padding-top: 0.9rem;
  border-top: 1px solid var(--border-color);
}

.paywall-avviso-testo {
  font-size: 0.9rem;
  line-height: 1.45;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}

.paywall-avviso label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.3rem;
}

.paywall-avviso-riga {
  display: flex;
  gap: 0.5rem;
}

.paywall-avviso-riga input {
  flex: 1;
  min-width: 0;
  min-height: 48px;
  padding: 0 0.8rem;
  font: inherit;
  font-size: 1rem;
  color: var(--text-primary);
  background: var(--bg-surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
}

.paywall-avviso-riga .btn-warm {
  min-height: 48px;
  flex-shrink: 0;
}

.paywall-avviso-riga .btn-warm:disabled {
  opacity: 0.6;
  cursor: default;
}

.paywall-avviso-esito {
  min-height: 1.3rem;
  margin-top: 0.45rem;
  font-size: 0.84rem;
  color: var(--success, #1e7b4f);
}

.paywall-avviso-esito.errore {
  color: var(--danger, #c8102e);
}

.paywall-avviso .paywall-legal a {
  color: var(--brand-text);
  text-decoration: underline;
}

.paywall-trappola {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

@media (max-width: 420px) {
  .paywall-avviso-riga {
    flex-direction: column;
  }
}

/* Contrasto dell'etichetta verde sulle schede d'esame (tema chiaro) */
:root:not([data-theme="dark"]) .free-sample-badge {
  color: #17633f;
}
