/* ============================================================
   Neuryax Meet — tema futurista
   Paleta extraída del propio logo (cian #60E0E0 / azul #2060A0).
   Solo afecta a la portada: NO toca galene.css (el cliente de vídeo).
   ============================================================ */

:root {
  --bg-0:      #030812;
  --bg-1:      #061428;
  --cyan:      #60e0e0;
  --cyan-soft: #8ff5f5;
  --blue:      #2060a0;
  --blue-deep: #0a2740;
  --text:      #e6f4f8;
  --muted:     #7a9bb0;
  --line:      rgba(96, 224, 224, 0.18);
  --glass:     rgba(10, 30, 48, 0.55);
  --radius:    18px;
  --font: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(1200px 700px at 50% -10%, #0d3355 0%, transparent 60%),
    radial-gradient(900px 600px at 90% 110%, #0a2740 0%, transparent 55%),
    linear-gradient(180deg, var(--bg-0) 0%, var(--bg-1) 100%);
  background-attachment: fixed;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ---------- fondo animado ---------- */
#mesh {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  opacity: 0.75;
  pointer-events: none;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(ellipse at 50% 45%,
              transparent 35%, rgba(3, 8, 18, 0.55) 100%);
}

/* ---------- escenario ---------- */
.stage {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 880px;
  padding: 56px 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 34px;
  flex: 1;
}

/* ---------- marca ---------- */
.brand {
  text-align: center;
  animation: rise 0.9s cubic-bezier(.2, .7, .3, 1) both;
}

.logo-wrap {
  position: relative;
  display: inline-flex;
  margin-bottom: 18px;
}

.logo-wrap::after {
  content: "";
  position: absolute;
  inset: -18%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(96,224,224,.30) 0%, transparent 68%);
  filter: blur(14px);
  z-index: -1;
  animation: breathe 5s ease-in-out infinite;
}

.logo {
  width: 148px;
  height: 148px;
  object-fit: contain;
  filter: drop-shadow(0 0 18px rgba(96, 224, 224, 0.45));
  animation: float 6s ease-in-out infinite;
}

.wordmark {
  margin: 0;
  font-size: clamp(2rem, 7vw, 3.1rem);
  font-weight: 800;
  letter-spacing: 0.16em;
  line-height: 1;
  background: linear-gradient(180deg, #ffffff 0%, #bfe9f2 55%, #6fc9d8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 42px rgba(96, 224, 224, 0.28);
}

.wordmark .accent {
  background: linear-gradient(180deg, var(--cyan-soft) 0%, var(--cyan) 60%, #2f9fb8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.meet-badge {
  display: inline-block;
  vertical-align: middle;
  margin-left: 0.42em;
  padding: 0.16em 0.5em;
  font-size: 0.30em;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: #041018;
  background: linear-gradient(135deg, var(--cyan-soft), var(--cyan) 55%, #2f9fb8);
  border-radius: 999px;
  box-shadow: 0 0 22px rgba(96, 224, 224, 0.5);
}

.tagline {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan);
  animation: pulse 2.2s ease-in-out infinite;
}

/* ---------- tarjeta de entrada ---------- */
.join-card {
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px 22px;
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  box-shadow:
    0 18px 50px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  animation: rise 0.9s cubic-bezier(.2, .7, .3, 1) 0.12s both;
}

.join-card label {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 12px;
  font-weight: 600;
}

.input-row {
  display: flex;
  gap: 12px;
}

#group {
  flex: 1;
  min-width: 0;
  padding: 15px 18px;
  font-size: 1.02rem;
  font-family: inherit;
  color: var(--text);
  background: rgba(3, 12, 24, 0.75);
  border: 1px solid rgba(96, 224, 224, 0.22);
  border-radius: 12px;
  outline: none;
  transition: border-color .22s, box-shadow .22s, background .22s;
}

#group::placeholder { color: #3f5d72; }

#group:focus {
  border-color: var(--cyan);
  background: rgba(3, 20, 34, 0.9);
  box-shadow: 0 0 0 3px rgba(96, 224, 224, 0.15),
              0 0 26px rgba(96, 224, 224, 0.28);
}

#submitbutton {
  padding: 15px 30px;
  font-size: 1rem;
  font-weight: 700;
  font-family: inherit;
  letter-spacing: 0.05em;
  color: #03121a;
  cursor: pointer;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--cyan-soft) 0%, var(--cyan) 50%, #2f9fb8 100%);
  box-shadow: 0 8px 26px rgba(96, 224, 224, 0.32);
  transition: transform .18s, box-shadow .18s, filter .18s;
  white-space: nowrap;
}

