@font-face {
  font-family: 'Brownhill';
  src: url('../fonts/Brownhill.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'Roboto';
  src: url('../fonts/Roboto-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'WireOne';
  src: url('../fonts/WireOne-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

:root {
  --bg-1: #050816;
  --bg-2: #10182d;
  --panel: rgba(15, 24, 42, 0.72);
  --panel-border: rgba(167, 197, 255, 0.35);
  --text: #edf6ff;
  --muted: rgba(237, 246, 255, 0.74);
  --accent: #7ce7ff;
  --accent-2: #a06bff;
  --shadow: rgba(6, 10, 20, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body,
html,
#app {
  margin: 0;
  width: 100%;
  min-height: 100%;
}

body {
  min-height: 100vh;
  font-family: "Roboto", sans-serif;
  font-size: 18px;
  color: var(--text);
  background: linear-gradient(160deg, var(--bg-1) 0%, var(--bg-2) 100%);
  touch-action: manipulation;
}

#app {
  position: relative;
  min-height: 100vh;
  font-family: "Roboto", sans-serif;
}

#canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 0;
  pointer-events: none;
}

.page-shell {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 1.25rem));
  margin: 0 auto;
  padding: 2rem 0 4rem;
}

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.8rem;
  padding: 2rem 0 1.5rem;
}

.eyebrow {
  margin: 0;
  font-size: 0.7rem;
  letter-spacing: 0.35rem;
  text-transform: uppercase;
  color: var(--accent);
  opacity: 0.9;
}

h1,
h2 {
  margin: 0;
  font-family: "WireOne";
  font-weight: normal;
  color: #fff;
  text-shadow: 0 0 24px rgba(0, 0, 0, 0.8);
}

h1 {
  font-size: clamp(5rem, 10vw, 8rem);
  line-height: 0.95;
}

h2 {
  font-size: clamp(3rem, 7vw, 5rem);
  line-height: 1;
}

.email-copy-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.75rem;
}

.email-copy-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100px;
  height: 100px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 50%;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.email-copy-button:hover,
.email-copy-button:focus-visible {
  transform: translateY(-1px) scale(1.04);
  border-color: rgba(124, 231, 255, 0.4);
  background: rgba(124, 231, 255, 0.06);
  box-shadow: 0 0 0 6px rgba(124, 231, 255, 0.06);
}

.email-copy-button svg {
  width: 100px;
  height: 100px;
  stroke: #eaf8ff;
  fill: none;
  stroke-width: 1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.copy-tooltip {
  position: absolute;
  bottom: calc(100% + 0.7rem);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  background: rgba(14, 20, 34, 0.96);
  color: var(--text);
  border: 1px solid rgba(124, 231, 255, 0.4);
  border-radius: 0.7rem;
  padding: 0.6rem 0.8rem;
  font-size: 0.82rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  box-shadow: 0 12px 28px rgba(5, 10, 20, 0.35);
}

.email-copy-wrap.is-visible .copy-tooltip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.hero p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(0.95rem, 2vw, 1.08rem);
  line-height: 1.65;
  text-shadow: 0 0 18px rgba(0, 0, 0, 0.7);
}

.hero .lead {
  margin-top: 0.5rem;
}

.links-section {
  margin-top: 1.25rem;
  width: 100%;
  max-width: 800px;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}

.link-card {
  position: relative;
  display: block;
  min-height: 180px;
  padding: 0;
  color: var(--text);
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: 22px;
  background: transparent;
  box-shadow: none;
  overflow: hidden;
  perspective: 1200px;
  transform-style: preserve-3d;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.link-card:hover,
.link-card:focus-visible {
  transform: translateY(-6px);
  border-color: rgba(124, 231, 255, 0.9);
  box-shadow: 0 24px 48px rgba(13, 19, 35, 0.7);
}

.card-content {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 180px;
  display: block;
  transform-style: preserve-3d;
}

.card-face {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  backface-visibility: hidden;
  transition: transform 0.75s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.45s ease;
  border-radius: 22px;
}

.card-front {
  z-index: 2;
  background: transparent;
  border: none;
  box-shadow: none;
}

.card-back {
  z-index: 1;
  opacity: 0;
  transform: rotateY(180deg);
  background: linear-gradient(145deg, rgba(113, 234, 255, 0.12), rgba(160, 107, 255, 0.14));
  border: 1px solid rgba(124, 231, 255, 0.0);
  box-shadow: inset 0 0 20px rgba(124, 231, 255, 0.08);
  flex-direction: column;
  text-align: center;
}

.link-card:hover .card-back,
.link-card:focus-visible .card-back {
  border-color: rgba(124, 231, 255, 0.3);
}

.link-card:hover .card-front,
.link-card:focus-visible .card-front {
  opacity: 0;
  transform: rotateY(-180deg);
}

.link-card:hover .card-back,
.link-card:focus-visible .card-back {
  opacity: 1;
  transform: rotateY(0deg);
}

.link-card.is-flipped .card-front {
  opacity: 0;
  transform: rotateY(-180deg);
}

.link-card.is-flipped .card-back {
  opacity: 1;
  transform: rotateY(0deg);
  border-color: rgba(124, 231, 255, 0.3);
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 120px;
  height: 120px;
  border-radius: 0;
  background: transparent;
  border: none;
  box-shadow: none;
  transition: transform 0.3s ease, filter 0.3s ease;
}

.card-icon svg {
  width: 120px;
  height: 120px;
  display: block;
  fill: none;
  stroke: #dffcff;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 10px rgba(124, 231, 255, 0.35));
}

.link-card:hover .card-icon,
.link-card:focus-visible .card-icon {
  transform: scale(1.08);
  filter: brightness(1.1);
}

.card-title {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #f4fbff;
}

.card-text {
  margin: 0;
  color: rgba(237, 246, 255, 0.82);
  font-size: 0.8rem;
  line-height: 1.5;
}

@media (max-width: 640px) {
  .page-shell {
    width: min(100% - 1rem, 1100px);
    padding-top: 1.2rem;
  }

  .hero {
    gap: 0.7rem;
    padding-top: 1.5rem;
  }

  .cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
  }

  .link-card,
  .card-content {
    min-height: 150px;
  }

  .card-text {
    font-size: 0.72rem;
    line-height: 1.35;
  }

  .link-card:hover .card-front,
  .link-card:hover .card-back,
  .link-card:focus-visible .card-front,
  .link-card:focus-visible .card-back {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
