:root {
  color-scheme: light;
  --ink: #191918;
  --muted: #615d59;
  --line: #dfdcd9;
  --soft: #f6f5f4;
  --blue: #0075de;
  --deep-blue: #005bab;
  --red: #b01601;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: #efeeeb; font-size: 16px; line-height: 1.5; word-break: keep-all; overflow-wrap: anywhere; }
button, input, select { color: inherit; font: inherit; }
button, a, summary, input, select { touch-action: manipulation; }
button, summary, select { cursor: pointer; }
button { border: 0; background: none; }
a { color: var(--deep-blue); }
:focus-visible { outline: 3px solid var(--deep-blue); outline-offset: 2px; }
button:disabled { cursor: default; opacity: .55; }
h1, h2, h3, p, dl, dd, fieldset, legend { margin: 0; }
h1 { font-size: 1.625rem; line-height: 1.26; letter-spacing: -.06em; }
h2 { font-size: 1.14rem; line-height: 1.4; letter-spacing: -.045em; }
h3 { font-size: 1rem; margin-bottom: 8px; }
.sheet { width: min(100%, 460px); margin: 0 auto; background: white; min-height: 100dvh; }
header, nav { padding: 0 20px; border-bottom: 1px solid var(--line); }
header { min-height: 58px; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); font-weight: 750; letter-spacing: -.045em; text-decoration: none; min-height: 44px; }
.header-button, .text-button, nav a { min-width: 44px; min-height: 44px; font-size: .9rem; }
.header-button { color: var(--muted); padding: 5px 0 5px 8px; }
nav { display: flex; gap: 18px; }
nav a { display: grid; align-content: center; color: var(--muted); text-align: center; text-decoration: none; border-bottom: 2px solid transparent; }
nav a[aria-current="page"] { color: var(--ink); font-weight: 700; border-color: currentColor; }
main { padding: 24px 20px 20px; }
.hero-head, .section-head, .dialog-head, .range, .calendar-head, .dialog-tools { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.hero-head, .section-head, .range { flex-wrap: wrap; row-gap: 4px; }
.date, .period, .hint, .muted, .loading { color: var(--muted); }
.date { margin-top: 5px; font-size: .875rem; }
.period, .hint { font-size: .8125rem; }
.hint { margin-top: 6px; }
.status { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 6px; color: var(--muted); background: var(--soft); font-weight: 650; font-size: .8125rem; }
.status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.status.active { color: #0f6220; background: #f0faf2; }
.times { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); padding: 12px 0; margin: 18px 0 12px; border-radius: 8px; background: var(--soft); }
.times div { padding: 0 12px; }
.times div + div { border-left: 1px solid var(--line); }
.times dt { color: var(--muted); font-size: .8125rem; }
.times dd { font-size: 1.2rem; font-weight: 650; letter-spacing: -.045em; }
.times small { display: block; font-size: .75rem; font-weight: 500; }
.primary, .secondary { width: 100%; min-height: 48px; padding: 9px 12px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-weight: 650; }
.primary { color: white; background: var(--blue); }
.primary:hover, .primary:active { background: var(--deep-blue); }
.secondary { background: white; border: 1px solid #c9c5bf; }
.secondary:hover, .month-controls button:hover:enabled { background: var(--soft); }
.primary svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.section { margin-top: 24px; padding-top: 22px; border-top: 1px solid var(--line); }
.week-stats { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 6px 12px; margin-top: 12px; }
.week-number { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px; }
.week-overtime { text-align: right; margin-left: auto; }
.week-overtime dt, .overtime-rows dt { color: var(--muted); font-size: .8125rem; }
.week-overtime dd { font-weight: 650; }
.overtime-rows { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); margin: 12px 0 8px; }
.overtime-rows > div + div { padding-left: 16px; border-left: 1px solid var(--line); }
.overtime-rows dd { font-size: 1.375rem; font-weight: 700; letter-spacing: -.045em; }
.week-number strong { font-size: 2rem; line-height: 1.2; letter-spacing: -.055em; }
.week-number span { font-size: 1.125rem; font-weight: 650; margin-right: 3px; }
.meter { height: 9px; position: relative; border-radius: 8px; background: #eae8e5; margin-top: 14px; overflow: hidden; }
.meter progress { display: block; width: 100%; height: 100%; border: 0; border-radius: inherit; background: transparent; color: #353431; appearance: none; }
progress::-webkit-progress-bar { background: transparent; }
progress::-webkit-progress-value { background: #353431; border-radius: 8px; }
progress::-moz-progress-bar { background: #353431; border-radius: 8px; }
.meter::after { content: ""; position: absolute; top: 0; height: 100%; left: 76.923%; border-left: 2px solid white; }
.range { margin-top: 7px; color: var(--muted); font-size: .8125rem; }
.over-limit { color: var(--red); background: #fef3f1; padding: 2px 6px; border-radius: 4px; font-weight: 700; }
.pay-rows { margin-top: 12px; }
.line, .detail-line { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; column-gap: 9px; row-gap: 0; }
.line { padding: 6px 0; }
.line dt { font-size: .94rem; color: var(--muted); }
.line dd { margin-left: auto; font-size: 1.17rem; font-weight: 650; letter-spacing: -.04em; }
.net dt, .net dd { color: var(--ink); font-weight: 700; }
.net dd { font-size: 1.55rem; }
.won { font-size: .72em; margin-left: 2px; }
.inline-setting { font-size: .87rem; font-weight: 600; color: var(--deep-blue); min-height: 44px; padding: 4px 0 4px 6px; }
.detail-box { margin-top: 12px; border-radius: 8px; background: var(--soft); }
summary { min-height: 44px; display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; color: var(--muted); font-size: .875rem; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary::after { content: ""; display: block; width: 7px; height: 7px; flex: none; border-right: 1.5px solid; border-bottom: 1.5px solid; transform: rotate(45deg); margin: -4px 3px 0 12px; }
details[open] > summary::after { transform: rotate(225deg); margin-top: 4px; }
.detail-body { margin: 0 12px; padding: 8px 0 12px; border-top: 1px solid var(--line); }
.detail-line { padding: 4px 0; font-size: .875rem; }
.detail-line dt { color: var(--muted); }
.detail-line dd { margin-left: auto; font-weight: 600; }
.detail-body h3 { margin-top: 12px; font-size: .92rem; }
.calendar-head { margin: 16px 0 8px; }
.month-controls, .segments, .actions { display: flex; gap: 5px; }
.month-controls button { width: 44px; height: 44px; font-size: 1.35rem; border: 1px solid var(--line); border-radius: 8px; }
.weekdays, .dates { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.weekdays span { padding: 4px 0 6px; text-align: center; color: var(--muted); font-size: .8125rem; }
.dates button { position: relative; min-height: 46px; border-radius: 8px; padding: 3px 0; font-size: .925rem; }
.dates button[aria-pressed="true"] { background: var(--ink); color: white; font-weight: 700; }
.dates button.has-record::after, .record-key::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: currentColor; }
.dates button.has-record::after { position: absolute; bottom: 5px; left: calc(50% - 2px); }
.record-key { display: flex; align-items: center; gap: 6px; font-size: .8125rem; color: var(--muted); margin-top: 7px; }
.day-detail { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 18px; }
.day-detail dl, .day-detail .muted { margin: 10px 0 12px; }
.day-detail .total { border-top: 1px solid var(--line); margin-top: 5px; padding-top: 10px; }
.notice { margin: 0 20px; padding: 0 0 18px; font-size: .875rem; color: var(--muted); }
.notice:empty, .form-status:empty { display: none; }
.gate { padding: 8px 0 10px; }
.gate h1 { margin: 14px 0 8px; }
.gate p { margin-bottom: 22px; color: var(--muted); }
.gate-icon { width: 50px; height: 50px; }
dialog { color: var(--ink); width: min(420px, calc(100% - 24px)); max-width: 100%; max-height: min(89dvh, 880px); overflow: auto; overscroll-behavior: contain; padding: 18px 20px 20px; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 12px 48px #19191833; }
dialog::backdrop { background: #19191855; }
body:has(dialog[open]) { overflow: hidden; }
.dialog-head { margin-bottom: 8px; }
.dialog-head h2 { font-size: 1.25rem; }
.close { width: 44px; height: 44px; font-size: 1.6rem; flex: none; margin-right: -5px; }
.form-fields { border: 0; padding: 0; min-width: 0; }
.field { display: block; margin-top: 14px; }
.field > span, legend { display: block; font-size: .875rem; font-weight: 650; margin-bottom: 5px; }
.field input, .field select { display: block; width: 100%; min-width: 0; max-width: 100%; min-height: 44px; border: 1px solid #a8a39c; background: white; border-radius: 7px; padding: 8px 10px; }
.field input:disabled { color: var(--muted); background: var(--soft); }
.pair { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 12px; }
.check { display: inline-flex; align-items: center; min-height: 44px; gap: 7px; font-size: .875rem; }
.check input { width: 18px; height: 18px; accent-color: var(--deep-blue); }
.segments { border-radius: 8px; padding: 3px; background: var(--soft); margin: 16px 0 8px; }
.segments button { flex: 1; min-height: 44px; font-size: .9rem; border-radius: 6px; }
.segments button[aria-pressed="true"] { background: white; box-shadow: 0 1px 3px #19191824; font-weight: 700; }
.week-picker { margin: 15px 0 0; padding: 0; border: 0; }
.week-picker div { display: flex; flex-wrap: wrap; gap: 1px 12px; }
.form-summary { margin-top: 14px; padding: 10px 12px; background: var(--soft); border-radius: 7px; font-size: .875rem; }
.form-status { color: var(--red); font-size: .875rem; margin-top: 10px; }
.dialog-save { margin-top: 16px; }
.text-button { color: var(--deep-blue); padding: 4px; }
.account { margin-top: 14px; padding-top: 8px; border-top: 1px solid var(--line); color: var(--muted); font-size: .8125rem; }
.conflict { margin-top: 12px; padding: 10px 12px; background: var(--soft); border-radius: 8px; }
.conflict p { margin: 5px 0; font-size: .875rem; }
.conflict ul { margin: 6px 0; padding-left: 19px; font-size: .8125rem; }
@media (min-width: 520px) {
  body { padding: 26px 16px; background-image: radial-gradient(#d7d4cf .65px,transparent .85px); background-size: 9px 9px; }
  .sheet { min-height: 0; border: 1px solid #d6d2cc; border-radius: 15px; box-shadow: 0 12px 42px #2c271013; overflow: hidden; }
  header, nav { padding-inline: 24px; }
  main { padding: 25px 24px; }
}
@media (max-width: 350px) {
  main { padding-inline: 16px; }
  .times div { padding-inline: 8px; }
  .times dd { font-size: 1.1rem; }
  dialog { padding-inline: 13px; }
  .pair { gap: 6px; }
}
