@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&display=swap');

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Montserrat', sans-serif;
}

body {
  background: #000;
  color: #fff;
  overflow-x: hidden;
}

/* ⭐ Zvijezde i meteori */
#stars {
  position: fixed;
  top: 0;
  left: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  background: radial-gradient(ellipse at bottom, #020111 0%, #000 100%);
  pointer-events: none;
}

/* HEADER */
header {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 20px 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
  z-index: 10;
}

header .logo-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

header img {
  height: 55px;
  width: auto;
  filter: brightness(1.1);
  transition: transform 0.3s ease, filter 0.3s ease;
}

header img:hover {
  transform: scale(1.05);
  filter: brightness(1.2);
}

header h1 {
  font-size: 1.6rem;
  letter-spacing: 2px;
}

header nav a {
  color: #fff;
  text-decoration: none;
  margin-left: 25px;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}

header nav a:hover {
  color: #fff;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

header nav a.active {
  text-shadow: 0 0 15px rgba(0,200,255,0.8);
}

/* SEKCIJE */
section {
  position: relative;
  width: 100%;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  overflow: hidden;
  --bg-image: none;
}

section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: var(--bg-image);
  background-size: cover;
  background-position: center;
  filter: brightness(0.7);
  opacity: 0.8;
  transition: all 0.8s ease;
  z-index: -1;
}

/* Hover efekat */
#agi:hover::before,
#earth:hover::before,
#space:hover::before {
  filter: brightness(0.9);
  transform: scale(1.05);
}

/* HERO */
#hero {
  display: flex;
  justify-content: center;
  align-items: center;
}

#hero .content {
  text-align: center;
}

/* Opšti sadržaj */
.content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  width: 100%;
  padding: 0 20px;
  opacity: 0;
  animation: fadeInOnly 1.5s ease-in-out forwards;
}

.content h2 {
  font-size: 3rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 0.5rem;
  letter-spacing: 1px;
}

.content h3 {
  font-size: 1.5rem;
  font-weight: 400;
  color: #ccc;
  margin-bottom: 1.5rem;
}

.content p {
  font-size: 1.1rem;
  line-height: 1.7;
  color: #ddd;
  margin-bottom: 2rem;
}

/* Dugmad */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border: 1px solid #fff;
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: 30px;
  transition: all 0.3s ease;
}

.btn:hover {
  background: #fff;
  color: #000;
  transform: scale(1.05);
}

/* O PROJEKTU - POBOLJŠANA SEKCIJA */
#about {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  min-height: 100vh;
  padding: 120px 20px 120px;
  margin-top: 80px;
  margin-bottom: 300px;
  position: relative;
  overflow: hidden;
}

#about::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: var(--bg-image);
  background-size: cover;
  background-position: center;
  filter: brightness(0.65) blur(2.5px);
  transform: scale(1);
  transition: all 0.8s ease;
  z-index: -1;
}

#about:hover::before {
  filter: brightness(0.85) blur(1.5px);
  transform: scale(1.04);
}

#about .content {
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(8px);
  padding: 70px 60px;
  border-radius: 30px;
  box-shadow: 0 0 40px rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.1);
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1.2s ease, transform 1.2s ease;
  max-width: 900px;
}

#about.show .content {
  opacity: 1;
  transform: translateY(0);
}

#about .content h2 {
  font-size: 3.2rem;
  font-weight: 700;
  margin-bottom: 0.8rem;
  letter-spacing: 2px;
  color: #fff;
  text-shadow: 0 0 15px rgba(255,255,255,0.3);
  text-align: center;
  text-transform: uppercase;
}

#about .content h3 {
  font-size: 1.8rem;
  font-weight: 500;
  color: #ccc;
  margin-bottom: 2rem;
  text-align: center;
  letter-spacing: 1px;
}

#about .content p {
  font-size: 1.15rem;
  line-height: 2;
  color: #e8e8e8;
  max-width: 800px;
  margin: 0 auto 2rem;
  text-align: center;
  letter-spacing: 0.3px;
}

/* TIM SEKCIJA */
#team {
  padding: 80px 20px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

#team h2 {
  font-size: 3.2rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 60px;
  letter-spacing: 2px;
  text-shadow: 0 0 15px rgba(255,255,255,0.3);
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 50px;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
}

