*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0
}

:root {
  --ct: #6bffca;
  --cc: #7c6aff;
  --ccl: #ff6b9d;
  --cv: #6baaff;
  --ca: #e0e0f0;
  --cam: #ff7a5a;
  --cvi: #c06bff;
  --co: #ffcc6b;
  --cs: #5affc0;
  --text: #e8e8f0;
  --muted: #5a5a72
}

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #050508;
  color: var(--text);
  font-family: 'Space Grotesk', sans-serif;
  user-select: none
}

/* ── World ── */
#world {
  position: fixed;
  top: 0;
  left: 0;
  width: 300vw;
  height: 100vh;
  will-change: transform
}

.col {
  position: absolute;
  top: 0;
  width: 100vw;
  will-change: transform
}

.col:nth-child(1) {
  left: 0
}

.col:nth-child(2) {
  left: 100vw
}

.col:nth-child(3) {
  left: 200vw
}

.page {
  width: 100vw;
  height: 100vh;
  position: relative;
  overflow: hidden
}

.bg-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%
}

/* ── Card content ── */
.pc {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 2;
  pointer-events: none
}

.card {
  max-width: 540px;
  width: 88%;
  max-height: calc(100vh - 4rem);
  overflow-y: auto;
  padding: 2.6rem 2.2rem;
  border-radius: 20px;
  background: rgba(0, 0, 0, 0.38);
  border: 1px solid rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  text-align: center;
  pointer-events: auto;
  user-select: text;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, .2) transparent
}

.tag {
  display: inline-block;
  font-size: .63rem;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--pc);
  opacity: .8;
  margin-bottom: .9rem
}

.card h1 {
  font-size: clamp(2.6rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1;
  color: #fff;
  margin-bottom: 1rem
}

.card h2 {
  font-size: clamp(1.9rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.05;
  color: var(--pc);
  margin-bottom: .9rem
}

.card p {
  font-size: .98rem;
  font-weight: 300;
  line-height: 1.85;
  color: rgba(232, 232, 240, .7)
}

.blob {
  width: 60px;
  height: 60px;
  border-radius: 17px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin: 0 auto 1.3rem;
  background: rgba(0, 0, 0, .45);
  border: 1px solid rgba(255, 255, 255, .1);
  box-shadow: 0 0 22px -4px var(--pc);
  animation: blp 3s ease-in-out infinite
}

@keyframes blp {

  0%,
  100% {
    box-shadow: 0 0 18px -4px var(--pc)
  }

  50% {
    box-shadow: 0 0 38px 2px var(--pc)
  }
}

/* ── Edge Bars ── */
.eb {
  position: fixed;
  z-index: 400;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: opacity .35s
}

.eb.on {
  opacity: 1;
  pointer-events: auto
}

.eb.hov {
  pointer-events: auto
}

.eb.hov:hover {
  opacity: 1
}

.eb.off {
  opacity: 0 !important;
  pointer-events: none !important
}

#ebl,
#ebr {
  top: 0;
  bottom: 0;
  width: 54px
}

#ebt,
#ebb {
  left: 0;
  right: 0;
  height: 54px
}

#ebl {
  left: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, .055), transparent);
  border-right: 1px solid rgba(255, 255, 255, .05)
}

#ebr {
  right: 0;
  background: linear-gradient(270deg, rgba(255, 255, 255, .055), transparent);
  border-left: 1px solid rgba(255, 255, 255, .05)
}

#ebt {
  top: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, .055), transparent);
  border-bottom: 1px solid rgba(255, 255, 255, .05)
}

#ebb {
  bottom: 0;
  background: linear-gradient(0deg, rgba(255, 255, 255, .055), transparent);
  border-top: 1px solid rgba(255, 255, 255, .05)
}

.eb svg {
  width: 22px;
  height: 22px;
  stroke: rgba(255, 255, 255, .55);
  fill: none;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke .2s, transform .2s
}

.eb:hover svg {
  stroke: #fff;
  transform: scale(1.15)
}

/* ── Minimap ── */
#mm {
  position: fixed;
  bottom: 22px;
  left: 22px;
  z-index: 500;
  background: rgba(0, 0, 0, .6);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 12px;
  padding: 9px;
  backdrop-filter: blur(18px);
  display: grid;
  grid-template-columns: repeat(3, 15px);
  grid-template-rows: repeat(3, 15px);
  gap: 5px
}

.mc {
  width: 15px;
  height: 15px;
  border-radius: 4px;
  background: var(--m);
  opacity: .22;
  cursor: pointer;
  transition: opacity .2s, box-shadow .2s, transform .2s;
  position: relative
}

.mc:hover {
  opacity: .65;
  transform: scale(1.12)
}

.mc.act {
  opacity: 1;
  box-shadow: 0 0 7px 1px var(--m)
}

.mc::after {
  content: attr(data-n);
  position: absolute;
  bottom: calc(100% + 7px);
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, .88);
  color: #fff;
  font-size: 10px;
  white-space: nowrap;
  padding: 3px 7px;
  border-radius: 5px;
  pointer-events: none;
  opacity: 0;
  transition: opacity .18s;
  font-family: inherit
}

.mc:hover::after {
  opacity: 1
}

/* ── Flash overlay ── */
#flash {
  position: fixed;
  inset: 0;
  z-index: 600;
  background: rgba(100, 80, 255, .04);
  opacity: 0;
  pointer-events: none;
  transition: opacity .12s
}

/* ── Site link chip ── */
.site-link {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  margin-top: 1.4rem;
  padding: .5rem 1.1rem;
  border-radius: 100px;
  border: 1px solid rgba(255, 255, 255, .12);
  background: rgba(255, 255, 255, .05);
  color: var(--pc);
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-decoration: none;
  pointer-events: auto;
  transition: background .2s, border-color .2s, transform .15s
}

.site-link:hover {
  background: rgba(255, 255, 255, .1);
  border-color: rgba(255, 255, 255, .22);
  transform: translateY(-2px)
}

.site-link svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round
}

/* ── Mobile: hide edge bars, draggable map ── */
#mm {
  cursor: grab
}

#mm:active {
  cursor: grabbing
}

@media (max-width: 768px) {
  .eb {
    opacity: 0 !important;
    pointer-events: none !important
  }

  .pc {
    justify-content: flex-start;
    padding: 1rem 0
  }

  .card {
    max-height: calc(100vh - 2rem);
    padding: 1.6rem 1.4rem
  }
}

/* ── MailerLite embed ── */
.ml-wrap {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height .4s ease, opacity .3s ease, margin .3s ease;
  margin-top: 0
}

.ml-wrap.open {
  max-height: 500px;
  opacity: 1;
  margin-top: 1.2rem
}

/* ── Noscript fallback ── */
.noscript-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
  color: var(--text);
  font-family: 'Space Grotesk', sans-serif;
  line-height: 1.7
}

.noscript-content h1 {
  font-size: 2.2rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 1rem
}

.noscript-content h2 {
  font-size: 1.5rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: .5rem
}

.noscript-content section {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, .08)
}

.noscript-content small {
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted)
}

.noscript-content p {
  color: rgba(232, 232, 240, .7);
  margin-bottom: .5rem
}

.noscript-content a {
  color: var(--cc);
  text-decoration: none;
  border-bottom: 1px solid rgba(124, 106, 255, .3)
}

.noscript-content a:hover {
  border-color: var(--cc)
}