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

:root {
      --bg: #f8f9fa;
      --card: #ffffff;
      --card-2: #f3f5f7;
      --surface: var(--card);
      --surface-soft: var(--card-2);
      --surface-strong: #ecfdf5;
      --text: #0f172a;
      --muted: #64748b;
      --line: rgba(15, 23, 42, .10);
      --line-2: rgba(15, 23, 42, .16);
      --green: #0f9f76;
      --green-2: #0d8b68;
      --green-dark: var(--green-2);
      --green-soft: rgba(15, 159, 118, .10);
      --blue: #2563eb;
      --blue-soft: rgba(37, 99, 235, .10);
      --warning: #9a6a14;
      --warning-soft: rgba(154, 106, 20, .12);
      --danger: #c94860;
      --danger-soft: rgba(201, 72, 96, .10);
      --shadow: 0 22px 60px -24px rgba(15, 23, 42, .28);
      --shadow-soft: 0 10px 40px -10px rgba(0, 0, 0, .08);
      --shadow-lift: 0 24px 60px -22px rgba(15, 23, 42, .32);
      --glass: rgba(255, 255, 255, .78);
      --glass-strong: rgba(255, 255, 255, .92);
      --overlay: rgba(11, 15, 25, .64);
      --radius: 16px;
      --radius-sm: 12px;
      --max: 1240px;
      --max-wide: 1320px;
      --tool-content-max: 1240px;
      --tool-panel-radius: 16px;
      --tool-card-min-height: 220px;
      --font-body: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
      --font-numeric: "Space Grotesk", Inter, system-ui, sans-serif;
    }

body.dark {
      --bg: #0b0f19;
      --card: #111827;
      --card-2: #0f172a;
      --surface: var(--card);
      --surface-soft: var(--card-2);
      --surface-strong: #064e3b;
      --text: #e2e8f0;
      --muted: #94a3b8;
      --line: rgba(148, 163, 184, .18);
      --line-2: rgba(148, 163, 184, .26);
      --green: #10b981;
      --green-2: #34d399;
      --green-dark: var(--green);
      --green-soft: rgba(16, 185, 129, .14);
      --blue: #60a5fa;
      --blue-soft: rgba(96, 165, 250, .13);
      --warning: #ffd27a;
      --warning-soft: rgba(255, 210, 122, .12);
      --danger: #ff7d96;
      --danger-soft: rgba(255, 125, 150, .12);
      --shadow: none;
      --shadow-soft: inset 0 1px 0 rgba(255, 255, 255, .04);
      --shadow-lift: inset 0 1px 0 rgba(255, 255, 255, .06), 0 18px 44px -30px rgba(0, 0, 0, .90);
      --glass: rgba(17, 24, 39, .74);
      --glass-strong: rgba(17, 24, 39, .92);
      --overlay: rgba(2, 6, 23, .78);
    }

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 0%, rgba(15, 166, 120, .12), transparent 28%),
    radial-gradient(circle at 92% 10%, rgba(23, 98, 130, .10), transparent 30%),
    var(--bg);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.menu-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

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

button {
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 16px;
  z-index: 20;
  width: min(var(--max), calc(100% - 32px));
  margin: 16px auto 0;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: rgba(255, 255, 255, .86);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

body.dark .site-header {
  background: rgba(13, 32, 29, .86);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  color: var(--text);
  white-space: nowrap;
}

.brand img {
  width: 174px;
  height: auto;
  display: block;
}

.desktop-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  color: var(--muted);
  font-size: .94rem;
  font-weight: 800;
}

.desktop-nav a:hover {
  color: var(--green);
}

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

.theme-btn,
.mobile-menu-btn,
.icon-btn {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-weight: 900;
}

.theme-btn {
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.mobile-menu-btn {
  display: none;
  padding: 0 14px;
  align-items: center;
  gap: 8px;
}

main {
  width: min(var(--max), calc(100% - 32px));
  margin: 26px auto 0;
}

.hero,
.section,
.tool-shell,
.article-shell {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, .78);
  box-shadow: var(--shadow);
}

body.dark .hero,
body.dark .section,
body.dark .tool-shell,
body.dark .article-shell {
  background: rgba(13, 32, 29, .82);
}

.hero {
  padding: clamp(28px, 5vw, 56px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, .72fr);
  gap: 24px;
  align-items: center;
}

.hero h1,
.section h2,
.article-content h2 {
  letter-spacing: 0;
  line-height: 1.04;
  color: var(--text);
}

.hero h1 {
  margin-top: 10px;
  font-size: clamp(2.1rem, 5.2vw, 4.65rem);
}

.hero h1 span,
.section h2 span {
  color: var(--green);
}

.hero p,
.section > p,
.article-content p,
.lead {
  color: var(--muted);
  line-height: 1.78;
  font-size: 1.03rem;
}

