/* ==========================================================================
   Cyberpunk Animated Glitch Theme & Interactive Dossier Modal
   Vibrant Neon Cyan (#00f0ff), Cyber Magenta (#ff0055), Matrix Yellow (#ffe600)
   ========================================================================== */

/* --------------------------------------------------------------------------
   Glitch Animation & Chromatic Aberration
   -------------------------------------------------------------------------- */

@keyframes cyberGlitch {
  0% {
    text-shadow: 2px 0 var(--pink), -2px 0 var(--cyan);
    transform: translate(0, 0);
  }
  20% {
    text-shadow: -2px 0 var(--pink), 2px 0 var(--cyan);
    transform: translate(-1px, 1px);
  }
  40% {
    text-shadow: 2px -1px var(--pink), -2px 1px var(--cyan);
    transform: translate(1px, -1px);
  }
  60% {
    text-shadow: -1px 2px var(--pink), 1px -2px var(--cyan);
    transform: translate(-1px, -1px);
  }
  80% {
    text-shadow: 2px 0 var(--pink), -2px 0 var(--cyan);
    transform: translate(1px, 1px);
  }
  100% {
    text-shadow: -2px 0 var(--pink), 2px 0 var(--cyan);
    transform: translate(0, 0);
  }
}

@keyframes scanlineFlicker {
  0% { opacity: 0.15; }
  50% { opacity: 0.28; }
  100% { opacity: 0.15; }
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: scale(0.92) translateY(20px);
    filter: brightness(1.8) blur(4px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
    filter: brightness(1) blur(0px);
  }
}

/* --------------------------------------------------------------------------
   Interactive Cyberpunk Modal / HUD Dossier
   -------------------------------------------------------------------------- */

.cyber-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 3vw, 40px);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.cyber-modal.is-open {
  pointer-events: auto;
  opacity: 1;
}

.cyber-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 6, 12, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.cyber-modal__window {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 820px;
  max-height: 88vh;
  background: #060a12;
  border: 1px solid var(--cyan);
  border-radius: 8px;
  box-shadow:
    0 0 45px rgba(0, 240, 255, 0.35),
    0 0 100px rgba(255, 0, 85, 0.2),
    inset 0 0 30px rgba(0, 240, 255, 0.08);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modalSlideIn 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Cyberpunk decorative chamfers */
.cyber-modal__window::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 14px;
  height: 14px;
  border-top: 2px solid var(--pink);
  border-left: 2px solid var(--pink);
  pointer-events: none;
}
.cyber-modal__window::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 14px;
  height: 14px;
  border-bottom: 2px solid var(--pink);
  border-right: 2px solid var(--pink);
  pointer-events: none;
}

.cyber-modal__glitch-bar {
  height: 3px;
  width: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--pink), var(--yellow), var(--cyan));
  background-size: 300% 100%;
  animation: scanlineFlicker 3s infinite linear;
}

.cyber-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  border-bottom: 1px solid rgba(0, 240, 255, 0.2);
  background: rgba(10, 18, 30, 0.6);
}

.cyber-modal__tags {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cyber-modal__tag {
  font-family: var(--mono);
  font-size: clamp(8px, 0.7vw, 11px);
  font-weight: 700;
  letter-spacing: 0.25em;
  color: var(--cyan);
  text-shadow: 0 0 8px var(--cyan);
}

.cyber-modal__period {
  font-family: var(--mono);
  font-size: clamp(7.5px, 0.65vw, 10px);
  letter-spacing: 0.15em;
  color: var(--yellow);
  background: rgba(246, 224, 94, 0.12);
  border: 1px solid rgba(246, 224, 94, 0.35);
  padding: 2px 8px;
  border-radius: 4px;
}

.cyber-modal__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: rgba(255, 30, 80, 0.14);
  border: 1.5px solid #ff2255;
  color: #ff2255;
  font-family: var(--mono);
  font-size: clamp(9.5px, 0.75vw, 11.5px);
  font-weight: 700;
  letter-spacing: 0.16em;
  padding: 6px 14px;
  border-radius: 6px;
  cursor: pointer;
  box-shadow: 0 0 14px rgba(255, 30, 80, 0.4), inset 0 0 8px rgba(255, 30, 80, 0.15);
  text-shadow: 0 0 8px rgba(255, 30, 80, 0.8);
  transition: all 0.22s cubic-bezier(0.2, 0.8, 0.2, 1);
  touch-action: manipulation;
}

.cyber-modal__close-x {
  display: inline-block;
  font-size: 15px;
  line-height: 1;
  font-weight: 900;
  color: #ff2255;
  text-shadow: 0 0 10px #ff2255, 0 0 20px #ff2255;
  transition: transform 0.25s ease, color 0.2s ease;
}

.cyber-modal__close:hover,
.cyber-modal__close:focus-visible {
  background: #ff2255;
  color: #ffffff;
  border-color: #ff3366;
  box-shadow: 0 0 22px rgba(255, 30, 80, 0.85), 0 0 40px rgba(255, 30, 80, 0.45);
  text-shadow: 0 0 8px #ffffff;
  transform: translateY(-1px) scale(1.05);
}

.cyber-modal__close:hover .cyber-modal__close-x,
.cyber-modal__close:focus-visible .cyber-modal__close-x {
  color: #ffffff;
  text-shadow: 0 0 10px #ffffff;
  transform: rotate(90deg);
}

