:root {
  color-scheme: light;
  --ink: #16241f;
  --ink-soft: #405049;
  --muted: #78817d;
  --line: #e1e7e3;
  --surface: #ffffff;
  --surface-soft: #f7f9f7;
  --canvas: #f2f5f1;
  --green-900: #173f34;
  --green-800: #1d5544;
  --green-700: #246b55;
  --green-100: #e4f1eb;
  --green-50: #f0f7f3;
  --amber-700: #8a5a13;
  --amber-100: #faedcd;
  --red-700: #a13d38;
  --red-100: #fbe9e7;
  --shadow: 0 18px 50px rgba(31, 58, 47, 0.08);
  --shadow-soft: 0 8px 28px rgba(31, 58, 47, 0.06);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --sans:
    "Avenir Next", "Segoe UI", "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC",
    sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-width: 320px;
  background: var(--canvas);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.7) 0%, rgba(242, 245, 241, 0) 26%),
    var(--canvas);
}

button,
input,
select {
  font: inherit;
}

button {
  color: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

svg {
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.page-glow {
  position: fixed;
  z-index: -1;
  border-radius: 50%;
  filter: blur(2px);
  pointer-events: none;
}

.page-glow-one {
  top: -180px;
  right: -150px;
  width: 430px;
  height: 430px;
  background: radial-gradient(circle, rgba(189, 222, 207, 0.5), transparent 70%);
}

.page-glow-two {
  top: 530px;
  left: -240px;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, rgba(238, 220, 177, 0.24), transparent 70%);
}

.app-shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 26px 0 32px;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.brand {
  display: inline-flex;
  gap: 12px;
  align-items: center;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 15px;
  color: #f7fcf9;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.13), transparent 55%),
    var(--green-900);
  box-shadow: 0 8px 18px rgba(23, 63, 52, 0.2);
  font-family: "STKaiti", "KaiTi", var(--sans);
  font-size: 23px;
  font-weight: 700;
}

.brand-copy {
  display: grid;
  gap: 1px;
}

.brand-copy strong {
  font-size: 17px;
  letter-spacing: 0.02em;
}

.brand-copy small {
  color: var(--muted);
  font-size: 12px;
}

.topbar-actions {
  display: flex;
  gap: 9px;
}

.icon-button {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  gap: 7px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 2px 8px rgba(31, 58, 47, 0.03);
  cursor: pointer;
  font-size: 13px;
  font-weight: 650;
  transition:
    border-color 160ms ease,
    color 160ms ease,
    background 160ms ease,
    transform 160ms ease;
}

.icon-button:hover {
  border-color: #c9d7cf;
  color: var(--green-800);
  background: #fff;
  transform: translateY(-1px);
}

.icon-button svg {
  width: 18px;
  height: 18px;
}

.install-button {
  color: var(--green-800);
  border-color: #cce0d6;
  background: var(--green-50);
}

main {
  display: grid;
  gap: 22px;
}

.storage-warning {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 17px 20px;
  border: 1px solid #efc7c3;
  border-radius: var(--radius-md);
  color: var(--red-700);
  background: var(--red-100);
}

.storage-warning strong {
  display: block;
  margin-bottom: 3px;
}

.storage-warning p {
  margin: 0;
  color: #7b514e;
  font-size: 13px;
}

.hero {
  position: relative;
  display: grid;
  min-height: 292px;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 30px;
  overflow: hidden;
  padding: 42px 48px;
  border-radius: var(--radius-xl);
  color: #f4fbf7;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.04), transparent 35%),
    linear-gradient(135deg, #173f34 0%, #1c5a47 60%, #236951 100%);
  box-shadow: 0 24px 65px rgba(24, 60, 48, 0.19);
}

.hero::after {
  position: absolute;
  right: 180px;
  bottom: -110px;
  width: 320px;
  height: 230px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 50%;
  content: "";
  transform: rotate(-13deg);
}

.hero-orbit {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  pointer-events: none;
}

.hero-orbit-one {
  top: -98px;
  right: -54px;
  width: 300px;
  height: 300px;
}

.hero-orbit-two {
  top: -50px;
  right: -6px;
  width: 205px;
  height: 205px;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 670px;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 999px;
  color: #d8eee4;
  background: rgba(255, 255, 255, 0.07);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.06em;
}

.status-badge::before {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #e5c77e;
  box-shadow: 0 0 0 4px rgba(229, 199, 126, 0.1);
  content: "";
}

.status-badge.is-complete {
  color: #e8fff4;
}

.status-badge.is-complete::before {
  background: #83dab3;
  box-shadow: 0 0 0 4px rgba(131, 218, 179, 0.12);
}

.hero h1 {
  max-width: 680px;
  margin: 18px 0 10px;
  font-size: clamp(31px, 4vw, 48px);
  font-weight: 680;
  letter-spacing: -0.035em;
  line-height: 1.15;
}

.hero p {
  max-width: 610px;
  margin: 0;
  color: rgba(232, 246, 238, 0.72);
  font-size: 15px;
  line-height: 1.75;
}

.hero-summary {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-top: 28px;
}

.hero-requirement {
  display: grid;
  gap: 3px;
}

.hero-requirement span {
  color: rgba(230, 244, 236, 0.62);
  font-size: 12px;
}

.hero-requirement strong {
  color: #fff;
  font-size: 20px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}

.hero-divider {
  width: 1px;
  height: 38px;
  background: rgba(255, 255, 255, 0.15);
}

.credit-medallion {
  position: relative;
  z-index: 1;
  display: grid;
  width: 154px;
  height: 154px;
  place-content: center;
  justify-items: center;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 35%, rgba(255, 255, 255, 0.14), transparent 65%),
    rgba(255, 255, 255, 0.06);
  box-shadow:
    inset 0 0 0 8px rgba(255, 255, 255, 0.025),
    0 18px 40px rgba(5, 28, 20, 0.16);
  backdrop-filter: blur(6px);
}

.credit-medallion::before,
.credit-medallion::after {
  position: absolute;
  inset: 11px;
  border: 1px dashed rgba(255, 255, 255, 0.13);
  border-radius: 50%;
  content: "";
}

.credit-medallion::after {
  inset: 21px;
  border-style: solid;
  opacity: 0.5;
}

.credit-number {
  font-size: 50px;
  font-weight: 650;
  letter-spacing: -0.07em;
  line-height: 1;
}

.credit-divider {
  position: absolute;
  top: 58px;
  right: 37px;
  color: rgba(255, 255, 255, 0.54);
  font-size: 14px;
}

.credit-medallion small {
  margin-top: 7px;
  color: rgba(255, 255, 255, 0.63);
  font-size: 12px;
  letter-spacing: 0.15em;
}

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

.panel {
  border: 1px solid rgba(218, 226, 221, 0.82);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.91);
  box-shadow: var(--shadow-soft);
}

