/* ═══════════════════════════════════════════
   Computer Complex — Illustrated & Animated
   Decorative elements (all aria-hidden)
   ═══════════════════════════════════════════ */

/* ─────────────────────────────────────────
   HERO: DOT-GRID BACKGROUND
───────────────────────────────────────── */
.hero-section { position: relative; }
.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(28,173,228,.10) 1.5px, transparent 1.5px);
  background-size: 28px 28px;
  pointer-events: none;
  z-index: 0;
  /* fade dots in only on the right half where the illustration lives */
  mask-image: linear-gradient(90deg, transparent 0%, transparent 38%, black 62%, black 100%);
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, transparent 38%, black 62%, black 100%);
}
.hero-section > .container { position: relative; z-index: 1; }

/* ─────────────────────────────────────────
   HERO: TERMINAL ILLUSTRATION
───────────────────────────────────────── */
.hero-illus-wrap {
  position: relative;
  width: 100%;
  height: 460px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-terminal {
  width: 330px;
  background: #0C1824;
  border-radius: 14px;
  box-shadow:
    0 0 0 1px rgba(28,173,228,.22),
    0 6px 48px rgba(28,173,228,.18),
    0 28px 70px rgba(0,0,0,.40);
  position: relative;
  z-index: 2;
  overflow: hidden;
  animation: termGlow 4s ease-in-out infinite;
}
@keyframes termGlow {
  0%,100% { box-shadow: 0 0 0 1px rgba(28,173,228,.22), 0 6px 48px rgba(28,173,228,.15), 0 28px 70px rgba(0,0,0,.40); }
  50%      { box-shadow: 0 0 0 1px rgba(28,173,228,.40), 0 6px 60px rgba(28,173,228,.32), 0 28px 70px rgba(0,0,0,.40); }
}

/* Chrome bar */
.term-chrome {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 11px 14px;
  background: rgba(255,255,255,.05);
  border-bottom: 1px solid rgba(255,255,255,.07);
}
.tch-dot {
  width: 11px; height: 11px;
  border-radius: 50%;
  flex-shrink: 0;
}
.tch-dot.red    { background: #FF5F57; box-shadow: 0 0 5px rgba(255,95,87,.6); }
.tch-dot.yellow { background: #FEBC2E; box-shadow: 0 0 5px rgba(254,188,46,.6); }
.tch-dot.green  { background: #28C840; box-shadow: 0 0 5px rgba(40,200,64,.6); }
.term-title-bar {
  font-size: .64rem;
  font-family: 'SF Mono', 'Fira Code', 'Courier New', monospace;
  color: rgba(255,255,255,.28);
  margin: 0 auto;
  padding-right: 30px;
  letter-spacing: .04em;
}

/* Body */
.term-body {
  padding: 16px;
  font-family: 'SF Mono', 'Fira Code', 'Courier New', monospace;
  font-size: .78rem;
  line-height: 1.75;
}
.term-row {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 22px;
}
.term-ps { color: #1CADE4; font-weight: 700; flex-shrink: 0; }
#typeTarget { color: #E2E8F0; }
.term-caret {
  display: inline-block;
  width: 7px; height: 15px;
  background: #1CADE4;
  border-radius: 1px;
  vertical-align: middle;
  flex-shrink: 0;
  animation: caretBlink .85s step-end infinite;
}
@keyframes caretBlink { 0%,49%{ opacity:1 } 50%,100%{ opacity:0 } }

.term-outputs { margin-top: 14px; display: flex; flex-direction: column; gap: 5px; }
.term-out-line {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .73rem;
  opacity: 0;
  animation: lineSlideIn .4s cubic-bezier(.22,1,.36,1) forwards;
}
.term-out-line:nth-child(1) { animation-delay: .9s; }
.term-out-line:nth-child(2) { animation-delay: 1.4s; }
.term-out-line:nth-child(3) { animation-delay: 1.9s; }
@keyframes lineSlideIn {
  from { opacity:0; transform: translateX(-8px); }
  to   { opacity:1; transform: translateX(0); }
}
.out-ok  { color: #28C840; font-size: .68rem; }
.out-arr { color: rgba(255,255,255,.3); }
.out-txt { color: rgba(255,255,255,.48); }

/* Scanline texture overlay */
.term-scanline {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg, transparent, transparent 2px,
    rgba(0,0,0,.04) 2px, rgba(0,0,0,.04) 4px
  );
  pointer-events: none;
  border-radius: 14px;
}

/* ─────────────────────────────────────────
   HERO: FLOATING SKILL CHIPS
───────────────────────────────────────── */
.skill-chip {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px 5px 8px;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(28,173,228,.18);
  border-radius: 20px;
  font-size: .72rem;
  font-weight: 600;
  color: var(--charcoal);
  box-shadow: 0 2px 14px rgba(0,0,0,.10);
  white-space: nowrap;
  z-index: 3;
  cursor: default;
}
.chip-pip {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--blue);
  flex-shrink: 0;
}

/* 8 unique float paths — varied speeds + delays */
@keyframes cf1 { 0%,100%{transform:translate(0,0) rotate(-1.5deg)} 40%{transform:translate(7px,-13px) rotate(1deg)} 70%{transform:translate(-4px,-6px) rotate(-.5deg)} }
@keyframes cf2 { 0%,100%{transform:translate(0,0) rotate(1deg)} 35%{transform:translate(-9px,-15px) rotate(-2deg)} 65%{transform:translate(6px,-4px) rotate(.5deg)} }
@keyframes cf3 { 0%,100%{transform:translate(0,0) rotate(-.5deg)} 45%{transform:translate(11px,-9px) rotate(2deg)} 75%{transform:translate(3px,7px) rotate(-1deg)} }
@keyframes cf4 { 0%,100%{transform:translate(0,0) rotate(2deg)} 30%{transform:translate(-5px,-17px) rotate(-1deg)} 60%{transform:translate(8px,-9px) rotate(1.5deg)} }
@keyframes cf5 { 0%,100%{transform:translate(0,0) rotate(-2deg)} 50%{transform:translate(-11px,-11px) rotate(1deg)} 80%{transform:translate(5px,5px) rotate(-1.5deg)} }
@keyframes cf6 { 0%,100%{transform:translate(0,0) rotate(.5deg)} 40%{transform:translate(9px,-19px) rotate(-1deg)} 70%{transform:translate(-7px,-7px) rotate(2deg)} }
@keyframes cf7 { 0%,100%{transform:translate(0,0) rotate(-1deg)} 35%{transform:translate(4px,-13px) rotate(2deg)} 65%{transform:translate(-9px,-5px) rotate(-.5deg)} }
@keyframes cf8 { 0%,100%{transform:translate(0,0) rotate(1.5deg)} 45%{transform:translate(-7px,-11px) rotate(-2deg)} 75%{transform:translate(7px,-15px) rotate(1deg)} }

/* Positions around the terminal card */
.sc1 { animation: cf1 4.8s ease-in-out infinite;         top:8%;  left:0; }
.sc2 { animation: cf2 5.3s ease-in-out infinite  .7s;    top:4%;  right:0; }
.sc3 { animation: cf3 4.4s ease-in-out infinite  .3s;    top:37%; right:0; }
.sc4 { animation: cf4 5.8s ease-in-out infinite 1.1s;    bottom:26%; right:0; }
.sc5 { animation: cf5 4.1s ease-in-out infinite  .5s;    bottom:8%; right:2%; }
.sc6 { animation: cf6 5.0s ease-in-out infinite  .9s;    bottom:4%; left:50%; margin-left:-56px; }
.sc7 { animation: cf7 4.6s ease-in-out infinite  .2s;    bottom:18%; left:0; }
.sc8 { animation: cf8 5.5s ease-in-out infinite  .4s;    top:36%; left:0; }

@media (max-width: 1040px) { .skill-chip { display: none; } }
@media (prefers-reduced-motion: reduce) {
  .hero-terminal { animation: none !important; }
  .skill-chip { animation: none !important; }
  .term-caret { animation: caretBlink .85s step-end infinite; } /* keep cursor */
}

/* ─────────────────────────────────────────
   WAVE DIVIDERS (between sections)
───────────────────────────────────────── */
.wave-div {
  display: block;
  width: 100%;
  overflow: hidden;
  line-height: 0;
  position: relative;
  margin: 0;
}
/* Each wave SVG is 200% wide and slides left so the seam is hidden */
.wave-div svg {
  display: block;
  width: 200%;
  animation: waveScroll 14s linear infinite;
}
.wave-div.wave-slow svg { animation-duration: 20s; }
.wave-div.wave-rev  svg { animation-direction: reverse; }
@keyframes waveScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .wave-div svg { animation: none; }
}

/* ─────────────────────────────────────────
   CTA STRIPS: FLOATING ORB SHAPES
───────────────────────────────────────── */
.cta-strip,
.cta-strip-dark { position: relative; overflow: hidden; }

.cta-strip::before, .cta-strip-dark::before {
  content: '';
  position: absolute;
  width: 300px; height: 300px;
  border-radius: 50%;
  top: -110px; left: -70px;
  pointer-events: none;
  animation: orbDrift 13s ease-in-out infinite;
}
.cta-strip::before    { background: rgba(255,255,255,.055); }
.cta-strip-dark::before { background: rgba(28,173,228,.06); }

.cta-strip::after, .cta-strip-dark::after {
  content: '';
  position: absolute;
  width: 200px; height: 200px;
  border-radius: 50%;
  bottom: -80px; right: -40px;
  pointer-events: none;
  animation: orbDrift 17s ease-in-out infinite -7s;
}
.cta-strip::after    { background: rgba(255,255,255,.04); }
.cta-strip-dark::after { background: rgba(28,173,228,.04); }

@keyframes orbDrift {
  0%,100% { transform: translate(0,0) scale(1); }
  33%      { transform: translate(22px,-18px) scale(1.06); }
  66%      { transform: translate(-12px,22px) scale(.94); }
}

/* Extra concentric rings in CTA */
.cta-ring {
  position: absolute;
  border-radius: 50%;
  border: 1.5px solid rgba(255,255,255,.09);
  pointer-events: none;
  animation: ringPulse 7s ease-in-out infinite;
}
.cr1 { width:110px; height:110px; left:6%;  top:50%; margin-top:-55px;  animation-delay:0s; }
.cr2 { width: 70px; height: 70px; left:9%;  top:50%; margin-top:-35px;  animation-delay:.6s; }
.cr3 { width: 80px; height: 80px; right:7%; bottom:10%;                  animation-delay:2.2s; }
.cr4 { width: 44px; height: 44px; right:14%;top:18%;                     animation-delay:1.6s; }
.cr5 { width:140px; height:140px; left:50%; top:50%; margin:-70px 0 0 -200px; animation-delay:3.5s; }
@keyframes ringPulse {
  0%,100% { transform: scale(1);   opacity: .5; }
  50%      { transform: scale(1.2); opacity: .2; }
}

/* ─────────────────────────────────────────
   PAGE-HERO: GRADIENT ORB BACKGROUND
   (all inner pages — Courses, About, etc.)
───────────────────────────────────────── */
.page-hero { position: relative; overflow: hidden; }
.page-hero::before {
  content: '';
  position: absolute;
  width: 380px; height: 380px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(28,173,228,.09) 0%, transparent 68%);
  right: -80px; top: -100px;
  pointer-events: none;
  animation: orbDrift 14s ease-in-out infinite;
}
.page-hero::after {
  content: '';
  position: absolute;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(28,173,228,.05) 0%, transparent 70%);
  right: 140px; bottom: -60px;
  pointer-events: none;
  animation: orbDrift 18s ease-in-out infinite -6s;
}

/* ─────────────────────────────────────────
   TRUST SECTION: GRID TEXTURE
───────────────────────────────────────── */
.trust-section { position: relative; overflow: hidden; }
.trust-section::before {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(28,173,228,.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(28,173,228,.055) 1px, transparent 1px);
  background-size: 36px 36px;
  pointer-events: none;
  z-index: 0;
}
.trust-inner { position: relative; z-index: 1; }


/* ─────────────────────────────────────────
   COURSES PAGE: MARQUEE TAG STRIP
───────────────────────────────────────── */
.course-tag-strip {
  display: flex;
  gap: 0;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, black 8%, black 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, black 8%, black 92%, transparent);
  margin-top: 24px;
  padding-bottom: 2px;
}
.cts-inner {
  display: flex;
  gap: 14px;
  flex-shrink: 0;
  padding-right: 14px;
  animation: tagMarquee 32s linear infinite;
}
@keyframes tagMarquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-100%); }
}
.ctag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: .75rem;
  font-weight: 600;
  border: 1px solid var(--border);
  background: white;
  color: var(--muted);
  white-space: nowrap;
  flex-shrink: 0;
  user-select: none;
}
.ctag-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--blue); flex-shrink: 0; }
@media (prefers-reduced-motion: reduce) {
  .cts-inner { animation: none; }
}

