:root {
  color-scheme: light;
  --bg: #f5f6f8;
  --surface: #ffffff;
  --ink: #1b1f24;
  --ink-2: #1f2937;
  --muted: #4b5563;
  --muted-2: #374151;
  --line: #dde1e6;
  --line-strong: #c9cfd6;
  --line-input: #9aa3ae;
  --row-line: #e5e8ec;
  --accent: #1d4ed8;
  --accent-dark: #1e3a8a;
  --accent-bg: #e8f0fe;
  --ok: #166534;
  --ok-bg: #e3f4e8;
  --warn: #9a3412;
  --warn-bg: #fff1e6;
  --warn-line: #f3c7a6;
  --later-bg: #eceef1;
  --step-bg: #e1e5ea;
  --th-bg: #f0f2f5;
  --highlight: #fff7d6;
  --font: "Noto Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
}

html {
  font-size: 18px;
  -webkit-text-size-adjust: 100%;
}
html[data-size="large"] {
  font-size: 21px;
}
html[data-size="xlarge"] {
  font-size: 24px;
}

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

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
}

h1,
h2,
p {
  margin: 0;
}

a {
  color: var(--accent);
}
a:hover {
  color: var(--accent-dark);
}

a:focus-visible,
button:focus-visible,
summary:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

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

button {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

summary {
  cursor: pointer;
}

.icon {
  flex: 0 0 auto;
}

.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;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -10rem;
  padding: 0.6rem 1rem;
  background: var(--surface);
  border: 1px solid var(--accent);
  border-radius: 0.5rem;
  z-index: 20;
}
.skip-link:focus {
  top: 1rem;
}

.boot {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  color: var(--muted);
}

.app-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.9rem 1.6rem;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.brand-name {
  font-size: 1.15rem;
  font-weight: 700;
}

.header-month {
  font-size: 1.167rem;
  font-weight: 700;
}

