@font-face {
  font-family: "Plex Sans";
  src: url("/assets/fonts/ibm-plex-sans-latin-wght-normal.woff2") format("woff2-variations");
  font-style: normal;
  font-weight: 100 700;
  font-display: swap;
}

:root {
  --paper: #f2f0e9;
  --paper-raised: #faf9f5;
  --ink: #17201c;
  --muted: #5d685f;
  --line: #cfd2c9;
  --line-strong: #9ba49c;
  --signal: #126447;
  --signal-soft: #dce9e1;
  --danger: #8b2d24;
  --focus: #0f6cbd;
  --font: "Plex Sans", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { background: var(--paper); color: var(--ink); }

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--signal); color: #fff; }

a { color: inherit; text-underline-offset: 0.22em; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.brand-mark { width: 25px; height: 25px; color: var(--signal); }

.auth-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(390px, 0.65fr);
  min-height: 100vh;
}

.auth-intro {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100vh;
  padding: clamp(30px, 5vw, 76px);
  background: var(--paper);
}

.auth-copy { max-width: 780px; padding: 12vh 0; }
.auth-copy h1 {
  max-width: 720px;
  margin: 0 0 26px;
  font-size: clamp(3.1rem, 6.5vw, 6rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 0.94;
  text-wrap: balance;
}
.auth-copy p { max-width: 610px; margin: 0; color: var(--muted); font-size: clamp(1.05rem, 1.5vw, 1.3rem); }
.auth-footnote { margin: 0; color: var(--muted); font-size: 13px; }

.auth-panel {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 42px;
  background: var(--ink);
  color: #f8f7f2;
}
.auth-panel-inner { width: min(100%, 390px); }
.auth-heading { margin: 0 0 10px; font-size: 1.4rem; font-weight: 650; letter-spacing: -0.02em; }
.auth-description { margin: 0 0 38px; color: #bbc4be; }
.auth-notice { margin: 0 0 18px; padding: 12px 14px; background: #f5dfdc; color: #672019; font-size: 14px; }

.google-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  min-height: 52px;
  padding: 12px 18px;
  background: #fff;
  color: #20251f;
  border-radius: 12px;
  font-weight: 650;
  text-decoration: none;
  transition: transform 180ms cubic-bezier(.16,1,.3,1), background-color 180ms ease-out;
}
.google-button:hover { background: #edf4ef; transform: translateY(-2px); }
.google-button svg { width: 20px; height: 20px; }
.privacy-note { margin: 18px 0 0; color: #97a39b; font-size: 12px; text-align: center; }
.setup-state { display: grid; gap: 6px; padding: 18px; background: #26312b; color: #f3f1ea; border-radius: 14px; }
.setup-state span { color: #b8c3bc; font-size: 14px; }

.app-frame { min-height: 100vh; }
.app-header {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr);
  align-items: center;
  min-height: 78px;
  padding: 0 clamp(22px, 4vw, 68px);
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.app-header nav { display: flex; align-items: stretch; align-self: stretch; }
.app-header nav a { display: flex; align-items: center; padding: 0 18px; font-size: 14px; font-weight: 650; text-decoration: none; border-bottom: 2px solid var(--signal); }
.account-area { display: flex; align-items: center; justify-content: flex-end; gap: 18px; }
.account-copy { display: grid; justify-items: end; line-height: 1.25; }
.account-copy strong { font-size: 13px; font-weight: 650; }
.account-copy span { color: var(--muted); font-size: 11px; }
.text-button { padding: 7px 0; border: 0; border-bottom: 1px solid var(--line-strong); background: transparent; color: var(--ink); cursor: pointer; font-size: 12px; }
.text-button:hover { border-bottom-color: var(--ink); }

.workspace { width: min(100% - 44px, 1320px); margin: 0 auto; padding: clamp(52px, 7vw, 100px) 0 110px; }
.workspace-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 30px; margin-bottom: 58px; }
.workspace-intro h1 { margin: 0 0 12px; font-size: clamp(2.4rem, 5vw, 5.4rem); font-weight: 500; line-height: 0.98; letter-spacing: -0.04em; }
.workspace-intro p { max-width: 660px; margin: 0; color: var(--muted); font-size: 1.05rem; }
.access-state { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; color: var(--signal); font-size: 12px; font-weight: 700; }
.access-state span { width: 8px; height: 8px; background: var(--signal); border-radius: 50%; box-shadow: 0 2px 9px rgba(18,100,71,.35); }

.desk { display: grid; grid-template-columns: minmax(0, .8fr) minmax(520px, 1.2fr); gap: clamp(48px, 8vw, 120px); padding: clamp(34px, 5vw, 68px); background: var(--ink); color: #f6f4ee; }
.desk-heading h2 { max-width: 450px; margin: 0 0 18px; font-size: clamp(2rem, 4vw, 4.2rem); font-weight: 500; line-height: 1; letter-spacing: -0.035em; }
.desk-heading p { max-width: 52ch; margin: 0; color: #b8c2bb; }
.status-ledger { margin: 0; border-top: 1px solid #59635e; }
.status-ledger div { display: grid; grid-template-columns: 1fr auto; gap: 24px; padding: 19px 0; border-bottom: 1px solid #59635e; }
.status-ledger dt { color: #c4cbc6; }
.status-ledger dd { margin: 0; color: #f5c56a; font-variant-numeric: tabular-nums; }

.extension-map { display: grid; grid-template-columns: minmax(260px, .68fr) minmax(0, 1.32fr); gap: clamp(48px, 9vw, 140px); padding-top: 100px; }
.section-heading h2 { max-width: 460px; margin: 0 0 18px; font-size: clamp(2rem, 3.2vw, 3.5rem); font-weight: 500; line-height: 1.05; letter-spacing: -0.03em; }
.section-heading p { max-width: 45ch; margin: 0; color: var(--muted); }
.build-path { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line-strong); }
.build-path li { display: grid; grid-template-columns: 115px minmax(170px, .75fr) minmax(230px, 1fr); gap: 24px; padding: 24px 0; border-bottom: 1px solid var(--line); }
.build-path span { color: var(--signal); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.build-path strong { font-weight: 650; line-height: 1.35; }
.build-path p { margin: 0; color: var(--muted); }

.app-footer { display: flex; justify-content: space-between; gap: 20px; padding: 26px clamp(22px, 4vw, 68px); border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
.simple-state { display: grid; place-content: center; min-height: 100vh; padding: 30px; text-align: center; }
.simple-state p { margin: 0; color: var(--signal); font-variant-numeric: tabular-nums; }
.simple-state h1 { margin: 14px 0 22px; font-size: clamp(2.2rem, 6vw, 5rem); font-weight: 500; letter-spacing: -0.04em; }
.simple-state a { font-weight: 700; }
.simple-state span { margin-top: 22px; color: var(--muted); font-size: 12px; }

@media (max-width: 900px) {
  .auth-layout { grid-template-columns: 1fr; }
  .auth-intro { min-height: 58vh; }
  .auth-copy { padding: 10vh 0 5vh; }
  .auth-panel { min-height: 42vh; }
  .app-header { grid-template-columns: 1fr auto; }
  .app-header nav { display: none; }
  .account-copy { display: none; }
  .desk, .extension-map { grid-template-columns: 1fr; }
  .desk { gap: 42px; }
}

@media (max-width: 620px) {
  .auth-intro { padding: 25px; }
  .auth-copy h1 { font-size: clamp(2.75rem, 14vw, 4.6rem); }
  .auth-panel { padding: 42px 25px; }
  .app-header { min-height: 68px; padding: 0 18px; }
  .brand span { max-width: 128px; line-height: 1.1; }
  .account-area { gap: 0; }
  .workspace { width: min(100% - 36px, 1320px); padding-top: 54px; }
  .workspace-intro { align-items: flex-start; flex-direction: column; margin-bottom: 38px; }
  .desk { margin-inline: -18px; padding: 36px 24px; }
  .extension-map { padding-top: 72px; gap: 42px; }
  .build-path li { grid-template-columns: 1fr; gap: 7px; padding: 22px 0; }
  .build-path p { max-width: 44ch; }
  .app-footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