.progress-panel {
  padding: 26px 27px 24px;
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  gap: 13px;
}

.section-icon {
  display: grid;
  width: 39px;
  height: 39px;
  flex: 0 0 39px;
  place-items: center;
  border-radius: 12px;
}

.section-icon svg {
  width: 20px;
  height: 20px;
}

.section-icon-core {
  color: #7c5b1a;
  background: #faf0d8;
}

.section-icon-elective {
  color: var(--green-700);
  background: var(--green-100);
}

.panel h2 {
  margin: 1px 0 5px;
  font-size: 18px;
  letter-spacing: -0.015em;
}

.panel-header p,
.activity-header p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.completion-chip {
  flex: 0 0 auto;
  padding: 5px 9px;
  border-radius: 999px;
  color: var(--amber-700);
  background: var(--amber-100);
  font-size: 11px;
  font-weight: 700;
}

.completion-chip.is-complete {
  color: var(--green-700);
  background: var(--green-100);
}

.text-button {
  padding: 4px;
  border: 0;
  color: var(--green-700);
  background: transparent;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
}

.text-button:hover {
  color: var(--green-900);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.progress-number-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 15px;
  margin-top: 25px;
}

.progress-number-row div {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.progress-number-row strong {
  font-size: 32px;
  font-weight: 680;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.04em;
}

.progress-number-row span {
  color: var(--muted);
  font-size: 12px;
}

.progress-track {
  height: 7px;
  overflow: hidden;
  margin-top: 11px;
  border-radius: 999px;
  background: #edf1ee;
}

.progress-fill {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  transition: width 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

.progress-fill-core {
  background: linear-gradient(90deg, #d3ac52, #e2c373);
}

.progress-fill-elective {
  background: linear-gradient(90deg, #318263, #75b898);
}

.module-coverage {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  margin-top: 9px;
  color: var(--muted);
  font-size: 11px;
}

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

.module-tile {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
  padding: 10px 11px;
  border: 1px solid #e8ece9;
  border-radius: 12px;
  color: var(--ink-soft);
  background: var(--surface-soft);
}

.module-tile.is-complete {
  border-color: #d7e9e0;
  background: var(--green-50);
}

.module-check {
  display: grid;
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  place-items: center;
  border: 1px solid #d4dcd7;
  border-radius: 50%;
  color: #98a29d;
  background: #fff;
}

.module-check svg {
  width: 12px;
  height: 12px;
  stroke-width: 2.2;
}

.module-tile.is-complete .module-check {
  border-color: var(--green-700);
  color: #fff;
  background: var(--green-700);
}

.module-name {
  overflow: hidden;
  flex: 1;
  font-size: 12px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.module-count {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

.module-tile.is-complete .module-count {
  color: var(--green-700);
}

.elective-modules {
  display: grid;
  gap: 8px;
  margin-top: 20px;
}

.elective-module {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid #e7ebe8;
  border-radius: 12px;
  background: var(--surface-soft);
}

.elective-module.is-complete {
  border-color: #d7e9e0;
  background: var(--green-50);
}

.elective-status-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border: 1px solid #adb8b2;
  border-radius: 50%;
  background: transparent;
}

.elective-module.is-complete .elective-status-dot {
  border-color: var(--green-700);
  background: var(--green-700);
  box-shadow: 0 0 0 4px rgba(36, 107, 85, 0.09);
}

.elective-module strong {
  flex: 1;
  font-size: 12px;
}

.elective-module span:last-child {
  color: var(--muted);
  font-size: 10px;
}

.elective-module.is-complete span:last-child {
  color: var(--green-700);
}

.unselected-note {
  margin: 13px 0 0;
  padding: 8px 10px;
  border-radius: 9px;
  color: #725a24;
  background: #fcf5e6;
  font-size: 10px;
  line-height: 1.55;
}

.task-panel {
  padding: 28px 30px 30px;
}

.task-panel-header {
  align-items: center;
}

.eyebrow {
  display: block;
  margin-bottom: 5px;
  color: var(--green-700);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.task-count {
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--ink-soft);
  background: var(--surface-soft);
  font-size: 11px;
  font-weight: 650;
}

.task-list {
  display: grid;
  gap: 9px;
  margin-top: 20px;
}

.task-item {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  padding: 15px 16px;
  border: 1px solid #e8ece9;
  border-radius: 14px;
  background: linear-gradient(180deg, #fff, #fcfdfc);
}

.task-marker {
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  place-items: center;
  margin-top: 1px;
  border: 1px solid #d6dfd9;
  border-radius: 8px;
  color: var(--green-700);
  background: var(--green-50);
}

.task-marker svg {
  width: 13px;
  height: 13px;
}

.task-content {
  min-width: 0;
}

.task-content strong {
  display: block;
  font-size: 13px;
  line-height: 1.55;
}

.task-content p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}

.task-item.is-complete {
  align-items: center;
  justify-content: center;
  min-height: 95px;
  border-color: #d1e7db;
  color: var(--green-700);
  background: var(--green-50);
  text-align: center;
}

.task-item.is-complete strong {
  font-size: 15px;
}

.task-item.is-complete p {
  color: #53816d;
}

.task-complete-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--green-700);
}

.task-complete-icon svg {
  width: 18px;
  height: 18px;
  stroke-width: 2.2;
}

.activity-panel {
  overflow: hidden;
}

.activity-header {
  align-items: center;
  padding: 26px 29px 22px;
  border-bottom: 1px solid #ebefec;
}

.activity-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
}

.button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: 11px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 680;
  white-space: nowrap;
  transition:
    background 150ms ease,
    border-color 150ms ease,
    color 150ms ease,
    transform 150ms ease,
    box-shadow 150ms ease;
}

.button svg {
  width: 16px;
  height: 16px;
}

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

.button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
  transform: none;
}

