:root {
  --bg: #131416;
  --text: #8b8d92;
  --text-dim: #55565b;
  --text-bright: #e2e3e6;
  --bubble-bg: #2e3036;
  --bubble-border: #45474e;
}

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

/* Landing page */

.landing {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.prompt {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  gap: 0;
}

.lead {
  font-size: clamp(2.25rem, 7vw, 4.5rem);
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.dots {
  display: inline-flex;
  align-items: baseline;
}

.dot-wrap {
  position: relative;
  display: inline-block;
}

.dot {
  appearance: none;
  background: none;
  border: none;
  padding: 0 0.06em;
  margin: 0;
  font-family: inherit;
  font-weight: inherit;
  font-size: clamp(2.25rem, 7vw, 4.5rem);
  color: var(--text);
  cursor: pointer;
  transition: color 0.2s ease;
  line-height: 1;
}

.dot-wrap:hover .dot,
.dot-wrap:focus-within .dot,
.dot-wrap.active .dot {
  color: var(--text-bright);
}

/* Thought bubble: a cloud-shaped bubble fed by a trail of small
   "crumbs" rising from the dot, each popping in with its own delay so
   the whole thing reads as one thought forming. */

.thought-trail {
  position: absolute;
  left: 50%;
  bottom: 100%;
  width: 0;
  height: 0;
  pointer-events: none;
}

.thought-crumb {
  position: absolute;
  left: 50%;
  border-radius: 50%;
  background: var(--bubble-bg);
  border: 1px solid var(--bubble-border);
  transform: translate(-50%, 0) scale(0);
  opacity: 0;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.2s ease;
}

.thought-crumb-1 {
  width: 6px;
  height: 6px;
  bottom: 6px;
}

.thought-crumb-2 {
  width: 9px;
  height: 9px;
  bottom: 16px;
  left: calc(50% + 3px);
}

.thought-crumb-3 {
  width: 13px;
  height: 13px;
  bottom: 29px;
  left: calc(50% + 7px);
}

.bubble {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 46px);
  transform: translate(-50%, 10px) scale(0.4);
  transform-origin: 30% 100%;
  display: block;
  white-space: nowrap;
  background: var(--bubble-bg);
  border: 1px solid var(--bubble-border);
  border-radius: 42% 46% 48% 44% / 58% 52% 60% 54%;
  padding: 16px 24px;
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: normal;
  color: var(--text-bright);
  text-decoration: none;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.32s cubic-bezier(0.34, 1.56, 0.64, 1);
  transition-delay: 0s;
  z-index: 10;
}

.bubble-text {
  position: relative;
  z-index: 1;
}

.dot-wrap:hover .thought-crumb,
.dot-wrap:focus-within .thought-crumb,
.dot-wrap.active .thought-crumb {
  transform: translate(-50%, 0) scale(1);
  opacity: 1;
}

.dot-wrap:hover .thought-crumb-1,
.dot-wrap:focus-within .thought-crumb-1,
.dot-wrap.active .thought-crumb-1 {
  transition-delay: 0s;
}

.dot-wrap:hover .thought-crumb-2,
.dot-wrap:focus-within .thought-crumb-2,
.dot-wrap.active .thought-crumb-2 {
  transition-delay: 0.05s;
}

.dot-wrap:hover .thought-crumb-3,
.dot-wrap:focus-within .thought-crumb-3,
.dot-wrap.active .thought-crumb-3 {
  transition-delay: 0.09s;
}

.dot-wrap:hover .bubble,
.dot-wrap:focus-within .bubble,
.dot-wrap.active .bubble {
  opacity: 1;
  transform: translate(-50%, 0) scale(1);
  pointer-events: auto;
  transition-delay: 0.16s;
}

/* Identity pages */

.page {
  max-width: 640px;
  margin: 0 auto;
  padding: 4rem 1.5rem 6rem;
}

.page .back {
  display: inline-block;
  margin-bottom: 3rem;
  color: var(--text-dim);
  text-decoration: none;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  transition: color 0.2s ease;
}

.page .back:hover {
  color: var(--text-bright);
}

.page h1 {
  color: var(--text-bright);
  font-weight: 400;
  font-size: clamp(2rem, 5vw, 2.75rem);
  letter-spacing: 0.02em;
  margin: 0 0 1rem;
}

.page .intro {
  font-size: 1.15rem;
  color: var(--text);
  margin: 0 0 2rem;
}

.page .content {
  font-weight: 300;
  line-height: 1.7;
  color: var(--text);
}

.page .content p {
  margin: 0 0 1.25rem;
}