.month-nav {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.month-step {
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  border-radius: 0.5rem;
  font-size: 1rem;
}
.month-current {
  font-size: 1.2rem;
  font-weight: 700;
  min-width: 7.5em;
  text-align: center;
}

.size-switch {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}
.size-label {
  font-size: 0.85rem;
  color: var(--muted);
  margin-right: 0.3rem;
}
.size-button {
  min-height: 2.6rem;
  padding: 0 0.9rem;
  border-radius: 0.5rem;
  font-size: 0.85rem;
  font-weight: 700;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
}
.size-button[aria-pressed="true"] {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

.layout {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
}

.nav-wrap {
  flex: 1 1 15rem;
  max-width: 17rem;
}
.side-nav {
  padding: 1.4rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.nav-link {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 0.6rem;
  background: transparent;
  color: var(--ink);
  font-size: 1rem;
  font-weight: 500;
  text-align: left;
  text-decoration: none;
}
.nav-link:hover {
  background: var(--th-bg);
  color: var(--ink);
}
.nav-link[aria-current="page"] {
  background: var(--accent);
  color: #ffffff;
  font-weight: 700;
}
.nav-logout {
  margin-top: 1rem;
  color: var(--muted);
}

.main {
  flex: 999 1 31rem;
  min-width: 0;
  max-width: 56rem;
  padding: 1.6rem 2rem 7rem;
  display: flex;
  flex-direction: column;
  gap: 1.222rem;
}
.main:focus {
  outline: none;
}

.page-title {
  font-size: 1.889rem;
  line-height: 1.3;
  font-weight: 700;
}
.lead {
  font-size: 1.111rem;
  color: var(--muted-2);
}
.section-title {
  font-size: 1.222rem;
  font-weight: 700;
}
.small {
  font-size: 0.889rem;
  color: var(--muted);
}
.note {
  font-size: 0.9rem;
  color: var(--muted);
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.stack-lg {
  display: flex;
  flex-direction: column;
  gap: 0.556rem;
}

.notice {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 0.8rem 1.1rem;
  background: var(--warn-bg);
  border: 1px solid var(--warn-line);
  border-radius: 0.667rem;
  color: var(--warn);
  font-weight: 700;
}

.progress {
  height: 0.6rem;
  background: var(--step-bg);
  border-radius: 999px;
  overflow: hidden;
}
.progress-bar {
  height: 100%;
  background: var(--accent);
}

.task-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.task-card {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  padding: 1.1rem 1.3rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.8rem;
  text-decoration: none;
  color: var(--ink);
  min-height: 2.75rem;
}
a.task-card:hover {
  border-color: var(--accent);
  color: var(--ink);
}
.task-days {
  flex: 0 0 5.2em;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--muted);
}
.task-title {
  flex: 1 1 auto;
  font-size: 1.2rem;
  font-weight: 700;
}
.task-card[aria-disabled="true"] .task-title {
  color: var(--muted-2);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  padding: 0.3em 0.8em;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 700;
  white-space: nowrap;
}
.pill-todo {
  background: var(--warn-bg);
  color: var(--warn);
}
.pill-progress {
  background: var(--accent-bg);
  color: var(--accent);
}
.pill-done {
  background: var(--ok-bg);
  color: var(--ok);
}
.pill-later {
  background: var(--later-bg);
  color: var(--muted-2);
}

.back-link {
  font-size: 0.889rem;
  text-decoration: none;
  align-self: flex-start;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.556rem;
}
.step {
  display: flex;
  align-items: center;
  gap: 0.444rem;
  padding: 0.444rem 0.889rem;
  border-radius: 999px;
  background: var(--step-bg);
  color: var(--muted-2);
  font-weight: 700;
}
.step[aria-current="step"] {
  background: var(--accent);
  color: #ffffff;
}
.step-done {
  background: var(--ok-bg);
  color: var(--ok);
}

.dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.556rem;
  padding: 1.889rem 1.111rem;
  background: var(--surface);
  border: 2px dashed var(--line-input);
  border-radius: 0.778rem;
  text-align: center;
}
.dropzone.is-over {
  border-color: var(--accent);
  background: var(--accent-bg);
}
.dropzone-title {
  font-size: 1.111rem;
  font-weight: 700;
}
.dropzone-hint {
  font-size: 0.889rem;
  color: var(--muted);
}
.file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  white-space: nowrap;
  border-radius: 0.667rem;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid transparent;
}
.btn-primary {
  min-height: 3.333rem;
  padding: 0 1.889rem;
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
  font-size: 1.111rem;
}
.btn-primary:hover {
  background: var(--accent-dark);
  color: #ffffff;
}
.btn-secondary {
  min-height: 3.333rem;
  padding: 0 1.556rem;
  background: var(--surface);
  border-color: var(--line-input);
  color: var(--ink);
  font-size: 1.056rem;
}
.btn-secondary:hover {
  color: var(--ink);
  border-color: var(--ink);
}
.btn-outline {
  min-height: 2.889rem;
  padding: 0 1.444rem;
  background: var(--surface);
  border-color: var(--accent);
  color: var(--accent);
  font-size: 1rem;
}
.btn-outline.btn-large {
  min-height: 3.333rem;
  font-size: 1.111rem;
}
.btn-done {
  min-height: 3.333rem;
  padding: 0 1.889rem;
  background: var(--ok);
  border-color: var(--ok);
  color: #ffffff;
  font-size: 1.111rem;
}
.btn-small {
  min-height: 2.667rem;
  padding: 0 1rem;
  border-radius: 0.556rem;
  font-size: 0.944rem;
}
.btn-small.btn-primary {
  min-height: 2.667rem;
  padding: 0 1rem;
  font-size: 0.944rem;
}
.btn-quiet {
  background: var(--surface);
  border-color: var(--line-input);
  color: var(--ink);
}
.btn-block {
  width: 100%;
}

.info-box {
  display: flex;
  gap: 0.778rem;
  align-items: flex-start;
  padding: 0.889rem 1.111rem;
  background: var(--accent-bg);
  border-radius: 0.667rem;
  color: var(--ink-2);
}
.info-box .icon {
  margin-top: 0.15rem;
}
.info-title {
  font-size: 1rem;
  font-weight: 700;
}
.warn-box {
  display: flex;
  gap: 0.778rem;
  align-items: flex-start;
  padding: 0.889rem 1.111rem;
  background: var(--warn-bg);
  border: 1px solid var(--warn-line);
  border-radius: 0.667rem;
  color: var(--ink-2);
}
.warn-text {
  color: var(--warn);
  font-weight: 700;
}

.need-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.667rem;
}
.need {
  display: flex;
  flex-direction: column;
  gap: 0.222rem;
  padding: 0.778rem 1.111rem;
}
.need + .need {
  border-top: 1px solid var(--row-line);
}
.need-row {
  display: flex;
  align-items: center;
  gap: 0.778rem;
  flex-wrap: wrap;
}
.need-state {
  display: inline-flex;
  align-items: center;
  gap: 0.333rem;
  min-width: 5.333rem;
  font-weight: 700;
}
.need-ready {
  color: var(--ok);
}
.need-missing {
  color: var(--warn);
}
.need-name {
  flex: 1 1 14rem;
  font-weight: 700;
}
.need-note {
  font-size: 0.833rem;
  color: var(--muted);
}
.need-where {
  margin-left: 6.111rem;
}
.need-where summary {
  font-size: 0.889rem;
  color: var(--accent);
}
.need-where p {
  margin: 0.333rem 0 0;
  font-size: 0.889rem;
  color: var(--muted-2);
}

