* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", sans-serif;
}

body {
  
  background: #f5f7fa;
  color: #222;
}

/* ===== HEADER ===== */
.header {
  position: sticky;
  top: 0;
  z-index: 5000;
  height: 70px;          /* 👈 DODAJ */
  background: #ffffff;
  display: flex;
   justify-content: space-between;
  align-items: center;
  padding: 0 16px;       /* 👈 umesto 12px 24px */
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}




.logo-area {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo {
  height: 50px;
}

.school-name {
  font-weight: 600;
  font-size: 16px;
}

.social-icons{
  display:flex;
  gap:15px;
  align-items:center;
  justify-content:center;
}

.social-icons img{
  width:28px;
  height:28px;
  transition:0.3s;
}

.social-icons img:hover{
  transform:scale(1.2);
}

/* ===== NAV ===== */
.nav {
	
  display: flex;
  gap: 18px;
  align-items: center;
}

.nav a,
.dropbtn {
  text-decoration: none;
  color: #004a99;
  font-weight: 500;
  background: none;
  border: none;
  cursor: pointer;
   font-family: inherit;
  font-size: inherit;
}

.nav a:hover,
.dropbtn:hover {
  color: #0077ff;
}

/* ===== DROPDOWN ===== */
.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;
  background: #fff;
  min-width: 220px;
  top: 100%;
  left: -20px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.15);
  border-radius: 8px;
  overflow: visible;
}

.dropdown-content a {
  display: block;
  padding: 12px 16px;
  color: #333;
}

.dropdown-content a:hover {
  background: #f0f4ff;
}

.dropdown.open .dropdown-content {
  display: block;
}


/* ===== HERO ===== */
.hero {
  position: relative;
  height: 420px;
  overflow: hidden;
  margin-top: 0px; /* 👈 SPUŠTA HERO ISPOD ZAGLAVLJA */
}


.slide {
  position: absolute;
  inset: 0;
  background-size: contain;
  background-position: center;
/*  background-repeat: no-repeat; */
  opacity: 0;
  clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  transition: clip-path 1.2s ease, opacity 1.2s ease;
}

.slide.active {
  opacity: 1;
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
}

/* ===== MAIN CONTENT ===== */
.main-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 30px;
  padding: 40px 60px;
}

.section {
  background: #fff;
  padding: 30px;
  border-radius: 14px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.05);
  overflow: hidden;
}

.section1 {
  background: #fff;
  padding: 10px;
  border-radius: 14px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.05);
  overflow: hidden;
}

.section h2 {
  margin-bottom: 16px;
  color: #004a99;
}
/* ===== LEAD SEKCIJA SA POZADINSKOM SLIKOM ===== */

.section:has(.lead) {
  background-repeat: no-repeat;
  background-position: top right;
  background-size: 220px;
}

.section:has(.lead) > * {
  max-width: calc(100% - 260px);
}



/* ===== SIDEBAR ===== */
.sidebar h3 {
  margin-bottom: 10px;
  color: #004a99;
}
.sidebar {
  align-self: start;
  position: sticky;
  top: 100px; /* ispod headera */
}


.fb-wrapper {
  margin-bottom: 10px;
}

.useful-links {
  display: flex;
  gap: 12px;
}

.useful-links img {
  width: 100%;
  max-width: 150px;
  border-radius: 12px;
  transition: transform 0.3s;
}

.useful-links img:hover {
  transform: scale(1.05);
}

/* ===== FOOTER ===== */
.footer {
  background: #004a99;
  color: #fff;
  text-align: center;
  padding: 20px;
  margin-top: 60px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .main-content {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .nav {
    flex-wrap: wrap;
    gap: 12px;
  }
}

/* ===== HAMBURGER ===== */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: auto;
}

.hamburger span {
  width: 26px;
  height: 3px;
  background: #004a99;
  border-radius: 3px;
  transition: all 0.3s ease;
}

