/* === Resume CSS  === */
.timeline-item::after { content: none !important; }

/* variables */
:root {
  --resume-accent: var(--accent);
  --resume-glow-color: rgba(55,224,255,0.12);
  --card-bg: #07070a;
  --card-border: rgba(55,224,255,0.06);
  --card-shadow: rgba(0,0,0,0.6);
  --text-color: var(--text);
}

/* layout */
.resume { padding: 5rem 5rem 0 5rem; position: relative; }
.resume .section-title { text-align: center; font-size: 2rem; margin-bottom: 2rem; }

.timeline { position: relative; padding: 1rem 0; display: grid; gap: 2.6rem; }

/* central axis */
.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 3px;
  transform: translateX(-50%);
  background: linear-gradient(180deg, transparent, rgba(255,255,255,0.03), transparent);
  z-index: 1;
  border-radius: 2px;
}

/* item base */
.timeline-item {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 120px;
  z-index: 2;
  padding: 0 1rem;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}
.timeline-item.visible { opacity: 1; transform: translateY(0); }

/* dot */
.timeline-item .dot {
  position: absolute;
  left: 50%;
  top: -10%;
  transform: translateX(-50%);
  z-index: 6;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--resume-accent);
  box-shadow: 0 0 6px rgba(0,0,0,0.6);
  will-change: transform, opacity;
}

/* pulsing glow */
.timeline-item .dot::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) scale(.6);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--resume-glow-color) 0%, transparent 60%);
  z-index: 3;
  opacity: .6;
  pointer-events: none;
  will-change: transform, opacity;
  animation: resumePulse 2.6s infinite;
}

/* explicit year element */
.timeline-item .year {
  position: absolute !important;
  top: -5% !important;
  transform: translateY(-50%) !important;
  left: calc(50% + 26px) !important;   /* sits to the right of the center line */
  color: var(--text-color) !important;
  font-weight: 700 !important;
  z-index: 7 !important;                /* above cards/dot */
  white-space: nowrap;
  font-size: 0.95rem;
  pointer-events: none;
}

/* card */
.timeline-item .card {
  background: var(--card-bg);
  border-radius: 28px;
  padding: 1.25rem 1.6rem;
  max-width: 760px;
  width: calc(45vw + 140px);
  color: var(--text-color);
  box-shadow: 0 10px 40px var(--card-shadow);
  border: 2px solid var(--card-border);
  filter: drop-shadow(0 0 16px rgba(55,224,255,0.06));
  z-index: 2;
  position: relative;
}

/* left / right helpers */
.timeline-item.right {
  justify-content: flex-end;
  text-align: left;
}
.timeline-item.right .card { margin-left: 42px; }

.timeline-item.left {
  justify-content: flex-start;
  text-align: right;
}
.timeline-item.left .card { margin-right: 42px; }

/* responsive */
@media (max-width: 900px) {
  .timeline::before { left: 14px; }
  .timeline-item { padding-left: 44px; padding-right: 16px; justify-content: flex-start; text-align: left; }
  .timeline-item .dot { left: 14px; transform: none; }
  .timeline-item .year { left: 44px; top: 50%; transform: translateY(-50%); } /* align with left dot */
  .timeline-item .card { width: 100%; max-width: none; margin: 0; border-radius: 16px; }
}

/* pulse animation */
@keyframes resumePulse {
  0% { transform: translate(-50%, -50%) scale(0.6); opacity: 0.6; }
  70% { transform: translate(-50%, -50%) scale(1.6); opacity: 0; }
  100% { transform: translate(-50%, -50%) scale(0.6); opacity: 0; }
}

/* reduce motion preference */
@media (prefers-reduced-motion: reduce) {
  .timeline-item,
  .timeline-item .dot::after {
    transition: none !important;
    animation: none !important;
  }
}
