:root {
  --bg: #f4f4f5;
  --surface: #ffffff;
  --text: #18181b;
  --muted: #71717a;
  --border: #e4e4e7;
  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --danger: #dc2626;
  --radius: 12px;
  --shadow: 0 1px 3px rgb(0 0 0 / 0.08);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans KR", sans-serif;
}

[data-theme="dark"] {
  --bg: #09090b;
  --surface: #18181b;
  --text: #fafafa;
  --muted: #a1a1aa;
  --border: #27272a;
  --accent: #3b82f6;
  --accent-hover: #60a5fa;
  --danger: #f87171;
  --shadow: 0 1px 3px rgb(0 0 0 / 0.35);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #09090b;
    --surface: #18181b;
    --text: #fafafa;
    --muted: #a1a1aa;
    --border: #27272a;
    --accent: #3b82f6;
    --accent-hover: #60a5fa;
    --danger: #f87171;
    --shadow: 0 1px 3px rgb(0 0 0 / 0.35);
  }
}

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

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

.app {
  max-width: 720px;
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.25rem 1.5rem;
}

.header {
  margin-bottom: 1.25rem;
}

.header__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.header__title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.header__tagline {
  margin: 0.5rem 0 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.main {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.section__title {
  margin: 0 0 1rem;
  font-size: 1rem;
  font-weight: 600;
}

.field-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-end;
}

.field-row .field {
  flex: 1 1 200px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.field__label {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 500;
}

.input {
  width: 100%;
  padding: 0.55rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  font: inherit;
}

.input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.btn {
  font: inherit;
  cursor: pointer;
  border: none;
  border-radius: 8px;
  padding: 0.55rem 1rem;
  font-weight: 600;
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

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

.btn--primary:hover:not(:disabled) {
  background: var(--accent-hover);
}

.btn--secondary {
  background: var(--border);
  color: var(--text);
  margin-top: 0.75rem;
}

.btn--secondary:hover:not(:disabled) {
  filter: brightness(0.95);
}

[data-theme="dark"] .btn--secondary:hover:not(:disabled) {
  filter: brightness(1.15);
}

.btn--ghost {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
}

.btn--ghost:hover:not(:disabled) {
  color: var(--text);
  border-color: var(--muted);
}

.btn--danger {
  background: transparent;
  color: var(--danger);
  padding: 0.35rem 0.5rem;
  font-size: 0.85rem;
}

.hint {
  margin: 0.75rem 0 0;
  font-size: 0.85rem;
  color: var(--muted);
  min-height: 1.25em;
}

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

.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1rem;
}

.task-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.task-item {
  display: grid;
  grid-template-columns: auto 1fr 5rem auto;
  gap: 0.5rem;
  align-items: center;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
}

@media (max-width: 540px) {
  .task-item {
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
  }

  .task-item__hours {
    grid-column: 2;
  }

  .task-item__delete {
    grid-column: 2;
    justify-self: end;
  }
}

.task-item--done .task-item__title {
  text-decoration: line-through;
  color: var(--muted);
}

.task-item__check {
  width: 1.15rem;
  height: 1.15rem;
  accent-color: var(--accent);
}

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

.task-item__hours {
  width: 100%;
}

.schedule {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.schedule-day {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  background: var(--bg);
}

.schedule-day__date {
  margin: 0 0 0.35rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
}

.schedule-day__task {
  margin: 0;
  font-size: 0.95rem;
}

.schedule-day__hours {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 0.25rem;
}

.empty {
  margin: 0 0 0.5rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.empty--hidden {
  display: none;
}



.footer {
  margin-top: 40px;
  padding: 24px;
  background-color: #ffffff; /* 기존 카드 배경색에 맞춤 */
}

/* 기술명세서 영역: 가로 배치 */
.footer__specs {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 16px;
  padding-bottom: 20px;
  border-bottom: 1px solid #f0f0f0;
  margin-bottom: 20px;
  text-align:center;
}

.spec-item {
  font-size: 0.85rem;
  color: #666;
  text-align: center;
}

.spec-item strong {
  display: block;
  color: #333;
  margin-bottom: 4px;
  font-size: 0.9rem;
}

/* 하단 연락처 및 카피라이트 */
.footer__bottom {
  text-align: center;
  font-size: 0.85rem;
  color: #999;
}

.footer__contact {
  margin-bottom: 8px;
}

.footer__contact a {
  color: #555;
  text-decoration: underline;
}
.footer__copyright{
	text-align:center;
}

/* 모바일 대응: 화면이 좁아지면 세로로 정렬 */
@media (max-width: 600px) {
  .footer__specs {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
	text-align:center;
  }
  .spec-item {
    text-align: left;
  }
  .spec-item strong {
    display: inline-block;
    margin-right: 8px;
  }
}