.hero p {
  max-width: 760px;
  margin-top: 18px;
}

.eyebrow {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--surface-strong);
  color: var(--green-dark);
  font-size: .86rem;
  font-weight: 900;
}

body.dark .eyebrow {
  color: #c6f5e5;
}

.hero-actions,
.action-row {
  margin-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.primary-btn,
.secondary-btn,
.danger-btn,
.ghost-btn {
  min-height: 46px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 900;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.primary-btn {
  color: #fff;
  background: var(--green);
}

.secondary-btn,
.ghost-btn {
  color: var(--text);
  background: var(--surface);
  border-color: var(--line);
}

.danger-btn {
  color: #fff;
  background: var(--danger);
}

.primary-btn:hover,
.secondary-btn:hover,
.danger-btn:hover,
.ghost-btn:hover {
  transform: translateY(-1px);
}

.hero-panel,
.metric-card,
.content-card,
.form-panel,
.goal-panel,
.chart-panel,
.calendar-panel,
.history-panel,
.backup-panel {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
}

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

.hero-stat-grid,
.metric-grid,
.content-grid {
  display: grid;
  gap: 12px;
}

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

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

.summary-column {
  display: grid;
  gap: 12px;
}

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

.hero-stat,
.metric-card {
  display: grid;
  gap: 6px;
}

.hero-stat small,
.metric-card span,
.content-card span,
.result-line span {
  color: var(--muted);
  font-size: .86rem;
  font-weight: 800;
}

.hero-stat strong,
.metric-card strong {
  color: var(--text);
  font-size: clamp(1.45rem, 2.6vw, 2rem);
}

.metric-card.highlight {
  background: linear-gradient(135deg, rgba(15, 166, 120, .18), rgba(23, 98, 130, .08)), var(--surface);
  border-color: rgba(15, 166, 120, .28);
}

.goal-panel {
  display: grid;
  gap: 14px;
  background:
    linear-gradient(135deg, rgba(23, 98, 130, .12), rgba(15, 166, 120, .10)),
    var(--surface);
  border-color: rgba(23, 98, 130, .20);
}

.goal-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, .45fr);
  gap: 12px;
  align-items: end;
}

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

.goal-result span {
  color: var(--muted);
  font-size: .82rem;
  font-weight: 900;
}

.goal-result strong {
  color: var(--green);
  font-size: 1.35rem;
}

.goal-progress {
  height: 16px;
  overflow: hidden;
  border: 1px solid rgba(23, 98, 130, .20);
  border-radius: 999px;
  background: var(--surface);
}

.goal-progress span {
  width: 0%;
  height: 100%;
  display: block;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--green));
  transition: width .25s ease;
}

.section,
.tool-shell,
.article-shell {
  margin-top: 20px;
  padding: clamp(20px, 3.2vw, 34px);
}

.section-head {
  max-width: 840px;
  margin-bottom: 20px;
}

.section-head.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.section h2,
.article-content h2 {
  margin: 10px 0 12px;
  font-size: clamp(1.65rem, 3.4vw, 2.7rem);
}

.content-card {
  display: grid;
  gap: 10px;
  align-content: start;
}

.content-card h3 {
  color: var(--text);
  font-size: 1.12rem;
}

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

.mini-icon {
  width: 46px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 15px;
  background: var(--surface-strong);
  color: var(--green-dark);
  font-weight: 950;
}

body.dark .mini-icon {
  color: #d9fff1;
}

.tool-shell {
  display: grid;
  gap: 18px;
}

.tool-layout {
  display: grid;
  grid-template-columns: minmax(320px, .8fr) minmax(0, 1.2fr);
  gap: 16px;
  align-items: start;
}

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

.field {
  display: grid;
  gap: 7px;
}

.field.full {
  grid-column: 1 / -1;
}

label {
  color: var(--muted);
  font-size: .9rem;
  font-weight: 900;
}

input,
select,
textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  color: var(--text);
  outline: none;
}

textarea {
  min-height: 84px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(15, 166, 120, .65);
  box-shadow: 0 0 0 4px rgba(15, 166, 120, .12);
}

.save-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: .9rem;
  font-weight: 800;
}

.save-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 5px rgba(15, 166, 120, .12);
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.dashboard-grid-narrow {
  grid-template-columns: 1fr;
}

.chart-panel,
.calendar-panel,
.history-panel,
.backup-panel {
  display: grid;
  gap: 14px;
  min-width: 0;
}

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

.panel-head h2,
.panel-head h3 {
  color: var(--text);
  font-size: 1.18rem;
}

.panel-head p {
  margin-top: 4px;
  color: var(--muted);
  line-height: 1.55;
  font-size: .94rem;
}

.month-chart,
.ranking-list,
.history-list,
.day-events,
.year-grid {
  display: grid;
  gap: 10px;
}