#submitbutton:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
  box-shadow: 0 12px 34px rgba(96, 224, 224, 0.5);
}

#submitbutton:active { transform: translateY(0); }

#errormessage {
  margin: 12px 0 0;
  min-height: 1.2em;
  color: #ff7d8a;
  font-size: 0.9rem;
}

/* ---------- salas ---------- */
.rooms {
  animation: rise 0.9s cubic-bezier(.2, .7, .3, 1) 0.22s both;
}

.rooms h2 {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 16px;
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--muted);
}

.rooms h2 .bar {
  width: 26px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--cyan), transparent);
  box-shadow: 0 0 10px var(--cyan);
}

#public-groups-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 9px;
  font-size: 0.96rem;
}

#public-groups-table td {
  padding: 15px 16px;
  background: rgba(10, 30, 50, 0.78);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

#public-groups-table td:nth-child(2) {
  color: #a9c8d8;
  font-size: 0.9rem;
}

#public-groups-table td:first-child {
  border-left: 1px solid var(--line);
  border-radius: 12px 0 0 12px;
  border-left: 3px solid var(--cyan);
}

#public-groups-table td:last-child {
  border-right: 1px solid var(--line);
  border-radius: 0 12px 12px 0;
  color: #8fb3c6;
  font-size: 0.84rem;
  text-align: right;
  white-space: nowrap;
}

#public-groups-table tr {
  transition: transform .18s;
}

#public-groups-table tr:hover td {
  background: rgba(20, 58, 88, 0.9);
  border-color: rgba(96, 224, 224, 0.5);
}

#public-groups-table tr:hover { transform: translateX(4px); }

#public-groups-table a {
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  letter-spacing: 0.02em;
}

#public-groups-table a::before {
  content: "▸";
  color: var(--cyan);
  margin-right: 9px;
  opacity: 0.85;
}

#public-groups-table tr:hover a { color: var(--cyan-soft); }

/* estados que mainpage.js aplica */
#public-groups.nogroups #public-groups-table {
  display: block;
  color: var(--muted);
  font-size: 0.9rem;
  padding: 14px 2px;
}

/* ---------- pie ---------- */
.signature {
  position: relative;
  z-index: 2;
  padding: 26px 20px 34px;
  font-size: 0.78rem;
  color: #4d6b80;
  text-align: center;
}

.signature a { color: var(--muted); text-decoration: none; border-bottom: 1px dotted rgba(122,155,176,.4); }
.signature a:hover { color: var(--cyan); }

/* ---------- animaciones ---------- */
@keyframes rise   { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes float  { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-11px); } }
@keyframes breathe{ 0%,100% { opacity: .55; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }
@keyframes pulse  { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.8); } }

/* ---------- movil ---------- */
@media (max-width: 620px) {
  .stage { padding: 40px 16px 20px; gap: 26px; }
  .logo { width: 112px; height: 112px; }
  .wordmark { letter-spacing: 0.10em; }
  .input-row { flex-direction: column; }
  #submitbutton { width: 100%; }
  #public-groups-table td { padding: 13px 12px; font-size: 0.9rem; }
  #public-groups-table td:nth-child(2) { display: none; }
}

/* ---------- accesibilidad ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  #mesh { display: none; }
}

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

/* ---------- selector de idioma ---------- */
.lang-switch {
  position: fixed;
  top: 16px;
  right: 18px;
  z-index: 10;
  display: flex;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(6, 20, 40, 0.72);
  border: 1px solid var(--line);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.lang-switch button {
  min-width: 38px;
  padding: 6px 10px;
  font: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #7fa6bd;
  background: transparent;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  transition: color .18s, background .18s, box-shadow .18s;
}

.lang-switch button:hover { color: var(--cyan-soft); }

.lang-switch button.on {
  color: var(--nx-ink, #04181f);
  background: linear-gradient(135deg, var(--cyan-soft), var(--cyan) 60%, #2f9fb8);
  box-shadow: 0 0 14px rgba(96, 224, 224, 0.45);
}

@media (max-width: 620px) {
  .lang-switch { top: 10px; right: 10px; }
  .lang-switch button { min-width: 32px; padding: 5px 8px; font-size: 0.68rem; }
}
