@font-face {
  font-family: "Golos Text Fallback";
  src: local("Segoe UI"), local("Arial"), local("Liberation Sans"), local("Helvetica Neue");
  size-adjust: 102.3%;
  ascent-override: 95.8%;
  descent-override: 21.5%;
  line-gap-override: 0%;
}

@font-face {
  font-family: "Golos Text";
  src: url("fonts/GolosText-variable.woff2") format("woff2"),
       url("fonts/GolosText-variable.ttf") format("truetype");
  font-weight: 400 700;
  font-style: normal;
  font-display: optional;
}

:root {
  --paper: #f4f2ec;
  --sheet: #ffffff;
  --ink: #1b2430;
  --muted: #5c6570;
  --line: #ddd8ce;
  --pine: #2f5c4c;
  --pine-hover: #24483c;
  --pine-soft: #e7efe9;
  --warn: #9a4d12;
  --warn-soft: #f7e7d4;
  --warn-strong: #c45c14;
  --focus: #2f5c4c;
  --radius: 10px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --t: 280ms var(--ease);
}

* {
  box-sizing: border-box;
}

html {
  font-size: 18px;
  scroll-behavior: auto;
  overscroll-behavior-y: none;
  overflow-x: clip;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(1200px 640px at 108% -10%, rgba(47, 92, 76, 0.22), transparent 58%),
    radial-gradient(900px 520px at -12% 92%, rgba(47, 92, 76, 0.11), transparent 60%),
    var(--paper);
  font-family: "Golos Text", "Golos Text Fallback", "Segoe UI", sans-serif;
  font-weight: 400;
  line-height: 1.55;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 80;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("noise.svg");
  background-size: 180px 180px;
  mix-blend-mode: multiply;
}

a {
  color: var(--pine);
  transition: color var(--t);
}

a:hover {
  color: var(--ink);
}

.wrap {
  width: min(1080px, calc(100% - clamp(24px, 6vw, 48px)));
  margin: 0 auto;
}

.wrap.wide {
  width: min(1180px, calc(100% - clamp(24px, 5vw, 40px)));
}

.top {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--paper) 90%, transparent);
  backdrop-filter: saturate(1.05) blur(14px);
  -webkit-backdrop-filter: saturate(1.05) blur(14px);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 42%, transparent);
}

.top-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 0 14px;
}

.mark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--ink);
  white-space: nowrap;
  transition: color var(--t);
}

.mark-ico {
  width: 22px;
  height: 22px;
  color: var(--pine);
  flex: none;
}

.mark:hover {
  color: var(--pine);
}

.mark span {
  display: none;
}

nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px clamp(12px, 2.4vw, 28px);
}

nav a {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 500;
  padding: 8px 0;
}

nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t);
}

nav a:hover,
nav a[aria-current="page"] {
  color: var(--pine);
}

nav a:hover::after,
nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

.hero {
  position: relative;
  min-height: calc(100svh - 72px);
  padding: 72px 0 22vh;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(220px, 0.85fr);
  gap: 36px 48px;
  align-items: center;
}

.hero-copy h1,
.hero h1 {
  margin: 0 0 20px;
  font-weight: 700;
  font-size: clamp(1.85rem, 1.1rem + 4.2vw, 4.35rem);
  line-height: 1.05;
  letter-spacing: -0.035em;
  max-width: 14ch;
  text-wrap: balance;
}

.hero-art {
  justify-self: end;
  width: min(100%, 420px);
}

.ghost-card {
  background: color-mix(in srgb, var(--sheet) 78%, transparent);
  border: 1px solid color-mix(in srgb, var(--pine) 22%, var(--line));
  border-radius: 18px;
  padding: 28px 26px 24px;
  box-shadow:
    0 24px 50px rgba(27, 36, 48, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
  transform: rotate(2.4deg);
}

.ghost-kicker {
  margin: 0 0 10px;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pine);
}

.ghost-title {
  margin: 0 0 22px;
  font-size: 1.35rem;
  font-weight: 650;
  letter-spacing: -0.03em;
}

.ghost-rule {
  display: block;
  height: 1px;
  background: var(--line);
  margin: 0 0 14px;
}

.ghost-rule.short {
  width: 42%;
}

.ghost-rule.mid {
  width: 68%;
}

