/* Recall V5: Minimalist Illustrated Sky Workspace (Web & Mobile) */
:root {
  --bg: #dff0fc;
  --ink: #1e3150;
  --ink-soft: #364f73;
  --muted: #69839f;
  --subtle: #8ca4bd;
  --line: rgba(158, 190, 218, 0.36);
  --card: rgba(255, 255, 255, 0.9);
  --card-solid: #ffffff;
  --primary: #1e2f4d;
  --primary-hover: #2b4268;
  --soft-bg: #e6f2fc;
  --soft-ink: #355880;
  --warning-bg: #fff4e5;
  --warning-ink: #b86b19;
  --green-bg: #e7f6ef;
  --green-ink: #1f7a54;
  --danger: #c84343;
  --shadow: 0 10px 28px rgba(30, 49, 80, 0.06), 0 2px 6px rgba(30, 49, 80, 0.03);
  --shadow-lg: 0 18px 44px rgba(30, 49, 80, 0.09), 0 4px 12px rgba(30, 49, 80, 0.04);
  --radius: 16px;
  --serif: Georgia, "Times New Roman", "Songti SC", "Noto Serif SC", serif;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font: 14px/1.6 "Segoe UI Variable", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, p {
  margin: 0;
}

button {
  cursor: pointer;
  border: 1px solid rgba(154, 184, 212, 0.45);
  background: rgba(255, 255, 255, 0.85);
  color: var(--ink);
  border-radius: 10px;
  min-height: 40px;
  padding: 8px 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
  transition: background 160ms ease, border-color 160ms ease, box-shadow 160ms ease, color 160ms ease;
}

button:hover {
  background: #ffffff;
  border-color: rgba(120, 158, 194, 0.7);
}

button:active {
  opacity: 0.88;
}

button:disabled {
  opacity: 0.45;
  cursor: default;
}

button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, [role="button"]:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
  font-weight: 500;
}

.primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  color: #ffffff;
}

.soft {
  background: var(--soft-bg);
  border-color: rgba(145, 182, 214, 0.45);
  color: var(--soft-ink);
  font-weight: 500;
}

.soft:hover {
  background: #daecfb;
}

.quiet {
  border-color: transparent;
  background: transparent;
  color: var(--muted);
}

.quiet:hover {
  background: rgba(255, 255, 255, 0.55);
  border-color: transparent;
  color: var(--ink);
}

.danger {
  color: var(--danger);
}

.pill-btn {
  border-radius: 999px;
  padding-inline: 20px;
}

svg.icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

.muted {
  color: var(--muted);
  font-size: 13px;
}

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

/* App Shell & Sidebar */
.shell {
  display: grid;
  grid-template-columns: 224px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  background: rgba(244, 250, 255, 0.86);
  backdrop-filter: blur(16px);
  border-right: 1px solid var(--line);
  padding: 26px 16px 20px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 5;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 10px;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.8px;
  color: var(--ink);
}

.logo-mark {
  width: 28px;
  height: 28px;
  border: 1.6px solid var(--ink);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--ink);
}

.logo-mark svg {
  width: 18px;
  height: 18px;
}

.sidebar-new {
  margin: 24px 6px 18px;
  border-radius: 999px;
  min-height: 42px;
  font-size: 13px;
  box-shadow: 0 6px 16px rgba(30, 47, 77, 0.14);
}

.sidebar nav {
  display: grid;
  gap: 4px;
}

.nav-item {
  border: 0;
  background: transparent;
  color: var(--muted);
  justify-content: flex-start;
  min-height: 42px;
  padding: 0 14px;
  border-radius: 11px;
  font-size: 13px;
  font-weight: 500;
  position: relative;
}

.nav-item:hover {
  background: rgba(218, 235, 250, 0.55);
  color: var(--ink);
}

.nav-item.selected {
  background: #dfeefb;
  color: var(--ink);
  font-weight: 600;
}

.count {
  margin-left: auto;
  background: rgba(255, 255, 255, 0.85);
  color: var(--soft-ink);
  font-size: 11px;
  font-weight: 600;
  padding: 1px 8px;
  border-radius: 999px;
}

.count.accent {
  background: var(--primary);
  color: #ffffff;
}