.button-primary {
  color: #fff;
  background: var(--green-800);
  box-shadow: 0 6px 16px rgba(29, 85, 68, 0.18);
}

.button-primary:hover {
  background: var(--green-900);
  box-shadow: 0 8px 20px rgba(29, 85, 68, 0.22);
}

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

.button-ghost:hover {
  border-color: #cbd8d1;
  color: var(--green-800);
  background: var(--green-50);
}

.button-danger {
  border-color: #e8beba;
  color: var(--red-700);
  background: #fff6f5;
}

.button-small {
  min-height: 34px;
  padding: 0 12px;
  font-size: 11px;
}

.activity-list {
  display: grid;
}

.activity-item {
  display: grid;
  grid-template-columns: 67px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 17px 29px;
  border-bottom: 1px solid #edf0ee;
  transition: background 150ms ease;
}

.activity-item:hover {
  background: #fbfcfb;
}

.activity-date {
  display: grid;
  justify-items: center;
  gap: 1px;
  padding: 7px 5px;
  border-right: 1px solid #ebefec;
}

.activity-date strong {
  font-size: 22px;
  font-weight: 620;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.04em;
  line-height: 1;
}

.activity-date span {
  color: var(--muted);
  font-size: 10px;
}

.activity-main {
  min-width: 0;
}

