/**
 * ===================================================================
 * hacker.css — tema "node.gila.ro"
 *
 * Se incarca DUPA base.css + main.css si suprascrie tema veche.
 * Pastreaza structura gila.ro (nume, motto, sociale) si fonturile
 * Poppins/Lora, dar in estetica de terminal verde + glob interactiv.
 * -------------------------------------------------------------------
 */

:root {
  --hx: #00ff9c;                       /* verde hacking */
  --hx-dim: rgba(0, 255, 156, 0.55);
  --hx-faint: rgba(0, 255, 156, 0.22);
  --hx-ink: #d9ffef;                   /* alb-verzui pentru text */
  --hx-bg: #020604;
  --mono: Consolas, "Courier New", ui-monospace, monospace;
}

html, body {
  height: 100%;
  background: var(--hx-bg);
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;            /* iOS: fara selectie la drag */
  touch-action: none;                   /* gestul de drag roteste globul,
                                           nu declanseaza scroll/refresh */
  overscroll-behavior: none;
  -webkit-tap-highlight-color: transparent;
}
body.globe-dragging { cursor: grabbing !important; }

/* ---- straturi canvas ---- */
#globe-matrix, #globe-scene {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
#globe-matrix { z-index: 1; opacity: 0.16; }
#globe-scene  { z-index: 2; }

.globe-vignette {
  position: fixed;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background: radial-gradient(120% 90% at 50% 45%,
    transparent 40%, rgba(2, 6, 4, 0.55) 78%, rgba(2, 6, 4, 0.92) 100%);
}

/* efect CRT discret */
.scanlines {
  position: fixed;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background: repeating-linear-gradient(0deg,
    rgba(0, 255, 156, 0.025) 0 1px, transparent 1px 3px);
}

/* ---- sectiunea intro (peste glob, dar lasa mouse-ul sa treaca) ---- */
#intro {
  background: transparent;
  position: relative;
  z-index: 5;
  pointer-events: none;          /* dragul ajunge la glob */
  min-height: 100vh;
}
#intro a { pointer-events: auto; } /* linkurile raman functionale */

/* ---- numele ---- */
.intro-content h1 {
  color: var(--hx-ink);
  text-shadow:
    0 2px 0 rgba(0, 0, 0, 0.45),
    0 8px 26px rgba(0, 0, 0, 0.7),
    0 0 26px rgba(0, 255, 156, 0.28);
  cursor: default;
  pointer-events: auto;
  transition: text-shadow 0.4s ease;
}
/* glitch la hover — verde + un strop din rozul vechiului gila.ro */
.intro-content h1:hover {
  animation: hxGlitch 0.42s steps(2) infinite;
}
@keyframes hxGlitch {
  0%, 100% {
    text-shadow:
      2px 0 rgba(0, 255, 156, 0.65), -2px 0 rgba(204, 0, 95, 0.45),
      0 8px 26px rgba(0, 0, 0, 0.7);
  }
  50% {
    text-shadow:
      -2px 0 rgba(0, 255, 156, 0.65), 2px 0 rgba(204, 0, 95, 0.45),
      0 8px 26px rgba(0, 0, 0, 0.7);
  }
}

/* ---- motto (pastrat din vechiul design, recolorat) ---- */
.intro-motto {
  position: relative;
  max-width: 620px;
  margin: 2rem auto 0;
  font-family: "lora-italic", Georgia, serif;
  font-style: italic;
  font-size: 1.7rem;
  line-height: 1.7;
  color: rgba(217, 255, 239, 0.8);
  text-shadow: 0 0 12px rgba(0, 0, 0, 0.6);
}
.intro-motto .motto-author {
  font-family: "poppins-semibold", sans-serif;
  font-style: normal;
  color: var(--hx);
  letter-spacing: 0.04rem;
  animation: hxAuthorGlow 5s ease-in-out 2s infinite;
}
.intro-motto .motto-quote:not(:empty)::before { content: "\201C"; }
.intro-motto .motto-quote:not(:empty)::after  { content: "\201D"; }
.intro-motto .motto-author:not(:empty)::before {
  content: " \2014 ";
  color: rgba(217, 255, 239, 0.5);
}
@keyframes hxAuthorGlow {
  0%, 100% { text-shadow: 0 0 6px rgba(0, 255, 156, 0.2); }
  50%      { text-shadow: 0 0 16px rgba(0, 255, 156, 0.6); }
}

/* ---- iconite sociale ---- */
.intro-social { z-index: 6; }
.intro-social li a, .intro-social li a:visited {
  color: var(--hx-ink);
  display: inline-block;
  text-shadow: 0 0 14px rgba(0, 0, 0, 0.6);
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.3, 1.4),
              color 0.3s ease, text-shadow 0.3s ease;
}
.intro-social li a:hover, .intro-social li a:focus {
  color: var(--hx);
  transform: translateY(-7px) scale(1.2);
  text-shadow:
    0 0 18px rgba(0, 255, 156, 0.9),
    0 0 44px rgba(0, 255, 156, 0.5);
}