/* ─────────────────────────────────────────
   CONTACT PAGE: MAP PIN PING
───────────────────────────────────────── */
.ping-wrap {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.ping-ring {
  position: absolute;
  inset: 0;
  border-radius: 9px;
  background: var(--blue);
  opacity: 0;
  pointer-events: none;
  animation: pingAnim 2.8s ease-out infinite;
}
.ping-ring:nth-child(2) { animation-delay: 1.4s; }
@keyframes pingAnim {
  0%   { transform: scale(1); opacity: .45; }
  100% { transform: scale(2.6); opacity: 0; }
}

/* ─────────────────────────────────────────
   ABOUT PAGE: ANIMATED TIMELINE SPINE
───────────────────────────────────────── */
.milestone-list {
  position: relative;
  padding-left: 0;
}
.timeline-spine {
  position: absolute;
  left: 4px; /* centre of the 10px dot */
  top: 10px;
  bottom: 10px;
  width: 2px;
  background: var(--border);
  border-radius: 2px;
}
.timeline-fill {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, var(--blue), rgba(28,173,228,.25));
  border-radius: 2px;
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 1.5s cubic-bezier(.22,1,.36,1);
}
.milestone-list.spine-lit .timeline-fill { transform: scaleY(1); }

/* Dots fire in sequence after spine */
.milestone-dot { position: relative; z-index: 1; }
.milestone-list.spine-lit .milestone-item:nth-child(1) .milestone-dot { animation: dotFire .45s cubic-bezier(.34,1.56,.64,1) .25s both; }
.milestone-list.spine-lit .milestone-item:nth-child(2) .milestone-dot { animation: dotFire .45s cubic-bezier(.34,1.56,.64,1) .65s both; }
.milestone-list.spine-lit .milestone-item:nth-child(3) .milestone-dot { animation: dotFire .45s cubic-bezier(.34,1.56,.64,1) 1.05s both; }
@keyframes dotFire {
  0%  { transform: scale(0); box-shadow: 0 0 0 0   rgba(28,173,228,.6); }
  55% { transform: scale(1.7); box-shadow: 0 0 0 10px rgba(28,173,228,.1); }
  100%{ transform: scale(1);  box-shadow: 0 0 0 4px rgba(28,173,228,.12); }
}