.activity-main h3 {
  overflow: hidden;
  margin: 0 0 7px;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.module-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: 999px;
  color: var(--green-700);
  background: var(--green-50);
  font-size: 10px;
  font-weight: 650;
}

.module-pill.is-core {
  color: #76571a;
  background: #fbf3e1;
}

.module-pill::before {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.activity-actions {
  display: flex;
  gap: 3px;
  opacity: 0.65;
  transition: opacity 150ms ease;
}

.activity-item:hover .activity-actions,
.activity-actions:focus-within {
  opacity: 1;
}

.mini-icon-button {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 0;
  border-radius: 9px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}

.mini-icon-button:hover {
  color: var(--green-800);
  background: var(--green-50);
}

.mini-icon-button.delete:hover {
  color: var(--red-700);
  background: var(--red-100);
}

.mini-icon-button svg {
  width: 16px;
  height: 16px;
}

.empty-state {
  display: grid;
  justify-items: center;
  padding: 50px 24px 54px;
  text-align: center;
}

.empty-illustration {
  display: grid;
  width: 90px;
  height: 90px;
  place-items: center;
  margin-bottom: 17px;
  border-radius: 28px;
  color: var(--green-700);
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.8), transparent 45%),
    var(--green-50);
}

.empty-illustration svg {
  width: 58px;
  height: 58px;
  stroke-width: 1.4;
}

.empty-state h3 {
  margin: 0 0 7px;
  font-size: 17px;
}

.empty-state p {
  max-width: 420px;
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

.rule-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 4px 8px 2px;
  color: #6d7772;
}

.rule-note svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  margin-top: 1px;
}

.rule-note p {
  margin: 0;
  font-size: 11px;
  line-height: 1.65;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 28px 4px 4px;
  color: #8b948f;
  font-size: 10px;
}

.modal {
  width: min(620px, calc(100% - 28px));
  max-height: calc(100dvh - 40px);
  padding: 0;
  overflow: auto;
  border: 0;
  border-radius: 24px;
  color: var(--ink);
  background: #fff;
  box-shadow: 0 30px 90px rgba(17, 40, 31, 0.25);
}

.modal::backdrop {
  background: rgba(14, 36, 28, 0.52);
  backdrop-filter: blur(5px);
}

.modal[open] {
  animation: modal-in 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

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

.modal-card {
  padding: 30px;
}

.modal-kicker {
  margin-bottom: 8px;
  color: var(--green-700);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.12em;
}

.modal h2 {
  margin: 0 0 8px;
  font-size: 24px;
  letter-spacing: -0.025em;
}

.modal p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.7;
}

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

