:root {
  --ink: #17332f;
  --ink-soft: #5f706d;
  --forest: #103c35;
  --forest-2: #185a4e;
  --mint: #dff2e8;
  --mint-2: #edf8f3;
  --cream: #f7f5ee;
  --paper: #fffefa;
  --line: #dfe6e2;
  --orange: #e9783c;
  --orange-soft: #fff0e6;
  --blue: #4b7ca8;
  --blue-soft: #eaf3fb;
  --purple: #786ca4;
  --purple-soft: #f0edfb;
  --danger: #b44444;
  --shadow: 0 16px 40px rgba(26, 61, 54, .09);
  --radius: 20px;
  --radius-sm: 12px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background: var(--cream);
  font-family: "Segoe UI", Inter, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(380px, 1.1fr) minmax(420px, .9fr);
  background: var(--cream);
}

.auth-visual {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(45px, 8vw, 110px);
  color: #fff;
  background:
    radial-gradient(circle at 18% 12%, rgba(139, 211, 184, .24), transparent 34%),
    linear-gradient(145deg, #123f37, #0a2d29);
}

.auth-brand-mark { width: 62px; height: 62px; display: grid; place-items: center; margin-bottom: 28px; border: 1px solid #8ec4b1; border-radius: 50%; font-size: 32px; }
.auth-visual > span { color: #9fc9bd; font-size: 10px; font-weight: 900; letter-spacing: .2em; }
.auth-visual h1 { max-width: 620px; margin: 14px 0; font-family: Georgia, serif; font-size: clamp(40px, 5vw, 68px); font-weight: 400; line-height: 1.08; }
.auth-visual p { max-width: 580px; color: #bed3cd; font-size: 14px; line-height: 1.7; }
.auth-points { display: grid; gap: 10px; margin-top: 28px; color: #d6e7e1; font-size: 11px; }
.auth-panel { display: grid; place-items: center; padding: 35px; }
.auth-panel > div { width: min(440px, 100%); }
.auth-panel h2 { margin: 8px 0; font-family: Georgia, serif; font-size: 35px; font-weight: 500; }
.auth-panel p { margin: 0 0 24px; color: var(--ink-soft); font-size: 12px; }
.auth-panel form { display: grid; gap: 14px; }
.auth-panel input { width: 100%; min-height: 46px; border: 1px solid var(--line); border-radius: 10px; padding: 0 13px; outline: 0; background: var(--paper); }
.auth-switch { width: 100%; border: 0; margin-top: 14px; padding: 10px; color: var(--forest-2); background: transparent; font-size: 11px; font-weight: 800; }
.auth-panel small { display: block; margin-top: 12px; color: var(--ink-soft); font-size: 9px; line-height: 1.5; text-align: center; }
.auth-error { border-radius: 9px; padding: 11px 13px; color: #8b3434; background: #ffedeb; font-size: 10px; }
.auth-loading { color: var(--ink-soft); font-size: 12px; text-align: center; }

button, input, textarea, select { font: inherit; }
button { color: inherit; }
button, select { cursor: pointer; }

.app-shell { min-height: 100vh; }

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 20;
  width: 248px;
  display: flex;
  flex-direction: column;
  padding: 30px 18px 22px;
  color: #fff;
  background:
    radial-gradient(circle at 10% 5%, rgba(78, 153, 126, .28), transparent 35%),
    linear-gradient(165deg, #123d37, #0a2d29);
  overflow-y: auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 11px 30px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: #bde1d2;
}

.brand-mark svg {
  width: 40px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
}

.brand strong {
  display: block;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  line-height: 1;
}

.brand span {
  display: block;
  margin-top: 5px;
  color: #8fbbb0;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .24em;
}

.main-nav { display: grid; gap: 5px; }

.nav-item {
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 13px;
  border: 0;
  border-radius: 12px;
  padding: 0 14px;
  color: #b9d0ca;
  background: transparent;
  text-align: left;
  transition: .2s ease;
}

.nav-item:hover { color: #fff; background: rgba(255,255,255,.07); }
.nav-item.active { color: #fff; background: rgba(255,255,255,.12); }
.nav-icon { width: 20px; font-size: 20px; text-align: center; }

.nav-badge {
  min-width: 24px;
  margin-left: auto;
  border-radius: 999px;
  padding: 3px 7px;
  color: #163f37;
  background: #bfe3d5;
  font-size: 11px;
  font-weight: 800;
  text-align: center;
}

.sidebar-bottom {
  display: grid;
  gap: 14px;
  margin-top: auto;
}

.exam-mini {
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 15px;
  padding: 15px;
  background: rgba(255,255,255,.06);
}

.exam-mini span, .exam-mini small {
  display: block;
  color: #9dbab3;
  font-size: 11px;
}

.exam-mini strong { display: block; margin: 5px 0 12px; font-size: 14px; }

.progress-track {
  height: 5px;
  margin-bottom: 8px;
  overflow: hidden;
  border-radius: 10px;
  background: rgba(255,255,255,.12);
}

.progress-track i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: #8ed3ba;
}

.main-content { min-height: 100vh; margin-left: 248px; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 15;
  min-height: 88px;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 16px 38px;
  border-bottom: 1px solid rgba(210, 220, 216, .85);
  background: rgba(247, 245, 238, .92);
  backdrop-filter: blur(16px);
}

.topbar h1 { margin: 2px 0 0; font-family: Georgia, "Times New Roman", serif; font-size: 24px; font-weight: 500; }
.eyebrow, .section-kicker { color: #6d827c; font-size: 10px; font-weight: 800; letter-spacing: .16em; }
.topbar-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.sync-indicator { max-width: 145px; overflow: hidden; color: var(--ink-soft); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }

.install-button {
  min-height: 38px;
  border: 1px solid var(--forest-2);
  border-radius: 999px;
  padding: 0 14px;
  color: #fff;
  background: var(--forest-2);
  font-size: 10px;
  font-weight: 800;
}

.icon-button, .mobile-menu {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  font-size: 19px;
}

.mobile-menu { display: none; }

.profile-button {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  padding: 4px;
  background: transparent;
  text-align: left;
}

.profile-button > span:first-child {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--forest-2);
  font-family: Georgia, serif;
  font-size: 18px;
}

.profile-copy strong, .profile-copy small { display: block; }
.profile-copy strong { font-size: 13px; }
.profile-copy small { margin-top: 2px; color: var(--ink-soft); font-size: 11px; }

.view { display: none; padding: 34px 38px 56px; animation: fade-in .28s ease; }
.view.active { display: block; }
@keyframes fade-in { from { opacity: 0; transform: translateY(5px); } }

.today-hero {
  position: relative;
  min-height: 260px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  overflow: hidden;
  border-radius: 25px;
  padding: 38px 50px;
  color: #fff;
  background:
    radial-gradient(circle at 84% 20%, rgba(139, 211, 184, .24), transparent 30%),
    radial-gradient(circle at 74% 90%, rgba(255,255,255,.08), transparent 35%),
    linear-gradient(130deg, #123f37, #0d302b);
  box-shadow: var(--shadow);
}

.today-hero::after {
  content: "";
  position: absolute;
  right: -70px;
  bottom: -140px;
  width: 340px;
  height: 340px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 50%;
  box-shadow: 0 0 0 50px rgba(255,255,255,.025), 0 0 0 100px rgba(255,255,255,.018);
}

.hero-copy { position: relative; z-index: 2; max-width: 650px; }
.date-pill { color: #a9cfc3; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.hero-copy h2 { margin: 12px 0 9px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(32px, 4vw, 50px); font-weight: 400; }
.hero-copy p { max-width: 590px; margin: 0; color: #c2d9d3; line-height: 1.6; }
.hero-actions { display: flex; gap: 10px; margin-top: 26px; }

.primary-button, .secondary-button, .file-button, .timer-button {
  min-height: 43px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 10px;
  padding: 0 17px;
  font-size: 13px;
  font-weight: 750;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}

.primary-button {
  border: 1px solid var(--forest-2);
  color: #fff;
  background: var(--forest-2);
  box-shadow: 0 7px 16px rgba(17, 75, 64, .18);
}

.today-hero .primary-button { border-color: #f2f5e9; color: var(--forest); background: #f2f5e9; }
.primary-button:hover, .secondary-button:hover, .file-button:hover { transform: translateY(-1px); }
.secondary-button, .file-button { border: 1px solid var(--line); color: var(--ink); background: var(--paper); }
.today-hero .secondary-button { border-color: rgba(255,255,255,.2); color: #fff; background: rgba(255,255,255,.08); }
.full { width: 100%; }

.hero-ring-wrap {
  position: relative;
  z-index: 2;
  min-width: 145px;
  display: grid;
  justify-items: center;
  gap: 10px;
}

.hero-ring {
  --progress: 0deg;
  width: 128px;
  height: 128px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(#9bdbc3 var(--progress), rgba(255,255,255,.12) 0);
}

.hero-ring::before {
  content: "";
  position: absolute;
  width: 108px;
  height: 108px;
  border-radius: 50%;
  background: #123c35;
}

.hero-ring div { position: relative; display: grid; justify-items: center; }
.hero-ring strong { font-family: Georgia, serif; font-size: 28px; font-weight: 400; }
.hero-ring span, .hero-ring-wrap small { color: #aecbc3; font-size: 11px; }

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin: 18px 0;
}

.stat-card {
  min-height: 118px;
  display: grid;
  grid-template-columns: 44px 1fr;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px;
  background: var(--paper);
}

.stat-card small { grid-column: 2; margin-top: -15px; color: var(--ink-soft); font-size: 10px; }
.stat-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; font-size: 20px; }
.stat-card span { display: block; color: var(--ink-soft); font-size: 11px; }
.stat-card strong { display: block; margin-top: 4px; font-family: Georgia, serif; font-size: 24px; font-weight: 500; }
.accent-orange .stat-icon { color: var(--orange); background: var(--orange-soft); }
.accent-green .stat-icon { color: var(--forest-2); background: var(--mint); }
.accent-blue .stat-icon { color: var(--blue); background: var(--blue-soft); }
.accent-purple .stat-icon { color: var(--purple); background: var(--purple-soft); }

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  box-shadow: 0 8px 30px rgba(26, 61, 54, .035);
}

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(280px, .7fr); gap: 18px; }
.study-plan-panel, .focus-panel, .weak-points-panel { padding: 24px; }
.weak-points-panel { margin-top: 18px; }

.panel-header, .calendar-header, .cards-summary, .radar-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.panel-header h3, .calendar-header h2, .cards-summary h2, .radar-hero h2, .method-hero h2 {
  margin: 5px 0 0;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
}

.panel-header h3 { font-size: 21px; }
.time-chip { border-radius: 999px; padding: 7px 11px; color: var(--forest-2); background: var(--mint-2); font-size: 11px; font-weight: 800; }
.text-button, .danger-text { border: 0; padding: 4px; color: var(--forest-2); background: transparent; font-size: 12px; font-weight: 700; }
.danger-text { color: var(--danger); }

.plan-list { display: grid; gap: 10px; margin-top: 18px; }

.plan-item {
  display: grid;
  grid-template-columns: 38px 1fr auto;
  align-items: center;
  gap: 13px;
  border: 1px solid #e5ebe8;
  border-radius: 13px;
  padding: 13px;
  background: #fff;
}

.plan-item.completed { opacity: .62; background: #f5f8f6; }
.plan-item.completed .plan-title { text-decoration: line-through; }
.plan-number { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: var(--forest-2); background: var(--mint-2); font-size: 11px; font-weight: 900; }
.plan-item[data-area="Cirurgia"] .plan-number { color: var(--orange); background: var(--orange-soft); }
.plan-title { display: block; font-size: 13px; }
.plan-meta { display: block; margin-top: 4px; color: var(--ink-soft); font-size: 10px; }
.plan-check { width: 28px; height: 28px; border: 1px solid #cfdad5; border-radius: 50%; background: #fff; }
.plan-item.completed .plan-check { border-color: var(--forest-2); color: #fff; background: var(--forest-2); }

.focus-panel { display: flex; flex-direction: column; }
.timer-field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin-top: 18px; }
.timer-field-grid label span { display: block; margin-bottom: 5px; color: var(--ink-soft); font-size: 9px; font-weight: 850; text-transform: uppercase; letter-spacing: .08em; }
.timer-field-grid select, .timer-field-grid input { width: 100%; min-height: 40px; border: 1px solid var(--line); border-radius: 10px; padding: 0 10px; background: #fff; outline: 0; font-size: 11px; }
.timer-today { margin-top: 14px; border: 1px solid var(--line); border-radius: 13px; padding: 12px; background: #fafbf8; }
.timer-today strong { display: block; margin-bottom: 8px; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
#timer-daily-topics { display: flex; flex-wrap: wrap; gap: 6px; }
#timer-daily-topics button { border: 1px solid #dfe8e4; border-radius: 999px; padding: 7px 10px; color: var(--forest-2); background: #fff; font-size: 9px; font-weight: 800; }
#timer-daily-topics button.active { color: #fff; border-color: var(--forest-2); background: var(--forest-2); }
.timer-display { margin: 25px 0 15px; font-family: Georgia, serif; font-size: clamp(42px, 5vw, 58px); text-align: center; letter-spacing: .02em; }
.timer-presets { display: flex; justify-content: center; gap: 7px; margin-bottom: 14px; }
.timer-presets.hidden { display: none; }
.timer-presets button { border: 1px solid var(--line); border-radius: 999px; padding: 6px 11px; color: var(--ink-soft); background: #fff; font-size: 10px; }
.timer-presets button.active { border-color: var(--forest-2); color: #fff; background: var(--forest-2); }
.timer-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.timer-button { width: 100%; border: 0; color: #fff; background: var(--forest); }
.timer-hint { margin: 12px 0 0; color: var(--ink-soft); font-size: 10px; line-height: 1.5; text-align: center; }

.weak-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 18px; }
.weak-item { border-radius: 13px; padding: 15px; background: #f6f8f6; }
.weak-item span { display: block; color: var(--ink-soft); font-size: 10px; }
.weak-item strong { display: block; margin: 5px 0 10px; font-size: 13px; }
.micro-progress { height: 5px; overflow: hidden; border-radius: 10px; background: #dfe7e3; }
.micro-progress i { display: block; height: 100%; border-radius: inherit; background: var(--orange); }

.section-toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.search-box { min-width: 220px; flex: 1; display: flex; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 11px; padding: 0 13px; background: var(--paper); }
.search-box input { width: 100%; height: 43px; border: 0; outline: 0; background: transparent; color: var(--ink); }
select, input, textarea { color: var(--ink); }
.section-toolbar > select, .editor-meta select, .editor-meta input, .settings-panel input, .settings-panel select, .modal form input, .modal form select {
  min-height: 43px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 12px;
  outline: none;
  background: var(--paper);
}

.notes-layout { min-height: 780px; display: grid; grid-template-columns: 245px minmax(0, 1fr); gap: 16px; }
.notes-layout.editor-wide { grid-template-columns: 0 minmax(0, 1fr); }
.notes-layout.editor-wide .notes-list-panel { width: 0; border: 0; opacity: 0; pointer-events: none; }
.notes-list-panel { overflow: hidden; }
.notes-list-heading { display: flex; justify-content: space-between; padding: 18px; border-bottom: 1px solid var(--line); }
.notes-list-heading span { color: var(--ink-soft); font-size: 11px; }
.notes-list { max-height: 750px; overflow-y: auto; }
.note-list-item { width: 100%; display: block; border: 0; border-bottom: 1px solid #edf0ee; padding: 16px 18px; background: transparent; text-align: left; }
.note-list-item:hover, .note-list-item.active { background: var(--mint-2); }
.note-list-item strong { display: block; overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.note-list-item p { display: -webkit-box; overflow: hidden; margin: 7px 0; color: var(--ink-soft); font-size: 11px; line-height: 1.45; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.note-list-item small { color: #80908c; font-size: 9px; }

.note-editor { min-width: 0; padding: 30px; transition: .2s ease; }
.empty-state { min-height: 560px; display: grid; place-content: center; justify-items: center; max-width: 430px; margin: auto; text-align: center; }
.empty-illustration { width: 72px; height: 72px; display: grid; place-items: center; border-radius: 22px; color: var(--forest-2); background: var(--mint); font-size: 31px; }
.empty-state h3 { margin: 18px 0 8px; font-family: Georgia, serif; font-size: 25px; font-weight: 500; }
.empty-state p { margin: 0 0 20px; color: var(--ink-soft); font-size: 13px; line-height: 1.6; }
.hidden { display: none !important; }
.editor-topline { display: flex; align-items: center; gap: 7px; color: var(--ink-soft); font-size: 10px; }
.editor-topline .danger-text { margin-left: auto; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #55a184; }
.title-input { width: 100%; border: 0; border-bottom: 1px solid var(--line); padding: 22px 0 15px; outline: 0; background: transparent; font-family: Georgia, serif; font-size: 29px; }
.editor-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 16px 0; }
label > span { display: block; margin-bottom: 7px; color: var(--ink-soft); font-size: 10px; font-weight: 700; }
.field-hint { display: block; margin-top: 6px; color: var(--ink-soft); font-size: 9px; line-height: 1.45; }
.editor-meta select, .editor-meta input { width: 100%; }
.template-strip { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; margin-bottom: 12px; }
.template-strip span { margin-right: 4px; color: var(--ink-soft); font-size: 10px; }
.template-strip button { border: 1px solid var(--line); border-radius: 999px; padding: 6px 10px; color: var(--ink-soft); background: #fff; font-size: 10px; }
#note-body { width: 100%; min-height: 520px; resize: vertical; border: 1px solid var(--line); border-radius: 13px; padding: 20px; outline: 0; background: #fff; font-family: "Segoe UI", sans-serif; font-size: 15px; line-height: 1.75; }
#note-body:focus, input:focus, textarea:focus, select:focus { border-color: #8eb9aa; box-shadow: 0 0 0 3px rgba(55, 130, 107, .08); }
.editor-helper { margin: 8px 0 0; color: var(--ink-soft); font-size: 10px; line-height: 1.45; }
.editor-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 13px; }
.editor-footer > span { color: var(--ink-soft); font-size: 10px; }
.editor-footer > div { display: flex; gap: 8px; }

.note-reader { margin-top: 22px; border: 1px solid var(--line); border-radius: 17px; overflow: hidden; background: #fff; }
.note-reader-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 20px; border-bottom: 1px solid var(--line); background: #f7f9f7; }
.note-reader-toolbar h3 { margin: 4px 0 0; font-family: Georgia, serif; font-size: 19px; font-weight: 500; }
.note-reader-toolbar select { min-height: 40px; border: 1px solid var(--line); border-radius: 9px; padding: 0 11px; background: #fff; }
.note-reading-output { min-height: 180px; padding: 22px; font-size: 12px; line-height: 1.7; }
.note-reading-output h4 { margin: 0 0 7px; font-family: Georgia, serif; font-size: 19px; font-weight: 500; }
.note-reading-output p { margin: 5px 0 14px; white-space: pre-wrap; }
.cornell-layout { display: grid; grid-template-columns: minmax(150px, .32fr) 1fr; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.cornell-cues, .cornell-notes { padding: 17px; }
.cornell-cues { border-right: 1px solid var(--line); background: var(--mint-2); }
.cornell-summary { grid-column: 1 / -1; border-top: 1px solid var(--line); padding: 17px; background: #fffaf2; }
.derived-block { border-left: 3px solid var(--forest-2); margin-bottom: 14px; padding: 4px 0 4px 14px; }
.derived-block .trap { color: #a44f27; font-size: 10px; }
.algorithm-steps { display: grid; gap: 9px; counter-reset: algorithm; }
.algorithm-step { position: relative; border: 1px solid var(--line); border-radius: 11px; padding: 13px 13px 13px 44px; background: #fafbf9; }
.algorithm-step::before { counter-increment: algorithm; content: counter(algorithm); position: absolute; left: 12px; top: 11px; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--forest-2); font-size: 9px; font-weight: 900; }

.note-focus-card {
  margin-top: 22px;
  border: 1px solid #bcd8cd;
  border-radius: 17px;
  padding: 22px;
  background: linear-gradient(135deg, #edf8f3, #fffdf6);
}

.note-focus-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.note-focus-heading h3 {
  margin: 5px 0 0;
  font-family: Georgia, serif;
  font-size: 22px;
  font-weight: 500;
}

.freshness-chip {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 7px 10px;
  color: var(--forest-2);
  background: #d9eee5;
  font-size: 9px;
  font-weight: 800;
}

.note-focus-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 20px;
}

.note-focus-columns strong { font-size: 11px; }
.note-focus-columns ul { margin: 10px 0 0; padding-left: 18px; color: var(--ink-soft); font-size: 11px; line-height: 1.65; }
.note-focus-columns li + li { margin-top: 6px; }
.note-focus-sources { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 18px; padding-top: 15px; border-top: 1px solid #cee1da; }
.note-focus-sources a { border-radius: 999px; padding: 7px 10px; color: var(--forest-2); background: #fff; font-size: 9px; font-weight: 750; text-decoration: none; }

.cards-summary, .calendar-header, .radar-hero { margin-bottom: 22px; }
.cards-summary h2, .calendar-header h2, .radar-hero h2, .method-hero h2 { font-size: 34px; }
.cards-summary p, .calendar-header p, .radar-hero p, .method-hero p { max-width: 700px; margin: 8px 0 0; color: var(--ink-soft); line-height: 1.55; }
.stat-grid.compact { margin-bottom: 20px; }
.mini-stat { border: 1px solid var(--line); border-radius: 14px; padding: 17px; background: var(--paper); }
.mini-stat span { display: block; color: var(--ink-soft); font-size: 10px; }
.mini-stat strong { display: block; margin-top: 4px; font-family: Georgia, serif; font-size: 25px; font-weight: 500; }
.cards-toolbar { padding: 18px 18px 0; }
.cards-list { display: grid; gap: 8px; padding: 0 18px 18px; }
.card-row { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(180px, 1fr) 120px 38px; align-items: center; gap: 16px; border: 1px solid #e7ece9; border-radius: 12px; padding: 14px; }
.card-row:hover { border-color: #b8d0c8; }
.card-row .question, .card-row .answer { min-width: 0; }
.card-row strong, .card-row p { display: -webkit-box; overflow: hidden; margin: 0; font-size: 12px; line-height: 1.4; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.card-row p { color: var(--ink-soft); }
.card-row small { display: block; margin-bottom: 4px; color: #8a9995; font-size: 9px; }
.card-status { justify-self: start; border-radius: 999px; padding: 6px 9px; font-size: 9px; font-weight: 800; }
.status-due { color: #a54d23; background: var(--orange-soft); }
.status-new { color: var(--blue); background: var(--blue-soft); }
.status-learning { color: var(--forest-2); background: var(--mint-2); }
.status-mature { color: var(--purple); background: var(--purple-soft); }
.delete-card { width: 32px; height: 32px; border: 0; border-radius: 9px; color: var(--danger); background: #fff4f2; }

.calendar-actions { display: flex; gap: 8px; }
.calendar-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(280px, .55fr); gap: 18px; }
.calendar-panel, .day-detail { padding: 24px; }
.month-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.month-nav h3 { margin: 0; font-family: Georgia, serif; font-size: 24px; font-weight: 500; text-transform: capitalize; }
.month-nav button { width: 35px; height: 35px; border: 1px solid var(--line); border-radius: 50%; background: #fff; font-size: 22px; }
.weekdays, .calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); }
.weekdays span { padding: 0 5px 10px; color: #81918d; font-size: 9px; font-weight: 800; text-align: center; }
.calendar-day { position: relative; min-height: 94px; border: 0; border-top: 1px solid var(--line); border-right: 1px solid var(--line); padding: 9px; background: transparent; text-align: left; }
.calendar-day:nth-child(7n) { border-right: 0; }
.calendar-day.other-month { color: #aeb9b6; background: #fafaf7; }
.calendar-day.past { color: #889793; background: #f0f2ef; }
.calendar-day.past .day-badge { opacity: .76; }
.calendar-day.selected { outline: 2px solid var(--forest-2); outline-offset: -2px; background: var(--mint-2); }
.calendar-day.today .day-number { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--forest-2); }
.day-number { font-size: 11px; font-weight: 700; }
.day-study-status { position: absolute; top: 7px; right: 7px; width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; color: #fff; font-size: 11px; font-weight: 950; box-shadow: 0 4px 10px rgba(19, 42, 36, .12); }
.day-study-status.done { background: var(--forest-2); }
.day-study-status.missed { background: var(--danger); }
.day-badges { display: grid; gap: 4px; margin-top: 9px; }
.day-badge { overflow: hidden; border-radius: 5px; padding: 4px 5px; font-size: 8px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.day-badge.review { color: #9f4f26; background: var(--orange-soft); }
.day-badge.study { color: var(--forest-2); background: var(--mint); }
.day-detail h3 { margin: 5px 0 20px; font-family: Georgia, serif; font-size: 24px; font-weight: 500; text-transform: capitalize; }
.day-section { margin-bottom: 22px; }
.day-section > strong { display: block; margin-bottom: 9px; font-size: 11px; }
.day-section-title-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 9px; }
.day-section-title-row strong { font-size: 11px; }
.day-section-title-row span { color: var(--ink-soft); font-size: 9px; }
.agenda-section { margin-bottom: 18px; }
.day-agenda-grid { display: grid; gap: 5px; max-height: 390px; overflow: auto; padding-right: 3px; }
.agenda-slot { width: 100%; display: grid; grid-template-columns: 44px 1fr; gap: 8px; align-items: start; border: 1px solid var(--line); border-radius: 10px; padding: 7px 8px; background: #fff; text-align: left; }
.agenda-slot.free { border-style: dashed; background: #fbfdf9; }
.agenda-slot.busy { background: #f7faf7; }
.agenda-slot:hover { border-color: #8eb9aa; box-shadow: 0 4px 14px rgba(19, 42, 36, .08); }
.agenda-time { color: var(--forest-2); font-size: 10px; font-weight: 900; }
.agenda-slot-body { display: grid; gap: 4px; min-width: 0; }
.agenda-free-text { color: var(--ink-soft); font-size: 9px; }
.agenda-entry { display: grid; gap: 2px; border-radius: 8px; padding: 5px 7px; color: var(--ink); background: #eef5f1; font-size: 9px; line-height: 1.25; }
.agenda-entry b { color: var(--forest-2); font-size: 8px; }
.agenda-entry em { color: var(--ink-soft); font-style: normal; font-size: 8px; }
.agenda-entry.event { background: var(--purple-soft); }
.agenda-entry.review { background: var(--orange-soft); }
.agenda-entry.study { background: var(--mint); }
.day-status-note { border-radius: 11px; margin: 4px 0 10px; padding: 9px 11px; font-size: 10px; line-height: 1.45; }
.day-status-note.done { color: var(--forest-2); background: var(--mint); }
.day-status-note.missed { color: var(--danger); background: #fdecea; }
.day-task { display: flex; gap: 10px; border-bottom: 1px solid #edf0ee; padding: 10px 0; }
.day-task i { width: 8px; height: 8px; flex: 0 0 auto; margin-top: 5px; border-radius: 50%; background: var(--orange); }
.day-task.study i { background: var(--forest-2); }
.day-task strong { display: block; font-size: 11px; }
.day-task small { color: var(--ink-soft); font-size: 9px; }
.empty-mini { color: var(--ink-soft); font-size: 12px; line-height: 1.6; }

.radar-hero { border-radius: 22px; padding: 28px 32px; background: linear-gradient(125deg, #e4f2eb, #f4f6ee); }
.radar-score { min-width: 170px; text-align: right; }
.radar-score strong { display: block; font-family: Georgia, serif; font-size: 42px; font-weight: 500; }
.radar-score span { color: var(--ink-soft); font-size: 10px; }
.institution-panel { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 18px; padding: 20px; }
.institution-panel h3 { margin: 0; font-size: 15px; }
.institution-panel p { margin: 4px 0 0; color: var(--ink-soft); font-size: 11px; }
.chip-group { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.target-exam-panel { display: grid; grid-template-columns: .85fr 1.15fr; gap: 16px; margin-bottom: 18px; padding: 20px; }
.target-exam-panel h3 { margin: 0; font-size: 15px; }
.target-exam-panel p { margin: 4px 0 0; color: var(--ink-soft); font-size: 11px; line-height: 1.45; }
.target-exam-controls { display: grid; grid-template-columns: 1fr 1.35fr; gap: 10px; }
.target-exam-controls label span, .settings-panel label span { display: block; margin-bottom: 5px; color: var(--ink-soft); font-size: 9px; font-weight: 850; text-transform: uppercase; letter-spacing: .08em; }
.target-exam-controls select { width: 100%; min-height: 40px; border: 1px solid var(--line); border-radius: 10px; padding: 0 10px; background: #fff; color: var(--ink); font-size: 11px; }
.target-summary { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr auto; gap: 14px; border: 1px solid #dbe8e2; border-radius: 14px; padding: 14px; background: #fbfdf9; }
.target-summary.compact { display: block; margin: 10px 0 14px; }
.target-summary span { color: var(--forest-2); font-size: 9px; font-weight: 900; text-transform: uppercase; letter-spacing: .1em; }
.target-summary strong { display: block; margin-top: 4px; font-family: Georgia, serif; font-size: 20px; font-weight: 500; }
.target-summary p { margin: 7px 0 4px; color: var(--ink); font-size: 12px; }
.target-summary small { color: var(--ink-soft); font-size: 10px; line-height: 1.45; }
.target-source-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; align-content: start; }
.target-source-links a { border: 1px solid var(--line); border-radius: 999px; padding: 7px 10px; color: var(--forest-2); background: #fff; font-size: 9px; font-weight: 800; text-decoration: none; }
.chip { border: 1px solid var(--line); border-radius: 999px; padding: 8px 12px; color: var(--ink-soft); background: #fff; font-size: 10px; font-weight: 750; }
.chip.active { border-color: var(--forest-2); color: #fff; background: var(--forest-2); }
.area-tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.area-tabs button { border: 0; border-radius: 999px; padding: 8px 12px; color: var(--ink-soft); background: #f0f3f1; font-size: 10px; }
.area-tabs button.active { color: #fff; background: var(--forest-2); }
.radar-list { display: grid; gap: 1px; }
.radar-row { display: grid; grid-template-columns: minmax(220px, 1.3fr) minmax(150px, .8fr) 90px 100px; align-items: center; gap: 18px; border-top: 1px solid #edf0ee; padding: 15px 20px; }
.radar-row:first-child { border-top: 0; }
.radar-topic strong { display: block; font-size: 12px; }
.radar-topic span { color: var(--ink-soft); font-size: 9px; }
.priority-bar { height: 7px; overflow: hidden; border-radius: 20px; background: #e7ece9; }
.priority-bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--forest-2), #77b79e); }
.priority-label { font-size: 10px; font-weight: 800; }
.priority-label.high { color: var(--orange); }
.coverage-label { color: var(--ink-soft); font-size: 10px; text-align: right; }
.source-note { margin-top: 15px; border-left: 3px solid #8ebbaa; padding: 12px 16px; color: var(--ink-soft); font-size: 11px; line-height: 1.55; }
.source-note strong { color: var(--ink); }
.source-note p { margin: 4px 0 0; }

.osce-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 20px;
  border-radius: 24px;
  padding: 30px 34px;
  color: #fff;
  background:
    radial-gradient(circle at 86% 10%, rgba(146, 216, 190, .22), transparent 32%),
    linear-gradient(130deg, #123f37, #0d302b);
}

.osce-hero h2 {
  margin: 6px 0 8px;
  font-family: Georgia, serif;
  font-size: 38px;
  font-weight: 500;
}

.osce-hero p { max-width: 720px; margin: 0; color: #bed5cf; font-size: 13px; line-height: 1.6; }
.osce-hero .section-kicker { color: #a9cfc3; }
.osce-local-badge { display: flex; align-items: center; gap: 10px; border: 1px solid rgba(255,255,255,.14); border-radius: 13px; padding: 12px 14px; background: rgba(255,255,255,.08); }
.osce-local-badge .status-dot { box-shadow: 0 0 0 5px rgba(85, 161, 132, .16); }
.osce-local-badge strong, .osce-local-badge small { display: block; }
.osce-local-badge strong { font-size: 11px; }
.osce-local-badge small { margin-top: 3px; color: #a9c8c0; font-size: 9px; }

.osce-mode-bar { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 18px; padding: 17px 20px; }
.osce-mode-bar strong, .osce-mode-bar span { display: block; }
.osce-mode-bar strong { font-size: 12px; }
.osce-mode-bar span { margin-top: 4px; color: var(--ink-soft); font-size: 10px; }
.osce-mode-bar > div:last-child { display: flex; align-items: center; gap: 8px; }
.osce-mode-bar select { min-height: 43px; border: 1px solid var(--line); border-radius: 10px; padding: 0 11px; background: #fff; }

.osce-layout { min-height: 700px; display: grid; grid-template-columns: 330px minmax(0, 1fr); gap: 18px; }
.osce-library, .osce-stage { overflow: hidden; }
.osce-library-header { padding: 21px; border-bottom: 1px solid var(--line); }
.osce-library-header h3 { margin: 4px 0 14px; font-family: Georgia, serif; font-size: 20px; font-weight: 500; }
.osce-library-header select { width: 100%; min-height: 40px; border: 1px solid var(--line); border-radius: 10px; padding: 0 10px; background: #fff; }
.osce-station-list { max-height: 670px; overflow-y: auto; }
.osce-station-button { width: 100%; display: block; border: 0; border-bottom: 1px solid #edf0ee; padding: 16px 19px; background: transparent; text-align: left; }
.osce-station-button:hover, .osce-station-button.active { background: var(--mint-2); }
.osce-station-button span { display: block; color: var(--ink-soft); font-size: 9px; font-weight: 800; text-transform: uppercase; }
.osce-station-button strong { display: block; margin: 5px 0; font-size: 13px; line-height: 1.35; }
.osce-station-button small { color: #7d8f8a; font-size: 9px; }

.osce-stage { padding: 30px; }
.osce-welcome { max-width: 590px; display: grid; place-content: center; min-height: 620px; margin: auto; text-align: center; }
.osce-welcome-mark { width: 92px; height: 92px; display: grid; place-items: center; margin: auto; border-radius: 50%; color: #fff; background: var(--forest-2); font-family: Georgia, serif; font-size: 18px; letter-spacing: .12em; }
.osce-welcome h3 { margin: 22px 0 8px; font-family: Georgia, serif; font-size: 28px; font-weight: 500; }
.osce-welcome p { margin: 0; color: var(--ink-soft); font-size: 12px; line-height: 1.6; }
.osce-welcome ol { display: inline-grid; gap: 8px; margin: 20px auto; padding-left: 24px; color: var(--ink-soft); font-size: 11px; text-align: left; }
.osce-welcome small { color: #81918d; font-size: 9px; line-height: 1.5; }

.osce-runner-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.osce-runner-top h3 { margin: 4px 0 0; font-family: Georgia, serif; font-size: 24px; font-weight: 500; }
.osce-timebox { display: grid; justify-items: end; gap: 7px; }
.osce-clock { min-width: 84px; border-radius: 12px; padding: 10px 12px; color: #fff; background: var(--forest); font-family: Georgia, serif; font-size: 21px; text-align: center; }
.osce-clock.warning { background: var(--orange); }
.osce-clock.paused { background: #6f807c; }
.tiny-button { min-height: 30px; padding: 6px 11px; border-radius: 999px; font-size: 9px; }
.tiny-button.active { border-color: var(--orange); color: #fff; background: var(--orange); }
.osce-progress { height: 5px; margin: 18px 0 26px; overflow: hidden; border-radius: 99px; background: #e3e9e6; }
.osce-progress i { display: block; width: 0; height: 100%; background: linear-gradient(90deg, var(--forest-2), #83c8af); transition: width .25s ease; }

.osce-door { min-height: 470px; display: grid; align-content: center; justify-items: start; border: 2px solid var(--forest); border-radius: 18px; padding: clamp(25px, 5vw, 55px); background: #fff; }
.osce-door > span { color: var(--orange); font-size: 10px; font-weight: 900; letter-spacing: .13em; }
.osce-door p { max-width: 720px; margin: 16px 0; font-family: Georgia, serif; font-size: 26px; line-height: 1.45; }
.osce-door strong { max-width: 720px; margin-bottom: 24px; color: var(--ink-soft); font-size: 12px; line-height: 1.55; }

.stage-counter { color: var(--orange); font-size: 10px; font-weight: 900; letter-spacing: .1em; }
.osce-interaction h4 { margin: 8px 0; font-family: Georgia, serif; font-size: 27px; font-weight: 500; }
.osce-prompt { margin: 0 0 18px; color: var(--ink-soft); font-size: 13px; line-height: 1.6; }
.osce-choice-list { display: grid; gap: 8px; margin: 0 0 14px; }
.osce-choice { display: grid; grid-template-columns: 30px 1fr; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 13px; padding: 10px 12px; background: #fff; cursor: pointer; }
.osce-choice input { display: none; }
.osce-choice span { display: grid; width: 30px; height: 30px; place-content: center; border-radius: 999px; color: var(--forest-2); background: var(--mint); font-weight: 900; }
.osce-choice strong { font-size: 12px; line-height: 1.45; }
.osce-choice:has(input:checked), .osce-choice.selected { border-color: var(--forest-2); background: #f3faf4; box-shadow: 0 0 0 2px rgba(75, 143, 122, .12); }
.osce-choice.correct { border-color: #4b8f7a; background: #eef9f2; }
.osce-choice.correct span { color: #fff; background: #4b8f7a; }
.osce-choice.wrong-selected { border-color: #d97845; background: #fff6ef; }
.osce-choice.wrong-selected span { color: #fff; background: #d97845; }
.osce-answer-actions { display: flex; justify-content: space-between; gap: 10px; margin-top: 13px; }
.patient-response { margin-top: 18px; border-left: 4px solid var(--forest-2); border-radius: 0 14px 14px 0; padding: 18px 20px; background: var(--mint-2); }
.patient-response > span { color: var(--forest-2); font-size: 9px; font-weight: 900; letter-spacing: .12em; }
.patient-response p { margin: 8px 0 15px; font-family: Georgia, serif; font-size: 18px; line-height: 1.55; }
.patient-response p strong { color: var(--forest); }
.patient-response p em { color: var(--orange); font-style: normal; font-weight: 800; }
.professor-feedback { display: grid; gap: 10px; }
.professor-feedback p { margin: 0; font-family: "Segoe UI", sans-serif; font-size: 13px; line-height: 1.6; }
.professor-feedback ul { display: grid; gap: 8px; margin: 2px 0; padding-left: 18px; }
.professor-feedback li { font-size: 12px; line-height: 1.5; }
.professor-feedback li span { color: var(--ink-soft); }

.osce-result { position: relative; padding-top: 12px; }
.osce-score-ring { --score: 0deg; width: 130px; height: 130px; display: grid; place-content: center; float: right; margin: 0 0 20px 25px; border-radius: 50%; background: radial-gradient(circle closest-side, var(--paper) 78%, transparent 79%), conic-gradient(var(--forest-2) var(--score), #e2e9e6 0); text-align: center; }
.osce-score-ring strong { font-family: Georgia, serif; font-size: 30px; font-weight: 500; }
.osce-score-ring span { color: var(--ink-soft); font-size: 9px; }
.osce-result-copy h3 { margin: 6px 0; font-family: Georgia, serif; font-size: 28px; font-weight: 500; }
.osce-result-copy p { max-width: 630px; color: var(--ink-soft); font-size: 12px; line-height: 1.6; }
.osce-feedback-grid { clear: both; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 25px; }
.osce-feedback-grid > div { border: 1px solid var(--line); border-radius: 14px; padding: 17px; }
.osce-feedback-grid h4 { margin: 0 0 10px; font-size: 12px; }
.feedback-item { display: flex; gap: 8px; border-top: 1px solid #edf0ee; padding: 10px 0; color: var(--ink-soft); font-size: 10px; line-height: 1.45; }
.feedback-item:first-child { border-top: 0; }
.feedback-item i { width: 18px; height: 18px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--forest-2); font-size: 9px; font-style: normal; }
.feedback-item.missed i { background: var(--orange); }
.feedback-item strong { display: block; margin-bottom: 3px; color: var(--ink); font-size: 10px; }
.osce-result-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.osce-references { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.osce-references strong { display: block; margin-bottom: 9px; font-size: 10px; }
.osce-references a { display: block; margin-top: 5px; color: var(--forest-2); font-size: 9px; }
.osce-disclaimer { margin-top: 16px; }

.progress-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.progress-hero h2 { margin: 6px 0; font-family: Georgia, serif; font-size: 35px; font-weight: 500; }
.progress-hero p { max-width: 720px; margin: 0; color: var(--ink-soft); font-size: 12px; line-height: 1.6; }
.progress-hero select { min-height: 43px; border: 1px solid var(--line); border-radius: 10px; padding: 0 12px; background: #fff; }
.progress-dashboard { display: grid; grid-template-columns: 1.15fr .85fr; gap: 18px; margin-bottom: 18px; }
.progress-dashboard .chart-panel:nth-child(3) { grid-column: 1 / -1; }
.chart-panel { min-width: 0; padding: 23px; }
.chart-panel canvas { width: 100%; margin-top: 18px; }
.area-pie-panel { position: relative; }
.area-pie-panel .panel-header select { min-height: 38px; border: 1px solid var(--line); border-radius: 10px; padding: 0 11px; background: #fff; color: var(--ink); font-size: 10px; }
.area-pie-wrap { position: relative; width: min(260px, 100%); margin: 18px auto 8px; }
.area-pie-wrap canvas { display: block; width: 100%; max-width: 260px; aspect-ratio: 1; margin: 0 auto; }
.area-pie-center { position: absolute; inset: 50% auto auto 50%; transform: translate(-50%, -50%); width: 92px; height: 92px; display: grid; place-content: center; border-radius: 50%; background: var(--paper); text-align: center; box-shadow: 0 0 0 1px var(--line); }
.area-pie-center strong { font-family: Georgia, serif; font-size: 27px; font-weight: 500; line-height: 1; }
.area-pie-center span { margin-top: 4px; color: var(--ink-soft); font-size: 9px; text-transform: uppercase; letter-spacing: .08em; }
.area-pie-legend { display: grid; gap: 9px; margin-top: 16px; }
.area-pie-row { display: grid; grid-template-columns: 12px minmax(95px, .8fr) 1fr 42px; align-items: center; gap: 9px; }
.area-pie-row i { width: 11px; height: 11px; border-radius: 50%; }
.area-pie-row strong { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.area-pie-row .mini-track { height: 7px; overflow: hidden; border-radius: 999px; background: #e5ebe8; }
.area-pie-row .mini-track span { display: block; height: 100%; border-radius: inherit; }
.area-pie-row em { color: var(--ink-soft); font-size: 9px; font-style: normal; text-align: right; }
.area-pie-missing { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 12px; color: var(--ink-soft); font-size: 9px; line-height: 1.45; }
.area-pie-missing strong { display: block; margin-bottom: 4px; color: var(--ink); font-size: 10px; }
.discipline-bars { display: grid; gap: 14px; margin-top: 20px; }
.discipline-bar-row { display: grid; grid-template-columns: minmax(105px, .4fr) 1fr 44px; align-items: center; gap: 11px; }
.discipline-bar-row strong { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.discipline-bar-row span { color: var(--ink-soft); font-size: 9px; text-align: right; }
.discipline-track { height: 9px; overflow: hidden; border-radius: 99px; background: #e5ebe8; }
.discipline-track i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--forest-2), #83c5ad); }
.progress-recommendations { display: grid; grid-template-columns: repeat(3, 1fr); gap: 11px; margin-top: 18px; }
.progress-recommendation { border: 1px solid var(--line); border-radius: 12px; padding: 14px; background: #fafbf8; }
.progress-recommendation span { color: var(--orange); font-size: 9px; font-weight: 900; text-transform: uppercase; }
.progress-recommendation strong { display: block; margin: 5px 0; font-size: 11px; }
.progress-recommendation p { margin: 0; color: var(--ink-soft); font-size: 9px; line-height: 1.5; }

.event-task i { background: var(--purple); }
.calendar-event-badge { color: #5d528a; background: var(--purple-soft); }
.day-task button { margin-left: auto; border: 0; color: var(--danger); background: transparent; font-size: 16px; }
.account-summary { border: 1px solid var(--line); border-radius: 11px; padding: 12px; background: #f8faf8; }
.account-summary strong, .account-summary span { display: block; }
.account-summary strong { font-size: 11px; }
.account-summary span { margin-top: 3px; color: var(--ink-soft); font-size: 9px; }
.danger-outline { min-height: 43px; border: 1px solid #deb5b5; border-radius: 10px; color: var(--danger); background: #fff9f8; font-size: 11px; font-weight: 800; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.method-hero { max-width: 760px; margin-bottom: 26px; }
.method-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 18px; }
.method-card { min-height: 190px; border: 1px solid var(--line); border-radius: 17px; padding: 20px; background: var(--paper); }
.method-card > span { color: #8bb7a7; font-family: Georgia, serif; font-size: 25px; }
.method-card h3 { margin: 25px 0 8px; font-family: Georgia, serif; font-size: 19px; font-weight: 500; }
.method-card p { margin: 0; color: var(--ink-soft); font-size: 11px; line-height: 1.6; }
.settings-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 18px; margin-bottom: 18px; }
.settings-panel, .backup-panel, .evidence-panel { padding: 24px; }
.settings-panel form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 20px; }
.settings-panel label input, .settings-panel label select { width: 100%; }
.settings-panel form > button { align-self: end; }
.toggle-row { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.toggle-row span { margin: 0; }
.toggle-row strong, .toggle-row small { display: block; }
.toggle-row small { margin-top: 3px; color: var(--ink-soft); font-size: 9px; }
.toggle-row input { position: absolute; opacity: 0; }
.toggle-row i { position: relative; width: 42px; height: 24px; border-radius: 99px; background: #cad4d0; }
.toggle-row i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: .2s; }
.toggle-row input:checked + i { background: var(--forest-2); }
.toggle-row input:checked + i::after { transform: translateX(18px); }
.backup-panel > p { color: var(--ink-soft); font-size: 12px; line-height: 1.6; }
.backup-panel .full { margin-top: 9px; }
.file-button { position: relative; }
.file-button input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.backup-panel > small { display: block; margin-top: 15px; color: var(--ink-soft); font-size: 9px; line-height: 1.5; }
.evidence-list { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 18px; }
.evidence-list a { border: 1px solid var(--line); border-radius: 11px; padding: 13px; color: inherit; text-decoration: none; transition: .15s; }
.evidence-list a:hover { border-color: #91b9ab; background: var(--mint-2); }
.evidence-list strong, .evidence-list span { display: block; }
.evidence-list strong { font-size: 11px; }
.evidence-list span { margin-top: 4px; color: var(--ink-soft); font-size: 9px; }

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(7, 30, 27, .64);
  backdrop-filter: blur(5px);
}

.modal {
  width: min(560px, 100%);
  max-height: 92vh;
  overflow-y: auto;
  border-radius: 22px;
  padding: 26px;
  background: var(--paper);
  box-shadow: 0 28px 80px rgba(0,0,0,.24);
  animation: modal-in .25s ease;
}

@keyframes modal-in { from { opacity: 0; transform: translateY(12px) scale(.98); } }
.large-modal { width: min(880px, 100%); }
.modal-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.modal-header h2 { margin: 5px 0 0; font-family: Georgia, serif; font-weight: 500; }
.modal-close { width: 34px; height: 34px; border: 0; border-radius: 50%; background: #eff2f0; font-size: 21px; }
.modal-intro { color: var(--ink-soft); font-size: 12px; }
.modal form { display: grid; gap: 14px; margin-top: 20px; }
.modal form input, .modal form select { width: 100%; }
.modal form textarea { width: 100%; min-height: 100px; resize: vertical; border: 1px solid var(--line); border-radius: 10px; padding: 12px; outline: 0; }
.onboarding-card { width: min(470px, 100%); text-align: center; }
.onboarding-logo { width: 60px; height: 60px; display: grid; place-items: center; margin: 0 auto 18px; border-radius: 50%; color: #fff; background: var(--forest-2); font-size: 30px; font-weight: 200; }
.onboarding-card h2 { margin: 8px 0; font-family: Georgia, serif; font-size: 30px; font-weight: 500; }
.onboarding-card > p { margin: 0; color: var(--ink-soft); font-size: 12px; }
.onboarding-card form { text-align: left; }
.onboarding-card > small { display: block; margin-top: 13px; color: var(--ink-soft); font-size: 9px; }

.generated-cards-list { display: grid; gap: 10px; max-height: 53vh; overflow-y: auto; margin-top: 18px; padding-right: 4px; }
.generated-card { display: grid; grid-template-columns: 28px 1fr 1fr; gap: 10px; border: 1px solid var(--line); border-radius: 12px; padding: 12px; }
.generated-card input[type="checkbox"] { width: 17px; height: 17px; margin-top: 11px; accent-color: var(--forest-2); }
.generated-card textarea { width: 100%; min-height: 80px; resize: vertical; border: 1px solid var(--line); border-radius: 9px; padding: 10px; outline: 0; font-size: 11px; line-height: 1.45; }
.modal-footer { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 18px; }
.modal-footer > span { color: var(--ink-soft); font-size: 10px; }

.review-modal { width: min(750px, 100%); color: #fff; background: #113b35; }
.review-top { display: grid; grid-template-columns: 34px 1fr 45px; align-items: center; gap: 12px; }
.review-top .modal-close { color: #fff; background: rgba(255,255,255,.1); }
.review-progress { height: 5px; overflow: hidden; border-radius: 20px; background: rgba(255,255,255,.12); }
.review-progress i { display: block; width: 0; height: 100%; background: #9ad7c1; }
.review-top > span { color: #a9c8c0; font-size: 10px; text-align: right; }
.review-topic { margin: 24px 0 8px; color: #a9c8c0; font-size: 10px; font-weight: 750; letter-spacing: .08em; text-align: center; text-transform: uppercase; }
.review-card { width: 100%; min-height: 330px; display: flex; flex-direction: column; align-items: center; justify-content: center; border: 1px solid rgba(255,255,255,.15); border-radius: 20px; padding: 40px; color: var(--ink); background: #fffef9; box-shadow: 0 20px 50px rgba(0,0,0,.16); }
.card-side-label { color: #7c918c; font-size: 9px; font-weight: 800; letter-spacing: .14em; }
#review-front, #review-back { max-width: 590px; margin: 24px 0; font-family: Georgia, serif; font-size: 24px; line-height: 1.5; white-space: pre-wrap; }
#review-back { font-family: "Segoe UI", sans-serif; font-size: 17px; }
#review-hint { color: #8a9995; font-size: 10px; }
.rating-area { margin-top: 20px; text-align: center; }
.rating-area > p { color: #b9d0ca; font-size: 11px; }
.rating-buttons { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.rating-buttons button { border: 1px solid rgba(255,255,255,.13); border-radius: 10px; padding: 10px 8px; color: #fff; background: rgba(255,255,255,.08); }
.rating-buttons button:hover { background: rgba(255,255,255,.15); }
.rating-buttons strong, .rating-buttons small { display: block; }
.rating-buttons strong { font-size: 11px; }
.rating-buttons small { margin-top: 3px; color: #9ec0b7; font-size: 9px; }

.toast-container { position: fixed; z-index: 200; right: 22px; bottom: 22px; display: grid; gap: 9px; }
.toast { min-width: 240px; border-radius: 12px; padding: 13px 16px; color: #fff; background: #163f38; box-shadow: var(--shadow); font-size: 11px; animation: toast-in .2s ease; }
.toast.error { background: #933f3f; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

@media (max-width: 1100px) {
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .dashboard-grid, .calendar-layout { grid-template-columns: 1fr; }
  .method-grid { grid-template-columns: 1fr 1fr; }
  .progress-dashboard { grid-template-columns: 1fr; }
  .notes-layout { grid-template-columns: 230px minmax(0, 1fr); }
  .osce-layout { grid-template-columns: 285px minmax(0, 1fr); }
}

@media (max-width: 820px) {
  .auth-shell { grid-template-columns: 1fr; }
  .auth-visual { min-height: auto; padding: 50px 28px; }
  .auth-visual h1 { font-size: 40px; }
  .auth-panel { min-height: 520px; }
  .sidebar { transform: translateX(-100%); transition: transform .25s ease; }
  .sidebar.open { transform: translateX(0); box-shadow: 20px 0 50px rgba(0,0,0,.2); }
  .main-content { margin-left: 0; }
  .mobile-menu { display: block; }
  .view { padding: 24px 18px 45px; }
  .topbar { padding: 13px 18px; }
  .today-hero { padding: 30px; }
  .notes-layout { grid-template-columns: 1fr; }
  .notes-layout.editor-wide { grid-template-columns: 1fr; }
  .notes-layout.editor-wide .notes-list-panel { display: none; }
  .notes-list-panel { max-height: 300px; }
  .notes-list { max-height: 235px; }
  .settings-grid { grid-template-columns: 1fr; }
  .institution-panel { align-items: flex-start; flex-direction: column; }
  .target-exam-panel, .target-exam-controls, .target-summary { grid-template-columns: 1fr; }
  .target-source-links { justify-content: flex-start; }
  .osce-mode-bar { align-items: flex-start; flex-direction: column; }
  .osce-layout { grid-template-columns: 1fr; }
  .osce-station-list { max-height: 320px; }
  .chip-group { justify-content: flex-start; }
  .card-row { grid-template-columns: 1fr 1fr 80px 32px; }
}

@media (max-width: 600px) {
  .profile-copy { display: none; }
  .install-button { display: none !important; }
  .topbar h1 { font-size: 19px; }
  .today-hero { align-items: flex-start; flex-direction: column; }
  .hero-ring-wrap { align-self: center; }
  .hero-actions, .section-toolbar, .calendar-header, .cards-summary, .radar-hero { align-items: stretch; flex-direction: column; }
  .note-reader-toolbar, .progress-hero { align-items: stretch; flex-direction: column; }
  .note-reader-toolbar select, .progress-hero select { width: 100%; }
  .timer-field-grid, .timer-actions { grid-template-columns: 1fr; }
  .area-pie-panel .panel-header { align-items: stretch; flex-direction: column; }
  .area-pie-panel .panel-header select { width: 100%; }
  .cornell-layout { grid-template-columns: 1fr; }
  .cornell-cues { border-right: 0; border-bottom: 1px solid var(--line); }
  .cornell-summary { grid-column: 1; }
  .progress-recommendations { grid-template-columns: 1fr; }
  .osce-mode-bar > div:last-child { width: 100%; align-items: stretch; flex-direction: column; }
  .osce-mode-bar select, .osce-mode-bar button { width: 100%; }
  .form-grid { grid-template-columns: 1fr; }
  .section-toolbar > * { width: 100%; }
  .stat-grid, .method-grid, .weak-grid, .evidence-list { grid-template-columns: 1fr; }
  .stat-card { min-height: 95px; }
  .editor-meta, .settings-panel form { grid-template-columns: 1fr; }
  .note-focus-heading, .osce-hero { align-items: stretch; flex-direction: column; }
  .note-focus-columns, .osce-feedback-grid { grid-template-columns: 1fr; }
  .freshness-chip { align-self: flex-start; }
  .osce-answer-actions, .osce-result-actions { flex-direction: column; }
  .osce-answer-actions button, .osce-result-actions button { width: 100%; }
  .osce-score-ring { float: none; margin: 0 auto 20px; }
  .calendar-day { min-height: 70px; padding: 5px; }
  .day-badge { padding: 3px; font-size: 0; }
  .day-badge::before { content: "•"; font-size: 12px; }
  .radar-row { grid-template-columns: 1fr 80px; gap: 10px; }
  .radar-row .priority-bar { grid-column: 1 / -1; }
  .coverage-label { text-align: left; }
  .card-row { grid-template-columns: 1fr 34px; }
  .card-row .answer, .card-row .card-status { grid-column: 1; }
  .card-row .delete-card { grid-column: 2; grid-row: 1; }
  .generated-card { grid-template-columns: 25px 1fr; }
  .generated-card label:last-child { grid-column: 2; }
  .rating-buttons { grid-template-columns: 1fr 1fr; }
  .review-card { min-height: 300px; padding: 24px; }
  #review-front, #review-back { font-size: 20px; }
}
