:root {
  color-scheme: light dark;
  --bg: #F5F2EC;
  --ink: #1B1814;
  --ink-2: #5E574D;
  --line: rgba(27, 24, 20, 0.12);
  --blob-a: #E9A27C;
  --blob-b: #FF8A9A;
  --blob-c: #E3C77A;
  --blob-d: #8FB0F5;
  --blob-opacity: 0.55;
  --rot-a: #B8562F;
  --rot-b: #C2304A;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0D0C10;
    --ink: #F4EFE6;
    --ink-2: #A8A095;
    --line: rgba(244, 239, 230, 0.12);
    --blob-a: #C97952;
    --blob-b: #C2304A;
    --blob-c: #8F7420;
    --blob-d: #2A54AE;
    --blob-opacity: 0.4;
    --rot-a: #F0A27A;
    --rot-b: #FF7A8E;
  }
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; }
.ic { width: 1em; height: 1em; vertical-align: -0.15em; }

.aurora {
  position: absolute;
  inset: 0 0 auto 0;
  height: 760px;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
  mask-image: linear-gradient(180deg, #000 40%, transparent);
  -webkit-mask-image: linear-gradient(180deg, #000 40%, transparent);
}
.aurora::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.5 0 0 0 0 0.5 0 0 0 0 0.5 0 0 0 0.55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.35;
  mix-blend-mode: overlay;
}
.aurora span {
  position: absolute;
  width: 46vmax;
  height: 46vmax;
  border-radius: 50%;
  filter: blur(80px);
  opacity: var(--blob-opacity);
  animation: drift 26s ease-in-out infinite alternate;
}
.aurora span:nth-child(1) { background: var(--blob-a); top: -22vmax; left: -12vmax; }
.aurora span:nth-child(2) { background: var(--blob-b); top: -26vmax; right: -14vmax; animation-delay: -9s; animation-duration: 31s; }
.aurora span:nth-child(3) { background: var(--blob-c); top: -6vmax; left: 22%; width: 30vmax; height: 30vmax; animation-delay: -17s; animation-duration: 37s; }
.aurora span:nth-child(4) { background: var(--blob-d); top: 2vmax; right: 4%; width: 34vmax; height: 34vmax; animation-delay: -5s; animation-duration: 33s; animation-direction: alternate-reverse; }
@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(6vmax, 5vmax, 0) scale(1.12); }
}

.intro, main, footer { position: relative; z-index: 1; }

.intro {
  max-width: 1080px;
  margin: 0 auto;
  padding: clamp(88px, 16vw, 168px) 20px 64px;
}
.eyebrow {
  margin: 0 0 18px;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.intro h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(56px, 12vw, 132px);
  line-height: 0.92;
  letter-spacing: -0.055em;
  margin: 0;
}
.lead {
  font-family: var(--display);
  font-size: clamp(20px, 2.6vw, 26px);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.4;
  max-width: 640px;
  margin: 28px 0 0;
  color: var(--ink-2);
}
.now {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  padding: 0;
  margin: 24px 0 0;
  font-size: 16px;
  font-weight: 650;
}
.now li { display: flex; align-items: center; gap: 8px; }
.now li::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #34C759;
  box-shadow: 0 0 0 4px color-mix(in srgb, #34C759 22%, transparent);
}
.now li + li::before { background: var(--ink-2); box-shadow: none; }
.now span { color: var(--ink-2); font-weight: 500; }
.now a { text-decoration: none; border-bottom: 1px solid var(--line); transition: border-color 0.2s; }
.now a:hover { border-color: currentColor; }
.cta .logo { width: 1.05em; height: 1.05em; }
.ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 32px 0 0;
}
.cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 55%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-weight: 650;
  font-size: 15px;
  text-decoration: none;
  transition: transform 0.2s, background 0.2s;
}
.cta:hover { transform: translateY(-2px); }
.cta.primary { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 14px clamp(28px, 5vw, 56px);
  margin: 44px 0 0;
}
.stats div {
  display: grid;
  gap: 4px;
  animation: rise 0.8s cubic-bezier(.2, .8, .2, 1) both;
  animation-delay: calc(var(--i) * 0.07s + 0.15s);
}
.stats dt {
  font-family: var(--display);
  font-size: clamp(40px, 6vw, 60px);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.stats dd {
  margin: 0;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-2);
}

main {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 16px 40px;
}
.section-title {
  font-size: 13px;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin: 0 4px 18px;
}
.apps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  align-items: start;
  padding-bottom: 120px;
}
.app:nth-child(even) { translate: 0 120px; }

