/* Upmark panel (app.upmarklabs.com). Look from the approved screens: deep teal, ink, grey, lines; Fraunces headings,
   Inter text; square-ish 4px buttons; phone-first. Every control's look is set here once, for every page. */

@font-face { font-family: "Inter"; src: url("/static/fonts/inter-latin.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --teal: #0B5D52; --teal-dark: #08443C; --teal-soft: #E7F1EE; --teal-ink: #D9ECE7;
  --ink: #101413; --ink-2: #2E3836; --ink-3: #3A4542; --muted: #5B6663;
  --grey: #F4F5F3; --line: #E2E6E4; --field: #C9D0CD; --white: #FFFFFF;
  --amber-bg: #FDF0DD; --amber: #8A4B05; --good: #11603A; --bad: #9B1C1C; --bad-bg: #FDECEC;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--grey); color: var(--ink); font-family: var(--sans); font-size: 15px; line-height: 1.5; }
a { color: var(--teal); }
a:hover { color: var(--teal-dark); }
h1, h2, h3 { margin: 0; }
p { margin: 0; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--white); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }

/* --- form controls: one look for every page --- */
label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; color: var(--ink); }
input, select, textarea { min-height: 48px; width: 100%; padding: 0 14px; border: 1px solid var(--field); border-radius: 4px; font: inherit;
  font-size: 16px; font-weight: 400; color: var(--ink); background-color: var(--white); }
textarea { padding: 12px 14px; min-height: 96px; }
input:focus, select:focus, textarea:focus { border-color: var(--teal); outline: 2px solid var(--teal-soft); outline-offset: 0; }
/* The one dropdown style: no browser arrow, our own arrow, 44px clear of the right edge so text never runs under it. */
select { appearance: none; -webkit-appearance: none; -moz-appearance: none; padding-right: 44px; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, #4A5552 50%), linear-gradient(135deg, #4A5552 50%, transparent 50%);
  background-position: right 20px center, right 14px center; background-size: 6px 6px, 6px 6px; background-repeat: no-repeat; }
select::-ms-expand { display: none; }
.hint { font-size: 13px; font-weight: 400; color: var(--muted); }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 18px; border-radius: 4px;
  border: 1px solid var(--teal); background: var(--teal); color: var(--white); font: inherit; font-size: 15px; font-weight: 500;
  text-decoration: none; cursor: pointer; }
.button:hover { background: var(--teal-dark); color: var(--white); }
.button.ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.button.ghost:hover { background: var(--grey); color: var(--ink); }
.button.quiet { background: transparent; color: var(--ink); border-color: var(--field); }
.button.wide { width: 100%; min-height: 52px; font-size: 16px; }
.link { background: none; border: 0; padding: 0; font: inherit; color: var(--teal); text-decoration: underline; cursor: pointer; }

.notice { padding: 12px 16px; border-radius: 6px; background: var(--teal-soft); color: var(--teal-dark); }
.error { padding: 12px 16px; border-radius: 6px; background: var(--bad-bg); color: var(--bad); }
.muted { color: var(--muted); }
.stack { display: flex; flex-direction: column; gap: 16px; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* --- sign-in and sign-up --- */
.auth { min-height: 100vh; display: flex; flex-direction: column; background: var(--white); }
.auth-top { display: flex; align-items: center; min-height: 72px; padding: 0 24px; border-bottom: 1px solid var(--line); }
.auth-body { flex: 1; display: flex; flex-wrap: wrap; }
.auth-form { flex: 1 1 560px; display: flex; justify-content: center; padding: 56px 16px; }
.auth-form > div { width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 22px; }
.auth h1 { font-family: var(--serif); font-size: 44px; line-height: 1.05; font-weight: 400; }
.auth .lead { font-size: 17px; color: var(--ink-3); }
.auth .small { font-size: 13px; line-height: 1.6; color: var(--muted); }
.auth-side { flex: 1 1 520px; min-height: 320px; background: var(--teal); color: var(--white); display: flex; align-items: flex-end; padding: 48px; }
.auth-side p { font-family: var(--serif); font-size: 32px; line-height: 1.2; }
.auth-side span { display: block; margin-top: 16px; font-size: 15px; color: var(--teal-ink); }
.google { background: var(--white); color: var(--ink); border-color: var(--field); }
.google:hover { background: var(--grey); color: var(--ink); }
.or { display: flex; align-items: center; gap: 12px; color: #6B7774; font-size: 14px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.choices { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.choices button { width: 100%; justify-content: space-between; }

/* --- brand mark --- */
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); text-decoration: none; font-size: 19px; font-weight: 700; }
.brand:hover { color: var(--ink); }

