/* PLIM church office (admin). Same colours as the public site. */
:root { --blue: #1d2fd6; --blue-600: #1626b4; --blue-deep: #0b1466; --night: #070a2e; --red: #d7191f; --flame: #ff6a00; --gold: #ffb81c;
  --ink: #14173a; --text: #3f4363; --muted: #70749a; --line: #e3e6f3; --bg: #f3f5fb; --card: #fff; --radius: 14px;
  --display: 'Fraunces', Georgia, serif; --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; }
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font: 400 14.5px/1.55 var(--sans); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: var(--blue); text-decoration: none; } a:hover { text-decoration: underline; }
h1, h2, h3 { color: var(--ink); margin: 0; line-height: 1.2; }
p { margin: 0 0 1em; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--muted); } .small { font-size: .86rem; } .mono { font-family: ui-monospace, Consolas, monospace; font-size: .86rem; }
.neg { color: var(--red) !important; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px; }

/* layout */
.side { position: fixed; inset: 0 auto 0 0; width: 244px; background: linear-gradient(180deg, var(--blue-deep), var(--night)); color: #b9c0ee; display: flex; flex-direction: column; overflow-y: auto; z-index: 30; }
.side-brand { display: flex; align-items: center; gap: 12px; padding: 20px 20px 16px; text-decoration: none !important; }
.side-brand img { width: 42px; height: 42px; border-radius: 50%; background: #fff; object-fit: contain; }
.side-brand span { display: flex; flex-direction: column; line-height: 1.15; }
.side-brand strong { font: 600 1.08rem var(--display); color: #fff; } .side-brand em { font-style: normal; font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.side nav { padding: 6px 12px 20px; flex: 1; }
.side h6 { margin: 20px 10px 6px; font-size: .66rem; letter-spacing: .16em; text-transform: uppercase; color: #7d86c6; font-weight: 700; }
.side nav a { display: block; padding: 8px 12px; border-radius: 9px; color: #cdd3f7; font-weight: 500; text-decoration: none; }
.side nav a:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.side nav a.on { background: #fff; color: var(--blue-deep); font-weight: 600; }
.side-foot { padding: 16px 22px; border-top: 1px solid rgba(255, 255, 255, .1); font-size: .86rem; } .side-foot a { color: #cdd3f7; }
.side-toggle { display: none; }
.main { margin-left: 244px; min-height: 100vh; }
.top { display: flex; align-items: center; gap: 16px; padding: 16px 30px; background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.top h1 { font: 600 1.4rem var(--display); flex: 1; }
.who { display: flex; align-items: center; gap: 10px; } .who > span { display: flex; flex-direction: column; text-align: right; line-height: 1.2; margin-right: 6px; }
.who strong { color: var(--ink); } .who em { font-style: normal; font-size: .76rem; color: var(--muted); }
.burger { display: none; width: 40px; height: 40px; padding: 10px 8px; cursor: pointer; } .burger span { display: block; height: 2px; background: var(--ink); margin: 4px 0; border-radius: 2px; }
.content { padding: 26px 30px 60px; max-width: 1400px; }

/* pieces */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; font: 600 .9rem/1 var(--sans); padding: .72em 1.15em; border-radius: 10px; border: 1px solid transparent; cursor: pointer; text-decoration: none !important; white-space: nowrap; transition: background .15s, border-color .15s; }
.btn-primary { background: var(--blue); color: #fff; } .btn-primary:hover { background: var(--blue-600); }
.btn-quiet { background: #fff; border-color: var(--line); color: var(--ink); } .btn-quiet:hover { border-color: #b9bfdf; background: #fafbff; }
.btn-sm { padding: .5em .8em; font-size: .82rem; } .btn-block { width: 100%; padding: .95em; }
.danger { color: var(--red) !important; }
.linkish { background: none; border: 0; padding: 0; font: inherit; color: var(--blue); cursor: pointer; } .linkish:hover { text-decoration: underline; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; margin-bottom: 22px; }
.panel.flush { padding: 0; overflow: hidden; } .panel .pad, .panel.flush > header { padding: 18px 24px; margin: 0; }
.panel > header, .panel header.pad { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.panel h2 { font: 600 1.02rem var(--sans); } .panel header a { font-size: .86rem; font-weight: 600; }
.narrow { max-width: 720px; }
.flash { padding: 12px 16px; border-radius: 10px; margin-bottom: 18px; border: 1px solid; }
.flash-ok { background: #e9f8ee; color: #135c2c; border-color: #bfe8cc; } .flash-error { background: #fdecec; color: #92161a; border-color: #f5c2c4; } .flash-info { background: #eef1ff; color: #1b2a8f; border-color: #cfd6ff; }
.secret { font: 600 1.05rem ui-monospace, Consolas, monospace; background: #fff; padding: 3px 9px; border-radius: 6px; border: 1px solid #bfe8cc; user-select: all; }
.tag { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: .74rem; font-weight: 600; background: #eef0f8; color: #50557c; white-space: nowrap; }
.tag-green, .tag-member { background: #e3f6ea; color: #17693a; } .tag-red { background: #fde8e8; color: #a11a1f; } .tag-gold, .tag-visitor { background: #fff1cf; color: #7a5200; } .tag-regular { background: #e6eaff; color: #1b2a8f; } .tag-inactive { background: #eee; color: #777; }
.toolbar { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar-right { display: flex; gap: 8px; align-items: center; margin-left: auto; flex-wrap: wrap; }
.search { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; }
.search label { display: grid; gap: 3px; font-size: .74rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
input, select, textarea { font: 400 .93rem var(--sans); color: var(--ink); padding: .6em .8em; border: 1px solid #cfd4ea; border-radius: 9px; background: #fff; max-width: 100%; }
input:focus, select:focus, textarea:focus { outline: 0; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(29, 47, 214, .14); }
input[type=search] { min-width: 250px; } input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--blue); padding: 0; }
.tabs { display: flex; gap: 4px; background: #e7eaf6; padding: 4px; border-radius: 11px; } .tabs a { padding: 7px 14px; border-radius: 8px; color: var(--text); font-weight: 600; font-size: .88rem; text-decoration: none; } .tabs a.on { background: #fff; color: var(--blue); box-shadow: 0 1px 3px rgba(0, 0, 0, .1); }

/* tables */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: .72rem; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); padding: 11px 16px; background: #f8f9fd; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 11px 16px; border-bottom: 1px solid #eef0f7; vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; } .table tbody tr:hover { background: #fafbff; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table .actions { text-align: right; white-space: nowrap; } .table .actions > * { margin-left: 12px; } .table .actions form { display: inline; }
.table .empty { text-align: center; padding: 44px 16px; color: var(--muted); }
.table tfoot td { background: #f8f9fd; border-top: 1px solid var(--line); } .table .total td { font-weight: 700; color: var(--ink); }
.table tr.unread td { background: #fffaf0; } .table tr.off td { opacity: .6; } .table .wide { min-width: 200px; }
.thumb { width: 38px; height: 38px; border-radius: 8px; object-fit: cover; } .thumb-lg { width: 96px; height: 96px; }
.person { display: flex; align-items: center; gap: 10px; color: var(--ink); } .person img, .person i { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; flex: none; }
.person i { display: grid; place-items: center; background: #e6eaff; color: var(--blue); font: 700 .72rem var(--sans); font-style: normal; }
.pager { display: flex; justify-content: center; align-items: center; gap: 16px; color: var(--muted); }

/* dashboard */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 22px; }
.stats-tight { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; display: block; color: inherit; text-decoration: none !important; transition: border-color .15s, transform .15s; }
a.stat:hover { border-color: var(--blue); transform: translateY(-2px); }
.stat span { font-size: .74rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.stat strong { display: block; font: 600 1.9rem/1.2 var(--display); color: var(--ink); margin: 6px 0 2px; } .stat em { font-style: normal; font-size: .84rem; color: var(--muted); }
.stat-accent { background: linear-gradient(140deg, var(--blue), var(--blue-deep)); border-color: transparent; } .stat-accent span, .stat-accent em { color: #c3caff; } .stat-accent strong { color: #fff; }
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 22px; align-items: start; } .cols-wide { grid-template-columns: 1.6fr 1fr; }
.bars { display: flex; align-items: flex-end; gap: 12px; height: 200px; padding-top: 22px; }
.bar { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; position: relative; min-width: 0; }
.bar b { width: 100%; max-width: 54px; border-radius: 8px 8px 3px 3px; background: linear-gradient(180deg, var(--gold), var(--flame)); }
.bars-blue .bar b { background: linear-gradient(180deg, #5b6cff, var(--blue)); }
.bar span { font-size: .7rem; color: var(--muted); margin-top: 7px; white-space: nowrap; } .bar em { font-style: normal; font-size: .7rem; font-weight: 700; color: var(--ink); order: -1; margin-bottom: 4px; }
.rows { list-style: none; margin: 0; padding: 0; } .rows li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid #eef0f7; } .rows li:last-child { border: 0; }
.rows li > a, .rows li > span:first-child { display: flex; flex-direction: column; color: var(--ink); min-width: 0; } .rows li span span { font-size: .82rem; color: var(--muted); } .rows .done strong { text-decoration: line-through; color: var(--muted); }
.amt { font-weight: 700; color: var(--ink); white-space: nowrap; font-variant-numeric: tabular-nums; }
.hbar { height: 7px; background: #eef0f7; border-radius: 6px; margin: 3px 0; overflow: hidden; } .hbar b { display: block; height: 100%; background: var(--blue); border-radius: 6px; } .hbar-red b { background: var(--flame); }

/* forms */
.form { display: grid; gap: 16px; } .form label { display: grid; gap: 6px; font-weight: 600; font-size: .86rem; color: var(--ink); }
.form input:not([type=checkbox]):not([type=file]), .form select, .form textarea { width: 100%; } .form small { font-weight: 400; color: var(--muted); }
.form .check, .check { display: flex !important; align-items: center; gap: 9px; font-weight: 500; }
.form-actions { display: flex; gap: 10px; margin-top: 8px; flex-wrap: wrap; }
.form-row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; margin: 14px 0; } .form-row .grow { flex: 1; min-width: 200px; }
.inline { display: inline; } .current { display: flex; align-items: center; gap: 14px; }
.settings .panel { max-width: 860px; } .savebar { position: sticky; bottom: 0; padding: 14px 0; background: linear-gradient(180deg, transparent, var(--bg) 40%); max-width: 860px; margin-bottom: 22px; }
.sub { font: 700 .76rem var(--sans); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin: 26px 0 10px; }
.roles { padding: 0; margin: 0; list-style: none; display: grid; gap: 8px; font-size: .86rem; } .roles strong { display: block; color: var(--ink); }

/* person */
.profile { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; margin-bottom: 22px; }
.profile-head { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; } .profile-head h2 { font: 600 1.6rem var(--display); margin-bottom: 6px; } .profile-head p { margin: 0 0 4px; }
.avatar { width: 78px; height: 78px; border-radius: 50%; object-fit: cover; display: grid; place-items: center; background: linear-gradient(150deg, var(--blue), var(--blue-deep)); color: #fff; font: 600 1.6rem var(--display); flex: none; }
.dl { display: grid; grid-template-columns: 150px 1fr; gap: 9px 16px; margin: 0; } .dl dt { color: var(--muted); } .dl dd { margin: 0; color: var(--ink); font-weight: 500; }
.note { background: #f8f9fd; border-radius: 10px; padding: 14px 16px; margin: 16px 0; white-space: pre-line; } .note p:last-child { margin: 0; }
.big { font: 600 1.7rem var(--display); color: var(--ink); } .big em { display: block; font: 400 .84rem var(--sans); color: var(--muted); }
.timeline { list-style: none; margin: 14px 0 0; padding: 0; } .timeline li { padding: 12px 0 12px 16px; border-left: 2px solid var(--line); margin-left: 6px; position: relative; }
.timeline li::before { content: ''; position: absolute; left: -6px; top: 18px; width: 10px; height: 10px; border-radius: 50%; background: var(--flame); } .timeline p { margin: 6px 0 2px; color: var(--ink); } .timeline em { font-style: normal; font-size: .8rem; color: var(--muted); }

/* care board */
.board { display: grid; grid-template-columns: repeat(4, minmax(230px, 1fr)); gap: 16px; overflow-x: auto; align-items: start; }
.lane { background: #e9ecf8; border-radius: var(--radius); padding: 14px; min-height: 200px; } .lane header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; } .lane h2 { font: 700 .82rem var(--sans); text-transform: uppercase; letter-spacing: .08em; }
.kcard { background: #fff; border-radius: 11px; padding: 14px; margin-bottom: 10px; border: 1px solid var(--line); } .kcard p { margin: 6px 0 10px; }
.kfoot { display: flex; justify-content: space-between; align-items: center; gap: 8px; } .kfoot select { padding: .35em .5em; font-size: .8rem; }

/* check-in */
.filter { width: 100%; margin-bottom: 14px; }
.checklist { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 8px; }
.checklist label { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; } .checklist label:has(input:checked) { background: #eef1ff; border-color: var(--blue); }
.checklist span { flex: 1; color: var(--ink); font-weight: 500; } .checklist em { font-style: normal; font-size: .74rem; color: var(--muted); } .checklist label[hidden] { display: none; }

/* sign-in */
.bare { background: radial-gradient(60% 50% at 50% 110%, rgba(255, 106, 0, .5), transparent 70%), linear-gradient(180deg, #0d1680, var(--night)); min-height: 100vh; }
.auth { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.auth-card { background: #fff; border-radius: 22px; padding: 38px 36px; width: min(420px, 100%); display: grid; gap: 14px; box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .6); text-align: center; }
.auth-card img { margin: 0 auto; border-radius: 50%; } .auth-card h1 { font: 600 1.35rem var(--display); } .auth-card label { display: grid; gap: 6px; text-align: left; font-weight: 600; font-size: .86rem; color: var(--ink); } .auth-card input { width: 100%; padding: .8em .9em; }

/* paper (receipts, statements) */
.paper-head { display: flex; align-items: center; gap: 16px; border-bottom: 2px solid var(--blue); padding-bottom: 16px; margin-bottom: 20px; } .paper-head img { width: 64px; height: 64px; object-fit: contain; } .paper-head h2 { font: 600 1.3rem var(--display); } .paper-head p { margin: 2px 0 0; }
.paper h3 { font: 700 .82rem var(--sans); text-transform: uppercase; letter-spacing: .12em; color: var(--red); margin-bottom: 16px; }

@media (max-width: 1000px) {
  .side { transform: translateX(-100%); transition: transform .2s; } .side-toggle:checked + .side { transform: none; box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .45); }
  .main { margin-left: 0; } .burger { display: block; } .content, .top { padding-left: 16px; padding-right: 16px; }
  .stats { grid-template-columns: 1fr 1fr; } .cols-wide { grid-template-columns: 1fr; } .who > span { display: none; } .dl { grid-template-columns: 1fr; gap: 2px; } .dl dd { margin-bottom: 8px; }
}
@media (max-width: 560px) { .stats { grid-template-columns: 1fr; } input[type=search] { min-width: 0; width: 100%; } .top h1 { font-size: 1.1rem; } }
@media print { .side, .top, .no-print, .flash { display: none !important; } .main { margin: 0; } body { background: #fff; } .panel { border: 0; padding: 0; } .content { padding: 0; } }
