* { margin:0; padding:0; box-sizing:border-box; font-family:'poppins', sans-serif; }

body { 
  background:#f2f6fa; 
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}


.hero{
  position: relative;
  background:
    linear-gradient(rgba(31, 79, 117, 0.75), rgba(31, 79, 117, 0.75)),
    url('../img/polije-sda2.jpeg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: white;
  min-height: 80vh;
  padding: 0 80px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-text{
  max-width: 700px;
  z-index: 2;
  position: relative;
}

.school-name{
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.hero-text h1{
  font-size:78px;
  font-weight: 800;
  line-height:1.1;
}

.hero-text span{
    color:#E5EB14;
}

.search-box{
    display:flex;
    margin:25px 0;
    width: 100%;
    max-width: 650px;
}

.search-box input{
  flex: 1;
  padding: 20px 24px;
  font-size: 22px;
  border: none;
  outline: none;
  border-radius: 10px 0 0 10px;
}

.search-box button{
  background: #E5EB14;
  border: none;
  padding:0px 28px;
  font-size:28px;
  cursor: pointer;
  border-radius: 0 10px 10px 0;
}

.motto{
  font-size: 28px;
  font-weight: 600;
  font-style:italic;
}

.hero-image{
  position: absolute;
  right: 0;
  bottom: 0;
  z-index: 1;
  line-height: 0;
}

.hero-image img{
    height: 80vh;
    width: auto;
    display: block;
}

.content {
  padding: 60px 80px;
  text-align: center;
  background: #f5f5f5;
}

.content h2 {
  font-size: 32px;
  color: #1f4f75;
  margin-bottom: 40px;
  font-weight: 700;
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 35px;
  max-width: 1100px;
  margin: auto;
}

.news-card {
  background: white;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 8px 18px rgba(0,0,0,0.08);
  transition: 0.3s;
  text-align: left;
  display:flex;
  flex-direction:column;
}

.news-card:hover {
  transform: translateY(-5px);
}

.news-card img {
  width: 100%;
  height: 500px;
  object-fit: contain;
  display: block;
}

.news-body {
  padding: 25px;
  display:flex;
  flex-direction:column;
  flex:1;
}

.news-body h3 {
  font-size: 24px;
  color: #2f4f6f;
  line-height: 1.5;
  margin-bottom: 20px;
  font-weight: 700;
}

.news-body a {
  display: inline-block;
  font-size: 14px;
  font-weight: 700;
  color: #d4d800;
  text-decoration: none;
  margin-bottom: 18px;
  margin-top: auto;
}

.news-body p {
  font-size: 13px;
  color: #999;
}

.content2{
  padding:60px 80px;
  background:#1f4f75;
  color:white;
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:50px; 
}

.banner{
  width:100%;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:20px;
  text-align:center;
}

.banner img{
  max-width:700px;
  display:block;
}

.bottom-content{
  width:100%;
  max-width:1100px;
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:40px;
}

.info-left{
  flex:1;
  text-align:left;
}

.info-right{
  flex:1;
  text-align:left;
  font-size:16px;
  line-height:1.7;
}

.info-left h2{
  color:#E5EB14;
  margin-bottom:15px;
}

.info-left p{
  margin:8px 0;
}

.divider{
  width:2px;
  background:white;
  min-height:150px;
}

@media screen and (max-width: 1024px) {
    .hero {
        padding: 40px;
        gap: 20px;
    }
    
    .hero-text h1 {
        font-size: 50px;
    }

    .hero-image img {
        height: 60vh;
    }

    .news-grid {
        grid-template-columns: repeat(2, 1fr); 
        padding: 0 20px;
    }
}

@media screen and (max-width: 768px) {
    html, body {
        overflow-x: hidden;
        width: 100%;
    }

  .hero {
        flex-direction: column;
        text-align: center;
        padding: 60px 20px; 
        height: auto;
        min-height: 100vh;
        justify-content: center; 
        align-items: center;
    }

    .hero-text {
        margin-bottom: 0;
        width: 100%;
    }

    .hero-image {
        display: none;
    }

    .hero-image img {
        height: 50vh;
        width: auto;
        display: block;
        margin: 0 auto;
    }

    .search-box {
        width: 100%;
        flex-direction: column;
    }

    .search-box input {
        border-radius: 10px;
        width: 100%;
        margin-bottom: 10px;
    }

    .search-box button {
        border-radius: 10px;
        width: 100%;
        padding: 15px;
    }

    .content {
        padding: 40px 15px;
    }

    .news-grid {
        grid-template-columns: 1fr;
        width: 100%;
        padding: 0;
    }

    .news-card {
        margin: 0 auto;
        width: 100%;
    }

    .news-card img {
        height: 300px;
    }

    .bottom-content {
        flex-direction: column;
        gap: 30px;
        flex-direction: column;
        text-align: center;
    }

    .info-left, .info-right {
        text-align: center;
    }

    .divider {
        width: 100%;
        height: 2px;
        min-height: auto;
        margin: 20px 0;
    }

    .banner img {
        width: 100%; 
        height: auto;
    }
}

@media screen and (max-width: 480px) {
    .hero-text h1 {
        font-size: 36px;
    }

    .school-name {
        font-size: 16px;
    }

    .motto {
        font-size: 18px;
    }

    .content, .content2 {
        padding: 40px 20px;
    }

    .news-card img {
        height: 250px;
    }

    .news-body h3 {
        font-size: 18px;
    }
}