/* Listo's site: the landing page, the app shell, the invite page and the two legal pages. */

@font-face {
  font-family: Fraunces;
  src: url(/fonts/fraunces.woff2) format('woff2');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: Fraunces;
  font-style: italic;
  src: url(/fonts/fraunces-italic.woff2) format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: Figtree;
  src: url(/fonts/figtree.woff2) format('woff2');
  font-weight: 300 900;
  font-display: swap;
}
@font-face {
  font-family: Caveat;
  src: url(/fonts/caveat.woff2) format('woff2');
  font-weight: 500;
  font-display: swap;
}

:root {
  --paper: #faf6ee;
  --paper-deep: #f2ecdf;
  --card: #fffdf9;
  --ink: #1c211e;
  --muted: #5f675f;
  --line: #e2d9c6;
  --line-strong: #c9bfa8;
  --green: #1f8a5b;
  --green-deep: #17694a;
  --on-green: #fdfbf5;
  --tint: #e2efe4;
  --pen: #2f5fa8;
  --shadow: 0 1px 1px rgba(60, 48, 20, 0.05), 0 14px 34px -18px rgba(60, 48, 20, 0.28);
  --serif: Fraunces, 'Iowan Old Style', 'Palatino Linotype', Georgia, serif;
  --sans: Figtree, ui-rounded, system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #131715;
    --paper-deep: #0f1311;
    --card: #1b211e;
    --ink: #edefe8;
    --muted: #9ea89f;
    --line: #2a332e;
    --line-strong: #3d4a43;
    --green: #4cc28a;
    --green-deep: #6fd3a2;
    --on-green: #07140d;
    --tint: #1b3327;
    --pen: #8fb4ee;
    --shadow: 0 1px 1px rgba(0, 0, 0, 0.3), 0 18px 40px -20px rgba(0, 0, 0, 0.7);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
}
ul,
ol {
  padding: 0;
  list-style: none;
}
a {
  color: var(--green-deep);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}
a:hover {
  text-decoration-thickness: 2px;
}
:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 3px;
  border-radius: 6px;
}
[hidden] {
  display: none !important;
}
.wrap {
  width: min(100% - 2.5rem, 68rem);
  margin-inline: auto;
}
.wordmark {
  display: block;
  color: var(--ink);
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 1.35rem;
  border: 0;
  border-radius: 0.8rem;
  background: var(--green);
  color: var(--on-green);
  font: 600 1.0625rem/1.2 var(--sans);
  text-decoration: none;
  cursor: pointer;
  transition:
    background 0.15s ease,
    transform 0.15s ease;
}
.button:hover {
  background: var(--green-deep);
}
.button:active {
  transform: translateY(1px);
}
.button.small {
  padding: 0.55rem 1rem;
  font-size: 0.975rem;
}
.quiet {
  color: var(--ink);
  font-weight: 500;
}

/* Header */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.5rem;
}
.top a.home {
  display: block;
  text-decoration: none;
}
.top nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  font-size: 0.975rem;
}
.top nav a:not(.button) {
  color: var(--muted);
  text-decoration: none;
}
.top nav a:not(.button):hover {
  color: var(--ink);
}

/* Hero */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  padding-block: clamp(2rem, 6vw, 5rem) clamp(4rem, 9vw, 7.5rem);
}
.hero h1 {
  font: 560 clamp(2.75rem, 6.2vw, 4.75rem) / 1.02 var(--serif);
  font-variation-settings: 'opsz' 144;
  letter-spacing: -0.022em;
  text-wrap: balance;
}
.hero h1 em {
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--green-deep);
}
.lead {
  margin-top: 1.5rem;
  max-width: 30rem;
  font-size: clamp(1.125rem, 1.6vw, 1.3rem);
  line-height: 1.55;
  color: var(--muted);
}
.lead strong {
  color: var(--ink);
  font-weight: 500;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 2.25rem;
}
.fine {
  margin-top: 1rem;
  font-size: 0.925rem;
  color: var(--muted);
}