.sidebar-bottom {
  margin-top: auto;
  display: grid;
  gap: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.profile {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 11px;
  cursor: pointer;
  transition: background 160ms ease;
}

.profile:hover {
  background: rgba(218, 235, 250, 0.55);
}

.profile-meta strong {
  display: block;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.3;
}

.profile-meta small {
  display: block;
  font-size: 11px;
  color: var(--muted);
}

.avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #bed7ec;
  color: #274466;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 600;
  flex: none;
}

.avatar.large {
  width: 48px;
  height: 48px;
  font-size: 16px;
}

.avatar-btn {
  border: 0;
  background: transparent;
  padding: 0;
  min-height: 36px;
  width: 36px;
  border-radius: 50%;
}

/* Workspace & Illustrated Background */
.workspace {
  min-width: 0;
  min-height: 100vh;
  position: relative;
  overflow: hidden;
  background: #dff0fc url('blue-ribbons.svg') center top / cover no-repeat;
  display: flex;
  flex-direction: column;
}

.ambient-art {
  position: absolute;
  top: 16px;
  right: 2%;
  width: 540px;
  max-width: 52vw;
  opacity: 0.48;
  pointer-events: none;
  z-index: 0;
}

.ambient-art img {
  width: 100%;
  height: auto;
  display: block;
}

.workspace[data-page="today"] .ambient-art {
  display: none;
}

.topbar {
  height: 64px;
  padding: 0 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 2;
}

.topbar-date {
  font-size: 11px;
  letter-spacing: 0.8px;
  font-weight: 600;
  color: var(--muted);
}

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

.top-add {
  border-radius: 999px;
  min-height: 36px;
  padding: 6px 14px;
  font-size: 12px;
  background: rgba(255, 255, 255, 0.78);
}

.icon-btn {
  width: 38px;
  height: 38px;
  min-height: 38px;
  padding: 0;
  border-radius: 50%;
  position: relative;
}

.dot {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e06d53;
  border: 1.5px solid #ffffff;
}

.main {
  flex: 1;
  width: 100%;
  max-width: 1040px;
  margin: 0 auto;
  padding: 8px 44px 56px;
  position: relative;
  z-index: 1;
}

/* Home Page (Sky Hero + Task Cards) */
.sky-home {
  max-width: 880px;
  margin: 0 auto;
}

.sky-date {
  display: none;
}

.sky-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0 0 24px;
}

.sky-art-wrap {
  width: 100%;
  max-width: 470px;
  margin: -10px auto -18px;
  pointer-events: none;
}

.sky-illustration {
  width: 100%;
  height: auto;
  display: block;
}

.sky-focus {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.sky-count {
  font: 500 88px/1 var(--serif);
  letter-spacing: -3px;
  color: var(--ink);
  margin: 0 0 8px;
}

.sky-focus h1 {
  font-size: 20px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: 0.3px;
}

.sky-start {
  margin-top: 22px;
  min-height: 50px;
  width: 300px;
  max-width: 100%;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  padding: 12px 26px;
  box-shadow: 0 10px 24px rgba(30, 47, 77, 0.18);
}

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

.sky-task {
  background: var(--card);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 16px;
  padding: 18px 20px;
  box-shadow: var(--shadow);
  min-width: 0;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.sky-task:hover {
  background: var(--card-solid);
  box-shadow: var(--shadow-lg);
}

.sky-overline {
  display: block;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.9px;
  color: var(--subtle);
  margin-bottom: 6px;
}

.sky-task-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sky-task-number {
  font-size: 12px;
  font-weight: 600;
  color: var(--subtle);
  align-self: flex-start;
  line-height: 26px;
  flex: none;
}

.sky-task-copy {
  flex: 1;
  min-width: 0;
}

.summary-button {
  border: 0;
  background: transparent;
  padding: 0;
  min-height: 26px;
  width: 100%;
  text-align: left;
  justify-content: flex-start;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

.summary-button:hover {
  background: transparent;
  color: var(--soft-ink);
}

.sky-task-copy p {
  font-size: 11px;
  color: var(--muted);
  margin-top: 5px;
}

.sky-task-go {
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  border-radius: 50%;
  border: 0;
  background: rgba(226, 240, 252, 0.65);
  color: var(--soft-ink);
  padding: 0;
  flex: none;
}

.sky-task-go:hover {
  background: var(--primary);
  color: #ffffff;
}

.sky-more {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 18px;
  padding: 0 4px;
  font-size: 12px;
  color: var(--muted);
}

.sky-more button {
  font-size: 12px;
  min-height: 34px;
  padding: 4px 10px;
}

/* Sub-Pages Common Layout */
.page-wrap {
  max-width: 920px;
  margin: 0 auto;
}

.narrow-wrap {
  max-width: 680px;
}

.page-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 22px;
}

.page-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.page-bar h1 {
  font-size: 26px;
  font-weight: 650;
  letter-spacing: -0.5px;
  color: var(--ink);
}

/* Pills & Tags */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--soft-bg);
  color: var(--soft-ink);
  white-space: nowrap;
}

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