.ghost-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.6fr 0.6fr 0.5fr;
  gap: 8px;
  margin-top: 8px;
}

.ghost-grid i {
  display: block;
  height: 28px;
  border-radius: 4px;
  background: color-mix(in srgb, var(--pine-soft) 80%, var(--line));
}

.lead {
  margin: 0;
  max-width: 38ch;
  font-size: 1.05rem;
  color: var(--muted);
}

.hero .actions {
  margin-top: 36px;
}

.fines {
  padding: 12px 0 72px;
  border-top: 1px solid var(--line);
}

.fines h2 {
  margin: 0 0 12px;
  font-size: clamp(1.7rem, 3.4vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.12;
}

.fines-lead {
  margin: 0 0 28px;
  max-width: 62ch;
  color: var(--muted);
}

.fines-list {
  display: grid;
  gap: 28px;
  max-width: 62ch;
}

.fines-kicker {
  margin: 0 0 6px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pine);
}

.fines h3 {
  margin: 0 0 8px;
  font-size: 1.12rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.fines-list p {
  margin: 0;
  color: var(--ink);
}

.page-head {
  padding: 36px 0 8px;
}

.page-head h1 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.page-head h1::before {
  content: "";
  display: block;
  width: 32px;
  height: 3px;
  margin-bottom: 18px;
  border-radius: 99px;
  background: var(--pine);
}

.page-head h2 {
  margin: 0 0 12px;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.page-head p {
  margin: 0;
  max-width: 62ch;
  color: var(--ink);
}

.rest {
  position: relative;
  padding: 48px 0 40px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: minmax(92px, 140px) minmax(0, 1fr);
  gap: 24px 40px;
  align-items: start;
}

.rest p {
  max-width: 62ch;
}

.rest-mark {
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1;
  color: color-mix(in srgb, var(--pine) 28%, var(--paper));
}

.rest-copy {
  border-left: 2px solid color-mix(in srgb, var(--pine) 35%, var(--line));
  padding-left: 28px;
}

.panel {
  background: var(--sheet);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 24px;
  transition: border-color var(--t), box-shadow var(--t);
}

.panel:focus-within {
  border-color: color-mix(in srgb, var(--pine) 45%, var(--line));
  box-shadow: 0 12px 28px rgba(27, 36, 48, 0.05);
}

.panel h2,
.content h2 {
  margin: 0 0 12px;
  font-weight: 650;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border: 1px solid var(--pine);
  border-radius: 8px;
  background: var(--pine);
  color: #fff;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  line-height: 1.2;
  transition: background var(--t), border-color var(--t), color var(--t), transform var(--t), box-shadow var(--t);
}

.btn:hover {
  background: var(--pine-hover);
  border-color: var(--pine-hover);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(47, 92, 76, 0.18);
}

.btn:active {
  transform: translateY(0);
  box-shadow: none;
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}

.btn-ghost:hover {
  background: var(--sheet);
  color: var(--ink);
  border-color: var(--ink);
  box-shadow: 0 8px 18px rgba(27, 36, 48, 0.06);
}

.btn-text {
  display: inline-flex;
  align-items: center;
  background: transparent;
  border: 0;
  color: var(--pine);
  padding: 12px 4px;
  font-weight: 500;
  text-decoration: none;
  font-size: 0.95rem;
  cursor: pointer;
  font-family: inherit;
  transition: color var(--t), transform var(--t);
}

.btn-text:hover {
  background: transparent;
  color: var(--ink);
  border: 0;
  transform: translateX(2px);
}

.note {
  background: var(--pine-soft);
  border-radius: 8px;
  padding: 14px 16px;
  margin: 18px 0;
}

.note p {
  margin: 0;
}

.content {
  padding: 36px 0 64px;
  max-width: 72ch;
}

.content h1 {
  font-weight: 700;
  font-size: 2.2rem;
  letter-spacing: -0.03em;
  margin: 0 0 16px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
  align-items: stretch;
}

.form-grid > label {
  min-width: 0;
}

.form-grid > label input,
.form-grid > label select {
  margin-top: auto;
}

.form-grid label,
.stack label,
.search {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
}

.span-2 {
  grid-column: span 2;
}

input,
select,
textarea {
  font: inherit;
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--ink);
  background: var(--sheet);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  width: 100%;
  transition: border-color var(--t), box-shadow var(--t);
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--focus);
  box-shadow: 0 0 0 3px rgba(47, 92, 76, 0.16);
}

