@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 300 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url('/fonts/archivo-latin.woff2') format('woff2');
}

:root {
  --ground: #eceff3;
  --ink: #12151b;
  --ink-soft: #4f5866;
  --line: rgb(18 21 27 / 0.12);
  --pill: #f7f8fa;
  --solid: #12151b;
  --on-solid: #f7f8fa;
  --violet: #6a47e0;
  --pink: #efc8d9;
  --on-pink: #321723;
  --on-pink-soft: #5b4150;
  --orb: url('/img/orb-day.webp');
  --orb-opacity: 0.8;
  --panel-edge: 0 10px 24px rgb(18 21 27 / 0.16);
  --panel-rim: transparent;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: light;
}

.dark {
  --ground: #0b0d12;
  --ink: #e8ebf2;
  --ink-soft: #a3abb8;
  --line: rgb(255 255 255 / 0.12);
  --pill: #171b23;
  --solid: #e8ebf2;
  --on-solid: #0b0d12;
  --violet: #b6a2ff;
  --orb: url('/img/orb-night.webp');
  --orb-opacity: 0.55;
  --panel-edge: none;
  --panel-rim: rgb(255 255 255 / 0.12);
  color-scheme: dark;
}

[hidden] {
  display: none !important;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  scrollbar-color: var(--line) var(--ground);
}

body {
  min-height: 100dvh;
  background: var(--ground);
  color: var(--ink);
  font-family: 'Archivo', system-ui, sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--pink);
  color: var(--on-pink);
}

a {
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
  color: inherit;
  -webkit-tap-highlight-color: transparent;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--violet);
  outline-offset: 3px;
}

ul {
  list-style: none;
}

.t-es {
  display: none;
}

html[lang='es'] .t-es {
  display: inline;
}

html[lang='es'] .t-en {
  display: none;
}

.shell {
  position: relative;
  overflow-x: clip;
  width: min(100%, 30rem);
  margin: 0 auto;
  padding: max(0.75rem, env(safe-area-inset-top)) 1rem max(1.5rem, env(safe-area-inset-bottom));
}

.orb {
  position: absolute;
  z-index: -1;
  top: 3rem;
  right: -6.5rem;
  width: 15rem;
  aspect-ratio: 1;
  opacity: var(--orb-opacity);
  background: var(--orb) center / contain no-repeat;
  pointer-events: none;
}

/* Header */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 3rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.brand img {
  width: 2rem;
  height: 2rem;
}

.mark-dark,
.dark .mark-light {
  display: none;
}

.dark .mark-dark {
  display: block;
}

.controls {
  display: flex;
  gap: 0.25rem;
}

.control {
  min-width: 2.75rem;
  min-height: 2.75rem;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink-soft);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
}

.control[aria-pressed='true'] {
  color: var(--ink);
  background: var(--pill);
}

.control svg {
  width: 1.25rem;
  height: 1.25rem;
}

.control:hover {
  color: var(--ink);
}

.dark .icon-sun,
.icon-moon {
  display: none;
}

.dark .icon-moon {
  display: block;
}

.lead {
  padding: 1.25rem 0 1.25rem;
}

h1 {
  max-width: 25ch;
  font-size: clamp(1.5rem, 6.6vw, 2.75rem);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

h1 .soft {
  color: var(--ink-soft);
}

/* Products: each panel keeps its product's own colors in both themes. */

.products {
  display: grid;
  gap: 0.75rem;
}

.product {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: 100%;
  border-radius: 16px;
  background: var(--p-ground);
  color: #f2f3f7;
  text-decoration: none;
  box-shadow: var(--panel-edge);
  transition: transform 300ms var(--ease);
}

.product::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px var(--panel-rim);
  pointer-events: none;
}

.product--tally {
  --p-ground: #08080d;
  --p-accent: #a48bff;
}

.product--aldava {
  --p-ground: #0f1622;
  --p-accent: #9fdcab;
}

.product-copy {
  padding: 1.1rem 1.1rem 0.9rem;
}

.product-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.product h2 {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--p-accent);
  font-size: 0.8125rem;
  font-weight: 600;
}

.status::before {
  content: '';
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: currentColor;
}

.status--plain::before {
  content: none;
}

.product p {
  margin-top: 0.35rem;
  color: #c9cdd6;
  font-size: 0.975rem;
  line-height: 1.4;
  text-wrap: pretty;
}

.visit {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.6rem;
  color: var(--p-accent);
  font-weight: 600;
}

.visit svg {
  width: 1rem;
  height: 1rem;
  transition: transform 300ms var(--ease);
}

.shot {
  display: block;
  width: 100%;
  height: auto;
  margin-top: auto;
}

.more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  min-height: 3rem;
  margin-top: 0.25rem;
  color: var(--ink);
  font-weight: 600;
  text-underline-offset: 0.2em;
}