.member {
  text-align: center;
  transition: transform 0.3s ease;
}

.member:hover {
  transform: translateY(-5px);
}

.member h3 {
  font-size: 1.2rem;
  margin-top: 10px;
  font-weight: 600;
  color: #fff;
}

.member p {
  font-size: 0.95rem;
  color: #ccc;
  margin-top: 5px;
}

.team-grid .member .img-wrap {
  overflow: hidden;
  border-radius: 50%;
  width: 180px;
  height: 180px;
  margin: 0 auto 15px;
  transition: transform 0.3s ease;
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.15);
}

.team-grid .member img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  transition: transform 0.4s ease, filter 0.4s ease;
}

.team-grid .member .img-wrap:hover img {
  transform: scale(1.15);
  filter: brightness(1.25);
}

/* FOOTER */
footer {
  background: rgba(0, 0, 0, 0.7);
  text-align: center;
  padding: 20px;
  font-size: 0.9rem;
  color: #aaa;
}

/* Animacije */
@keyframes fadeInOnly {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* More Button */
.more-btn {
  margin-top: 20px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.4);
  padding: 14px 36px;
  font-size: 1.1rem;
  border-radius: 30px;
  transition: all 0.3s ease;
  color: #fff;
  text-decoration: none;
  display: inline-block;
  cursor: pointer;
}

.more-btn:hover {
  background: #fff;
  color: #000;
  transform: scale(1.05);
  box-shadow: 0 0 25px rgba(255,255,255,0.25);
}

/* Chapter Links */
.chapter-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin: 20px 0 30px;
}

.chapter-links a {
  color: #fff;
  text-decoration: none;
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: color 0.3s ease, transform 0.3s ease;
}

.chapter-links a:hover {
  color: #fff;
  transform: translateY(-2px);
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

/* === Dropdown meni – samo zastavice (kompaktna verzija) === */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropbtn {
  cursor: pointer;
  white-space: nowrap;
  user-select: none;
  transition: color 0.3s ease;
}

/* Glavni container */
.dropdown-content {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 6px;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(8px);
  border-radius: 10px;
  min-width: auto;             /* automatska širina prema sadržaju */
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.6);
  z-index: 30;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s 0.25s;
  padding: 4px;                /* blago unutrašnje poravnanje */
}

/* Aktivno stanje */
.dropdown.open .dropdown-content {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: all;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0s;
}

/* Svaka zastava kao "dugme" */
.dropdown-content a {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 8px;                /* manji padding */
  transition: background 0.3s ease, transform 0.2s ease;
}

.dropdown-content a:hover {
  background: rgba(255,255,255,0.15);
  transform: scale(1.05);
  border-radius: 6px;
}

/* Zastavice */
.flag {
  width: 28px;
  height: 20px;
  border-radius: 3px;
  object-fit: cover;
  box-shadow: 0 0 6px rgba(255,255,255,0.25);
  margin: 0;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Efekat na hover zastave */
.flag:hover {
  transform: scale(1.08);
  box-shadow: 0 0 10px rgba(255,255,255,0.4);
}


/* Responsive ostaje isto */


/* Responsive Design */
@media (max-width: 768px) {
  .content h2 { font-size: 2rem; }
  .content h3 { font-size: 1.2rem; }
  
  header { 
    flex-direction: column;
    gap: 15px;
    padding: 15px; 
  }
  
  header nav {
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
  }
  
  header .logo-group { 
    margin-bottom: 5px; 
  }
  
  #about .content {
    padding: 40px 30px;
  }
  
  #about .content h2 {
    font-size: 2.2rem;
  }
  
  #about .content h3 {
    font-size: 1.4rem;
  }
  
  #about .content p {
    font-size: 1rem;
    line-height: 1.8;
  }
  
  .team-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 30px;
    padding: 0 15px;
  }
  
  .team-grid .member .img-wrap {
    width: 150px;
    height: 150px;
  }
  
  .member h3 {
    font-size: 1.1rem;
  }
  
  .member p {
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .team-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  
  .team-grid .member .img-wrap {
    width: 200px;
    height: 200px;
  }
}