/* ===== MOBILNI MENI ===== */
@media (max-width: 900px) {

  .nav {
    position: fixed;
    top: 70px;
    right: -100%;
    width: 260px;
    height: calc(100vh - 70px);
    background: #ffffff;
    flex-direction: column;
    align-items: flex-start;
    padding: 20px;
    gap: 16px;
    box-shadow: -10px 0 25px rgba(0,0,0,0.15);
    transition: right 0.35s ease;
  }



  .nav.active {
    right: 0;
  }

  .hamburger {
    display: flex;
  }

  /* dropdown u mobilnom */
  .dropdown-content {
    position: static;
    box-shadow: none;
    transform: none;
    opacity: 1;
    visibility: visible;
    display: none;
  }

  .dropdown.open .dropdown-content {
    display: block;
  }

  .dropdown:hover .dropdown-content {
    display: none;
  }
}

/* ===== SCROLL ANIMATIONS ===== */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s ease;
}

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

/* varijante */
.reveal-left {
  transform: translateX(-360px);
}

.reveal-right {
  transform: translateX(0px);
}

.reveal-left.active,
.reveal-right.active {
  transform: translateX(0);
}
/* ===== HERO TEXT OVERLAY ===== */
.hero-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: center;   /* horizontalno u sredini */
  align-items: flex-end;     /* vertikalno dole */
  padding-bottom: 10px;      /* 👈 10px od dna */
  pointer-events: none;
}



.hero-text {
  background: rgba(0, 0, 0, 0.55);
  color: #ffffff;
  padding: 22px 36px;
  border-radius: 16px;
  font-size: 22px;
  font-weight: 500;
  text-align: center;
  max-width: 80%;
  line-height: 1.4;
  animation: pulse 3s ease-in-out infinite;
  box-shadow: 0 0 0 rgba(0,0,0,0.4);
}

/* PULSIRAJUĆA ANIMACIJA */
@keyframes pulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(0, 119, 255, 0.4);
  }
  50% {
    transform: scale(1.03);
    box-shadow: 0 0 25px 10px rgba(0, 119, 255, 0.15);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(0, 119, 255, 0.4);
  }
}

/* RESPONSIVE */
.submenu {
  position: relative;
   z-index: 2000;
}

.submenu-content {
  position: absolute;
  top: 0;
  right: 100%;       /* 👈 ide ulevo */
  left: auto;
  min-width: 260px;
  background: #ffffff;
  border-radius: 10px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.15);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-10px); /* animacija ulevo */
  transition: all 0.3s ease;
  z-index: 3000;
}

@media (max-width: 900px) {

  .dropdown-content {
    padding-left: 0;
  }

  .submenu {
    width: 100%;
  }

  .submenu-content {
    position: static;        /* 👈 KLJUČ */
    width: 100%;
    margin-left: 0;
    box-shadow: none;
    border-radius: 0;
    background: #f8f9fc;
	max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }
}


/* ===== SUBMENU CLICK (MOBILE) ===== */
.submenu.open .submenu-content {
  opacity: 1;
  visibility: visible;
  transform: none;
  max-height: 500px;
}


@media (max-width: 768px) {
	  .section:has(.lead) {
    background-size: 120px;
    background-position: top right;
    padding: 20px;   /* prostor ispod loga */
  }

  .section:has(.lead) > * {
  max-width: 100%;
}
  .hero-text {
    font-size: 17px;
    padding: 18px 22px;
  }
   .hero {
    height: 190px;                 /* niži hero za mobilni */
  }

  .slide {
    background-size: contain;        /* 👈 UMESTO contain */
    background-position: center;
	background-repeat: no-repeat; 
  }

}

/* ===== POZADINSKE SLIKE PO SMERU ===== */

.smer-arhitektonski .section:has(.lead) {
  background-image: url("gallery/arhitektonskiLOGO.jpg");
}

.smer-gradjevinski .section:has(.lead) {
  background-image: url("gallery/gradjevinskiLOGO.jpg");
}

