/* Night palette shared with the website (site/src/assets/css/tokens.css). */
:root { --ink: #eef0fa; --muted: #b4bad3; --line: rgba(238, 240, 250, 0.16); --bg: #0e1222; --card: #171d3a; --field: #090c17; --accent: #a99cff; --accent-fill: #6a58ee; --danger: #ff8f8f; --ok: #7be0b0; --warn: #ffb547; color-scheme: dark; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 15px/1.45 system-ui, "Segoe UI", Roboto, Tahoma, Arial, sans-serif; color: var(--ink); min-height: 100vh; background: radial-gradient(ellipse at 50% 0%, #2a2453 0%, transparent 60%), linear-gradient(180deg, #121730 0%, #0e1222 55%, #090c17 100%) fixed; }
a { color: var(--accent); }
.top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; padding: 10px 16px; background: rgba(9, 12, 23, 0.85); border-bottom: 1px solid var(--line); color: #fff; }
.top a { color: #fff; text-decoration: none; }
.brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; }
.brand img { border-radius: 6px; }
.nav { display: flex; align-items: center; gap: 16px; margin-left: auto; }
.nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 4px; }
main { max-width: 980px; margin: 0 auto; padding: 16px; }
h1 { font-size: 22px; margin: 4px 0 14px; }
h2 { font-size: 17px; margin: 0 0 10px; }
.page-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 14px; margin-bottom: 14px; }
.panel.narrow { max-width: 420px; margin: 40px auto; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; }
label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 10px; }
label > input, label > select, label > textarea { display: block; margin-top: 3px; }
input[type=text], input[type=email], input[type=password], input[type=search], select, textarea { font: inherit; padding: 7px 9px; border: 1px solid var(--line); border-radius: 7px; background: var(--field); color: var(--ink); width: 100%; max-width: 100%; }
.row > label { flex: 1 1 200px; margin-bottom: 0; }
textarea { min-height: 4.5em; resize: vertical; font-family: Consolas, "Cascadia Mono", "DejaVu Sans Mono", "Courier New", monospace; }
button, .button { font: inherit; padding: 7px 14px; border-radius: 7px; border: 1px solid var(--accent-fill); background: var(--accent-fill); color: #fff; cursor: pointer; text-decoration: none; display: inline-block; }
button.secondary, .button.secondary { background: transparent; color: var(--accent); border-color: var(--accent); }
button.danger { background: transparent; color: var(--danger); border-color: var(--danger); }
button.link { background: none; border: 0; padding: 0; color: inherit; text-decoration: underline; cursor: pointer; }
form.inline { display: inline; margin: 0; }
form.inline.row { display: inline-flex; align-items: center; gap: 6px; }
form.inline.row input[type=text] { width: 14em; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 10px 0 0; }
.project-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 12px; }
.project-head h2 { margin: 0; }
.project-head h2 a { text-decoration: none; color: var(--ink); }
.videos { margin: 10px 0 0; padding-left: 18px; }
.new-project { align-items: end; }
.badge { display: inline-block; padding: 1px 8px; border-radius: 99px; font-size: 12px; font-weight: 600; border: 1px solid currentColor; white-space: nowrap; }
.badge.pro { color: var(--ok); }
.badge.trial { color: var(--warn); }
.muted { color: var(--muted); }
.notice { padding: 10px 12px; border-radius: 8px; margin-bottom: 14px; border: 1px solid; }
.notice.ok { color: var(--ok); background: rgba(123, 224, 176, 0.12); }
.notice.error { color: var(--danger); background: rgba(255, 143, 143, 0.12); }
.notice.warn { color: var(--warn); background: rgba(255, 181, 71, 0.12); }
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; overflow-wrap: anywhere; }
.mono { font-family: Consolas, "Cascadia Mono", "DejaVu Sans Mono", "Courier New", monospace; }
@media (max-width: 640px) {
  .nav { margin-left: 0; width: 100%; }
  dl.facts { grid-template-columns: 1fr; gap: 0; }
  dl.facts dd { margin-bottom: 8px; }
}
.signed-out { position: sticky; top: 0; z-index: 10; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; padding: 12px 16px; background: #2a1622; color: var(--danger); border-bottom: 2px solid var(--danger); font-weight: 600; }
.signed-out .button { margin-left: auto; background: var(--danger); border-color: var(--danger); }

/* My projects gallery: square-ish tiles side by side with a still of each project. */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.gallery .project { margin: 0; padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.gallery .project > :not(.thumb) { padding-left: 12px; padding-right: 12px; }
.gallery .thumb { display: block; aspect-ratio: 16 / 9; background: #fbfaf7 url("/static/app-icon-32.png") center / 32px no-repeat; border-bottom: 1px solid var(--line); }
.gallery .thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.gallery .project-head { padding-top: 10px; }
.gallery .project-head h2 { font-size: 16px; margin: 0 0 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gallery .actions { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.gallery .actions .button, .gallery .actions button { padding: 5px 10px; font-size: 14px; }
.gallery .more { padding-bottom: 12px; font-size: 14px; }
.gallery .more summary { cursor: pointer; color: var(--muted); }
.gallery .more form.inline.row { display: flex; margin: 8px 0; }
.gallery .more form.inline.row input[type=text] { width: auto; flex: 1; min-width: 0; }