.ui-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.ui-table th,
.ui-table td {
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 10px 8px;
  vertical-align: top;
  text-align: left;
}

.ui-table th {
  background: transparent;
  font-weight: 600;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.35;
  vertical-align: bottom;
}

.ui-table tbody tr {
  animation: enter 0.32s var(--ease) both;
}

.ui-table input,
.ui-table select,
.ui-table textarea {
  border: 1px solid var(--line);
  padding: 8px 10px;
  background: var(--sheet);
  border-radius: 8px;
  min-height: 42px;
  width: 100%;
}

.ui-table textarea {
  resize: vertical;
  min-height: 42px;
  line-height: 1.4;
  overflow: hidden;
  field-sizing: content;
}

.ui-table input[type="date"] {
  min-width: 10.5rem;
}

.ui-table td:last-child {
  vertical-align: middle;
}

.ui-table input::placeholder,
.ui-table textarea::placeholder {
  color: var(--muted);
  opacity: 0.7;
}

.table-norms .ui-table {
  table-layout: fixed;
}

.table-norms th:nth-child(1),
.table-norms td:nth-child(1) {
  width: 46%;
}

.table-norms th:nth-child(2),
.table-norms td:nth-child(2) {
  width: 12%;
}

.table-norms th:nth-child(3),
.table-norms td:nth-child(3) {
  width: 22%;
}

.table-norms th:nth-child(4),
.table-norms td:nth-child(4) {
  width: 12%;
}

.table-norms th:nth-child(5),
.table-norms td:nth-child(5) {
  width: 8%;
  vertical-align: middle;
}

.issue-list {
  display: grid;
  gap: 16px;
  margin: 16px 0 12px;
  min-width: 0;
}

.issue-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  padding: 16px 16px 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: color-mix(in srgb, var(--paper) 55%, var(--sheet));
}

.issue-card-top {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}

.issue-card > label,
.issue-block > label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
}

.issue-card .span-2,
.issue-block .span-2,
.issue-card-top {
  grid-column: 1 / -1;
}

.issue-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 16px;
  padding: 14px;
  border-radius: 8px;
  background: var(--sheet);
  border: 1px solid var(--line);
}

.issue-block h3 {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 0.95rem;
  font-weight: 650;
  color: var(--ink);
}

.issue-card input,
.issue-card select,
.issue-card textarea {
  min-height: 48px;
  font-size: 1rem;
}

input.js-date {
  min-height: 56px;
  font-size: 1.2rem;
  letter-spacing: 0.04em;
}

.issue-card .check-line {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
}

.issue-card .check-line .check {
  min-height: 48px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--sheet);
}

.norm-list {
  display: grid;
  gap: 16px;
  margin: 16px 0 12px;
  min-width: 0;
}

.norm-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: color-mix(in srgb, var(--paper) 55%, var(--sheet));
  min-width: 0;
}

.norm-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.norm-card > label,
.norm-meta > label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
}

.norm-meta {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr) minmax(0, 0.8fr);
  gap: 12px;
}

.ppe-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 16px 0 12px;
}

.ppe-count {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
}

.ppe-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ppe-filters button {
  font: inherit;
  font-size: 0.88rem;
  font-weight: 650;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--sheet);
  color: var(--ink);
  cursor: pointer;
}

.ppe-filters button.is-on {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

.ppe-list {
  display: grid;
  gap: 16px;
  margin: 0 0 12px;
  min-width: 0;
}

.ppe-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--sheet);
  min-width: 0;
}

.ppe-card[hidden] {
  display: none !important;
}

.ppe-card.is-pending {
  background: var(--warn-soft);
  border-color: color-mix(in srgb, var(--warn) 42%, var(--line));
}

.ppe-card.is-issued {
  background: var(--pine-soft);
  border-color: color-mix(in srgb, var(--pine) 38%, var(--line));
}

.ppe-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.ppe-card-id {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}

.ppe-status {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.2;
}

.ppe-status.is-wait {
  background: var(--warn-strong);
  color: #fff;
}

.ppe-status.is-done {
  background: var(--pine);
  color: #fff;
}

