/* ===== The three looks (chosen on the Account page): harbour (the default, in app.css), ledger, sandstone ===== */
.looks { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; }
.look { display: flex; flex-direction: column; gap: 6px; border: 2px solid var(--line); border-radius: 12px; padding: 10px; cursor: pointer; font-weight: 400; margin: 0; position: relative; }
.look:has(input:checked) { border-color: var(--accent); } .look input { position: absolute; opacity: 0; } .look-name { font-weight: 600; }
.look:has(input:focus-visible) { outline: 3px solid var(--info); }
/* the little pictures: drawn in each look's own colours, whatever look you are using now */
.pv { display: grid; height: 96px; border-radius: 8px; overflow: hidden; gap: 4px; padding: 6px; border: 1px solid #0002; }
.pv i { display: block; border-radius: 3px; }
.pv-harbour { background: #f6f7f9; grid-template-columns: 1fr 1fr; grid-template-rows: 14px 1fr 10px 10px; }
.pv-harbour .pv-nav { grid-column: 1 / 3; background: #fff; border-bottom: 3px solid #1f6f5c; } .pv-harbour .pv-card { background: #fff; border: 1px solid #dde; }
.pv-harbour .pv-row { grid-column: 1 / 3; background: #1f6f5c33; }
.pv-ledger { background: #fff; grid-template-columns: 1fr 1fr; grid-template-rows: 9px 1fr 7px 7px; gap: 2px; }
.pv-ledger .pv-nav { grid-column: 1 / 3; background: #1f4e8c; border-radius: 0; } .pv-ledger .pv-card { background: #eef1f6; border-radius: 0; border: 1px solid #b8c2d3; }
.pv-ledger .pv-row { grid-column: 1 / 3; background: #dfe5ef; border-radius: 0; }
.pv-sandstone { background: #fbf5ec; grid-template-columns: 22px 1fr 1fr; grid-template-rows: 1fr 1fr 12px 12px; }
.pv-sandstone .pv-nav { grid-row: 1 / 5; background: #b5532f; border-radius: 6px; } .pv-sandstone .pv-card { background: #fffdf9; border: 1px solid #eadfce; border-radius: 8px; }
.pv-sandstone .pv-row { grid-column: 2 / 4; background: #b5532f33; border-radius: 6px; }

/* Ledger: compact and spreadsheet-like */
html[data-theme="ledger"] { --bg: #f1f3f7; --card: #fff; --ink: #14181f; --muted: #5b6575; --line: #c3ccdb; --accent: #1f4e8c; --accent-ink: #fff; }
html[data-theme="ledger"] body { font-size: 14px; line-height: 1.35; }
html[data-theme="ledger"] main { max-width: 1180px; padding-top: 14px; }
html[data-theme="ledger"] .top { padding: 4px 12px; gap: 6px 14px; background: #1f4e8c; border-bottom: 0; }
html[data-theme="ledger"] .top .brand, html[data-theme="ledger"] .top nav a, html[data-theme="ledger"] .who, html[data-theme="ledger"] .who .tenant, html[data-theme="ledger"] .top button.link { color: #fff; }
html[data-theme="ledger"] .top .logo { background: #fff; color: #1f4e8c; border-radius: 3px; width: 22px; height: 22px; }
html[data-theme="ledger"] .top nav a { padding: 3px 9px; border-radius: 0; } html[data-theme="ledger"] .top nav a[aria-current="page"] { background: #ffffff26; }
html[data-theme="ledger"] .panel, html[data-theme="ledger"] .look, html[data-theme="ledger"] input, html[data-theme="ledger"] select, html[data-theme="ledger"] button, html[data-theme="ledger"] .btn, html[data-theme="ledger"] .flash { border-radius: 0; }
html[data-theme="ledger"] .panel { padding: 10px 12px; margin-bottom: 10px; border-color: var(--line); }
html[data-theme="ledger"] h1 { font-size: 1.25rem; margin-bottom: 10px; } html[data-theme="ledger"] h2 { font-size: 1rem; }
html[data-theme="ledger"] input, html[data-theme="ledger"] select { padding: 4px 6px; } html[data-theme="ledger"] button, html[data-theme="ledger"] .btn { padding: 4px 12px; }
html[data-theme="ledger"] label { margin: 8px 0 2px; }
html[data-theme="ledger"] th, html[data-theme="ledger"] td { padding: 3px 7px; border: 1px solid var(--line); }
html[data-theme="ledger"] th { background: #e6ebf3; font-weight: 600; } html[data-theme="ledger"] table.statement td, html[data-theme="ledger"] table.statement th { padding: 3px 7px; }
html[data-theme="ledger"] .num { font-family: ui-monospace, Consolas, monospace; font-size: .95em; }
html[data-theme="ledger"] .env { border-radius: 0; }

/* Sandstone: warm, roomy, menu down the left */
html[data-theme="sandstone"] { --bg: #fbf5ec; --card: #fffdf9; --ink: #3b2f27; --muted: #7d6c5f; --line: #eadfce; --accent: #b5532f; --accent-ink: #fff; }
html[data-theme="sandstone"] body { font-size: 17px; line-height: 1.55; }
html[data-theme="sandstone"] .panel, html[data-theme="sandstone"] .look { border-radius: 18px; padding: 20px; box-shadow: 0 1px 2px #3b2f2714; }
html[data-theme="sandstone"] input, html[data-theme="sandstone"] select { border-radius: 12px; padding: 11px 13px; }
html[data-theme="sandstone"] button, html[data-theme="sandstone"] .btn { border-radius: 999px; padding: 11px 22px; }
html[data-theme="sandstone"] .flash { border-radius: 14px; }
html[data-theme="sandstone"] main { max-width: 900px; padding-top: 32px; }
html[data-theme="sandstone"] body.app { display: grid; grid-template-columns: 250px minmax(0, 1fr); align-items: start; }
html[data-theme="sandstone"] body.app > .top { position: sticky; top: 0; height: 100vh; flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 14px;
  padding: 22px 16px; background: #f5ead9; border-bottom: 0; border-right: 1px solid var(--line); overflow-y: auto; }
html[data-theme="sandstone"] .top nav { flex-direction: column; gap: 2px; flex: 0 0 auto; }
html[data-theme="sandstone"] .top nav a { padding: 10px 14px; border-radius: 12px; } html[data-theme="sandstone"] .top nav a[aria-current="page"] { background: #fffdf9; box-shadow: 0 1px 2px #3b2f2714; }
html[data-theme="sandstone"] .who { margin: auto 0 0; flex-direction: column; align-items: flex-start; gap: 6px; }
@media (max-width: 800px) {
  html[data-theme="sandstone"] body.app { display: block; }
  html[data-theme="sandstone"] body.app > .top { position: static; height: auto; flex-direction: row; flex-wrap: wrap; border-right: 0; border-bottom: 1px solid var(--line); padding: 10px 14px; }
  html[data-theme="sandstone"] .top nav { flex-direction: row; flex-wrap: wrap; } html[data-theme="sandstone"] .who { margin: 0; flex-direction: row; align-items: center; }
}

/* dark versions follow the device, as in the default look */
@media (prefers-color-scheme: dark) {
  html[data-theme="ledger"] { --bg: #12161d; --card: #1a2029; --ink: #e6ebf3; --muted: #94a1b5; --line: #323d4f; --accent: #6aa5ff; --accent-ink: #0b1220; }
  html[data-theme="ledger"] .top { background: #1d3557; } html[data-theme="ledger"] th { background: #232c3a; }
  html[data-theme="sandstone"] { --bg: #231c17; --card: #2d241e; --ink: #f1e6d8; --muted: #b6a393; --line: #43362c; --accent: #e08a63; --accent-ink: #231c17; }
  html[data-theme="sandstone"] body.app > .top { background: #2a211b; } html[data-theme="sandstone"] .top nav a[aria-current="page"] { background: #3a2e26; }
}
