/* Sivun tausta + peruslayout */
body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Inter", sans-serif;
  background: #05060a;
  color: #f5f7ff;
}

.page {
  min-height: 100vh;
  padding: 40px 16px 60px;
}

/* Artikkeliblokki keskelle ja kapeaksi */
.post {
  max-width: 820px;
  margin: 0 auto;
}

.post-inner {
  background: #0b0e16;
  border-radius: 20px;
  padding: 32px 20px 40px;
  border: 1px solid rgba(122, 255, 212, 0.12);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.6);
}

/* Tekstipalstat hiukan kapeammiksi */
.post-body,
.post-visual {
  max-width: 640px;
  margin: 0 auto 32px;
}

/* Otsikot */
.post-header {
  max-width: 640px;
  margin: 0 auto 28px;
}

.post-kicker {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.75rem;
  color: #92a2c7;
  margin: 0 0 4px;
}

.post-header h1 {
  font-size: 1.8rem;
  line-height: 1.25;
  margin: 0;
  color: #f7fbff;
}

/* Leipäteksti */
.post-body p {
  line-height: 1.7;
  font-size: 0.98rem;
  color: #d7e0f5;
  margin: 0 0 1rem;
}

/* ----------------- STATS ----------------- */

.stats-container {
  max-width: 420px;
  margin: 0 auto;
  text-align: center;
}

.stats-container h2 {
  font-size: 1.3rem;
  margin-bottom: 16px;
  color: #7affd4;
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 10px 0;
  opacity: 0;
  transform: translateY(6px);
  transition: 0.4s ease;
}

.stat.active {
  opacity: 1;
  transform: translateY(0);
}

.stat-number {
  font-size: 1.8rem;
  font-weight: 700;
}

.stat-label {
  font-size: 0.85rem;
  color: #9aa6c4;
}

/* ----------------- TIMELINE ----------------- */

#junction-timeline h2 {
  font-size: 1.3rem;
  margin-bottom: 8px;
  color: #7affd4;
}

.timeline-intro {
  font-size: 0.9rem;
  color: #a5b0cc;
  margin: 0 0 16px;
}

.timeline {
  max-width: 520px;
  margin: 0 auto 16px;
}

/* Yksi kortti */
.timeline-card {
  background: #151823;
  border-radius: 16px;
  padding: 18px 18px 14px;
  border: 1px solid rgba(122, 255, 212, 0.25);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
  display: grid;
  row-gap: 10px;
}

/* Päiväkohtaiset "alkuasennot" animaatiolle */
.timeline-card--fri {
  transform: translateX(-20px);
}

.timeline-card--sat {
  transform: translateY(6px);
}

.timeline-card--sun {
  transform: translateX(20px);
}

/* Yleinen sisääntuloanimaatio */
.timeline-card--enter {
  opacity: 0;
  animation: cardFadeIn 0.45s ease-out forwards;
}

@keyframes cardFadeIn {
  to {
    opacity: 1;
    transform: translateX(0) translateY(0);
  }
}

/* Lauantain Hacking-kortille neon glow -pulssi */
.timeline-card--highlight {
  position: relative;
  border-color: rgba(122, 255, 212, 0.8);
  background: radial-gradient(
      circle at top left,
      rgba(122, 255, 212, 0.18),
      transparent 55%
    ),
    #151823;
  animation: pulseGlow 2s infinite ease-in-out;
}

@keyframes pulseGlow {
  0% {
    box-shadow: 0 0 0px rgba(122, 255, 212, 0.4);
  }
  50% {
    box-shadow: 0 0 18px rgba(122, 255, 212, 0.85);
  }
  100% {
    box-shadow: 0 0 0px rgba(122, 255, 212, 0.4);
  }
}

/* Connector-pallurat korttien väliin */
.timeline-connector {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin: 10px 0 14px;
}

.timeline-connector span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #7affd4;
  opacity: 0.3;
  animation: dotPulse 1.6s infinite ease-in-out;
}

.timeline-connector span:nth-child(2) {
  animation-delay: 0.2s;
}
.timeline-connector span:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes dotPulse {
  0%, 100% {
    opacity: 0.25;
    transform: scale(1);
  }
  50% {
    opacity: 0.9;
    transform: scale(1.4);
  }
}

/* Otsikko, aika ja tyyppi */
.timeline-card_header h3 {
  margin: 0;
  font-size: 1.05rem;
  color: #eaf4ff;
}

