/* InfoTaller — portal de registro y páginas de taller */

:root {
  --bg0: #070b16;
  --bg1: #0d1424;
  --line: #22304f;
  --txt: #e8ecf6;
  --muted: #93a0bd;
  --gold: #f5b942;
  --gold2: #e0862c;
  --err: #ff6b6b;
  --ok: #4cd97b;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  color: var(--txt);
  background: radial-gradient(1200px 800px at 70% -10%, #14203c 0%, var(--bg0) 55%),
              var(--bg0);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  min-height: 100vh;
}

.muted { color: var(--muted); }
a { color: var(--gold); }

/* ---------- fondo de estrellas (landing) ---------- */
#bg-stars {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* ---------- landing ---------- */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 26px;
  padding: 40px 18px 26px;
}

.brand { text-align: center; }
.brand-ico { font-size: 44px; display: block; margin-bottom: 4px; }
.brand h1 {
  margin: 0;
  font-size: clamp(38px, 7vw, 64px);
  font-weight: 800;
  letter-spacing: -0.03em;
}
.brand-accent { color: var(--gold); }
.brand-sub { margin: 8px 0 0; color: var(--muted); font-size: 17px; }

.glass {
  background: rgba(13, 20, 36, 0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.card {
  width: min(440px, 94vw);
  padding: 28px 28px 22px;
}
.card.narrow { width: min(400px, 94vw); text-align: left; }

.card h2 { margin: 0 0 10px; font-size: 24px; letter-spacing: -0.02em; }
.card h3 { margin: 22px 0 8px; font-size: 17px; }

.url-demo {
  text-align: center;
  font-weight: 700;
  color: var(--gold);
  background: rgba(245, 185, 66, 0.08);
  border: 1px dashed rgba(245, 185, 66, 0.4);
  border-radius: 10px;
  padding: 8px 10px;
  margin: 14px 0 18px;
  font-size: 15px;
  overflow-wrap: anywhere;
}

.url-big { text-align: center; margin: 14px 0 4px; }
.url-big a {
  font-size: clamp(18px, 4vw, 24px);
  font-weight: 800;
  color: var(--gold);
  text-decoration: none;
  border-bottom: 2px solid rgba(245, 185, 66, 0.35);
  overflow-wrap: anywhere;
}

form label {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  margin: 14px 0 6px;
}

form input[type="text"],
form input[type="email"],
form input[type="password"] {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #0a101f;
  color: var(--txt);
  font-size: 15px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
form input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(245, 185, 66, 0.15);
}
form input[type="file"] {
  width: 100%;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 6px;
}

.btn-primary {
  width: 100%;
  margin-top: 20px;
  padding: 13px 16px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  color: #101423;
  font-size: 15.5px;
  font-weight: 800;
  letter-spacing: .01em;
  cursor: pointer;
  transition: transform .12s, box-shadow .12s, filter .12s;
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 26px rgba(245, 185, 66, 0.25);
  filter: brightness(1.05);
}
.btn-primary:active { transform: translateY(0); }

.btn-ghost {
  margin-top: 12px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--txt);
  font-size: 14px;
  cursor: pointer;
}
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }

.flash {
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
  margin: 12px 0 2px;
}
.flash.error { background: rgba(255, 107, 107, .12); border: 1px solid rgba(255,107,107,.35); color: #ffb3b3; }
.flash.ok { background: rgba(76, 217, 123, .1); border: 1px solid rgba(76,217,123,.35); color: #b8f5cd; }

.alt { text-align: center; margin-top: 18px; font-size: 14px; color: var(--muted); }
.alt a { color: var(--gold); text-decoration: none; font-weight: 600; }

.foot { font-size: 13px; }

.resend { display: inline-block; }

.logo-preview {
  max-width: 220px;
  max-height: 120px;
  border-radius: 10px;
  background: #fff;
  padding: 6px;
}

.qr-img {
  width: 180px;
  background: #fff;
  padding: 10px;
  border-radius: 12px;
}

/* ---------- página del taller ---------- */
body.taller {
  overflow: hidden;
  background: radial-gradient(1400px 900px at 50% 120%, #16244a 0%, #0a0f1e 45%, #060911 100%),
              #060911;
}

#starfield {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  display: block;
}

.star-title {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  opacity: 0;
  left: 50%; top: 50%;
}

.taller-logo-wrap {
  position: fixed;
  top: 7vh;
  left: 0; right: 0;
  display: flex;
  justify-content: center;
  z-index: 2;
  pointer-events: none;
}
#taller-logo {
  max-height: 18vh;
  max-width: 46vw;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  padding: 8px 14px;
  box-shadow: 0 14px 44px rgba(0, 0, 0, 0.5), 0 0 60px rgba(245, 185, 66, 0.12);
}

.taller-hint {
  position: fixed;
  bottom: 12vh;
  left: 0; right: 0;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
  letter-spacing: .08em;
  z-index: 2;
  pointer-events: none;
  animation: hint 5s ease-in-out infinite;
}
@keyframes hint { 0%,100% { opacity:.45 } 50% { opacity:.9 } }

/* ---------- login de trabajadores (página del taller) ---------- */
.taller-login {
  position: fixed;
  top: 66%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(320px, 86vw);
  padding: 18px 20px;
  border-radius: 16px;
  background: rgba(13, 20, 36, 0.55);
}

.taller-login input {
  width: 100%;
  padding: 11px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(10, 16, 31, 0.85);
  color: var(--txt);
  font-size: 14.5px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.taller-login input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(245, 185, 66, 0.15);
}
.taller-login .btn-primary {
  margin-top: 4px;
  padding: 11px 16px;
  font-size: 14.5px;
}

.taller-foot {
  position: fixed;
  bottom: 14px;
  left: 0; right: 0;
  text-align: center;
  z-index: 2;
}
.foot-link {
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
  opacity: .8;
  transition: opacity .15s, color .15s;
}
.foot-link:hover { color: var(--gold); opacity: 1; }

@media (max-width: 640px) {
  #taller-logo { max-width: 64vw; }
  .taller-hint { bottom: 14vh; font-size: 12.5px; }
}
