/* Genie website — one stylesheet for every page. Colours come from the logo: lamp-gold yellow and turban blue. */

:root {
  --bg: #fffdf7;
  --surface: #ffffff;
  --surface-2: #fff6dc;
  --text: #14213d;
  --muted: #4d5875;
  --line: #ece4cc;
  --blue: #1f56d6;
  --blue-dark: #163f9e;
  --blue-soft: #e8efff;
  --gold: #f5b82e;
  --gold-soft: #fde9b4;
  --danger: #b42318;
  --radius: 18px;
  --shadow: 0 1px 2px rgba(20, 33, 61, .06), 0 8px 28px rgba(20, 33, 61, .08);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1424;
    --surface: #151d33;
    --surface-2: #1b2440;
    --text: #eef2fb;
    --muted: #a6b0c8;
    --line: #26304d;
    --blue: #6f9bff;
    --blue-dark: #9ab8ff;
    --blue-soft: #1c2a52;
    --gold: #f5b82e;
    --gold-soft: #3a3016;
    --danger: #ff8a80;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 28px rgba(0, 0, 0, .35);
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--blue-dark); }
h1, h2, h3 { font-family: var(--display); line-height: 1.15; letter-spacing: -.02em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.3rem, 5.5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.5vw, 2.3rem); }
h3 { font-size: 1.15rem; letter-spacing: -.01em; }
p { margin: 0 0 1em; }

.wrap { width: min(1100px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); margin-inline: auto; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; gap: 16px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); font-weight: 700; font-size: 1.15rem; }
.brand img { width: 36px; height: 36px; border-radius: 10px; object-fit: cover; }
.nav { margin-left: auto; display: flex; align-items: center; gap: 22px; }
.nav a { color: var(--muted); text-decoration: none; font-size: .95rem; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
@media (max-width: 640px) { .nav .hide-sm { display: none; } .nav { gap: 14px; } }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 22px; border-radius: 999px; border: 1px solid transparent;
  font: 600 1rem/1 var(--font); text-decoration: none; cursor: pointer;
  transition: transform .12s ease, background .15s ease, box-shadow .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--blue); color: #fff; box-shadow: 0 6px 18px rgba(31, 86, 214, .28); }
.btn-primary:hover { background: var(--blue-dark); color: #fff; }
@media (prefers-color-scheme: dark) { .btn-primary { color: #0e1424; } .btn-primary:hover { color: #0e1424; } }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--line); }
.btn-ghost:hover { color: var(--text); border-color: var(--muted); }
.btn-small { padding: 8px 16px; font-size: .9rem; }
.btn-danger { background: transparent; color: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, transparent); }
.btn-danger:hover { color: var(--danger); background: color-mix(in srgb, var(--danger) 8%, transparent); }
.btn[disabled] { opacity: .55; cursor: default; }

.btn-google { background: #fff; color: #1f1f1f; border-color: #dadce0; font-family: Roboto, var(--font); }
.btn-google:hover { color: #1f1f1f; background: #f8f9fa; }
.btn-google svg { width: 20px; height: 20px; }

/* Hero */
.hero { padding: 72px 0 56px; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px; background: var(--gold-soft);
  font-size: .85rem; font-weight: 600; margin-bottom: 20px;
}
.lead { font-size: 1.2rem; color: var(--muted); max-width: 34em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 14px; }
.fine { font-size: .88rem; color: var(--muted); }
.hero-art { position: relative; justify-self: center; width: min(420px, 100%); }
.hero-art img { width: 100%; border-radius: 32px; box-shadow: var(--shadow); }
.hero-art::before {
  content: ""; position: absolute; inset: -12%; z-index: -1; border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--gold) 45%, transparent), transparent);
}
@media (max-width: 860px) {
  .hero { padding-top: 40px; }
  .hero .wrap { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .hero-art { width: min(300px, 80%); order: -1; }
}

/* Sections */
.section { padding: 72px 0; }
.section-alt { background: var(--surface-2); }
.section-head { max-width: 640px; margin-bottom: 40px; }
.section-head p { color: var(--muted); font-size: 1.08rem; }

.grid { display: grid; gap: 20px; grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .grid { grid-template-columns: minmax(0, 1fr); } }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow);
}
.card p { color: var(--muted); margin: 0; font-size: .98rem; }
.icon {
  width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center;
  background: var(--blue-soft); color: var(--blue); margin-bottom: 14px;
}
.icon svg { width: 22px; height: 22px; }