.ppe-card.is-pending .js-open {
  min-height: 48px;
  font-size: 1.02rem;
}

.print-hint {
  flex: 1 0 100%;
  margin: 4px 0 0;
  font-size: 0.92rem;
  font-weight: 650;
  color: var(--ink);
}

.issue-block input.js-date {
  background: #fff8ef;
  border-color: color-mix(in srgb, var(--warn) 45%, var(--line));
  font-weight: 650;
}

.ppe-main {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.ppe-main > label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
}

.ppe-norm-hint {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--muted);
}

.ppe-norm-view {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.ppe-name {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 650;
  line-height: 1.35;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.ppe-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin: 0;
  font-size: 0.88rem;
  color: var(--muted);
}

.ppe-card input,
.ppe-card select,
.ppe-card textarea {
  min-height: 48px;
  font-size: 1rem;
}

.ppe-fold {
  height: 0;
  overflow: hidden;
  min-width: 0;
}

.ppe-card.is-open .ppe-fold {
  height: auto;
  overflow: visible;
}

.ppe-fold-inner {
  min-height: 0;
}

.ppe-tray {
  margin-top: 14px;
  padding: 16px;
  border-radius: 12px;
  background: var(--sheet);
  border: 1px solid color-mix(in srgb, var(--line) 80%, var(--ink));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.85),
    0 12px 28px rgba(27, 36, 48, 0.05);
  display: grid;
  gap: 14px;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.38s var(--ease), transform 0.44s var(--ease);
}

.ppe-card.is-open .ppe-tray {
  opacity: 1;
  transform: none;
}

.ppe-tray .issue-block {
  background: color-mix(in srgb, var(--paper) 48%, var(--sheet));
  border-radius: 10px;
}

.ppe-card:not(.is-open) .ppe-tray {
  transition-duration: 0.2s, 0.22s;
}

.ppe-card .js-events {
  display: grid;
  gap: 14px;
}

.ppe-toggle {
  display: grid;
  justify-items: stretch;
  min-width: 8.2rem;
}

.ppe-toggle > .btn {
  grid-area: 1 / 1;
  transition: opacity 0.28s var(--ease), transform 0.28s var(--ease),
    background var(--t), border-color var(--t), color var(--t), box-shadow var(--t);
}

.ppe-card .js-fold {
  opacity: 0;
  transform: translateY(5px);
  pointer-events: none;
}