.selection-option {
  position: relative;
  display: flex;
  min-height: 76px;
  align-items: flex-start;
  gap: 10px;
  padding: 13px;
  border: 1px solid #e2e8e4;
  border-radius: 14px;
  background: #fbfcfb;
  cursor: pointer;
  transition:
    border-color 150ms ease,
    background 150ms ease,
    box-shadow 150ms ease;
}

.selection-option:hover {
  border-color: #c8d9d0;
  background: var(--green-50);
}

.selection-option:has(input:checked) {
  border-color: #8ab9a4;
  background: var(--green-50);
  box-shadow: inset 0 0 0 1px rgba(36, 107, 85, 0.08);
}

.selection-option:has(input:disabled:not(:checked)) {
  cursor: not-allowed;
  opacity: 0.46;
}

.selection-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.selection-check {
  display: grid;
  width: 21px;
  height: 21px;
  flex: 0 0 21px;
  place-items: center;
  margin-top: 1px;
  border: 1px solid #cbd5cf;
  border-radius: 7px;
  color: transparent;
  background: #fff;
}

.selection-check svg {
  width: 13px;
  height: 13px;
  stroke-width: 2.3;
}

.selection-option input:checked + .selection-check {
  border-color: var(--green-700);
  color: #fff;
  background: var(--green-700);
}

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

.selection-copy strong {
  font-size: 12px;
}

.selection-copy small {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.45;
}

.selection-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-top: 24px;
  padding-top: 19px;
  border-top: 1px solid #edf0ee;
}

.selection-footer > span {
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 650;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 24px;
}

.selection-footer .modal-actions {
  margin-top: 0;
}

.field {
  display: grid;
  gap: 7px;
  margin-top: 20px;
}

.field > span {
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 650;
}

.field input,
.field select {
  width: 100%;
  height: 46px;
  padding: 0 13px;
  border: 1px solid #dce3df;
  border-radius: 11px;
  outline: none;
  color: var(--ink);
  background: #fbfcfb;
  font-size: 13px;
  transition:
    border-color 150ms ease,
    box-shadow 150ms ease,
    background 150ms ease;
}

.field input:focus,
.field select:focus {
  border-color: #78a994;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(55, 126, 98, 0.09);
}

.field input::placeholder {
  color: #a8b0ac;
}

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

.report-list {
  display: grid;
  max-height: 260px;
  gap: 7px;
  margin-top: 18px;
  overflow: auto;
}

.report-item {
  padding: 9px 11px;
  border-radius: 9px;
  color: #725a24;
  background: #fcf5e6;
  font-size: 11px;
  line-height: 1.55;
}

.report-item.is-error {
  color: var(--red-700);
  background: var(--red-100);
}

.toast-region {
  position: fixed;
  z-index: 50;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  display: grid;
  justify-items: end;
  gap: 8px;
  pointer-events: none;
}

.toast {
  max-width: min(380px, calc(100vw - 40px));
  padding: 12px 15px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  color: #f5fbf7;
  background: #203a30;
  box-shadow: 0 12px 34px rgba(16, 42, 32, 0.24);
  font-size: 12px;
  line-height: 1.55;
  animation: toast-in 220ms ease;
}

.toast.is-error {
  background: #843f3a;
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(44, 123, 94, 0.28);
  outline-offset: 2px;
}

@media (max-width: 860px) {
  .app-shell {
    width: min(100% - 28px, 720px);
    padding-top: 19px;
  }

  .hero {
    min-height: 280px;
    padding: 35px 32px;
  }

  .credit-medallion {
    width: 132px;
    height: 132px;
  }

  .credit-number {
    font-size: 44px;
  }

  .credit-divider {
    top: 51px;
    right: 30px;
  }

  .progress-grid {
    grid-template-columns: 1fr;
  }

  .activity-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .activity-toolbar {
    width: 100%;
    flex-wrap: wrap;
  }

  .activity-toolbar .button-primary {
    margin-left: auto;
  }
}

