/* ==========================================================================
   SPECTRAL HORN - CSS ARCHITECTURE & STYLING
   Optimized for JS13k with shared glassmorphism, flex layouts, and CSSO compression.
   ========================================================================== */

@keyframes s {
  50% {
    background-position: 100% 50%;
  }
}

@keyframes f {
  0% {
    opacity: 0;
  }
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
}

b,
.l,
.mt,
.tm,
.ch,
.bp,
.b1 {
  font-weight: 900;
}

button b {
  font-weight: 600;
}

body,
#c {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
}

body {
  background: #030611;
  color: #fff;
  font-family: system-ui, sans-serif;
  text-align: center;
}

#c {
  position: fixed;
  inset: 0;
  touch-action: none;
}

header,
footer,
#ac,
.gc,
.m,
.mb {
  backdrop-filter: blur(14px);
}

header,
footer,
#ac {
  position: fixed;
  background: #0a122a22;
  box-shadow: 0 0 16px #38bdf833;
}

header,
footer {
  left: 50%;
  transform: translateX(-50%);
}

header,
#ac,
button,
select {
  border-radius: 99px;
}

header,
footer,
#ac,
.gc,
.cc,
button,
select {
  border: 1px solid #38bdf859;
}

header {
  top: 10px;
  padding: 5px 12px;
  gap: 6px;
  z-index: 10;
}

footer,
#ac {
  bottom: 10px;
}

footer {
  padding: 5px 16px;
  border-radius: 14px;
  pointer-events: none;
  gap: 2px;
  z-index: 10;
}

footer b {
  font-size: .8rem;
}

footer span,
#ac {
  font-size: .74rem;
  color: #94a3b8;
}

#ac {
  right: 12px;
  z-index: 25;
  padding: 4px 10px;
  gap: 6px;
}

#ac a {
  color: #38bdf8;
  text-decoration: none;
  font-weight: 700;
}

#ac a:hover,
footer b {
  color: gold;
  text-shadow: 0 0 10px #ffd70099;
}

.l,
.mt,
.tm {
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  background-image: linear-gradient(135deg, gold, #ff7b00, #ec4899, #38bdf8);
  background-size: 200% 200%;
  animation: s 5s ease infinite;
}

.l,
button,
select {
  white-space: nowrap;
}

.l {
  font-size: .95rem;
  letter-spacing: 1.5px;
}

button,
select {
  background: #0a122a66;
  color: #fff;
  padding: 5px 10px;
  font-size: .8rem;
  cursor: pointer;
  outline: 0;
  justify-content: center;
  gap: 4px;
  transition: .2s;
}

select {
  max-width: 150px;
  text-overflow: ellipsis;
}

option {
  background: #0a122a;
  color: #fff;
}

.gc {
  transition: .2s;
}

#ac:hover,
.gc:hover,
button:hover,
select:hover {
  border-color: gold;
  box-shadow: 0 0 16px #ffd70080;
  transform: translateY(-1px);
}

button:active {
  transform: scale(.95);
}

.bp,
.b1 {
  background: linear-gradient(135deg, gold, #f59e0b);
  color: #030611;
  border: 1px solid #fff275;
  box-shadow: 0 0 24px #ffd700b3;
}

.b1 {
  padding: 10px 28px;
  font-size: 1rem;
  align-self: center;
}

.bp:hover,
.b1:hover {
  background: linear-gradient(135deg, #fff275, #fbbf24);
  box-shadow: 0 0 36px #ffd700f2;
}

.bp {
  font-size: 1.2rem;
  padding: 10px 44px;
  gap: 8px;
}

.bp:hover {
  transform: scale(1.05);
}

#wm p {
  color: #cbd5e1;
}

.h {
  display: none !important;
}

.t header,
.t footer,
body:not(.t) #ts {
  display: none;
}

#ts,
.th,
.m,
.mb,
footer,
.cl,
.ci {
  display: flex;
  flex-direction: column;
}

#ts,
.th,
.m,
.mb {
  align-items: center;
}

header,
#ac,
button,
select,
.l,
.bp,
.cb {
  display: flex;
  align-items: center;
}

#ts,
.m {
  position: fixed;
  inset: 0;
  animation: f .3s ease-out;
}

#ts {
  z-index: 20;
  justify-content: space-between;
  padding: 36px 24px;
  pointer-events: none;
  overflow-y: auto;
}

.th {
  gap: 8px;
}

.th,
.tc,
.bp {
  pointer-events: auto;
}

.tm {
  font-size: 3rem;
  letter-spacing: 3.5px;
  filter: drop-shadow(0 0 36px #38bdf8a6);
}

#ts p {
  font-size: 1.05rem;
  color: #cbd5e1;
  font-weight: 600;
}

.tc {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 18px;
  width: 100%;
  max-width: 1040px;
}

.gc {
  background: #0a122a22;
  border-radius: 20px;
  padding: 16px 18px;
  gap: 8px;
  box-shadow: 0 0 24px #38bdf833;
}

.ch {
  font-size: 1.05rem;
  color: gold;
  gap: 8px;
  padding: 0 0 8px 0;
}

.cb {
  gap: 12px;
}

.cc {
  width: 160px;
  height: 175px;
  background: #0a122a99;
  border-radius: 12px;
  flex-shrink: 0;
}

.cl {
  gap: 8px;
  flex: 1;
  text-align: left;
}

.ci {
  background: #0a122ad9;
  padding: 6px 10px;
  border-radius: 8px;
  gap: 2px;
}

.c {
  color: #38bdf8;
  border: 1px solid #38bdf8;
}

.g {
  color: gold;
  border: 1px solid gold;
}

.k {
  color: #4ade80;
  border: 1px solid #4ade80;
}

.ci b {
  font-size: .82rem;
}

.ci span {
  font-size: .72rem;
  color: #cbd5e1;
}

.m {
  background: #0a122a22;
  justify-content: center;
  z-index: 30;
}

.mb {
  background: #0a122ac7;
  border: 1.5px solid gold;
  box-shadow: 0 0 54px #ffd70073;
  padding: 32px 42px;
  border-radius: 24px;
  gap: 16px;
  max-width: min(92vw, 560px);
}

.ml {
  max-width: min(94vw, 920px);
  max-height: 90vh;
  overflow-y: auto;
  padding: 24px;
}

.mt {
  font-size: clamp(1.35rem, 4vw, 1.8rem);
  letter-spacing: 1.5px;
}

/* RESPONSIVE LAYOUT BREAKPOINT */
@media (max-width: 850px) {
  header {
    top: 8px;
    padding: 4px 8px;
    gap: 4px;
  }

  .l {
    font-size: .92rem;
  }

  header b {
    display: none;
  }

  select {
    max-width: 140px;
    font-size: .76rem;
    padding: 4px 6px;
  }

  button {
    padding: 5px 8px;
  }

  footer {
    padding: 5px 14px;
  }

  #ac {
    bottom: 8px;
    right: 8px;
    font-size: .7rem;
    padding: 4px 8px;
  }

  .tc {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  #ts {
    padding: 24px 16px;
  }
}