.smer-graficki .section:has(.lead) {
  background-image: url("gallery/grafikaLOGO.jpg");
}

.smer-drvni .section:has(.lead) {
  background-image: url("gallery/drvniLOGO.jpg");
}

.smer-moda .section:has(.lead) {
  background-image: url("gallery/modaLOGO.jpg");
}

.smer-polagac .section:has(.lead) {
  background-image: url("gallery/polagacLOGO.jpg");
}

.smer-mehanizacija .section:has(.lead) {
  background-image: url("gallery/rukovalacLOGO.jpg");
}

.smer-krojac .section:has(.lead) {
  background-image: url("gallery/modniLOGO.jpg");
}

/* ===== SUBMENU ===== */



/* hover desktop */
.submenu:hover .submenu-content {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}

.submenu-content a {
  display: block;
  padding: 12px 16px;
  color: #333;
}

.submenu-content a:hover {
  background: #f0f4ff;
}

.no-js .reveal {
  opacity: 1;
  transform: none;
}

.lead {
  font-size: 18px;
  max-width: 800px;
}

.info-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin: 30px 0;
}

.card {
  background: #fff;
  padding: 20px;
  border-radius: 14px;
  box-shadow: 0 10px 20px rgba(0,0,0,0.08);
  text-align: center;
}

.plan-program {
  grid-column: 1 / 2;   /* samo leva kolona */
  width: 100%;
  max-width: none;      /* 👈 KLJUČ */
  padding-left: 0;      /* 👈 poravnanje sa levom ivicom */
  padding-right: 0;
}

.nastavni-plan {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
}

.nastavni-plan caption {
  font-size: 22px;
  font-weight: bold;
  margin-bottom: 15px;
}

.nastavni-plan th,
.nastavni-plan td {
  border: 1px solid #444;
  padding: 8px 10px;
  font-size: 14px;
}

.nastavni-plan th {
  background: #f2f2f2;
}

.razredi th {
  background: #d9d9d9;
  font-size: 16px;
  text-align: center;
}

.nastavni-plan td:nth-child(2),
.nastavni-plan td:nth-child(6) {
  text-align: left;
}

.nastavni-plan td {
  text-align: center;
}


.useful-links {
  display: flex;
  flex-direction: column;
  gap: 15px;
  align-items: center;
}

.useful-links a {
  display: block;
}

.useful-links img {
  max-width: 350px;
  width: 100%;
}


#kontakt {
    max-width: 900px;
    margin: 40px auto;
    padding: 20px;
}

#kontakt h2 {
    text-align: center;
    margin-bottom: 20px;
}

.mapa {
    margin-bottom: 30px;
    border-radius: 8px;
    overflow: hidden;
}

.kontakt-forma {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.kontakt-forma input,
.kontakt-forma textarea {
    padding: 8px;
    font-size: 14px;
}

.kontakt-forma button {
    width: 150px;
    padding: 10px;
    background-color: #2c7be5;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 4px;
}

.kontakt-forma button:hover {
    background-color: #1a5bb8;
}

/* ===== GALERIJA ===== */
.gallery-section {
	text-align: center;
  background: #fff;
  padding: 30px;
  border-radius: 14px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.05);
  margin-top: 40px;
}
.gallery-section {
  grid-column: 1 / 2;   /* 👈 samo leva kolona */
  max-width: 100%;
  overflow: hidden;
}


.gallery-section h3 {
  margin-bottom: 20px;
  color: #004a99;
  grid-column: 1 / -1;
}