.app {
  --ink-on: #FBF4EA;
  --pad: clamp(24px, 4.5vw, 48px);
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(24px, 4vw, 40px);
  gap: 8px;
  padding: var(--pad);
  border-radius: 28px;
  color: var(--ink-on);
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset, 0 24px 60px -24px rgba(0, 0, 0, 0.45);
  transition: transform 0.35s cubic-bezier(.2, .8, .2, 1), box-shadow 0.35s;
  animation: rise 0.8s cubic-bezier(.2, .8, .2, 1) both;
  animation-delay: calc(var(--i) * 0.08s + 0.1s);
}
.app::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--card);
}
.app::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(120% 90% at 0% 0%, rgba(255, 255, 255, 0.16), transparent 55%);
}
.spot {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.18), transparent 60%);
  transition: opacity 0.4s;
}
.app:hover .spot { opacity: 1; }
.app:hover { transform: translateY(-4px); box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08) inset, 0 34px 70px -24px rgba(0, 0, 0, 0.55); }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }

.app[data-app="arkive"] { --card: linear-gradient(135deg, #C97952 0%, #7A5540 52%, #3B2D23 100%); --pill: #FAF3E8; }
.app[data-app="pyllar"] { --card: linear-gradient(135deg, #3B6FD8 0%, #1E4596 50%, #0C1630 100%); --pill: #F2F6FF; }
.app[data-app="tyde"] { --card: linear-gradient(135deg, #FF6B7A 0%, #8E2F52 48%, #14121F 100%); --pill: #FBEEF0; }
.app[data-app="whispercourt"] { --card: linear-gradient(135deg, #5A4129 0%, #2C2017 50%, #120E0B 100%); --pill: #E9DCC0; --ink-on: #EFE3C8; }
.app[data-app="whispercourt"] .kind { color: #D9B648; }

.app-icon { position: relative; display: block; width: 76px; flex: none; aspect-ratio: 1; }
.app-art { display: grid; place-items: center; }
.app-art { padding-block: 24px 8px; }
.app-art .app-icon { width: 190px; }
.app-icon img {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 22.5%;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.4);
  transform: perspective(700px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform 0.6s cubic-bezier(.2, .8, .2, 1);
}
.app-icon img.glow {
  position: absolute;
  inset: 0;
  filter: blur(32px) saturate(1.6);
  opacity: 0.75;
  transform: scale(1.08) translateY(10px);
  box-shadow: none;
}
.app:hover .app-icon img:not(.glow) { transition-duration: 0.15s; }

.app-body { min-width: 0; }
.app-head { display: flex; align-items: center; gap: 18px; margin-bottom: 16px; }
.app-head .kind { margin-bottom: 8px; }
.app-head h3 { margin: 0; }

.app-shots {
  position: relative;
  display: block;
  min-height: 300px;
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform 0.6s cubic-bezier(.2, .8, .2, 1);
}
.app-shots video { aspect-ratio: 1206 / 2622; object-fit: cover; background: #000; }
.app-shots > * {
  --x: 0px; --y: 0px; --r: 0deg;
  position: absolute;
  left: 50%;
  bottom: calc(var(--pad) * -1 - 44px);
  width: 146px;
  height: auto;
  border-radius: 20px;
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.45);
  transform-origin: 50% 100%;
  transform: translateX(-50%) translate(var(--x), var(--y)) rotate(var(--r));
  transition: transform 0.6s cubic-bezier(.2, .8, .2, 1);
}
.app-shots > :nth-child(1) { --x: -82px; --r: -10deg; }
.app-shots > :nth-child(2) { --y: -22px; z-index: 2; }
.app-shots > :nth-child(3) { --x: 82px; --r: 10deg; }
.app:hover .app-shots > :nth-child(1) { --x: -112px; --y: -10px; --r: -14deg; }
.app:hover .app-shots > :nth-child(2) { --y: -44px; }
.app:hover .app-shots > :nth-child(3) { --x: 112px; --y: -10px; --r: 14deg; }
.app-shots.landscape > * { width: 300px; border-radius: 16px; }
.app-shots.landscape > *:nth-child(1) { --x: -26px; --y: -118px; --r: -5deg; }
.app-shots.landscape > *:nth-child(2) { --x: 22px; --y: -6px; --r: 3deg; }
.app:hover .app-shots.landscape > *:nth-child(1) { --x: -44px; --y: -138px; --r: -7deg; }
.app:hover .app-shots.landscape > *:nth-child(2) { --x: 36px; --y: -14px; --r: 4deg; }

.rotator {
  display: inline-grid;
  vertical-align: bottom;
  font-weight: 700;
}
.rotator span {
  grid-area: 1 / 1;
  background: linear-gradient(90deg, var(--rot-a), var(--rot-b));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  opacity: 0;
  transform: translateY(0.45em);
  transition: opacity 0.45s, transform 0.45s cubic-bezier(.2, .8, .2, 1);
}
.rotator span.on { opacity: 1; transform: none; }
.rotator span.out { opacity: 0; transform: translateY(-0.45em); }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.ticker {
  position: relative;
  z-index: 1;
  overflow: hidden;
  padding-block: 8px;
  margin: 0 0 64px;
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.ticker-track {
  display: flex;
  align-items: center;
  width: max-content;
  animation: marquee 60s linear infinite;
}
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker span {
  font-family: var(--display);
  font-size: clamp(34px, 6vw, 64px);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1.1;
  white-space: nowrap;
  padding-inline: 24px;
  color: transparent;
  -webkit-text-stroke: 1.2px var(--ink-2);
}
.ticker span:nth-of-type(3n + 1) { color: var(--ink); -webkit-text-stroke: 0; }
.ticker i {
  flex: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--blob-a);
}
.ticker i:nth-of-type(3n + 2) { background: var(--blob-b); }
.ticker i:nth-of-type(3n) { background: #3B6FD8; }
@keyframes marquee { to { transform: translateX(-50%); } }
.kind {
  margin: 0 0 6px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.8;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
}
.status {
  font-size: 10.5px;
  letter-spacing: 0.1em;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}
.app h3 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(36px, 5vw, 52px);
  letter-spacing: -0.04em;
  line-height: 1;
  margin: 0 0 14px;
}
.app h3 a { text-decoration: none; }
.tagline {
  font-family: var(--display);
  font-size: clamp(18px, 2.2vw, 21px);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.35;
  margin: 0 0 12px;
}
.about {
  font-size: 15px;
  line-height: 1.6;
  margin: 0 0 18px;
  opacity: 0.82;
  max-width: 560px;
}
.facts {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0;
  margin: 0 0 24px;
}
.facts li {
  font-size: 12px;
  font-weight: 650;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.16);
}
.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
}
.store {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  background: var(--pill);
  color: #15120F;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s;
}
a.store:hover { transform: translateY(-2px); }
.store.soon {
  background: rgba(255, 255, 255, 0.10);
  color: inherit;
  border: 1px dashed rgba(255, 255, 255, 0.35);
  box-shadow: none;
  font-weight: 600;
}
.facts li.more { background: none; border-style: dashed; }
.secondary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 650;
  text-decoration: none;
  padding: 10px 14px;
  border-radius: 999px;
  opacity: 0.9;
  transition: background 0.2s, opacity 0.2s;
}
a.secondary:hover { background: rgba(255, 255, 255, 0.14); opacity: 1; }
.secondary.soon { opacity: 0.7; font-weight: 600; }

.skills { margin-top: 72px; }
.skill-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: 16px;
}
.skill {
  padding: 24px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: color-mix(in srgb, var(--ink) 3%, transparent);
}
.skill h3 {
  font-family: var(--display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
}
.skill-chips {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0;
  margin: 0;
}
.skill-chips li {
  font-size: 13px;
  font-weight: 600;
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--ink-2);
}

.contact {
  margin: 72px 4px 24px;
  padding-top: 40px;
  border-top: 1px solid var(--line);
}
.contact h2 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(30px, 4vw, 40px);
  letter-spacing: -0.035em;
  margin: 0 0 10px;
}
.contact .ctas { margin-top: 0; }
.contact p { color: var(--ink-2); font-size: 17px; line-height: 1.55; margin: 0 0 18px; max-width: 560px; }
.mail {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 650;
  font-size: 17px;
  text-decoration: none;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid var(--line);
  transition: background 0.2s;
}
.mail:hover { background: color-mix(in srgb, var(--ink) 7%, transparent); }

footer {
  text-align: center;
  padding: 24px 20px 56px;
  color: var(--ink-2);
  font-size: 13px;
}
footer p { margin: 4px 0; }
footer a { color: var(--ink-2); }
footer .fine { opacity: 0.7; }

@media (max-width: 820px) {
  .apps { grid-template-columns: minmax(0, 1fr); padding-bottom: 0; }
  .app:nth-child(even) { translate: none; }
}

@media (max-width: 680px) {
  .ctas { gap: 8px; }
  .cta { padding: 10px 14px; font-size: 14px; gap: 6px; }
  .app { border-radius: 24px; }
  .app-head .app-icon { width: 60px; }
  .app-art .app-icon { width: 150px; }
  .app-icon img.glow { filter: blur(22px) saturate(1.6); }
  .app-shots { min-height: 250px; }
  .app-shots > * { width: 122px; border-radius: 16px; }
  .app-shots > :nth-child(1) { --x: -74px; }
  .app-shots > :nth-child(3) { --x: 74px; }
  .app-shots.landscape { min-height: 290px; }
  .app-shots.landscape > * { width: min(250px, 70vw); }
  .app-shots.landscape > *:nth-child(1) { --x: -18px; --y: -104px; }
  .app-shots.landscape > *:nth-child(2) { --x: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .aurora span, .app, .stats div, .ticker-track { animation: none; }
  .app, .app-icon img, .store, .app-shots, .app-shots > *, .rotator span { transition: none; }
}