.ppe-card.is-open .js-fold {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.ppe-card.is-open .js-open {
  opacity: 0;
  transform: translateY(-5px);
  pointer-events: none;
}

.ppe-card .js-more {
  display: inline-flex;
  justify-self: start;
}

.issue-event {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  align-items: start;
}

.issue-event.is-arrive {
  animation: enter 0.4s var(--ease) both;
}

.issue-event-top {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}

.issue-block .span-2,
.issue-event .span-2 {
  grid-column: 1 / -1;
}

.issue-block .check-line {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
}

.issue-block .check-line .check {
  min-height: 48px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--sheet);
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 20px;
  position: sticky;
  top: 56px;
  z-index: 12;
  padding: 8px 0;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.layout-work > div:first-child,
.search,
.search input {
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.search {
  margin: 0 0 16px;
}

.list {
  display: grid;
  gap: 2px;
  max-height: min(72vh, 680px);
  overflow: auto;
}

.job {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  padding: 12px 14px;
  cursor: pointer;
  font: inherit;
  color: var(--ink);
  border-radius: 8px;
  transition: background var(--t);
}

.job:hover {
  background: color-mix(in srgb, var(--pine-soft) 55%, transparent);
}

.job[aria-selected="true"] {
  background: var(--pine-soft);
}

.job b {
  display: block;
  font-weight: 600;
}

.job span {
  color: var(--muted);
  font-size: 0.82rem;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 8px;
}

.tabs button {
  margin: 0;
  border: 0;
  border-radius: 8px;
  padding: 8px 14px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--t), color var(--t);
}

.tabs button:hover {
  background: color-mix(in srgb, var(--pine-soft) 55%, transparent);
  color: var(--ink);
}

.tabs button[aria-selected="true"] {
  background: var(--pine-soft);
  color: var(--ink);
}

.ui-table.mode-jobs th:last-child,
.ui-table.mode-jobs td:last-child {
  display: none;
}

.foot {
  border-top: 1px solid var(--line);
  padding: 10px 0 12px;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.4;
}

.foot .wrap {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 28px;
}

.foot p {
  margin: 0;
}

.foot a {
  color: var(--muted);
  transition: color var(--t);
}

.foot a:hover {
  color: var(--pine);
}

.foot-credit {
  margin: 0 0 0 auto;
  flex: none;
  white-space: nowrap;
}

.foot-credit a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.foot-credit img {
  width: 14px;
  height: 14px;
  border-radius: 2px;
}

.cookie-pill {
  position: fixed;
  left: 50%;
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 12px;
  width: max-content;
  max-width: min(36rem, calc(100% - 24px));
  padding: 8px 8px 8px 16px;
  border: 1px solid color-mix(in srgb, var(--pine) 22%, var(--line));
  border-radius: 20px;
  background: color-mix(in srgb, var(--sheet) 94%, transparent);
  color: var(--ink);
  box-shadow: 0 14px 36px rgba(27, 36, 48, 0.12);
  backdrop-filter: saturate(1.05) blur(14px);
  -webkit-backdrop-filter: saturate(1.05) blur(14px);
  transform: translateX(-50%);
  font-size: 0.88rem;
  line-height: 1.35;
}

.cookie-pill p {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
}

.cookie-pill a {
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
}

.cookie-pill a:hover {
  color: var(--pine);
}

.cookie-ok {
  flex: none;
  margin: 0;
  min-width: 44px;
  min-height: 44px;
  padding: 8px 16px;
  border: 0;
  border-radius: 999px;
  background: var(--pine);
  color: #fff;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

.cookie-ok:hover {
  background: var(--pine-hover);
}

.cookie-ok:focus-visible {
  outline: 2px solid var(--pine);
  outline-offset: 2px;
}

body.has-cookie {
  padding-bottom: calc(3.75rem + env(safe-area-inset-bottom, 0px));
}

.table-wrap {
  overflow-x: auto;
  margin: 16px 0 8px;
}

.muted {
  color: var(--muted);
}

.layout-work {
  display: grid;
  grid-template-columns: minmax(260px, 320px) 1fr;
  gap: 40px;
  padding: 28px 0 64px;
  align-items: start;
}

.job-result h2 {
  margin: 0 0 6px;
  font-size: 1.8rem;
  letter-spacing: -0.03em;
}

.job-result.is-swap {
  animation: enter 0.42s var(--ease) both;
}

.check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--ink);
  white-space: nowrap;
}

.check input {
  width: auto;
}

@media (max-width: 800px) {
  html {
    font-size: 17px;
  }

  .form-grid,
  .layout-work,
  .issue-block,
  .issue-event,
  .norm-meta {
    grid-template-columns: 1fr;
  }

  .span-2 {
    grid-column: auto;
  }

  .top-inner {
    gap: 8px 16px;
    padding: 8px 0 6px;
  }

  .mark {
    font-size: 0.9rem;
  }

  nav {
    gap: 0 14px;
  }

  nav a {
    font-size: 0.9rem;
  }

  .hero {
    min-height: 0;
    padding: 28px 0 48px;
    grid-template-columns: 1fr;
    gap: 28px;
    overflow-x: clip;
  }

  .hero-art {
    justify-self: center;
    width: min(100%, 380px);
  }

  .ghost-card {
    transform: rotate(1.2deg);
    padding: 20px 18px 16px;
  }

  .ghost-grid i {
    height: 20px;
  }

  .hero .actions {
    margin-top: 24px;
  }

  .rest {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 32px 0 36px;
  }

  .rest-copy {
    border-left: 0;
    padding-left: 0;
    border-top: 2px solid color-mix(in srgb, var(--pine) 35%, var(--line));
    padding-top: 20px;
  }

  .panel {
    padding: 16px;
  }

  .toolbar .btn,
  .toolbar a.btn {
    min-height: 44px;
  }

  .page-head {
    padding: 24px 0 8px;
  }

  .content h1 {
    font-size: clamp(1.6rem, 6vw, 2.2rem);
  }

  .tabs button,
  .ppe-filters button {
    min-height: 44px;
  }
}