.file-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.file-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 0.9rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.6rem;
}
.file-name {
  flex: 1 1 14rem;
  min-width: 0;
  overflow-wrap: anywhere;
  font-weight: 500;
}
.file-state {
  font-size: 0.889rem;
  font-weight: 700;
}
.file-state-saving {
  color: var(--muted-2);
}
.file-state-saved {
  color: var(--ok);
}
.file-state-error,
.file-state-unknown {
  color: var(--warn);
}

.action-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.778rem;
  padding: 1rem 1.222rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.667rem;
}
.action-bar p {
  flex: 1 1 20rem;
  color: var(--muted-2);
}
.error-text {
  color: var(--warn);
  font-weight: 700;
}
.status-text {
  color: var(--muted-2);
}
.ok-text {
  color: var(--ok);
  font-weight: 700;
}

.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
  gap: 0.778rem;
}
.tile {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.667rem;
  padding: 1rem 1.111rem;
  min-width: 0;
}
.tile-label {
  color: var(--muted);
  font-size: 0.889rem;
}
.tile-value {
  font-size: 1.889rem;
  font-weight: 700;
  line-height: 1.35;
  overflow-wrap: anywhere;
  font-variant-numeric: tabular-nums;
}
.tile-warn {
  background: var(--warn-bg);
  border-color: var(--warn-line);
}
.tile-warn .tile-label {
  color: var(--warn);
  font-weight: 700;
}
.tile-warn .tile-value {
  color: var(--warn);
}
.tile-ok {
  background: var(--ok-bg);
  border-color: #b7dfc3;
}
.tile-ok .tile-label,
.tile-ok .tile-value {
  color: var(--ok);
  font-weight: 700;
}

.check-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.778rem;
  padding: 0.889rem 1.111rem;
  background: var(--surface);
  border: 1px solid var(--warn-line);
  border-radius: 0.667rem;
}
.check-card.is-done {
  border-color: var(--line);
}
.check-text {
  flex: 1 1 23rem;
  min-width: 0;
  overflow-wrap: anywhere;
}
.check-who {
  font-weight: 700;
}
.check-what {
  color: var(--muted-2);
}
.check-actions {
  display: flex;
  gap: 0.444rem;
  flex-wrap: wrap;
}
.done-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  color: var(--ok);
  font-weight: 700;
}

.infos summary {
  font-weight: 700;
}
.infos ul {
  margin: 0.556rem 0 0;
  padding-left: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.222rem;
  color: var(--muted-2);
  font-size: 0.889rem;
}