/* The scene beside the headline: something said, then the list it landed on */
.scene {
  position: relative;
  max-width: 27rem;
  margin-inline: auto 0;
  width: 100%;
}
.said {
  display: flex;
  justify-content: flex-end;
}
.bubble {
  max-width: 85%;
  padding: 0.7rem 1rem;
  border-radius: 1.15rem 1.15rem 0.3rem 1.15rem;
  background: var(--ink);
  color: var(--paper);
  font-size: 1rem;
  line-height: 1.4;
}
.did {
  margin: 0.6rem 0 0.9rem 0.25rem;
  font-size: 0.925rem;
  color: var(--muted);
}
.did b {
  color: var(--ink);
  font-weight: 600;
}

.list {
  padding: 1.15rem 1.25rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: 1.1rem;
  background: var(--card);
  box-shadow: var(--shadow);
}
.list-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}
.list-title {
  font: 600 1.2rem/1.2 var(--serif);
  font-variation-settings: 'opsz' 30;
}
.list-sub,
.count {
  font-size: 0.85rem;
  color: var(--muted);
}
.count {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.bar {
  height: 4px;
  margin: 0.8rem 0 0.2rem;
  border-radius: 4px;
  background: var(--tint);
  overflow: hidden;
}
.bar i {
  display: block;
  height: 100%;
  width: 0;
  background: var(--green);
  transition: width 0.35s ease;
}
.aisle {
  margin: 0.95rem 0 0.15rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
}
.item {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--line);
}
.items .item:last-child {
  border-bottom: 0;
}
.box {
  flex: none;
  display: grid;
  place-items: center;
  width: 1.35rem;
  height: 1.35rem;
  margin-top: 0.12rem;
  padding: 0;
  border: 1.5px solid var(--line-strong);
  border-radius: 0.4rem;
  background: transparent;
  color: var(--on-green);
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease;
}
.box svg {
  width: 0.95rem;
  height: 0.95rem;
  opacity: 0;
  transform: scale(0.6);
  transition:
    opacity 0.15s ease,
    transform 0.2s cubic-bezier(0.3, 1.6, 0.6, 1);
}
.box:hover {
  border-color: var(--green);
}
.item.done .box {
  background: var(--green);
  border-color: var(--green);
}
.item.done .box svg {
  opacity: 1;
  transform: none;
}
.item .what {
  min-width: 0;
  flex: 1;
  line-height: 1.4;
}
.item.done .name {
  color: var(--muted);
  text-decoration: line-through;
}
.item.done .qty {
  color: var(--muted);
}
.qty {
  font-weight: 600;
  margin-right: 0.3rem;
}
.who {
  display: block;
  font-size: 0.8rem;
  color: var(--muted);
}
.again {
  flex: none;
  align-self: center;
  padding: 0.15rem 0.55rem;
  border-radius: 99px;
  background: var(--tint);
  color: var(--green-deep);
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
}
.item.fresh {
  animation: fresh 2.4s ease 0.5s both;
}
@keyframes fresh {
  from {
    background: var(--tint);
    box-shadow: 0 0 0 0.45rem var(--tint);
  }
  to {
    background: transparent;
    box-shadow: 0 0 0 0.45rem transparent;
  }
}
.add {
  display: flex;
  gap: 0.5rem;
  margin-top: 1rem;
}
.add input {
  flex: 1;
  min-width: 0;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--line-strong);
  border-radius: 0.65rem;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
}
.add input::placeholder {
  color: var(--muted);
}
.add button {
  padding: 0.6rem 1rem;
  border: 0;
  border-radius: 0.65rem;
  background: var(--ink);
  color: var(--paper);
  font: 600 0.95rem var(--sans);
  cursor: pointer;
}
.scribble {
  position: absolute;
  left: 0.9rem;
  bottom: -3.9rem;
  display: flex;
  align-items: flex-end;
  gap: 0.35rem;
  font:
    500 1.7rem/1 Caveat,
    'Segoe Print',
    'Bradley Hand',
    cursive;
  color: var(--pen);
}
.scribble span {
  transform: rotate(-3deg) translateY(0.35rem);
}
.scribble svg {
  flex: none;
  width: 2.6rem;
  height: 2.6rem;
}