@media (max-width: 560px) {
  .top-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .toolbar {
    top: 6.25rem;
  }

  .cookie-pill {
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    transform: none;
    padding: 10px 10px 10px 14px;
  }

  .hero .actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    margin-top: 22px;
  }

  .hero .actions .btn {
    width: 100%;
    max-width: 22rem;
  }

  .foot .wrap {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
  }

  .foot-credit {
    margin: 0;
  }

  .toolbar .btn,
  .toolbar a.btn {
    flex: 1 1 calc(50% - 8px);
  }

  .toolbar a.btn-ghost {
    flex: 1 1 100%;
  }
}

@media (max-width: 800px) and (max-height: 480px) {
  .hero-art {
    display: none;
  }

  .hero {
    padding: 16px 0 28px;
  }
}

@media (pointer: coarse) {
  input,
  select,
  textarea {
    font-size: 16px;
    min-height: 44px;
  }
}

@media (hover: none) {
  .btn:hover,
  .btn-ghost:hover,
  .btn-text:hover {
    transform: none;
    box-shadow: none;
  }
}

.print-only {
  display: none;
}

.print-stage {
  position: absolute;
  left: -12000px;
  top: 0;
  width: 297mm;
  min-height: 210mm;
  background: #fff;
  pointer-events: none;
}

.sheet-a4 {
  background: #fff;
  border: 1px solid #cfc9bd;
  box-shadow: 0 18px 40px rgba(27, 36, 48, 0.06);
  padding: 22px 24px 28px;
  margin: 28px 0 36px;
  color: #000;
  font-family: "Times New Roman", Times, serif;
}

.sheet-a4 h2,
.form-766n-title {
  text-align: center;
  font-family: "Times New Roman", Times, serif;
  font-size: 15pt;
  margin: 0 0 14px;
  font-weight: 700;
  letter-spacing: 0;
  color: #000;
}

.form-side {
  margin: 0 0 6px;
  text-align: center;
  font-family: "Times New Roman", Times, serif;
  font-size: 11pt;
  font-weight: 700;
  color: #000;
}

.form-extra {
  margin: 0 0 10px;
  padding: 5px 8px;
  text-align: center;
  font-family: "Times New Roman", Times, serif;
  font-size: 9pt;
  font-weight: 700;
  color: #000;
  border: 1px solid #000;
}

.duty-head {
  margin: 0 0 12px;
  font-family: "Times New Roman", Times, serif;
  font-size: 11pt;
  color: #000;
}

.duty-head p {
  margin: 0 0 8px;
}

.form-duty {
  font-size: 9pt;
  table-layout: fixed;
  width: 100%;
}

.form-duty thead tr:first-child th:nth-child(1) {
  width: 20%;
}

.form-duty thead tr:first-child th:nth-child(2) {
  width: 16%;
}

.form-duty thead tr:first-child th:nth-child(3) {
  width: 28%;
}

.form-duty thead tr:first-child th:nth-child(4) {
  width: 36%;
}

.form-duty th,
.form-duty td {
  font-size: 9pt;
}

.form-766n,
.form-766n table,
.sheet-a4 table {
  color: #000;
  font-family: "Times New Roman", Times, serif;
}

.card-head {
  display: grid;
  grid-template-columns: 1.45fr 0.85fr;
  gap: 0;
  border: 1px solid #000;
}

.card-head .col {
  padding: 8px 10px;
}

.card-head .col + .col {
  border-left: 1px solid #000;
}

.card-head p {
  margin: 0 0 6px;
  font-size: 11pt;
}

.sheet-a4 table,
.form-766n table {
  width: 100%;
  border-collapse: collapse;
  font-size: 10pt;
}

.sheet-a4 th,
.sheet-a4 td,
.form-766n th,
.form-766n td {
  border: 1px solid #000;
  padding: 4px 5px;
  vertical-align: top;
  text-align: center;
  font-weight: 400;
}

.sheet-a4 thead th,
.form-766n thead th {
  background: #fff;
  font-weight: 700;
  font-size: 9pt;
}

.sheet-a4 td:first-child,
.form-766n td:first-child,
.sheet-a4 th:first-child,
.form-766n th:first-child {
  text-align: left;
}

.sign-row {
  display: grid;
  grid-template-columns: 1.5fr 0.8fr 0.9fr;
  gap: 16px;
  margin-top: 18px;
  font-size: 11pt;
}

