/* Sixth Day Studios. Same palette as the Guardian dashboard: light + dark from one set
   of tokens, teal accent. Mobile first. */

:root {
  --bg: #f4f5f7; --surface: #ffffff; --surface-2: #eef0f3; --border: #dfe3e8;
  --text: #16191d; --muted: #5d6671; --accent: #0f8f7a; --accent-ink: #ffffff;
  --ok: #1f9d55; --warn: #c97a07; --down: #d64545;
  --glow: rgba(15, 143, 122, .14);
  --radius: 16px; --shadow: 0 1px 2px rgba(0,0,0,.05), 0 8px 24px rgba(0,0,0,.06);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1115; --surface: #171a20; --surface-2: #1f232b; --border: #2a2f38;
    --text: #e8ebef; --muted: #98a2ad; --accent: #2cc4a8; --accent-ink: #06231d;
    --ok: #3ccf7f; --warn: #f0a93a; --down: #ff6b6b;
    --glow: rgba(44, 196, 168, .12);
    --shadow: none; color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* ── Top bar ── */
.top { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 85%, transparent);
       backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); }
.top .wrap { display: flex; align-items: center; gap: 16px; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 700; letter-spacing: .2px; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
              background: var(--accent); color: var(--accent-ink); font-weight: 800; font-size: 15px; }
.top nav { margin-left: auto; display: flex; gap: 18px; font-size: 15px; }
.top nav a { color: var(--muted); }
.top nav a:hover { color: var(--text); text-decoration: none; }

/* ── Hero ── */
.hero { position: relative; overflow: hidden; padding: 84px 0 64px; }
.hero::before { content: ""; position: absolute; inset: -40% -10% auto; height: 520px;
                background: radial-gradient(closest-side, var(--glow), transparent); pointer-events: none; }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
           color: var(--accent); background: var(--glow); padding: 4px 10px; border-radius: 999px; }
.hero h1 { position: relative; font-size: clamp(34px, 6vw, 58px); line-height: 1.08; margin: 18px 0 16px; letter-spacing: -.02em; }
.hero h1 span { color: var(--accent); }
.hero p.lead { position: relative; font-size: clamp(17px, 2.2vw, 20px); color: var(--muted); max-width: 640px; margin: 0 0 28px; }
.verse { position: relative; margin: 28px 0 0; padding-left: 14px; border-left: 3px solid var(--accent);
         color: var(--muted); font-style: italic; max-width: 560px; }
.verse cite { display: block; font-style: normal; font-size: 13px; margin-top: 4px; }
.btns { position: relative; display: flex; flex-wrap: wrap; gap: 12px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 20px;
       border-radius: 12px; border: 1px solid var(--border); background: var(--surface); color: var(--text);
       font: inherit; font-weight: 600; cursor: pointer; }
.btn:hover { text-decoration: none; border-color: var(--accent); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { filter: brightness(1.05); }
.btn:disabled { opacity: .6; cursor: default; }

/* ── Sections ── */
section { padding: 56px 0; }
section h2 { font-size: clamp(26px, 3.6vw, 34px); margin: 0 0 8px; letter-spacing: -.01em; }
section .sub { color: var(--muted); margin: 0 0 28px; }

/* ── App cards ── */
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
        padding: 20px; box-shadow: var(--shadow); transition: transform .15s ease, border-color .15s ease; }
.card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.card h3 { margin: 0 0 6px; font-size: 19px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }
/* Wraps so a long name pushes the status pill onto its own line instead of off the card. */
.card .row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin-bottom: 10px; }
.card .row h3 { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none;
        background: var(--surface-2); color: var(--accent); font-weight: 800; font-size: 18px; }
.pill { margin-left: auto; font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.pill.live { color: var(--ok); background: color-mix(in srgb, var(--ok) 14%, transparent); }
.pill.wip { color: var(--warn); background: color-mix(in srgb, var(--warn) 16%, transparent); }
.empty { color: var(--muted); }

/* ── Contact ── */
.contact { display: grid; gap: 28px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 860px) { .contact { grid-template-columns: 1fr 1.3fr; } }
form.card { display: grid; gap: 14px; }
label { display: grid; gap: 6px; font-size: 14px; font-weight: 600; }
input, textarea { width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--border);
                  background: var(--bg); color: var(--text); font: inherit; font-weight: 400; }
input:focus, textarea:focus { outline: 2px solid color-mix(in srgb, var(--accent) 55%, transparent); border-color: var(--accent); }
textarea { min-height: 140px; resize: vertical; }
.note { font-size: 14px; color: var(--muted); }
.msg { font-size: 15px; padding: 10px 12px; border-radius: 10px; }
.msg.ok { color: var(--ok); background: color-mix(in srgb, var(--ok) 12%, transparent); }
.msg.bad { color: var(--down); background: color-mix(in srgb, var(--down) 12%, transparent); }
.hp { position: absolute; left: -9999px; }   /* honeypot field: humans never see it */

