
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html { height: 100%; }

body {
  font-family: 'DM Sans', sans-serif;
  background: #07192e;
  color: #fff;
  min-height: 100%;
  min-height: 100svh;
  overflow-x: hidden;
}

/* Background canvas */
canvas#bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
}

.grain {
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
  opacity: 0.35;
  pointer-events: none;
  z-index: 1;
  animation: grain 6s steps(2) infinite;
}

@keyframes grain {
  0%, 100% { transform: translate(0,0); }
  33% { transform: translate(-1%, 1%); }
  66% { transform: translate(1%, -1%); }
}

.page {
  position: relative;
  z-index: 10;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5rem 1.5rem 4rem;
}

.logo {
  margin-bottom: 2.5rem;
  animation: rise 1.2s ease 0.2s both;
  max-width: 100%;
}

.logo img {
  height: clamp(44px, 8vw, 68px);
  max-width: 90vw;
  object-fit: contain;
  filter: drop-shadow(0 0 30px rgba(29,164,212,0.4));
}

.rule {
  width: 120px;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(93,207,239,0.5), transparent);
  margin-bottom: 2.5rem;
  animation: rise 1.2s ease 0.35s both;
}

.eyebrow {
  font-size: clamp(0.58rem, 1.8vw, 0.66rem);
  letter-spacing: 0.45em;
  text-transform: uppercase;
  color: #c9a96e;
  margin-bottom: 1.2rem;
  animation: rise 1.2s ease 0.5s both;
}

h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.9rem, 4.5vw, 3.6rem);
  font-weight: 400;
  line-height: 1.15;
  margin-bottom: 1.4rem;
  animation: rise 1.2s ease 0.62s both;
}

h1 em {
  font-style: normal;
  color: #5dcfef;
  display: block;
}

.sub {
  font-size: clamp(0.82rem, 2vw, 0.96rem);
  font-weight: 300;
  color: rgba(255,255,255,0.52);
  max-width: 400px;
  line-height: 1.8;
  margin-bottom: 2.5rem;
  animation: rise 1.2s ease 0.75s both;
  padding: 0 0.5rem;
}

.buttons {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 1rem;
  animation: rise 1.2s ease 0.88s both;
  width: 100%;
  max-width: 520px;
}

.btn-wrap {
  position: relative;
  display: inline-flex;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: clamp(0.7rem, 2vw, 0.85rem) clamp(1.2rem, 3vw, 2rem);
  font-family: 'DM Sans', sans-serif;
  font-size: clamp(0.68rem, 1.8vw, 0.78rem);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
  border: none;
  white-space: nowrap;
}

.btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.btn-primary {
  background: linear-gradient(135deg, #1382d7, #00b3f8);
  color: #fff;
  box-shadow: 0 4px 28px rgba(14,110,184,0.45);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 36px rgba(29,164,212,0.55);
}

.btn-outline {
  background: transparent;
  color: rgba(255,255,255,0.7);
  border: 1px solid rgba(255,255,255,0.2);
  backdrop-filter: blur(10px);
}

.btn-outline:hover {
  background: rgba(255,255,255,0.07);
  color: #fff;
  border-color: rgba(255,255,255,0.4);
  transform: translateY(-2px);
}

.tooltip {
  position: absolute;
  bottom: calc(100% + 12px);
  left: 50%;
  transform: translateX(-50%) translateY(5px);
  color: rgba(255,255,255,0.75);
  font-size: 0.73rem;
  font-family: 'DM Sans', sans-serif;
  letter-spacing: 0.06em;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 100;
}

.tooltip-inner {
  position: relative;
  display: inline-block;
  padding: 0.45rem 1rem;
  border-radius: 100px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(20px);
}

.tooltip-label,
.tooltip-copied {
  display: block;
  transition: opacity 0.35s ease;
}

.tooltip-copied {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #00b3f8;
  opacity: 0;
}

@media (hover: hover) {
  .btn-wrap:hover .tooltip {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.tooltip.is-copied .tooltip-label { opacity: 0; }
.tooltip.is-copied .tooltip-copied { opacity: 1; }

footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  text-align: center;
  z-index: 10;
  font-size: clamp(0.58rem, 1.5vw, 0.68rem);
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.25);
  animation: rise 1.2s ease 1.1s both;
  padding: 0.8rem 1rem;
  background: linear-gradient(to top, rgba(6,14,28,0.6), transparent);
}

footer a {
  color: rgba(255,255,255,0.35);
  text-decoration: none;
  transition: color 0.2s;
}

footer a:hover { color: #5dcfef; }

@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 480px) {
  .page {
    padding: 4.5rem 1.25rem 4.5rem;
    justify-content: center;
  }

  .buttons {
    flex-direction: column;
    align-items: stretch;
    gap: 0.6rem;
  }

  .btn-wrap { width: 100%; }

  .btn {
    width: 100%;
    padding: 0.9rem 1.5rem;
  }

  .tooltip { display: none; }

  footer {
    position: relative;
    margin-top: 1.5rem;
    background: none;
    padding: 0 1rem 0.5rem;
  }
}

@media (min-width: 481px) and (max-width: 768px) {
  .buttons {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .btn-wrap,
  .buttons > a {
    flex: 1 1 auto;
    min-width: 140px;
  }

  .btn { width: 100%; }
}

@media (min-width: 1400px) {
  h1 { font-size: 4rem; }
}

@media (max-height: 600px) and (orientation: landscape) {
  .logo { margin-bottom: 1.2rem; }
  .logo img { height: 38px; }
  .rule { margin-bottom: 1.2rem; }
  .eyebrow { margin-bottom: 0.7rem; }
  h1 { margin-bottom: 0.8rem; }
  .sub { margin-bottom: 1.5rem; }
  .page { padding: 3rem 1.5rem 3rem; }
}
