/*
 * Ecomlaude Trial public pages: the home page, the invite page and the join form. (v5.3)
 * Same calm look as the admin: white, lots of space, one dark button.
 */
:root {
  --ink: #111827; --muted: #6b7280; --line: #e6e8eb; --bg: #f6f7f9;
  --brand: #1f6f5c; --bad: #b3261e; --radius: 12px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); font: 16px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; }
a { color: var(--brand); }

/* Top bar (home page) */
.top { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px; max-width: 1080px; margin: 0 auto; padding: 22px 24px; }
.top__brand { font-weight: 700; color: var(--ink); text-decoration: none; letter-spacing: -.01em; }
.top__links { display: flex; gap: 22px; align-items: center; font-size: 15px; }
.top__links a { color: var(--muted); text-decoration: none; }
.top__links a:hover, .top__links a:focus-visible { color: var(--ink); }

/* Home page */
.home { min-height: 100vh; display: flex; flex-direction: column; background: #fff; }
.hero { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 8px 24px 72px; }
.cat { width: 320px; margin: 0 0 28px; touch-action: manipulation; } /* 16px per pixel: every square the same size */
.cat svg { display: block; width: 100%; height: auto; image-rendering: pixelated; }
.hero h1 { font-size: clamp(30px, 5vw, 44px); line-height: 1.15; letter-spacing: -.02em; margin: 0 0 10px; }
.hero p { color: var(--muted); font-size: 18px; margin: 0 0 28px; max-width: 520px; }
.hero .note { font-size: 14px; margin: 18px 0 0; }
.btn { display: inline-block; background: var(--ink); color: #fff; text-decoration: none; font-weight: 600; border-radius: 10px; padding: 13px 28px; border: 0; font: inherit; font-weight: 600; cursor: pointer; }
.btn:hover, .btn:focus-visible { background: #1f2937; color: #fff; }

/* About us */
dialog.about { border: 0; border-radius: 16px; padding: 28px; max-width: 460px; width: calc(100% - 32px); box-shadow: 0 20px 60px rgba(17, 24, 39, .18); color: var(--ink); }
dialog.about::backdrop { background: rgba(17, 24, 39, .35); }
dialog.about h2 { margin: 0 0 10px; font-size: 20px; }
dialog.about p { color: var(--muted); margin: 0 0 20px; white-space: pre-line; }
dialog.about .btn { padding: 10px 20px; }
.about-fallback:not(:target) { display: none; }

/* Join, invite and message pages */
.wrap { max-width: 460px; margin: 0 auto; padding: 40px 16px 56px; }
.brand { font-weight: 700; letter-spacing: -.01em; font-size: 15px; margin: 0 0 18px; }
.brand a { color: var(--ink); text-decoration: none; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 26px 24px; }
.card h1 { font-size: 24px; line-height: 1.25; margin: 0 0 6px; }
p.sub { color: var(--muted); margin: 0 0 18px; }
label { display: block; font-weight: 600; font-size: 14px; margin: 14px 0 6px; }
input { width: 100%; font: inherit; padding: 11px 12px; border: 1px solid #d0d5dd; border-radius: 9px; background: #fff; color: var(--ink); }
input:focus { outline: 0; border-color: var(--brand); box-shadow: 0 0 0 3px #e8f3ef; }
.addr { display: flex; align-items: stretch; border: 1px solid #d0d5dd; border-radius: 9px; overflow: hidden; }
.addr span { background: #f3f4f6; color: var(--muted); padding: 11px 10px; font-size: 14px; white-space: nowrap; }
.addr input { border: 0; border-radius: 0; }
.addr:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px #e8f3ef; }
.addr input:focus { box-shadow: none; }
.hint { font-size: 13px; color: var(--muted); margin-top: 5px; min-height: 18px; }
.err { color: var(--bad); font-size: 13px; margin-top: 5px; }
.hint.ok { color: var(--brand); }
.hint.bad { color: var(--bad); }
.formerr { background: #fdecea; color: var(--bad); border-radius: 9px; padding: 10px 12px; margin: 0 0 10px; font-size: 14px; }
.card button { width: 100%; margin-top: 22px; font: inherit; font-weight: 600; background: var(--ink); color: #fff; border: 0; border-radius: 10px; padding: 13px; cursor: pointer; }
.card button:hover { background: #1f2937; }
.card button:disabled { opacity: .6; }
.foot { text-align: center; color: var(--muted); font-size: 14px; margin-top: 16px; }

@media (max-width: 600px) {
  .top { padding: 16px; }
  .top__links { gap: 16px; font-size: 14px; }
  .hero p { font-size: 16px; }
  .cat { width: 240px; } /* 12px per pixel */
}