/* ─────────────────────────────────────────
   INDUSTRIAL TRAINING: STEP PROGRESS TRACK
───────────────────────────────────────── */
.it-steps-wrap {
  position: relative;
}
.step-track {
  position: absolute;
  top: 50px; /* 32px it-step padding-top + 18px half badge height */
  left: 12.5%; /* starts from center of step 1 */
  right: 12.5%; /* ends at center of step 4 */
  height: 2px;
  background: var(--border);
  margin-top: -1px;
  z-index: 1; /* above it-step hover background */
  pointer-events: none;
  border-radius: 2px;
  overflow: visible;
}
.step-track-fill {
  position: absolute;
  top: 0; left: 0;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--blue), rgba(28,173,228,.5));
  border-radius: 2px;
  transition: width 1.8s cubic-bezier(.22,1,.36,1);
  box-shadow: 0 0 8px rgba(28,173,228,.45);
}
.it-steps-wrap.track-lit .step-track-fill { width: 100%; }
.it-step { position: relative; }

/* Step number circles */
.step-num-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--blue-bg);
  border: 2px solid var(--border);
  color: var(--blue);
  font-size: .8rem;
  font-weight: 700;
  font-family: 'SF Mono', 'Fira Code', monospace;
  margin: 0 auto 12px;
  transition: background .3s ease, border-color .3s ease, box-shadow .3s ease;
  position: relative;
  z-index: 2;
}
.it-steps-wrap.track-lit .it-step:nth-child(1) .step-num-badge { animation: badgePop .4s cubic-bezier(.34,1.56,.64,1) .1s both; }
.it-steps-wrap.track-lit .it-step:nth-child(2) .step-num-badge { animation: badgePop .4s cubic-bezier(.34,1.56,.64,1) .65s both; }
.it-steps-wrap.track-lit .it-step:nth-child(3) .step-num-badge { animation: badgePop .4s cubic-bezier(.34,1.56,.64,1) 1.2s both; }
.it-steps-wrap.track-lit .it-step:nth-child(4) .step-num-badge { animation: badgePop .4s cubic-bezier(.34,1.56,.64,1) 1.75s both; }
@keyframes badgePop {
  0%  { transform: scale(.6); background: var(--blue-bg); border-color: var(--border); }
  55% { transform: scale(1.2); background: var(--blue); border-color: var(--blue); color: white; box-shadow: 0 0 16px rgba(28,173,228,.5); }
  100%{ transform: scale(1);   background: var(--blue); border-color: var(--blue); color: white; box-shadow: 0 0 8px rgba(28,173,228,.3); }
}