.pill.warning {
  background: var(--warning-bg);
  color: var(--warning-ink);
}

.pill.gray {
  background: rgba(212, 224, 235, 0.6);
  color: var(--muted);
}

/* Knowledge Base Page */
.filterbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.tabs {
  display: inline-flex;
  padding: 4px;
  background: rgba(255, 255, 255, 0.76);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 999px;
  gap: 2px;
}

.tabs button {
  border: 0;
  background: transparent;
  min-height: 32px;
  padding: 4px 14px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--muted);
  gap: 5px;
}

.tabs button small {
  font-size: 11px;
  opacity: 0.75;
}

.tabs button.active {
  background: var(--primary);
  color: #ffffff;
  font-weight: 600;
}

.search {
  position: relative;
}

.search input {
  width: 210px;
  min-height: 40px;
  padding: 8px 14px 8px 36px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(10px);
  font-size: 13px;
  box-shadow: 0 4px 14px rgba(30, 49, 80, 0.04);
}

.search svg {
  position: absolute;
  left: 13px;
  top: 11px;
  width: 16px;
  height: 16px;
  color: var(--muted);
}

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

.k-card {
  background: var(--card);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
  transition: box-shadow 160ms ease, background 160ms ease;
}

.k-card:hover {
  background: var(--card-solid);
  box-shadow: var(--shadow-lg);
}

.k-meta {
  font-size: 12px;
  color: var(--muted);
}

.k-title {
  border: 0;
  background: transparent;
  padding: 0;
  min-height: 0;
  text-align: left;
  justify-content: flex-start;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.55;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
  width: 100%;
}

.k-title:hover {
  background: transparent;
  color: var(--soft-ink);
}

.k-card-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
}

.k-foot-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.k-action {
  border: 0;
  background: rgba(230, 242, 252, 0.65);
  min-height: 32px;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  color: var(--soft-ink);
  gap: 4px;
  flex: none;
}

.k-action.due {
  background: var(--primary);
  color: #ffffff;
}

.k-action:hover {
  background: var(--primary-hover);
  color: #ffffff;
}

.k-action svg {
  width: 14px;
  height: 14px;
}

/* Review Flashcard Stage */
.review-stage {
  max-width: 640px;
  margin: 12px auto 0;
}

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

.compact-btn {
  padding: 6px 10px;
  min-height: 36px;
  font-size: 13px;
}

.review-progress-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(10px);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--ink-soft);
  white-space: nowrap;
  flex: none;
  box-shadow: 0 4px 12px rgba(30, 49, 80, 0.04);
}

.mini-track {
  width: 56px;
  height: 5px;
  background: #d7e7f5;
  border-radius: 999px;
  overflow: hidden;
}

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

.review-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(18px);
  border: 1px solid #ffffff;
  border-radius: 24px;
  padding: 32px 36px;
  box-shadow: var(--shadow-lg);
}

.review-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}

.review-content {
  font-size: 18px;
  line-height: 1.9;
  color: var(--ink);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  min-height: 170px;
  padding: 6px 0 26px;
}

.review-card-foot {
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.feedback-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.fb-btn {
  flex-direction: column;
  gap: 4px;
  min-height: 66px;
  padding: 12px 10px;
  border-radius: 14px;
  background: #f4f9fd;
  border-color: rgba(154, 186, 214, 0.45);
}

.fb-btn strong {
  font-size: 14px;
}

.fb-btn small {
  font-size: 11px;
  opacity: 0.78;
}

.fb-btn.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
}

