/* One design for every site in the family. Each page sets its app's colors on <html class="tinted">
   (--t for the mark tile, --accent-l and --accent-d for text in light and dark), and cards for
   other apps set their own the same way. */

:root {
  color-scheme: light dark;

  --paper: #f6f3ec;
  --card: #fdfbf6;
  --ink: #1d1b18;
  --ink-soft: #56514a;
  --rule: #ddd5c6;
  --shadow: 0 1px 2px rgb(40 30 20 / 0.06), 0 16px 36px -22px rgb(40 30 20 / 0.35);

  --font-display: "DM Serif Display", Georgia, "Times New Roman", serif;
  --font-body: "Libre Franklin", "Franklin Gothic", system-ui, sans-serif;
}

.tinted {
  --accent: var(--accent-l);
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #131210;
    --card: #1c1a17;
    --ink: #f1ece3;
    --ink-soft: #b9b1a4;
    --rule: #34302a;
    --shadow: 0 1px 0 rgb(255 255 255 / 0.04) inset, 0 18px 40px -20px rgb(0 0 0 / 0.8);
  }

  .tinted {
    --accent: var(--accent-d);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--paper);
  background-image: radial-gradient(
    ellipse 70% 50% at 80% 0%,
    color-mix(in srgb, var(--accent) 13%, transparent),
    transparent 70%
  );
  background-repeat: no-repeat;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  overflow-wrap: break-word;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 2px;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  padding: 0.5rem 0.75rem;
  background: var(--ink);
  color: var(--paper);
  font-weight: 700;
  z-index: 10;
}

.skip-link:focus {
  top: 1rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.wrap {
  width: 100%;
  max-width: 68rem;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 40rem) {
  .wrap {
    padding: 0 2rem;
  }
}

/* Marks */

.mark {
  display: block;
  flex: none;
}

.mark .tile {
  fill: var(--t);
}

.mark .g {
  fill: #fff;
}

.mark .c {
  fill: var(--t);
}

.mark .r {
  fill: none;
  stroke: var(--t);
  stroke-width: 1.2;
  opacity: 0.6;
}

.mark .s {
  fill: none;
  stroke: #fff;
  stroke-width: 3.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Header */

.site-header {
  border-bottom: 1px solid var(--rule);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1.2;
}

.wordmark .mark {
  width: 2rem;
  height: 2rem;
}

.header-link {
  flex: none;
  font-weight: 600;
  font-size: 0.9rem;
}

.pill,
.tag {
  display: inline-block;
  flex: none;
  padding: 0.3rem 0.7rem;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--accent) 9%, transparent);
  color: var(--accent);
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  line-height: 1.2;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Hero */

.hero {
  display: grid;
  gap: 2.5rem;
  align-items: center;
  padding: 3rem 0 3.5rem;
}

@media (min-width: 52rem) {
  .hero {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: 3rem;
    padding: 5rem 0;
  }
}

.eyebrow,
.section-label {
  margin: 0 0 1rem;
  color: var(--ink-soft);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.eyebrow {
  color: var(--accent);
}

.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.5rem, 10.5vw, 4.75rem);
  line-height: 1;
  letter-spacing: -0.01em;
}

.hero h1 span {
  display: block;
  color: var(--accent);
  font-style: italic;
}

.lede {
  max-width: 34rem;
  margin: 1.5rem 0 0;
  color: var(--ink-soft);
  font-size: clamp(1.1rem, 3.4vw, 1.3rem);
  line-height: 1.55;
}

.byline {
  margin: 1.25rem 0 0;
  color: var(--ink-soft);
}

.stamp {
  display: inline-block;
  margin: 2rem 0 0;
  padding: 0.55rem 1rem;
  border: 2px solid var(--accent);
  border-radius: 6px;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.collection {
  margin: 1.5rem 0 0;
  font-weight: 600;
}

.collection a::after {
  content: " \2192";
}

.hero-mark {
  justify-self: center;
  width: min(100%, 14rem);
}

@media (min-width: 52rem) {
  .hero-mark {
    width: min(100%, 17rem);
  }
}

.mark-hero {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 24px 30px color-mix(in srgb, var(--t) 35%, transparent));
  animation: drift 9s ease-in-out infinite alternate;
}

@keyframes drift {
  from {
    transform: translateY(0) rotate(-2deg);
  }
  to {
    transform: translateY(-10px) rotate(2deg);
  }
}

/* Hub mosaic */

.mosaic {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1.25rem 0.75rem;
  justify-self: center;
  width: min(100%, 26rem);
  padding-bottom: 1rem;
}

.mosaic .mark {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 10px 14px color-mix(in srgb, var(--t) 30%, transparent));
  animation: rise 0.7s ease-out both;
}

