/*
 * more.ostendorf.link: link page for Simon Ostendorf Veranstaltungstechnik.
 * A dark stage with sweeping light beams, the links as mixer channel strips.
 * Every animation is switched off under prefers-reduced-motion (end of file).
 */

:root {
  --bg: #07060f;
  --panel: rgb(22 19 42 / 0.72);
  --panel-hover: rgb(32 27 64 / 0.9);
  --border: rgb(255 255 255 / 0.09);
  --text: #f2f1fb;
  --text-muted: rgb(242 241 251 / 0.7);
  --text-faint: rgb(242 241 251 / 0.56);

  /* Brand gradient from the logo; --violet is the purple lightened for text contrast. */
  --cyan: #1ee3f5;
  --purple: #7b3cf5;
  --violet: #a47cff;
  --gradient: linear-gradient(90deg, var(--cyan), var(--purple));
  --gradient-text: linear-gradient(90deg, var(--cyan), var(--violet));

  --radius: 14px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
}

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

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px 16px 32px;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

/* ---------- Stage lights ---------- */

.stage {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  /* Haze glowing on the stage floor. */
  background:
    radial-gradient(ellipse 90% 45% at 50% 110%, rgb(123 60 245 / 0.28), transparent 70%),
    radial-gradient(ellipse 60% 30% at 50% 105%, rgb(30 227 245 / 0.12), transparent 70%);
}

/*
 * A beam is a soft cone hanging from above the viewport, swaying between --from and --to.
 * The cone shape sits on ::before because a clip-path on the blurred element would cut
 * the blur off again and leave hard edges.
 */
.beam {
  position: absolute;
  top: -12vh;
  width: 36vmax;
  height: 125vh;
  margin-left: -18vmax;
  transform-origin: 50% 0;
  transform: rotate(var(--from));
  filter: blur(16px);
  mix-blend-mode: screen;
  opacity: 0.55;
  will-change: transform;
  animation: sway 12s ease-in-out infinite alternate;
}

.beam::before {
  content: "";
  position: absolute;
  inset: 0;
  clip-path: polygon(47% 0, 53% 0, 100% 100%, 0 100%);
  background: linear-gradient(to bottom, var(--beam) 0%, transparent 80%);
}

.beam:nth-child(1) {
  left: 8%;
  --beam: rgb(30 227 245 / 0.5);
  --from: -28deg;
  --to: -8deg;
}

.beam:nth-child(2) {
  left: 34%;
  --beam: rgb(123 60 245 / 0.6);
  --from: 14deg;
  --to: -10deg;
  animation-duration: 15s;
  animation-delay: -4s;
}

.beam:nth-child(3) {
  left: 66%;
  --beam: rgb(30 227 245 / 0.42);
  --from: -12deg;
  --to: 14deg;
  animation-duration: 13s;
  animation-delay: -7s;
}

.beam:nth-child(4) {
  left: 92%;
  --beam: rgb(123 60 245 / 0.6);
  --from: 28deg;
  --to: 8deg;
  animation-duration: 17s;
  animation-delay: -2s;
}

@keyframes sway {
  from { transform: rotate(var(--from)); }
  to { transform: rotate(var(--to)); }
}

/* ---------- Content ---------- */

.card {
  position: relative;
  width: 100%;
  max-width: 440px;
}

.hero {
  text-align: center;
  margin-bottom: 32px;
  animation: rise 700ms var(--ease) both;
}

.logo {
  display: block;
  width: 104px;
  height: auto;
  margin: 0 auto 20px;
  overflow: visible;
  filter: drop-shadow(0 0 22px rgb(123 60 245 / 0.5));
}

/* The bars pump gently like an equalizer, each at its own tempo. */
.logo-bar {
  transform-box: fill-box;
  transform-origin: 50% 50%;
  animation: pump 1.6s ease-in-out infinite;
}

.logo-bar:nth-child(1) { animation-duration: 1.3s; animation-delay: -0.2s; }
.logo-bar:nth-child(2) { animation-duration: 1.7s; animation-delay: -0.9s; }
.logo-bar:nth-child(3) { animation-duration: 1.1s; animation-delay: -0.4s; }
.logo-bar:nth-child(4) { animation-duration: 1.9s; animation-delay: -1.2s; }
.logo-bar:nth-child(5) { animation-duration: 1.4s; animation-delay: -0.6s; }
.logo-bar:nth-child(6) { animation-duration: 1.2s; animation-delay: -1s; }
.logo-bar:nth-child(7) { animation-duration: 1.6s; animation-delay: -0.3s; }

@keyframes pump {
  0%, 100% { transform: scaleY(1); }
  50% { transform: scaleY(0.8); }
}