/* Statistics Page */
.stat-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.stat-card {
  background: var(--card);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: var(--radius);
  padding: 20px 22px;
  box-shadow: var(--shadow);
}

.stat-card span {
  display: block;
  font-size: 12px;
  color: var(--muted);
}

.stat-card strong {
  display: block;
  font: 500 38px/1.2 var(--serif);
  color: var(--ink);
  margin-top: 6px;
}

.stat-split {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 16px;
}

.glass-card {
  background: var(--card);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: var(--radius);
  padding: 22px 24px;
  box-shadow: var(--shadow);
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.card-head h2 {
  font-size: 15px;
  font-weight: 600;
}

.chart {
  height: 170px;
  display: flex;
  align-items: flex-end;
  gap: 12px;
  padding-top: 12px;
}

.bar-col {
  flex: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.bar-col small {
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
}

.bar-track {
  flex: 1;
  width: 100%;
  max-width: 28px;
  background: rgba(206, 226, 244, 0.45);
  border-radius: 999px;
  display: flex;
  align-items: flex-end;
  padding: 3px;
}

.bar {
  width: 100%;
  background: #9ec2e0;
  border-radius: 999px;
  transition: height 240ms ease;
}

.bar.today {
  background: var(--primary);
}

.bar-day {
  font-size: 11px;
  color: var(--muted);
}

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

.recent-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

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

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

.recent-main strong {
  display: block;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.recent-main small {
  font-size: 11px;
  color: var(--muted);
}

.fb-tag {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--soft-bg);
  color: var(--soft-ink);
  flex: none;
}

.fb-tag.remembered {
  background: var(--green-bg);
  color: var(--green-ink);
}

.fb-tag.fuzzy {
  background: var(--warning-bg);
  color: var(--warning-ink);
}

/* Notifications Page */
.msg-list {
  display: grid;
  gap: 14px;
}

.msg-card {
  display: flex;
  align-items: center;
  gap: 16px;
}

.msg-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--soft-bg);
  color: var(--soft-ink);
  display: grid;
  place-items: center;
  position: relative;
  flex: none;
}

.unread-dot {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #e06d53;
  border: 2px solid #ffffff;
}

.msg-body {
  flex: 1;
  min-width: 0;
}

.msg-body h3 {
  font-size: 15px;
  font-weight: 600;
}

.msg-date {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-top: 3px;
}

/* Settings Page */
.settings-stack {
  display: grid;
  gap: 14px;
}

.profile-card {
  display: flex;
  align-items: center;
  gap: 14px;
}

.profile-info {
  flex: 1;
  min-width: 0;
}

.profile-info h2 {
  font-size: 17px;
}

.profile-info p {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

.pref-card {
  padding-block: 6px 18px;
}

.pref-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.pref-row h3 {
  font-size: 14px;
  font-weight: 600;
}

.pref-row select {
  min-height: 36px;
  padding: 6px 12px;
  border-radius: 10px;
  border: 1px solid rgba(145, 180, 210, 0.55);
  background: #ffffff;
  font-size: 13px;
}

.switch-toggle {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 26px;
  margin: 0;
  cursor: pointer;
  flex: none;
}

.switch-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  inset: 0;
  background: #cbdbe9;
  border-radius: 999px;
  transition: background 180ms ease;
}

.slider:before {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  left: 3px;
  top: 3px;
  background: #ffffff;
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
  transition: transform 180ms ease;
}

.switch-toggle input:checked + .slider {
  background: var(--primary);
}

.switch-toggle input:checked + .slider:before {
  transform: translateX(20px);
}

.stat-link {
  width: 100%;
  justify-content: space-between;
  border: 0;
  background: transparent;
  padding: 0;
  font-size: 14px;
  font-weight: 600;
}

.pref-foot {
  padding-top: 16px;
  display: flex;
  justify-content: flex-end;
}

.demo-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.45);
  font-size: 12px;
  color: var(--muted);
}

.demo-btns {
  display: flex;
  gap: 6px;
}

.demo-btns button {
  min-height: 30px;
  padding: 4px 10px;
  font-size: 12px;
}

