:root {
    --bg: #f3f5f7;
    --paper: #fff;
    --ink: #1c2430;
    --muted: #5d6976;
    --line: #e3e8ee;
    --accent: #1f3f61;
    --accent-2: #2f6f62;
    --danger: #8d3a3a;
    --required: #c2410c;
    --ok: #e7f3ec;
    --err: #f8e8e8;
    --shadow: 0 10px 30px rgba(28, 36, 48, .06);
}

* { box-sizing: border-box; }
body {
    margin: 0;
    color: var(--ink);
    background: var(--bg);
    font-family: "Malgun Gothic", "Apple SD Gothic Neo", sans-serif;
    line-height: 1.5;
}
a { color: var(--accent); }
h1, h2, h3 { line-height: 1.3; }
h1 { font-size: 1.6rem; margin: 0 0 .3rem; }
h2 { font-size: 1.05rem; margin: 0 0 .7rem; }

.topbar { background: var(--accent); color: #fff; }
.topbar-inner, .wrap { width: min(1080px, calc(100% - 32px)); margin: 0 auto; }
.topbar-inner { display: flex; justify-content: space-between; gap: 16px; align-items: center; min-height: 58px; }
.brand { color: #fff; text-decoration: none; font-weight: 700; }
.topbar nav { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.topbar nav a, .who { color: #fff; text-decoration: none; }
.wrap { padding: 28px 0 64px; }
.page-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-end; margin-bottom: 18px; }
.page-head-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}
.obit-foot-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
    margin: 16px 0 8px;
}
.page-head-actions .btn,
.page-head-actions a.btn,
.page-head-actions button.btn,
.obit-foot-actions .btn,
.obit-foot-actions a.btn,
.obit-foot-actions button.btn {
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    height: 40px;
    padding: 0 16px;
    border-radius: 6px;
    font-size: .9rem;
    font-weight: 700;
    line-height: 1;
}
.page-head-actions .btn-danger,
.page-head-actions a.btn-danger,
.page-head-actions button.btn-danger,
.obit-foot-actions .btn-danger,
.obit-foot-actions a.btn-danger,
.obit-foot-actions button.btn-danger,
.area-hall .btn-danger,
.area-hall a.btn-danger,
.area-hall button.btn-danger,
.area-admin .btn-danger,
.area-admin a.btn-danger,
.area-admin button.btn-danger {
    background: #c62828;
    border-color: #c62828;
    color: #fff;
}
.page-head-actions .btn-danger:hover,
.obit-foot-actions .btn-danger:hover,
.area-hall .btn-danger:hover,
.area-admin .btn-danger:hover {
    background: #b71c1c;
    border-color: #b71c1c;
    color: #fff;
}
.muted { color: var(--muted); }
.card, .login-card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow);
    padding: 20px;
    margin-bottom: 16px;
}
.narrow { max-width: 460px; }
.login-card { max-width: 420px; margin: 8vh auto; padding: 32px 28px; }
.login-mode { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 14px; }
.login-mode label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 8px 10px;
    cursor: pointer;
    font-weight: 700;
    white-space: nowrap;
}
.login-mode input[type="radio"] {
    width: 16px;
    height: 16px;
    min-height: 0;
    margin: 0;
    padding: 0;
    flex: none;
    border: none;
    box-shadow: none;
    appearance: auto;
}
.login-mode label:has(input:checked) { background: #d9e4f4; border-color: #1b2a4a; }
.eyebrow { letter-spacing: .28em; color: var(--accent-2); margin: 0; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.stats div { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.stats strong { display: block; font-size: 1.6rem; }
.stats span { color: var(--muted); }

.table-wrap { overflow-x: auto; padding: 0; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { font-size: .86rem; color: var(--muted); background: #f8fafb; }
.nowrap { white-space: nowrap; }
.nowrap a, .nowrap button { margin-right: 8px; }

.form-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px 14px;
}
.form-grid .span-2 { grid-column: span 2; }
.form-grid .span-full,
.form-grid .span-2.span-full { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.field span { font-size: .86rem; color: var(--muted); }
.field i { color: var(--danger); font-style: normal; }
.field.is-required > span:first-child,
.field:has([required]) > span:first-child {
    color: var(--required);
}
input, select, textarea {
    width: 100%;
    border: 1px solid #cfd6de;
    border-radius: 10px;
    padding: 10px 12px;
    font: inherit;
    background: #fff;
    color: inherit;
}
textarea { resize: vertical; }
.checks { display: flex; gap: 16px; align-items: center; margin: 8px 0 16px; }
.checks input { width: auto; }
.obit-deceased .deceased-publish-field {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    column-gap: 8px;
    margin: 10px 0 0;
}
.obit-deceased .deceased-publish-field > span:first-child {
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: max-content;
    min-width: 4.6rem;
    max-width: 6.2rem;
    min-height: 40px;
    padding: 6px 8px;
    text-align: center;
    color: #334155;
    font-weight: 700;
    font-size: .78rem;
    line-height: 1.2;
    background: #e8e8e8;
    border-radius: 8px;
}
.obit-deceased .deceased-publish-checks {
    margin: 0;
    min-height: 40px;
}
.obit-deceased .deceased-publish-checks label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    white-space: nowrap;
}
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.btn, button.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #c9d2dc;
    background: #fff;
    color: var(--ink);
    border-radius: 999px;
    padding: 8px 14px;
    text-decoration: none;
    cursor: pointer;
    font: inherit;
}
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-ghost { background: transparent; }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.danger-form { margin-top: 8px; }
.obit-delete-dialog { width: min(420px, calc(100vw - 24px)); }
.obit-delete-body { display: flex; flex-direction: column; gap: 14px; }
.obit-delete-warn {
    margin: 0;
    padding: 12px 14px;
    border: 1px solid #fecaca;
    border-radius: 10px;
    background: #fef2f2;
    color: #7f1d1d;
    line-height: 1.55;
    font-size: .92rem;
}
.obit-delete-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin: 4px 0 0;
}
.save-progress {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, .42);
}
.save-progress[hidden] { display: none !important; }
.save-progress-card {
    width: min(360px, 100%);
    padding: 22px 20px 18px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 18px 40px rgba(15, 23, 42, .28);
    text-align: center;
}
.save-progress-card strong {
    display: block;
    margin: 0 0 14px;
    color: #1b2a4a;
    font-size: 1rem;
}
.save-progress-bar {
    overflow: hidden;
    height: 8px;
    border-radius: 999px;
    background: #e8eef6;
}
.save-progress-bar > span {
    display: block;
    width: 40%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #1b2a4a, #3b82f6, #1b2a4a);
    background-size: 200% 100%;
    animation: save-progress-slide 1.1s linear infinite;
}
@keyframes save-progress-slide {
    0% { transform: translateX(-120%); }
    100% { transform: translateX(280%); }
}
.btn.is-saving,
button.btn.is-saving {
    opacity: .65;
    cursor: wait;
    pointer-events: none;
}
.login-note { margin: 0 0 14px; padding: 10px 12px; border-radius: 10px; background: var(--ok); }
.toast-stack {
    position: fixed;
    top: 20px;
    left: 50%;
    z-index: 90;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: min(420px, calc(100% - 32px));
    transform: translateX(-50%);
    pointer-events: none;
}
.toast {
    pointer-events: auto;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 12px 12px 14px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, .16);
    animation: toast-in .22s ease;
}
.toast p { margin: 0; flex: 1; }
.toast-ok { background: #f3faf6; border-color: #b7d7c6; }
.toast-err { background: #f8e8e8; border-color: #e7b0b0; }
.toast-ask { flex-wrap: wrap; }
.toast-actions { display: flex; justify-content: flex-end; gap: 8px; width: 100%; }
.toast-actions button { width: auto; }
.toast-x {
    border: 0;
    background: transparent;
    color: #64748b;
    font: inherit;
    font-size: 1.15rem;
    line-height: 1;
    padding: 0 2px;
    cursor: pointer;
}
.toast.out { opacity: 0; transform: translateY(-6px); transition: opacity .2s ease, transform .2s ease; }
@keyframes toast-in {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: none; }
}
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.filters input, .filters select { width: auto; min-width: 140px; }
.pager { display: flex; gap: 8px; flex-wrap: wrap; }
.pager a { text-decoration: none; padding: 4px 8px; }
.pager .on { font-weight: 700; }

.badge { display: inline-block; border-radius: 999px; padding: 2px 8px; background: #eef2f5; font-size: .82rem; }
.badge-open { background: #111827; color: #fff; }
.badge-wait { background: #65a30d; color: #fff; }
.badge-closed { background: #d1d5db; color: #111827; }

.room-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; margin-bottom: 22px; }
.room-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 16px; }

.status-board-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}
.status-board-card {
    display: flex;
    flex-direction: column;
    min-height: 260px;
    background: #fff;
    border: 1px solid #d7dee8;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(28, 36, 48, .06);
    text-decoration: none;
    color: inherit;
    transition: transform .12s ease, box-shadow .12s ease;
}
a.status-board-card:hover,
.status-board-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(28, 36, 48, .12);
}
a.status-board-main {
    text-decoration: none;
    color: inherit;
}
a.status-board-main:hover .status-board-name {
    color: #1f3f61;
}
.room-filter-strip {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}
.room-filter-box {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-height: 78px;
    padding: 12px 14px;
    border: 1px solid #d7dee8;
    border-radius: 12px;
    background: #fff;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 6px 16px rgba(28, 36, 48, .05);
}
.room-filter-box strong {
    font-size: .92rem;
    line-height: 1.3;
}
.room-filter-box span {
    color: #64748b;
    font-size: .78rem;
    font-weight: 700;
}
.room-filter-box.is-busy {
    border-color: #93c5fd;
    background: #f8fbff;
}
.room-filter-box.is-on {
    border-color: #1f3f61;
    background: #1f3f61;
    color: #fff;
    box-shadow: 0 10px 22px rgba(31, 63, 97, .24);
}
.room-filter-box.is-on span { color: rgba(255,255,255,.82); }

.hall-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px;
    margin: 0 0 16px;
    padding: 14px 16px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 6px 16px rgba(28, 36, 48, .04);
}
.hall-filter-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 0;
    flex: 0 0 auto;
    width: 140px;
}
.hall-filter-item.hall-filter-grow {
    width: 180px;
}
.hall-filter-label {
    display: block;
    margin: 0;
    color: #64748b;
    font-size: .78rem;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
}
.hall-filters .hall-filter-item input,
.hall-filters .hall-filter-item select {
    width: 100%;
    min-width: 0;
    min-height: 40px;
    margin: 0;
    border: 1px solid #d5deea;
    border-radius: 8px;
    padding: 8px 10px;
    background: #fff;
    box-sizing: border-box;
}
.hall-filter-actions {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
}
.hall-filter-actions .btn {
    min-height: 40px;
    min-width: 72px;
    padding: 8px 16px;
    white-space: nowrap;
    flex: none;
}
@media (max-width: 900px) {
    .hall-filter-item,
    .hall-filter-item.hall-filter-grow {
        width: 150px;
    }
}