/* ── Footer ── */
footer { border-top: 1px solid var(--border); padding: 28px 0 40px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; }
footer .right { margin-left: auto; }

/* ── Signed-in area: sign in / register / my apps / app info / dev page ── */
main.page { padding: 40px 0 64px; min-height: 70vh; }
.narrow { max-width: 460px; }
.narrow-wide { max-width: 760px; }
.auth { display: grid; gap: 14px; }
.auth h1 { margin: 0; font-size: 28px; }
.hint { font-weight: 400; font-size: 13px; color: var(--muted); }
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 16px; margin-bottom: 24px; }
.page-head h1 { margin: 0; font-size: clamp(28px, 4vw, 36px); }
.page-head .sub { margin: 4px 0 0; }
.page-head .btns { margin-left: auto; }
.linktree { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.card.link .btns { margin-top: 14px; }
.btn.discord { background: #5865f2; border-color: #5865f2; color: #fff; }
.btn.danger { color: var(--down); }
.btn.danger:hover { border-color: var(--down); }
.btns.small .btn { min-height: 38px; padding: 0 14px; font-size: 14px; }
.icon.big { width: 52px; height: 52px; font-size: 24px; border-radius: 14px; }
.info p { color: var(--text); margin: 14px 0; }
#app .row h1 { margin: 0; font-size: 30px; }

/* Dev page */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.tab { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface);
       color: var(--muted); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.tab.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
#view { display: grid; gap: 14px; }
#view .card:hover { transform: none; }
.card .row strong { font-size: 17px; }
.note.right { margin-left: auto; }
.label { margin: 10px 0 6px; font-size: 13px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.ticks { display: flex; flex-wrap: wrap; gap: 8px; }
.tick { display: inline-flex; align-items: center; gap: 8px; font-weight: 500; font-size: 14px;
        padding: 6px 10px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg); }
.tick input { width: 18px; height: 18px; accent-color: var(--accent); }
.pill.bad { color: var(--down); background: color-mix(in srgb, var(--down) 14%, transparent); }
.card.done { opacity: .6; }
.pre { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--text) !important; margin: 10px 0 !important; }
.linkbox { margin-top: 10px; }
.copy { font-family: Consolas, monospace; font-size: 13px; }
.grid2 { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.app-edit { display: grid; gap: 12px; }
.app-edit h3 { margin: 0; }
select { width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--border);
         background: var(--bg); color: var(--text); font: inherit; font-weight: 400; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 140%); opacity: 0;
         padding: 10px 18px; border-radius: 12px; font-weight: 600; transition: all .2s ease; z-index: 50;
         background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow); }
.toast.ok, .toast.bad { transform: translate(-50%, 0); opacity: 1; }
.toast.ok { color: var(--ok); }
.toast.bad { color: var(--down); }
.top nav a.nav-cta { color: var(--accent); font-weight: 600; }
.top nav a[hidden] { display: none; }
.brand, .top nav a { white-space: nowrap; }
.top nav a.nav-cta { padding: 4px 12px; border: 1px solid var(--accent); border-radius: 999px; }
.top nav a.nav-cta:hover { background: var(--glow); }
/* Phones: the page's own Apps/Contact jumps make room for Sign in / Sign up on one line. */
@media (max-width: 560px) {
  .top nav { gap: 14px; align-items: center; }
  .top nav a[href^="#"], .top nav a[href^="/#"] { display: none; }
}
.providers { display: grid; gap: 10px; }
.btn.provider { width: 100%; }
.btn.provider.google::before { content: "G"; font-weight: 800; color: #4285f4; }
.btn.provider.microsoft::before { content: "⊞"; font-weight: 800; color: #00a4ef; }
.or { text-align: center; font-size: 13px; color: var(--muted); margin-top: 4px; }

.providers { display: grid; gap: 10px; }
.btn.provider { width: 100%; }
.btn.provider.google::before { content: "G"; font-weight: 800; color: #4285f4; }
.btn.provider.microsoft::before { content: "\229E"; font-weight: 800; color: #00a4ef; }
.or { text-align: center; font-size: 13px; color: var(--muted); margin-top: 4px; }
.prose h1 { font-size: clamp(28px, 4vw, 36px); margin: 0 0 4px; }
.prose h2 { font-size: 20px; margin: 28px 0 8px; }
.prose p, .prose li { color: var(--text); }
.prose ul { padding-left: 20px; }
.prose li { margin: 6px 0; }
footer a + a { margin-left: 16px; }
