/* jimplanner.app — the app's own palette and system type, nothing the app does not have.
   The site is dark only, like the app's default. Two lights give the ground its depth:
   a cool light-blue one just above the top edge and a deep-blue one just below the
   bottom edge. Both are fixed to the viewport and drift slowly; reduced-motion stops them. */
:root {
  color-scheme: dark;
  --ground: #0A0D13;
  --surface: #14171E;
  --surface-glass: rgba(20, 23, 30, 0.72);
  --ink: #F3F4F6;
  --ink-2: #C9CDD6;
  --muted: #9AA1AE;
  --line: #262A33;
  --line-glass: rgba(255, 255, 255, 0.08);
  --brand: #4D9BFF;
  --brand-ink: #0A0D13;
  --tonal: #1E3663;
  --primary: #3D8CFF;
  /* the two lights, as rgb triplets */
  --light-top-core: 170, 210, 255;
  --light-top-halo: 77, 155, 255;
  --light-bottom: 28, 66, 140;
  --light-bottom-far: 30, 54, 99;
}
* { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  background: var(--ground);
}
body {
  margin: 0;
  background: transparent;
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  padding-inline: 20px;
  padding-block: 0 64px;
}

/* The lights. Pseudo-elements, so every page gets them without a markup change.
   Painted behind the content (negative z-index inside the root stacking context) and
   above the html ground. Only transform and opacity animate, so they stay on the GPU. */
body::before,
body::after,
html::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
}
body::before {
  z-index: -3;
  transform-origin: 50% 0;
  background:
    radial-gradient(ellipse 36% 32% at 50% -5%,
      rgba(var(--light-top-core), 0.55) 0%,
      rgba(var(--light-top-core), 0.22) 38%,
      rgba(var(--light-top-core), 0.06) 68%,
      rgba(var(--light-top-core), 0) 100%),
    radial-gradient(ellipse 78% 60% at 50% -14%,
      rgba(var(--light-top-halo), 0.30) 0%,
      rgba(var(--light-top-halo), 0.12) 42%,
      rgba(var(--light-top-halo), 0.03) 72%,
      rgba(var(--light-top-halo), 0) 100%);
  animation:
    drift-top 26s ease-in-out infinite alternate,
    breathe 11s ease-in-out infinite alternate;
}
body::after {
  z-index: -2;
  transform-origin: 50% 100%;
  background:
    radial-gradient(ellipse 58% 42% at 50% 108%,
      rgba(var(--light-bottom), 0.60) 0%,
      rgba(var(--light-bottom), 0.26) 42%,
      rgba(var(--light-bottom), 0.07) 72%,
      rgba(var(--light-bottom), 0) 100%),
    radial-gradient(ellipse 110% 62% at 50% 118%,
      rgba(var(--light-bottom-far), 0.55) 0%,
      rgba(var(--light-bottom-far), 0.18) 48%,
      rgba(var(--light-bottom-far), 0) 100%);
  animation: drift-bottom 38s ease-in-out infinite alternate;
}
/* Fine grain over both lights: keeps the long gradients from banding and gives the dark
   a little material. */
html::after {
  z-index: -1;
  opacity: 0.055;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}
@keyframes drift-top {
  from { transform: translate3d(-3%, -1%, 0) scale(1); }
  to   { transform: translate3d(3%, 1.5%, 0) scale(1.08); }
}
@keyframes drift-bottom {
  from { transform: translate3d(3%, 1%, 0) scale(1.06); }
  to   { transform: translate3d(-3%, -1.5%, 0) scale(1); }
}
@keyframes breathe {
  from { opacity: 0.84; }
  to   { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  body::before, body::after { animation: none; }
}

a { color: var(--primary); text-decoration: none; }
a:hover, a:focus-visible { text-decoration: underline; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 6px; }
.wrap { max-width: 720px; margin: 0 auto; }
h1, h2, h3 { margin: 0; letter-spacing: -0.01em; text-wrap: balance; }
p { margin: 0; }

/* Top bar */
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding-block: 20px;
}
.lockup { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); font-weight: 900; font-size: 22px; letter-spacing: 0.3px; }
.lockup:hover { text-decoration: none; }
.mark { width: 28px; height: 28px; color: var(--brand); flex: none; display: block; }
.top nav { display: flex; gap: 18px; font-size: 15px; font-weight: 500; }
.top nav a { color: var(--ink-2); }