.inline-form { display: inline; margin: 0; }
.inline-form .btn {
    padding: 2px 8px;
    min-height: 0;
    border-radius: 6px;
    font-size: .82rem;
}
.status-board-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    background: #1f2937;
    color: #fff;
}
.status-board-card.is-wait .status-board-head { background: #334155; }
.status-board-card.is-open .status-board-head { background: #1f3f61; }
.status-board-card.is-funeral .status-board-head { background: #7c2d12; }
.status-board-card.is-done .status-board-head { background: #475569; }
.status-board-card.is-empty .status-board-head { background: #64748b; }
.status-board-head strong {
    font-size: .95rem;
}
.status-board-head span {
    flex: none;
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(255,255,255,.14);
    font-size: .75rem;
    font-weight: 700;
}
.status-board-body {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
    padding: 14px;
    background:
        radial-gradient(circle at 85% 20%, rgba(31, 63, 97, .05), transparent 40%),
        #fff;
}
.status-board-main {
    display: grid;
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
}
.status-board-portrait {
    width: 88px;
    height: 110px;
    border-radius: 8px;
    overflow: hidden;
    background: #eef2f6;
    border: 1px solid #e2e8f0;
}
.status-board-portrait img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.status-board-portrait-empty {
    display: block;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(135deg, #f8fafc 25%, #e2e8f0 25%, #e2e8f0 50%, #f8fafc 50%, #f8fafc 75%, #e2e8f0 75%);
    background-size: 16px 16px;
}
.status-board-name {
    margin: 0 0 8px;
    font-size: 1.05rem;
    font-weight: 800;
    color: #111827;
}
.status-board-times {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 6px;
}
.status-board-times li {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 8px;
    align-items: baseline;
    font-size: .86rem;
}
.status-board-times span {
    color: #64748b;
    font-weight: 700;
}
.status-board-times strong {
    color: #1f2937;
    font-weight: 700;
}
.status-board-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: auto;
}
.status-board-empty {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 12px;
    min-height: 160px;
    color: #64748b;
}
.status-board-empty p { margin: 0; }
.room-top { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.room-name { font-size: 1.15rem; margin: 10px 0 0; }
.floor-title { margin: 8px 0 10px; }
.mourner { display: grid; grid-template-columns: .8fr 1fr 1fr .8fr 1.2fr .8fr auto; gap: 6px; margin-bottom: 8px; }
.obit-form { padding: 20px; }
.obit-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: start;
    align-content: start;
    margin-bottom: 16px;
}
.obit-col {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
    height: fit-content;
    align-self: start;
}
.obit-left-main {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
    height: fit-content;
}
.obit-panel {
    border: 1px solid #e6ebf2;
    border-radius: 10px;
    background: #fff;
    padding: 16px 18px 18px;
    min-width: 0;
}
.obit-panel h2 {
    margin: 0 0 14px;
    font-size: .95rem;
    font-weight: 700;
}
.obit-deceased .form-grid,
.obit-info .form-grid,
.obit-mobile .form-grid,
.area-admin .obit-deceased .form-grid,
.area-admin .obit-info .form-grid,
.area-admin .obit-mobile .form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 12px;
    margin-bottom: 8px;
}
.obit-deceased .field,
.obit-info .field,
.obit-mobile .field,
.area-admin .obit-deceased .field,
.area-admin .obit-info .field,
.area-admin .obit-mobile .field {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: stretch;
    column-gap: 8px;
    row-gap: 0;
    margin-bottom: 0;
    flex-direction: unset;
}
.obit-deceased .field > span:first-child,
.obit-info .field > span:first-child,
.obit-mobile .field > span:first-child,
.area-admin .obit-deceased .field > span:first-child,
.area-admin .obit-info .field > span:first-child,
.area-admin .obit-mobile .field > span:first-child {
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: max-content;
    min-width: 4.6rem;
    max-width: 6.2rem;
    min-height: 40px;
    padding: 6px 8px;
    text-align: center;
    color: #334155;
    font-weight: 700;
    font-size: .78rem;
    line-height: 1.2;
    background: #e8e8e8;
    border-radius: 8px;
    white-space: normal;
}
.obit-deceased .field.is-required > span:first-child,
.obit-info .field.is-required > span:first-child,
.obit-mobile .field.is-required > span:first-child,
.area-admin .obit-deceased .field.is-required > span:first-child,
.area-admin .obit-info .field.is-required > span:first-child,
.area-admin .obit-mobile .field.is-required > span:first-child,
.obit-deceased .field:has([required]) > span:first-child,
.obit-info .field:has([required]) > span:first-child,
.obit-mobile .field:has([required]) > span:first-child,
.area-admin .obit-deceased .field:has([required]) > span:first-child,
.area-admin .obit-info .field:has([required]) > span:first-child,
.area-admin .obit-mobile .field:has([required]) > span:first-child {
    color: var(--required);
}
.obit-deceased .field > input,
.obit-deceased .field > select,
.obit-info .field > input,
.obit-info .field > select,
.obit-mobile .field > input,
.obit-mobile .field > select,
.area-admin .obit-deceased .field > input,
.area-admin .obit-deceased .field > select,
.area-admin .obit-info .field > input,
.area-admin .obit-info .field > select,
.area-admin .obit-mobile .field > input,
.area-admin .obit-mobile .field > select {
    min-height: 40px;
    width: 100%;
}
.obit-deceased .field-combo,
.obit-info .field-combo {
    display: flex;
    gap: 8px;
    min-width: 0;
    width: 100%;
    align-items: stretch;
}
.obit-deceased .field-combo select,
.obit-info .field-combo select {
    flex: 0 0 96px;
    min-height: 40px;
}
.obit-deceased .field-combo input,
.obit-info .field-combo input {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 40px;
}
.obit-deceased .form-grid .span-full {
    grid-column: 1 / -1;
}
.obit-deceased .deceased-address {
    display: grid;
    gap: 8px;
    width: 100%;
    min-width: 0;
}
.obit-deceased .deceased-address .address-line {
    display: flex;
    gap: 8px;
    min-width: 0;
    align-items: center;
}
.obit-deceased .deceased-address .address-line .zip {
    flex: 0 0 88px;
    min-height: 40px;
}
.obit-deceased .deceased-address .address-line input[data-address-base] {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 40px;
}
.obit-deceased .deceased-address .address-line .btn {
    flex: none;
    white-space: nowrap;
}
.obit-deceased .deceased-address > input {
    min-height: 40px;
    width: 100%;
}
.area-admin .obit-deceased .deceased-address .address-line,
.area-hall .obit-deceased .deceased-address .address-line {
    display: flex;
}
.deceased-detail-foot {
    display: flex;
    justify-content: flex-end;
    margin-top: 14px;
}
.btn-detail-toggle {
    min-width: 132px;
    border-radius: 8px;
    font-weight: 700;
    gap: 6px;
    background: #fff;
    border-color: #1b2a4a;
    color: #1b2a4a;
}
.btn-detail-toggle::after {
    content: '▾';
    font-size: .85em;
    line-height: 1;
}
.btn-detail-toggle:hover {
    background: #eef2f7;
    border-color: #1b2a4a;
    color: #1b2a4a;
}
.btn-detail-toggle.is-open {
    background: #1b2a4a;
    border-color: #1b2a4a;
    color: #fff;
}
.btn-detail-toggle.is-open::after {
    content: '▴';
}
.btn-detail-toggle.is-open:hover {
    background: #243656;
    border-color: #243656;
    color: #fff;
}
.area-admin .btn-detail-toggle {
    background: #fff;
    border-color: #111;
    color: #111;
}
.area-admin .btn-detail-toggle:hover {
    background: #f3f4f6;
}
.area-admin .btn-detail-toggle.is-open {
    background: #111;
    border-color: #111;
    color: #fff;
}
.area-admin .btn-detail-toggle.is-open:hover {
    background: #2a2a2a;
    border-color: #2a2a2a;
}
.deceased-detail {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e6ebf2;
}
.deceased-detail[hidden] {
    display: none !important;
}
.obit-deceased .deceased-detail-grid,
.obit-info .rite-detail-grid,
.obit-info .info-schedule-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 12px;
}
.obit-deceased .deceased-detail-grid .span-full,
.obit-info .rite-detail-grid .span-full {
    grid-column: 1 / -1;
}
.obit-rooms {
    margin-bottom: 14px;
    padding: 12px 14px;
    border: 1px solid #e6ebf2;
    border-radius: 10px;
    background: #f8fafc;
}
.obit-rooms-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 6px;
}
.obit-rooms-head strong {
    font-size: .9rem;
}
.obit-rooms-head strong.is-required {
    color: var(--required);
}
.obit-rooms-tip {
    margin: 0 0 10px;
    font-size: .8rem;
}
.obit-rooms-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.obit-room-row {
    display: grid;
    grid-template-columns: 48px minmax(140px, 1.2fr) minmax(180px, 1fr) minmax(180px, 1fr) auto;
    gap: 8px;
    align-items: center;
}
.obit-rooms .obit-room-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    min-height: 36px;
    padding: 0 8px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #e2e8f0;
    color: #334155;
    font-size: .72rem;
    font-weight: 700;
}
.obit-rooms .obit-room-row.is-primary .obit-room-badge {
    border-color: #1b2a4a !important;
    background: #1b2a4a !important;
    color: #fff !important;
}
.obit-rooms .obit-room-dt {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    column-gap: 6px;
    margin: 0;
    min-width: 0;
}
.obit-rooms .obit-room-dt > span {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: auto;
    min-width: 0;
    max-width: none;
    min-height: 36px;
    padding: 0 8px !important;
    border: 1px solid #cfd6de !important;
    border-radius: 6px;
    background: #fff !important;
    color: #334155 !important;
    font-size: .72rem !important;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}
.obit-rooms .obit-room-dt.is-required > span,
.obit-rooms .obit-room-dt:has([required]) > span {
    color: var(--required) !important;
    border-color: #f0b89a !important;
}
.obit-room-row select,
.obit-room-row input,
.obit-room-dt input {
    min-height: 40px;
    width: 100%;
}
input[type="datetime-local"],
input[type="date"],
input[type="time"],
input.flatpickr-input,
input.flatpickr-alt-input {
    cursor: pointer;
}
.flatpickr-calendar,
.flatpickr-calendar.fp-bordered,
.flatpickr-calendar.open {
    width: 320px !important;
    max-width: calc(100vw - 24px);
    padding: 12px 12px 10px !important;
    border: 1px solid #64748b !important;
    border-radius: 12px !important;
    box-shadow: 0 16px 40px rgba(15, 23, 42, .22) !important;
    background: #fff !important;
    font-family: "Malgun Gothic", "Apple SD Gothic Neo", sans-serif;
    font-size: 14px !important;
    line-height: 1.4 !important;
    overflow: hidden;
}
.flatpickr-calendar.arrowTop:before,
.flatpickr-calendar.arrowBottom:before {
    border-bottom-color: #64748b !important;
    border-top-color: #64748b !important;
}
.flatpickr-calendar.arrowTop:after {
    border-bottom-color: #fff !important;
}
.flatpickr-calendar.arrowBottom:after {
    border-top-color: #fff !important;
}
.flatpickr-months {
    align-items: center;
    margin-bottom: 6px;
    padding: 0 2px;
}
.flatpickr-months .flatpickr-month {
    height: 40px !important;
    background: transparent !important;
    color: #1c2430 !important;
    fill: #1c2430 !important;
    overflow: visible !important;
}
.flatpickr-current-month {
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding-top: 0 !important;
    height: 40px !important;
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #1c2430 !important;
}
.flatpickr-current-month .flatpickr-monthDropdown-months,
.flatpickr-current-month input.cur-year {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #1c2430 !important;
    background: transparent !important;
}
.flatpickr-current-month input.cur-year {
    width: 4.2em !important;
}
.flatpickr-months .flatpickr-prev-month,
.flatpickr-months .flatpickr-next-month {
    top: 0 !important;
    height: 40px !important;
    width: 36px;
    padding: 10px !important;
    border-radius: 8px;
    color: #334155 !important;
    fill: #334155 !important;
}
.flatpickr-months .flatpickr-prev-month:hover,
.flatpickr-months .flatpickr-next-month:hover {
    background: #f1f5f9;
}
.flatpickr-months .flatpickr-prev-month svg,
.flatpickr-months .flatpickr-next-month svg {
    width: 14px;
    height: 14px;
}
.flatpickr-innerContainer {
    display: block;
    padding: 0 2px 4px;
}
.flatpickr-rContainer {
    display: block;
    width: 100%;
}
.flatpickr-weekdays {
    height: 32px !important;
    margin-top: 2px;
    background: transparent !important;
}
span.flatpickr-weekday {
    color: #64748b !important;
    font-size: .82rem !important;
    font-weight: 700 !important;
    background: transparent !important;
}
.flatpickr-days {
    width: 100% !important;
}
.dayContainer {
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    min-height: 0 !important;
    padding: 2px 0 6px;
}
.flatpickr-day {
    height: 38px !important;
    line-height: 38px !important;
    max-width: 38px !important;
    margin: 2px 1px !important;
    border-radius: 10px !important;
    font-size: .95rem !important;
    font-weight: 600 !important;
    color: #1c2430 !important;
}
.flatpickr-day.flatpickr-disabled,
.flatpickr-day.prevMonthDay,
.flatpickr-day.nextMonthDay {
    color: #94a3b8 !important;
    font-weight: 500 !important;
}
.flatpickr-day:hover,
.flatpickr-day:focus {
    background: #e8eef5 !important;
    border-color: #e8eef5 !important;
}
.flatpickr-day.today {
    border-color: #1f3f61 !important;
    font-weight: 700 !important;
}
.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange,
.flatpickr-day.selected:hover,
.flatpickr-day.startRange:hover,
.flatpickr-day.endRange:hover {
    background: #1f3f61 !important;
    border-color: #1f3f61 !important;
    color: #fff !important;
    font-weight: 700 !important;
}
.flatpickr-calendar.hasTime .flatpickr-time {
    height: 48px !important;
    margin-top: 6px;
    padding: 6px 8px 2px;
    border-top: 1px solid #e2e8f0 !important;
}
.flatpickr-time {
    max-height: none !important;
    line-height: 40px !important;
}
.flatpickr-time .numInputWrapper {
    height: 40px !important;
}
.flatpickr-time input,
.flatpickr-time .flatpickr-time-separator,
.flatpickr-time .flatpickr-am-pm {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #1c2430 !important;
    height: 40px !important;
    line-height: 40px !important;
}
.flatpickr-time input.flatpickr-hour,
.flatpickr-time input.flatpickr-minute {
    font-weight: 700 !important;
}
.flatpickr-time input:hover,
.flatpickr-time .flatpickr-am-pm:hover,
.flatpickr-time input:focus,
.flatpickr-time .flatpickr-am-pm:focus {
    background: #f1f5f9 !important;
}
.flatpickr-calendar .numInputWrapper {
    position: relative;
}
.flatpickr-calendar .numInputWrapper input {
    padding-right: 22px !important;
}
.flatpickr-calendar .numInputWrapper span.arrowUp,
.flatpickr-calendar .numInputWrapper span.arrowDown {
    position: absolute;
    right: 2px;
    width: 18px !important;
    height: calc(50% - 2px) !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 5px !important;
    background: #eef2f6 !important;
    opacity: 1 !important;
    box-sizing: border-box;
    display: flex !important;
    align-items: center;
    justify-content: center;
}
.flatpickr-calendar .numInputWrapper span.arrowUp {
    top: 2px;
}
.flatpickr-calendar .numInputWrapper span.arrowDown {
    top: auto;
    bottom: 2px;
}
.flatpickr-calendar .numInputWrapper span.arrowUp:hover,
.flatpickr-calendar .numInputWrapper span.arrowDown:hover {
    background: #1f3f61 !important;
}
.flatpickr-calendar .numInputWrapper span.arrowUp::after,
.flatpickr-calendar .numInputWrapper span.arrowDown::after {
    content: "";
    display: block;
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
}
.flatpickr-calendar .numInputWrapper span.arrowUp::after {
    border-bottom: 5px solid #475569;
    border-top: 0;
}
.flatpickr-calendar .numInputWrapper span.arrowDown::after {
    border-top: 5px solid #475569;
    border-bottom: 0;
}
.flatpickr-calendar .numInputWrapper span.arrowUp:hover::after {
    border-bottom-color: #fff;
}
.flatpickr-calendar .numInputWrapper span.arrowDown:hover::after {
    border-top-color: #fff;
}
.flatpickr-calendar .numInputWrapper span.arrowUp i,
.flatpickr-calendar .numInputWrapper span.arrowDown i {
    display: none !important;
}
.flatpickr-current-month .numInputWrapper {
    width: 4.6em;
}
.flatpickr-time .numInputWrapper {
    background: #f8fafc;
    border: 1px solid #dbe3ec;
    border-radius: 8px;
    overflow: hidden;
}
.rite-detail {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e6ebf2;
}
.rite-detail[hidden] {
    display: none !important;
}
.detail-subhead {
    margin: 0 0 12px;
    font-size: .9rem;
    font-weight: 700;
    color: #1b2a4a;
}
.obit-info .field-range {
    display: flex;
    gap: 8px;
    align-items: center;
    min-width: 0;
    width: 100%;
    flex-wrap: wrap;
}
.obit-info .field-range input[type="datetime-local"] {
    flex: 1 1 160px;
    min-width: 0;
    min-height: 40px;
}
.obit-info .field-range input[type="text"],
.obit-info .field-range input:not([type]) {
    flex: 1 1 140px;
    min-width: 0;
    min-height: 40px;
}
.obit-info .range-tilde {
    flex: none;
    color: #64748b;
}
.rite-note {
    margin: 8px 0 0;
    color: #c2410c;
    font-size: .78rem;
    line-height: 1.4;
}
.obit-deceased > .field,
.obit-deceased .deceased-detail > .field,
.obit-info > .field,
.obit-mobile > .field {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
    column-gap: 8px;
    margin-top: 10px;
}
.obit-deceased > .field > span:first-child,
.obit-deceased .deceased-detail > .field > span:first-child,
.obit-info > .field > span:first-child,
.obit-mobile > .field > span:first-child {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 4.6rem;
    max-width: 6.2rem;
    min-height: 40px;
    padding: 6px 8px;
    text-align: center;
    color: #334155;
    font-weight: 700;
    font-size: .78rem;
    background: #e8e8e8;
    border-radius: 8px;
}
.obit-portrait {
    width: fit-content;
    max-width: 100%;
    height: fit-content;
    box-sizing: border-box;
    padding: 14px;
}
.obit-portrait h2 {
    margin: 0 0 10px;
    white-space: nowrap;
}
.obit-portrait .portrait-picker,
.obit-portrait .portrait-frame {
    width: 120px;
}
.obit-portrait .portrait-box {
    width: 120px;
    height: 150px;
}
.portrait-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
    width: 100%;
    min-width: 120px;
}
.schedule-manage-btn,
.schedule-extra-btn,
.guest-link-btn {
    display: flex;
    width: 100%;
    border-radius: 8px;
    font-size: .82rem;
    font-weight: 600;
    white-space: nowrap;
    padding: 9px 10px;
}
.btn.schedule-manage-btn {
    border-color: #1b2a4a;
    background: #fff;
    color: #1b2a4a !important;
}
.btn.schedule-manage-btn:hover:not(:disabled),
.btn.schedule-manage-btn:focus:not(:disabled) {
    background: #1b2a4a;
    border-color: #1b2a4a;
    color: #fff !important;
}
.schedule-extra-btn,
.guest-link-btn {
    border-color: #64748b;
    background: #fff;
    color: #1e293b;
}
.schedule-extra-btn:hover:not(:disabled),
.guest-link-btn:hover:not(:disabled) {
    background: #f8fafc;
    border-color: #475569;
}
.area-admin .schedule-manage-btn,
.area-admin .schedule-extra-btn,
.area-admin .guest-link-btn {
    border-radius: 6px;
}
.form-dialog.guest-link-dialog {
    width: min(560px, calc(100vw - 24px));
}
.guest-link-body { padding: 16px 18px; }
.guest-link-tip {
    margin: 0 0 14px;
    font-size: .82rem;
    line-height: 1.45;
}
.guest-link-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 12px;
}
.guest-link-fields .field {
    margin-bottom: 0;
}
.guest-link-field { margin-bottom: 0; }
.guest-link-line {
    display: flex;
    gap: 8px;
    align-items: center;
    min-width: 0;
}
.guest-link-line input {
    flex: 1 1 auto;
    min-width: 0;
}
.guest-link-line .btn {
    flex: 0 0 auto;
    white-space: nowrap;
}
.guest-link-actions {
    margin-top: 16px;
    justify-content: flex-end;
}
@media (max-width: 600px) {
    .guest-link-fields { grid-template-columns: 1fr; }
}
.area-admin .btn.schedule-manage-btn {
    border-color: #111;
    background: #fff;
    color: #111 !important;
}
.area-admin .btn.schedule-manage-btn:hover:not(:disabled),
.area-admin .btn.schedule-manage-btn:focus:not(:disabled) {
    background: #111;
    border-color: #111;
    color: #fff !important;
}
.area-hall .btn.schedule-manage-btn {
    background: #fff;
    color: #1b2a4a !important;
}
.area-hall .btn.schedule-manage-btn:hover:not(:disabled),
.area-hall .btn.schedule-manage-btn:focus:not(:disabled) {
    background: #1b2a4a;
    color: #fff !important;
}
.form-dialog.schedule-dialog {
    width: min(860px, calc(100vw - 24px));
    max-width: none;
}
.schedule-dialog-head {
    background: #1b2a4a;
    border-bottom: 0;
    padding: 12px 14px;
}
.schedule-dialog-head h3 {
    color: #fff;
    font-size: .95rem;
    font-weight: 700;
}
.schedule-dialog-x {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #fff;
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
}
.schedule-dialog-x:hover { background: rgba(255, 255, 255, .12); }
.schedule-dialog-body { padding: 14px 16px 16px; }
.schedule-seed-note {
    margin: 0 0 12px;
    color: #64748b;
    font-size: .78rem;
    line-height: 1.45;
}
.schedule-table-wrap {
    overflow: auto;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}