.mosaic .mark:nth-child(5n + 2),
.mosaic .mark:nth-child(5n + 4) {
  translate: 0 1rem;
}

.mosaic .mark:nth-child(2) { animation-delay: 60ms; }
.mosaic .mark:nth-child(3) { animation-delay: 120ms; }
.mosaic .mark:nth-child(4) { animation-delay: 180ms; }
.mosaic .mark:nth-child(5) { animation-delay: 240ms; }
.mosaic .mark:nth-child(6) { animation-delay: 300ms; }
.mosaic .mark:nth-child(7) { animation-delay: 360ms; }
.mosaic .mark:nth-child(8) { animation-delay: 420ms; }
.mosaic .mark:nth-child(9) { animation-delay: 480ms; }
.mosaic .mark:nth-child(10) { animation-delay: 540ms; }

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mark-hero,
  .mosaic .mark {
    animation: none;
  }
}

/* Sections */

.block {
  padding: 0 0 3.5rem;
}

.feature {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem 1.5rem;
  align-items: flex-start;
  padding: 1.5rem;
  border: 1px solid var(--rule);
  border-radius: 14px;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 10%, transparent), transparent 60%),
    var(--card);
  box-shadow: var(--shadow);
}

@media (min-width: 40rem) {
  .feature {
    flex-wrap: nowrap;
    padding: 2rem;
  }
}

.feature > div {
  flex: 1 1 16rem;
  min-width: 0;
}

.feature h2,
.feature h3 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.6rem, 5vw, 2.1rem);
  line-height: 1.15;
}

.feature h2 a,
.feature h3 a {
  color: var(--ink);
  text-decoration: none;
}

.feature h2 a:hover,
.feature h3 a:hover {
  color: var(--accent);
}

.feature p {
  margin: 0;
  color: var(--ink-soft);
}

.feature .section-label {
  margin-bottom: 0.4rem;
}

.feature-small {
  margin: 0 0 4rem;
}

.feature-small h2 {
  font-size: clamp(1.4rem, 4.5vw, 1.75rem);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  margin-top: 1.25rem !important;
}

.button {
  display: inline-block;
  padding: 0.7rem 1.15rem;
  border-radius: 999px;
  background: var(--t);
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1.2;
  text-decoration: none;
}

.button:hover {
  background: color-mix(in srgb, var(--t) 85%, #000);
  color: #fff;
}

.text-link {
  font-weight: 600;
}

/* Hub cards */

.cards {
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 36rem) {
  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 58rem) {
  .cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
  }
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 1.35rem;
  border: 1px solid var(--rule);
  border-radius: 12px;
  background: var(--card);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.card:hover,
.card:focus-within {
  border-color: color-mix(in srgb, var(--accent) 55%, var(--rule));
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

@media (prefers-reduced-motion: reduce) {
  .card {
    transition: border-color 0.2s, box-shadow 0.2s;
  }

  .card:hover,
  .card:focus-within {
    transform: none;
  }
}

.card h3 {
  margin: 1rem 0 0.25rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.45rem;
  line-height: 1.2;
}

.card h3 a {
  color: var(--ink);
  text-decoration: none;
}

.card h3 a::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.card h3 a:focus-visible {
  outline: none;
}

.card:has(a:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.card p {
  margin: 0;
  color: var(--ink-soft);
}

.card .card-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-top: auto;
  padding-top: 1.1rem;
}

.domain {
  min-width: 0;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}

/* Family row on the coming-soon pages */

.family {
  margin: 0 0 3rem;
  padding: 2.5rem 0;
  border-top: 1px solid var(--rule);
  text-align: center;
}

.family h2 {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.6rem, 5vw, 2.1rem);
  line-height: 1.15;
}

.family > p:not(.section-label) {
  max-width: 34rem;
  margin: 0 auto;
  color: var(--ink-soft);
}

.family-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
  margin: 1.75rem 0 0;
  padding: 0;
  list-style: none;
}

.family-row a {
  display: block;
  border-radius: 12px;
  transition: transform 0.2s;
}

.family-row a:hover {
  transform: translateY(-3px);
}

.family-row a[aria-current="page"] {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .family-row a {
    transition: none;
  }

  .family-row a:hover {
    transform: none;
  }
}

/* Footer */

.site-footer {
  padding: 1.5rem 0 2.5rem;
  border-top: 1px solid var(--rule);
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
}

.site-footer p {
  margin: 0;
  font-weight: 600;
}

.site-footer nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Prose pages */

.prose {
  max-width: 40rem;
  padding: 3rem 0 4rem;
}

.prose h1 {
  margin: 0 0 1.5rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.2rem, 8vw, 3.25rem);
  line-height: 1.05;
}

.prose h2 {
  margin: 2rem 0 0.5rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.5rem;
  line-height: 1.2;
}

.prose p {
  margin: 0 0 1rem;
}