.month-chart {
  min-height: 260px;
  grid-template-columns: repeat(12, minmax(32px, 1fr));
  align-items: end;
  gap: 8px;
  padding: 12px 4px 0;
}

.month-bar {
  min-width: 0;
  display: grid;
  align-items: end;
  gap: 8px;
  text-align: center;
}

.month-bar-fill {
  height: var(--bar-size, 8%);
  min-height: 8px;
  border-radius: 12px 12px 6px 6px;
  background: linear-gradient(180deg, var(--blue), var(--green));
  box-shadow: 0 10px 20px rgba(23, 98, 130, .18);
}

.month-bar strong {
  color: var(--text);
  font-size: .74rem;
}

.month-bar span {
  color: var(--muted);
  font-size: .72rem;
  font-weight: 800;
  justify-self: center;
}

.dashboard-grid-narrow .donut-wrap {
  grid-template-columns: 1fr;
  justify-items: center;
}

.dashboard-grid-narrow .donut-wrap .legend-list {
  width: 100%;
}

.donut-wrap {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
}

.donut {
  width: 210px;
  aspect-ratio: 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: conic-gradient(var(--green) 0 100%);
  position: relative;
}

.donut::after {
  content: "";
  width: 58%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--surface);
  position: absolute;
}

.donut-center {
  z-index: 1;
  display: grid;
  gap: 2px;
  text-align: center;
}

.donut-center strong {
  color: var(--text);
  font-size: 1.1rem;
}

.donut-center span {
  color: var(--muted);
  font-size: .8rem;
  font-weight: 800;
}

.legend-list,
.ranking-list {
  list-style: none;
}

.legend-item,
.ranking-item,
.history-item,
.result-line,
.day-event,
.year-item {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-soft);
}

.legend-item,
.ranking-item,
.result-line,
.day-event,
.year-item {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.legend-key {
  width: 12px;
  height: 12px;
  display: inline-flex;
  border-radius: 50%;
  margin-right: 8px;
  vertical-align: -1px;
}

.calendar-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.calendar-title {
  color: var(--text);
  font-size: 1.2rem;
  font-weight: 950;
}

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

.weekday,
.calendar-day {
  min-width: 0;
  text-align: center;
}

.weekday {
  color: var(--muted);
  font-size: .75rem;
  font-weight: 950;
}

.calendar-day {
  min-height: 84px;
  padding: 8px 6px;
  display: grid;
  align-content: start;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text);
}

.calendar-day.is-muted {
  opacity: .42;
}

.calendar-day.has-events {
  border-color: rgba(15, 166, 120, .46);
  background: linear-gradient(135deg, rgba(15, 166, 120, .13), rgba(23, 98, 130, .07)), var(--surface);
}

.calendar-day.is-selected {
  outline: 3px solid rgba(15, 166, 120, .18);
}

.calendar-day strong {
  justify-self: start;
  font-size: .88rem;
}

.calendar-day span {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: clip;
  white-space: nowrap;
  color: var(--green-dark);
  font-size: .72rem;
  font-weight: 950;
}

body.dark .calendar-day span {
  color: #bdf5e2;
}

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

.history-controls {
  display: grid;
  grid-template-columns: 1fr 160px;
  gap: 10px;
}

.history-item {
  grid-template-columns: 1fr auto auto;
  align-items: center;
}

.history-main {
  display: grid;
  gap: 4px;
}

.history-main strong {
  color: var(--text);
}

.history-main span {
  color: var(--muted);
  font-size: .88rem;
}

.empty-state {
  padding: 18px;
  border: 1px dashed var(--line);
  border-radius: 16px;
  color: var(--muted);
  background: var(--surface-soft);
  line-height: 1.7;
}

.month-chart .empty-state {
  grid-column: 1 / -1;
}

.privacy-note {
  padding: 14px;
  border-radius: 16px;
  background: var(--blue-soft);
  color: var(--muted);
  line-height: 1.65;
}

.article-shell {
  display: grid;
  grid-template-columns: minmax(0, .75fr) minmax(0, 1.25fr);
  gap: 24px;
  align-items: start;
}

.article-toc {
  position: sticky;
  top: 122px;
  display: grid;
  gap: 10px;
}

.article-toc a {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--muted);
  font-weight: 850;
}

.article-content {
  display: grid;
  gap: 22px;
}

.article-content section {
  display: grid;
  gap: 12px;
}

.article-content ul,
.article-content ol {
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.75;
}

.table-like {
  display: grid;
  gap: 8px;
}

.table-row {
  display: grid;
  grid-template-columns: .8fr 1fr 1.2fr;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
}

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

.resource-disclosure {
  padding: 14px;
  border: 1px solid rgba(23, 98, 130, .18);
  border-radius: 16px;
  background: var(--blue-soft);
  color: var(--muted);
  line-height: 1.65;
}