.sheet-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.sheet-tab {
  min-height: 2.444rem;
  padding: 0 0.889rem;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  border-radius: 0.5rem;
  font-size: 0.889rem;
  font-weight: 700;
}
.sheet-tab[aria-pressed="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: #ffffff;
}

.table-box {
  position: relative;
  overflow: auto;
  max-height: 70vh;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.667rem;
  font-variant-numeric: tabular-nums;
}
.sheet {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  font-size: 0.944rem;
}
.sheet th,
.sheet td {
  padding: 0.556rem 0.778rem;
  border-bottom: 1px solid var(--row-line);
  white-space: nowrap;
  text-align: left;
  vertical-align: top;
  background: var(--surface);
}
.sheet td.num {
  text-align: right;
}
.sheet td.long {
  white-space: pre-line;
  min-width: 16rem;
  max-width: 36rem;
}
.sheet th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--th-bg);
  font-size: 0.833rem;
  color: var(--muted-2);
}
.sheet th:first-child,
.sheet td:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  font-weight: 700;
  box-shadow: 1px 0 0 var(--row-line);
}
.sheet th:first-child {
  z-index: 2;
}
.sheet tr.is-highlight td {
  background: var(--highlight);
}
.sheet-empty {
  padding: 1rem;
  color: var(--muted);
}

.nav-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.667rem;
}

.save-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 0.889rem;
}
.save-card {
  display: flex;
  flex-direction: column;
  gap: 0.667rem;
  padding: 1.222rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.778rem;
}
.save-card .card-action {
  margin-top: auto;
}
.sms-state {
  display: flex;
  gap: 0.556rem;
  align-items: center;
  padding: 0.556rem 0.778rem;
  background: var(--later-bg);
  border-radius: 0.556rem;
  font-weight: 700;
  color: var(--muted-2);
}
.sms-preview {
  display: flex;
  gap: 0.667rem;
  align-items: center;
}
.sms-thumb {
  width: 5.333rem;
  height: 7.111rem;
  flex: 0 0 auto;
  border: 1px solid var(--line-strong);
  border-radius: 0.444rem;
  background: #fafbfc;
  display: flex;
  flex-direction: column;
  gap: 0.333rem;
  padding: 0.556rem;
}
.sms-thumb span {
  display: block;
  height: 0.333rem;
  border-radius: 0.2rem;
  background: #d3d8de;
}
.sms-thumb .thumb-title {
  height: 0.444rem;
  width: 70%;
  background: var(--accent);
}
.sms-thumb .thumb-total {
  margin-top: auto;
  height: 0.556rem;
  width: 60%;
  background: var(--ink);
}
.confirm-box {
  display: flex;
  flex-direction: column;
  gap: 0.556rem;
  padding: 0.778rem;
  border: 1px solid var(--accent);
  border-radius: 0.556rem;
}

.history-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.778rem;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 0.222rem;
}
.field label {
  font-size: 0.833rem;
  font-weight: 700;
}
select,
.select {
  -webkit-appearance: none;
  appearance: none;
  min-height: 2.889rem;
  padding: 0 2.667rem 0 0.889rem;
  border: 1px solid var(--line-input);
  border-radius: 0.556rem;
  background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 6l4.5 4.5L12.5 6' fill='none' stroke='%231B1F24' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.889rem center;
  background-size: 1rem 1rem;
  color: var(--ink);
  text-align: left;
  line-height: 1.4;
  cursor: pointer;
}
select:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}
.history-table th,
.history-table td {
  padding: 0.667rem 0.889rem;
  border-bottom: 1px solid var(--row-line);
  text-align: left;
  white-space: nowrap;
  vertical-align: top;
}
.history-table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.944rem;
}
.history-table th {
  background: var(--th-bg);
  font-size: 0.833rem;
  color: var(--muted-2);
}
.history-detail td {
  white-space: normal;
  background: #fafbfc;
}
.download-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.444rem;
  align-items: center;
  margin-top: 0.333rem;
}
.download-group + .download-group {
  margin-top: 0.667rem;
}