.schedule-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    min-width: 640px;
}
.schedule-table th,
.schedule-table td {
    padding: 8px;
    border-bottom: 1px solid #e6ebf2;
    vertical-align: middle;
}
.schedule-table th {
    background: #f1f5f9;
    color: #334155;
    font-size: .78rem;
    font-weight: 700;
    text-align: left;
}
.schedule-table tbody tr:last-child td { border-bottom: 0; }
.schedule-table th:nth-child(1),
.schedule-table td:nth-child(1) { width: 18%; }
.schedule-table th:nth-child(2),
.schedule-table td:nth-child(2) { width: 12%; }
.schedule-table th:nth-child(3),
.schedule-table td:nth-child(3) { width: 22%; }
.schedule-table th:nth-child(4),
.schedule-table td:nth-child(4) { width: 28%; }
.schedule-table th:nth-child(5),
.schedule-table td:nth-child(5) { width: 120px; text-align: center; }
.schedule-table input {
    width: 100%;
    min-height: 36px;
    box-sizing: border-box;
    border: 1px solid #d0d7e2;
    border-radius: 6px;
    padding: 6px 8px;
    font: inherit;
    background: #fff;
}
.schedule-order {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}
.schedule-move,
.schedule-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    margin: 0;
    padding: 0;
    border-radius: 6px;
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #334155;
    font-size: .9rem;
    line-height: 1;
    cursor: pointer;
}
.schedule-remove {
    border-color: #f1a8a8;
    color: #dc2626;
}
.schedule-move:hover,
.schedule-remove:hover { background: #f8fafc; }
.schedule-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 12px;
}
.schedule-add-row {
    border-radius: 8px;
    border-color: #3b82f6;
    color: #2563eb;
    background: #fff;
    font-weight: 600;
}
.schedule-add-row:hover {
    background: #eff6ff;
}
.schedule-actions { margin: 0; }
.schedule-close-btn {
    border-radius: 8px;
    background: #94a3b8;
    border-color: #94a3b8;
    color: #fff;
}
.schedule-close-btn:hover {
    background: #64748b;
    border-color: #64748b;
}
.schedule-actions .btn-primary {
    border-radius: 8px;
}
.area-admin .schedule-dialog-head { background: #1f2937; }
.area-admin .schedule-add-row { border-radius: 6px; }
.area-admin .schedule-close-btn,
.area-admin .schedule-actions .btn-primary { border-radius: 6px; }
@media (max-width: 720px) {
    .schedule-toolbar { align-items: stretch; }
    .schedule-actions { width: 100%; justify-content: flex-end; }
}
.form-dialog.schedule-extra-dialog {
    width: min(520px, calc(100vw - 24px));
}
.schedule-extra-body { padding: 18px 18px 16px; }
.schedule-extra-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.schedule-extra-row {
    display: grid;
    grid-template-columns: 88px minmax(0, 1fr);
    align-items: center;
    column-gap: 12px;
    margin: 0;
}
.schedule-extra-row > span {
    color: #1e293b;
    font-size: .9rem;
    font-weight: 600;
    letter-spacing: .08em;
    white-space: nowrap;
}
.schedule-extra-row input {
    width: 100%;
    min-height: 40px;
    border: 1px solid #cfd6de;
    border-radius: 6px;
    padding: 8px 10px;
}
.schedule-extra-actions {
    margin-top: 18px;
    justify-content: flex-end;
}
.schedule-extra-actions .btn {
    min-width: 72px;
    border-radius: 6px;
    border-color: #111;
    background: #fff;
    color: #111;
}
.schedule-extra-actions .btn:hover {
    background: #f8fafc;
}
/*
  영정정보 | 고인정보 | 모바일 부고장
           | 부고정보 | 상주정보(+업무)
  고인·부고는 한 묶음이라 우측이 길어도 사이 간격이 벌어지지 않음
*/
@media (min-width: 1100px) {
    .obit-split {
        grid-template-columns: auto minmax(0, 1.2fr) minmax(320px, .95fr);
        gap: 16px;
        align-items: start;
        align-content: start;
    }
    .obit-col-left {
        display: contents;
    }
    .obit-portrait {
        display: block;
        width: fit-content;
        max-width: 100%;
        height: fit-content;
        align-self: start;
    }
    .obit-portrait .portrait-actions {
        margin-top: 12px;
        width: 100%;
        min-width: 120px;
    }
    .obit-left-main {
        display: flex;
        flex-direction: column;
        gap: 16px;
        min-width: 0;
        height: fit-content;
        align-self: start;
    }
    .obit-col-right {
        display: flex;
        flex-direction: column;
        gap: 16px;
        height: fit-content;
        align-self: start;
        position: sticky;
        top: 12px;
        max-height: calc(100vh - 24px);
        overflow: auto;
    }
}
@media (min-width: 1600px) {
    .obit-split {
        grid-template-columns: auto minmax(0, 1.35fr) minmax(400px, 1fr);
    }
    .obit-deceased .form-grid,
    .obit-info .form-grid,
    .area-admin .obit-deceased .form-grid,
    .area-admin .obit-info .form-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
    .obit-mobile .form-grid,
    .area-admin .obit-mobile .form-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
.obit-mourners .panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}
.obit-mourners .panel-head h2 { margin: 0; }
.obit-mourners .panel-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.btn-navy,
#mourner-detail-open.btn-primary {
    background: #1b2a4a;
    border-color: #1b2a4a;
    color: #fff;
}
.btn-navy:hover,
#mourner-detail-open.btn-primary:hover {
    background: #243656;
    border-color: #243656;
    color: #fff;
}
.area-admin .btn-navy,
.area-admin #mourner-detail-open.btn-primary {
    background: #1b2a4a;
    border-color: #1b2a4a;
    color: #fff;
}
.btn-outline-danger {
    background: #fff;
    border-color: #dc2626;
    color: #dc2626;
}
.btn-outline-danger:hover {
    background: #fef2f2;
    border-color: #b91c1c;
    color: #b91c1c;
}
.mourner-detail-group {
    margin-bottom: 16px;
    border: 1px solid #e6ebf2;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}
.mourner-detail-group h4 {
    margin: 0;
    padding: 10px 12px;
    background: #f3f6fb;
    border-bottom: 1px solid #e6ebf2;
    font-size: .92rem;
    color: #1b2a4a;
}
.mourner-detail-table { display: flex; flex-direction: column; }
.mourner-detail-head,
.mourner-detail-row {
    display: grid;
    grid-template-columns: 28px minmax(80px, .7fr) minmax(110px, 1fr) minmax(100px, .85fr) minmax(120px, 1.1fr) minmax(90px, .8fr) minmax(120px, .95fr) auto;
    gap: 10px;
    align-items: center;
    padding: 10px 14px;
}
.mourner-detail-row .col-drag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 0;
    padding: 0;
    background: transparent;
    color: #94a3b8;
    cursor: grab;
    letter-spacing: -1px;
    user-select: none;
}
.mourner-detail-row .col-drag:active { cursor: grabbing; }
.mourner-detail-row.is-dragging { opacity: .55; }
.mourner-detail-row.drag-over { box-shadow: inset 0 2px 0 #1b2a4a; }
.mourner-share-actions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}
.mourner-share-actions .btn {
    min-height: 32px;
    height: 32px;
    padding: 0 10px;
    font-size: .78rem;
}
.mourner-share-pending {
    color: #94a3b8;
    font-size: .78rem;
    white-space: nowrap;
}
.mourner-detail-head {
    background: #f8fafc;
    border-bottom: 1px solid #eef2f7;
    color: #64748b;
    font-size: .78rem;
    font-weight: 700;
}
.mourner-detail-row {
    border-bottom: 1px solid #f1f5f9;
    background: #fff;
}
.mourner-detail-row:last-child { border-bottom: 0; }
.mourner-detail-row .col-name {
    font-weight: 600;
    color: #1e293b;
    font-size: .9rem;
}
.mourner-detail-row .col-name input {
    font-weight: 600;
}
.mourner-detail-row input,
.mourner-detail-row select {
    width: 100%;
    min-width: 0;
}
.mourner-detail-row .col-verify { justify-self: end; }
.btn-account-verify {
    white-space: nowrap;
    background: #fff;
    border-color: #1b2a4a;
    color: #1b2a4a;
    min-height: 38px;
    padding: 0 12px;
}
.btn-account-verify:hover {
    background: #eef3fb;
    border-color: #1b2a4a;
    color: #1b2a4a;
}
.btn-account-verify .verify-label-card { display: none; }
@media (max-width: 900px) {
    .form-dialog.mourner-detail-dialog { width: calc(100vw - 16px); }
    .mourner-detail-group {
        border: 0;
        background: transparent;
        overflow: visible;
        margin-bottom: 14px;
    }
    .mourner-detail-group h4 {
        border: 0;
        border-radius: 8px;
        margin-bottom: 8px;
    }
    .mourner-detail-table {
        gap: 10px;
    }
    .mourner-detail-head { display: none; }
    .mourner-detail-row {
        grid-template-columns: 28px 1fr;
        grid-template-areas:
            "drag name"
            "drag phone"
            "drag holder"
            "drag bank"
            "drag account"
            "drag share"
            "drag verify";
        gap: 8px;
        padding: 12px;
        border: 1px solid #e6ebf2;
        border-radius: 10px;
        background: #fff;
        box-shadow: 0 1px 2px rgba(15, 23, 42, .04);
    }
    .mourner-detail-row:last-child { border-bottom: 1px solid #e6ebf2; }
    .mourner-detail-row .col-drag { grid-area: drag; align-self: start; margin-top: 6px; }
    .mourner-detail-row .col-name {
        grid-area: name;
        padding-bottom: 6px;
        margin-bottom: 2px;
        border-bottom: 1px solid #eef2f7;
        font-size: .95rem;
    }
    .mourner-detail-row .col-phone { grid-area: phone; }
    .mourner-detail-row .col-holder { grid-area: holder; }
    .mourner-detail-row .col-bank { grid-area: bank; }
    .mourner-detail-row .col-account { grid-area: account; }
    .mourner-detail-row .col-share { grid-area: share; }
    .mourner-detail-row .col-verify {
        grid-area: verify;
        justify-self: stretch;
    }
    .mourner-detail-row .col-verify .btn-account-verify {
        width: 100%;
    }
    .btn-account-verify .verify-label-list { display: none; }
    .btn-account-verify .verify-label-card { display: inline; }
}
.obit-mourners .muted { margin: 0 0 12px; font-size: .82rem; }
.obit-mourners .mourner-list {
    border: 1px solid #e6ebf2;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}
.obit-mourners .mourner-list-head,
.obit-mourners .mourner-group {
    display: grid;
    grid-template-columns: 28px minmax(240px, 320px) minmax(0, 1fr) 64px;
    gap: 8px;
    align-items: center;
    padding: 8px 10px;
}
.obit-mourners .mourner-list-head {
    background: #f8fafc;
    border-bottom: 1px solid #e6ebf2;
    color: #64748b;
    font-size: .8rem;
    font-weight: 700;
}
.obit-mourners .mourner-list-head .col-relation { padding-left: 2px; }
.obit-mourners #mourners { display: flex; flex-direction: column; }
.obit-mourners .mourner-group {
    border-bottom: 1px solid #eef2f7;
    background: #fff;
    min-height: 52px;
}
.obit-mourners .mourner-group:last-child { border-bottom: 0; }
.obit-mourners .mourner-group.is-dragging { opacity: .55; background: #f8fafc; }
.obit-mourners .mourner-group.drag-over { box-shadow: inset 0 2px 0 #1b2a4a; }
.obit-mourners .group-drag-handle {
    border: 0;
    background: transparent;
    color: #94a3b8;
    cursor: grab;
    padding: 6px 2px;
    line-height: 1;
    font-size: .95rem;
    letter-spacing: -2px;
}
.obit-mourners .group-drag-handle:active { cursor: grabbing; }
.obit-mourners .mourner-relation-fields {
    display: grid;
    grid-template-columns: minmax(110px, 130px) minmax(0, 1fr);
    gap: 6px;
    min-width: 0;
}
.obit-mourners .group-relation-preset,
.obit-mourners .group-relation,
.obit-mourners .name-write {
    width: 100%;
    min-width: 0;
}
.obit-mourners .group-relation.is-readonly,
.obit-mourners .group-relation[readonly] {
    background: #eef2f7;
    color: #475569;
    cursor: default;
}
.obit-mourners .name-inbox {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    min-height: 38px;
    padding: 4px 8px;
    border: 1px solid #d7dee8;
    border-radius: 6px;
    background: #fff;
    cursor: text;
    min-width: 0;
}
.obit-mourners .name-box {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.obit-mourners .name-write {
    flex: 1 1 120px;
    border: 0 !important;
    box-shadow: none !important;
    outline: none;
    min-height: 28px;
    padding: 4px 2px;
    background: transparent;
}
.obit-mourners .mn-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 999px;
    background: #e8eef8;
    color: #1b2a4a;
    font-size: .86rem;
    line-height: 1.2;
    cursor: grab;
    user-select: none;
}
.obit-mourners .mn-chip.is-dragging { opacity: .55; }
.obit-mourners .mn-chip.drag-over { box-shadow: inset 0 0 0 1px #1b2a4a; }
.obit-mourners .mn-chip.has-detail {
    background: #dce8f8;
    box-shadow: inset 0 0 0 1px #9bb4d6;
}
.obit-mourners .mn-chip.has-share,
.obit-mourners .mn-chip.is-draft {
    padding-right: 6px;
}
.obit-mourners .mn-chip em {
    font-style: normal;
    font-weight: 600;
}
.obit-mourners .mn-chip-pending {
    display: inline-flex;
    align-items: center;
    min-height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: #fff7ed;
    color: #c2410c;
    font-size: .7rem;
    font-weight: 700;
    line-height: 1;
}
.obit-mourners .mn-chip-link,
.obit-mourners .mn-chip-copy {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 20px;
    padding: 0 6px;
    border: 1px solid #9bb4d6;
    border-radius: 999px;
    background: #fff;
    color: #1b2a4a;
    font-size: .72rem;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
}
.obit-mourners .mn-chip-copy {
    border-color: #cbd5e1;
    color: #475569;
}
.obit-mourners .mn-chip-x {
    border: 0;
    background: transparent;
    color: #64748b;
    cursor: pointer;
    padding: 0 2px;
    font-size: 1rem;
    line-height: 1;
}
.obit-mourners .remove-mourner-group {
    white-space: nowrap;
    justify-self: end;
}
.obit-work .work-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.obit-work .field {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    align-items: start;
    column-gap: 8px;
    margin-bottom: 0;
}
.obit-work .field > span:first-child {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 6px 8px;
    text-align: center;
    color: #334155;
    font-weight: 700;
    font-size: .78rem;
    background: #e8e8e8;
    border-radius: 8px;
}
.obit-work .work-checks {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    align-items: center;
    min-height: 40px;
}
.obit-work .work-check {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center;
    gap: 6px;
    margin: 0;
    font-size: .9rem;
    color: #1e293b;
    white-space: nowrap;
    cursor: pointer;
}
.obit-work .work-check input[type="checkbox"] {
    width: 16px;
    height: 16px;
    min-height: 0;
    margin: 0;
    padding: 0;
    flex: none;
    accent-color: #1b2a4a;
}
.obit-work .work-check span {
    font-size: .9rem;
    color: #1e293b;
    font-weight: 500;
    background: transparent;
    padding: 0;
    min-height: 0;
}
.obit-work textarea,
.obit-work input[type="text"],
.obit-work input:not([type]) {
    width: 100%;
    min-height: 40px;
}
.obit-work textarea {
    min-height: 96px;
    resize: vertical;
}
.area-admin .obit-work .field {
    grid-template-columns: 76px minmax(0, 1fr);
    margin-bottom: 0;
}
.obit-mobile .mobile-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}
.obit-mobile .mobile-panel-head h2 {
    margin: 0;
}
.obit-mobile .tip-line {
    grid-column: 1 / -1;
    margin: 0;
    font-size: .8rem;
    line-height: 1.45;
}
.obit-mobile .mobile-panel-actions {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
    flex-wrap: wrap;
    justify-content: flex-end;
}
.obit-mobile .tip-send-btn,
.obit-mobile .tip-copy-btn {
    flex: 0 0 auto;
    white-space: nowrap;
}
.obit-mobile .tip-send-btn.is-muted,
.obit-mobile .tip-copy-btn.is-muted {
    opacity: .55;
}
.obit-mobile .form-grid,
.area-admin .obit-mobile .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
}
.obit-mobile .form-grid > .field:not(.mobile-notice-field),
.area-admin .obit-mobile .form-grid > .field:not(.mobile-notice-field) {
    grid-column: span 1;
    width: 100%;
    max-width: none;
    min-width: 0;
}
.obit-mobile .form-grid .field > input,
.area-admin .obit-mobile .form-grid .field > input {
    width: 100%;
    min-width: 0;
}
.obit-mobile .field > span:first-child,
.area-admin .obit-mobile .field > span:first-child {
    min-width: 5.2rem;
    max-width: 6.5rem;
    flex: none;
}
.obit-mobile .form-grid .mobile-notice-field,
.area-admin .obit-mobile .form-grid .mobile-notice-field {
    grid-column: 1 / -1 !important;
    width: 100%;
    max-width: none;
    min-width: 0;
    align-items: start;
    grid-template-columns: 5.6rem minmax(0, 1fr);
}
.obit-mobile .mobile-notice-field > span:first-child,
.area-admin .obit-mobile .mobile-notice-field > span:first-child {
    min-width: 5.2rem;
    max-width: 5.6rem;
    min-height: 40px;
}
.obit-mobile .mobile-notice-field textarea,
.area-admin .obit-mobile .mobile-notice-field textarea {
    width: 100%;
    max-width: none;
    min-width: 0;
    min-height: 96px;
    box-sizing: border-box;
    resize: vertical;
}
.mourner-family .mourner-share {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
body.area-family { background: #f4f6fa; color: #1e293b; font-size: 14px; }
.family-top {
    background: #1b2a4a;
    color: #fff;
}
.family-top-inner {
    width: min(1080px, calc(100% - 32px));
    margin: 0 auto;
    min-height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.family-top-inner span { color: #c9d4e6; font-size: .82rem; }
body.area-family h1 { color: #1b2a4a; font-size: 1.2rem; font-weight: 700; }
body.area-family .btn-primary { background: #1b2a4a; border-color: #1b2a4a; color: #fff; }
body.area-family .card,
body.area-family .obit-panel {
    border: 1px solid #e6ebf2;
    border-radius: 10px;
    box-shadow: none;
}
.portrait-now { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.portrait-now img { width: 72px; height: 90px; object-fit: cover; border-radius: 8px; }
.portrait-field { margin-top: 8px; }
.portrait-picker {
    display: block;
}
.portrait-frame {
    position: relative;
    width: 120px;
    flex: none;
}
.portrait-box {
    width: 120px;
    height: 150px;
    padding: 0;
    border: 1px solid #d5deea;
    border-radius: 4px;
    background: #f1f3f6;
    color: #64748b;
    cursor: pointer;
    overflow: hidden;
    display: grid;
    place-items: center;
    position: relative;
}
.portrait-box:hover { background: #e8ecf1; }
.portrait-picker.has-image .portrait-box {
    border-color: #cfd6de;
    background: #fff;
}
.portrait-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.portrait-box img[hidden],
.portrait-box img:not([src]),
.portrait-box img[src=""] {
    display: none !important;
}
.portrait-placeholder {
    width: 100%;
    height: 100%;
    pointer-events: none;
}
.portrait-clear-x {
    display: none;
    position: absolute;
    top: 4px;
    right: 4px;
    z-index: 2;
    width: 24px;
    height: 24px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(15, 23, 42, .72);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 4px rgba(15, 23, 42, .25);
}
.portrait-picker.has-image .portrait-clear-x {
    display: inline-flex;
}
.portrait-clear-x:hover {
    background: rgba(185, 28, 28, .92);
}
.share-box textarea { font-family: inherit; }

body.area-admin,
body.area-admin-auth {
    background: #f4f6fa;
    color: #1e293b;
    font-size: 14px;
}
body.area-admin h1 { font-size: 1.2rem; }
body.area-admin h2 { font-size: .95rem; }
body.area-admin h3 { font-size: .9rem; }
body.area-admin .stats strong { font-size: 1.4rem; }
body.area-admin th { font-size: .8rem; }
body.area-admin .badge { font-size: .75rem; }
body.area-admin-auth h1 { font-size: 1.35rem; }
.admin-side {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 220px;
    background: #111;
    color: #d4d4d4;
    display: flex;
    flex-direction: column;
    z-index: 20;
}
.admin-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    height: 64px;
    padding: 0 18px;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    letter-spacing: .08em;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.admin-mark {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: grid;
    place-items: center;
    background: #2a2a2a;
    color: #fff;
    font-size: .78rem;
    letter-spacing: 0;
}
.admin-nav, .admin-side-foot { display: flex; flex-direction: column; gap: 2px; padding: 12px 10px; }
.admin-side-foot { margin-top: auto; border-top: 1px solid rgba(255, 255, 255, .08); }
.admin-nav a, .admin-side-foot a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #cfcfcf;
    text-decoration: none;
    padding: 11px 12px;
    border-radius: 8px;
}
.admin-nav a:hover, .admin-side-foot a:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.admin-nav a.on { background: #2a2a2a; color: #fff; }
.admin-nav-group { display: flex; flex-direction: column; gap: 2px; }
.admin-nav-parent { position: relative; }
.admin-nav-parent .nav-caret {
    margin-left: auto;
    width: 6px;
    height: 6px;
    border-right: 1.6px solid currentColor;
    border-bottom: 1.6px solid currentColor;
    transform: rotate(45deg);
    opacity: .7;
    transition: transform .15s ease;
}
.admin-nav-group.open .admin-nav-parent .nav-caret { transform: rotate(225deg); }
.admin-nav-sub {
    display: none;
    flex-direction: column;
    gap: 2px;
    padding: 0 0 4px 18px;
}
.admin-nav-group.open .admin-nav-sub { display: flex; }
.admin-nav-sub a {
    padding: 9px 12px 9px 22px;
    font-size: .92rem;
    color: #bdbdbd;
}
.admin-nav-sub a.on { background: #2a2a2a; color: #fff; }
.side-pc-note {
    margin: 10px 2px 4px;
    padding: 10px 10px;
    border-radius: 8px;
    background: rgba(255, 255, 255, .06);
    color: rgba(255, 255, 255, .72);
    font-size: .72rem;
    line-height: 1.45;
}
.nav-ico { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.admin-body { margin-left: 220px; min-height: 100vh; }
.admin-top {
    height: 56px;
    background: #fff;
    border-bottom: 1px solid #e6ebf2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
}
.admin-top span { color: #64748b; }
.admin-content { padding: 24px 28px 56px; }
.area-admin .card, .area-admin .stats div {
    border: 1px solid #e6ebf2;
    border-radius: 10px;
    box-shadow: none;
    background: #fff;
}
.area-admin .stats div { padding: 16px 18px; }
.area-admin .stats strong { color: #111; }
.area-admin h1 { font-weight: 700; color: #111; }
.area-admin .form-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px 20px;
    align-items: center;
    margin-bottom: 14px;
}
.area-admin .form-grid.single { grid-template-columns: 1fr; }
.area-admin .form-block + .form-block { margin-top: 6px; }
.area-admin .form-block h2 { margin: 2px 0 12px; font-size: .875rem; color: #111; }
.area-admin .span-2 { grid-column: 1 / -1; }
.area-admin .address-line { display: flex; gap: 8px; min-width: 0; align-items: center; }
.area-admin .address-line input.zip { width: 140px; flex: 0 0 140px; }
.area-admin .address-line .btn { flex: none; }
.postcode-modal {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, .45);
}
.postcode-modal[hidden] { display: none; }
.postcode-dialog {
    width: min(520px, 100%);
    height: min(640px, calc(100vh - 48px));
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 18px 50px rgba(15, 23, 42, .25);
}
.postcode-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border-bottom: 1px solid #e6ebf2;
}
.postcode-embed { flex: 1; min-height: 0; }
.area-admin .field {
    display: grid;
    grid-template-columns: 140px minmax(0, 1fr);
    align-items: center;
    column-gap: 12px;
    margin-bottom: 14px;
}
.area-admin .form-grid .field { margin-bottom: 0; }
.area-admin .field > span:first-child {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 40px;
    padding: 6px 10px;
    text-align: center;
    color: #111;
    font-weight: 700;
    font-size: .82rem;
    line-height: 1.3;
    background: #e8e8e8;
    border-radius: 8px;
}
.area-admin .field.is-required > span:first-child,
.area-admin .field:has([required]) > span:first-child {
    color: var(--required);
}
.area-admin .field > span:first-child i { color: #111; font-style: normal; }
.area-admin .field.is-required > span:first-child i,
.area-admin .field:has([required]) > span:first-child i {
    color: var(--required);
}
.area-admin .tip {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    margin-left: 4px;
    border-radius: 50%;
    background: #111;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    cursor: help;
    flex: none;
}
.area-admin .tip-box {
    display: none;
    position: absolute;
    left: 50%;
    top: calc(100% + 8px);
    transform: translateX(-50%);
    width: 260px;
    padding: 10px 12px;
    border-radius: 8px;
    background: #111;
    color: #fff;
    font-size: .75rem;
    font-weight: 400;
    line-height: 1.45;
    text-align: left;
    white-space: normal;
    z-index: 40;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .2);
}
.area-admin .tip:hover .tip-box,
.area-admin .tip:focus .tip-box,
.area-admin .tip:focus-within .tip-box { display: block; }
.area-admin .field:has(textarea) { align-items: start; }
.area-admin .portrait-now { grid-column: 2; }
.area-admin input,
.area-admin select,
.area-admin textarea {
    border: 1px solid #d5deea;
    border-radius: 6px;
    background: #fff;
    padding: 9px 12px;
    min-height: 40px;
}
.area-admin textarea { min-height: 88px; }
.area-admin input:required,
.area-admin select:required,
.area-admin textarea:required,
.area-hall input:required,
.area-hall select:required,
.area-hall textarea:required {
    border-color: #e7b0b0;
}
.area-admin input:focus,
.area-admin select:focus,
.area-admin textarea:focus {
    outline: none;
    border-color: #111;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, .14);
}
.area-admin input:disabled { background: #f1f5f9; color: #64748b; }
.area-admin .btn,
.area-admin a.btn,
.area-admin button.btn {
    border-radius: 6px;
    min-height: 40px;
    height: 40px;
    padding: 0 16px;
    line-height: 1;
    box-sizing: border-box;
}
.area-admin .btn-primary { background: #111; border-color: #111; color: #fff; }
.area-admin .btn-primary:hover { background: #2a2a2a; }
.floor-panels { align-items: start; margin-bottom: 16px; }
.floor-panels > .floor-board { margin-bottom: 0; min-width: 0; }
.floor-board .section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}
.floor-board .section-head h2 { margin: 0; }
.section-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.room-filter { display: inline-flex; align-items: center; gap: 8px; margin: 0; color: #1e293b; font-size: .82rem; }
.room-filter select { width: auto; min-width: 140px; min-height: 38px; }
.form-modal {
    position: fixed;
    inset: 0;
    z-index: 85;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, .45);
}
.form-modal[hidden] { display: none; }
.form-dialog {
    width: min(480px, 100%);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 18px 50px rgba(15, 23, 42, .25);
    overflow: hidden;
}
.form-dialog.mourner-detail-dialog {
    width: min(1320px, calc(100vw - 40px));
    max-width: none;
}
.form-dialog.mourner-detail-dialog .form-dialog-body {
    max-height: min(82vh, 880px);
    overflow: auto;
}
.form-dialog-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid #e6ebf2;
}
.form-dialog-head h3 { margin: 0; font-size: .95rem; color: #111; }
.area-admin .floor-table tr.drag-over { background: #f0f0f0; }
.form-dialog-body { padding: 16px; }
.form-dialog-body .actions { margin-top: 4px; justify-content: flex-end; }
.floor-table { margin-top: 8px; border-top: 1px solid #e6ebf2; }
.floor-table tr[draggable="true"] { cursor: grab; }
.floor-table tr[draggable="true"].is-dragging { opacity: .45; }
.floor-table tr.drag-over { background: #eef3fb; }
.drag-handle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    margin-right: 8px;
    color: #94a3b8;
    letter-spacing: -1px;
    user-select: none;
}
.floor-table th.manage-col,
.floor-table td.manage-col { width: 180px; text-align: right; }
.manage-actions { display: inline-flex; align-items: center; justify-content: flex-end; gap: 8px; }
.manage-actions .inline-form { margin: 0; }
.area-admin .filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 20px;
    background: #fff;
    border: 1px solid #e6ebf2;
    border-radius: 10px;
    padding: 16px 18px;
}
.area-admin .filters .field { flex: 1 1 260px; margin: 0; }
.area-admin .filters input,
.area-admin .filters select { width: 100%; min-width: 0; }
.area-admin .filters .btn { flex: none; }
.area-admin th { background: #f8fafc; color: #64748b; font-weight: 600; }
.area-admin td { color: #1e293b; }
.area-admin .card.form .checks,
.area-admin .card.form .actions { margin-left: 152px; }

.place-settings {
    display: grid;
    gap: 16px;
    max-width: 920px;
}
.place-section {
    margin: 0;
    padding: 18px 20px 20px;
}
.place-section-head {
    margin: 0 0 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e8eef5;
}
.place-section-head h2 {
    margin: 0 0 4px;
    font-size: 1.05rem;
    color: #0f172a;
}
.place-section-head .muted {
    margin: 0;
    font-size: .86rem;
    line-height: 1.45;
}
.place-form .form-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.place-form .field {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    align-items: center;
    column-gap: 12px;
    margin-bottom: 0;
}
.place-form .field > span:first-child {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 6px 10px;
    color: #111;
    font-weight: 700;
    background: #d9e4f4;
    border-radius: 8px;
    text-align: center;
    white-space: nowrap;
}
.place-form .field:has(textarea) { align-items: start; }
.place-form .field:has(textarea) > span:first-child { margin-top: 4px; }
.place-form .address-line { display: flex; gap: 8px; align-items: center; min-width: 0; }
.place-form .address-line input.zip { width: 140px; flex: 0 0 140px; }
.place-form input,
.place-form select,
.place-form textarea {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    border: 1px solid #d5deea;
    border-radius: 6px;
    padding: 9px 12px;
    min-height: 40px;
}
.place-form textarea { min-height: 88px; }
.place-notice-field {
    display: block;
    margin: 0;
}
.place-notice-field textarea {
    width: 100%;
    min-height: 160px;
    box-sizing: border-box;
}
.place-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
#fv-hall-notice h2 {
    color: #1f3f61;
}

body.area-hall,
body.area-auth,
body.area-public {
    font-size: 14px;
}
body.area-hall h1 { font-size: 1.2rem; }
body.area-auth h1 { font-size: 1.35rem; }
body.area-hall h2,
body.area-auth h2 { font-size: .95rem; }
body.area-hall h3,
body.area-auth h3 { font-size: .9rem; }
body.area-hall .stats strong { font-size: 1.4rem; }
body.area-hall th,
body.area-auth th { font-size: .8rem; }
body.area-hall .field > span,
body.area-auth .field > span { font-size: .8rem; }
body.area-hall .badge { font-size: .75rem; }
body.area-hall .room-name { font-size: 1.05rem; }
body.area-hall .floor-title { font-size: .95rem; }
body.area-auth .eyebrow { font-size: .78rem; }
body.area-auth .login-mode label { font-size: .9rem; }
body.area-hall .layer-pop-item h2,
body.area-auth .layer-pop-item h2 { font-size: 1.05rem; }
body.area-public .fv-identity h1 { font-size: 1.55rem; }
body.area-public .fv-card h2 { font-size: 1rem; }

.area-auth { background: #f4f6fa; color: #1e293b; }
.area-admin-auth .login-card,
.area-auth .login-card {
    border: 1px solid #e6ebf2;
    border-radius: 10px;
    box-shadow: none;
}
.area-admin-auth h1 { color: #111; }
.area-auth h1 { color: #1b2a4a; }
.area-admin-auth .login-card h1,
.area-auth .login-card h1 { margin: 0 0 28px; }
.area-admin-auth .eyebrow { letter-spacing: .12em; font-size: .78rem; color: #111; }
.area-admin-auth .admin-login-form,
.area-auth .hall-login-form {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
}
.area-admin-auth .admin-login-form input:not([type="checkbox"]):not([type="radio"]),
.area-auth .hall-login-form input:not([type="checkbox"]):not([type="radio"]) {
    width: 100%;
    border: 1px solid #d5deea;
    border-radius: 6px;
    margin: 0;
}
.area-admin-auth .admin-login-form input:not([type="checkbox"]):not([type="radio"]):focus {
    outline: none;
    border-color: #111;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, .14);
}
.area-auth .hall-login-form input:not([type="checkbox"]):not([type="radio"]):focus {
    outline: none;
    border-color: #1b2a4a;
    box-shadow: 0 0 0 3px rgba(27, 42, 74, .16);
}
.area-admin-auth .admin-login-form .btn-primary,
.area-auth .hall-login-form .btn-primary {
    width: 100%;
    max-width: none;
    min-height: 40px;
    margin: 0;
    border-radius: 6px;
    color: #fff;
}
.area-admin-auth .admin-login-form .btn-primary {
    background: #111;
    border-color: #111;
}
.area-admin-auth .admin-login-form .btn-primary:hover { background: #2a2a2a; }
.area-auth .hall-login-form .btn-primary {
    background: #1b2a4a;
    border-color: #1b2a4a;
}
.area-auth .hall-login-form .btn-primary:hover { background: #243656; }
.area-admin-auth .save-id,
.area-auth .save-id {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    color: #1e293b;
    font-size: .82rem;
}
.area-admin-auth .save-id input,
.area-auth .save-id input {
    width: 16px;
    height: 16px;
    min-height: 0;
    margin: 0;
    padding: 0;
    flex: none;
    border: none;
    box-shadow: none;
    appearance: auto;
}
.area-auth .save-id.is-hidden { display: none; }
.area-auth .login-mode { margin-bottom: 0; }
.area-auth .login-mode label {
    border-radius: 6px;
    font-weight: 600;
    color: #1e293b;
}
.area-auth .login-mode label:has(input:checked) {
    background: #d9e4f4;
    border-color: #1b2a4a;
    color: #1b2a4a;
}

body.area-hall { background: #f4f6fa; color: #1e293b; }
.hall-side {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 220px;
    background: #1b2a4a;
    color: #d5deee;
    display: flex;
    flex-direction: column;
    z-index: 20;
}
.hall-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 64px;
    padding: 12px 18px;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    letter-spacing: .02em;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    line-height: 1.3;
}
.hall-mark {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: grid;
    place-items: center;
    background: #2c4270;
    color: #fff;
    font-size: .78rem;
    letter-spacing: 0;
    flex: none;
}
.hall-nav, .hall-side-foot { display: flex; flex-direction: column; gap: 2px; padding: 12px 10px; }
.hall-side-foot { margin-top: auto; border-top: 1px solid rgba(255, 255, 255, .08); }
.hall-nav a, .hall-side-foot a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #c9d4e6;
    text-decoration: none;
    padding: 11px 12px;
    border-radius: 8px;
}
.hall-nav a:hover, .hall-side-foot a:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.hall-nav a.on { background: #2c4270; color: #fff; }
.hall-side .side-pc-note { color: rgba(201, 212, 230, .85); }
.hall-body { margin-left: 220px; min-height: 100vh; }
.hall-top {
    height: 56px;
    background: #fff;
    border-bottom: 1px solid #e6ebf2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
}
.hall-top span { color: #64748b; }
.area-hall .muted { color: #64748b; }
.area-hall .card,
.area-hall .room-card,
.area-hall .stats div {
    border: 1px solid #e6ebf2;
    border-radius: 10px;
    box-shadow: none;
    background: #fff;
}
.area-hall h1 { color: #1b2a4a; font-weight: 700; }
.area-hall h2,
.area-hall .floor-title { color: #1b2a4a; }
.area-hall .btn,
.area-hall a.btn,
.area-hall button.btn {
    border-radius: 6px;
    min-height: 40px;
    height: 40px;
    padding: 0 16px;
    line-height: 1;
    box-sizing: border-box;
}
.area-hall .btn-primary {
    background: #1b2a4a;
    border-color: #1b2a4a;
    color: #fff;
}
.area-hall .btn-primary:hover { background: #243656; }
.area-hall input,
.area-hall select,
.area-hall textarea {
    border: 1px solid #d5deea;
    border-radius: 6px;
    background: #fff;
    padding: 9px 12px;
    min-height: 40px;
}
.area-hall textarea { min-height: 88px; }
.area-hall input:focus,
.area-hall select:focus,
.area-hall textarea:focus {
    outline: none;
    border-color: #1b2a4a;
    box-shadow: 0 0 0 3px rgba(27, 42, 74, .16);
}
.area-hall .address-line { display: flex; gap: 8px; min-width: 0; align-items: center; }
.area-hall .address-line input.zip { width: 140px; flex: 0 0 140px; }
.area-hall .address-line .btn { flex: none; }
.area-hall th { background: #f8fafc; color: #64748b; font-weight: 600; }
.area-hall .stats strong { color: #1b2a4a; }
.area-hall .badge {
    border-radius: 6px;
    border: 1px solid transparent;
    font-weight: 700;
}
.area-hall .badge-open {
    background: #111827;
    color: #fff;
    border-color: #111827;
}
.area-hall .badge-wait {
    background: #65a30d;
    color: #fff;
    border-color: #65a30d;
}
.area-hall .badge-closed {
    background: #d1d5db;
    color: #111827;
    border-color: #d1d5db;
}
.area-public {
    background: #eceff3;
    color: #1f2937;
}
.area-public main.wrap {
    width: min(480px, 100%);
    margin: 0 auto;
    padding: 0 0 96px !important;
}
.sheet {
    width: min(440px, calc(100% - 24px));
    margin: 18px auto 40px;
    background: #fff;
    color: #1f2937;
    border: 1px solid #e5eaf1;
    border-radius: 14px;
    padding: 28px 22px 22px;
}
.sheet h1 { margin: 0 0 10px; font-size: 1.35rem; }
.fv {
    width: 100%;
    padding-bottom: 12px;
}
.fv-top {
    position: sticky;
    top: 0;
    z-index: 20;
    background: #243447;
    color: #fff;
}
.fv-top-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 48px;
    padding: 10px 16px;
}
.fv-top strong {
    font-size: .95rem;
    font-weight: 700;
    letter-spacing: -.02em;
}
.fv-top a {
    color: #d7e3f4;
    font-size: .82rem;
    text-decoration: none;
    white-space: nowrap;
}
.fv-mourner-banner {
    margin: 0;
    padding: 10px 16px;
    background: #334155;
    color: #f8fafc;
    text-align: center;
    font-size: .86rem;
    font-weight: 700;
}
.fv-person.is-self strong {
    color: #9a3412;
    text-decoration: underline;
    text-underline-offset: 2px;
}
.fv-hero {
    background: #243447;
    padding: 0 12px 0;
}
.fv-hero-art {
    position: relative;
    overflow: hidden;
    border-radius: 14px 14px 0 0;
    background: #ebe3d6;
}
.fv-hero-art svg {
    display: block;
    width: 100%;
    height: auto;
}
.fv-hero-art p {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 14px;
    margin: 0;
    text-align: center;
    color: #5b4a38;
    font-size: .92rem;
    font-weight: 600;
    letter-spacing: .04em;
}
.fv-identity {
    background: #fff;
    text-align: center;
    padding: 22px 18px 18px;
    border-bottom: 1px solid #e8edf3;
}
.fv-portrait {
    margin: 0 0 12px;
}
.fv-portrait img {
    width: 96px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
}
.fv-day {
    margin: 0 0 6px;
    color: #64748b;
    font-size: .9rem;
}
.fv-identity h1 {
    margin: 0;
    font-size: 1.55rem;
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.35;
}
.fv-sub {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px 10px;
    margin: 8px 0 0;
    color: #6b7280;
    font-size: .84rem;
}
.fv-badge {
    display: inline-block;
    margin: 12px 0 0;
    padding: 7px 12px;
    border-radius: 999px;
    background: #f3f4f6;
    color: #4b5563;
    font-size: .82rem;
}
.fv-card {
    background: #fff;
    margin: 10px 12px 0;
    padding: 16px 16px 14px;
    border: 1px solid #e5eaf1;
    border-radius: 14px;
    box-shadow: 0 8px 18px rgba(28, 36, 48, .04);
}
.fv-card h2 {
    margin: 0 0 12px;
    padding: 0 0 8px;
    border-bottom: 2px solid #111827;
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: -.02em;
}
.fv-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px;
}
.fv-section-head h2 {
    margin: 0;
    flex: 1;
}
.fv-text-link {
    color: #2563eb;
    font-size: .82rem;
    text-decoration: none;
    white-space: nowrap;
}
.fv-table {
    margin: 0;
}
.fv-row {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 10px;
    padding: 11px 0;
    border-bottom: 1px solid #eef2f6;
}
.fv-row:last-child { border-bottom: 0; }
.fv-row dt {
    color: #6b7280;
    font-size: .86rem;
    font-weight: 700;
    text-align: center;
    align-self: start;
    padding-top: 2px;
}
.fv-row dd {
    margin: 0;
    color: #111827;
    font-size: .95rem;
    line-height: 1.55;
    word-break: keep-all;
}
.fv-schedule { margin-top: 4px; }
.fv-person {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-right: 2px;
}
.fv-person strong { font-weight: 700; }
.fv-sep {
    margin-right: 4px;
    color: #9ca3af;
}
.fv-tel {
    display: inline-flex;
    width: 18px;
    height: 18px;
    color: #111827;
}
.fv-tel svg { width: 100%; height: 100%; fill: currentColor; }
.fv-dday {
    display: block;
    margin-top: 4px;
    color: #b45309;
    font-style: normal;
    font-size: .84rem;
    font-weight: 700;
}
.fv-empty {
    margin: 0;
    color: #94a3b8;
    font-size: .9rem;
}
.fv-prose {
    color: #374151;
    font-size: .92rem;
    line-height: 1.7;
    white-space: normal;
}
.fv-prose + .fv-prose { margin-top: 10px; }
.fv-place-name {
    margin: 0 0 4px;
    font-weight: 800;
    font-size: 1rem;
}
.fv-address {
    margin: 0;
    color: #4b5563;
    font-size: .9rem;
    line-height: 1.55;
}
.fv-map-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}
.fv-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 12px;
    border: 1px solid #d7dee8;
    border-radius: 999px;
    background: #f8fafc;
    color: #1f2937;
    font-size: .82rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}
.fv-chip:hover { background: #eef2f7; }
.fv-traffic {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid #eef2f6;
}
.fv-traffic h3 {
    margin: 12px 0 6px;
    font-size: .88rem;
    color: #64748b;
}
.fv-accounts,
.fv-phone-list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.fv-accounts li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #eef2f6;
}
.fv-accounts li:last-child { border-bottom: 0; }
.fv-accounts span,
.fv-accounts em {
    display: block;
    color: #6b7280;
    font-size: .8rem;
    font-style: normal;
}
.fv-accounts strong {
    display: block;
    margin: 2px 0;
    font-size: .95rem;
}
.fv-phone-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #eef2f6;
}
.fv-phone-list a {
    color: #1d4ed8;
    font-weight: 700;
    text-decoration: none;
}
.fv-share-text {
    width: 100%;
    min-height: 160px;
    border: 1px solid #dbe3ee;
    border-radius: 10px;
    padding: 12px;
    background: #f8fafc;
    color: #1f2937;
    resize: vertical;
    font-size: .9rem;
    line-height: 1.55;
}
.fv-share-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}
.fv-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 14px;
    border: 1px solid #d1d9e4;
    border-radius: 10px;
    background: #fff;
    color: #1f2937;
    font-size: .9rem;
    font-weight: 700;
    cursor: pointer;
}
.fv-btn-primary {
    border-color: #243447;
    background: #243447;
    color: #fff;
}
.fv-foot {
    margin: 18px 12px 0;
    text-align: center;
    color: #94a3b8;
    font-size: .78rem;
}
.fv-dock {
    position: fixed;
    left: 50%;
    bottom: 0;
    z-index: 30;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    width: min(480px, 100%);
    transform: translateX(-50%);
    background: #fff;
    border-top: 1px solid #dbe3ee;
    box-shadow: 0 -8px 24px rgba(15, 23, 42, .08);
}
.fv-dock a,
.fv-dock button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 64px;
    padding: 8px 4px;
    border: 0;
    border-right: 1px solid #eef2f6;
    background: #fff;
    color: #334155;
    text-decoration: none;
    font-size: .72rem;
    font-weight: 700;
    cursor: pointer;
}
.fv-dock a:last-child,
.fv-dock button:last-child { border-right: 0; }
.fv-dock svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}
.fv-dock .is-accent {
    background: #fff8e8;
    color: #92400e;
}
.fv-dock .is-share {
    background: #243447;
    color: #fff;
}
@media print {
    .fv-dock { display: none !important; }
    .area-public main.wrap { padding-bottom: 0; }
}

@media (max-width: 1400px) {
    .obit-form { padding: 14px; }
    .obit-panel { padding: 14px; }
    .obit-deceased .field > span:first-child,
    .obit-info .field > span:first-child,
    .obit-mobile .field > span:first-child,
    .area-admin .obit-deceased .field > span:first-child,
    .area-admin .obit-info .field > span:first-child,
    .area-admin .obit-mobile .field > span:first-child {
        min-width: 3.8rem;
        max-width: 5.2rem;
        font-size: .74rem;
        padding: 6px;
    }
    .obit-work .field {
        grid-template-columns: 64px minmax(0, 1fr);
    }
    .obit-room-row {
        grid-template-columns: 48px minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr) auto;
    }
    .obit-deceased .field-combo select,
    .obit-info .field-combo select {
        flex: 0 0 84px;
    }
}
@media (max-width: 1200px) {
    .form-grid,
    .area-admin .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .form-grid .span-2 { grid-column: span 2; }
    .admin-body,
    .hall-body { margin-left: 200px; }
    .admin-side,
    .hall-side { width: 200px; }
}
@media (max-width: 1100px) {
    .obit-split { grid-template-columns: 1fr; }
    .obit-col-right {
        position: static;
        max-height: none;
        overflow: visible;
    }
    .obit-portrait {
        display: block;
        width: fit-content;
        max-width: 100%;
    }
    .obit-portrait .portrait-actions {
        margin-top: 12px;
    }
}
@media (max-width: 900px) {
    .form-grid,
    .area-admin .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .form-grid .span-2 { grid-column: span 2; }
    .obit-mourners .mourner-list-head,
    .obit-mourners .mourner-group {
        grid-template-columns: 28px 1fr 64px;
    }
    .obit-mourners .mourner-list-head .col-names,
    .obit-mourners .name-inbox {
        grid-column: 1 / -1;
    }
    .obit-mourners .mourner-group .name-inbox {
        grid-column: 2 / 3;
    }
    .obit-room-row {
        grid-template-columns: 48px 1fr;
    }
    .obit-room-row .remove-obit-room {
        grid-column: 2;
        justify-self: start;
    }
}
@media (max-width: 800px) {
    .split, .stats, .floor-panels { grid-template-columns: 1fr; }
    .floor-table th.manage-col,
    .floor-table td.manage-col { width: auto; }
    .manage-actions { flex-wrap: wrap; justify-content: flex-start; }
    .mourner { grid-template-columns: 1fr 1fr; }
    .page-head { align-items: flex-start; flex-direction: column; }
    .filters input, .filters select { width: 100%; }
    .area-admin .field { grid-template-columns: 92px minmax(0, 1fr); }
    .area-admin .card.form .checks,
    .area-admin .card.form .actions { margin-left: 0; }
    .place-form .field { grid-template-columns: 92px minmax(0, 1fr); }
    .place-actions { justify-content: stretch; }
    .place-actions .btn { width: 100%; }
    .admin-side,
    .hall-side { position: static; width: auto; }
    .admin-body,
    .hall-body { margin-left: 0; }
    .admin-nav,
    .hall-nav { flex-direction: row; overflow-x: auto; }
    .admin-side-foot,
    .hall-side-foot { margin-top: 0; border-top: 0; padding-top: 0; }
    .admin-logo,
    .hall-logo { height: 52px; min-height: 52px; }
    .obit-portrait {
        display: block;
        width: fit-content;
        max-width: 100%;
    }
}
@media (max-width: 600px) {
    .form-grid,
    .area-admin .form-grid,
    .obit-deceased .form-grid,
    .area-admin .obit-deceased .form-grid,
    .obit-deceased .deceased-detail-grid,
    .obit-info .form-grid,
    .area-admin .obit-info .form-grid,
    .obit-info .rite-detail-grid,
    .obit-info .info-schedule-grid,
    .obit-mobile .form-grid,
    .area-admin .obit-mobile .form-grid { grid-template-columns: 1fr; }
    .obit-deceased .field,
    .obit-info .field,
    .obit-mobile .field,
    .area-admin .obit-deceased .field,
    .area-admin .obit-info .field,
    .area-admin .obit-mobile .field,
    .obit-deceased > .field,
    .obit-info > .field,
    .obit-mobile > .field {
        grid-template-columns: 1fr;
        gap: 6px;
    }
    .obit-deceased .field > span:first-child,
    .obit-info .field > span:first-child,
    .obit-mobile .field > span:first-child,
    .area-admin .obit-deceased .field > span:first-child,
    .area-admin .obit-info .field > span:first-child,
    .area-admin .obit-mobile .field > span:first-child,
    .obit-deceased > .field > span:first-child,
    .obit-info > .field > span:first-child,
    .obit-mobile > .field > span:first-child {
        justify-content: flex-start;
        width: auto;
        max-width: none;
        min-height: 0;
        padding: 0;
        background: transparent;
        font-weight: 600;
    }
    .form-grid .span-2 { grid-column: 1 / -1; }
    .mourner { grid-template-columns: 1fr; }
    .obit-mourners .mourner-list-head { display: none; }
    .obit-mourners .mourner-group {
        grid-template-columns: 28px 1fr auto;
        gap: 6px;
    }
    .obit-mourners .mourner-relation-fields,
    .obit-mourners .name-inbox {
        grid-column: 2 / 3;
    }
    .obit-mourners .mourner-relation-fields {
        grid-template-columns: 1fr;
    }
    .obit-work .field {
        grid-template-columns: 1fr;
    }
    .obit-work .field > span:first-child {
        justify-content: flex-start;
        min-height: 0;
        width: auto;
        background: transparent;
        padding: 0;
    }
    .area-admin .field { grid-template-columns: 1fr; }
    .area-admin .field > span:first-child { justify-content: flex-start; min-height: 0; }
}
@media print {
    .noprint, .topbar, .admin-side, .admin-top, .hall-side, .hall-top, .toast-stack { display: none !important; }
    .admin-body,
    .hall-body { margin-left: 0; }
    .area-public { background: #fff; }
    .fv-card { box-shadow: none; }
}
.inline-form { display: inline-flex; margin-left: 8px; vertical-align: middle; }
.notice-brief { list-style: none; margin: 0; padding: 0; }
.notice-brief li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.notice-brief span { color: var(--muted); white-space: nowrap; }
.layer-pop {
    position: fixed;
    inset: 0;
    z-index: 70;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, .45);
}
.layer-pop[hidden] { display: none; }
.layer-pop-box {
    width: min(480px, 100%);
    max-height: min(80vh, 680px);
    overflow: auto;
    background: #fff;
    border-radius: 12px;
    padding: 20px;
}
.layer-pop-item + .layer-pop-item { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.layer-pop-item h2 { margin: 0 0 8px; font-size: 1.2rem; }

.inline-add { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.inline-add input { min-width: 220px; flex: 1; }
.option-list-card { overflow: hidden; }
.option-list-table { width: 100%; }
.option-list-table .option-row-cell {
    padding: 0;
    border-bottom: 1px solid var(--line);
}
.option-edit-row {
    display: grid;
    grid-template-columns: 22px minmax(140px, 1fr) 110px auto;
    gap: 10px;
    align-items: center;
    padding: 10px 12px;
}
.option-edit-row .drag-handle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 36px;
    margin: 0;
    color: #94a3b8;
    letter-spacing: -1px;
    cursor: grab;
    user-select: none;
    touch-action: none;
}
.option-edit-row .drag-handle:active { cursor: grabbing; }
.option-row-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    white-space: nowrap;
}
.option-list-table tr[data-option-id].is-dragging { opacity: .45; }
.option-list-table tr[data-option-id].drag-over { background: #eef3fb; }
.option-list-table tr[data-option-id] { cursor: default; }

.switch {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
}
.switch input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    pointer-events: none;
}
.switch-ui {
    position: relative;
    flex: none;
    width: 36px;
    height: 20px;
    border-radius: 999px;
    background: #cbd5e1;
    border: 1px solid #b6c0cc;
    transition: background .15s ease, border-color .15s ease;
}
.switch-ui::after {
    content: "";
    position: absolute;
    top: 1px;
    left: 1px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .18);
    transition: transform .15s ease;
}
.switch input:checked + .switch-ui {
    background: #1f3f61;
    border-color: #1f3f61;
}
.switch input:checked + .switch-ui::after {
    transform: translateX(16px);
}
.switch input:focus-visible + .switch-ui {
    outline: 2px solid #93c5fd;
    outline-offset: 2px;
}
.switch-text {
    color: #475569;
    font-size: .86rem;
    font-weight: 600;
}
@media (max-width: 720px) {
    .option-edit-row {
        grid-template-columns: 22px minmax(0, 1fr);
    }
    .option-edit-row .switch,
    .option-edit-row .option-row-actions {
        grid-column: 2 / -1;
        justify-self: start;
    }
    .option-edit-row .option-row-actions { justify-self: stretch; }
}

.wreath-list-table .wreath-thumb {
    width: 56px;
    height: 56px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    display: block;
    background: #f8fafc;
}
.wreath-list-table .wreath-thumb.is-empty {
    background:
        linear-gradient(135deg, #f8fafc 25%, #e2e8f0 25%, #e2e8f0 50%, #f8fafc 50%, #f8fafc 75%, #e2e8f0 75%);
    background-size: 12px 12px;
}
.wreath-summary {
    margin-top: 4px;
    font-size: .82rem;
}
/* td에 flex를 주면 행 높이보다 셀 border가 짧아져 이중 라인으로 보임 */
.wreath-list-table td.option-row-actions {
    display: table-cell;
    vertical-align: middle;
    text-align: right;
    white-space: nowrap;
}
.wreath-list-table td.option-row-actions > .btn,
.wreath-list-table td.option-row-actions > .inline-form {
    display: inline-flex;
    vertical-align: middle;
    margin-left: 8px;
}
.wreath-list-table td.option-row-actions > .btn:first-child,
.wreath-list-table td.option-row-actions > .inline-form:first-child {
    margin-left: 0;
}
.row-actions {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.row-actions .inline-form {
    display: inline-flex;
}
.wreath-info-block h2 {
    margin: 0 0 16px;
    font-size: 1.05rem;
}
.area-admin .wreath-images-field {
    align-items: start;
}
.area-admin .wreath-images-field > span:first-child {
    align-self: start;
}
.wreath-images-panel {
    min-width: 0;
}
.wreath-images-tip {
    margin: 10px 0 0;
    font-size: .84rem;
    line-height: 1.45;
}
.wreath-image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 12px;
    margin: 0 0 14px;
    min-height: 148px;
}
.wreath-image-grid.is-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
    background: #f8fafc;
}
.wreath-image-empty {
    color: #94a3b8;
    font-size: .88rem;
    font-weight: 600;
}
.wreath-image-item {
    display: flex;
    flex-direction: column;
    margin: 0;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 4px 12px rgba(15, 23, 42, .04);
}
.wreath-image-item.is-primary {
    border-color: #111;
    box-shadow: 0 0 0 2px rgba(17, 17, 17, .14);
}
.wreath-image-item.is-removed {
    opacity: .42;
}
.wreath-image-item.is-dragging {
    opacity: .55;
}
.wreath-image-item.drag-over {
    outline: 2px dashed #111;
    outline-offset: -2px;
}
.wreath-image-thumb {
    position: relative;
    background: #eef2f7;
}
.wreath-drag-handle {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: rgba(17, 17, 17, .72);
    color: #fff;
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: -.06em;
    cursor: grab;
    user-select: none;
    touch-action: none;
}
.wreath-drag-handle:active {
    cursor: grabbing;
}
.wreath-image-thumb img {
    display: block;
    width: 100%;
    height: 128px;
    object-fit: cover;
}
.wreath-images-field .wreath-primary-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 3px 8px;
    border-radius: 999px;
    background: #111;
    color: #fff;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .02em;
}
.wreath-image-actions {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0;
    border-top: 1px solid #eef2f7;
}
.wreath-primary,
.wreath-remove,
.wreath-staged-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 0;
    min-height: 34px;
    padding: 0 10px;
    border: 0;
    background: #fff;
    font-size: .78rem;
    font-weight: 700;
    cursor: pointer;
}
.wreath-primary {
    color: #334155;
    justify-content: flex-start;
}
.wreath-primary input[type="radio"] {
    width: 14px;
    height: 14px;
    margin: 0;
    accent-color: #111;
    flex: none;
}
.wreath-remove,
.wreath-staged-remove {
    color: #b91c1c;
    border-left: 1px solid #eef2f7;
}
.wreath-image-upload {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding-top: 2px;
}
.wreath-image-upload .btn.is-disabled {
    opacity: .45;
    pointer-events: none;
}
.wreath-active-field {
    align-items: center;
}
.wreath-active-toggle {
    display: inline-flex;
    align-items: stretch;
    width: fit-content;
    max-width: 100%;
    min-height: 40px;
    padding: 3px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: #f3f4f6;
    gap: 2px;
}
.wreath-active-choice {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    min-width: 88px;
    padding: 0 14px;
    border-radius: 8px;
    cursor: pointer;
    color: #6b7280;
    font-size: .86rem;
    font-weight: 700;
    line-height: 1;
    user-select: none;
}
.wreath-active-choice input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.wreath-active-choice.is-on,
.wreath-active-choice:has(input:checked) {
    background: #111;
    color: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .22);
}
.wreath-active-field .wreath-active-choice.is-on span,
.wreath-active-field .wreath-active-choice:has(input:checked) span {
    color: #fff;
}
