@font-face { font-family: 'Fraunces'; src: url('/fonts/fraunces-latin.woff2') format('woff2'); font-weight: 200 900; font-display: swap; }
@font-face { font-family: 'Book Serif'; src: url('/fonts/serif-latin.woff2') format('woff2'); font-weight: 200 900; font-display: swap; }

:root {
  --ink: #26302e;
  --muted: #5f6a67;
  --paper: #f4f1ea;
  --card: #fff;
  --line: #d9d4c8;
  --accent: #2f5d50;
  --danger: #9a3324;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 17px/1.5 'Book Serif', Georgia, serif; }
.top { padding: 16px 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.account { display: flex; align-items: center; gap: 12px; }
.brand { font-family: Fraunces, Georgia, serif; font-size: 20px; color: var(--ink); text-decoration: none; }
main { max-width: 680px; margin: 0 auto; padding: 8px 16px 72px; }
h1 { font: 500 clamp(30px, 7vw, 42px)/1.12 Fraunces, Georgia, serif; margin: 20px 0 12px; letter-spacing: -.01em; }
h2 { font: 500 25px/1.25 Fraunces, Georgia, serif; margin: 0 0 12px; }
p { margin: 0 0 14px; }
.lead { color: var(--muted); font-size: 18px; }
.small { color: var(--muted); font-size: 15px; }
.error { color: var(--danger); }
.error:empty { display: none; }

button, .button {
  font: inherit; font-size: 16px; cursor: pointer; border-radius: 6px; padding: 11px 18px; min-height: 44px;
  border: 1px solid var(--accent); background: var(--accent); color: #fff; text-decoration: none; display: inline-block;
}
button.secondary, .button.secondary { background: transparent; color: var(--accent); }
button.link { background: none; border: none; padding: 8px 0; color: var(--accent); text-decoration: underline; }
button:disabled { opacity: .5; cursor: default; }
:focus-visible { outline: 3px solid #b5852d; outline-offset: 2px; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 16px; }

.drop { display: block; border: 1.5px dashed #a9a394; border-radius: 10px; background: var(--card); padding: 36px 20px; text-align: center; cursor: pointer; margin: 22px 0 12px; }
.drop.over { border-color: var(--accent); background: #f0f5f2; }
.drop input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.drop:focus-within { outline: 3px solid #b5852d; outline-offset: 2px; }
.drop strong { font: 500 20px Fraunces, Georgia, serif; display: block; margin-bottom: 4px; }

progress { width: 100%; height: 10px; accent-color: var(--accent); margin: 8px 0; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 20px; margin-top: 16px; }
.notice { background: #fbf4e2; border: 1px solid #e6d7ae; border-radius: 8px; padding: 12px 14px; margin: 14px 0; font-size: 15px; }
.notice ul { margin: 6px 0 0; padding-left: 20px; }

.thumbs { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px; margin: 12px 0 16px; }
.thumbs img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; display: block; }
label.field { display: block; font-size: 15px; color: var(--muted); margin-bottom: 6px; }
select { font: inherit; padding: 10px 12px; min-height: 44px; border: 1px solid #a9a394; border-radius: 6px; background: #fff; color: var(--ink); }
input[type=email], input[type=password], input[type=text] { width: 100%; font: inherit; padding: 10px 12px; min-height: 44px; border: 1px solid #a9a394; border-radius: 6px; background: #fff; color: var(--ink); }
.form-field { margin-bottom: 16px; }
textarea { width: 100%; min-height: 110px; font: inherit; padding: 10px 12px; border: 1px solid #a9a394; border-radius: 6px; background: #fff; color: var(--ink); }

.book { display: flex; flex-direction: column; gap: 18px; margin-top: 18px; }
.sheet { background: var(--card); box-shadow: 0 1px 4px rgb(38 48 46 / 18%); border-radius: 3px; overflow: hidden; }
.sheet-tools { border-top: 1px solid #eee9de; padding: 2px 12px 8px; }
.sheet-tools textarea { min-height: 76px; margin-top: 4px; }
.sticky { position: sticky; top: 0; z-index: 2; background: var(--paper); padding: 10px 0; border-bottom: 1px solid var(--line); }
.status { min-height: 1.5em; }
@media (prefers-reduced-motion: no-preference) { .sheet { transition: opacity .2s; } }
.sheet.busy { opacity: .55; }

.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; margin: 18px 0 10px; }
.plan { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 20px; display: flex; flex-direction: column; gap: 8px; }
.plan.featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.plan h3 { font: 500 22px/1.2 Fraunces, Georgia, serif; margin: 0; }
.plan .price { font: 500 34px/1.1 Fraunces, Georgia, serif; margin: 0; }
.plan .price span { font: 16px/1.4 'Book Serif', Georgia, serif; color: var(--muted); }
.plan ul { margin: 0 0 8px; padding-left: 18px; flex: 1; }
.plan button { width: 100%; }
.account .link { padding: 8px 0; }
