/* ============================================================
   LAYOUT — Sections, HUD, Grids — Neural Interface
   ============================================================ */

/* --- Main Content Container --- */
#mainContent {
  /* No custom scroll — uses native body scroll via Lenis */
}

/* --- Snap Section --- */
.snap-section {
  height: 100vh;
  width: 100%;
  position: relative;
  overflow: hidden;
  z-index: 10;
  background: var(--surface-dim);
  perspective: 1200px;
}

.section-inner {
  height: 100%;
  width: 100%;
  padding: var(--section-padding) var(--hud-padding);
  position: relative;
  display: flex;
  flex-direction: column;
}

/* --- Section Number + inline title --- */
.section-number {
  font-family: var(--font-headline);
  font-size: clamp(60px, 10vw, 120px);
  font-weight: 700;
  letter-spacing: -0.05em;
  opacity: 0.12;
  position: absolute;
  top: 40px;
  left: 40px;
  line-height: 1;
  pointer-events: none;
  z-index: 0;
  display: flex;
  align-items: baseline;
  gap: 16px;
}
.section-number .section-label {
  font-size: 24px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  opacity: 1;
}

/* Section number colors */
#profilePin .section-number,
#profileArea .section-number { color: #ffffff; }
#flipFront .section-number { color: #00e5ff; }
#flipBack .section-number { color: #d05bff; }
#projectsPin .section-number { color: #00ff9c; }
#neuralmap .section-number { color: #ff00ff; }
#contact .section-number { color: #ffaa00; }

/* --- Section Title (hidden, replaced by inline label) --- */
.section-title {
  display: none;
}

/* ============================================================
   HUD — Fixed overlay
   ============================================================ */
#hud {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
}

.hud-zone {
  position: absolute;
  pointer-events: auto;
}

/* Top Left: Socials */
.hud-top-left {
  top: var(--hud-padding);
  left: var(--hud-padding);
  display: flex;
  gap: 16px;
  align-items: center;
}

.hud-icon {
  color: var(--outline);
  opacity: 0.6;
  transition: color 0.3s, opacity 0.3s;
  text-decoration: none;
}
.hud-icon:hover {
  color: var(--primary-container);
  opacity: 1;
}

/* Top Right: Navigation */
.hud-top-right {
  top: var(--hud-padding);
  right: var(--hud-padding);
  display: flex;
  gap: 24px;
  align-items: center;
}

.hud-nav-link {
  font-family: var(--font-headline);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--outline);
  opacity: 0.6;
  transition: color 0.3s, opacity 0.3s;
  position: relative;
  padding-bottom: 4px;
  perspective: 400px;
  display: inline-block;
  overflow: hidden;
  height: 1.4em;
}

/* Inner text wrapper for 3D rotate — created by JS */
.hud-nav-link .nav-text {
  display: block;
  transition: transform 0.5s cubic-bezier(0.65, 0.05, 0, 1);
  transform-origin: center top;
  transform-style: preserve-3d;
}
.hud-nav-link .nav-text-hover {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  transform: rotateX(-90deg);
  transform-origin: center bottom;
  transition: transform 0.5s cubic-bezier(0.65, 0.05, 0, 1);
}

.hud-nav-link:hover .nav-text {
  transform: rotateX(90deg);
}
.hud-nav-link:hover .nav-text-hover {
  transform: rotateX(0deg);
}