.fab {
  position: fixed;
  right: 1.4rem;
  bottom: 1.4rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.3rem;
  background: var(--ink);
  color: #ffffff;
  border: none;
  border-radius: 999px;
  font-weight: 700;
  box-shadow: 0 6px 18px rgba(17, 24, 39, 0.25);
  z-index: 10;
}

.feedback {
  position: fixed;
  inset: 0 0 0 auto;
  margin: 0;
  width: 100%;
  max-width: 27.778rem;
  height: 100%;
  max-height: 100%;
  padding: 1.556rem 1.667rem;
  border: none;
  background: var(--surface);
  color: var(--ink);
  overflow-y: auto;
}
.feedback[open] {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.feedback::backdrop {
  background: rgba(17, 24, 39, 0.45);
}
.feedback-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.667rem;
}
.feedback-title {
  font-size: 1.556rem;
  font-weight: 700;
}
.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.667rem;
  height: 2.667rem;
  border-radius: 0.556rem;
  border: 1px solid var(--line-strong);
  background: var(--surface);
}
.textarea {
  width: 100%;
  padding: 0.778rem 0.889rem;
  line-height: 1.6;
  border: 1px solid var(--line-input);
  border-radius: 0.667rem;
  resize: vertical;
}
.context-box {
  border: 1px solid var(--line);
  border-radius: 0.667rem;
  padding: 0.778rem 0.889rem;
}
.context-box summary {
  font-weight: 700;
}
.context-box ul {
  margin: 0.556rem 0 0;
  padding-left: 1.111rem;
  display: flex;
  flex-direction: column;
  gap: 0.222rem;
  color: var(--muted-2);
  font-size: 0.889rem;
}
.context-box p {
  margin: 0.556rem 0 0;
  font-size: 0.833rem;
  color: var(--muted);
}
.feedback-actions {
  display: flex;
  gap: 0.556rem;
  margin-top: auto;
}
.feedback-actions .btn-secondary {
  flex: 1 1 0;
}
.feedback-actions .btn-primary {
  flex: 2 1 0;
}
.center {
  text-align: center;
}

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2.667rem 1rem;
}
.login-card {
  width: 100%;
  max-width: 24.444rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.889rem;
  padding: 2.222rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.222rem;
}
.login-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.556rem;
}
.login-title {
  font-size: 1.556rem;
  font-weight: 700;
}
.login-field {
  display: flex;
  flex-direction: column;
  gap: 0.444rem;
}
.login-field label {
  font-weight: 700;
}
.input {
  height: 3.111rem;
  padding: 0 0.889rem;
  border: 1px solid var(--line-input);
  border-radius: 0.556rem;
  background: var(--surface);
}
.login-error {
  font-size: 0.889rem;
  color: var(--warn);
}

