/* The ai1.place homepage. Same system as /advisor/style.css and /love-lock/style.css: each app
   keeps its own accent, and neither owns the page. */

:root {
  color-scheme: light dark;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --bg: light-dark(#f2f2f7, #1c1c1e);
  --card: light-dark(#ffffff, #2c2c2e);
  --text: light-dark(#1c1c1e, #f2f2f7);
  --muted: light-dark(rgba(28, 28, 30, 0.68), rgba(242, 242, 247, 0.68));
  --faint: light-dark(rgba(28, 28, 30, 0.45), rgba(242, 242, 247, 0.45));
  --badge: light-dark(#e3e3e8, #3a3a3c);
  --line: light-dark(rgba(0, 0, 0, 0.08), rgba(255, 255, 255, 0.08));
  --shadow: light-dark(rgba(0, 0, 0, 0.14), rgba(0, 0, 0, 0.5));
  /* Each app's accent, as its own pages use it: a solid for buttons, a link color with 4.5:1
     contrast, and a soft tint behind its screenshot. */
  --advisor: #0a84ff;
  --advisor-link: light-dark(#0062cc, #4da3ff);
  --advisor-tint: light-dark(#e6f0ff, #1b2838);
  --love-lock: #ed1b26;
  --love-lock-link: light-dark(#c4111b, #ff6b73);
  --love-lock-tint: light-dark(#fde8e9, #3a1f22);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-size: 17px;
  line-height: 1.5;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a,
a:visited {
  color: var(--text);
}

:focus-visible {
  outline: 2px solid var(--advisor);
  outline-offset: 3px;
}

/* Advisor's LED stripe on the left, Love Lock's red on the right. */
.ribbon {
  display: flex;
  height: 6px;
}

.ribbon > span {
  flex: 1;
}

.leds {
  display: flex;
}

.leds span {
  flex: 1;
}

.hearts {
  background: linear-gradient(90deg, #8c1019, var(--love-lock) 50%, #ec3f7a);
}

.wrap {
  width: min(1080px, calc(100% - 40px));
  margin: 0 auto;
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 0 8px;
}

.wordmark,
.wordmark:visited {
  color: var(--text);
  text-decoration: none;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

header nav {
  display: flex;
  gap: 18px;
}

header nav a,
header nav a:visited {
  color: var(--muted);
  text-decoration: none;
  font-size: 15px;
}

header nav a:hover {
  color: var(--text);
}

.intro {
  padding: 36px 0 36px;
}

h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 50px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  max-width: 18ch;
}

.lede {
  margin: 16px 0 0;
  max-width: 40rem;
  color: var(--muted);
  font-size: 18px;
}

/* Two apps, side by side, built the same way. */

.apps {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  padding-bottom: 56px;
}

.app {
  --accent: var(--advisor);
  --link: var(--advisor-link);
  --tint: var(--advisor-tint);
  display: flex;
  flex-direction: column;
  padding: 24px;
  border-radius: 20px;
  background: var(--card);
  box-shadow: 0 0 0 1px var(--line);
}

.app.love-lock {
  --accent: var(--love-lock);
  --link: var(--love-lock-link);
  --tint: var(--love-lock-tint);
}

.app-head {
  display: flex;
  align-items: center;
  gap: 14px;
}

.app-icon {
  width: 64px;
  height: 64px;
  flex: none;
  border-radius: 15px;
  box-shadow: 0 6px 16px var(--shadow);
}

.eyebrow {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

h2 {
  margin: 0;
  font-size: 28px;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.pitch {
  margin: 16px 0 0;
  color: var(--muted);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.tags li {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 4px 10px 4px 4px;
  border-radius: 9px;
  background: var(--badge);
  font-size: 14px;
  font-weight: 600;
}

/* Both badges in a tag are the same 26px square: a robot face on Advisor's dark keycap, or an
   emoji on Love Lock's tint. */
.tags .face,
.tags .emoji {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 6px;
}

.tags .face {
  background: #1c1c1e;
}

.tags .face img {
  width: 22px;
  height: 22px;
}

.tags .emoji {
  background: var(--tint);
  font-size: 15px;
  line-height: 1;
}

/* The top of each app's hero screenshot, on its tint, fading out at the bottom. */
.preview {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  height: 320px;
  margin: 22px 0 0;
  padding-top: 26px;
  overflow: hidden;
  border-radius: 14px;
  background: var(--tint);
  -webkit-mask-image: linear-gradient(180deg, #000 72%, transparent);
  mask-image: linear-gradient(180deg, #000 72%, transparent);
}

.preview .window,
.preview .devices {
  flex: none;
}

.preview .window {
  width: min(340px, 100%);
  /* The shot's own transparent shadow margin already spaces it from the top. */
  margin-top: -16px;
}

.preview .phone {
  display: block;
  width: 220px;
  height: max-content;
  padding: 6px;
  border-radius: 34px;
  background: #1c1c1e;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.1),
    0 16px 36px var(--shadow);
}

.preview .phone img {
  border-radius: 28px;
}

/* Love Lock's Apple Watch, overlapping the phone's right edge beside the clock. The pair stays
   centered, so it fits the narrowest card. */
.preview .devices {
  display: flex;
  align-items: flex-start;
}

.preview .devices > * {
  flex: none;
}

.preview .watch {
  position: relative;
  display: block;
  width: 116px;
  margin: 112px 0 0 -30px;
  padding: 7px;
  border-radius: 34px / 30px;
  background: #0b0b0c;
  box-shadow:
    inset 0 0 0 2px #8e8e93,
    0 14px 30px var(--shadow);
}

/* The Digital Crown. */
.preview .watch::after {
  content: "";
  position: absolute;
  top: 28%;
  right: -4px;
  width: 4px;
  height: 22%;
  border-radius: 0 3px 3px 0;
  background: #8e8e93;
}

.preview .watch img {
  border-radius: 26px / 22px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  margin: 22px 0 0;
  font-size: 15px;
}

.actions a,
.actions a:visited {
  color: var(--link);
  font-weight: 600;
}

.actions span {
  color: var(--muted);
  font-weight: 600;
}

.actions .button,
.actions .button:visited {
  padding: 10px 18px;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
}

.actions .button:hover {
  filter: brightness(0.92);
}

footer {
  padding: 8px 0 40px;
  color: var(--faint);
  font-size: 13px;
}

footer p {
  margin: 0 0 6px;
}

footer a,
footer a:visited {
  color: var(--muted);
}

@media (max-width: 860px) {
  .apps {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .wrap {
    width: calc(100% - 32px);
  }

  .intro {
    padding: 24px 0 28px;
  }

  .app {
    padding: 18px;
  }

  .preview {
    height: 280px;
  }
}