@media (max-width: 720px) {
  .step-track { display: none; }
}

/* ─────────────────────────────────────────
   ABOUT PAGE: FLOATING PARTICLE DOTS in hero
───────────────────────────────────────── */
.particle-field {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}
.particle-field > span {
  position: absolute;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--blue);
  opacity: 0;
  animation: particleFly var(--dur,6s) ease-in-out var(--delay,0s) infinite;
}
@keyframes particleFly {
  0%   { opacity: 0; transform: translate(0,0) scale(.8); }
  15%  { opacity: .6; }
  85%  { opacity: .3; }
  100% { opacity: 0; transform: translate(var(--tx,20px), var(--ty,-40px)) scale(1.2); }
}

/* ─────────────────────────────────────────
   SECTION SPARKLE DOTS (subtle accent)
───────────────────────────────────────── */
.sparkle-dot {
  display: inline-block;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--blue);
  animation: sparklePop 2s ease-in-out infinite;
}
.sparkle-dot:nth-child(2) { animation-delay: .5s; }
.sparkle-dot:nth-child(3) { animation-delay: 1s; }
@keyframes sparklePop {
  0%,100% { transform: scale(1);   opacity: .5; }
  50%      { transform: scale(1.6); opacity: 1; }
}

/* ─────────────────────────────────────────
   REDUCE-MOTION: blanket disable
───────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .wave-div svg,
  .ping-ring,
  .cta-ring,
  .cts-inner,
.step-track-fill,
  .timeline-fill,
  .particle-field > span,
  .term-out-line {
    animation: none !important;
    transition: none !important;
  }
  .term-out-line { opacity: 1 !important; }
}