.cyber-modal__close:active {
  transform: scale(0.95);
}

.cyber-modal__body {
  padding: clamp(20px, 3vw, 32px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--cyan) #0a1018;
}

.cyber-modal__title {
  margin: 0 0 4px;
  font-family: var(--disp);
  font-size: clamp(20px, 2.5vw, 32px);
  font-weight: 500;
  letter-spacing: 0.08em;
  color: #fff;
  text-transform: uppercase;
  text-shadow: 0 0 12px rgba(0, 240, 255, 0.6);
}
.cyber-modal__title:hover {
  animation: cyberGlitch 0.4s ease infinite;
}

.cyber-modal__role {
  margin: 0 0 20px;
  font-family: var(--mono);
  font-size: clamp(9px, 0.8vw, 12px);
  letter-spacing: 0.15em;
  color: var(--cyan);
  text-shadow: 0 0 6px rgba(0, 240, 255, 0.4);
  text-transform: uppercase;
}

.cyber-modal__metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.cm-metric {
  background: rgba(10, 20, 32, 0.7);
  border: 1px solid rgba(0, 240, 255, 0.2);
  border-radius: 6px;
  padding: 10px 14px;
}
.cm-metric__label {
  display: block;
  font-family: var(--mono);
  font-size: 8px;
  letter-spacing: 0.2em;
  color: rgba(200, 220, 240, 0.6);
  margin-bottom: 4px;
}
.cm-metric__val {
  display: block;
  font-family: var(--disp);
  font-size: clamp(14px, 1.3vw, 18px);
  color: var(--yellow);
  letter-spacing: 0.08em;
  text-shadow: 0 0 8px rgba(246, 224, 94, 0.4);
}

.cyber-modal__section {
  margin-bottom: 22px;
}

.cyber-modal__sec-title {
  margin: 0 0 8px;
  font-family: var(--mono);
  font-size: clamp(8px, 0.65vw, 10px);
  font-weight: 700;
  letter-spacing: 0.25em;
  color: var(--pink);
  text-shadow: 0 0 6px var(--pink);
}

.cyber-modal__summary {
  margin: 0;
  font-family: var(--ui);
  font-size: clamp(13px, 1vw, 15px);
  line-height: 1.6;
  color: rgba(225, 238, 255, 0.88);
}

.cyber-modal__list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cyber-modal__list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-family: var(--ui);
  font-size: clamp(12px, 0.95vw, 14px);
  line-height: 1.5;
  color: rgba(215, 230, 250, 0.85);
}
.cyber-modal__list li span {
  color: var(--cyan);
  font-family: var(--mono);
  font-weight: 700;
  flex-shrink: 0;
}

.cyber-modal__tech {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.cm-pill {
  font-family: var(--mono);
  font-size: clamp(8px, 0.65vw, 10px);
  letter-spacing: 0.12em;
  color: var(--cyan);
  background: rgba(0, 240, 255, 0.08);
  border: 1px solid rgba(0, 240, 255, 0.25);
  padding: 4px 10px;
  border-radius: 4px;
}

.cyber-modal__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  border-top: 1px solid rgba(0, 240, 255, 0.2);
  background: rgba(6, 12, 20, 0.9);
}

.cyber-modal__socials {
  display: flex;
  align-items: center;
  gap: 14px;
}
.cm-soc-link {
  font-family: var(--mono);
  font-size: clamp(8px, 0.65vw, 10.5px);
  font-weight: 600;
  letter-spacing: 0.15em;
  color: var(--cyan);
  text-decoration: none;
  transition: all 0.2s ease;
}
.cm-soc-link:hover {
  color: #fff;
  text-shadow: 0 0 8px var(--cyan);
}

.cyber-modal__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.cyber-modal__live-btn {
  font-family: var(--mono);
  font-size: clamp(8px, 0.65vw, 10.5px);
  font-weight: 700;
  letter-spacing: 0.18em;
  color: #fff;
  background: var(--pink);
  padding: 6px 14px;
  border-radius: 4px;
  text-decoration: none;
  box-shadow: 0 0 15px rgba(255, 0, 85, 0.6);
  transition: all 0.2s ease;
}
.cyber-modal__live-btn:hover {
  background: #ff2b75;
  box-shadow: 0 0 25px rgba(255, 0, 85, 0.95);
  transform: translateY(-1px);
}

.cyber-modal__action-btn {
  font-family: var(--mono);
  font-size: clamp(8px, 0.65vw, 10.5px);
  font-weight: 700;
  letter-spacing: 0.18em;
  color: #000;
  background: var(--cyan);
  padding: 6px 14px;
  border-radius: 4px;
  text-decoration: none;
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.5);
  transition: all 0.2s ease;
}
.cyber-modal__action-btn:hover {
  background: #fff;
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.9);
  transform: translateY(-1px);
}

/* --------------------------------------------------------------------------
   Hover & Glitch feedback for interactive cards
   -------------------------------------------------------------------------- */

.uni-card, .yr, .g-card {
  cursor: pointer !important;
}

.uni-card:hover .uni-card__title,
.yr:hover .yr__key,
.g-card:hover .g-cyber-card__title {
  text-shadow: 0 0 10px var(--cyan), 2px 0 var(--pink);
}
