:root {
  color-scheme: dark;
  --navy: #031c42;
  --navy-deep: #011637;
  --blue: #006ab8;
  --ice: #8bc8ff;
  --border: rgba(136, 192, 247, .23);
  --ease: cubic-bezier(.2, .8, .2, 1);
}

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

html { min-height: 100%; background: var(--navy-deep); }

body {
  min-width: 320px;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(ellipse 100% 115% at -10% -15%, rgba(0, 126, 213, .75) 0%, rgba(0, 82, 160, .52) 32%, transparent 75%),
    radial-gradient(ellipse 76% 90% at 12% 94%, rgba(0, 76, 150, .42), transparent 75%),
    linear-gradient(106deg, #064e89 0%, #043b70 35%, #031c42 74%, #011634 100%);
  font-family: Arial, Helvetica, sans-serif;
}

/* Aura em movimento lento; nunca cobre ou altera as artes. */
.ambient {
  position: fixed;
  z-index: 0;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.ambient__glow {
  position: absolute;
  display: block;
  border-radius: 50%;
  filter: blur(72px);
  will-change: transform;
}

.ambient__glow--left {
  width: 54vw;
  height: 60vh;
  left: -29vw;
  top: -23vh;
  background: radial-gradient(ellipse, rgba(0, 148, 255, .44), rgba(0, 89, 191, .14) 55%, transparent 73%);
  animation: breathe 17s ease-in-out infinite alternate;
}

.ambient__glow--center {
  width: 62vw;
  height: 82vh;
  left: 23%;
  top: 12%;
  background: radial-gradient(ellipse, rgba(7, 101, 201, .17), transparent 70%);
  animation: wander 22s ease-in-out infinite alternate;
}

.ambient__glow--bottom {
  width: 50vw;
  height: 50vh;
  left: -16vw;
  bottom: -25vh;
  background: radial-gradient(ellipse, rgba(17, 112, 212, .24), transparent 70%);
  animation: breathe 20s ease-in-out infinite alternate-reverse;
}

.ambient__light {
  position: absolute;
  width: 1px;
  height: 85vh;
  left: 50%;
  top: -40vh;
  transform: rotate(-27deg);
  box-shadow: 0 0 95px 64px rgba(81, 164, 255, .042);
  opacity: .7;
}

/* Uma coluna de artes grandes, como pequenos painéis de destaque. */
.page {
  position: relative;
  z-index: 1;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  justify-content: center;
  padding: clamp(46px, 8vh, 96px) 24px clamp(72px, 12vh, 150px);
}

.links {
  width: min(100%, 940px);
  display: flex;
  flex-direction: column;
  gap: clamp(22px, 2.9vw, 34px);
}

.link-card {
  --mx: 50%;
  --my: 50%;
  --rx: 0deg;
  --ry: 0deg;
  position: relative;
  display: block;
  width: 100%;
  border-radius: clamp(18px, 2vw, 28px);
  overflow: hidden;
  isolation: isolate;
  border: 1px solid var(--border);
  background: rgba(2, 19, 46, .72);
  box-shadow:
    0 25px 48px -24px rgba(0, 9, 33, .64),
    0 3px 9px rgba(1, 11, 36, .23),
    inset 0 1px 0 rgba(201, 230, 255, .09);
  text-decoration: none;
  outline-offset: 6px;
  transform: translateZ(0);
  transition:
    transform .5s var(--ease),
    box-shadow .5s var(--ease),
    border-color .38s ease,
    filter .5s var(--ease);
  animation: rise-in .85s var(--ease) backwards;
  animation-delay: var(--delay, 80ms);
}

.link-card picture {
  display: block;
  width: 100%;
}

.link-card img {
  display: block;
  width: 100%;
  height: auto;
  /* Não aplica zoom às imagens para não cortar logos nem textos das artes. */
  user-select: none;
  -webkit-user-drag: none;
}

/* Brilho espalhado pelo cursor na superfície. */
.link-card::after {
  content: "";
  position: absolute;
  z-index: 2;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    500px circle at var(--mx) var(--my),
    rgba(140, 205, 255, .17) 0%,
    rgba(97, 176, 254, .06) 32%,
    transparent 68%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity .32s ease;
}

/* Contorno luminoso bem próximo ao mouse. */
.link-card::before {
  content: "";
  position: absolute;
  z-index: 3;
  inset: 0;
  padding: 2px;
  border-radius: inherit;
  background: radial-gradient(
    350px circle at var(--mx) var(--my),
    rgba(225, 246, 255, .98),
    rgba(72, 171, 255, .65) 32%,
    transparent 74%
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask-composite: exclude;
  opacity: 0;
  pointer-events: none;
  transition: opacity .32s ease;
}

@media (hover: hover) and (pointer: fine) {
  .link-card:hover {
    border-color: rgba(145, 211, 255, .5);
    transform: perspective(1400px) translateY(-9px) scale(1.016) rotateX(var(--rx)) rotateY(var(--ry));
    box-shadow:
      0 42px 80px -27px rgba(0, 9, 33, .83),
      0 0 52px -18px rgba(79, 167, 255, .45),
      inset 0 1px 0 rgba(201, 230, 255, .14);
  }

  .link-card:hover::before,
  .link-card:hover::after { opacity: 1; }
}

.link-card:focus-visible {
  outline: 3px solid var(--ice);
  border-color: var(--ice);
  box-shadow: 0 0 0 7px rgba(90, 176, 255, .16);
}

.link-card:active { transform: translateY(-2px) scale(.995); }

@keyframes rise-in {
  from { opacity: 0; transform: translateY(35px) scale(.97); filter: blur(8px); }
  to { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

@keyframes breathe {
  from { transform: translate3d(-3%, -1%, 0) scale(.94); opacity: .72; }
  to { transform: translate3d(6%, 7%, 0) scale(1.15); opacity: 1; }
}

@keyframes wander {
  from { transform: translate3d(0, 3%, 0) scale(.92); }
  to { transform: translate3d(-14%, -6%, 0) scale(1.2); }
}

@media (max-width: 760px) {
  .page { padding: 40px 18px 76px; }
  .links { gap: 22px; }
  .link-card { border-radius: 17px; }
  .ambient__glow--left { width: 95vw; left: -60vw; }
  .ambient__glow--center { width: 100vw; left: 10vw; }
}

@media (max-width: 420px) {
  .page { padding: 30px 13px 54px; }
  .links { gap: 17px; }
  .link-card { border-radius: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}
