:root {
  --bg-deep: #03040b;
  --bg-mid: #0b1020;
  --bg-bright: #151a36;
  --text: #f7ebff;
  --muted: #baaed8;
  --accent: #86dfff;
  --accent-2: #dd8dff;
  --accent-3: #70ffd0;
  --panel: rgba(5, 8, 19, 0.72);
  --border: rgba(255, 255, 255, 0.16);
  --shadow: 0 30px 90px rgba(0, 0, 0, 0.45);
  --radius: 28px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Segoe UI", Inter, "Avenir Next", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.7;
  color: var(--text);
  background:
    radial-gradient(circle at 20% 0%, rgba(134, 223, 255, 0.22), transparent 28%),
    radial-gradient(circle at 80% 5%, rgba(221, 141, 255, 0.24), transparent 30%),
    radial-gradient(circle at 10% 100%, rgba(112, 255, 208, 0.16), transparent 34%),
    linear-gradient(140deg, var(--bg-deep) 0%, var(--bg-mid) 35%, var(--bg-bright) 100%);
  overflow-x: hidden;
  position: relative;
  isolation: isolate;
}

body::before {
  content: "";
  position: fixed;
  inset: -20%;
  background:
    radial-gradient(circle at center, rgba(255, 255, 255, 0.07), transparent 60%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 100% 100%, 110px 110px, 110px 110px;
  mask-image: radial-gradient(circle at center, black 35%, transparent 85%);
  opacity: 0.5;
  animation: drift 24s linear infinite;
  pointer-events: none;
  z-index: -2;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: conic-gradient(from 180deg at 50% 50%, rgba(255, 255, 255, 0.04), transparent 18%, rgba(255, 255, 255, 0.04) 32%, transparent 48%, rgba(255, 255, 255, 0.045) 66%, transparent 100%);
  mix-blend-mode: screen;
  opacity: 0.7;
  animation: spin 32s linear infinite;
  pointer-events: none;
  z-index: -1;
}

::selection {
  background: rgba(134, 223, 255, 0.35);
  color: white;
}

.page-wrapper {
  max-width: 1440px;
  margin: 0 auto;
  padding: 4.5rem 2rem 6rem;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
  gap: 2rem;
  align-items: start;
}

.intro {
  grid-column: 1 / -1;
}

.main {
  grid-column: 1;
}

.sidebar {
  grid-column: 2;
  grid-row: 2 / span 2;
}

.intro,
.main,
.sidebar .wrapper {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  overflow: hidden;
}

.intro,
.main {
  clip-path: polygon(0 0, 100% 0, 100% 94%, 92% 100%, 0 100%);
}

.intro::before,
.main::before,
.sidebar .wrapper::before {
  content: "";
  position: absolute;
  inset: -1px;
  background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.16) 35%, transparent 65%, rgba(255, 255, 255, 0.08) 100%);
  pointer-events: none;
  mix-blend-mode: screen;
}

.intro {
  padding: 3rem 3.2rem 2.4rem;
}

.main {
  padding: 2.2rem 2.4rem 2.4rem;
}

.sidebar .wrapper {
  padding: 2rem;
  transform: rotate(-0.8deg);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.sidebar .wrapper:hover {
  transform: rotate(-0.3deg) translateY(-4px);
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.55);
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 300;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

h1 {
  font-size: clamp(2.4rem, 5vw, 4.4rem);
  text-shadow: 0 0 24px rgba(134, 223, 255, 0.4), 0 0 60px rgba(221, 141, 255, 0.24);
  animation: pulseText 6s ease-in-out infinite;
}

h2 {
  margin-top: 0.7rem;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.3rem);
}

h3 {
  margin-bottom: 0.8rem;
  font-size: 0.95rem;
  color: #efe1ff;
}

p,
li,
a {
  font-size: 1rem;
}

p {
  margin: 0 0 1rem;
  color: #d9cfe9;
}

.summary,
.preamble,
.explanation,
.participation,
.benefits,
.requirements {
  position: relative;
  padding: 1.35rem 1.3rem;
  margin-bottom: 1rem;
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025));
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05), 0 18px 35px rgba(0, 0, 0, 0.25);
  transform: perspective(1000px) rotateX(2deg);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.summary:hover,
.preamble:hover,
.explanation:hover,
.participation:hover,
.benefits:hover,
.requirements:hover {
  transform: perspective(1000px) rotateX(0deg) translateY(-3px);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08), 0 24px 48px rgba(0, 0, 0, 0.32);
}

