/* ── Fonts ── */
@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@700;900&family=Share+Tech+Mono&family=Exo+2:wght@400;600;700&display=swap');

/* ── Reset ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --c:    #00ffff;
  --c2:   #12d3f9;
  --blue: #004cff;
  --g:    #0fff6b;
  --bg:   #06060e;
  --bg2:  #0a0a18;
  --bdr:  rgba(0,255,255,0.15);
  --txt:  #c0ccdd;
  --dim:  #2a3344;
}

/* ── Body ── */
body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: var(--bg);
  font-family: 'Exo 2', sans-serif;
  color: var(--txt);
  position: relative;
  overflow: hidden;
}

/* Scanline */
body::before {
  content: '';
  position: fixed; inset: 0;
  background: repeating-linear-gradient(
    0deg, transparent, transparent 2px,
    rgba(0,0,0,0.08) 2px, rgba(0,0,0,0.08) 4px
  );
  pointer-events: none;
  z-index: 9999;
}

/* Háttér rács */
.bg-grid {
  position: fixed; inset: 0;
  background-image:
    linear-gradient(rgba(0,255,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,255,255,0.04) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse at 50% 50%, black 20%, transparent 75%);
  pointer-events: none;
  z-index: 0;
}

/* Ambient glow */
body::after {
  content: '';
  position: fixed;
  top: 40%; left: 50%;
  transform: translate(-50%, -50%);
  width: 500px; height: 500px;
  background: radial-gradient(circle,
    rgba(0,76,255,0.08) 0%,
    rgba(0,255,255,0.04) 40%,
    transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* Sarok díszek */
.corner {
  position: fixed;
  width: 48px; height: 48px;
  border-color: var(--c);
  border-style: solid;
  opacity: 0.2;
  z-index: 1;
}
.c-tl { top: 20px;  left: 20px;  border-width: 2px 0 0 2px; }
.c-tr { top: 20px;  right: 20px; border-width: 2px 2px 0 0; }
.c-bl { bottom: 20px; left: 20px;  border-width: 0 0 2px 2px; }
.c-br { bottom: 20px; right: 20px; border-width: 0 2px 2px 0; }

/* ════════════════════════
   WRAPPER
════════════════════════ */
.wrapper {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 420px;
  height: 300px;
  overflow: hidden;
  padding: 28px 28px 24px;

  background: rgba(10, 10, 24, 0.85);
  border: 1px solid var(--bdr);
  border-radius: 16px;
  backdrop-filter: blur(24px);

  box-shadow:
    0 0 0 1px rgba(0,255,255,0.05),
    0 0 40px rgba(0,255,255,0.07),
    0 24px 60px rgba(0,0,0,0.6);

  transition: height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Top glow vonal */
.wrapper::before {
  content: '';
  position: absolute;
  top: 0; left: 10%; right: 10%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--c), transparent);
  opacity: 0.6;
}

.wrapper.active {
  height: 580px;
}

/* ════════════════════════
   HEADER
════════════════════════ */
.header-badge {
  font-family: 'Share Tech Mono', monospace;
  font-size: 10px;
  color: var(--c2);
  letter-spacing: 2px;
  margin-bottom: 10px;
  opacity: 0.7;
}

header h1 {
  font-family: 'Orbitron', sans-serif;
  font-size: 20px;
  font-weight: 900;
  color: #fff;
  letter-spacing: 1px;
  text-shadow: 0 0 20px rgba(0,255,255,0.25);
  line-height: 1.2;
}

header p {
  margin-top: 5px;
  font-size: 13px;
  color: var(--dim);
  font-family: 'Share Tech Mono', monospace;
  letter-spacing: 0.5px;
}

/* ════════════════════════
   FORM
════════════════════════ */
.wrapper .form {
  margin: 22px 0 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form input {
  width: 100%;
  height: 50px;
  background: rgba(0,0,0,0.4);
  border: 1px solid rgba(0,255,255,0.15);
  border-radius: 9px;
  padding: 0 16px;
  color: #e0e8f0;
  font-size: 14px;
  font-family: 'Share Tech Mono', monospace;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form input:focus {
  border-color: rgba(0,255,255,0.4);
  box-shadow: 0 0 0 3px rgba(0,255,255,0.07), 0 0 14px rgba(0,255,255,0.1);
}

.form input::placeholder {
  color: #2a3a4a;
  font-family: 'Share Tech Mono', monospace;
}

.form button {
  width: 100%;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;

  background: linear-gradient(90deg, #0077cc, var(--blue));
  border: none;
  border-radius: 9px;
  cursor: pointer;

  color: #fff;
  font-size: 14px;
  font-weight: 700;
  font-family: 'Exo 2', sans-serif;
  letter-spacing: 1px;
  text-transform: uppercase;

  transition: box-shadow 0.25s, transform 0.15s;
}

.form button:hover {
  box-shadow: 0 0 24px rgba(0,76,255,0.5);
  transform: translateY(-1px);
}

.form button:active {
  transform: translateY(0);
}

.form button svg {
  transition: transform 0.2s;
}

.form button:hover svg {
  transform: translateX(3px);
}

/* ════════════════════════
   QR CODE
════════════════════════ */
.qr-code {
  opacity: 0;
  pointer-events: none;
  margin-top: 20px;
  padding: 20px;

  background: rgba(0,0,0,0.3);
  border: 1px solid rgba(0,255,255,0.12);
  border-radius: 12px;

  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
  transition: border-color 0.3s;
}

/* Sarok díszek a QR kereten */
.qr-code::before,
.qr-code::after {
  content: '';
  position: absolute;
  width: 16px; height: 16px;
  border-color: var(--c);
  border-style: solid;
  opacity: 0;
  transition: opacity 0.4s;
}

.qr-code::before {
  top: 8px; left: 8px;
  border-width: 2px 0 0 2px;
}

.qr-code::after {
  bottom: 8px; right: 8px;
  border-width: 0 2px 2px 0;
}

.wrapper.active .qr-code {
  opacity: 1;
  pointer-events: auto;
  transition: opacity 0.5s 0.1s ease, border-color 0.3s;
}

.wrapper.active .qr-code::before,
.wrapper.active .qr-code::after {
  opacity: 0.6;
}

.qr-code:hover {
  border-color: rgba(0,255,255,0.3);
  box-shadow: 0 0 20px rgba(0,255,255,0.06);
}

/* QR kép maga – fekete-fehér → filter inverted + neon tint */
.qr-code img {
  width: 180px;
  height: 180px;
  border-radius: 6px;
  filter: invert(1) sepia(1) saturate(0) brightness(1.1);
  image-rendering: pixelated;
  display: block;
}

/* Letöltés hint */
.qr-hint {
  text-align: center;
  font-family: 'Share Tech Mono', monospace;
  font-size: 10px;
  color: #1a2a38;
  letter-spacing: 1px;
  margin-top: 10px;
  opacity: 0;
  transition: opacity 0.4s 0.3s;
}

.wrapper.active .qr-hint {
  opacity: 1;
}

/* ════════════════════════
   RESPONSIVE
════════════════════════ */
@media (max-width: 460px) {
  .wrapper {
    height: 285px;
    padding: 22px 20px 18px;
    border-radius: 12px;
  }
  .wrapper.active {
    height: 555px;
  }
  header h1 { font-size: 17px; }
  .form input,
  .form button { height: 46px; }
  .qr-code img { width: 160px; height: 160px; }
  .corner { width: 32px; height: 32px; }
}