h1 {
  margin: 0;
  font-size: clamp(2rem, 9vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.subtitle {
  display: inline-block;
  margin: 10px 0 0;
  /* Balances the letter spacing after the last letter so the word stays centred. */
  padding-left: 0.22em;
  font-size: clamp(0.8rem, 3.6vw, 0.95rem);
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--cyan);
}

@supports (background-clip: text) or (-webkit-background-clip: text) {
  .subtitle {
    background: var(--gradient-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
  }
}

.services {
  margin: 10px 0 0;
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--text-faint);
}

/* ---------- Links as channel strips ---------- */

.links {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.links li {
  animation: rise 600ms var(--ease) both;
}

.links li:nth-child(1) { animation-delay: 120ms; }
.links li:nth-child(2) { animation-delay: 180ms; }
.links li:nth-child(3) { animation-delay: 240ms; }
.links li:nth-child(4) { animation-delay: 300ms; }
.links li:nth-child(5) { animation-delay: 360ms; }
.links li:nth-child(6) { animation-delay: 420ms; }

.link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--panel);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  text-decoration: none;
  transition: transform 200ms var(--ease), box-shadow 200ms ease;
}

/* On hover the strip gets a gradient border and a coloured glow, like a lit channel. */
.link:hover,
.link:focus-visible {
  border-color: transparent;
  background:
    linear-gradient(var(--panel-hover), var(--panel-hover)) padding-box,
    var(--gradient) border-box;
  box-shadow: 0 10px 32px -12px rgb(123 60 245 / 0.7), 0 0 24px -10px rgb(30 227 245 / 0.6);
  transform: translateY(-2px);
}

.channel {
  flex-shrink: 0;
  padding: 3px 6px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--text-faint);
}

.link:hover .channel,
.link:focus-visible .channel {
  border-color: rgb(30 227 245 / 0.5);
  color: var(--cyan);
}

.link-icon {
  display: flex;
  flex-shrink: 0;
  color: var(--text);
}

.link-icon svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.link-icon .icon-dot {
  fill: currentColor;
  stroke: none;
}

.link:hover .link-icon,
.link:focus-visible .link-icon {
  color: var(--cyan);
}

.link-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.link-label {
  font-size: 1rem;
  font-weight: 700;
}

.link-handle {
  overflow: hidden;
  font-size: 0.82rem;
  color: var(--text-muted);
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Level meter: five segments that idle low and jump when the channel is hovered. */
.meter {
  display: flex;
  flex-shrink: 0;
  align-items: flex-end;
  gap: 3px;
  height: 22px;
  margin-left: auto;
}

.meter span {
  width: 3px;
  height: 100%;
  border-radius: 2px;
  transform-origin: 50% 100%;
  transform: scaleY(0.25);
  opacity: 0.45;
  transition: transform 200ms var(--ease), opacity 200ms ease;
}

.meter span:nth-child(1) { background: #1ee3f5; }
.meter span:nth-child(2) { background: #3cb8f6; transform: scaleY(0.35); }
.meter span:nth-child(3) { background: #5a8df6; }
.meter span:nth-child(4) { background: #6b64f5; transform: scaleY(0.3); }
.meter span:nth-child(5) { background: #7b3cf5; }

.link:hover .meter span,
.link:focus-visible .meter span {
  opacity: 1;
  animation: level 700ms ease-in-out infinite alternate;
}

.link:hover .meter span:nth-child(2),
.link:focus-visible .meter span:nth-child(2) { animation-duration: 520ms; animation-delay: -200ms; }
.link:hover .meter span:nth-child(3),
.link:focus-visible .meter span:nth-child(3) { animation-duration: 640ms; animation-delay: -350ms; }
.link:hover .meter span:nth-child(4),
.link:focus-visible .meter span:nth-child(4) { animation-duration: 460ms; animation-delay: -100ms; }
.link:hover .meter span:nth-child(5),
.link:focus-visible .meter span:nth-child(5) { animation-duration: 580ms; animation-delay: -420ms; }

@keyframes level {
  from { transform: scaleY(0.3); }
  to { transform: scaleY(1); }
}

/* ---------- Footer ---------- */

.footer {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 40px;
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-faint);
}

.footer p {
  margin: 0;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.footer-links a {
  color: var(--text-muted);
  text-underline-offset: 3px;
}

.footer-links a:hover {
  color: var(--cyan);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
}

/* ---------- Narrow screens ---------- */

@media (max-width: 360px) {
  .channel {
    display: none;
  }
}

/* ---------- Reduced motion: the stage stands still, hover keeps only colour changes. ---------- */

@media (prefers-reduced-motion: reduce) {
  .beam,
  .logo-bar,
  .hero,
  .links li {
    animation: none;
  }

  .link {
    transition: none;
  }

  .link:hover,
  .link:focus-visible {
    transform: none;
  }

  .link:hover .meter span,
  .link:focus-visible .meter span {
    animation: none;
    transform: scaleY(1);
    transition: none;
  }
}
