:root {
    --ink: #1c1915;
    --muted: #6f675c;
    --paper: #f3efe6;
    --card: #fffdf8;
    --line: #e4d9c8;
    --pine: #145c45;
    --pine-ink: #10281f;
    --gold: #e2b15a;
    --coral: #9d3b2f;
    --shadow: 0 18px 40px rgba(48, 36, 18, 0.08);
    --sidebar: 248px;
    --sans: Outfit, "Avenir Next", "Segoe UI", sans-serif;
    --serif: Newsreader, "Iowan Old Style", Palatino, "Palatino Linotype", serif;
    color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body { margin: 0; padding: 0; }
body {
    min-height: 100vh;
    color: var(--ink);
    font-family: var(--sans);
    font-size: 15px;
    line-height: 1.5;
    background-color: var(--paper);
    background-image:
        linear-gradient(rgba(20, 40, 32, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(20, 40, 32, 0.035) 1px, transparent 1px);
    background-size: 28px 28px;
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--pine); }
img, svg { display: block; }
h1, h2, h3, p { margin-top: 0; }
.icon { width: 18px; height: 18px; flex: none; }

.skip {
    position: absolute;
    left: -999px;
    top: 8px;
    background: white;
    padding: 8px 12px;
    z-index: 80;
}
.skip:focus { left: 12px; }

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

.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sidebar);
    display: flex;
    flex-direction: column;
    padding: 18px 14px;
    background: var(--pine-ink);
    color: #d7e4dc;
    border-top: 3px solid var(--gold);
    z-index: 30;
    overflow: auto;
}
.main { margin-left: var(--sidebar); min-height: 100vh; }
.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 22px;
    color: inherit;
    text-decoration: none;
}
.brand strong { display: block; color: #fff; font-size: 16px; }
.brand small { display: block; color: #9eb4a8; font-size: 12px; }
.monogram {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--gold);
    color: #1a160f;
    font-weight: 700;
    letter-spacing: 0.04em;
    font-size: 13px;
    flex: none;
}
.side-nav { display: flex; flex-direction: column; gap: 4px; }
.nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    color: #d5e4db;
    text-decoration: none;
}
.nav-link:hover { background: rgba(255, 255, 255, 0.06); }
.nav-link.is-active {
    background: rgba(226, 177, 90, 0.16);
    color: #f8f1df;
    box-shadow: inset 3px 0 0 var(--gold);
}
button.nav-link {
    width: 100%;
    background: transparent;
    border: 0;
    text-align: left;
}
.side-user { margin-top: auto; padding-top: 18px; }
.side-user form { margin: 8px 0 0; }
.who strong, .who span {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.who span { color: #9eb4a8; font-size: 13px; }

.backdrop {
    position: fixed;
    inset: 0;
    background: rgba(16, 22, 18, 0.48);
    z-index: 25;
}
.menu-btn {
    display: none;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: var(--card);
}
.topbar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 28px;
    background: rgba(243, 239, 230, 0.9);
    backdrop-filter: blur(12px);
}
.topbar-title {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 15px;
}
.gap-top { margin-top: 16px; }
.gap-bottom { margin-bottom: 14px; }
.page { width: 100%; max-width: 1200px; margin: 0 auto; padding: 8px 28px 56px; }
.page-head, .record-head { margin: 8px 0 18px; }
.record-head, .page-head.split {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
}
.page-head h1, .record-head h1 {
    margin: 0;
    font-size: 32px;
    line-height: 1.15;
    letter-spacing: -0.03em;
}
.eyebrow {
    margin: 0 0 4px;
    font-size: 12px;
    font-weight: 650;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--muted);
}
.intro { color: var(--muted); max-width: 68ch; }

.stat-grid, .type-grid, .layout-2, .create-row { display: grid; gap: 14px; }
.stat-grid { grid-template-columns: repeat(4, 1fr); }
.type-grid { grid-template-columns: repeat(3, 1fr); margin-top: 14px; }
.layout-2 { grid-template-columns: 1.55fr 0.9fr; margin-top: 14px; }
.create-row { grid-template-columns: repeat(3, 1fr); margin-bottom: 14px; }