/* VisionarIAs */

.community {
  margin-top: 1.25rem;
  padding: 1.5rem 1.25rem;
  border-radius: 16px;
  background: var(--pink);
  color: var(--on-pink);
}

.community h2 {
  font-size: 2rem;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.community p {
  max-width: 34ch;
  margin-top: 0.5rem;
  color: var(--on-pink-soft);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.65rem 1.4rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--solid);
  color: var(--on-solid);
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.community .button {
  margin-top: 1.1rem;
  background: var(--on-pink);
  color: #fdf7fa;
}

.button--line {
  background: transparent;
  border-color: var(--line);
  color: var(--ink);
}

/* Gio */

.person {
  margin-top: 2.25rem;
}

.person h2 {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.person > p {
  margin-top: 0.15rem;
  color: var(--ink-soft);
}

.person .button-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-top: 1rem;
}

.quiet {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1rem;
  margin-top: 0.5rem;
}

.quiet a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--ink-soft);
  text-decoration: none;
}

.quiet a:hover {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

/* QR and footer */

.qr {
  margin-top: 1.5rem;
  border-top: 1px solid var(--line);
}

.qr summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 3.25rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.qr summary::-webkit-details-marker {
  display: none;
}

.qr summary svg {
  width: 1.1rem;
  height: 1.1rem;
  color: var(--ink-soft);
  transition: transform 300ms var(--ease);
}

.qr[open] summary svg {
  transform: rotate(180deg);
}

.qr ul {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  padding-bottom: 1rem;
}

.qr li {
  font-size: 0.875rem;
  text-align: center;
}

.qr img {
  display: block;
  width: 100%;
  max-width: 10rem;
  height: auto;
  margin: 0 auto 0.4rem;
  border-radius: 8px;
}

.qr a[download] {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--ink-soft);
}

.foot {
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.875rem;
}

.foot p {
  color: var(--ink);
  font-weight: 600;
}

.foot .quiet {
  margin: 0 0 0.5rem;
}

.foot small {
  font-size: inherit;
}

/* VisionarIAs page */

.gate {
  display: grid;
  min-height: 100dvh;
  place-items: center;
  padding: 1rem;
  background: var(--pink);
  color: var(--on-pink);
}

.gate main {
  width: min(100%, 26rem);
}

.gate h1 {
  font-size: clamp(2.75rem, 13vw, 3.75rem);
  font-weight: 600;
}

.gate p {
  margin-top: 0.75rem;
  color: var(--on-pink-soft);
  font-size: 1.125rem;
}

.gate h2 {
  margin-top: 2rem;
  font-size: 1.25rem;
  font-weight: 600;
}

.gate .actions {
  display: grid;
  gap: 0.5rem;
  margin-top: 0.9rem;
}

.gate .button {
  width: 100%;
  background: var(--on-pink);
  color: #fdf7fa;
}

.gate .button--line {
  background: transparent;
  border-color: rgb(50 23 35 / 0.35);
  color: var(--on-pink);
}

.gate a:focus-visible,
.gate button:focus-visible {
  outline-color: var(--on-pink);
}

/* Motion: the panels settle into place when the page opens after a tap. */

@media (prefers-reduced-motion: no-preference) {
  .orb {
    animation: drift 14s ease-in-out infinite alternate;
  }

  .products li {
    animation: settle 700ms var(--ease) backwards;
  }

  .products li + li {
    animation-delay: 90ms;
  }

  .button,
  .control {
    transition: transform 160ms var(--ease);
  }

  .product:active,
  .button:active,
  .control:active {
    transform: scale(0.98);
  }

  @media (hover: hover) {
    .product:hover {
      transform: translateY(-3px);
    }

    .product:hover .visit svg {
      transform: translate(2px, -2px);
    }

    .button:hover {
      opacity: 0.88;
    }
  }
}

@keyframes settle {
  from {
    transform: translateY(1.25rem);
  }
}

@keyframes drift {
  to {
    transform: translate(-0.75rem, 0.75rem) scale(1.04);
  }
}

@media (max-width: 22rem) {
  .brand {
    gap: 0.35rem;
    font-size: 0.9rem;
  }

  .brand img {
    width: 1.5rem;
    height: 1.5rem;
  }

  .controls {
    gap: 0;
  }
}

/* Wider screens */

@media (min-width: 48rem) {
  .shell {
    width: min(100%, 58rem);
    padding-inline: 2rem;
  }

  .orb {
    top: 3.5rem;
    right: 2rem;
    width: 17rem;
  }

  .lead {
    padding: 3rem 0 2.5rem;
  }

  .products {
    grid-template-columns: 1fr 1fr;
  }

  .lower {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: start;
    gap: 2rem;
  }

  .person {
    margin-top: 1.25rem;
  }

  .qr ul {
    grid-template-columns: repeat(4, 1fr);
  }
}