/* Empty Card & Login */
.empty-card {
  background: var(--card);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 20px;
  padding: 44px 24px;
  text-align: center;
  box-shadow: var(--shadow);
  grid-column: 1 / -1;
}

.empty-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--soft-bg);
  color: var(--soft-ink);
  display: grid;
  place-items: center;
  margin: 0 auto 14px;
}

.empty-card h2 {
  font-size: 17px;
  margin-bottom: 6px;
}

.empty-card p {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 20px;
}

.center-actions {
  display: flex;
  justify-content: center;
  margin-top: 18px;
}

.login-stage {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background: #dff0fc url('blue-ribbons.svg') center top / cover no-repeat;
}

.login-card {
  width: 100%;
  max-width: 390px;
  padding: 34px 30px;
  border-radius: 22px;
}

.login-card .logo {
  padding: 0;
  margin-bottom: 22px;
}

.login-card h1 {
  font-size: 22px;
  margin-bottom: 6px;
}

.login-card label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin: 16px 0 6px;
}

.login-card input {
  width: 100%;
  min-height: 42px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(145, 180, 210, 0.55);
}

.full-btn {
  width: 100%;
  margin-top: 14px;
}

.error {
  color: var(--danger);
  font-size: 12px;
  margin-top: 8px;
}

/* Dialog / Drawer */
dialog {
  position: fixed;
  inset: 0 0 0 auto;
  margin: 0;
  width: 520px;
  max-width: 100%;
  height: 100dvh;
  max-height: 100dvh;
  padding: 0;
  border: 0;
  border-left: 1px solid rgba(255, 255, 255, 0.8);
  background: rgba(248, 252, 255, 0.96);
  backdrop-filter: blur(20px);
  color: var(--ink);
  box-shadow: -16px 0 40px rgba(30, 49, 80, 0.12);
  overflow: auto;
}

dialog::backdrop {
  background: rgba(24, 40, 66, 0.25);
  backdrop-filter: blur(3px);
}

.dialog-body {
  padding: 28px 30px;
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

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

.dialog-top h2 {
  font-size: 19px;
}

.dialog-badges {
  display: flex;
  align-items: center;
  gap: 10px;
}

textarea {
  width: 100%;
  min-height: 260px;
  padding: 16px;
  border-radius: 14px;
  border: 1px solid rgba(145, 180, 210, 0.5);
  background: #ffffff;
  font-size: 15px;
  line-height: 1.85;
  resize: vertical;
}

.editor-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted);
}

.editor-meta span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.editor-meta svg {
  width: 14px;
  height: 14px;
}

.detail-reader {
  background: #ffffff;
  border-radius: 16px;
  padding: 22px 24px;
  font-size: 16px;
  line-height: 1.9;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  box-shadow: var(--shadow);
}

.detail-schedule {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
  padding: 14px 18px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 12px;
  font-size: 13px;
}

.detail-schedule span {
  color: var(--muted);
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}

.split-actions {
  justify-content: space-between;
}

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

.history-section {
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.history-section h3 {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 12px;
}

.history-list {
  display: grid;
  gap: 8px;
}

.history-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.65);
  border-radius: 10px;
  font-size: 12px;
  color: var(--ink-soft);
}

#toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  background: var(--primary);
  color: #ffffff;
  font-size: 13px;
  padding: 11px 20px;
  border-radius: 999px;
  box-shadow: 0 10px 25px rgba(24, 40, 66, 0.22);
  z-index: 50;
}

#toast:empty {
  display: none;
}

.mobile-top, .bottom-tabs, .mobile-only, .mobile-only-inline {
  display: none;
}

/* Responsive Web Breakpoints */
@media (max-width: 1080px) {
  body:not(.mobile) .shell {
    grid-template-columns: 196px minmax(0, 1fr);
  }
  body:not(.mobile) .main {
    padding: 8px 28px 48px;
  }
  body:not(.mobile) .topbar {
    padding: 0 28px;
  }
}

@media (max-width: 820px) {
  body:not(.mobile) .sky-agenda,
  body:not(.mobile) .knowledge-grid,
  body:not(.mobile) .stat-split {
    grid-template-columns: 1fr;
  }
  body:not(.mobile) .stat-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *:before, *:after {
    transition: none !important;
    animation: none !important;
  }
}