/* Home */
/* The hero is centred under the top light; the cards and steps below stay left-aligned. */
.hero {
  display: grid; gap: 22px; justify-items: center; text-align: center;
  padding-block: 40px 28px;
}
.hero .tonal { width: 132px; height: 132px; display: block; }
.hero h1 { font-size: clamp(34px, 6vw, 48px); line-height: 1.06; font-weight: 800; letter-spacing: -0.02em; max-width: 18ch; }
.hero .sub { font-size: 19px; color: var(--ink-2); max-width: 44ch; }
.cta {
  display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: 12px;
  background: var(--brand); color: var(--brand-ink); font-weight: 700; font-size: 16px;
  box-shadow: 0 10px 28px -10px rgba(77, 155, 255, 0.55);
}
.cta:hover { text-decoration: none; filter: brightness(1.06); }
.cta svg { width: 18px; height: 18px; }
.hero .note { font-size: 14px; color: var(--muted); }

.rows { display: grid; gap: 10px; padding-block: 12px 36px; }
/* Cards are a little translucent so the lights show through, with a hairline catch of the
   top light along their upper edge and a soft shadow under them. */
.row {
  display: grid; grid-template-columns: 48px 1fr; gap: 14px; align-items: center;
  background: var(--surface-glass); border: 1px solid var(--line-glass); border-radius: 14px; padding: 14px 16px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 14px 34px -22px rgba(0, 0, 0, 0.9);
}
.row .ic { width: 48px; height: 48px; border-radius: 12px; background: color-mix(in srgb, var(--primary) 14%, transparent); display: grid; place-items: center; color: var(--primary); }
.row .ic svg { width: 24px; height: 24px; }
.row b { display: block; font-size: 17px; font-weight: 700; }
.row span { display: block; font-size: 14px; color: var(--muted); }

.steps { display: grid; gap: 14px; padding-block: 8px 40px; }
.steps h2 { font-size: 22px; font-weight: 800; }
.steps ol { margin: 0; padding-left: 22px; display: grid; gap: 8px; color: var(--ink-2); }
.steps li::marker { color: var(--brand); font-weight: 700; }

/* Legal pages */
article { padding-block: 28px 8px; display: grid; gap: 22px; }
article h1 { font-size: clamp(30px, 5vw, 38px); font-weight: 800; line-height: 1.1; }
article .dated { font-size: 14px; color: var(--muted); }
article h2 { font-size: 20px; font-weight: 800; padding-top: 10px; }
article p, article li { color: var(--ink-2); }
article ul { margin: 0; padding-left: 22px; display: grid; gap: 6px; }
article .box {
  background: var(--surface-glass); border: 1px solid var(--line-glass); border-radius: 14px; padding: 16px 18px; color: var(--ink-2); font-size: 15px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
article table { border-collapse: collapse; width: 100%; font-size: 15px; }
article th, article td { text-align: left; vertical-align: top; padding: 10px 10px 10px 0; border-bottom: 1px solid var(--line); color: var(--ink-2); }
article th { color: var(--ink); font-weight: 700; white-space: nowrap; }
.scroll { overflow-x: auto; }

/* Footer */
footer { border-top: 1px solid var(--line-glass); margin-top: 24px; padding-top: 20px; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 14px; color: var(--muted); align-items: center; }
footer a { color: var(--ink-2); }

@media (max-width: 480px) {
  .top nav { gap: 14px; }
  .hero .tonal { width: 108px; height: 108px; }
  .row { grid-template-columns: 44px 1fr; }
  .row .ic { width: 44px; height: 44px; }
}