.resource-filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.resource-filter {
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-weight: 900;
}

.resource-filter.is-active,
.resource-filter:hover {
  border-color: rgba(15, 166, 120, .34);
  background: var(--surface-strong);
  color: var(--green-dark);
}

body.dark .resource-filter.is-active,
body.dark .resource-filter:hover {
  color: #d9fff1;
}

.resource-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.resource-card {
  min-height: 100%;
  display: grid;
  gap: 12px;
  align-content: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
}

.resource-card.is-hidden {
  display: none;
}

.resource-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.resource-card h3 {
  color: var(--text);
  font-size: 1.08rem;
  line-height: 1.25;
}

.resource-card p {
  color: var(--muted);
  line-height: 1.65;
}

.resource-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.resource-tag {
  padding: 6px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: .78rem;
  font-weight: 900;
}

.resource-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.resource-placeholder {
  color: var(--muted);
  opacity: .78;
  cursor: default;
}

.resource-placeholder:hover {
  transform: none;
}

.resource-note-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.resource-note {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface-soft);
}

.resource-note strong {
  display: block;
  color: var(--text);
  margin-bottom: 6px;
}

.resource-note span {
  color: var(--muted);
  line-height: 1.6;
}

.site-footer {
  width: min(var(--max), calc(100% - 32px));
  margin: 24px auto;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
}

.footer-top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
}

.footer-top p {
  margin-top: 8px;
  line-height: 1.65;
}

.footer-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.footer-btn {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: .86rem;
  font-weight: 850;
}

.footer-btn:hover {
  color: var(--green);
}

.mobile-menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: none;
  padding: 16px;
  background: rgba(0, 0, 0, .42);
}

.mobile-menu-backdrop.show {
  display: grid;
  place-items: start center;
}

.mobile-panel {
  width: min(520px, 100%);
  max-height: calc(100vh - 32px);
  overflow: auto;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.mobile-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.mobile-head p {
  color: var(--muted);
  line-height: 1.5;
  font-size: .92rem;
}

.close-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: var(--text);
  font-size: 1.4rem;
}

.mobile-section {
  margin-top: 14px;
  display: grid;
  gap: 10px;
}

.mobile-section h3 {
  color: var(--text);
}

.mobile-list {
  display: grid;
  gap: 9px;
}

.mobile-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface-soft);
}

.mobile-item strong {
  display: block;
}

.mobile-item small {
  color: var(--muted);
  line-height: 1.4;
}

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

@media (max-width: 1080px) {
  .desktop-nav {
    display: none;
  }

  .mobile-menu-btn {
    display: inline-flex;
  }

  .hero,
  .tool-layout,
  .dashboard-grid,
  .resource-grid,
  .resource-note-list,
  .article-shell {
    grid-template-columns: 1fr;
  }

  .article-toc {
    position: static;
  }
}

@media (max-width: 760px) {
  .site-header,
  main,
  .site-footer {
    width: min(100% - 20px, var(--max));
  }

  .site-header {
    top: 8px;
    margin-top: 8px;
    border-radius: 22px;
  }

  .brand img {
    width: 150px;
  }

  .theme-text {
    display: none;
  }

  .hero,
  .section,
  .tool-shell,
  .article-shell,
  .site-footer {
    padding: 18px;
    border-radius: 20px;
  }

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

  .hero-stat-grid,
  .metric-grid,
  .content-grid,
  .field-grid,
  .goal-grid,
  .donut-wrap,
  .year-grid,
  .footer-top,
  .history-controls {
    grid-template-columns: 1fr;
  }

  .month-chart {
    min-height: auto;
    overflow: visible;
    grid-template-columns: 1fr;
    align-items: stretch;
    padding: 0;
  }

  .month-bar {
    grid-template-columns: 42px minmax(0, 1fr) 68px;
    align-items: center;
    gap: 8px;
    text-align: left;
  }

  .month-bar-fill {
    width: var(--bar-size, 0%);
    max-width: 100%;
    height: 12px;
    min-height: 12px;
    border-radius: 999px;
  }

  .month-bar strong {
    order: -1;
    font-size: .82rem;
    text-transform: capitalize;
  }

  .month-bar span {
    justify-self: end;
    font-size: .78rem;
    white-space: nowrap;
  }

  .calendar-grid {
    gap: 5px;
  }

  .calendar-day {
    min-height: 68px;
    padding: 6px 4px;
    border-radius: 12px;
  }

  .calendar-day span {
    font-size: .62rem;
  }

  .history-item {
    grid-template-columns: 1fr;
  }

  .footer-actions {
    justify-content: flex-start;
  }

  .table-row {
    grid-template-columns: 1fr;
  }

  .resource-filter-bar {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }

  .resource-filter {
    flex: 0 0 auto;
  }

  .resource-actions a,
  .resource-actions button {
    width: 100%;
  }
}
