/* NomadTools: the studio's own pages (home, privacy, 404). The chrome stays quiet and cool
   so each app's tile can wear its own colors and type. Light only. */

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("/fonts/BricolageGrotesque.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}
/* Pensar's tile speaks in Pensar's serif; the Pensar pages share the same file. */
@font-face {
  font-family: "Source Serif 4";
  src: url("/pensar/fonts/SourceSerif4-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}

:root {
  --fog: #EDEFF1;
  --white: #FFFFFF;
  --graphite: #1E2227;
  --slate: #58606B;
  --rule: #D3D8DE;
  --cobalt: #2347D5;
  --cobalt-dark: #1A37A8;

  --sans: "Bricolage Grotesque", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --gutter: 16px;
  --wide: 1120px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--fog);
  color: var(--graphite);
  font: 400 17px/1.55 var(--sans);
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}

a { color: var(--cobalt); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--cobalt-dark); }
:focus-visible { outline: 2px solid var(--cobalt); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { margin: 0; font-weight: 650; line-height: 1.1; letter-spacing: -0.02em; text-wrap: balance; }
p { margin: 0 0 1em; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: var(--gutter); top: 8px; background: var(--white); padding: 8px 12px; z-index: 2; }

.wrap { width: 100%; max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Header ---------- */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 18px;
  padding-bottom: 18px;
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--graphite);
  text-decoration: none;
  font-size: 21px;
  font-weight: 720;
  letter-spacing: -0.035em;
  padding: 6px 0;
}
.wordmark svg { width: 28px; height: 28px; flex: none; }
.wordmark:hover { color: var(--graphite); }
.top-link {
  font-size: 16px;
  font-weight: 560;
  color: var(--graphite);
  text-decoration: none;
  padding: 10px 0;
}
.top-link:hover { color: var(--cobalt); text-decoration: underline; }

/* ---------- Intro ---------- */

.intro { padding-top: 40px; padding-bottom: 40px; }
.intro h1 {
  font-size: clamp(40px, 10.5vw, 84px);
  font-weight: 680;
  letter-spacing: -0.045em;
  line-height: 0.98;
  max-width: 11.5em;
}
.intro p {
  margin: 22px 0 0;
  max-width: 34em;
  font-size: clamp(18px, 2.4vw, 21px);
  color: var(--slate);
}

/* ---------- The shelf: one tile per app, each in its own skin ---------- */

.shelf {
  display: grid;
  gap: 16px;
  padding-bottom: 64px;
}

.tile {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 400px;
  padding: 24px;
  text-decoration: none;
  isolation: isolate;
}
.tile:focus-visible { outline-offset: 4px; }

.tile-head { display: flex; align-items: center; gap: 14px; }
.tile-head img { width: 64px; height: 64px; flex: none; }
.tile-name { margin: 0; font-size: 26px; line-height: 1.1; }
.tile-where { margin: 4px 0 0; font-size: 15px; }
.tile-line { margin: 28px 0 0; max-width: 13em; }
.tile-line span { display: block; }
.tile-go {
  margin-top: auto;
  padding-top: 28px;
  font-size: 16px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
}

/* Pensar: paper, ink, a clay underline under the word you'd tap. */
.tile--pensar {
  background: #F4EDDF;
  color: #1B2230;
  border-radius: 8px;
  box-shadow: inset 0 0 0 1px #DED3BF;
}
.tile--pensar .tile-head img { border-radius: 15px; box-shadow: 0 6px 18px -8px rgba(160, 60, 25, 0.45); }
.tile--pensar .tile-name,
.tile--pensar .tile-line { font-family: "Source Serif 4", Georgia, serif; font-weight: 600; letter-spacing: -0.01em; }
.tile--pensar .tile-where { color: #5E6674; }
.tile--pensar .tile-line { font-size: clamp(28px, 7vw, 38px); line-height: 1.12; }
.tile--pensar .tile-go { color: #B03C18; }

.say {
  margin: 22px 0 0;
  font-size: 17px;
  color: #454E5C;
}
.say .word {
  font-family: "Source Serif 4", Georgia, serif;
  font-weight: 600;
  color: #1B2230;
  border-bottom: 2px solid #C0431C;
  padding-bottom: 1px;
}
.say .means {
  display: inline-block;
  margin-left: 6px;
  color: #B03C18;
  opacity: 0;
  transform: translateY(3px);
  transition: opacity 180ms ease-out, transform 180ms cubic-bezier(.3, .7, .4, 1);
}
.tile--pensar:hover .means,
.tile--pensar:focus-visible .means { opacity: 1; transform: none; }
@media (hover: none) { .say .means { opacity: 1; transform: none; } }

.paco {
  position: absolute;
  right: -14px;
  bottom: -26px;
  width: 150px;
  height: auto;
  z-index: -1;
  transform-origin: 60% 100%;
  transition: transform 260ms cubic-bezier(.3, .7, .4, 1);
}
.tile--pensar:hover .paco { transform: rotate(-6deg) translateY(-6px); }

/* MaxAura: deep rose, gold and ivory, the serif italic of its wordmark. */
.tile--maxaura {
  background: radial-gradient(120% 90% at 85% 10%, #8B1A4A 0%, #6B1239 45%, #3A0A22 100%);
  color: #FDF8F3;
  border-radius: 22px;
}
.tile--maxaura .tile-head img { border-radius: 50%; }
.tile--maxaura .tile-name,
.tile--maxaura .tile-line { font-family: "Playfair Display", "Iowan Old Style", Georgia, serif; font-style: italic; font-weight: 600; }
.tile--maxaura .tile-where { color: #DCC196; }
.tile--maxaura .tile-line { font-size: clamp(28px, 7vw, 38px); line-height: 1.12; letter-spacing: -0.01em; }
.tile--maxaura .tile-go { color: #DCC196; }

.palette {
  display: flex;
  gap: 8px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}
.palette li {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgba(253, 248, 243, 0.85);
  transition: transform 220ms cubic-bezier(.3, .7, .4, 1);
}
/* Inline styles are blocked by the CSP, so the swatches live here. */
.palette li:nth-child(1) { background: #B98A5E; }
.palette li:nth-child(2) { background: #A0664B; transition-delay: 30ms; }
.palette li:nth-child(3) { background: #7E8B5C; transition-delay: 60ms; }
.palette li:nth-child(4) { background: #C4958A; transition-delay: 90ms; }
.palette li:nth-child(5) { background: #5F7B78; transition-delay: 120ms; }
.palette li:nth-child(6) { background: #D9BE8F; transition-delay: 150ms; }
.tile--maxaura:hover .palette li,
.tile--maxaura:focus-visible .palette li { transform: translateY(-5px); }
.palette-name { margin: 10px 0 0; font-size: 15px; color: #EDC4D6; }

/* ---------- Promises ---------- */

.promises {
  display: grid;
  gap: 28px;
  padding-top: 8px;
  padding-bottom: 56px;
}
.promises h2 { font-size: 22px; margin-bottom: 8px; }
.promises p { margin: 0; color: var(--slate); max-width: 26em; }

/* ---------- About ---------- */

.about {
  padding-top: 40px;
  padding-bottom: 64px;
}
/* Rules span the content, not the gutters. */
.about, .foot { background: linear-gradient(var(--rule), var(--rule)) center top / calc(100% - 2 * var(--gutter)) 1px no-repeat; }
.about h2 { font-size: clamp(28px, 5vw, 40px); max-width: 16em; }
.about p { margin: 16px 0 0; max-width: 36em; color: var(--slate); font-size: 18px; }
.mail {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  margin-top: 24px;
  padding: 0 22px;
  border-radius: 999px;
  background: var(--graphite);
  color: var(--white);
  font-weight: 600;
  text-decoration: none;
  transition: background 120ms, transform 120ms;
}
.mail:hover { background: var(--cobalt); color: var(--white); }
.mail:active { transform: scale(0.98); }

/* ---------- Footer: every app's legal pages in one place ---------- */

.foot {
  padding-top: 32px;
  padding-bottom: 40px;
  font-size: 15px;
  color: var(--slate);
}
.legal {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 20px 32px;
  margin-bottom: 28px;
}
.legal h2 { font-size: 15px; font-weight: 650; letter-spacing: 0; color: var(--graphite); margin-bottom: 4px; }
.legal ul { margin: 0; padding: 0; list-style: none; }
.legal a { display: inline-block; padding: 6px 0; color: var(--slate); text-decoration: none; }
.legal a:hover { color: var(--cobalt); text-decoration: underline; }
.foot p { margin: 0; }

/* ---------- Text pages (privacy, 404) ---------- */

.doc { max-width: 680px; padding-top: 24px; padding-bottom: 64px; }
.doc h1 { font-size: clamp(36px, 8vw, 56px); letter-spacing: -0.04em; }
.doc h2 { font-size: 24px; margin: 40px 0 10px; }
.doc .updated { margin: 12px 0 28px; color: var(--slate); font-size: 15px; }
.doc ul { padding-left: 1.2em; }
.doc li { margin-bottom: 8px; }
.doc .mail { margin-top: 8px; }

@media (min-width: 720px) {
  :root { --gutter: 32px; }
  .intro { padding-top: 72px; padding-bottom: 56px; }
  .tile { padding: 32px; min-height: 460px; }
  .paco { width: 190px; right: -6px; }
  .promises { grid-template-columns: repeat(3, 1fr); gap: 32px; }
}
@media (min-width: 900px) {
  .shelf { grid-template-columns: 1fr 1fr; gap: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}
