:root {
  --green: #157a67;
  --green-dark: #0f5d50;
  --green-soft: #e7f5ef;
  --blue: #35689d;
  --blue-soft: #eaf1fb;
  --orange: #c47b27;
  --orange-soft: #fff2df;
  --red: #c9534c;
  --red-soft: #fceceb;
  --navy: #26354a;
  --ink: #17241f;
  --muted: #74827c;
  --line: #e3ebe7;
  --surface: #ffffff;
  --background: #f4f7f5;
  --shadow: 0 18px 44px rgba(25, 58, 48, .08);
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--background); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif; padding-bottom: 84px; }
button, input, select { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
h1, h2, p { margin: 0; }
h1 { font-size: 34px; line-height: 1.15; letter-spacing: .01em; }
h2 { font-size: 18px; line-height: 1.3; }
.muted, .page-subtitle, .panel-note { color: var(--muted); font-size: 13px; }
.eyebrow { display: block; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }

.login-screen { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: radial-gradient(circle at 10% 10%, #e0f3ea 0, transparent 32%), var(--background); }
.login-shell { width: min(430px, 100%); padding: 36px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 850; letter-spacing: .02em; white-space: nowrap; }
.brand-large { justify-content: center; font-size: 24px; }
.version-badge { padding: 4px 7px; color: var(--green-dark); background: var(--green-soft); border-radius: 999px; font-size: 10px; font-weight: 800; }
.login-kicker { margin: 14px 0 28px; color: var(--muted); text-align: center; font-size: 13px; }
.setup-shell { border-top: 4px solid var(--green); }
.login-form label, .modal label { display: block; margin-bottom: 15px; color: var(--muted); font-size: 12px; font-weight: 750; }
.login-switch { display: flex; justify-content: center; align-items: center; gap: 5px; margin-top: 16px; color: var(--muted); font-size: 12px; }
.login-switch .text-button { font-size: 12px; }
.register-shell { border-top: 4px solid var(--blue); }
input, select { width: 100%; min-height: 42px; margin-top: 7px; padding: 0 12px; color: var(--ink); background: var(--surface); border: 1px solid #d5e2dc; border-radius: 6px; outline: none; }
input:focus, select:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgba(21, 122, 103, .11); }
.form-error { min-height: 20px; margin-top: 12px; color: var(--red); text-align: center; font-size: 12px; }
.login-footnote { margin-top: 24px; padding-top: 15px; color: var(--muted); border-top: 1px solid var(--line); font-size: 12px; line-height: 1.7; text-align: center; }

.topbar { position: sticky; top: 0; z-index: 10; height: 68px; display: flex; align-items: center; justify-content: space-between; padding: 0 max(20px, calc((100vw - 1160px) / 2)); background: rgba(255, 255, 255, .96); border-bottom: 1px solid var(--line); backdrop-filter: blur(12px); }
.account-tools { display: flex; align-items: center; gap: 10px; }
.child-select { width: auto; max-width: 155px; min-height: 35px; margin: 0; color: var(--green-dark); background: var(--green-soft); border-color: #b7daca; }
.account-label { font-size: 12px; font-weight: 750; white-space: nowrap; }
.connection-state { color: var(--muted); font-size: 11px; }
.avatar { display: block; flex: 0 0 auto; object-fit: cover; border-radius: 50%; }
.avatar-top { width: 30px; height: 30px; }
.avatar-hero { width: 74px; height: 74px; border: 4px solid rgba(255,255,255,.65); box-shadow: 0 8px 22px rgba(0,0,0,.16); }
.avatar-small { width: 38px; height: 38px; }
.avatar-table { width: 30px; height: 30px; }

.app-shell { width: min(1160px, calc(100% - 36px)); margin: 32px auto; }
.page { display: none; }
.page.active { display: block; animation: page-in .18s ease-out; }
@keyframes page-in { from { opacity: .2; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.page-heading { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 23px; }
.home-heading { align-items: center; }
.date-chip { padding: 8px 11px; color: var(--green-dark); background: var(--green-soft); border: 1px solid #c7e3d6; border-radius: 6px; font-size: 12px; font-weight: 750; white-space: nowrap; }

.hero-panel { display: grid; grid-template-columns: 1.45fr .62fr 1.18fr; gap: 22px; align-items: center; min-height: 210px; margin-bottom: 18px; padding: 26px; color: white; background: linear-gradient(135deg, #157a67, #165c62); border-radius: 12px; box-shadow: var(--shadow); }
.overview-rpg-banner { color: #f7f4df; background: linear-gradient(120deg, #1b2f46, #3e315e 58%, #754b3a); border: 1px solid #665274; box-shadow: 0 18px 40px rgba(36, 29, 63, .18); }
.overview-rpg-banner .hero-identity { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.16); }
.overview-rpg-banner .hero-balance, .overview-rpg-banner .hero-adventure { border-color: rgba(255,255,255,.2); }
.hero-identity { min-width: 0; display: grid; grid-template-columns: minmax(0, .86fr) minmax(0, 1.14fr); gap: 20px; align-items: center; padding: 18px; background: rgba(5, 79, 78, .34); border: 1px solid rgba(255,255,255,.16); border-radius: 12px; }
.hero-profile { display: flex; align-items: center; gap: 15px; min-width: 0; }
.hero-profile h2 { margin-top: 5px; font-size: 24px; }
.hero-profile .muted { margin-top: 5px; color: rgba(255,255,255,.72); }
.hero-profile .eyebrow { color: rgba(255,255,255,.68); }
.hero-balance { padding-left: 22px; border-left: 1px solid rgba(255,255,255,.22); }
.hero-balance span, .hero-balance small { display: block; color: rgba(255,255,255,.75); font-size: 12px; }
.hero-balance strong { display: inline-block; margin: 8px 7px 2px 0; font-size: 58px; line-height: .95; }
.hero-adventure { min-width: 0; padding-left: 20px; border-left: 1px solid rgba(255,255,255,.22); }
.hero-adventure-heading, .hero-level-line { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.hero-adventure .eyebrow { color: rgba(255,255,255,.68); }
.hero-level-chip { display: inline-flex; align-items: baseline; gap: 4px; padding: 6px 9px; color: #fff4c7; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25); border-radius: 8px; font-size: 10px; font-weight: 850; }
.hero-level-chip strong { font-size: 18px; }
.hero-level-line { margin-top: 17px; }
.hero-level-line strong { overflow: hidden; color: #fff; text-overflow: ellipsis; white-space: nowrap; font-size: 17px; }
.hero-level-line span { flex: 0 0 auto; color: rgba(255,255,255,.72); font-size: 11px; font-weight: 750; }
.hero-adventure .xp-track { margin-top: 9px; background: rgba(255,255,255,.15); }
.hero-adventure .xp-track i { background: linear-gradient(90deg, #71d7bb, #f8d77a); }
.hero-adventure-mode { min-height: 18px; margin-top: 8px; color: rgba(255,255,255,.68); font-size: 11px; line-height: 1.5; }
.hero-adventure-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-top: 13px; }
.hero-adventure-stats div { padding: 9px 10px; background: rgba(255,255,255,.09); border-radius: 8px; }
.hero-adventure-stats span, .hero-adventure-stats strong { display: block; }
.hero-adventure-stats span { color: rgba(255,255,255,.62); font-size: 10px; }
.hero-adventure-stats strong { margin-top: 5px; color: #f8d77a; font-size: 21px; }
.hero-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.hero-actions .command-wide { grid-column: span 2; }
.command-button { min-height: 78px; display: flex; align-items: center; gap: 9px; padding: 12px; text-align: left; border-color: transparent; }
.command-button small { display: block; margin-top: 5px; color: rgba(255,255,255,.68); font-size: 10px; font-weight: 500; }
.button-icon { font-size: 22px; line-height: 1; }

.summary-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(148px, 1fr)); gap: 10px; margin-bottom: 18px; }
.metric-card { min-height: 92px; padding: 15px 16px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--green); border-radius: 7px; box-shadow: 0 5px 18px rgba(20, 49, 40, .04); }
.metric-card span, .metric-card small { display: block; color: var(--muted); font-size: 11px; }
.metric-card strong { display: inline-block; margin: 8px 5px 0 0; font-size: 24px; line-height: 1; }
.metric-green { border-left-color: var(--green); }.metric-blue { border-left-color: var(--blue); }.metric-orange { border-left-color: var(--orange); }.metric-red { border-left-color: var(--red); }
.metric-blue strong { color: var(--blue); }.metric-orange strong { color: var(--orange); }.metric-red strong { color: var(--red); }

.content-panel { margin-bottom: 17px; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: 9px; box-shadow: 0 5px 18px rgba(20, 49, 40, .035); }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 17px; }
.text-button { padding: 3px 0; color: var(--green); background: transparent; border: 0; font-size: 12px; font-weight: 800; }
.control-panel { display: flex; align-items: center; justify-content: space-between; gap: 18px; background: #fbfdfb; }
.control-panel .panel-note { margin-top: 7px; }
.button-row, .row-actions { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.table-scroll { width: 100%; overflow-x: auto; }
.management-table { width: 100%; min-width: 690px; border-collapse: collapse; font-size: 12px; }
.management-table th { color: var(--muted); background: #f6f9f7; font-size: 10px; font-weight: 800; white-space: nowrap; }
.management-table th, .management-table td { padding: 12px 13px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.management-table tr:last-child td { border-bottom: 0; }.management-table tbody tr:hover { background: #fbfdfc; }
.table-person, .request-person { display: flex; align-items: center; gap: 9px; min-width: 150px; }
.table-person strong, .request-person strong { display: block; }.table-person small, .request-person span, .request-person em { display: block; margin-top: 3px; color: var(--muted); font-size: 10px; font-style: normal; }
.table-number { font-weight: 850; white-space: nowrap; }.income { color: var(--green); }.expense { color: var(--red); }
.pending-badge { display: inline-grid; place-items: center; min-width: 24px; height: 22px; padding: 0 6px; color: var(--orange); background: var(--orange-soft); border-radius: 999px; font-weight: 850; }
.pending-badge + .pending-badge { margin-left: 5px; }
.pending-badge-task { color: var(--blue); background: var(--blue-soft); }
.request-section-head { display: flex; align-items: center; gap: 8px; margin: 4px 0 2px; }
.request-section-head:not(:first-child) { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.request-section-head h3 { color: var(--muted); font-size: 12px; font-weight: 850; letter-spacing: .06em; }
.request-row-task { background: #f8fbff; border-left: 4px solid var(--blue); }
.status-pill { display: inline-block; padding: 5px 8px; border-radius: 999px; font-size: 10px; font-weight: 800; white-space: nowrap; }.status-pending { color: var(--orange); background: var(--orange-soft); }.status-approved { color: var(--green-dark); background: var(--green-soft); }.status-rejected { color: var(--red); background: var(--red-soft); }
.log-action { font-weight: 800; }.log-action.admin { color: var(--blue); }.log-action.child { color: var(--green-dark); }

.week-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 7px; }.day-item { min-height: 66px; padding: 10px 4px; color: var(--ink); background: #f7faf8; border: 1px solid transparent; border-radius: 6px; }.day-item span, .day-item strong { display: block; }.day-item span { color: var(--muted); font-size: 10px; }.day-item strong { margin-top: 8px; font-size: 15px; }.day-item.selected { border-color: #9acdbb; background: var(--green-soft); }.day-item.today { color: white; background: var(--green); }.day-item.today span { color: rgba(255,255,255,.78); }
.request-preview, .request-list, .item-list, .record-list { display: grid; gap: 8px; }.request-row, .list-row, .record-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 62px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 7px; }.request-person { flex: 1; min-width: 0; }.request-person > div { min-width: 0; }.request-person strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.request-amount, .record-amount { font-weight: 850; white-space: nowrap; }.record-row > div:first-child { flex: 1; min-width: 0; }.record-row span { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.empty-state { padding: 27px 14px; color: var(--muted); border: 1px dashed var(--line); border-radius: 6px; text-align: center; font-size: 12px; }.item-info { min-width: 0; }.item-info strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.item-points { display: block; margin-top: 5px; font-size: 12px; font-weight: 800; }
.feature-form { margin-bottom: 17px; padding: 16px; border-radius: 9px; }.earn-surface { background: var(--green-soft); }.deduct-surface { background: var(--red-soft); }.quick-form { display: grid; grid-template-columns: 1fr 130px auto; gap: 9px; }.quick-form input { margin: 0; background: rgba(255,255,255,.82); }.settings-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 17px; }
.currency-panel { display: flex; align-items: center; justify-content: space-between; gap: 24px; background: #f8fbff; border-left: 4px solid var(--blue); }
.currency-panel .panel-note { margin-top: 7px; }
.currency-form { display: flex; align-items: end; gap: 10px; min-width: min(430px, 100%); }
.currency-form label { flex: 1; color: var(--muted); font-size: 12px; font-weight: 750; }
.currency-form input { margin-top: 7px; }
.cash-exchange-panel { background: #fffaf1; border-left: 4px solid var(--orange); }
.section-illustration { width: 56px; height: 56px; object-fit: contain; }
.cash-exchange-form { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: end; gap: 10px; }
.cash-exchange-form label { color: var(--muted); font-size: 12px; font-weight: 750; }
.cash-exchange-form input { margin-top: 7px; background: rgba(255,255,255,.9); }
.cash-exchange-form output { min-height: 42px; display: grid; place-items: center; padding: 0 14px; color: var(--orange); background: #fff3dc; border: 1px solid #f0d5a7; border-radius: 6px; font-size: 14px; font-weight: 850; white-space: normal; text-align: center; }
.month-calendar { overflow: hidden; border: 1px solid var(--line); border-radius: 7px; }.month-weekdays, .month-days { display: grid; grid-template-columns: repeat(7, 1fr); }.month-weekdays { background: #f6f9f7; }.month-weekdays span { padding: 8px 2px; color: var(--muted); text-align: center; font-size: 10px; }.month-day { min-height: 52px; padding: 7px; border-top: 1px solid var(--line); border-right: 1px solid var(--line); font-size: 11px; }.month-day:nth-child(7n) { border-right: 0; }.month-day span, .month-day strong { display: block; }.month-day strong { margin-top: 5px; color: var(--green); font-size: 10px; }.month-day.today { background: var(--green-soft); }.history-controls { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }

.button { min-height: 38px; padding: 0 14px; color: white; border: 1px solid transparent; border-radius: 6px; font-size: 12px; font-weight: 800; transition: filter .15s, transform .15s; }.button:hover { filter: brightness(.95); }.button:active { transform: translateY(1px); }.button-block { width: 100%; }.button-primary { background: var(--green); }.button-danger { background: var(--red); }.button-dark { background: var(--navy); }.button-quiet { min-height: 34px; padding: 0 10px; color: var(--ink); background: #eff3f1; }.button-outline { color: var(--ink); background: transparent; border-color: #cddbd4; }.button-outline-danger { color: var(--red); background: transparent; border-color: #e4b9b5; }.button-small { min-height: 31px; padding: 0 10px; font-size: 11px; }.icon-button { width: 32px; height: 32px; color: var(--ink); background: #eef3f0; border: 0; border-radius: 6px; font-size: 21px; }

.bottom-nav { position: fixed; right: 0; bottom: 0; left: 0; z-index: 20; display: flex; justify-content: center; gap: 3px; padding: 8px max(10px, calc((100vw - 640px) / 2)); padding-bottom: calc(8px + env(safe-area-inset-bottom)); background: rgba(255,255,255,.97); border-top: 1px solid var(--line); box-shadow: 0 -8px 24px rgba(20, 49, 40, .06); }.nav-button { width: 92px; min-height: 47px; display: grid; place-items: center; color: var(--muted); background: transparent; border: 0; border-radius: 7px; }.nav-button span { font-size: 18px; line-height: 1; }.nav-button small { margin-top: 3px; font-size: 10px; }.nav-button.active { color: var(--green); background: var(--green-soft); font-weight: 800; }
.modal-backdrop { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; padding: 16px; background: rgba(17, 29, 25, .52); }.modal { width: min(430px, 100%); max-height: calc(100vh - 32px); overflow: auto; padding: 24px; background: var(--surface); border-radius: 10px; box-shadow: 0 24px 80px rgba(0,0,0,.2); }.modal-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 22px; }.modal-header h2 { margin-top: 5px; }.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 22px; }.toast { position: fixed; left: 50%; bottom: 96px; z-index: 50; max-width: calc(100% - 32px); padding: 11px 15px; color: white; background: #263831; border-radius: 7px; opacity: 0; pointer-events: none; transform: translate(-50%, 8px); transition: opacity .2s, transform .2s; font-size: 12px; }.toast.show { opacity: 1; transform: translate(-50%, 0); }

.confirm-modal { width: min(460px, 100%); }.confirm-message { margin: -4px 0 0; color: var(--muted); font-size: 14px; line-height: 1.7; }.confirm-actions { margin-top: 26px; }.confirm-actions .button { min-width: 96px; }

.cash-exchange-discount { color: var(--orange); font-weight: 850; }
.announcement-popup { position: fixed; top: 92px; right: 22px; z-index: 60; width: min(420px, calc(100vw - 28px)); padding: 20px 22px; color: var(--ink); background: #fffdf4; border: 1px solid #ebd8ab; border-left: 5px solid #d9ad58; border-radius: 10px; box-shadow: 0 18px 46px rgba(38, 51, 74, .2); animation: announcement-popup-in .2s ease-out; }
.announcement-popup-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.announcement-popup-head .icon-button { flex: 0 0 auto; }
.announcement-popup h2 { margin-top: 7px; font-size: 20px; }
.announcement-popup p { margin-top: 9px; color: var(--muted); font-size: 14px; line-height: 1.7; white-space: pre-wrap; }
.announcement-popup-footer { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 17px; color: var(--muted); font-size: 12px; }
.announcement-popup-footer .button { flex: 0 0 auto; }
@keyframes announcement-popup-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }

@media (max-width: 900px) { .hero-panel { grid-template-columns: 1fr 1fr; }.hero-actions { grid-column: 1 / -1; }.summary-grid { grid-template-columns: repeat(2, 1fr); }.settings-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 680px) { .topbar { height: 60px; padding: 0 13px; }.connection-state, .account-label { display: none; }.app-shell { width: calc(100% - 22px); margin: 21px auto; }.hero-panel { grid-template-columns: 1fr; gap: 17px; padding: 20px; }.hero-balance { padding: 16px 0 0; border-top: 1px solid rgba(255,255,255,.22); border-left: 0; }.hero-actions { grid-template-columns: repeat(2, 1fr); }.hero-actions .command-wide { grid-column: span 2; }.page-heading, .control-panel { align-items: flex-start; flex-direction: column; }.date-chip { align-self: flex-start; }.quick-form { grid-template-columns: 1fr 100px; }.quick-form .button { grid-column: 1 / -1; }.settings-grid { grid-template-columns: 1fr; }.content-panel { padding: 17px; } }
@media (max-width: 680px) { .currency-panel { align-items: stretch; flex-direction: column; gap: 16px; }.currency-form { min-width: 0; }.cash-exchange-form { grid-template-columns: 1fr 1fr; }.cash-exchange-form label { grid-column: 1 / -1; }.cash-exchange-form .button { grid-column: 1 / -1; }.cash-exchange-form output { min-width: 0; } }
@media (max-width: 680px) { .announcement-popup { top: 72px; right: 14px; left: 14px; width: auto; padding: 17px; } }
@media (max-width: 430px) { .login-shell { padding: 26px 20px; }.brand-large { font-size: 21px; }.brand .version-badge { display: none; }.summary-grid { gap: 7px; }.metric-card { min-height: 82px; padding: 12px 10px; }.metric-card strong { font-size: 20px; }.week-grid { gap: 4px; }.day-item { min-height: 58px; padding: 8px 2px; }.day-item strong { font-size: 13px; }.request-row, .list-row, .record-row { gap: 8px; padding: 9px; }.request-amount { font-size: 12px; }.bottom-nav { justify-content: space-between; }.nav-button { width: auto; flex: 1; }.nav-button small { font-size: 9px; } }

/* v0.6.1：桌面端和触屏设备的重点操作放大，提升总览、审核和账号管理的可读性 */
h1 { font-size: 42px; }
h2 { font-size: 21px; }
.page-subtitle, .muted, .panel-note { font-size: 15px; }
.eyebrow { font-size: 11px; }
.topbar { height: 76px; }
.app-shell { margin-top: 38px; margin-bottom: 42px; }
.content-panel { margin-bottom: 22px; padding: 28px; border-radius: 12px; }
.section-heading { margin-bottom: 21px; }
.text-button { font-size: 14px; }
.hero-panel { min-height: 238px; padding: 32px; border-radius: 15px; }
.hero-profile { gap: 19px; }
.hero-profile h2 { font-size: 28px; }
.hero-balance strong { font-size: 68px; }
.hero-actions { gap: 12px; }
.command-button { min-height: 92px; padding: 17px; gap: 13px; border-radius: 10px; font-size: 16px; }
.command-button small { font-size: 12px; }
.button-icon { font-size: 28px; }
.summary-grid { gap: 14px; margin-bottom: 22px; }
.metric-card { min-height: 116px; padding: 20px; border-radius: 10px; }
.metric-card span, .metric-card small { font-size: 13px; }
.metric-card strong { margin-top: 12px; font-size: 31px; }
.management-table { font-size: 14px; }
.management-table th { font-size: 12px; }
.management-table th, .management-table td { padding: 17px 16px; }
.table-person, .request-person { gap: 13px; }
.table-person small, .request-person span, .request-person em { font-size: 12px; }
.avatar-table { width: 40px; height: 40px; }
.pending-badge { min-width: 30px; height: 27px; font-size: 13px; }
.status-pill { padding: 7px 10px; font-size: 12px; }
.week-grid { gap: 10px; }
.day-item { min-height: 86px; padding: 14px 7px; border-radius: 9px; }
.day-item span { font-size: 12px; }
.day-item strong { margin-top: 11px; font-size: 18px; }
.request-preview, .request-list, .item-list, .record-list { gap: 12px; }
.request-row, .list-row, .record-row { gap: 18px; min-height: 78px; padding: 16px 18px; border-radius: 10px; }
.request-person strong, .item-info strong, .record-row strong { font-size: 16px; }
.request-amount, .record-amount { font-size: 17px; }
.record-row span { font-size: 13px; }
.item-points { margin-top: 7px; font-size: 14px; }
.empty-state { padding: 34px 18px; font-size: 14px; }
.feature-form { margin-bottom: 22px; padding: 22px; border-radius: 12px; }
.quick-form { gap: 12px; }
.quick-form input { min-height: 52px; padding: 0 15px; font-size: 15px; }
.button { min-height: 50px; padding: 0 19px; border-radius: 8px; font-size: 14px; }
.button-small { min-height: 42px; padding: 0 14px; font-size: 13px; }
.button-quiet { min-height: 44px; }
.icon-button { width: 42px; height: 42px; font-size: 27px; }
.bottom-nav { gap: 8px; padding-top: 11px; }
.nav-button { width: 108px; min-height: 60px; border-radius: 10px; }
.nav-button span { font-size: 23px; }
.nav-button small { margin-top: 5px; font-size: 12px; }
.modal { padding: 30px; border-radius: 14px; }
.modal label { font-size: 14px; }

@media (max-width: 680px) {
  .topbar { height: 68px; }
  .app-shell { width: calc(100% - 28px); margin-top: 26px; }
  .hero-panel { gap: 22px; padding: 24px; }
  .hero-profile h2 { font-size: 25px; }
  .hero-actions { gap: 10px; }
  .command-button { min-height: 82px; padding: 14px; font-size: 14px; }
  .content-panel { padding: 22px; }
  .quick-form { grid-template-columns: 1fr 125px; }
  .quick-form .button { grid-column: 1 / -1; }
  .management-table th, .management-table td { padding: 15px 14px; }
  .nav-button { width: auto; min-height: 58px; flex: 1; }
}

@media (max-width: 430px) {
  h1 { font-size: 29px; }
  h2 { font-size: 19px; }
  .page-subtitle, .muted, .panel-note { font-size: 14px; }
  .app-shell { width: calc(100% - 20px); }
  .hero-panel { padding: 20px; }
  .metric-card { min-height: 100px; padding: 15px 13px; }
  .metric-card span, .metric-card small { font-size: 12px; }
  .metric-card strong { font-size: 25px; }
  .content-panel { padding: 18px; }
  .section-heading { align-items: flex-start; flex-direction: column; gap: 9px; }
  .request-row, .list-row, .record-row { min-height: 70px; padding: 13px; }
  .request-person strong, .item-info strong, .record-row strong { font-size: 14px; }
  .request-amount, .record-amount { font-size: 15px; }
  .button { min-height: 46px; }
  .button-small { min-height: 40px; }
  .bottom-nav { gap: 2px; }
  .nav-button { min-height: 55px; }
}

/* v0.6.2: no-child state, project illustrations, and multi-device layout */
.login-illustration { display: block; width: 190px; height: 190px; margin: 0 auto 18px; border-radius: 26px; object-fit: contain; box-shadow: 0 10px 24px rgba(25, 58, 48, .12); }
.no-child-panel { display: flex; align-items: center; justify-content: space-between; gap: 24px; border: 1px solid #c7e3d6; background: #f2fbf6; }
.no-child-copy { min-width: 0; }
.no-child-copy h2 { margin: 6px 0; }
.log-heading { align-items: center; }
.log-heading > div { flex: 1; min-width: 0; }
.log-heading .muted { display: block; margin-top: 7px; }
.item-info { display: flex; align-items: center; gap: 14px; min-width: 0; }
.item-info > div:last-child { min-width: 0; }
.item-info strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.project-visual-wrap { width: 56px; height: 56px; display: grid; place-items: center; flex: 0 0 auto; background: #f4faf7; border: 1px solid #d9ebe2; border-radius: 12px; }
.project-visual { width: 48px; height: 48px; object-fit: contain; }
.list-row .row-actions { flex: 0 0 auto; }

@media (min-width: 681px) and (max-width: 980px) {
  .topbar { padding: 0 22px; }
  .app-shell { width: min(920px, calc(100% - 36px)); }
  .hero-panel { grid-template-columns: 1fr 1fr; }
  .hero-actions { grid-column: 1 / -1; }
  .management-table { min-width: 760px; }
  .no-child-panel { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 680px) {
  h1 { font-size: 31px; }
  .hero-balance strong { font-size: 54px; }
  .login-illustration { width: 170px; height: 170px; }
  .no-child-panel { align-items: stretch; flex-direction: column; gap: 16px; }
  .log-heading { align-items: flex-start; flex-direction: row; }
  .item-info { gap: 10px; }
  .project-visual-wrap { width: 48px; height: 48px; border-radius: 10px; }
  .project-visual { width: 41px; height: 41px; }
  .list-row { align-items: center; }
  .list-row .button-small { min-width: 76px; padding: 0 10px; }
}

@media (max-width: 430px) {
  .login-illustration { width: 146px; height: 146px; border-radius: 21px; }
  .log-heading { gap: 5px; }
  .item-info strong { max-width: 150px; }
  .project-visual-wrap { width: 43px; height: 43px; }
  .project-visual { width: 37px; height: 37px; }
}

/* v0.7.0: child branding, project icon picker, and the family command center */
.control-center { margin-bottom: 22px; padding: 26px; color: #fff; background: #1d3b42; border: 1px solid #315a5e; border-radius: 15px; box-shadow: 0 18px 40px rgba(29, 59, 66, .16); }
.control-center-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 21px; }
.control-center h2 { margin-top: 5px; font-size: 25px; }
.control-center .eyebrow, .control-center .panel-note { color: rgba(255,255,255,.68); }
.live-chip { display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; color: #c9f1dd; background: rgba(117, 205, 164, .12); border: 1px solid rgba(157, 229, 193, .28); border-radius: 999px; font-size: 12px; font-weight: 800; white-space: nowrap; }
.live-chip i { width: 8px; height: 8px; background: #79d6a8; border-radius: 50%; box-shadow: 0 0 0 4px rgba(121, 214, 168, .14); }
.control-center-grid { display: grid; grid-template-columns: 1.15fr 1.4fr .95fr; gap: 16px; align-items: stretch; }
.control-center-overview { display: flex; align-items: center; gap: 14px; min-width: 0; padding: 16px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12); border-radius: 11px; }
.control-center-overview img { width: 84px; height: 84px; flex: 0 0 auto; padding: 3px; object-fit: contain; background: rgba(255,255,255,.94); border-radius: 18px; }
.control-center-overview strong, .control-center-overview span { display: block; }
.control-center-overview strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 17px; }
.control-center-overview span { margin-top: 7px; color: rgba(255,255,255,.66); font-size: 12px; line-height: 1.5; }
.control-center-actions { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
.control-center-actions .button { min-height: 54px; justify-content: flex-start; text-align: left; }
.control-center-actions .button-icon { margin-right: 5px; font-size: 24px; }
.control-center-stats { display: grid; grid-template-columns: 1fr; gap: 8px; }
.control-center-stats div { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 14px; background: rgba(255,255,255,.08); border-radius: 9px; }
.control-center-stats span { color: rgba(255,255,255,.68); font-size: 12px; }
.control-center-stats strong { color: #fff; font-size: 23px; }
.icon-picker-field { margin: 8px 0 0; padding: 14px; border: 1px solid var(--line); border-radius: 9px; }
.icon-picker-field legend { padding: 0 5px; color: var(--ink); font-size: 13px; font-weight: 800; }
.icon-picker-field .panel-note { margin-bottom: 12px; font-size: 12px; }
.item-icon-picker { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.icon-choice { min-height: 72px; display: grid; place-items: center; gap: 3px; padding: 6px 3px; color: var(--muted); background: #f7faf8; border: 2px solid transparent; border-radius: 8px; font-size: 10px; }
.icon-choice img { width: 34px; height: 34px; object-fit: contain; }
.icon-choice:hover, .icon-choice.selected { color: var(--green-dark); background: var(--green-soft); border-color: #81c5a9; }
.icon-choice.selected { box-shadow: 0 0 0 2px rgba(21,122,103,.08); }
.icon-search { margin: 0 0 12px; }.icon-group { margin-top: 8px; border: 1px solid var(--line); border-radius: 8px; }.icon-group summary { padding: 10px 12px; color: var(--ink); cursor: pointer; font-size: 12px; font-weight: 800; }.icon-group[open] summary { color: var(--green-dark); background: var(--green-soft); }.icon-group .item-icon-picker { padding: 10px; }.icon-choice .icon-emoji, .project-emoji { display: grid; place-items: center; font-family: "Segoe UI Emoji", "Noto Color Emoji", sans-serif; }.icon-choice .icon-emoji { width: 34px; height: 34px; font-size: 25px; }.project-emoji { width: 48px; height: 48px; font-size: 31px; }.inline-icon-library { grid-column: 1 / -1; margin-top: -4px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; }.inline-icon-library summary { color: var(--green-dark); cursor: pointer; font-size: 12px; font-weight: 800; }.inline-icon-library input { margin-top: 10px; }.inline-icon-library #quest-icon-groups { max-height: 260px; overflow: auto; }
.quest-focus { display: grid; grid-template-columns: auto 1fr auto auto; gap: 15px; align-items: center; margin-bottom: 22px; padding: 21px 24px; color: #fff; background: linear-gradient(120deg, #1b2f46, #5d3e70); border: 1px solid #7a5b8f; border-radius: 14px; box-shadow: 0 14px 32px rgba(55,39,80,.16); }.quest-focus-mark { width: 52px; height: 52px; display: grid; place-items: center; color: #f8d77a; background: rgba(255,255,255,.12); border: 2px solid #d2ad64; border-radius: 16px; font-size: 27px; }.quest-focus-copy { min-width: 0; }.quest-focus-copy .eyebrow { color: rgba(255,255,255,.65); }.quest-focus-copy h2 { overflow: hidden; margin-top: 5px; text-overflow: ellipsis; white-space: nowrap; font-size: 20px; }.quest-focus-copy p { overflow: hidden; margin-top: 5px; color: rgba(255,255,255,.7); text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }.quest-focus-reward { padding-left: 15px; border-left: 1px solid rgba(255,255,255,.2); }.quest-focus-reward strong, .quest-focus-reward span { display: block; }.quest-focus-reward strong { color: #f8d77a; font-size: 18px; }.quest-focus-reward span { margin-top: 5px; color: rgba(255,255,255,.68); font-size: 11px; }.announcement-mark { font-size: 28px; }.announcement-editor { margin-bottom: 15px; padding: 14px; background: #f7faf8; border: 1px solid var(--line); border-radius: 9px; }.announcement-form { display: grid; grid-template-columns: 1fr 1.5fr .8fr auto; gap: 10px; align-items: end; }.announcement-form label { color: var(--muted); font-size: 12px; font-weight: 750; }.announcement-form input, .announcement-form textarea, .announcement-form select { width: 100%; margin-top: 6px; }.announcement-form textarea { resize: vertical; padding: 10px 12px; color: var(--ink); background: #fff; border: 1px solid #d5e2dc; border-radius: 6px; outline: none; }.announcement-actions { display: flex; gap: 7px; }.announcement-list { display: grid; gap: 9px; }.announcement-card { padding: 14px 16px; background: #fffdf4; border: 1px solid #ebd8ab; border-left: 4px solid #d9ad58; border-radius: 8px; }.announcement-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }.announcement-card h3 { font-size: 15px; }.announcement-card p { margin-top: 8px; color: var(--muted); font-size: 13px; line-height: 1.65; white-space: pre-wrap; }.announcement-card small { display: block; margin-top: 8px; color: var(--muted); font-size: 10px; }.announcement-card .row-actions { flex: 0 0 auto; }

.rpg-banner { display: grid; grid-template-columns: auto 1.7fr .7fr .7fr; gap: 18px; align-items: center; margin-bottom: 22px; padding: 22px 26px; color: #f7f4df; background: linear-gradient(120deg, #1b2f46, #3e315e 58%, #754b3a); border: 1px solid #665274; border-radius: 15px; box-shadow: 0 18px 40px rgba(36, 29, 63, .18); }
.rpg-avatar { width: 62px; height: 62px; display: grid; place-items: center; color: #f8d77a; background: linear-gradient(145deg, #263d5b, #5b3d67); border: 2px solid #d2ad64; border-radius: 18px; box-shadow: inset 0 0 0 5px rgba(255,255,255,.08), 0 8px 18px rgba(0,0,0,.2); font-size: 31px; }
.rpg-progress-copy { min-width: 0; }.rpg-progress-copy strong { display: inline-block; margin: 3px 10px 2px 0; font-size: 29px; }.rpg-progress-copy > span:last-of-type { color: rgba(247,244,223,.72); font-size: 12px; }.rpg-banner .eyebrow { color: rgba(247,244,223,.64); }.xp-track { height: 9px; margin-top: 8px; overflow: hidden; background: rgba(255,255,255,.15); border-radius: 99px; }.xp-track i { display: block; width: 0; height: 100%; background: linear-gradient(90deg, #71d7bb, #f8d77a); border-radius: inherit; transition: width .3s ease; }
.rpg-stat { padding-left: 18px; border-left: 1px solid rgba(255,255,255,.18); }.rpg-stat span, .rpg-stat strong { display: block; }.rpg-stat span { color: rgba(247,244,223,.65); font-size: 12px; }.rpg-stat strong { margin-top: 6px; color: #f8d77a; font-size: 27px; }
.quest-publish-panel { border-top: 4px solid #8a5da6; }.quest-rune { color: #c8a5e2; font-size: 32px; }.quest-form { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }.quest-form label { color: var(--muted); font-size: 12px; font-weight: 750; }.quest-form label:first-child, .quest-form label:nth-child(2) { grid-column: span 2; }.quest-form input, .quest-form select, .quest-form textarea { width: 100%; margin-top: 7px; }.quest-form textarea { resize: vertical; padding: 11px 12px; color: var(--ink); background: var(--surface); border: 1px solid #d5e2dc; border-radius: 6px; outline: none; }.quest-form button { align-self: end; min-height: 42px; }
.quest-board { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }.quest-card { position: relative; overflow: hidden; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(20,49,40,.05); }.quest-card::before { position: absolute; top: 0; right: 0; width: 100px; height: 100px; content: ""; background: radial-gradient(circle, rgba(122,91,166,.12), transparent 68%); pointer-events: none; }.quest-card.epic { border-color: #c7a36c; background: linear-gradient(145deg, #fff, #fffaf0); }.quest-card-head, .quest-card-meta, .quest-card-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; }.quest-card-head { align-items: flex-start; }.quest-card-title { display: flex; align-items: center; gap: 12px; min-width: 0; }.quest-card-title img { width: 48px; height: 48px; padding: 7px; background: #f3ecfa; border-radius: 12px; }.quest-card-title h2 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 17px; }.quest-card-title p { margin-top: 5px; color: var(--muted); font-size: 12px; }.quest-rarity { flex: 0 0 auto; padding: 6px 9px; color: #754b3a; background: #fff0c9; border-radius: 99px; font-size: 10px; font-weight: 850; }
.quest-target-badge { padding: 4px 9px; color: var(--blue); background: var(--blue-soft); border-radius: 99px; font-size: 10px; font-weight: 850; }
.quest-card.targeted { border-color: #b7cfe8; }
.quest-card.targeted::before { background: radial-gradient(circle, rgba(53, 104, 157, .14), transparent 68%); }.quest-description { min-height: 42px; margin: 16px 0; color: var(--muted); font-size: 13px; line-height: 1.7; }.quest-card-meta { justify-content: flex-start; flex-wrap: wrap; padding-top: 12px; border-top: 1px solid var(--line); }.quest-reward { color: #a56d21; font-size: 12px; font-weight: 850; }.quest-reward + .quest-reward { color: #7a58a2; }.quest-card-actions { justify-content: flex-end; margin-top: 16px; }.quest-assignees { margin-top: 13px; padding: 10px 12px; color: var(--muted); background: #f7faf8; border-radius: 8px; font-size: 11px; }.quest-assignee { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 5px 0; }.quest-assignee + .quest-assignee { border-top: 1px solid var(--line); }.quest-status { padding: 4px 7px; border-radius: 99px; font-size: 10px; font-weight: 800; }.quest-status-submitted { color: var(--orange); background: var(--orange-soft); }.quest-status-completed { color: var(--green-dark); background: var(--green-soft); }.quest-status-rejected { color: var(--red); background: var(--red-soft); }.quest-status-claimed { color: var(--blue); background: var(--blue-soft); }
.achievement-intro { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; padding: 20px 24px; color: #f7f4df; background: linear-gradient(120deg, #26334a, #3d5664); border-radius: 13px; }.achievement-orbit { width: 56px; height: 56px; display: grid; place-items: center; color: #f8d77a; background: #35475c; border: 2px solid #d2ad64; border-radius: 50%; font-size: 29px; }.achievement-intro strong { font-size: 18px; }.achievement-intro p { margin-top: 5px; color: rgba(247,244,223,.68); font-size: 12px; }.achievement-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }.achievement-card { min-height: 190px; padding: 22px 16px; text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: 13px; box-shadow: 0 8px 24px rgba(20,49,40,.05); }.achievement-card.locked { filter: grayscale(.8); opacity: .72; }.achievement-medal { width: 84px; height: 84px; display: grid; place-items: center; margin: 0 auto 13px; background: linear-gradient(145deg, #fff3b8, #cc8f54); border: 4px solid #f8d77a; border-radius: 27px; box-shadow: inset 0 0 0 4px rgba(255,255,255,.45), 0 9px 15px rgba(157,103,50,.22); }.achievement-medal img { width: 48px; height: 48px; }.achievement-card strong, .achievement-card p, .achievement-card small { display: block; }.achievement-card strong { font-size: 15px; }.achievement-card p { min-height: 34px; margin-top: 6px; color: var(--muted); font-size: 11px; line-height: 1.5; }.achievement-card small { margin-top: 10px; color: var(--green-dark); font-size: 10px; font-weight: 850; }
.achievement-card .achievement-state { margin-top: 10px; }
.achievement-progress { margin-top: 10px; }
.achievement-progress-track { overflow: hidden; height: 7px; background: #eceff0; border-radius: 999px; }
.achievement-progress-track span { display: block; height: 100%; background: linear-gradient(90deg, var(--green), #4aa88f); border-radius: 999px; transition: width .3s ease; }
.achievement-progress small { margin-top: 6px; color: var(--muted); font-size: 10px; font-weight: 800; }
.achievement-card.locked .achievement-progress-track span { background: linear-gradient(90deg, #9aa6a1, #b9c3bf); }
.achievement-tag { display: inline-block; margin-top: 5px; padding: 3px 7px; border-radius: 999px; font-size: 10px; font-weight: 800; }
.achievement-tag.unlocked { color: var(--green-dark); background: var(--green-soft); }

@media (max-width: 900px) { .quest-board { grid-template-columns: 1fr; }.achievement-grid { grid-template-columns: repeat(2, 1fr); }.rpg-banner { grid-template-columns: auto 1fr 1fr; }.rpg-stat:last-child { grid-column: 2; } }
@media (max-width: 680px) { .quest-form { grid-template-columns: 1fr 1fr; }.quest-form label:first-child, .quest-form label:nth-child(2) { grid-column: 1 / -1; }.rpg-banner { grid-template-columns: auto 1fr; gap: 13px; padding: 18px; }.rpg-stat { padding-left: 0; border-left: 0; }.rpg-stat:last-child { grid-column: auto; }.achievement-grid { gap: 10px; }.achievement-card { padding: 17px 10px; }.achievement-medal { width: 68px; height: 68px; border-radius: 22px; }.achievement-medal img { width: 39px; height: 39px; } }
@media (max-width: 900px) { .announcement-form { grid-template-columns: 1fr 1fr; }.announcement-form label:nth-child(2) { grid-column: span 2; }.announcement-actions { justify-content: flex-end; } }
@media (max-width: 680px) { .quest-focus { grid-template-columns: auto 1fr; }.quest-focus-reward { grid-column: 2; padding-left: 0; border-left: 0; }.quest-focus > .button { grid-column: 1 / -1; }.announcement-form { grid-template-columns: 1fr; }.announcement-form label:nth-child(2) { grid-column: auto; }.announcement-actions { justify-content: stretch; }.announcement-actions .button { flex: 1; } }
.quest-card-title .quest-icon { flex: 0 0 auto; width: 48px; height: 48px; padding: 7px; background: #f3ecfa; border-radius: 12px; font-size: 31px; }

@media (max-width: 980px) {
  .control-center-grid { grid-template-columns: 1fr 1fr; }
  .control-center-stats { grid-column: 1 / -1; grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 680px) {
  .control-center { padding: 21px; }
  .control-center-heading { align-items: flex-start; flex-direction: column; }
  .control-center-grid { grid-template-columns: 1fr; }
  .control-center-stats { grid-column: auto; grid-template-columns: repeat(3, 1fr); }
  .control-center-stats div { align-items: flex-start; flex-direction: column; padding: 10px; }
  .control-center-stats strong { font-size: 20px; }
  .item-icon-picker { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 430px) {
  .control-center { padding: 17px; }
  .control-center h2 { font-size: 22px; }
  .control-center-overview img { width: 68px; height: 68px; border-radius: 14px; }
  .control-center-actions .button { padding: 0 11px; font-size: 13px; }
  .item-icon-picker { gap: 5px; }
  .icon-choice { min-height: 64px; }
}

/* v0.7.1: overview adventure progress, broadcasts, and readable command actions */
.control-center-actions .button-outline {
  color: #ffffff;
  background: rgba(255, 255, 255, .14);
  border-color: rgba(255, 255, 255, .58);
  font-size: 15px;
  font-weight: 850;
}
.control-center-actions .button-outline:hover {
  color: #17383a;
  background: #ffffff;
  border-color: #ffffff;
}
.control-center-actions .button {
  min-height: 58px;
}
.home-adventure-panel {
  border-left: 4px solid #8060a7;
  background: #fbf9ff;
}
.home-adventure-grid {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) repeat(2, minmax(120px, .42fr));
  gap: 18px;
  align-items: center;
}
.home-level-badge {
  width: 84px;
  height: 84px;
  display: grid;
  place-items: center;
  align-content: center;
  color: #fff4c7;
  background: linear-gradient(145deg, #253b59, #6a4b77);
  border: 3px solid #dfbf72;
  border-radius: 24px;
  box-shadow: inset 0 0 0 5px rgba(255, 255, 255, .1);
}
.home-level-badge span { font-size: 11px; font-weight: 850; letter-spacing: 1px; }
.home-level-badge strong { margin-top: 1px; font-size: 34px; line-height: 1; }
.home-level-progress { min-width: 0; }
.home-level-line { display: flex; justify-content: space-between; gap: 12px; }
.home-level-line strong { color: var(--ink); font-size: 17px; }
.home-level-line span { color: var(--muted); font-size: 12px; font-weight: 750; white-space: nowrap; }
.home-level-progress .xp-track { background: #e7deef; }
.home-level-progress .xp-track i { background: linear-gradient(90deg, #6c4f9b, #d09b45); }
.home-level-progress p { margin-top: 8px; color: var(--muted); font-size: 12px; }
.home-adventure-stat {
  min-height: 78px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex-direction: column;
  padding-left: 18px;
  border-left: 1px solid #dfd5ea;
}
.home-adventure-stat span { color: var(--muted); font-size: 12px; }
.home-adventure-stat strong { margin-top: 8px; color: #664a8e; font-size: 27px; }
.home-announcement-top { border-left: 4px solid #d9ad58; background: #fffdf4; }
.home-announcement-top .section-heading { margin-bottom: 14px; }
.home-task-panel { border-left: 4px solid var(--green); }
.home-task-panel .section-heading { align-items: flex-start; }
.home-task-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.home-list-tag {
  flex: 0 0 auto;
  padding: 5px 8px;
  color: #7b5d25;
  background: #fff0c9;
  border-radius: 99px;
  font-size: 10px;
  font-weight: 850;
}
.home-announcement-panel .announcement-card { padding: 13px 14px; }
.home-task-list { display: grid; gap: 8px; }
.home-task-row {
  width: 100%;
  min-height: 66px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 11px;
  color: var(--ink);
  background: #fbfdfb;
  border: 1px solid var(--line);
  border-radius: 8px;
  text-align: left;
}
.home-task-row:hover { background: var(--green-soft); border-color: #9acdbb; }
.home-task-icon { width: 42px; height: 42px; display: grid; place-items: center; flex: 0 0 auto; background: #f3ecfa; border-radius: 10px; }
.home-task-visual { width: 34px; height: 34px; object-fit: contain; }
.home-task-copy { min-width: 0; flex: 1; }
.home-task-copy strong, .home-task-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.home-task-copy strong { font-size: 14px; }
.home-task-copy small { margin-top: 5px; color: var(--muted); font-size: 11px; }
.home-task-reward { flex: 0 0 auto; color: #a56d21; font-size: 12px; font-weight: 850; }
.home-task-reward small { display: block; margin-top: 4px; color: var(--muted); font-size: 10px; font-weight: 700; text-align: right; }
.adventure-settings-panel { display: flex; align-items: center; justify-content: space-between; gap: 24px; background: #fbf9ff; border-left: 4px solid #8060a7; }
.adventure-settings-panel .panel-note { max-width: 560px; margin-top: 7px; }
.adventure-level-form { display: flex; align-items: end; gap: 10px; min-width: min(490px, 100%); }
.adventure-level-form label { flex: 1; color: var(--muted); font-size: 12px; font-weight: 750; }
.adventure-level-form input, .adventure-level-form select { margin-top: 7px; }

@media (max-width: 900px) {
  .hero-panel { grid-template-columns: 1fr 1fr; }
  .hero-identity { grid-column: 1 / -1; }
  .hero-balance { grid-column: 1 / -1; padding: 18px 0 0; border-top: 1px solid rgba(255,255,255,.22); border-left: 0; }
  .hero-actions { grid-column: 1 / -1; }
  .home-adventure-grid { grid-template-columns: auto minmax(0, 1fr); }
  .home-adventure-stat { min-height: 62px; border-top: 1px solid #dfd5ea; border-left: 0; padding: 13px 0 0; }
  .home-task-list { grid-template-columns: 1fr; }
  .adventure-settings-panel { align-items: stretch; flex-direction: column; gap: 16px; }
  .adventure-level-form { min-width: 0; }
}
@media (max-width: 680px) {
  .control-center-actions .button-outline { font-size: 14px; }
  .hero-panel { grid-template-columns: 1fr; }
  .hero-identity { grid-column: auto; grid-template-columns: 1fr; gap: 17px; padding: 16px; }
  .hero-balance, .hero-actions { grid-column: auto; }
  .hero-adventure { padding: 17px 0 0; border-top: 1px solid rgba(255,255,255,.22); border-left: 0; }
  .hero-level-line { align-items: flex-start; flex-direction: column; gap: 4px; }
  .hero-adventure-stats strong { font-size: 20px; }
  .adventure-level-form { align-items: stretch; flex-direction: column; }
  .adventure-level-form .button { width: 100%; }
}

/* Keep the base value visible when the child's level changes the actual value. */
.benefit-note,
.quest-reward-note {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}
.quest-reward-note { display: inline; margin-left: 5px; }
#cash-exchange-preview {
  min-height: 24px;
  display: flex;
  align-items: center;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.5;
}

/* v0.7.3: make adventure-level benefits visible above the exchange area. */
.level-benefit-panel {
  color: #f7f4df;
  background: linear-gradient(120deg, #26334a, #3d5664);
  border-color: #506b76;
  box-shadow: 0 16px 34px rgba(38, 51, 74, .14);
}
.level-benefit-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 18px; }
.level-benefit-heading h2 { margin-top: 5px; color: #fff; }
.level-benefit-heading .panel-note { color: rgba(247,244,223,.7); }
.level-benefit-heading .eyebrow { color: rgba(247,244,223,.64); }
.level-benefit-badge { display: grid; place-items: center; min-width: 76px; min-height: 76px; color: #fff4c7; background: rgba(255,255,255,.1); border: 2px solid #d2ad64; border-radius: 20px; font-size: 12px; font-weight: 850; }
.level-benefit-badge strong { display: block; margin-top: 2px; font-size: 31px; line-height: 1; }
.level-benefit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.level-benefit-grid > div { min-height: 94px; padding: 15px; background: rgba(255,255,255,.09); border: 1px solid rgba(255,255,255,.12); border-radius: 10px; }
.level-benefit-grid span, .level-benefit-grid small { display: block; color: rgba(247,244,223,.68); font-size: 11px; }
.level-benefit-grid strong { display: block; margin-top: 9px; color: #f8d77a; font-size: 24px; }
.level-benefit-grid small { margin-top: 7px; font-size: 10px; }
.level-benefit-next strong { font-size: 16px; }

@media (max-width: 680px) {
  .level-benefit-heading { align-items: flex-start; }
  .level-benefit-badge { min-width: 64px; min-height: 64px; }
  .level-benefit-grid { grid-template-columns: 1fr; }
  .level-benefit-grid > div { min-height: 76px; }
}

/* v0.7.2: combine the selected account and family control center. */
.overview-control-panel {
  display: block;
  padding: 26px;
  background: linear-gradient(120deg, #1b2f46, #3e315e 58%, #754b3a);
  border-color: #665274;
}
.overview-control-panel .control-center-heading { margin-bottom: 18px; }
.overview-control-panel .control-center-heading h2 { color: #fff; }
.overview-control-panel .control-center-heading .panel-note { color: rgba(255,255,255,.68); }
.overview-control-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(190px, .62fr) minmax(230px, .78fr);
  gap: 14px;
  align-items: stretch;
}
.overview-control-panel .hero-identity,
.overview-control-panel .hero-balance,
.overview-control-panel .control-center-stats {
  min-width: 0;
  padding: 16px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 11px;
}
.overview-control-panel .hero-identity { grid-template-columns: minmax(180px, .82fr) minmax(0, 1.18fr); gap: 16px; }
.overview-control-panel .hero-balance { display: flex; flex-direction: column; justify-content: center; padding-left: 16px; }
.overview-control-panel .hero-balance span,
.overview-control-panel .hero-balance small { color: rgba(255,255,255,.72); }
.overview-control-panel .hero-balance strong { color: #fff4c7; font-size: 48px; }
.overview-control-panel .control-center-stats { display: grid; grid-template-columns: 1fr; gap: 8px; }
.overview-control-panel .control-center-stats div { background: rgba(255,255,255,.08); }
.overview-control-panel .control-center-actions {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 9px;
  margin-top: 14px;
}
.overview-control-panel .overview-child-actions { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.overview-control-panel .control-center-actions .button { min-height: 58px; justify-content: flex-start; text-align: left; }
.overview-control-panel .control-center-actions .button-icon { margin-right: 4px; }
.overview-control-panel .control-center-actions .button small { display: block; margin-top: 4px; color: rgba(255,255,255,.68); font-size: 10px; font-weight: 600; }

@media (max-width: 980px) {
  .overview-control-grid { grid-template-columns: minmax(0, 1fr) minmax(190px, .72fr); }
  .overview-control-panel .hero-identity { grid-column: 1 / -1; }
  .overview-control-panel .control-center-stats { grid-column: 1 / -1; grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .overview-control-panel { padding: 19px; }
  .overview-control-grid { grid-template-columns: 1fr; }
  .overview-control-panel .hero-identity { grid-column: auto; grid-template-columns: 1fr; gap: 17px; }
  .overview-control-panel .hero-balance { min-height: 112px; }
  .overview-control-panel .control-center-stats { grid-column: auto; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .overview-control-panel .control-center-actions,
  .overview-control-panel .overview-child-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
