/* VARIABLES */
:root {
  --bg-color: #f0f7fb;
  --text-dark: #1e293b;
  --text-muted: #475569;
  --primary-blue: #0284c7;
  --primary-light: #e0f2fe;
  --accent-blue: #0369a1;
  
  --color-green: #22c55e;
  --color-orange: #f59e0b;
  --color-red: #ef4444;

  --font-main: 'Plus Jakarta Sans', sans-serif;
  --font-heading: 'Fraunces', serif;

  --spacing-section: 4rem; /* Reduced from maybe larger spaces */
  --transition: 0.3s ease-in-out;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font-main);
  background-color: var(--bg-color);
  color: var(--text-dark);
  line-height: 1.6;
  overflow-x: hidden;
}

.site-header { display: flex; justify-content: space-between; align-items: center; padding: 1rem 2rem; background: #fff; position: sticky; top: 0; z-index: 100; box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05); }

.brand { text-decoration: none; display: inline-block; cursor: pointer; }
.brand:hover .brand-text { color: #38bdf8; /* Lighter blue */ }

.brand-text { font-family: var(--font-heading); font-weight: 700; color: var(--primary-blue); font-size: 1.25rem; transition: color 0.3s ease; }
.site-nav a { margin-left: 1.5rem; text-decoration: none; color: var(--text-muted); font-weight: 600; }
.site-nav a:hover { color: var(--primary-blue); }

.site-nav { display:flex; align-items:center; gap:0.5rem; }

/* Active/Current section style: colored pill + subtle outline */
.site-nav a.active {
  color: #0284c7; /* Primary blue instead of white for lighter look */
  background: #e0f2fe; /* light blue background */
  box-shadow: 0 2px 4px rgba(2,132,199,0.05);
  border: 1px solid rgba(2,132,199,0.1);
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  margin-left: 0.5rem;
}

.section { padding: var(--spacing-section) 2rem; max-width: 1200px; margin: 0 auto; }
.justify { text-align: justify; text-justify: inter-word; hyphens: none; }

.section { padding: var(--spacing-section) 2rem; max-width: 1200px; margin: 0 auto; }
.story-flow { margin-bottom: 2rem; border-bottom: 1px solid rgba(2, 132, 199, 0.1); padding-bottom: calc(var(--spacing-section) + 2rem); }
.story-flow:last-child { border-bottom: none; }

.section-head { text-align: center; margin-bottom: 3rem; }
.section-head h2 { font-family: var(--font-heading); font-size: 2.5rem; color: var(--accent-blue); margin-bottom: 1rem; text-align: center; }
.section-head p { font-size: 1.125rem; color: var(--text-muted); max-width: 1000px; margin: 0 auto; text-align: center; }

/* Global block settings reverted to their beautiful native left alignment */
p, li { text-align: left; }
/* EXCEPTIONS for specific elements that shouldn't follow paragraph defaults */
.site-nav a, .brand-text, .cta, .quiz-btn, .carousel-btn, .lab-number, h1, h3, h4, h5, h6, .scrolly-title { text-align: left; }
h1, h2.scrolly-title { text-align: center; } /* Hero and title headers centered */

.hero-description { font-size: 1.25rem; max-width: 800px; margin: 0 auto 2.5rem auto; color: var(--text-muted); text-align: center; }

/* Remove old justify overrides */
.justify { text-align: center; }
.hero { text-align: center; position: relative; padding-top: 11rem; padding-bottom: 6rem; }
.hero h1 { font-family: var(--font-heading); font-size: 3.5rem; color: var(--accent-blue); margin-bottom: 1.5rem; line-height: 1.2; }
.hero-description { font-size: 1.25rem; max-width: 800px; margin: 0 auto 2.5rem auto; color: var(--text-muted); }
.cta { display: inline-block; background: var(--primary-blue); color: #fff; padding: 1rem 2.5rem; border-radius: 999px; text-decoration: none; font-weight: 700; transition: var(--transition); box-shadow: 0 4px 12px rgba(2,132,199,0.3); }
.cta:hover { background: var(--accent-blue); transform: translateY(-3px); }

/* WAVES */
.water-visual { 
  position: absolute; 
  bottom: -140px; 
  left: calc(-50vw + 50%); 
  width: 100vw; 
  height: 140px; 
  z-index: -1; 
  opacity: 0.1; 
  background: url('data:image/svg+xml;utf8,<svg viewBox="0 0 1440 320" xmlns="http://www.w3.org/2000/svg"><path fill="%230284c7" d="M0,160L48,170.7C96,181,192,203,288,197.3C384,192,480,160,576,144C672,128,768,128,864,138.7C960,149,1056,171,1152,165.3C1248,160,1344,128,1392,112L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') repeat-x center bottom; 
  animation: wave 8s linear infinite; 
}
@keyframes wave { 0% { background-position-x: 0; } 100% { background-position-x: 1440px; } }
.wave { display: none; }

/* MAP SECTION */
.map-card-container { display: flex; gap: 2rem; align-items: flex-start; margin-bottom: 2rem; min-height: 400px; }
.map-stage { flex: 2; position: relative; background: #e2e8f0; border-radius: 1rem; overflow: hidden; height: 400px; border: 2px solid var(--primary-light); }
.map-side-card { flex: 1; background: #fff; padding: 1.5rem; border-radius: 1rem; box-shadow: 0 4px 6px rgba(0,0,0,0.05); border-top: 4px solid var(--primary-blue); }
.map-side-card img { width: 100%; border-radius: 0.5rem; margin-bottom: 1rem; object-fit: cover; height: 150px; }

.marker { position: absolute; width: 30px; height: 30px; border-radius: 50%; border: 3px solid #fff; cursor: pointer; color: #fff; font-weight: bold; transform: translate(-50%, -50%); transition: var(--transition); box-shadow: 0 2px 4px rgba(0,0,0,0.2); }
.marker:hover { transform: translate(-50%, -50%) scale(1.2); }
.marker-red { background: var(--color-red); }
.marker-orange { background: var(--color-orange); }
.marker-green { background: var(--color-green); }

.map-note { font-size: 0.875rem; color: var(--text-muted); text-align: center; margin: 1rem auto 3rem auto; max-width: 1200px; line-height: 1.5; }
.map-note.justify { text-align: center; }
/* Ensure justified utility overrides section/hero centering when applied */
.section-head p.justify,
.hero .justify,
.scrolly-step p.justify { text-align: center; }

/* STATUS CARDS */
.status-cards-container { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; margin-bottom: 1rem; }
.status-card { background: #fff; padding: 1.5rem; border-radius: 1rem; box-shadow: 0 4px 6px rgba(0,0,0,0.05); }
.border-red { border-top: 4px solid var(--color-red); }
.border-orange { border-top: 4px solid var(--color-orange); }
.border-green { border-top: 4px solid var(--color-green); }
.status-badge { display: inline-block; padding: 0.25rem 0.75rem; border-radius: 999px; font-size: 0.75rem; font-weight: 700; margin: 0.5rem 0 1rem 0; color: #fff; }
.badge-red { background: var(--color-red); }
.badge-orange { background: var(--color-orange); }
.badge-green { background: var(--color-green); }
.cards-source, .cards-disclaimer { font-size: 0.875rem; color: var(--text-muted); text-align: center; }

/* VIDEO & LAB */
.modern-video { width: 100%; max-width: 600px; max-height: 400px; border-radius: 1rem; display: block; margin: 0 auto 3rem auto; box-shadow: 0 10px 25px rgba(0,0,0,0.1); }
.lab-story-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2rem; margin-top: 2rem; }
.lab-step { background: #fff; border-radius: 1rem; overflow: hidden; box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05); position: relative; cursor: pointer; transition: transform var(--transition); }
.lab-step:hover { transform: scale(1.02); }
.lab-step img { width: 100%; height: 200px; object-fit: cover; border-bottom: 3px solid var(--primary-light); }
.lab-step-content { padding: 1.5rem; }
.lab-number { position: absolute; top: 10px; left: 10px; background: var(--primary-blue); color: #fff; width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: bold; font-family: var(--font-heading); }

/* COMPARE */
.compare-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
.compare-card { background: #fff; padding: 2rem; border-radius: 1rem; box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05); }
.compare-card.monitored { border: 2px solid var(--primary-light); }
.compare-card.unmonitored { border: 2px solid #fee2e2; }
.compare-card h3 { font-family: var(--font-heading); font-size: 1.5rem; margin-bottom: 1.5rem; display: flex; align-items: center; gap: 0.5rem; }
.compare-card ul { list-style: none; }
.compare-card li { margin-bottom: 1rem; display: flex; align-items: center; gap: 1rem; font-weight: 500; color: var(--text-dark); }
.icon { font-size: 1.25rem; }

/* GLOBAL & CAROUSEL */
.global-content { background: #fff; padding: 2rem; border-radius: 1rem; margin-bottom: 2rem; }
.global-content ul { list-style: none; }
.global-content li { margin-bottom: 1rem; position: relative; padding-left: 2rem; }
.global-content li::before { content: '🌍'; position: absolute; left: 0; }
.carousel-container { position: relative; background: var(--primary-light); padding: 3rem; border-radius: 1rem; text-align: center; }
.carousel-track { min-height: 80px; display: flex; align-items: center; justify-content: center; font-size: 1.25rem; font-family: var(--font-heading); color: var(--accent-blue); }
.carousel-btn { position: absolute; top: 50%; transform: translateY(-50%); background: #fff; border: none; width: 40px; height: 40px; border-radius: 50%; cursor: pointer; box-shadow: 0 2px 4px rgba(0,0,0,0.1); font-size: 1.25rem; color: var(--primary-blue); transition: var(--transition); }
.carousel-btn:hover { background: var(--primary-blue); color: #fff; }
#prevFact { left: 1rem; }
#nextFact { right: 1rem; }

/* QUIZ */
.quiz-interactive { background: #fff; padding: 2rem; border-radius: 1rem; box-shadow: 0 4px 10px rgba(0,0,0,0.05); max-width: 800px; margin: 0 auto; }
.quiz-question { font-size: 1.25rem; font-weight: 400; margin-bottom: 1.5rem; }
.quiz-options { display: flex; flex-direction: column; gap: 1rem; }
.quiz-btn { padding: 1rem; background: var(--primary-light); border: none; border-radius: 0.5rem; text-align: left; font-weight: 400; cursor: pointer; transition: var(--transition); }
.quiz-btn:hover { background: #bae6fd; }
.quiz-btn.correct { background: var(--color-green); color: #fff; }
.quiz-btn.wrong { background: var(--color-red); color: #fff; }
.quiz-feedback { margin-top: 1.5rem; padding: 1rem; border-radius: 0.5rem; display: none; }

/* MODAL / ZOOM (if used for images) */
.lightbox-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.85); /* dark backdrop */
  z-index: 1000;
  align-items: center;
  justify-content: center;
  cursor: zoom-out;
  backdrop-filter: blur(5px);
}
.lightbox-content {
  position: relative;
  text-align: center;
  max-width: 90%;
  max-height: 90%;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.lightbox-content img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  object-fit: contain;
}
.lightbox-caption {
  color: white;
  margin-top: 1rem;
  font-size: 1.1rem;
  max-width: 700px;
  line-height: 1.5;
  background: rgba(0,0,0,0.5);
  padding: 0.5rem 1rem;
  border-radius: 8px;
}
.zoomable {
  cursor: zoom-in;
  transition: transform 0.2s ease;
}
.zoomable:hover {
  transform: scale(1.03);
}

@media (max-width: 768px) {
  .compare-columns, .map-card-container { grid-template-columns: 1fr; flex-direction: column; }
  .map-stage { height: 300px; width: 100%; }
}

/* FOOTER / FUNDING LOGOS */
.site-footer { background: #ffffff; padding: 2rem 1rem; margin-top: 2rem; border-top: 1px solid rgba(2,132,199,0.06); }
.footer-inner { max-width: 1200px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.footer-logos { display: flex; gap: 1.5rem; align-items: center; flex-wrap: wrap; justify-content: center; }
.footer-logos img { height: 56px; width: auto; display: block; }
.footer-funding { color: var(--text-muted); text-align: center; font-size: 0.95rem; max-width: 900px; }

@media (max-width: 480px) {
  .footer-logos img { height: 40px; }
  .footer-inner { padding: 0 0.5rem; }
}

/* CHROME-LIKE TABS */
.chrome-tabs-container {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  border-radius: 8px 8px 0 0;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.chrome-tabs-header {
  display: flex;
  background-color: #e2e8f0;
  padding: 10px 10px 0 10px;
  border-bottom: 2px solid var(--primary-light);
}

.chrome-tab-btn {
  background-color: #cbd5e1;
  border: none;
  border-radius: 8px 8px 0 0;
  padding: 12px 20px;
  margin-right: 4px;
  cursor: pointer;
  font-family: var(--font-main);
  font-weight: 600;
  color: var(--text-muted);
  transition: all 0.2s ease;
  min-width: 150px;
  text-align: center;
}

.chrome-tab-btn:hover {
  background-color: #dbeafe;
  color: var(--primary-blue);
}

.chrome-tab-btn.active {
  background-color: #ffffff;
  color: var(--accent-blue);
  box-shadow: 0 -2px 5px rgba(0,0,0,0.05);
}

.chrome-tabs-content {
  background-color: #ffffff;
  padding: 2rem;
  border-radius: 0 0 8px 8px;
}

/* SCROLLYTELLING STYLES (Apple/Kubrick inspired) */
.scrolly-container {
  display: grid;
  grid-template-columns: 1fr;
  position: relative;
  max-width: 1200px;
  margin: 10rem auto 0 auto;
  padding: 0;
}

@media (min-width: 768px) {
  .scrolly-container {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    padding: 0 2rem;
  }
}

.scrolly-sticky {
  position: sticky;
  top: 10vh;
  height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 2rem;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.1);
  transition: all 0.5s ease;
  z-index: 1;
}

/* On mobile, sticky visual covers background, text scrolls over it */
@media (max-width: 767px) {
  .scrolly-container { display: block; }
  .scrolly-sticky { 
    position: sticky; 
    top: 5vh; 
    height: 90vh; 
    width: 100%;
    border-radius: 1rem;
    z-index: 0; /* behind text */
  }
  .scrolly-text {
    position: relative;
    z-index: 10;
    margin-top: -85vh; /* Pull text up over the sticky background */
    padding: 0 1rem;
  }
}

.scrolly-container.dark-scrolly .scrolly-sticky {
  box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.scrolly-visual {
  width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
  color: white;
  z-index: 1;
}

.scrolly-bg {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: var(--primary-blue);
  z-index: -1;
  transition: background 0.8s ease;
}

.scrolly-title {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  margin-bottom: 2rem;
  line-height: 1.2;
  text-shadow: 0 4px 10px rgba(0,0,0,0.2);
  transform: translateY(20px);
  opacity: 0;
  animation: fadeUpIn 0.8s forwards;
}

@keyframes fadeUpIn {
  to { transform: translateY(0); opacity: 1; }
}

.scrolly-model {
  font-size: 8rem;
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.3));
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.scrolly-text {
  padding-top: 15vh;
  padding-bottom: 50vh; /* gives room to scroll past the last item */
  /* Remove scrollbar visually */
  -ms-overflow-style: none;
  scrollbar-width: none;
}

@media (min-width: 768px) {
  .scrolly-container.dark-scrolly .scrolly-sticky {
    grid-column: 2;
    grid-row: 1;
  }
  .scrolly-container.dark-scrolly .scrolly-text {
    grid-column: 1;
    grid-row: 1;
  }
}

.scrolly-step {
  padding: 2.5rem;
  margin-bottom: 70vh; /* space between text blocks so only 1 is active at a time usually */
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(16px);
  border-radius: 1.5rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  border: 1px solid rgba(255, 255, 255, 0.5);
  opacity: 0.3;
  transform: scale(0.95);
  transition: all 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
  position: relative;
  overflow: hidden;
}

.scrolly-step::before {
  content: '';
  position: absolute;
  top: -1px; left: -1px; bottom: -1px;
  width: 6px;
  border-radius: 1.5rem 0 0 1.5rem;
  background: var(--primary-blue);
  transition: background 0.6s ease;
}

.scrolly-step.active {
  opacity: 1;
  transform: scale(1) translateY(-10px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.scrolly-step p, .scrolly-step li {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--text-dark);
}

.scrolly-step ul {
  margin-left: 1.5rem;
  margin-bottom: 1.5rem;
}


.storymap-card p, .storymap-card ul {
  font-size: 1.15rem;
  color: var(--text-dark);
  margin-bottom: 1.25rem;
}

.storymap-card ul {
  margin-left: 2rem;
}

.storymap-card li {
  margin-bottom: 0.75rem;
  padding-left: 0.5rem;
}

.storymap-card strong {
  color: var(--accent-blue);
  font-weight: 700;
}

.drop-cap::first-letter {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--primary-blue);
  float: left;
  line-height: 1;
  margin-right: 0.75rem;
  margin-top: 0.2rem;
}

/* FUN FACTS FLIP CARDS */
.facts-flip-container {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
  perspective: 1000px;
}

.flip-card {
  background-color: transparent;
  width: 350px;
  height: 400px;
  perspective: 1000px;
  cursor: pointer;
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  transform-style: preserve-3d;
  box-shadow: 0 15px 35px rgba(0,0,0,0.1);
  border-radius: 1.5rem;
}

.flip-card:hover .flip-card-inner {
  transform: rotateY(180deg);
}

.flip-card-front, .flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2rem;
}

.flip-card-front {
  color: white;
}

.flip-card-front h3 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.flip-card-front .icon {
  font-size: 5rem;
}

.flip-card-back {
  background-color: white;
  color: var(--text-dark);
  transform: rotateY(180deg);
  border: 2px solid var(--primary-light);
  overflow-y: auto;
  align-items: flex-start;
  text-align: left;
}

.flip-card-back p {
  font-size: 0.95rem;
  line-height: 1.6;
}

.storymap-card:nth-child(even) {
  border-left: none;
  border-right: 6px solid var(--accent-blue);
  margin-left: auto;
  margin-right: 0;
  max-width: 85%;
}

.storymap-card:nth-child(odd) {
  margin-left: 0;
  margin-right: auto;
  max-width: 85%;
}

@media (max-width: 768px) {
  .storymap-card:nth-child(even), .storymap-card:nth-child(odd) {
    max-width: 100%;
    border-right: none;
    border-left: 6px solid var(--primary-blue);
  }
}

.chrome-tab-panel {
  display: none;
  animation: fadeIn 0.3s ease;
}

.chrome-tab-panel.active {
  display: block;
}

.chrome-tab-panel p {
  margin-bottom: 1rem;
  color: var(--text-muted);
}

.chrome-tab-panel ul {
  margin-left: 2rem;
  margin-bottom: 1rem;
  color: var(--text-muted);
}

.chrome-tab-panel li {
  margin-bottom: 0.5rem;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}
/* Custom Compare Layout ADDITIONS */
.compare-columns.two-cols {
  position: relative;
}
.compare-columns.two-cols::after {
  content: """";
  position: absolute;
  top: 5%;
  bottom: 5%;
  left: 50%;
  width: 2px;
  background-color: var(--primary-light);
  transform: translateX(-50%);
}
.compare-columns.three-cols {
  grid-template-columns: repeat(3, 1fr);
  position: relative;
}
/* Styling the list bullets to look like the image */
.compare-card li::before {
  content: """";
  display: block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--primary-blue);
  flex-shrink: 0;
  margin-top: 5px;
}

@media (max-width: 768px) {
  .compare-columns.two-cols::after {
    display: none;
  }
  .compare-columns.three-cols {
    grid-template-columns: 1fr;
  }
}

.team-info p {
  text-align: center;
}

/* Gladko drsenje ob kliku na gumbe v glavi */
html {
  scroll-behavior: smooth;
}

/* Prepreči, da bi fiksni meni prekril naslov sekcije */
#info-scrolly, #map {
  scroll-margin-top: 90px;
}