.timeline-card_header small {
  color: #8b96b3;
  font-size: 0.8rem;
}

.timeline-card_time {
  font-variant-numeric: tabular-nums;
  color: #7affd4;
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 4px;
}

.timeline-card_title {
  color: #e6ecff;
  font-size: 0.95rem;
}

.timeline-card_type {
  margin-top: 4px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #9fa9c4;
}

/* Napit */
.timeline-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 8px;
}

.timeline-btn {
  border-radius: 999px;
  padding: 6px 12px;
  border: 1px solid rgba(143, 156, 190, 0.7);
  background: transparent;
  color: #e5ecff;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.1s ease, opacity 0.15s ease;
}

.timeline-btn:hover:not(:disabled) {
  background: rgba(143, 156, 190, 0.18);
  transform: translateY(-1px);
}

.timeline-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.timeline-card_step {
  font-size: 0.8rem;
  color: #9aa4c1;
}

/* Mobiili: pienempi padding ja otsikko */
@media (max-width: 640px) {
  .post-inner {
    padding: 24px 14px 32px;
  }

  .post-header h1 {
    font-size: 1.4rem;
  }

  .post-body,
  .post-visual {
    margin-bottom: 24px;
  }
}
/* ----------------- BACK BANNER ----------------- */
.back-banner {
  display: inline-block;
  margin-bottom: 16px;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.85rem;
  color: #cfe8ff;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(122, 255, 212, 0.25);
  backdrop-filter: blur(4px);
  transition: all 0.2s ease;
}

.back-banner:hover {
  background: rgba(122, 255, 212, 0.12);
  color: #7affd4;
  transform: translateX(-3px);
}

/*#partners {
  max-width: 520px;
  margin: 0 auto 32px;
}

#partners h2 {
  font-size: 1.3rem;
  color: #7affd4;
  margin-bottom: 12px;
  text-align: center;
}

.partners-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.partners-list li {
  color: #d4dbf1;
  margin: 6px 0;
  opacity: 0;
  transform: translateY(6px);
  animation: fadeUp 0.6s forwards;
}

.partners-list li:nth-child(odd) {
  animation-delay: 0.05s;
}
.partners-list li:nth-child(even) {
  animation-delay: 0.1s;
}

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.partners-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 20px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.partners-list li {
  opacity: 0;
  animation: fadeUp 0.5s forwards;
  color: #d4dbf1;
} */

/* ----------- HERO BANNER ----------- */

.hero-banner {
  position: relative;
  width: 100%;
  max-width: 100%;
  height: 240px;
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 28px;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.6);
}

.hero-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.65);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0,0,0,0.4),
    rgba(0,0,0,0.6) 60%,
    rgba(0,0,0,0.75)
  );
}

.hero-title {
  position: absolute;
  bottom: 22px;
  left: 24px;
}

.hero-title h1 {
  margin: 0;
  font-size: 1.9rem;
  font-weight: 700;
  color: #f8fcff;
  text-shadow: 0 4px 10px rgba(0,0,0,0.6);
}

/* Mobile */
@media (max-width: 640px) {
  .hero-banner {
    height: 180px;
  }

  .hero-title h1 {
    font-size: 1.3rem;
  }
}
.stats-hint {
  font-size: 0.8rem;
  color: #9aa6c4;
  margin: 0 0 8px;
}

/* ----- STAT BOX ----- */

.stats-box {
  background: #11141f;
  border: 1px solid rgba(122, 255, 212, 0.15);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.55);
  border-radius: 20px;
  padding: 28px 22px 32px;
  max-width: 640px;
  margin: 0 auto 40px;
}

.stats-header {
  text-align: center;
  margin-bottom: 20px;
}

.stats-box h2 {
  font-size: 1.35rem;
  margin: 0;
  color: #7affd4;
}

.stats-hint {
  margin: 6px 0 0;
  font-size: 0.8rem;
  color: #8c97b5;
}

/* GRID layout statsille */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 20px 12px;
  text-align: center;
}

/* yksittäinen stat */
.stat {
  background: rgba(255, 255, 255, 0.02);
  padding: 14px 10px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.04);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  cursor: pointer;
}

.stat.active {
  opacity: 1;
  transform: translateY(0);
}

.stat-number {
  font-size: 1.6rem;
  font-weight: 700;
  color: #eaf4ff;
}

.stat-label {
  font-size: 0.8rem;
  color: #9aa6c4;
}

@media (max-width: 520px) {
  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }
}