/* Sections */
section {
  padding-block: clamp(3.5rem, 8vw, 6.5rem);
}
.band {
  background: var(--paper-deep);
}
h2 {
  font: 560 clamp(2rem, 4vw, 2.9rem) / 1.08 var(--serif);
  font-variation-settings: 'opsz' 120;
  letter-spacing: -0.018em;
  text-wrap: balance;
}
.intro {
  margin-top: 0.9rem;
  max-width: 34rem;
  font-size: 1.15rem;
  color: var(--muted);
}

/* A week with it */
.week {
  margin-top: 2.75rem;
}
.day {
  display: grid;
  grid-template-columns: 9.5rem minmax(0, 1fr) 17rem;
  gap: 1.5rem 2.5rem;
  align-items: start;
  padding-block: 2rem;
  border-top: 1px solid var(--line);
}
.day:last-child {
  border-bottom: 1px solid var(--line);
}
.day h3 {
  font: italic 400 1.6rem/1.2 var(--serif);
  color: var(--green-deep);
}
.day p {
  max-width: 33rem;
  font-size: 1.15rem;
  line-height: 1.6;
}
.scrap {
  justify-self: end;
  width: 100%;
  max-width: 17rem;
}
.scrap .bubble {
  display: inline-block;
  max-width: 100%;
  font-size: 0.95rem;
}
.scrap.right {
  text-align: right;
}
.slip {
  padding: 0.35rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 0.85rem;
  background: var(--card);
  font-size: 0.95rem;
}
.slip .item {
  padding: 0.4rem 0;
}
.slip .item:last-child {
  border-bottom: 0;
}
.slip .box {
  cursor: default;
}

/* Things you can say */
.sayings {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 4rem;
  margin-top: 2.5rem;
}
.sayings > div {
  padding-block: 1.6rem;
  border-top: 1px solid var(--line);
}
.sayings dt {
  font: italic 400 1.45rem/1.3 var(--serif);
}
.sayings dd {
  margin-top: 0.5rem;
  max-width: 27rem;
  color: var(--muted);
}

/* Where it lives */
.places {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 3rem 4rem;
  margin-top: 2.5rem;
}
.places h3 {
  font: 600 1.35rem/1.25 var(--serif);
  font-variation-settings: 'opsz' 40;
}
.places p {
  margin-top: 0.6rem;
  max-width: 28rem;
  color: var(--muted);
}
.places .button {
  margin-top: 1.4rem;
}
.steps {
  margin-top: 1rem;
  counter-reset: step;
}
.steps li {
  position: relative;
  padding: 0.3rem 0 0.3rem 2rem;
  max-width: 28rem;
}
.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0.38rem;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  background: var(--tint);
  color: var(--green-deep);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.35rem;
  text-align: center;
}
.app-name {
  margin-top: 1.6rem;
  font-weight: 600;
  color: var(--ink);
}
.copy {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
  padding: 0.35rem 0.35rem 0.35rem 0.9rem;
  max-width: 28rem;
  border: 1px solid var(--line-strong);
  border-radius: 0.75rem;
  background: var(--card);
}
.copy code {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font:
    0.9rem ui-monospace,
    'SF Mono',
    Menlo,
    Consolas,
    monospace;
}
.copy button {
  padding: 0.45rem 0.85rem;
  border: 0;
  border-radius: 0.5rem;
  background: var(--ink);
  color: var(--paper);
  font: 600 0.875rem var(--sans);
  cursor: pointer;
}

.ruled {
  border-top: 1px solid var(--line);
}

/* The dull, important part */
.plain {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 2rem 4rem;
  align-items: start;
}
.promises li {
  display: flex;
  gap: 0.9rem;
  padding-block: 1rem;
  border-top: 1px solid var(--line);
  font-size: 1.1rem;
}
.promises li:first-child {
  border-top: 0;
  padding-top: 0.3rem;
}
.promises svg {
  flex: none;
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.3rem;
  color: var(--green);
}
.more {
  margin-top: 1.25rem;
  color: var(--muted);
}

/* The last word */
.closing {
  text-align: center;
}
.closing h2 {
  max-width: 20ch;
  margin-inline: auto;
}
.closing .button {
  margin-top: 2rem;
}