.summary {
  animation: floatUp 8s ease-in-out infinite;
}

abbr {
  text-decoration: none;
  border-bottom: 1px dotted rgba(255, 255, 255, 0.4);
}

a {
  color: #cfeeff;
  text-decoration: none;
  position: relative;
  transition: color 0.25s ease, transform 0.25s ease;
}

a:hover {
  color: white;
  transform: translateY(-1px);
}

a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.9), transparent);
  transform: scaleX(0.15);
  transform-origin: center;
  transition: transform 0.25s ease;
}

a:hover::after {
  transform: scaleX(1);
}

ul {
  padding-left: 1.1rem;
  margin: 0 0 0.8rem;
}

li {
  margin-bottom: 0.4rem;
  color: #d9cfe9;
}

li::marker {
  color: var(--accent);
}

nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

nav li {
  margin: 0.5rem 0;
}

.design-name,
.designer-name {
  display: inline-block;
}

.design-name {
  color: #f6ecff;
}

.design-selection,
.design-archives,
.zen-resources {
  margin-bottom: 1.2rem;
}

.design-selection h3,
.design-archives h3,
.zen-resources h3 {
  margin-bottom: 0.7rem;
  color: var(--accent-3);
}

footer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.4rem;
}

footer a {
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

footer a:hover {
  background: rgba(255, 255, 255, 0.14);
}

.extra1,
.extra2,
.extra3,
.extra4,
.extra5,
.extra6 {
  position: fixed;
  pointer-events: none;
  z-index: -3;
  filter: blur(12px);
  opacity: 0.7;
}

.extra1 {
  width: 280px;
  height: 280px;
  top: -80px;
  left: -90px;
  background: radial-gradient(circle, rgba(134, 223, 255, 0.28), transparent 70%);
  animation: floatOrb 10s ease-in-out infinite;
}

.extra2 {
  width: 340px;
  height: 340px;
  right: -110px;
  top: 20%;
  background: radial-gradient(circle, rgba(221, 141, 255, 0.26), transparent 70%);
  animation: floatOrb 12s ease-in-out infinite reverse;
}

.extra3 {
  width: 220px;
  height: 220px;
  left: 30%;
  bottom: -80px;
  background: radial-gradient(circle, rgba(112, 255, 208, 0.2), transparent 70%);
  animation: floatOrb 14s ease-in-out infinite;
}

.extra4,
.extra5,
.extra6 {
  inset: auto;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.14), transparent 70%);
}

.extra4 { top: 15%; right: 24%; }
.extra5 { bottom: 16%; left: 20%; }
.extra6 { bottom: 8%; right: 10%; }

@supports (animation-timeline: view()) {
  .summary,
  .preamble,
  .explanation,
  .participation,
  .benefits,
  .requirements,
  .sidebar .wrapper {
    animation: reveal linear both;
    animation-timeline: view();
    animation-range: entry 0% cover 35%;
  }
}

@keyframes drift {
  0% { transform: translate3d(0, 0, 0) rotate(0deg); }
  50% { transform: translate3d(10px, -10px, 0) rotate(1deg); }
  100% { transform: translate3d(0, 0, 0) rotate(0deg); }
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes pulseText {
  0%,
  100% { text-shadow: 0 0 24px rgba(134, 223, 255, 0.4), 0 0 60px rgba(221, 141, 255, 0.24); }
  50% { text-shadow: 0 0 34px rgba(134, 223, 255, 0.55), 0 0 90px rgba(221, 141, 255, 0.35); }
}

@keyframes floatUp {
  0%,
  100% { transform: translateY(0px) perspective(1000px) rotateX(2deg); }
  50% { transform: translateY(-6px) perspective(1000px) rotateX(0deg); }
}

@keyframes floatOrb {
  0%,
  100% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(16px, -12px, 0) scale(1.04); }
}

@keyframes reveal {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 980px) {
  .page-wrapper {
    grid-template-columns: 1fr;
  }

  .main,
  .sidebar {
    grid-column: auto;
    grid-row: auto;
  }

  .sidebar .wrapper {
    transform: none;
  }
}

@media (max-width: 700px) {
  .page-wrapper {
    padding: 1.4rem 1rem 3rem;
  }

  .intro,
  .main {
    padding: 1.4rem;
    clip-path: none;
  }

  .intro {
    padding-top: 2rem;
  }

  h1 {
    font-size: 2.2rem;
  }

  footer {
    flex-direction: column;
    align-items: flex-start;
  }
}