.stat, .panel, .type-card, .create-chip, .sheet, .closed-card, .auth-shell {
    background: var(--card);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}
.stat, .panel, .type-card, .create-chip { border-radius: 18px; }
.stat { padding: 16px 16px 14px; border-top: 3px solid var(--accent, var(--pine)); }
.stat-pine { --accent: #145c45; }
.stat-blue { --accent: #1e4d6b; }
.stat-gold { --accent: #b8862f; }
.stat-coral { --accent: #9d3b2f; }
.stat span { color: var(--muted); font-size: 13px; font-weight: 600; }
.stat strong {
    display: block;
    margin-top: 8px;
    font-size: 32px;
    letter-spacing: -0.04em;
    font-variant-numeric: tabular-nums;
}
.panel { padding: 16px 16px 8px; }
.panel-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    padding: 2px 4px 12px;
}
.panel-head h2 { margin: 0; font-size: 18px; letter-spacing: -0.02em; }
.panel-foot { padding: 8px 4px 10px; color: var(--muted); font-size: 13px; }

.type-card, .create-chip {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 18px;
    text-decoration: none;
    color: inherit;
    min-height: 180px;
}
.create-chip { min-height: 0; }
.type-card:hover, .create-chip:hover { border-color: #c9b89a; transform: translateY(-2px); }
.type-card .code, .create-chip span, .code-chip {
    color: #7c2d2d;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.01em;
}
.type-card strong, .create-chip strong { font-size: 18px; letter-spacing: -0.02em; }
.type-card p { margin: 0; color: var(--muted); font-size: 14px; }
.type-card em { font-style: normal; font-size: 13px; color: var(--pine); font-weight: 650; }

.chart {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 8px;
    align-items: end;
    height: 160px;
    padding: 4px 4px 12px;
}
.bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    height: 100%;
    gap: 6px;
    min-width: 0;
}
.bar b { font-size: 11px; font-weight: 650; min-height: 1em; }
.bar-track {
    width: 100%;
    height: 96px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}
.bar-fill {
    display: block;
    width: 100%;
    max-width: 22px;
    background: linear-gradient(#1f7a5c, #145c45);
    border-radius: 6px 6px 3px 3px;
}
.bar span { font-size: 11px; color: var(--muted); }
.w-0 { height: 0; } .w-5 { height: 5%; } .w-10 { height: 10%; } .w-15 { height: 15%; }
.w-20 { height: 20%; } .w-25 { height: 25%; } .w-30 { height: 30%; } .w-35 { height: 35%; }
.w-40 { height: 40%; } .w-45 { height: 45%; } .w-50 { height: 50%; } .w-55 { height: 55%; }
.w-60 { height: 60%; } .w-65 { height: 65%; } .w-70 { height: 70%; } .w-75 { height: 75%; }
.w-80 { height: 80%; } .w-85 { height: 85%; } .w-90 { height: 90%; } .w-95 { height: 95%; }
.w-100 { height: 100%; }

.data-table { width: 100%; border-collapse: collapse; }
.data-table th {
    text-align: left;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
    font-weight: 650;
    padding: 8px 10px;
    border-bottom: 1px solid var(--line);
}
.data-table td {
    padding: 12px 10px;
    border-bottom: 1px solid #efe7da;
    vertical-align: middle;
}
.data-table a { color: inherit; font-weight: 650; text-decoration: none; }
.data-table a:hover { text-decoration: underline; }
.nowrap { white-space: nowrap; }
.cluster { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cluster .link-field { flex: 1 1 240px; width: auto; }

.badge {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 0 8px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.01em;
    white-space: nowrap;
}
.badge-ok { background: #e5f4ec; color: #0f6b45; }
.badge-draft { background: #f8efd8; color: #8a5a12; }
.badge-danger { background: #f8e8e4; color: #9d3b2f; }
.badge-muted { background: #eeeae3; color: #5e584e; }
.badge-ink { background: #e7eef3; color: #1e4d6b; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 40px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid transparent;
    text-decoration: none;
    font-weight: 650;
    font-size: 14px;
    line-height: 1;
}
.btn-primary { background: var(--pine); color: #fff; }
.btn-primary:hover { background: #0f4a38; }
.btn-ghost { background: transparent; border-color: #d9d0c2; color: var(--ink); }
.btn-ghost:hover { background: #f6f1e6; }
.btn-danger { background: #f8ece8; color: var(--coral); border-color: #efd2cb; }
.btn-danger:hover { background: #f3ddd7; }
.btn-small { min-height: 34px; padding: 0 10px; font-size: 13px; }
.btn-block { width: 100%; }
.icon-btn {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 0;
    background: transparent;
    color: #8a5a4a;
}
.icon-btn:hover { background: #f8ece8; }

.chip {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid var(--line);
    text-decoration: none;
    color: var(--ink);
    background: var(--card);
    font-size: 14px;
    font-weight: 650;
}
.chip.is-on { background: var(--pine-ink); color: #fff; border-color: var(--pine-ink); }

.alert { border-radius: 14px; padding: 12px 14px; margin-bottom: 14px; }
.alert ul { margin: 0; padding-left: 18px; }
.alert-ok { background: #e7f5ee; color: #0d5a3c; }
.alert-error { background: #fbeceb; color: #8d2e24; }
.empty { padding: 28px 12px; text-align: center; color: var(--muted); }
.empty strong { display: block; color: var(--ink); font-size: 18px; margin-bottom: 6px; }
.empty .btn { margin-top: 12px; }
.pager { display: flex; gap: 12px; align-items: center; justify-content: flex-end; padding: 12px 4px; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; margin-bottom: 14px; }
.filters .field { min-width: 150px; flex: 1; }

.field label, .form-section legend {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 700;
}
.field input, .field select, .field textarea, .link-field, .editor-table input, .editor-table textarea {
    width: 100%;
    border: 1px solid #ddd4c6;
    background: #fff;
    border-radius: 10px;
    padding: 10px 12px;
}
.field textarea { min-height: 96px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus,
.editor-table input:focus, .editor-table textarea:focus, .link-field:focus {
    outline: 2px solid var(--pine);
    border-color: var(--pine);
}
.help { margin: 6px 0 0; color: var(--muted); font-size: 13px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.span-2 { grid-column: 1 / -1; }
.form-section {
    border: 1px solid var(--line);
    border-radius: 18px;
    background: var(--card);
    padding: 16px;
    margin: 0 0 14px;
}
.form-section legend { padding: 0 6px; }
.form-actions {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    background: rgba(255, 253, 248, 0.94);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 10px;
}
.period-form [data-periods] { display: none; }
.period-form:has([data-period] option[value="harian"]:checked) [data-periods~="harian"],
.period-form:has([data-period] option[value="bulanan"]:checked) [data-periods~="bulanan"],
.period-form:has([data-period] option[value="tahunan"]:checked) [data-periods~="tahunan"] { display: block; }
.share-form [data-custom-expiry] { display: none; }
.share-form:has([data-expiry-preset] option[value="custom"]:checked) [data-custom-expiry] { display: block; }

.table-scroll, .sheet-scroll { overflow-x: auto; }
.editor-table { width: 100%; border-collapse: collapse; min-width: 720px; }
.editor-table.cols-6 { min-width: 980px; }
.editor-table.cols-8 { min-width: 1180px; }
.editor-table th {
    text-align: left;
    font-size: 12px;
    color: var(--muted);
    padding: 8px;
    border-bottom: 1px solid var(--line);
}
.editor-table td { border-bottom: 1px solid #efe7da; vertical-align: top; padding: 4px; }
.editor-table input, .editor-table textarea {
    border: 0;
    background: transparent;
    border-radius: 8px;
    padding: 8px;
}
.editor-table textarea { min-height: 64px; resize: vertical; }
.editor-table input:focus, .editor-table textarea:focus { background: #fff; }
.row-no, .sheet-grid .num { width: 42px; text-align: center; color: var(--muted); font-variant-numeric: tabular-nums; }
.row-act { width: 46px; }

.sheet {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    padding: 22px;
    color: #221c16;
}
.kop { width: 100%; border-collapse: collapse; background: #fff; }
.kop td { border: 1px solid #1a1a1a; vertical-align: middle; }
.kop-logo { width: 30%; text-align: center; padding: 8px 12px; }
.kop-logo img { width: min(190px, 100%); height: auto; margin: 0 auto; }
.kop-title {
    text-align: center;
    font-weight: 700;
    letter-spacing: 0.14em;
    font-size: 16px;
    padding: 10px;
}
.kop-code {
    text-align: center;
    font-weight: 700;
    color: #7c2d2d;
    font-size: 13px;
    padding: 8px 10px;
    white-space: nowrap;
}
.kop-date, .kop-rev {
    text-align: center;
    font-size: 12px;
    font-weight: 650;
    padding: 6px 8px;
    white-space: nowrap;
}
.kop-rev { width: 78px; }
.watermark {
    position: absolute;
    left: 50%;
    top: 46%;
    transform: translate(-50%, -50%) rotate(-14deg);
    font-size: 92px;
    font-weight: 700;
    letter-spacing: 0.18em;
    color: rgba(157, 59, 47, 0.12);
    pointer-events: none;
    z-index: 0;
}
.kop, .sheet-title, .sheet-period, .sheet-scroll, .sheet-notes, .sign-row { position: relative; z-index: 1; }
.sheet-title {
    text-align: center;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    margin: 22px 8px 6px;
}
.sheet-period { text-align: center; margin: 0 0 16px; }
.sheet-grid { width: 100%; border-collapse: collapse; font-size: 12px; }
.sheet-grid.cols-4 { min-width: 640px; }
.sheet-grid.cols-6 { min-width: 820px; }
.sheet-grid.cols-8 { min-width: 1040px; }
.sheet-grid.cols-9 { min-width: 1180px; }
.sheet-grid th, .sheet-grid td {
    border: 1px solid #cfc4b2;
    padding: 7px 8px;
    vertical-align: top;
    text-align: left;
}
.sheet-grid th { background: #f3eee4; font-size: 11px; }
.sheet-grid td { height: 30px; }
.sheet-notes { margin-top: 14px; }
.sheet-notes h2 { font-size: 14px; margin-bottom: 4px; }
.sheet-notes p { margin: 0; white-space: pre-wrap; }
.sign-row { display: flex; margin-top: 28px; }
.sign-row.is-split { justify-content: space-between; }
.sign-block { width: min(240px, 46%); font-size: 14px; }
.sign-block p { margin-bottom: 0; }
.sign-gap { height: 64px; }
.sign-line { border-top: 1px solid #221c16; margin-bottom: 6px; }
.sign-block strong, .sign-block span { display: block; min-height: 1.2em; }
.sign-block span { color: #5e564c; font-size: 13px; }

.link-list { display: flex; flex-direction: column; gap: 12px; }
.link-row { border-top: 1px solid var(--line); padding-top: 12px; }
.link-field { font-size: 13px; background: #faf7f2; }
.meta-line { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; color: var(--muted); font-size: 13px; }

.auth { display: grid; place-items: center; padding: 24px; }
.auth-shell {
    width: min(980px, 100%);
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    border-radius: 24px;
    overflow: hidden;
    min-height: 560px;
}
.auth-brand {
    background: var(--pine-ink);
    color: #f4efe6;
    padding: 36px 32px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 24px;
}
.auth-brand h1 { font-family: var(--serif); font-size: 40px; line-height: 1.05; margin: 12px 0; font-weight: 650; }
.auth-brand p { color: #c9d7ce; max-width: 36ch; }
.code-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.code-list li { display: flex; flex-direction: column; }
.code-list b { color: var(--gold); font-size: 13px; }
.code-list span { color: #d7e4dc; }
.auth-panel { padding: 36px 32px; display: flex; flex-direction: column; justify-content: center; }
.auth-panel h2 { font-size: 28px; letter-spacing: -0.03em; margin-bottom: 6px; }
.credential-hint {
    background: #f6f1e6;
    border: 1px solid #e4d8c4;
    border-radius: 12px;
    padding: 12px 14px;
    margin: 0 0 16px;
}
.stack { display: flex; flex-direction: column; gap: 12px; }

.public-body { background: #efeae1; }
.public-bar {
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
    padding: 12px 20px;
    background: var(--pine-ink);
    color: #f4efe6;
}
.public-brand, .public-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.public-bar strong { display: block; color: #fff; }
.public-bar .btn-primary { background: var(--gold); color: #1a160f; }
.public-bar .btn-primary:hover { background: #f0c56e; }
.public-bar .btn-ghost { border-color: rgba(255, 255, 255, 0.35); color: #fff; }
.public-bar .btn-ghost:hover { background: rgba(255, 255, 255, 0.1); }
.share-intro { display: flex; gap: 16px; align-items: center; margin-bottom: 12px; }
.share-intro img { width: 148px; height: auto; }
.share-intro h1 { margin: 0 0 4px; font-size: 26px; }
.share-intro p { margin: 0; color: var(--muted); }
.public-bar .public-brand span { color: #c9d7ce; font-size: 13px; }
.public-main { max-width: 1200px; margin: 0 auto; padding: 24px 16px 48px; }
.closed { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.closed-card { width: min(480px, 100%); border-radius: 20px; padding: 32px 28px; text-align: center; }
.closed-card .monogram { margin: 0 auto 8px; }
.closed-card h1 { font-family: var(--serif); font-size: 32px; margin: 8px 0 10px; }
.closed-card p { color: var(--muted); }

.toast {
    position: fixed;
    bottom: 18px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--pine-ink);
    color: #f4efe6;
    padding: 10px 16px;
    border-radius: 999px;
    z-index: 70;
    font-size: 14px;
}

@media (max-width: 1000px) {
    .stat-grid { grid-template-columns: 1fr 1fr; }
    .layout-2, .type-grid, .create-row { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
    .sidebar { transform: translateX(-105%); transition: transform 0.2s ease; }
    .sidebar.is-open { transform: none; }
    .main { margin-left: 0; }
    .menu-btn { display: inline-flex; }
    .auth-shell { grid-template-columns: 1fr; }
    .auth-brand { padding: 24px; }
    .auth-brand h1 { font-size: 32px; }
}
@media (max-width: 760px) {
    .page, .topbar { padding-left: 16px; padding-right: 16px; }
    .page-head h1, .record-head h1 { font-size: 26px; }
    .record-head, .page-head.split, .form-actions, .public-bar { flex-direction: column; align-items: stretch; }
    .form-grid { grid-template-columns: 1fr; }
    .span-2 { grid-column: auto; }
    .share-intro { flex-direction: column; align-items: flex-start; }
    .sheet { padding: 14px; }
    .kop-title { letter-spacing: 0.04em; font-size: 13px; }
    .kop-code, .kop-date, .kop-rev { white-space: normal; }
    .sheet-title { font-size: 16px; }
    .data-table thead { display: none; }
    .data-table, .data-table tbody, .data-table tr, .data-table td { display: block; width: 100%; }
    .data-table tr {
        margin-bottom: 12px;
        border: 1px solid var(--line);
        border-radius: 14px;
        overflow: hidden;
        background: #fff;
    }
    .data-table td {
        display: flex;
        justify-content: space-between;
        gap: 12px;
        align-items: center;
    }
    .data-table td::before {
        content: attr(data-label);
        color: var(--muted);
        font-size: 12px;
        font-weight: 700;
    }
    .data-table td.actions { justify-content: flex-start; }
    .data-table td.actions::before { display: none; }
    input, select, textarea { font-size: 16px; }
}
@media (max-width: 560px) {
    .stat-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; }
}
@page sheet-portrait { size: A4 portrait; margin: 12mm; }
@page sheet-landscape { size: A4 landscape; margin: 10mm; }
@media print {
    @page { size: A4 landscape; margin: 10mm; }
    .sheet.is-portrait { page: sheet-portrait; }
    .sheet.is-landscape { page: sheet-landscape; }
    body { background: #fff !important; }
    .sidebar, .topbar, .backdrop, .no-print, .toast, .alert, .skip { display: none !important; }
    .main { margin: 0 !important; }
    .page, .public-main { max-width: none; padding: 0; }
    .sheet { box-shadow: none; border: 0; border-radius: 0; width: 100%; }
    .sheet-scroll { overflow: visible; }
    .sheet-grid thead { display: table-header-group; }
    .sheet-grid tr { break-inside: avoid; page-break-inside: avoid; }
    .sheet-grid, .sheet-grid.cols-4, .sheet-grid.cols-6, .sheet-grid.cols-8, .sheet-grid.cols-9 { min-width: 0 !important; font-size: 9px; }
    .sheet, .kop, .sheet-grid th { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
    a { color: inherit; text-decoration: none; }
}

:focus-visible { outline: 2px solid var(--pine); outline-offset: 2px; }
.sidebar :focus-visible { outline-color: var(--gold); }
body.nav-open { overflow: hidden; }

.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 18px; margin: 8px 0 0; }
.facts div { margin: 0; }
.facts dt { color: var(--muted); font-size: 12px; }
.facts dd { margin: 2px 0 0; }
.shot-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.shot-grid figure { margin: 0; width: 148px; }
.shot-grid img { width: 148px; height: 110px; object-fit: cover; border-radius: 12px; border: 1px solid var(--line); background: #fff; }
.shot-grid figcaption { margin-top: 6px; }
.choice-row { display: flex; flex-wrap: wrap; gap: 12px 18px; }
.choice { display: flex; align-items: center; gap: 8px; font-weight: 500; }
.label-like { display: block; margin-bottom: 6px; font-weight: 600; }
.voice-choices { display: grid; gap: 10px; }
.voice-choices .choice { align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.voice-live {
    width: min(100%, 640px); min-height: 72px; margin: 0; padding: 14px 16px;
    border-radius: 14px; background: #fff; border: 1px solid var(--line);
    font-size: 18px; line-height: 1.45;
}
.voice-live.is-empty { color: var(--muted); font-size: 15px; }
.voice-preview { margin-top: 8px; }
.voice-preview h2 { margin: 0 0 8px; font-size: 16px; }
.voice-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.voice-table th, .voice-table td { border: 1px solid var(--line); padding: 8px; vertical-align: top; text-align: left; min-width: 140px; }
.voice-table th { background: #f7f1e6; font-weight: 650; }
textarea.cell-text { display: block; width: 100%; min-width: 140px; min-height: 64px; margin: 0 0 8px; resize: vertical; font-size: 16px; }
.cell-date { width: 100%; min-width: 140px; }
.cell-mic {
    border: 0; border-radius: 999px; padding: 6px 12px; background: var(--pine); color: #fff;
    font: inherit; font-size: 13px; font-weight: 650; cursor: pointer;
}
.cell-mic.is-on { background: var(--coral); }
.voice-stage { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 8px 0 4px; }
.voice-mic {
    width: 116px; height: 116px; border: 0; border-radius: 50%;
    background: var(--pine); color: #fff; font: inherit; font-weight: 650; cursor: pointer;
    box-shadow: 0 10px 24px rgba(20, 92, 69, 0.28);
}
.voice-mic[data-recording="1"] { background: var(--coral); box-shadow: 0 10px 24px rgba(157, 59, 47, 0.28); }
.voice-play { display: block; width: min(100%, 440px); margin-top: 8px; }
.paraf-blank { display: block; min-height: 36px; color: var(--muted); font-size: 11px; text-align: center; padding-top: 10px; }
.paraf-space { display: block; min-height: 28px; }
@media (max-width: 760px) {
    .facts { grid-template-columns: 1fr; }
}