kbd {
  font: 600 .82em/1 var(--font); padding: 3px 7px; border-radius: 6px;
  background: var(--surface); border: 1px solid var(--line); border-bottom-width: 2px; white-space: nowrap;
}

.steps { counter-reset: step; display: grid; gap: 20px; grid-template-columns: repeat(3, 1fr); }
@media (max-width: 800px) { .steps { grid-template-columns: 1fr; } }
.step { position: relative; padding-top: 56px; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; top: 20px; left: 24px; width: 28px; height: 28px; border-radius: 50%;
  display: grid; place-items: center; background: var(--gold); color: #14213d; font-weight: 700; font-size: .9rem;
}

.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.checks li { display: flex; gap: 12px; align-items: flex-start; }
.checks li::before {
  content: ""; flex: none; width: 22px; height: 22px; margin-top: 2px; border-radius: 50%;
  background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center/14px no-repeat;
}
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
@media (max-width: 800px) { .two-col { grid-template-columns: 1fr; gap: 28px; } }

.cta {
  text-align: center; background: var(--blue); color: #fff; border-radius: 28px; padding: 56px 24px;
}
.cta h2 { color: #fff; }
.cta p { color: rgba(255, 255, 255, .85); max-width: 32em; margin-inline: auto; }
.cta .btn-google { margin-top: 12px; }
@media (prefers-color-scheme: dark) { .cta { background: var(--blue-soft); } }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 32px 0 48px; color: var(--muted); font-size: .92rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 20px; margin-left: auto; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }

/* Legal pages */
.legal { padding: 56px 0 80px; }
.legal h1 { font-size: clamp(2rem, 4.5vw, 2.8rem); }
.legal h2 { font-size: 1.45rem; margin-top: 2.2em; padding-top: .4em; }
.legal h3 { margin-top: 1.6em; }
.legal ul { padding-left: 1.3em; }
.legal li { margin-bottom: .45em; }
.legal .meta { color: var(--muted); }
.callout {
  background: var(--surface-2); border: 1px solid var(--line); border-left: 4px solid var(--gold);
  border-radius: 12px; padding: 18px 20px; margin: 24px 0;
}
.callout p:last-child { margin: 0; }
.toc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 24px; margin: 28px 0; }
.toc ol { margin: 8px 0 0; padding-left: 1.3em; columns: 2; column-gap: 32px; }
@media (max-width: 600px) { .toc ol { columns: 1; } }
.table-wrap { overflow-x: auto; margin: 16px 0 24px; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-weight: 600; background: var(--surface-2); }

/* Account page */
.account { padding: 56px 0 80px; }
.panel {
  background: var(--surface); border: 1px solid var(--line); border-radius: 24px;
  padding: 36px; box-shadow: var(--shadow);
}
@media (max-width: 600px) { .panel { padding: 24px; } }
.panel-center { text-align: center; max-width: 520px; margin-inline: auto; }
.panel-center img.mascot { width: 120px; height: 120px; object-fit: cover; border-radius: 28px; margin: 0 auto 20px; }
.consent { font-size: .88rem; color: var(--muted); margin-top: 18px; }
.profile { display: flex; align-items: center; gap: 14px; margin-bottom: 28px; }
.profile img { width: 52px; height: 52px; object-fit: cover; border-radius: 50%; background: var(--surface-2); }
.profile .who { min-width: 0; }
.profile .who strong { display: block; font-size: 1.1rem; }
.profile .who span { color: var(--muted); overflow-wrap: anywhere; }
.profile form { margin-left: auto; }
.key-box {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
  background: var(--surface-2); border: 1px dashed var(--gold); border-radius: 14px; padding: 18px 20px; margin: 12px 0 8px;
}
.key-box code {
  font: 600 clamp(1rem, 2.6vw, 1.3rem)/1.3 ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: .04em;
  overflow-wrap: anywhere; flex: 1 1 260px;
}
.key-pending { color: var(--muted); }
.status { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .82rem; font-weight: 600; background: var(--blue-soft); color: var(--blue); }
.status.warn { background: var(--gold-soft); color: var(--text); }
.status.bad { background: color-mix(in srgb, var(--danger) 14%, transparent); color: var(--danger); }
.danger-zone { margin-top: 36px; padding-top: 24px; border-top: 1px solid var(--line); }
.danger-zone p { color: var(--muted); font-size: .95rem; }
.notice { padding: 12px 16px; border-radius: 12px; background: color-mix(in srgb, var(--danger) 10%, transparent); color: var(--danger); margin-bottom: 20px; }
[hidden] { display: none !important; }

