:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #20222c;
  color: #f5f5f8;
  font-synthesis: none;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .5; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, [contenteditable]:focus-visible, .employee-card:focus-visible { outline: 2px solid #6a8cff; outline-offset: 2px; }
::selection { background: #6555a6; color: #fff; }

.shell { max-width: 1440px; min-height: 100vh; margin: 0 auto; padding: 24px 22px 64px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.brand { display: flex; align-items: center; gap: 11px; font-size: 13px; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; color: #f6f7fb; }
.brand-mark { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: linear-gradient(135deg, #32d678, #25a960); box-shadow: 0 8px 24px #22b66526; font-size: 17px; }
.local-label { font-size: 12px; color: #99a3bb; display: inline-flex; align-items: center; gap: 7px; }
.local-dot { width: 7px; height: 7px; border-radius: 50%; background: #39d880; box-shadow: 0 0 0 4px #39d88021; }
.local-label.offline .local-dot { background: #ff7f8d; box-shadow: 0 0 0 4px #ff7f8d21; }
.connection-screen { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.connection-card { width: min(100%, 480px); background: #171923; border: 1px solid #383e51; border-radius: 13px; padding: 30px; box-shadow: 0 20px 55px #090b1455; }
.connection-card h1 { margin: 26px 0 10px; font-size: 27px; }
.connection-card p { color: #aebbd4; line-height: 1.5; }
.connection-card form { display: grid; gap: 12px; margin-top: 24px; }
.connection-card label { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: #c4cee2; }
.connection-card .primary-button { margin-top: 5px; }
.connection-error { min-height: 20px; margin: 2px 0 0; color: #ffadb4 !important; font-size: 13px; }
.discord-login { width: 100%; margin-top: 20px; }
.topbar-right { display: flex; align-items: center; justify-content: flex-end; gap: 12px; flex-wrap: wrap; }
.account-label { display: inline-flex; align-items: center; gap: 7px; color: #d7dfee; font-size: 12px; }
.account-label strong { background: #303750; border: 1px solid #485577; border-radius: 999px; padding: 4px 8px; color: #dbe4ff; font-size: 10px; text-transform: uppercase; letter-spacing: .04em; }
.access-panel { background: #171923; border: 1px solid #353947; border-radius: 10px; padding: 24px; }
.access-panel h2 { margin: 0 0 10px; font-size: 20px; }
.access-panel > p { margin: 0 0 20px; color: #aebbd4; line-height: 1.5; font-size: 13px; }
.access-users { display: grid; gap: 10px; }
.access-user { display: grid; grid-template-columns: minmax(190px, 1fr) minmax(220px, 360px) auto; align-items: end; gap: 14px; padding: 14px; border: 1px solid #393f50; border-radius: 8px; background: #1e222e; }
.access-identity { align-self: center; min-width: 0; }
.access-identity strong, .access-identity small { display: block; overflow-wrap: anywhere; }
.access-identity small { margin-top: 4px; color: #98a7c6; }
.access-role span { display: block; margin-bottom: 6px; color: #aebbd4; font-size: 11px; font-weight: 800; text-transform: uppercase; }
.access-role .select { width: 100%; }
.access-fixed { grid-column: 2 / -1; align-self: center; color: #e2e9ff; font-size: 12px; font-weight: 800; }
.case-reader { display: grid; gap: 16px; }
.read-panel { background: #171923; border: 1px solid #353947; border-radius: 9px; padding: 20px 24px; min-width: 0; }
.read-panel h2 { font-size: 22px; margin: 9px 0 3px; }
.read-panel p { margin: 10px 0 0; color: #d8dfed; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
.read-panel .read-meta { color: #99a9c6; font-size: 12px; }
.read-report { margin-top: 14px; min-height: 70px; line-height: 1.6; color: #f1f3f9; overflow-wrap: anywhere; }
.read-report p { color: inherit; margin: .4em 0; }
.read-list { display: grid; gap: 8px; margin-top: 12px; }
.read-item { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; padding: 11px 13px; border: 1px solid #3d4456; border-radius: 7px; background: #202532; font-size: 13px; }
.read-item a { color: #a9beff; }
.read-item span { color: #aebcdb; }
.read-panel .legacy-evidence { border-top: 1px solid #393f50; padding-top: 15px; }
.editor-sync-notice { color: #f5cf87; background: #49371f; border: 1px solid #8c6535; border-radius: 7px; padding: 12px 15px; margin: -20px 0 20px; font-size: 13px; }
.editor-sync-notice:empty { display: none; }
.view-surface { border: 1px solid #323745; border-radius: 13px; overflow: hidden; background: #171923; box-shadow: 0 20px 55px #090b1424; }

.hero { min-height: 192px; background: rgb(255, 255, 0); padding: 30px 22px 28px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.hero h1 { margin: 0 0 17px; display: flex; align-items: center; gap: 11px; color: #171923; font-size: clamp(25px, 3vw, 35px); font-weight: 900; letter-spacing: .015em; text-transform: uppercase; line-height: 1.1; }
.hero h1 svg { flex: none; }
.search-row { width: min(100%, 665px); display: flex; gap: 13px; }
.search-wrap { flex: 1; min-width: 0; position: relative; }
.search-wrap svg { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); color: #98a4bc; pointer-events: none; }
.search-input { width: 100%; height: 49px; border: 1px solid #141722; background: #171923; border-radius: 9px; padding: 0 18px 0 48px; color: #fff; font-size: 15px; outline: none; }
.search-input::placeholder { color: #a4aec4; }
.search-input:focus { border-color: #acc9ff; box-shadow: 0 0 0 3px #acc9ff3b; }
.add-person { border: 1px solid #11151e; background: #1b202c; color: #fff; border-radius: 9px; width: 51px; height: 49px; display: grid; place-items: center; transition: transform .15s, background .15s; }
.add-person:hover { background: #283047; transform: translateY(-1px); }
.board { padding: 21px 20px 26px; }
.board-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin: 0 1px 17px; }
.board-heading h2 { font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: #bbc5d9; margin: 0; font-weight: 800; }
.board-heading span { color: #808da7; font-size: 12px; }
.board-tools { display: flex; align-items: center; gap: 13px; flex-wrap: wrap; justify-content: flex-end; }
.utility-button { border: 1px solid #555d70; border-radius: 6px; background: #252a38; color: #e4e9f6; font-size: 12px; padding: 7px 10px; }
.utility-button:hover { background: #343b50; }
.archive-toggle { border: 1px solid #555d70; border-radius: 6px; background: #252a38; color: #e4e9f6; font-size: 12px; padding: 7px 10px; }
.archive-toggle:hover { background: #343b50; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.employee-card { display: block; width: 100%; border: 1px solid #2f3443; border-radius: 11px; background: #151720; color: inherit; text-align: left; padding: 0; overflow: hidden; min-height: 167px; transition: border-color .15s, background .15s, transform .15s, box-shadow .15s; }
.employee-card:hover { border-color: #5b667f; background: #1b1d29; transform: translateY(-2px); box-shadow: 0 11px 20px #0b0d1661; }
.employee-card.archived { opacity: .82; }
.deleted-badge { color: #ffbbc3; background: #4c2832; border: 1px solid #8a4555; border-radius: 999px; padding: 4px 8px; font-size: 10px; font-weight: 850; text-transform: uppercase; }
.card-top { background: #1e202b; height: 38px; display: flex; align-items: center; justify-content: space-between; gap: 10px; border-bottom: 1px solid #2c3040; padding: 0 12px; }
.card-id { min-width: 0; display: flex; align-items: center; gap: 8px; color: #9eacd2; font-size: 10px; font-weight: 800; letter-spacing: .1em; white-space: nowrap; }
.card-id svg { color: #8695bc; flex: none; }
.open-badge { display: inline-flex; align-items: center; gap: 5px; padding: 4px 8px; border-radius: 999px; background: #533b1e; color: #ffab1d; border: 1px solid #9f6b17; text-transform: uppercase; font-weight: 900; font-size: 10px; white-space: nowrap; line-height: 1; }
.open-badge svg { width: 12px; height: 12px; }
.card-main { display: flex; align-items: center; gap: 15px; padding: 13px; min-height: 128px; }
.portrait { object-fit: cover; flex: none; background: #252b3a; border: 1px solid #323a4b; border-radius: 6px; width: 82px; height: 100px; }
.card-name { display: block; min-width: 0; font-size: 17px; font-weight: 850; line-height: 1.25; letter-spacing: -.015em; overflow-wrap: anywhere; }
.empty { padding: 52px 20px; text-align: center; border: 1px dashed #3a4255; border-radius: 11px; color: #a6b0c6; }
.empty strong { display: block; color: #f5f6fb; font-size: 17px; margin-bottom: 7px; }

.subshell { max-width: 1400px; margin: 0 auto; padding: 21px 20px 70px; }
.subhead { display: flex; align-items: center; gap: 23px; padding: 0 0 20px; border-bottom: 1px solid #30333e; margin-bottom: 38px; min-height: 56px; }
.back-link { border: 0; background: none; color: #b7c1d5; font-size: 15px; display: inline-flex; align-items: center; gap: 8px; padding: 7px 0; white-space: nowrap; }
.back-link:hover { color: #fff; }
.section-title { margin: 0; font-size: clamp(25px, 2.5vw, 32px); line-height: 1.08; letter-spacing: .015em; font-weight: 900; text-transform: uppercase; background: linear-gradient(100deg, #d74854, #6152bd); color: transparent; background-clip: text; }
.subhead .spacer { flex: 1; }
.header-danger { margin-left: auto; white-space: nowrap; }
.primary-button { border: 0; background: linear-gradient(105deg, #a43a4b, #4d56b3); color: #fff; padding: 0 21px; min-height: 46px; border-radius: 7px; font-size: 13px; letter-spacing: .02em; font-weight: 850; text-transform: uppercase; display: inline-flex; align-items: center; justify-content: center; gap: 9px; box-shadow: 0 8px 18px #3c327a30; white-space: nowrap; }
.primary-button:hover { filter: brightness(1.15); }
.secondary-button { border: 1px solid #454c5e; background: #232735; color: #e5e9f4; padding: 0 15px; min-height: 40px; border-radius: 7px; font-size: 13px; font-weight: 750; }
.secondary-button:hover { border-color: #7580a2; background: #2c3143; }
.danger-button { border: 1px solid #743c49; background: #40232e; color: #ffb5c0; padding: 0 14px; min-height: 40px; border-radius: 7px; }
.danger-button:hover { background: #572633; }
.muted-button { border: none; background: transparent; color: #a6b2cd; padding: 8px; border-radius: 6px; }
.muted-button:hover { background: #2b3040; color: white; }

.profile-card { display: flex; align-items: center; gap: 26px; padding: 25px; border: 1px solid #353947; border-radius: 10px; background: #171923; margin-bottom: 31px; }
.profile-photo { width: 132px; height: 155px; border-radius: 8px; object-fit: cover; background: #252b3a; border: 1px solid #3c4455; }
.eyebrow { color: #9eabc9; font-size: 11px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.profile-name { font-size: clamp(25px, 3vw, 37px); line-height: 1.1; font-weight: 900; margin: 11px 0 13px; }
.profile-meta { color: #adb9d2; font-size: 14px; }
.profile-meta strong { color: #f4f5f8; }
.deleted-note { display: block; color: #ffbbc3; margin-top: 10px; font-size: 12px; }
.profile-actions { margin-left: auto; display: flex; align-items: flex-start; flex-direction: column; gap: 8px; }
.profile-actions .secondary-button { text-align: center; }
.quiet-link { background: none; border: 0; color: #9ba8c6; font-size: 12px; padding: 5px 0; text-decoration: underline; text-underline-offset: 3px; }
.quiet-link:hover { color: white; }
.list-section { background: #171923; border: 1px solid #343846; border-radius: 10px; overflow: hidden; }
.list-section-head { min-height: 58px; display: flex; align-items: center; gap: 11px; border-bottom: 1px solid #343846; padding: 14px 19px; }
.list-section-head h2 { margin: 0; font-size: 18px; font-weight: 850; }
.count-pill { color: #b6c1dd; border-radius: 99px; background: #2a3041; padding: 3px 9px; font-size: 11px; font-weight: 800; }
.case-list { display: grid; }
.case-row { display: flex; align-items: center; gap: 17px; border-top: 1px solid #2c303f; padding: 17px 19px; }
.case-row:first-child { border-top: 0; }
.case-row:hover { background: #1d202c; }
.case-open { border: 0; background: none; padding: 0; color: inherit; min-width: 0; text-align: left; flex: 1; }
.case-open strong { display: block; font-size: 16px; margin-bottom: 6px; overflow-wrap: anywhere; }
.case-open span { color: #9da9c3; font-size: 12px; }
.case-actions { display: flex; align-items: center; gap: 12px; }
.case-export-button { border: 1px solid #535d75; border-radius: 6px; background: #272e40; color: #d5e0ff; font-size: 12px; padding: 7px 10px; white-space: nowrap; }
.case-export-button:hover { background: #36425d; border-color: #7f92ba; }
.status-pill { display: inline-flex; align-items: center; gap: 6px; border-radius: 99px; padding: 6px 10px; text-transform: uppercase; letter-spacing: .04em; font-size: 10px; font-weight: 900; white-space: nowrap; }
.status-pill.open { background: #4b351b; border: 1px solid #8e621d; color: #ffb544; }
.status-pill.closed { background: #263440; border: 1px solid #45627a; color: #a2d3ef; }
.status-toggle { border: 0; background: transparent; color: #a7b3ce; font-size: 12px; padding: 8px; border-radius: 6px; }
.status-toggle:hover { background: #2b3040; color: #fff; }
.no-cases { padding: 56px 20px; text-align: center; color: #9da9c2; }
.no-cases strong { display: block; color: #f4f6fc; font-size: 17px; margin-bottom: 6px; }

.form-panel { border: 1px solid #383b48; border-radius: 9px; background: #171923; padding: 30px; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 29px; margin-bottom: 32px; }
.field { min-width: 0; }
.field label, .field-label { display: block; color: #d4d9e7; font-weight: 850; font-size: 11px; letter-spacing: .07em; text-transform: uppercase; margin-bottom: 12px; }
.input, .textarea, .select { width: 100%; border: 1px solid #3b4152; background: #1e212c; border-radius: 6px; color: #f8f9fc; outline: 0; padding: 12px 15px; }
.input { height: 47px; }
.textarea { min-height: 103px; resize: vertical; line-height: 1.5; }
.input::placeholder, .textarea::placeholder { color: #79859d; }
.input:focus, .textarea:focus, .select:focus { border-color: #6f80c5; box-shadow: 0 0 0 3px #6476c329; }
.form-group { margin-bottom: 31px; }
.editor-box { border: 1px solid #373c4b; border-radius: 6px; overflow: hidden; background: #1d202b; }
.toolbar { background: #30333f; padding: 7px 12px; display: flex; align-items: center; gap: 3px; flex-wrap: wrap; border-bottom: 1px solid #2b2f3a; }
.toolbar button, .toolbar select { background: transparent; border: 0; color: #d2d7e4; border-radius: 4px; min-height: 28px; min-width: 28px; padding: 3px 8px; }
.toolbar button:hover, .toolbar select:hover { background: #464b5c; }
.toolbar button:focus-visible, .toolbar select:focus-visible { outline-offset: -2px; }
.toolbar select { color: #91aaff; font-size: 12px; margin-right: 10px; width: 125px; }
.toolbar select option { background: #292d39; color: white; }
.toolbar-sep { border-left: 1px solid #505460; height: 19px; margin: 0 7px; }
.rich-editor { min-height: 300px; padding: 18px 20px; outline: none; color: #f5f6fb; line-height: 1.55; overflow-wrap: anywhere; }
.rich-editor:empty:before { content: attr(data-placeholder); color: #68758f; pointer-events: none; }
.rich-editor h2 { font-size: 24px; margin: .3em 0; }
.rich-editor h3 { font-size: 19px; margin: .3em 0; }
.rich-editor p { margin: .4em 0; }
.rich-editor ul, .rich-editor ol { padding-left: 26px; }
.evidence-box { border: 1px solid #393d4b; border-radius: 7px; padding: 14px; }
.evidence-controls { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr) 42px; gap: 9px; align-items: end; }
.evidence-controls > div, .evidence-item > div { min-width: 0; }
.evidence-controls label, .evidence-item label { margin-bottom: 7px; }
.evidence-add { height: 47px; }
.evidence-list { display: grid; gap: 8px; margin-top: 13px; }
.evidence-empty { margin: 0; padding: 13px; border: 1px dashed #3c4459; border-radius: 6px; color: #8999b8; font-size: 12px; }
.evidence-item { display: grid; grid-template-columns: 29px minmax(0, 1fr) minmax(0, 1.6fr) 35px; align-items: end; gap: 9px; padding: 11px; border: 1px solid #3c4254; border-radius: 6px; background: #1d212d; }
.evidence-number { align-self: center; text-align: center; color: #91a3cb; font-weight: 800; font-size: 12px; }
.evidence-remove { width: 35px; height: 47px; border: 1px solid #7a3e4c; border-radius: 6px; background: #422732; color: #ffadb4; font-size: 20px; }
.evidence-remove:hover { background: #5b303d; }
.legacy-evidence { margin-top: 17px; }
.legacy-evidence .textarea { min-height: 85px; }
.participants-box { border: 1px solid #393d4b; border-radius: 7px; padding: 12px; }
.participants-controls { display: grid; grid-template-columns: minmax(0, 1fr) 150px 42px; gap: 8px; }
.participants-controls .input, .participants-controls .select { height: 48px; }
.participant-suggest { position: relative; }
.suggest-menu { position: absolute; z-index: 6; left: 0; right: 0; top: calc(100% + 4px); max-height: 240px; overflow-y: auto; border: 1px solid #566078; background: #252a38; border-radius: 7px; box-shadow: 0 15px 30px #06091299; }
.suggest-item { width: 100%; border: 0; border-bottom: 1px solid #3a4052; background: none; color: white; text-align: left; padding: 10px 13px; display: flex; justify-content: space-between; gap: 8px; }
.suggest-item:last-child { border-bottom: 0; }
.suggest-item:hover { background: #343b50; }
.suggest-item small { color: #a8b4ce; }
.small-add { border: 1px solid #5b6480; background: #303b59; color: white; border-radius: 6px; font-size: 23px; }
.small-add:hover { background: #415075; }
.chips { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding-top: 11px; }
.chip { display: inline-flex; align-items: center; gap: 8px; border: 1px solid #464a5b; border-radius: 999px; background: #242733; padding: 4px 5px 4px 10px; font-size: 12px; font-weight: 700; max-width: 100%; }
.chip-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.role-tag { border: 0; padding: 4px 8px; font-weight: 900; text-transform: uppercase; letter-spacing: .04em; border-radius: 99px; font-size: 9px; white-space: nowrap; }
.role-tater { background: #4a2e22; color: #ffa466; border: 1px solid #8e5335; }
.role-mittater { background: #433913; color: #ffd447; border: 1px solid #a8871e; }
.role-zeuge { background: #1e4053; color: #4ab3ff; border: 1px solid #31749a; }
.role-geschadigter { background: #1d483d; color: #42dc95; border: 1px solid #2b9a6b; }
.chip-remove { border: 0; background: #4b2c35; color: #ff808b; width: 20px; height: 20px; border-radius: 50%; line-height: 1; padding: 0; }
.chip-remove:hover { background: #70313e; }
.helper { margin: 9px 0 0; font-size: 12px; color: #8695b3; line-height: 1.4; }
.status-choice { display: inline-flex; border: 1px solid #42485a; border-radius: 7px; overflow: hidden; }
.status-choice label { margin: 0; }
.status-choice input { position: absolute; opacity: 0; }
.status-choice span { display: inline-block; padding: 10px 17px; color: #aab6ce; font-size: 12px; font-weight: 850; text-transform: uppercase; cursor: pointer; }
.status-choice input:checked + span { background: #313b55; color: #fff; }
.status-choice input:focus-visible + span { outline: 2px solid #6a8cff; outline-offset: -2px; }
.form-bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; border-top: 1px solid #313645; padding-top: 24px; margin-top: 30px; }
.error-message { color: #ff9eaa; font-size: 12px; min-height: 18px; }

.modal-backdrop { position: fixed; inset: 0; background: #070911c9; backdrop-filter: blur(5px); z-index: 20; overflow-y: auto; display: flex; align-items: flex-start; justify-content: center; padding: 6vh 16px 35px; }
.modal { width: min(100%, 720px); background: #191c27; border: 1px solid #454b60; border-radius: 13px; box-shadow: 0 25px 80px #0009; overflow: hidden; }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; padding: 22px 24px 17px; border-bottom: 1px solid #353a4d; }
.modal-head h2 { font-size: 21px; margin: 0 0 5px; }
.modal-head p { margin: 0; font-size: 13px; color: #9faccc; }
.close-modal { border: none; background: #2b3040; color: #e4e9f4; font-size: 20px; width: 31px; height: 31px; border-radius: 6px; }
.close-modal:hover { background: #424b62; }
.modal-body { padding: 20px 24px 24px; }
.tabs { display: flex; gap: 5px; padding: 4px; background: #242837; border: 1px solid #363e52; border-radius: 8px; margin-bottom: 21px; }
.tabs button { flex: 1; border: 0; border-radius: 6px; color: #aab7d2; background: none; font-size: 13px; font-weight: 800; padding: 10px 8px; }
.tabs button.active { background: #3a4260; color: #fff; }
.upload-zone { border: 1px dashed #637090; border-radius: 9px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 25px 14px; text-align: center; background: #202534; color: #cbd4eb; gap: 8px; cursor: pointer; min-height: 132px; }
.upload-zone.dragover { border-color: #60da97; background: #243b36; }
.upload-zone strong { color: #fff; }
.upload-zone small { color: #99a6c1; }
.upload-zone svg { color: #8ea5e8; }
.import-preview { display: flex; gap: 15px; align-items: flex-start; margin: 18px 0; }
.import-preview img { width: 110px; max-height: 155px; object-fit: contain; background: #12141d; border: 1px solid #41495d; border-radius: 5px; }
.import-preview p { color: #a9b6cf; font-size: 13px; line-height: 1.5; margin: 0; }
.import-preview strong { display: block; color: #f4f5f8; margin-bottom: 5px; }
.ocr-result { margin-top: 18px; }
.ocr-result .textarea { min-height: 120px; }
.import-rows { display: grid; gap: 8px; max-height: 210px; overflow: auto; margin: 15px 0; }
.import-row { display: grid; grid-template-columns: 84px minmax(0, 1fr) 27px; gap: 8px; align-items: center; }
.import-row .input { height: 39px; padding: 8px 10px; font-size: 13px; }
.import-row button { border: 0; background: transparent; color: #ff9aa8; font-size: 18px; }
.modal-actions { display: flex; justify-content: flex-end; align-items: center; gap: 11px; margin-top: 20px; }
.modal .field { margin-bottom: 18px; }
.photo-row { display: flex; gap: 15px; align-items: center; }
.photo-row img { width: 70px; height: 83px; object-fit: cover; border-radius: 5px; border: 1px solid #41495d; }
.photo-row input { min-width: 0; width: 100%; font-size: 12px; color: #a9b6cc; }
.hint-box { padding: 12px 13px; background: #222b3a; border: 1px solid #3d4e65; border-radius: 7px; color: #aebfdb; font-size: 12px; line-height: 1.5; }
.inline-warning { color: #e6b367; font-size: 12px; margin: 8px 0 0; }
.toast { position: fixed; z-index: 50; bottom: 24px; right: 24px; max-width: min(420px, calc(100vw - 36px)); background: #263646; border: 1px solid #54718b; box-shadow: 0 12px 40px #0007; color: white; padding: 12px 16px; border-radius: 8px; font-size: 13px; }
.toast.error { background: #492a34; border-color: #8b4659; }

@media (max-width: 950px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } .profile-actions { margin-left: 0; } }
@media (max-width: 820px) { .profile-card { flex-wrap: wrap; } .profile-actions { flex-basis: 100%; } }
@media (max-width: 650px) {
  .shell { padding: 10px 10px 30px; }
  .topbar { margin: 6px 3px 14px; }
  .topbar-right { justify-content: flex-start; }
  .access-user { grid-template-columns: 1fr; }
  .access-fixed { grid-column: auto; }
  .hero { min-height: 164px; padding: 24px 14px; }
  .hero h1 { font-size: 22px; }
  .board { padding: 14px; }
  .cards { grid-template-columns: 1fr; gap: 12px; }
  .subshell { padding: 16px 12px 50px; }
  .subhead { gap: 12px; flex-wrap: wrap; margin-bottom: 22px; }
  .section-title { font-size: 23px; order: 2; flex-basis: 100%; }
  .subhead .header-danger { order: 3; margin-left: auto; }
  .subhead .primary-button { margin-left: auto; }
  .profile-card { padding: 16px; flex-wrap: wrap; gap: 17px; }
  .profile-photo { width: 97px; height: 118px; }
  .profile-name { font-size: 24px; }
  .profile-actions { flex-basis: 100%; }
  .case-row { align-items: flex-start; flex-direction: column; gap: 9px; }
  .case-actions { width: 100%; justify-content: flex-start; flex-wrap: wrap; }
  .form-panel { padding: 17px; }
  .field-grid { grid-template-columns: 1fr; gap: 19px; margin-bottom: 20px; }
  .rich-editor { min-height: 260px; }
  .evidence-controls { grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr) 38px; }
  .evidence-item { grid-template-columns: 22px minmax(0, 1fr) minmax(0, 1.3fr) 32px; gap: 6px; padding: 9px; }
  .evidence-remove { width: 32px; }
  .participants-controls { grid-template-columns: 1fr 120px 38px; }
  .modal-body, .modal-head { padding-left: 16px; padding-right: 16px; }
}
@media (max-width: 470px) {
  .evidence-controls, .evidence-item { grid-template-columns: 1fr; }
  .evidence-number { display: none; }
  .evidence-add, .evidence-remove { width: 100%; height: 36px; }
}