/* ---- HUD ---- */
.hud {
  position: fixed;
  z-index: 6;
  pointer-events: none;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(217, 255, 239, 0.5);
  line-height: 2;
}
.hud b { color: var(--hx); font-weight: 500; }

.hud-tl { top: 24px; left: 30px; }
.hud-tr { top: 24px; right: 30px; text-align: right; }
.hud-bl { bottom: 24px; left: 30px; }
.hud-br { bottom: 24px; right: 30px; text-align: right; }

.hud .cursor { animation: hxBlink 1.1s steps(1) infinite; color: var(--hx); }
@keyframes hxBlink { 50% { opacity: 0; } }

/* node.gila.ro LIVE + inima verde care bate */
.live-line {
  color: rgba(217, 255, 239, 0.75);
  font-size: 12px;
  text-transform: none;   /* node.gila.ro ramane lowercase */
}
.live-heart {
  display: inline-block;
  color: var(--hx);
  margin-right: 4px;
  transform-origin: center;
  animation: hxHeartbeat 1.4s ease-in-out infinite;
  text-shadow:
    0 0 10px rgba(0, 255, 156, 0.95),
    0 0 24px rgba(0, 255, 156, 0.55);
}
@keyframes hxHeartbeat {
  0%, 100% { transform: scale(1); }
  14%      { transform: scale(1.32); }
  28%      { transform: scale(1); }
  42%      { transform: scale(1.22); }
  56%      { transform: scale(1); }
}

/* ---- feed terminal ---- */
#term-feed {
  display: flex;
  flex-direction: column-reverse;
  gap: 2px;
  margin-bottom: 6px;
  min-height: 0;
}
.feed-line {
  animation: hxFeedIn 0.25s ease-out;
  text-transform: none;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.feed-line:nth-child(2) { opacity: 0.75; }
.feed-line:nth-child(3) { opacity: 0.55; }
.feed-line:nth-child(4) { opacity: 0.4; }
.feed-line:nth-child(5) { opacity: 0.28; }
.feed-line:nth-child(6) { opacity: 0.16; }
.feed-time { color: rgba(217, 255, 239, 0.35); }
@keyframes hxFeedIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { transform: translateY(0); }
}

/* ---- ecranul de boot ---- */
#boot {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: var(--hx-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.8s ease;
}
#boot.off { opacity: 0; pointer-events: none; }
#boot pre {
  background: transparent;   /* suprascrie stilul pre din base.css */
  border: none;
  padding: 0;
  margin: 0;
  font-family: var(--mono);
  font-size: 14px;
  line-height: 2;
  color: var(--hx);
  text-shadow: 0 0 8px rgba(0, 255, 156, 0.45);
  text-align: left;
  min-width: 340px;
  min-height: 12em;
}

/* continutul intra dupa boot */
.intro-content h1,
.intro-motto,
.intro-social,
.hud {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.9s ease, transform 0.9s ease;
}
.booted .intro-content h1 { opacity: 1; transform: none; }
.booted .intro-motto  { opacity: 1; transform: none; transition-delay: 0.25s; }
.booted .intro-social { opacity: 1; transform: none; transition-delay: 0.45s; }
.booted .hud          { opacity: 1; transform: none; transition-delay: 0.6s; }

/* ---- responsive ---- */
@media (max-width: 760px) {
  .hud-br, .hud-tr { display: none; }
  .hud-tl { top: 16px; left: 18px; font-size: 10px; }
  .hud-bl {
    bottom: calc(16px + env(safe-area-inset-bottom));
    left: 18px;
    font-size: 10px;
    line-height: 1.9;
  }
  .live-line { font-size: 11px; }
  .intro-motto { font-size: 1.4rem; padding: 0 1rem; }

  /* iconitele sociale merg jos-dreapta, sa nu se suprapuna cu HUD-ul */
  .intro-social {
    left: auto;
    right: 18px;
    bottom: calc(18px + env(safe-area-inset-bottom));
    width: auto;
    font-size: 2.6rem;
    text-align: right;
  }
  .intro-social li { margin: 0 0 0 18px; }
}

/* ---- miscare redusa ---- */
@media (prefers-reduced-motion: reduce) {
  .live-heart,
  .intro-motto .motto-author,
  .hud .cursor { animation: none; }
  .intro-content h1:hover { animation: none; }
  .intro-content h1, .intro-motto, .intro-social, .hud {
    transition: none; opacity: 1; transform: none;
  }
}