.gallery-main {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.gallery-main img {
  position: static;   /* ⬅️ KLJUČNO */
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}


.gallery-thumbs {
   display: flex;
  gap: 10px;
  overflow-x: auto;          /* 👈 horizontalni scroll */
  overflow-y: hidden;
  max-width: 100%;
  padding-top:10px;
  padding-bottom: 10px;      /* prostor za scrollbar */
  scroll-behavior: smooth;
}

.gallery-thumbs img {
	flex: 0 0 auto;    
  height: 80px;
  cursor: pointer;
  border-radius: 8px;
  opacity: 0.7;
  transition: all 0.3s ease;
}

.gallery-thumbs img:hover {
  opacity: 1;
  transform: scale(1.05);
}

.news-item {
  display: flex;
  gap: 20px;
  align-items: center;
  padding: 18px;
  border-radius: 14px;
  cursor: pointer;
  transition: background 0.3s, transform 0.3s;
}

.news-item:hover {
  background: #f0f4ff;
  transform: translateY(-3px);
}

.news-item img {
  width: 160px;
  height: 110px;
  object-fit: cover;
  border-radius: 12px;
}

.news-text h3 {
  margin-bottom: 8px;
  color: #004a99;
}

.news-text p {
  color: #444;
}

/* mobilni */
@media (max-width: 768px) {
  .news-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .news-item img {
    width: 100%;
    height: auto;
  }
}

@media (max-width: 900px) {
  .sidebar {
    position: static;
    top: auto;
    width: 100%;
    margin-top: 40px;
  }
}



@media (max-width: 900px) {

  .useful-links {
    width: 100%;
    max-width: 100%;
    padding: 0 12px;
    box-sizing: border-box;
    align-items: center;
  }

  .useful-links a {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .useful-links img {
    width: 100%;
    max-width: 260px;   /* 👈 KLJUČ */
    height: auto;
  }

}
body {
  overflow-x: hidden;
}

/* ===== SUBMENU CLICK (MOBILE FIX) ===== */
@media (max-width: 900px) {
  .submenu.open .submenu-content {
    opacity: 1;
    visibility: visible;
    transform: none;
  }
}

.submenu > a {
  display: flex;
  justify-content: space-between;
  align-items: center;
}



@media (hover: none) {
  .dropdown.open .dropdown-content {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  .submenu.open .submenu-content {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
}

.pdf-wrapper {
  position: relative;
  width: 100%;
  height: 100vh;          /* ceo ekran */
  max-height: 1000px;
  overflow: hidden;
}

.pdf-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* mobilni */
@media (max-width: 768px) {
  .pdf-wrapper {
    height: 80vh;
  }
}

.plan-program {
  max-width: 100%;
  margin: 10px auto;
  padding: 0 15px;
}

.plan-program h2 {
  text-align: center;
  margin-bottom: 10px;
}

.accordion-btn {
	  display: block;
  width: 100%;
  padding: 14px 18px;
  background: #1f3c88;
  color: #fff;
  font-size: 18px;
  border: none;
  text-align: left;
  cursor: pointer;
  margin-bottom: 5px;
  position: relative;
  background: linear-gradient(90deg, #1f3c88, #274cb3);
	 border-radius: 6px;
}

.accordion-btn::after {
  content: "↓";
  position: absolute;
  right: 20px;
  font-size: 22px;
}

.accordion-btn.active::after {
  content: "–";
}

.accordion-content {
  display: none;
  background: #fff;
  border: 1px solid #ddd;
  margin-bottom: 15px;
  padding: 10px;
}

.accordion-content table {
  width: 100%;
  border-collapse: collapse;
}

.accordion-content th,
.accordion-content td {
  border: 1px solid #ccc;
  padding: 8px;
  font-size: 14px;
  text-align: center;
}

.accordion-content td:nth-child(2) {
  text-align: left;
}

.accordion-content {
  display: none;
  overflow: hidden;
}
.accordion-content.open {
  display: block;
}

@media (min-width: 992px) {

  .plan-program {
    padding-left: 0;
    padding-right: 0;
  }

  .accordion-btn {
    font-size: 19px;
    padding: 18px 32px;
	background: linear-gradient(90deg, #1f3c88, #274cb3);
	 border-radius: 6px;
  }
}



/* mapa zauzima pun prostor */
.mapa-wrapper {
  flex: 1;
  display: flex;
}

.mapa-wrapper iframe {
  width: 100%;
  height: 100%;
  min-height: 400px;
  border: 0;
}

.section table img {
  max-width: 100%;
  height: auto;
}

.galleryVest {
  max-width: 900px;
  margin: 40px auto;
}

.gallery-mainVest img {
  width: 100%;
  height: 450px;
  object-fit: contain;
  border-radius: 10px;
}

.gallery-thumbsVest {
  display: flex;
  gap: 10px;
  margin-top: 15px;
  overflow-x: auto;
  padding-bottom: 10px;
}

.gallery-thumbsVest img {
  width: 120px;
  height: 80px;
  object-fit: contain;
  cursor: pointer;
  border-radius: 6px;
  opacity: 0.7;
  transition: 0.3s;
}

.gallery-thumbsVest img:hover {
  opacity: 1;
  transform: scale(1.05);
}

/* мобилни */
@media (max-width: 600px) {
  .gallery-mainVest img {
    height: 250px;
  }

  .gallery-thumbsVest img {
    width: 90px;
    height: 60px;
  }
}

.welcome-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none; /* po defaultu skriven */
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.welcome-card {
    background: white;
    padding: 40px;
    border-radius: 15px;
    text-align: center;
    max-width: 400px;
    width: 90%;
}

.welcome-logo {
    width: 100px;
    margin-bottom: 20px;
}

.welcome-card h2 {
    margin-bottom: 25px;
    color: #003366;
}

.welcome-card button {
    padding: 10px 25px;
    background: #003366;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

/* ===== ANALOG SCHOOL CLOCK ===== */

.school-clock {
  display: flex;
  justify-content: flex-end;
  padding: 20px 60px 0 60px;
}

.clock-card {
  background: #fff;
  padding: 25px;
  border-radius: 20px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.08);
  text-align: center;
  width: 320px;
  transition: 0.4s ease;
}

/* BOJE STANJA */
.clock-green { background: #e6f9ec; }
.clock-yellow { background: #fff8d6; }
.clock-blue { background: #e6f0ff; }

.shift-label {
  font-weight: bold;
  font-size: 18px;
  margin-bottom: 15px;
  color: #004a99;
}

/* Analogni sat */
.analog-clock {
  position: relative;
  width: 180px;
  height: 180px;
  margin: 0 auto 15px auto;
  border: 8px solid #004a99;
  border-radius: 50%;
  background: #ffffff;
}

.hand {
  position: absolute;
  bottom: 50%;
  left: 50%;
  transform-origin: bottom;
  transform: translateX(-50%) rotate(0deg);
  border-radius: 6px;
}

.hour {
  width: 6px;
  height: 45px;
  background: #004a99;
}

.minute {
  width: 4px;
  height: 65px;
  background: #1f3c88;
}

.second {
  width: 2px;
  height: 75px;
  background: red;
}

.center-dot {
  position: absolute;
  width: 12px;
  height: 12px;
  background: #004a99;
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.digital-time {
  font-size: 22px;
  font-weight: bold;
  color: #004a99;
}

.clock-date {
  font-size: 15px;
  margin: 5px 0;
  color: #555;
}

.clock-status {
  font-size: 17px;
  font-weight: 600;
  margin-top: 10px;
}

/* mobilni */
@media (max-width: 900px) {
  .school-clock {
    justify-content: center;
    padding: 20px;
  }
}

.teacher {
  position: relative;
  cursor: pointer;
  color: #1d4ed8;
}

.teacher:hover {
  text-decoration: underline;
}

/* Tooltip */
.tooltip {
  position: absolute;
  top: 120%;
  left: 0;
  width: 200px;
  background: white;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.2);
  padding: 10px;
  display: none;
  z-index: 999;
  text-align: center;
}

/* Slika */
.tooltip img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 8px;
}

/* Prikaz na hover */
.teacher:hover .tooltip {
  display: block;
}