.sign-row div {
  border-top: 1px solid #000;
  padding-top: 4px;
  text-align: center;
}

.sign-row div:first-child {
  text-align: left;
}

.table-order {
  width: 100%;
  table-layout: fixed;
}

.table-order th:nth-child(1) {
  width: 22%;
}

.table-order th:nth-child(2) {
  width: 30%;
}

.table-order th:nth-child(3) {
  width: 10%;
}

.table-order th:nth-child(4) {
  width: 26%;
}

.table-order th:nth-child(5) {
  width: 12%;
}

.table-order tbody td {
  height: 22px;
}

.sheet-note {
  margin: 0 0 10px;
  font-size: 0.88rem;
}

.form-back {
  font-size: 9pt;
  table-layout: fixed;
  width: 100%;
}

.form-back thead tr:first-child th:nth-child(1) {
  width: 18%;
}

.form-back thead tr:first-child th:nth-child(2) {
  width: 14%;
}

.form-back thead tr:first-child th:nth-child(3),
.form-back thead tr:first-child th:nth-child(4) {
  width: 34%;
}

.form-back th,
.form-back td {
  font-size: 9pt;
}

.pagebreak {
  break-before: page;
  page-break-before: always;
}

@keyframes enter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.hero-art {
  animation: enter 0.55s var(--ease) both;
}

.reveal {
  animation: enter 0.55s var(--ease) both;
}

.will-reveal {
  opacity: 0;
  transform: translateY(12px);
}

.will-reveal.reveal {
  animation: enter 0.55s var(--ease) forwards;
}

@view-transition {
  navigation: auto;
}

::view-transition-old(root) {
  animation: fade 180ms var(--ease) reverse;
}

::view-transition-new(root) {
  animation: fade 280ms var(--ease);
}

::view-transition-group(site-header) {
  animation-duration: 0.01ms;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .btn:hover,
  .btn-text:hover {
    transform: none;
    box-shadow: none;
  }
}

@media print {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    box-shadow: none !important;
  }

  body::before,
  .hero-art,
  .rest-mark,
  .cookie-pill {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    font-size: 11pt;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .no-print {
    display: none !important;
  }

  .print-only {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
  }

  .will-reveal,
  .sheet-a4 {
    opacity: 1 !important;
    transform: none !important;
    visibility: visible !important;
  }

  .sheet-a4 {
    border: 0;
    box-shadow: none;
    margin: 0;
    padding: 16mm 12mm;
    color: #000;
  }

  .wrap,
  .wrap.wide {
    width: auto;
  }

  .print-only .table-wrap,
  .sheet-a4 .table-wrap {
    overflow: visible;
  }

  .form-766n table {
    width: 100%;
    table-layout: fixed;
    word-break: normal;
    overflow-wrap: break-word;
    hyphens: manual;
  }

  .form-back td:nth-child(6),
  .form-back td:nth-child(9) {
    vertical-align: bottom;
  }

  @page {
    size: A4 landscape;
    margin: 0;
    @top-left { content: none; }
    @top-center { content: none; }
    @top-right { content: none; }
    @bottom-left { content: none; }
    @bottom-center { content: none; }
    @bottom-right { content: none; }
  }

  html::before,
  html::after {
    content: "";
    position: fixed;
    left: 0;
    right: 0;
    height: 12mm;
    background: #fff;
    z-index: 99999;
  }

  html::before {
    top: 0;
  }

  html::after {
    bottom: 0;
  }

  .form-back thead tr:first-child th:nth-child(1) {
    width: 18%;
  }

  .form-back thead tr:first-child th:nth-child(2) {
    width: 14%;
  }

  .form-back thead tr:first-child th:nth-child(3),
  .form-back thead tr:first-child th:nth-child(4) {
    width: 34%;
  }

  .form-back tbody td,
  .form-duty tbody td {
    height: 22px;
  }

  .form-duty thead tr:first-child th:nth-child(1) {
    width: 20%;
  }

  .form-duty thead tr:first-child th:nth-child(2) {
    width: 16%;
  }

  .form-duty thead tr:first-child th:nth-child(3) {
    width: 28%;
  }

  .form-duty thead tr:first-child th:nth-child(4) {
    width: 36%;
  }
}