/* Buttons inside the nav keep their own colours (the nav's link colour would otherwise win). */
.nav a.btn-primary, .nav a.btn-primary:hover { color: #fff; }
@media (prefers-color-scheme: dark) { .nav a.btn-primary, .nav a.btn-primary:hover { color: #0e1424; } }

/* Buying on the account page */
.buy {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px;
  background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px; margin: 12px 0;
}
.buy p { margin: 0; }
.price { font-size: 1.1rem; }
.price strong { font-size: 2rem; letter-spacing: -.02em; }
#manage { margin-top: 4px; }

/* Asking for a trial key on the account page */
.trial { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.trial label { display: block; font-weight: 600; margin: 12px 0 6px; }
.trial textarea, .admin-days input, .admin-upload textarea {
  font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--line); border-radius: 12px;
}
.trial textarea { display: block; width: 100%; padding: 10px 12px; margin-bottom: 12px; resize: vertical; }
.trial textarea:focus, .admin-days input:focus { outline: 2px solid var(--blue); outline-offset: 1px; }
.profile #admin-link { margin-left: auto; }
.profile #admin-link:not([hidden]) + form { margin-left: 0; }
.price-big { font-size: 1.3rem; color: #fff !important; margin-bottom: .6em !important; }
.price-big strong { font-size: 3.2rem; letter-spacing: -.03em; }
.fine-light { font-size: .85rem; margin-top: 18px !important; margin-bottom: 0 !important; }
@media (prefers-color-scheme: dark) { .price-big { color: var(--text) !important; } }

/* Pricing page */
.pricing-top { padding-top: 56px; }
.center { text-align: center; margin-inline: auto; }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; max-width: 820px; margin: 0 auto 24px; }
@media (max-width: 700px) { .plans { grid-template-columns: minmax(0, 1fr); } }
.plan { display: flex; flex-direction: column; padding: 32px 28px; }
.plan h2 { font-size: 1.5rem; margin-bottom: .3em; }
.plan .eyebrow { align-self: flex-start; margin-bottom: 14px; }
.plan .price { margin-bottom: .4em; color: var(--text); }
.plan .plan-note { font-size: .9rem; margin-bottom: 22px; }
.plan .checks { margin-bottom: 28px; gap: 12px; font-size: .98rem; }
.plan .btn { margin-top: auto; }
.plan-main { border: 2px solid var(--blue); }
.faq { margin: 24px 0; }
.faq details { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq summary { cursor: pointer; font-weight: 600; padding: 14px 0; list-style-position: outside; }
.faq details p { color: var(--muted); margin: 0 0 16px; }

/* Trial requests page (admins) */
.admin-request { background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; margin: 14px 0; }
.admin-request p { margin: 6px 0; }
.admin-who strong { display: block; }
.admin-who span { color: var(--muted); font-size: .92rem; overflow-wrap: anywhere; }
.admin-reason { white-space: pre-wrap; overflow-wrap: anywhere; }
.admin-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 12px; }
.admin-days { margin-right: auto; font-size: .95rem; }
.admin-days input { width: 4.5em; padding: 6px 8px; margin: 0 4px; }
.admin-upload { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.admin-upload label { display: block; font-weight: 600; margin: 14px 0 6px; }
.admin-upload input[type=file] { display: block; max-width: 100%; margin-bottom: 4px; }
.admin-upload textarea { display: block; width: 100%; padding: 10px 12px; margin-bottom: 14px; resize: vertical; }
.admin-upload #upload-status { margin-left: 10px; }