@media (max-width: 620px) {
  .app-shell {
    width: calc(100% - 22px);
    padding-top: max(13px, env(safe-area-inset-top));
    padding-bottom: max(22px, env(safe-area-inset-bottom));
  }

  .topbar {
    margin-bottom: 16px;
  }

  .brand-mark {
    width: 41px;
    height: 41px;
    border-radius: 13px;
    font-size: 21px;
  }

  .brand-copy small {
    display: none;
  }

  .brand-copy strong {
    font-size: 15px;
  }

  .icon-button {
    width: 39px;
    min-height: 39px;
    justify-content: center;
    padding: 0;
  }

  .icon-button span {
    display: none;
  }

  main {
    gap: 15px;
  }

  .storage-warning {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero {
    min-height: 0;
    grid-template-columns: 1fr;
    gap: 25px;
    padding: 29px 24px 27px;
    border-radius: 24px;
  }

  .hero h1 {
    margin-top: 14px;
    font-size: 30px;
    line-height: 1.22;
  }

  .hero p {
    font-size: 13px;
    line-height: 1.65;
  }

  .hero-summary {
    margin-top: 22px;
  }

  .credit-medallion {
    display: flex;
    width: auto;
    height: auto;
    justify-self: start;
    gap: 2px;
    padding: 9px 16px;
    border-radius: 999px;
    box-shadow: inset 0 0 0 4px rgba(255, 255, 255, 0.025);
  }

  .credit-medallion::before,
  .credit-medallion::after {
    display: none;
  }

  .credit-number {
    font-size: 24px;
    letter-spacing: -0.03em;
  }

  .credit-divider {
    position: static;
    font-size: 12px;
  }

  .credit-medallion small {
    margin: 0 0 0 2px;
    letter-spacing: 0.06em;
  }

  .progress-panel {
    padding: 22px 19px 20px;
  }

  .panel-header {
    gap: 10px;
  }

  .panel-heading {
    gap: 10px;
  }

  .section-icon {
    width: 35px;
    height: 35px;
    flex-basis: 35px;
  }

  .panel h2 {
    font-size: 16px;
  }

  .panel-header p {
    font-size: 10px;
  }

  .completion-chip {
    font-size: 10px;
  }

  .progress-number-row {
    margin-top: 21px;
  }

  .progress-number-row strong {
    font-size: 29px;
  }

  .module-grid {
    gap: 7px;
  }

  .module-tile {
    padding: 9px;
  }

  .module-name {
    font-size: 11px;
  }

  .module-coverage {
    font-size: 10px;
  }

  .task-panel {
    padding: 22px 19px 20px;
  }

  .task-item {
    padding: 13px;
  }

  .activity-header {
    padding: 22px 19px 17px;
  }

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

  .activity-toolbar .button-primary {
    grid-column: 1 / -1;
    grid-row: 1;
    margin-left: 0;
  }

  .activity-toolbar .button {
    width: 100%;
  }

  .activity-item {
    grid-template-columns: 49px minmax(0, 1fr) auto;
    gap: 12px;
    padding: 14px 17px;
  }

  .activity-date strong {
    font-size: 19px;
  }

  .activity-main h3 {
    font-size: 13px;
  }

  .activity-actions {
    gap: 0;
    opacity: 1;
  }

  .mini-icon-button {
    width: 31px;
    height: 31px;
  }

  .empty-state {
    padding: 40px 20px 43px;
  }

  .rule-note {
    padding: 0 4px;
  }

  footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
    padding-top: 23px;
  }

  .modal {
    width: calc(100% - 18px);
    max-height: calc(100dvh - 18px);
    border-radius: 21px;
  }

  .modal-card {
    padding: 24px 19px;
  }

  .modal h2 {
    font-size: 21px;
  }

  .selection-grid {
    grid-template-columns: 1fr;
    gap: 7px;
    margin-top: 20px;
  }

  .selection-option {
    min-height: 65px;
    padding: 11px;
  }

  .selection-footer {
    align-items: stretch;
    flex-direction: column;
    gap: 13px;
  }

  .selection-footer .modal-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .field-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .toast-region {
    right: 11px;
    bottom: max(11px, env(safe-area-inset-bottom));
    left: 11px;
    justify-items: stretch;
  }

  .toast {
    max-width: none;
  }
}

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