.task-row {
  display: flex;
  align-items: stretch;
  gap: 0.5rem;
}
.task-row .task-card {
  flex: 1 1 auto;
  min-width: 0;
}
.task-row .task-card[aria-disabled="true"] {
  margin-right: calc(max(44px, 2.75rem) + 0.5rem);
}
.info-button {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: max(44px, 2.75rem);
  min-height: max(44px, 2.75rem);
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 0.6rem;
  background: var(--surface);
  color: var(--accent);
}
.info-button:hover {
  border-color: var(--accent);
}
.title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}
.table-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}
.sheet-search {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}
.search-label {
  font-weight: 700;
}
.search-input {
  flex: 1 1 12rem;
  min-width: 9rem;
  height: 2.667rem;
}
.search-count {
  min-width: 4.5em;
  color: var(--muted-2);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.sheet td.is-match {
  background: #fff3b0;
  outline: 2px dashed #7a5c00;
  outline-offset: -3px;
  scroll-margin: 3rem 0 0 11rem;
}
.sheet td.is-current {
  background: #ffe066;
  outline: 3px solid var(--accent);
  outline-offset: -3px;
  font-weight: 700;
}
.sheet-overlay {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1rem 1.2rem;
  background: var(--bg);
}
.overlay-bar {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.overlay-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}
.table-box.table-box-full {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
}
html.is-locked,
html.is-locked body {
  overflow: hidden;
}
.logic-dialog {
  width: min(46rem, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  padding: 1.4rem 1.6rem;
  border: none;
  border-radius: 0.9rem;
  background: var(--surface);
  color: var(--ink);
  overflow-y: auto;
}
.logic-dialog::backdrop {
  background: rgba(17, 24, 39, 0.45);
}
.logic-body {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
.logic-list {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.logic-item {
  padding: 0.7rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 0.6rem;
}
.logic-item dt {
  font-weight: 700;
}
.logic-item dd {
  margin: 0.2rem 0 0;
}
.logic-formula {
  color: var(--ink-2);
}
.logic-note {
  color: var(--muted);
  font-size: 0.889rem;
}
.logic-table {
  border-collapse: collapse;
  width: 100%;
  font-size: 0.944rem;
  font-variant-numeric: tabular-nums;
}
.logic-table caption {
  text-align: left;
  font-weight: 700;
  padding-bottom: 0.3rem;
}
.logic-table th,
.logic-table td {
  padding: 0.45rem 0.6rem;
  border-bottom: 1px solid var(--row-line);
  text-align: left;
  vertical-align: top;
}
.logic-table thead th {
  background: var(--th-bg);
  font-size: 0.833rem;
  color: var(--muted-2);
}
.logic-table tbody th {
  font-weight: 500;
}

.preview-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}
.preview-nav .select {
  max-width: 14rem;
}
.notice-card {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  max-width: 40rem;
  padding: 1.4rem 1.6rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0.778rem;
}
.notice-title {
  text-align: center;
  font-size: 1.333rem;
  font-weight: 700;
}
.notice-sub {
  text-align: center;
  color: var(--muted-2);
}
.notice-name {
  text-align: right;
  font-size: 1.167rem;
  font-weight: 700;
}
.notice-table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}
.notice-table th,
.notice-table td {
  padding: 0.35rem 0.5rem;
  border-bottom: 1px solid var(--row-line);
  text-align: left;
  vertical-align: middle;
}
.notice-table thead th {
  background: var(--th-bg);
  font-size: 0.833rem;
  color: var(--muted-2);
}
.notice-table tbody th {
  font-weight: 500;
  white-space: nowrap;
}
.notice-table td.num {
  text-align: right;
  white-space: nowrap;
}
.note-input {
  width: 100%;
  min-width: 7rem;
  height: 2.444rem;
  padding: 0 0.6rem;
}
.notice-total {
  font-size: 1.111rem;
}
.notice-account {
  color: var(--ink-2);
}
.notice-sign {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 1.111rem;
  font-weight: 700;
}
.notice-seal {
  width: 4rem;
  height: auto;
}

@media (max-width: 40rem) {
  .app-header {
    padding: 0.8rem 1rem;
  }
  .nav-wrap {
    max-width: none;
    flex-basis: 100%;
  }
  .side-nav {
    max-width: none;
    flex-direction: row;
    flex-wrap: wrap;
    padding: 0.8rem 1rem 0;
  }
  .nav-link {
    width: auto;
  }
  .nav-logout {
    margin-top: 0;
  }
  .main {
    padding: 1.2rem 1rem 7rem;
  }
  .need-where {
    margin-left: 0;
  }
  .task-card {
    flex-wrap: wrap;
    gap: 0.6rem;
  }
  .notice-card {
    padding: 1rem;
  }
  .notice-table thead {
    display: none;
  }
  .notice-table tbody tr {
    display: grid;
    grid-template-columns: 1fr auto;
    border-bottom: 1px solid var(--row-line);
    padding: 0.3rem 0;
  }
  .notice-table tbody th,
  .notice-table tbody td {
    border-bottom: none;
  }
  .notice-table tbody td:last-child {
    grid-column: 1 / -1;
  }
}

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