:root {
  color-scheme: light;
  --paper: #f8f5f2; --panel: #fffdfa; --ink: #171717; --muted: #646e65;
  --line: #dcded5; --accent: #385144; --on-accent: #fffdfa; --tint: #eaf0e8;
  --danger: #9d3e38; --shadow: 0 12px 40px #25382a06;
  font: 15px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--paper); color: var(--ink);
}
@media (prefers-color-scheme: dark) {
  :root { color-scheme: dark; --paper: #222222; --panel: #282b28; --ink: #f8f5f2; --muted: #b0b7ae; --line: #414841; --accent: #a5c3ad; --on-accent: #17251c; --tint: #323d34; --danger: #ffada3; --shadow: none; }
  .brand img { filter: invert(1); }
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100dvh; display: flex; flex-direction: column; }
a { color: var(--accent); text-underline-offset: 4px; }
button, input, select, textarea { font: inherit; }
button, a, input, select { touch-action: manipulation; }
button, .button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 17px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--ink); font-size: 14px; font-weight: 600; line-height: 1.4; cursor: pointer; text-decoration: none; }
button:hover, .button:hover { background: var(--tint); border-color: var(--accent); }
button:disabled { opacity: .55; cursor: wait; }
:where(button, a, input, select, textarea, summary):focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.primary { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.primary:hover { background: var(--accent); filter: brightness(.93); }
.full-width { width: 100%; }
.danger { color: var(--danger); }
label { display: block; margin-bottom: 20px; font-size: 13px; font-weight: 600; }
input:not([type=checkbox]), select, textarea { display: block; width: 100%; min-width: 0; min-height: 48px; margin-top: 7px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 9px; background: var(--paper); color: var(--ink); font-size: 16px; font-weight: 400; }
input::placeholder, textarea::placeholder { color: var(--muted); opacity: .9; }
input[type=checkbox] { width: 18px; height: 18px; margin: 0 8px 0 0; vertical-align: middle; accent-color: var(--accent); }
textarea { min-height: 120px; resize: vertical; }
h1, h2, h3, p { margin: 0; }
h1 { font: 42px/1.15 Georgia, "Times New Roman", serif; letter-spacing: -.035em; }
h2 { font-size: 18px; line-height: 1.4; font-weight: 600; letter-spacing: -.02em; }
h3 { font-size: 16px; line-height: 1.4; font-weight: 600; }
.site-header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; min-height: 88px; padding: 20px clamp(22px, 5vw, 72px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 9px; color: var(--ink); font: 27px/1 Georgia, serif; letter-spacing: -.8px; }
.brand img { object-fit: contain; }
.brand-ink { font-style: italic; }
.header-caption, .eyebrow { font-size: 10px; letter-spacing: .16em; font-weight: 650; color: var(--muted); }
.site-nav { display: flex; flex-wrap: wrap; gap: 8px; }
.site-nav a { padding: 9px 12px; border-radius: 8px; font-size: 13px; font-weight: 550; text-decoration: none; }
.site-nav a:hover, .site-nav a[aria-current=page] { background: var(--tint); }
.account-shell { width: min(100% - 40px, 460px); margin: clamp(36px, 7vh, 80px) auto 48px; }
.page-intro { margin-bottom: 28px; }
.page-intro .eyebrow { margin-bottom: 14px; }
.page-intro h1 { margin-bottom: 14px; }
.page-intro > p:last-child { color: var(--muted); font-size: 15px; max-width: 52ch; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 28px; box-shadow: var(--shadow); min-width: 0; }
.auth-panel { padding: 30px; }
#account > .primary { margin-top: 4px; min-height: 48px; }
.field-help { color: var(--muted); font-size: 12px; margin: -10px 0 20px; }
.auth-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 10px; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.auth-actions button { border: 0; background: transparent; padding: 8px 5px; font-size: 12px; font-weight: 500; color: var(--accent); min-height: 36px; }
.auth-actions button:hover { text-decoration: underline; text-underline-offset: 4px; }
.signin-return { text-align: center; margin-top: 20px; font-size: 13px; }
.auth-footnote { text-align: center; color: var(--muted); font-size: 12px; line-height: 1.7; margin-top: 24px; }
.notice { border: 1px solid var(--line); border-radius: 10px; padding: 13px 16px; margin-bottom: 20px; background: var(--tint); font-size: 14px; overflow-wrap: anywhere; }
.notice:empty { display: none; }
.notice[data-kind=error] { color: var(--danger); border-color: var(--danger); background: var(--panel); }
.account-shell.settings-view { width: min(100% - 40px, 960px); margin-top: 48px; }
.settings-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; margin: 20px 0; }
.section-heading { margin-bottom: 24px; }
.section-heading p, .signout-panel p { margin-top: 6px; color: var(--muted); font-size: 13px; }
.identity-panel, .signout-panel { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.account-identity { color: var(--muted); overflow-wrap: anywhere; margin-top: 5px; }
.identity-panel button, .signout-panel button { flex-shrink: 0; }
.session-list { list-style: none; padding: 0; margin: 0; }
.session-list li { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; border-top: 1px solid var(--line); }
.session-list li:first-child { border-top: 0; padding-top: 0; }
.session-list .session-info { min-width: 0; overflow-wrap: anywhere; font-size: 14px; }
.session-list small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.session-list button { flex-shrink: 0; min-height: 36px; padding: 7px 10px; font-size: 12px; font-weight: 500; }
.session-list .empty-state { color: var(--muted); font-size: 13px; padding: 0; }
.site-footer { margin-top: auto; padding: 12px 24px 28px; text-align: center; color: var(--muted); font: italic 14px/1.5 Georgia, serif; }
dialog { width: min(560px, calc(100% - 32px)); max-height: calc(100dvh - 40px); overflow: auto; border: 1px solid var(--line); border-radius: 18px; padding: 30px; background: var(--panel); color: var(--ink); box-shadow: 0 24px 90px #0003; }
dialog::backdrop { background: #10201688; }
@media (max-width: 600px) {
  .site-header { min-height: 76px; gap: 14px; padding: 17px 22px; }
  .header-caption { display: none; }
  .site-nav { gap: 2px; }
  .site-nav a { padding: 8px; font-size: 12px; }
  h1 { font-size: 36px; }
  .account-shell, .account-shell.settings-view { width: calc(100% - 32px); margin-top: 32px; }
  .panel, .auth-panel { padding: 23px; }
  .settings-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .identity-panel, .signout-panel { align-items: flex-start; flex-direction: column; gap: 18px; }
  .auth-actions { gap: 3px 12px; }
  .auth-actions button { min-height: 44px; }
}
@media (prefers-reduced-motion: no-preference) {
  button, a { transition: background-color .15s, border-color .15s; }
}