footer {
  padding-block: 2.5rem 3rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.925rem;
}
.foot {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem 3rem;
}
.foot .aside {
  margin-top: 0.9rem;
  max-width: 24rem;
}
.foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}
.foot a {
  color: var(--muted);
}

/* Reading pages: privacy and terms */
.doc {
  max-width: 40rem;
  padding-block: 2.5rem 5rem;
}
.doc h1 {
  font: 560 clamp(2.2rem, 5vw, 3.2rem) / 1.08 var(--serif);
  font-variation-settings: 'opsz' 120;
  letter-spacing: -0.018em;
}
.doc .dated {
  margin-top: 0.75rem;
  color: var(--muted);
  font-size: 0.95rem;
}
.doc h2 {
  margin-top: 2.75rem;
  font-size: 1.5rem;
  font-variation-settings: 'opsz' 40;
  letter-spacing: -0.01em;
}
.doc p,
.doc ul {
  margin-top: 0.9rem;
}
.doc ul {
  padding-left: 1.2rem;
  list-style: disc;
}
.doc li {
  margin-top: 0.4rem;
}

/* Small pages: the invite, and the app before sign-in */
.note {
  max-width: 34rem;
  margin: clamp(2rem, 8vh, 5rem) auto;
  padding: 2.25rem;
  border: 1px solid var(--line);
  border-radius: 1.25rem;
  background: var(--card);
  box-shadow: var(--shadow);
}
.note h1 {
  margin-top: 1.5rem;
  font: 560 1.9rem/1.15 var(--serif);
  font-variation-settings: 'opsz' 60;
  letter-spacing: -0.012em;
}
.note p {
  margin-top: 1rem;
}
.note .muted {
  color: var(--muted);
  font-size: 0.95rem;
}
.note .code {
  padding: 0.8rem 1rem;
  border-radius: 0.75rem;
  background: var(--paper-deep);
  font:
    0.9rem/1.5 ui-monospace,
    'SF Mono',
    Menlo,
    Consolas,
    monospace;
  word-break: break-all;
}

/* The app: a slim bar, then the chat fills the rest */
body.app {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
}
.app-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 1.1rem;
  border-bottom: 1px solid var(--line);
  background: var(--card);
}
.app-bar a {
  display: block;
}
.app main {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
#chat {
  flex: 1;
  min-height: 0;
  width: 100%;
  max-width: 55rem;
  margin-inline: auto;
}
#signin {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 2rem 1rem;
  text-align: center;
}
#signin h1 {
  font: 560 2rem/1.15 var(--serif);
  font-variation-settings: 'opsz' 60;
  letter-spacing: -0.012em;
}
#signin .muted {
  max-width: 26rem;
  color: var(--muted);
}
.invited {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 0.75rem;
  width: min(100% - 2rem, 55rem);
  margin: 0.75rem auto 0;
  padding: 0.6rem 0.9rem;
  border-radius: 0.85rem;
  background: var(--tint);
  font-size: 0.9rem;
}
.invited code {
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  word-break: break-all;
}
.invited button {
  padding: 0.4rem 0.8rem;
  border: 0;
  border-radius: 0.55rem;
  background: var(--green);
  color: var(--on-green);
  font: 600 0.875rem var(--sans);
  cursor: pointer;
}

@media (max-width: 60rem) {
  .hero {
    grid-template-columns: 1fr;
  }
  .scene {
    margin-inline: 0;
    margin-bottom: 3rem;
  }
  .day {
    grid-template-columns: 8rem minmax(0, 1fr);
  }
  .scrap {
    grid-column: 2;
    justify-self: start;
  }
  .scrap.right {
    text-align: left;
  }
  .plain {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 40rem) {
  body {
    font-size: 1rem;
  }
  .top nav a:not(.button) {
    display: none;
  }
  .day {
    grid-template-columns: 1fr;
    gap: 0.6rem;
  }
  .scrap {
    grid-column: 1;
    margin-top: 0.4rem;
  }
  .sayings,
  .places {
    grid-template-columns: 1fr;
  }
  .note {
    padding: 1.5rem;
    margin-inline: 1rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