/* --- the panel shell: side menu + main (phone first: menu on top, side by side from 900px) --- */
.shell { display: flex; flex-direction: column; min-height: 100vh; }
.side { background: var(--white); border-bottom: 1px solid var(--line); padding: 16px 14px; display: flex; flex-direction: column; gap: 16px; }
.side .brand { padding: 0 8px; }
.side .site-pick { display: flex; flex-direction: column; gap: 6px; }
.side .site-pick label { font-size: 12px; font-weight: 400; color: var(--muted); padding: 0 8px; }
.side .site-pick select { min-height: 44px; font-size: 15px; font-weight: 500; border-radius: 6px; }
.side .site-pick .go { min-height: 40px; }
.js .side .site-pick .go { display: none; }
.menu { display: flex; flex-direction: column; gap: 2px; }
.menu a { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 0 10px; border-radius: 6px; text-decoration: none;
  font-size: 15px; color: var(--ink-2); }
.menu a:hover { background: var(--grey); color: var(--ink); }
.menu a.active { background: var(--teal-soft); color: var(--teal); font-weight: 600; }
.menu svg { flex: none; }
.menu .label { flex: 1; }
.badge { font-size: 12px; font-weight: 600; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--amber-bg);
  color: var(--amber); display: inline-flex; align-items: center; justify-content: center; }
.plan-box { background: var(--grey); border-radius: 10px; padding: 14px; display: flex; flex-direction: column; gap: 6px; }
.plan-box strong { font-size: 14px; }
.plan-box span { font-size: 13px; color: var(--muted); }
.plan-box a { font-size: 13px; font-weight: 600; text-decoration: none; }
.who { display: flex; flex-direction: column; gap: 6px; padding: 0 8px; font-size: 13px; color: var(--muted); }
.who form { margin: 0; }
.main { flex: 1; min-width: 0; padding: 24px 16px 48px; display: flex; flex-direction: column; gap: 24px; }

@media (min-width: 900px) {
  .shell { flex-direction: row; }
  .side { flex: 0 0 260px; border-bottom: 0; border-right: 1px solid var(--line); padding: 20px 14px; gap: 18px; min-height: 100vh; position: sticky; top: 0; align-self: flex-start; }
  .side-more { flex: 1; }
  .side .plan-box { margin-top: auto; }
  .main { padding: 40px 48px 64px; }
}

/* --- panel content --- */
.head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px; }
.head .hello { font-size: 15px; color: var(--muted); }
.head h1, .title { font-family: var(--serif); font-size: 36px; line-height: 1.1; font-weight: 400; overflow-wrap: anywhere; }
@media (min-width: 900px) { .head h1, .title { font-size: 44px; } }
h2.section { font-family: var(--serif); font-size: 30px; font-weight: 400; margin-top: 8px; }
.cards { display: flex; flex-wrap: wrap; gap: 16px; }
.card { flex: 1 1 300px; background: var(--white); border-radius: 14px; padding: 24px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.card.wide { flex: 2 1 460px; }
.card.teal { background: var(--teal); color: var(--white); }
.card.teal a { color: var(--white); }
.card.teal .sub { color: var(--teal-ink); }
.card h2 { font-size: 18px; font-weight: 600; }
.card-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; }
.card-head a { font-size: 14px; }
.lines { list-style: none; margin: 0; padding: 0; }
.lines li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 0;
  border-top: 1px solid var(--line); font-size: 15px; }
.lines li form { margin: 0; }
.empty { color: var(--muted); font-size: 15px; }
.score { display: flex; align-items: center; gap: 20px; }
.score strong { font-size: 18px; }
.results { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; }
.result { background: var(--white); border-radius: 12px; padding: 20px; display: flex; flex-direction: column; gap: 6px; }
.result .what { font-size: 14px; color: var(--muted); }
.result .number { font-size: 30px; font-weight: 600; }
.result .sub { font-size: 13px; color: var(--muted); }
.pill { display: inline-flex; align-items: center; font-size: 13px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--amber-bg); color: var(--amber); }
.pill.good { background: var(--teal-soft); color: var(--good); }
.pill.bad { background: var(--bad-bg); color: var(--bad); }
.plan-name { font-family: var(--serif); font-size: 30px; font-weight: 400; }
.grid-form { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 640px) { .grid-form { grid-template-columns: 1fr 1fr; } .grid-form .full { grid-column: 1 / -1; } }
.narrow { max-width: 560px; }
.stack.tight { gap: 6px; }
.inline-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.inline-form label { flex: 1 1 240px; }

/* Phone: the menu folds away behind a Menu button (with script; without it the menu simply shows). */
.side-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.side-more { display: flex; flex-direction: column; gap: 16px; }
.menu-button { display: none; min-height: 44px; }
@media (max-width: 899px) {
  .js .menu-button { display: inline-flex; }
  .js .side-more { display: none; }
  .js .side.open .side-more { display: flex; }
}