/* Underline */
.hud-nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: currentColor;
  transition: width 0.4s cubic-bezier(0.65, 0.05, 0, 1);
}
.hud-nav-link:hover::after,
.hud-nav-link.active::after {
  width: 100%;
}
.hud-nav-link.active {
  opacity: 1;
}
.hud-nav-link[data-section="profile"]:hover { color: #ffffff; opacity: 1; }
.hud-nav-link[data-section="skills"]:hover { color: #00e5ff; opacity: 1; }
.hud-nav-link[data-section="experience"]:hover { color: #d05bff; opacity: 1; }
.hud-nav-link[data-section="projects"]:hover { color: #00ff9c; opacity: 1; }
.hud-nav-link[data-section="neuralmap"]:hover { color: #ff00ff; opacity: 1; }
.hud-nav-link[data-section="contact"]:hover { color: #ffaa00; opacity: 1; }


/* Section colors */
.section-01 .hud-nav-link.active { color: #ffffff; }
.section-01.p2-active .hud-nav-link.active { color: #131313; }
.section-01.p2-active .scroll-tracker__progress { background: #131313; box-shadow: 0 0 8px rgba(0,0,0,0.3); }
.section-01.p2-active .scroll-tracker__label { color: #131313; }
.section-02 .hud-nav-link.active { color: #00e5ff; }
.section-03 .hud-nav-link.active { color: #d05bff; }
.section-04 .hud-nav-link.active { color: #00ff9c; }
.section-05 .hud-nav-link.active { color: #ff00ff; }
.section-06 .hud-nav-link.active { color: #ffaa00; }

.section-01 .scroll-tracker__progress { background: #ffffff; box-shadow: 0 0 8px #ffffff; }
.section-02 .scroll-tracker__progress { background: #00e5ff; box-shadow: 0 0 8px #00e5ff; }
.section-03 .scroll-tracker__progress { background: #d05bff; box-shadow: 0 0 8px #d05bff; }
.section-04 .scroll-tracker__progress { background: #00ff9c; box-shadow: 0 0 8px #00ff9c; }
.section-05 .scroll-tracker__progress { background: #ff00ff; box-shadow: 0 0 8px #ff00ff; }
.section-06 .scroll-tracker__progress { background: #ffaa00; box-shadow: 0 0 8px #ffaa00; }

.section-01 .scroll-tracker__label { color: #ffffff; }
.section-02 .scroll-tracker__label { color: #00e5ff; }
.section-03 .scroll-tracker__label { color: #d05bff; }
.section-04 .scroll-tracker__label { color: #00ff9c; }
.section-05 .scroll-tracker__label { color: #ff00ff; }
.section-06 .scroll-tracker__label { color: #ffaa00; }

/* Right: Scroll Tracker */
.hud-right {
  right: var(--hud-padding);
  top: 50%;
  transform: translateY(-50%);
}

.scroll-tracker {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.scroll-tracker__bar {
  width: 2px;
  height: 120px;
  background: var(--surface-container-high);
  position: relative;
}

.scroll-tracker__progress {
  width: 100%;
  height: 0%;
  background: var(--primary-container);
  box-shadow: 0 0 8px var(--primary-container);
  transition: height 0.3s ease;
}

.scroll-tracker__label {
  font-family: var(--font-headline);
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--primary-container);
  writing-mode: vertical-rl;
  text-orientation: mixed;
}

/* Bottom Right: Tools */
.hud-bottom-right {
  bottom: var(--hud-padding);
  right: var(--hud-padding);
  display: flex;
  gap: 12px;
  align-items: center;
}

.hud-tool {
  background: none;
  border: 1px solid var(--ghost-border);
  color: var(--outline);
  opacity: 0.6;
  padding: 8px;
  cursor: pointer;
  transition: color 0.3s, opacity 0.3s, border-color 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}
.hud-tool:hover {
  color: #ffffff;
  opacity: 1;
  border-color: rgba(255, 255, 255, 0.3);
}
.hud-tool.disabled {
  opacity: 0.2;
  pointer-events: none;
}
.hud-tool.active {
  color: var(--primary-container);
  opacity: 1;
  border-color: rgba(0, 229, 255, 0.3);
}
.hud-tool.notif {
  animation: blink 1s infinite;
}

/* Bottom Left: Status */
.hud-bottom-left {
  bottom: var(--hud-padding);
  left: var(--hud-padding);
}

.hud-status {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ============================================================
   PROFILE — Pinned scroll morphing section
   ============================================================ */
.profile-scroll-area {
  height: 250vh;
  position: relative;
  z-index: 1;
}

.profile-pin {
  height: 100vh;
  width: 100%;
  position: fixed;
  top: 0;
  left: 0;
  overflow: hidden;
  background: transparent;
  z-index: 1;
}
.profile-pin.phase-p2 .section-number {
  color: #131313 !important;
  opacity: 1;
}
.profile-pin.phase-p2 .keyword-ticker__track span {
  color: #131313;
  opacity: 0.05;
}
.profile-pin.phase-p2 .profile-bio p {
  color: #2a2a2a;
}
.profile-pin.phase-p2 .profile-bio .bio-quote {
  color: #555555;
}
.profile-pin.phase-p2 .label-hud {
  color: #444444;
}
.profile-pin.phase-p2 .status-value {
  color: var(--primary);
  text-shadow: 1px 1px 3px black;
}
.profile-pin.phase-p2 .status-value--green { color: var(--success); }
.profile-pin.phase-p2 .status-value--purple { color: var(--secondary-container); }
.profile-pin.phase-p2 .status-value--gold { color: var(--warning); }

#bustContainer {
  position: absolute;
  inset: 0;
  z-index: 1;
  /* GSAP will animate: width, height, left, top, border-radius */
}
#bustContainer canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

.profile-name {
  font-family: var(--font-headline);
  font-size: clamp(48px, 12vw, 180px);
  font-weight: 700;
  line-height: 0.85;
  letter-spacing: -0.05em;
  text-transform: uppercase;
  color: var(--on-surface);
  mix-blend-mode: difference;
  text-align: center;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  pointer-events: none;
  white-space: nowrap;
}

/* Scroll invitation */
.scroll-invite {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  color: var(--outline);
  opacity: 0.4;
  animation: scrollBounce 2s ease-in-out infinite;
}
@keyframes scrollBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

.profile-definition {
  position: absolute;
  bottom: 80px;
  left: var(--hud-padding);
  max-width: 280px;
  z-index: 3;
}
.profile-definition p {
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.5;
  color: var(--on-surface-variant);
  margin-top: 8px;
}

/* Keyword tickers — multiple rows behind content */
.keyword-tickers {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
}

.keyword-ticker {
  overflow: hidden;
  width: 100%;
}

/* Bio — right side */
.profile-bio {
  position: absolute;
  right: 19%;
  top: 40%;
  transform: translateY(-50%);
  max-width: 420px;
  z-index: 3;
  opacity: 0;
}
.profile-bio p {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
  letter-spacing: 0.02em;
  color: var(--on-surface-variant);
}
.profile-bio .bio-quote {
  font-style: italic;
  opacity: 0.5;
  margin-top: 16px;
}

/* Status — left side */
.profile-status {
  position: absolute;
  left: 25%;
  bottom: 30%;
  display: flex;
  flex-direction: column;
  gap: 20px;
  z-index: 3;
  opacity: 0;
  text-align: right;
  transform: scale(1.5);
}
.profile-status .status-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.status-value {
  font-family: var(--font-headline);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--primary);
}
.status-value--green { color: var(--success); }
.status-value--purple { color: var(--secondary-container); }
.status-value--gold { color: var(--warning); }

.keyword-ticker__track {
  display: flex;
  gap: 50px;
  white-space: nowrap;
}

.keyword-ticker__track span {
  font-family: var(--font-headline);
  font-size: clamp(36px, 7vw, 80px);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: -0.03em;
  color: var(--on-surface);
  opacity: 0.04;
}

/* Directions */
.ticker--left .keyword-ticker__track {
  animation: tickerLeft linear infinite;
}
.ticker--right .keyword-ticker__track {
  animation: tickerRight linear infinite;
}

/* Speeds */
.ticker--fast .keyword-ticker__track  { animation-duration: 18s; }
.ticker--medium .keyword-ticker__track { animation-duration: 28s; }
.ticker--slow .keyword-ticker__track  { animation-duration: 40s; }

@keyframes tickerLeft {
  from { transform: translateX(0); }
  to { transform: translateX(-33.333%); }
}
@keyframes tickerRight {
  from { transform: translateX(-33.333%); }
  to { transform: translateX(0); }
}

/* (duplicates removed — see above) */

/* ============================================================
   FLIP CARD (02 Skills ↔ 03 Logs)
   ============================================================ */
.flip-scroll-area {
  height: 600vh; /* scroll room: skills build + flip + 3D timeline travel */
  position: relative;
  z-index: 10;
}

.flip-pin {
  height: 100vh;
  width: 100%;
  position: relative;
  perspective: 1500px;
}

.flip-card {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
}

.flip-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--section-padding) var(--hud-padding);
  background: var(--surface-dim);
  overflow: hidden;
}

.flip-front {
  z-index: 2;
}

.flip-back {
  transform: rotateY(180deg);
  z-index: 1;
}

.flip-back .section-inner {
  height: 100%;
  width: 100%;
}

/* ============================================================
   SKILLS (Section 2)
   ============================================================ */
/* Skills content is now inside .flip-front */

.skills-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  z-index: 1;
}

.skills-legend {
  display: flex;
  flex-direction: row;
  gap: 60px;
}

.skills-radar-wrap {
  z-index: 1;
}

.skills-tags-wrap {
  display: flex;
  gap: 60px;
  z-index: 1;
}

.skills-column {
  flex: 1;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* ============================================================
   MISSION LOGS (Section 3)
   ============================================================ */
/* ============================================================
   TIMELINE 3D (03 — inside flip-back)
   ============================================================ */
#timelineCanvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
  z-index: 1;
}

.timeline-vignette {
  position: absolute;
  z-index: 10;
  background: rgba(28, 27, 27, 0.92);
  border-left: 3px solid var(--primary-container);
  padding: 16px 20px;
  max-width: 300px;
  pointer-events: none;
  backdrop-filter: blur(8px);
}
.timeline-vignette.active {
  pointer-events: auto;
}
.timeline-vignette .vignette-date {
  font-family: var(--font-body);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--outline);
  font-variant-numeric: tabular-nums;
  margin-bottom: 4px;
}
.timeline-vignette h3 {
  font-family: var(--font-headline);
  font-size: 14px;
  font-weight: 600;
  color: var(--on-surface);
  margin-bottom: 6px;
}
.timeline-vignette p {
  font-family: var(--font-body);
  font-size: 12px;
  line-height: 1.5;
  color: var(--on-surface-variant);
}
.timeline-vignette .vignette-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 8px;
}
.timeline-vignette .vignette-type {
  font-family: var(--font-headline);
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-top: 8px;
}
.timeline-vignette .vignette-type.exp { color: var(--primary-container); }
.timeline-vignette .vignette-type.edu { color: var(--secondary-container); }

.timeline-legend {
  position: absolute;
  bottom: var(--hud-padding);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 32px;
  z-index: 5;
  align-items: center;
}
.timeline-legend .label-hud {
  display: flex;
  align-items: center;
  gap: 8px;
}

.logs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  flex: 1;
  overflow-y: auto;
  z-index: 1;
  padding-bottom: 40px;
}

.logs-column {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.log-item {
  position: relative;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.log-accent {
  position: absolute;
  left: 0;
  top: 0;
  width: 4px;
  height: 100%;
  background: var(--primary-container);
  opacity: 0.3;
  transition: opacity 0.3s;
}
.log-item.active .log-accent { opacity: 1; }

.log-date {
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--outline);
}

.log-item h4 {
  font-family: var(--font-headline);
  font-size: 15px;
  font-weight: 600;
  color: var(--on-surface);
}

.log-item p {
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: var(--on-surface-variant);
}

.log-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

/* --- HUD Chips --- */
.hud-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--surface-container-highest);
  font-family: var(--font-headline);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--secondary);
  padding: 4px 10px;
  border: none;
}

/* ============================================================
   PROJECTS — Horizontal scroll with 3D neon cards
   ============================================================ */
.projects-scroll-area {
  height: 700vh;
  position: relative;
  z-index: 10;
}

.projects-pin {
  height: 100vh;
  width: 100%;
  position: relative;
  overflow: hidden;
  background: var(--surface-dim);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--section-padding) 0;
}

.projects-track {
  display: flex;
  gap: 40px;
  padding: 0 calc(50vw - 160px) 0 calc(50vw - 160px);
  align-items: center;
  height: 60vh;
}
/* Extra space after last card so it centers */
.projects-track::after {
  content: '';
  flex-shrink: 0;
  width: calc(50vw - 160px);
}

/* ── 3D Card ── */
.project-card-3d {
  flex-shrink: 0;
  width: 320px;
  height: 420px;
  perspective: 800px;
  cursor: pointer;
}

.card-3d-inner {
  width: 100%;
  height: 100%;
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--surface-container-low);
  border: 1px solid rgba(0, 229, 255, 0.08);
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

/* Card color driven by status */
.project-card-3d { --card-color: 0, 229, 255; } /* default cyan */
.project-card-3d:has(.project-status--live) { --card-color: 0, 255, 156; }
.project-card-3d:has(.project-status--wip) { --card-color: 208, 91, 255; }
.project-card-3d:has(.project-status--concept) { --card-color: 132, 147, 150; }
.project-card-3d:has(.project-status--old) { --card-color: 255, 170, 0; }
.project-card-3d:has(.project-status--bp) { --card-color: 0, 229, 255; }

/* Neon glow on hover — uses card color */
.project-card-3d:hover .card-3d-inner {
  border-color: rgba(var(--card-color), 0.4);
  box-shadow:
    0 0 15px rgba(var(--card-color), 0.15),
    0 0 40px rgba(var(--card-color), 0.08),
    0 20px 60px rgba(0, 0, 0, 0.4);
}

/* Shine overlay */
.card-3d-inner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(var(--card-color), 0.06) 0%, transparent 50%, rgba(var(--card-color), 0.03) 100%);
  opacity: 0;
  transition: opacity 0.4s;
  pointer-events: none;
}
.project-card-3d:hover .card-3d-inner::before {
  opacity: 1;
}

/* Edge glow line at top */
.card-3d-inner::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(var(--card-color), 1), transparent);
  opacity: 0;
  transition: opacity 0.4s;
}
.project-card-3d:hover .card-3d-inner::after {
  opacity: 0.6;
}

.project-status {
  font-family: var(--font-headline);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 6px;
}
.project-status--live { color: var(--success); }
.project-status--wip { color: var(--secondary-container); }
.project-status--concept { color: var(--outline); }
.project-status--old { color: var(--warning); }
.project-status--bp { color: #00e5ff; }

.card-3d-inner h3 {
  font-family: var(--font-headline);
  font-size: 20px;
  font-weight: 600;
  color: var(--on-surface);
}

.card-3d-inner p {
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.6;
  color: var(--on-surface-variant);
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: auto;
}

/* ============================================================
   NEURAL MAP (Section 5)
   ============================================================ */
.neuralmap-layout {
  align-items: center;
  justify-content: center;
  background: #1a1025;
  padding: var(--section-padding) var(--hud-padding);
}

.neural-content {
  display: flex;
  gap: 60px;
  align-items: flex-start;
  z-index: 1;
  width: 100%;
  max-width: 900px;
}

.neural-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
}

.neural-item {
  font-family: var(--font-headline);
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--outline);
  padding: 8px 16px;
  cursor: pointer;
  transition: color 0.2s, background 0.2s, padding-left 0.2s;
  white-space: nowrap;
}
.neural-item:hover {
  color: #ff00ff;
  background: rgba(255, 0, 255, 0.06);
  padding-left: 24px;
}

.neural-card {
  flex: 1;
  padding: 32px;
  background: rgba(255, 0, 255, 0.04);
  border-left: 3px solid #ff00ff;
  animation: cardSlideIn 0.3s ease-out;
}
@keyframes cardSlideIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

.neural-card__emoji {
  font-size: 48px;
  margin-bottom: 16px;
  animation: emojiFloat 2s ease-in-out infinite;
}
@keyframes emojiFloat {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-6px) rotate(3deg); }
  75% { transform: translateY(4px) rotate(-3deg); }
}

.neural-card__title {
  font-family: var(--font-headline);
  font-size: 18px;
  font-weight: 600;
  color: #ff00ff;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.neural-card__desc {
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.6;
  color: var(--on-surface-variant);
}

#neuralCanvas {
  width: 100%;
  height: 70vh;
  z-index: 1;
}

/* ============================================================
   CONTACT (Section 6)
   ============================================================ */
.contact-layout {
  align-items: center;
  justify-content: center;
  gap: 40px;
  text-align: center;
}

.contact-links {
  display: flex;
  gap: 24px;
  z-index: 1;
}

.contact-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 32px 40px;
  background: var(--surface-container);
  color: var(--on-surface-variant);
  text-decoration: none;
  transition: color 0.3s, box-shadow 0.3s;
}
.contact-card:hover {
  box-shadow: 0 20px 40px rgba(255, 170, 0, 0.1);
}
.contact-card .label-hud {
  color: #ffaa00;
}
.contact-card svg {
  stroke: #ffaa00;
}
.contact-card.hud-corner::before {
  border-color: #ffaa00;
}
.contact-card span:last-child {
  font-family: var(--font-body);
  font-size: 12px;
}

.contact-legacy {
  z-index: 1;
}
.contact-legacy a {
  font-family: var(--font-headline);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--outline);
  text-decoration: none;
  transition: color 0.3s;
}
.contact-legacy a:hover { color: var(--primary-container); }

.contact-footer {
  position: absolute;
  bottom: var(--hud-padding);
  color: var(--outline);
}

/* ============================================================
   LOGIN SCREEN
   ============================================================ */
#loginScreen {
  position: fixed;
  inset: 0;
  z-index: 210;
  background: var(--surface-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.login-bg-text {
  position: absolute;
  inset: 0;
  display: flex;
  flex-wrap: wrap;
  align-content: center;
  justify-content: center;
  gap: 14px 24px;
  padding: 40px;
  pointer-events: none;
  overflow: hidden;
}

.login-bg-text span {
  font-family: var(--font-headline);
  font-size: clamp(11px, 2vw, 18px);
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--on-surface);
  opacity: 0.05;
  line-height: 2.4;
  white-space: nowrap;
  transition: opacity 0.3s;
}

#loginCTA {
  position: relative;
  z-index: 2;
  font-family: var(--font-headline);
  font-size: 13px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--on-primary);
  border: none;
  padding: 16px 48px;
  cursor: pointer;
  font-weight: 600;
  transition: box-shadow 0.3s;
  animation: ctaColorCycle 8s linear infinite;
}
#loginCTA:hover {
  animation-play-state: paused;
  background: #ffffff;
  color: #131313;
  box-shadow: 0 0 40px rgba(255, 255, 255, 0.3);
}

@keyframes ctaColorCycle {
  0%      { background: #00e5ff; } /* cyan */
  20%     { background: #d05bff; } /* violet */
  40%     { background: #00ff9c; } /* green */
  60%     { background: #ff00ff; } /* magenta */
  80%     { background: #ffaa00; } /* gold */
  100%    { background: #00e5ff; } /* back to cyan */
}

/* ============================================================
   BOOT SCREEN
   ============================================================ */
#bootScreen {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--surface-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.boot-wrapper {
  position: relative;
  z-index: 1;
  width: 70%;
  max-width: 900px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

#bootLogoScene {
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 55vh;
  position: relative;
}
#bootLogoScene canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

#bootCorpLabel {
  font-family: var(--font-headline);
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 700;
  letter-spacing: 0.15em;
  color: transparent;
  -webkit-text-stroke: 1px var(--primary-container);
  text-shadow: none;
  position: absolute;
  bottom: 12%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  white-space: nowrap;
}

/* ── Boot terminal popups ── */
.boot-popup {
  position: absolute;
  z-index: 2;
  width: clamp(180px, 20vw, 260px);
  max-height: 160px;
  overflow: hidden;
  background: rgba(28, 27, 27, 0.6);
  border: 1px solid rgba(0, 229, 255, 0.08);
  padding: 10px 12px;
  font-family: var(--font-headline);
  font-size: 9px;
  line-height: 1.6;
  letter-spacing: 0.05em;
  color: var(--outline);
  opacity: 0;
}
.boot-popup::before {
  content: '> TERMINAL';
  display: block;
  color: var(--popup-color, var(--primary-container));
  opacity: 0.4;
  font-size: 8px;
  letter-spacing: 0.2em;
  margin-bottom: 6px;
}
.boot-popup .popup-line {
  opacity: 0.6;
}
.boot-popup .popup-line.highlight {
  color: var(--primary-container);
  opacity: 0.8;
}

@media (max-width: 768px) {
  .boot-wrapper {
    width: 98%;
  }
}

/* ── Fixer notification on status ── */
.fixer-notif {
  cursor: pointer;
  animation: fixerPulse 1s ease-in-out infinite;
  position: relative;
}
.fixer-notif::after {
  content: '1';
  position: absolute;
  top: -6px;
  right: -10px;
  width: 16px;
  height: 16px;
  background: #ff3344;
  color: #fff;
  font-family: var(--font-headline);
  font-size: 9px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
}
@keyframes fixerPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* ============================================================
   FIXER / ALFRED — Cyberpunk 2077 Style
   ============================================================ */

/* ── Incoming Call ── */
.fixer-call {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 300;
}

.fixer-call__frame {
  width: 320px;
  background: rgba(10, 10, 10, 0.95);
  border: 2px solid #ff3344;
  box-shadow: 0 0 40px rgba(255, 51, 68, 0.15), inset 0 0 30px rgba(255, 51, 68, 0.05);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: callPulse 2s ease-in-out infinite;
}
@keyframes callPulse {
  0%, 100% { box-shadow: 0 0 40px rgba(255, 51, 68, 0.15), inset 0 0 30px rgba(255, 51, 68, 0.05); }
  50% { box-shadow: 0 0 60px rgba(255, 51, 68, 0.25), inset 0 0 40px rgba(255, 51, 68, 0.08); }
}

.fixer-call__header {
  padding: 10px 16px;
  border-bottom: 1px solid rgba(255, 51, 68, 0.2);
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.fixer-call__signal {
  font-family: var(--font-headline);
  font-size: 9px;
  letter-spacing: 0.2em;
  color: #ff3344;
  opacity: 0.6;
}
.fixer-call__name {
  font-family: var(--font-headline);
  font-size: 22px;
  font-weight: 700;
  color: var(--on-surface);
  letter-spacing: 0.05em;
}

.fixer-call__avatar {
  position: relative;
  height: 300px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #050505;
}
.fixer-call__avatar img {
  width: 120%;
  padding-top: 165px;
  filter: brightness(1.6);
}
.fixer-call__scanline {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(255, 51, 68, 0.03) 2px,
    rgba(255, 51, 68, 0.03) 4px
  );
  pointer-events: none;
}

.fixer-call__actions {
  display: flex;
  border-top: 1px solid rgba(255, 51, 68, 0.2);
}

.fixer-btn {
  flex: 1;
  font-family: var(--font-headline);
  font-size: 11px;
  letter-spacing: 0.2em;
  padding: 14px;
  border: none;
  cursor: pointer;
  text-transform: uppercase;
  transition: background 0.2s;
}
.fixer-btn--answer {
  background: rgba(255, 51, 68, 0.15);
  color: #ff3344;
  border-right: 1px solid rgba(255, 51, 68, 0.2);
}
.fixer-btn--answer:hover {
  background: #ff3344;
  color: #0a0a0a;
}
.fixer-btn--dismiss {
  background: rgba(255, 255, 255, 0.03);
  color: var(--outline);
}
.fixer-btn--dismiss:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--on-surface);
}

/* ── Chat Window ── */
.fixer-chat {
  position: fixed;
  bottom: 60px;
  right: var(--hud-padding);
  z-index: 300;
  width: 400px;
  max-height: 600px;
}

.fixer-chat__frame {
  background: rgba(10, 10, 10, 0.95);
  border: 2px solid #ff3344;
  box-shadow: 0 0 30px rgba(255, 51, 68, 0.1);
  display: flex;
  flex-direction: column;
  max-height: 580px;
}

.fixer-chat__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 51, 68, 0.15);
  background: rgba(255, 51, 68, 0.04);
}

.fixer-chat__contact {
  display: flex;
  align-items: center;
  gap: 10px;
}

.fixer-chat__thumb-wrap {
  width: 44px;
  height: 44px;
  overflow: hidden;
  border: 1px solid rgba(255, 51, 68, 0.3);
  flex-shrink: 0;
}
.fixer-chat__thumb {
  width: 160%;
  margin-top: -54%;
  margin-left: -28%;
  filter: brightness(1.2);
}

.fixer-chat__name {
  font-family: var(--font-headline);
  font-size: 13px;
  font-weight: 600;
  color: var(--on-surface);
  letter-spacing: 0.05em;
  display: block;
}

.fixer-chat__status {
  font-family: var(--font-headline);
  font-size: 9px;
  letter-spacing: 0.15em;
  color: #ff3344;
  display: block;
}

.fixer-chat__close {
  background: none;
  border: none;
  color: var(--outline);
  cursor: pointer;
  font-size: 16px;
  padding: 4px 8px;
  transition: color 0.2s;
}
.fixer-chat__close:hover {
  color: #ff3344;
}

.fixer-chat__body {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 250px;
  max-height: 400px;
  scrollbar-width: thin;
  scrollbar-color: #ff3344 rgba(255, 51, 68, 0.08);
}
.fixer-chat__body::-webkit-scrollbar { width: 5px; }
.fixer-chat__body::-webkit-scrollbar-track { background: rgba(255, 51, 68, 0.08); }
.fixer-chat__body::-webkit-scrollbar-thumb { background: #ff3344; border-radius: 2px; }
.fixer-chat__body::-webkit-scrollbar-thumb:hover { background: #ff5566; }

/* Message bubbles */
.fixer-chat__body .msg-alfred {
  align-self: flex-start;
  background: rgba(255, 51, 68, 0.06);
  border-left: 2px solid #ff3344;
  padding: 10px 14px;
  max-width: 85%;
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.5;
  color: var(--on-surface-variant);
  white-space: pre-wrap;
}

.msg-alfred .msg-deco {
  color: #ff3344;
}

.msg-alfred .msg-ascii {
  display: block;
  font-family: 'Space Grotesk', 'Courier New', monospace;
  font-size: 10px;
  line-height: 1.15;
  white-space: pre;
  color: #ff3344;
  margin-bottom: 8px;
}

.fixer-chat__body .msg-user {
  align-self: flex-end;
  background: rgba(0, 229, 255, 0.08);
  border-right: 2px solid var(--primary-container);
  padding: 10px 14px;
  max-width: 85%;
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1.5;
  color: var(--on-surface);
}

.fixer-chat__input {
  display: flex;
  border-top: 1px solid rgba(255, 51, 68, 0.15);
}
.fixer-chat__input input {
  flex: 1;
  background: rgba(255, 255, 255, 0.03);
  border: none;
  padding: 14px 16px;
  color: var(--on-surface);
  font-family: var(--font-headline);
  font-size: 12px;
  letter-spacing: 0.03em;
  outline: none;
}
.fixer-chat__input input::placeholder {
  color: var(--outline);
  opacity: 0.5;
}
.fixer-chat__input button {
  background: rgba(255, 51, 68, 0.12);
  color: #ff3344;
  border: none;
  padding: 14px 20px;
  font-family: var(--font-headline);
  font-size: 11px;
  letter-spacing: 0.15em;
  cursor: pointer;
  transition: background 0.2s;
}
.fixer-chat__input button:hover {
  background: #ff3344;
  color: #0a0a0a;
}
