html {
  scroll-behavior: smooth;
}

body {
  margin: 0px;
  padding: 0px;
  box-sizing: border-box;
  background: #ffffff;
  color: #153353;
  font-family: Arial, Helvetica, sans-serif;
}
html,
body {
  overflow-x: hidden;
  width: 100%;
}

body {
  font-family: "Saira Semi Condensed", sans-serif;
  font-weight: 100;
  font-style: normal;
}

.navbar {
  position: fixed;
  width: 100%;
  top: 0;
  background: #ffffff;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  z-index: 100;
}

/* Navbar container centered with a max width */
.navbar-container {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding-top: 15px;
  padding-bottom: 15px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  height: 50px; /* Adjust this value as needed */
  width: auto;
  margin: 0;
  margin-left: 10px;
}

/* Nav-links for desktop */
.nav-links {
  list-style: none;
  display: flex;
  gap: 15px;
}

.nav-links a {
  text-decoration: none;
  color: #153353;
  font-weight: 500;
}

/* Hamburger menu - hidden by default */
.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
}

.hamburger .bar {
  width: 25px;
  height: 3px;
  background-color: #153353;
  margin: 4px 0;
  transition: 0.2s;
}

.hero {
  height: 100vh;
  background: url("assets/product/cover.jpg") no-repeat center/cover;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 2rem;
  text-align: center;
}

.hero h3 {
  color: white;
  transform: translateY(-220px);
}

.hero p {
  color: white;
  transform: translateY(-220px);
}

.section {
  padding: 20px 20px;
  text-align: center;
  margin-top: 40px; /* prevent content from being hidden behind fixed navbar */
  scroll-margin-top: 80px; /* offset for smooth scrolling */
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.card {
  background: white;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0);
  text-align: center;
  transition: 0.2s ease-in-out, color 0.2s ease-in-out;
}

.card img {
  width: 100%;
  border-radius: 10px;
}

.quality img {
  width: 50px;
  height: 50px;
}

/* Kontakt and company info */
.contact-grid {
  justify-content: space-around;
  margin-top: 20px;
  text-align: center;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.company-info {
  margin-top: 30px;
  text-align: center;
}

footer {
  background: white;
  color: #bdc0c4;
  text-align: center;
  padding: 15px 0;
  padding-top: 20px;
}

a {
  text-decoration: none;
  color: inherit;
}

h2,
h3 {
  color: #153353;
}

#about {
  background-color: #153353;
  color: white;
}

#about h2 {
  color: white;
}

#about p {
  width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.quality {
  background-color: #153353;
  color: white;
}

.quality h3 {
  color: white;
}

#qualities .grid {
  padding: 0px;
  margin: 0px;
  grid-template-columns: repeat(4, 1fr);
}

.company-info {
  color: white;
  background-color: #153353;
}

#contact {
  background-color: #153353;
  color: white;
  margin-top: 0px;
  padding-top: 20px;
}

#contact h2 {
  color: white;
}

#contact h3 {
  color: white;
}

#qualities {
  background-color: #153353;
  margin-top: 0;
}

#qualities h3 {
  color: #d08c35;
}

.nav-links li a {
  text-decoration: none; /* Optional: removes underline */
  transition: color 0.2s ease-in-out; /* Smooth transition effect */
}

.nav-links li a:hover {
  color: #d08c35; /* Change color on hover */
  opacity: 1;
}

/* Default styles for all links */
.nav-links li a,
.contact-grid a,
.company-info a {
  text-decoration: none; /* Remove underline */
  transition: color 0.2s ease-in-out; /* Smooth transition */
}

.contact-grid a {
  opacity: 1;
  color: rgb(182, 182, 182);
}

/* Hover effect for all links */
.nav-links li a:hover,
.contact-grid a:hover,
.company-info a:hover {
  color: #d08c35; /* Change color on hover */
  opacity: 1;
}

.hamburger.active .bar {
  background-color: #d08c35; /* Change this to the desired color */
}

.card:hover {
  background: #153353;
  color: white;
}

.card h3 {
  transition: color 0.2s ease-in-out;
}

.card:hover h3 {
  color: white; /* Explicitly set h3 color */
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px; /* spacing between nav items */
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links li {
  display: inline-block;
}

/* Upload button in the nav */
#upload-button-nav a {
  display: inline-block;
  padding: 8px 16px;
  border: 2px solid #d08c35;
  border-radius: 4px;
  background-color: #153353;
  color: #d08c35;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.3s, color 0.3s;
}

#upload-button-nav a:hover {
  background-color: #d08c35;
  color: #ffffff;
}

/* Responsive navbar for screens up to 1000px */
@media (max-width: 1300px) {
  .navbar-container {
    justify-content: space-between;
    padding-top: 15px;
    padding-bottom: 15px;
  }

  /* Hide nav-links by default on mobile */
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%; /* directly below navbar */
    left: 0;
    right: 0;
    background: white;
    padding: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    z-index: 100;
    margin-top: 0;
    border-top: 1px solid #d08c35;

    justify-content: center; /* Centers items horizontally */
    align-items: center; /* Centers items vertically (if needed) */
    list-style: none; /* Removes bullet points */
    padding: 0;
    margin: 0 auto; /* Centers the entire ul if its parent has a defined width */
    width: 100%; /* Adjusts width to content */
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links.active li:first-child a,
  .nav-links.active li:last-child a {
    padding-right: 0 !important;
  }

  .nav-links.active li {
    padding: 5px;
  }

  .bar .active {
    opacity: 0.2;
  }

  /* Show hamburger on mobile (remains on the right) */
  .hamburger {
    display: flex;
    margin-right: 10px;
  }

  .hamburger .bar {
    width: 25px;
    height: 3px;
    background-color: #153353;
    margin: 4px 0;
    transition: 0.2s;
  }

  .logo {
    height: 30px; /* Adjust this value as needed */
    width: auto;
    margin: 0;
    margin-left: 10px;
  }

  .section {
    padding: 5px;
  }

  .card {
    padding: 5px;
  }

  #products .section {
    padding: 5px;
  }

  #products .grid {
    grid-template-columns: 1fr;
  }

  /* "Naše kvalitete" as 2x2 grid on small screens */
  #qualities .grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }

  #products .grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }

  .contact-grid {
    justify-content: space-around;
    margin-top: 20px;
    text-align: center;
    display: grid;
    grid-template-columns: repeat(2, 2fr);
    gap: 10px;
  }

  .hero h3 {
    color: white;
    transform: translateY(-180px);
  }

  .hero p {
    color: white;
    transform: translateY(-180px);
  }

  #about p {
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
  }
}

@media (max-width: 800px) {
  #products .grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  #about p {
    max-width: 450px;
    margin-left: auto;
    margin-right: auto;
  }

  .hamburger .bar {
    width: 25px;
    height: 3px;
    background-color: #153353;
    margin: 4px 0;
    transition: 0.2s;
  }
}

/* Responsive navbar for screens up to 1000px */
@media (max-width: 500px) {
  .navbar-container {
    justify-content: space-between;
    padding-top: 15px;
    padding-bottom: 15px;
  }

  /* Hide nav-links by default on mobile */
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%; /* directly below navbar */
    left: 0;
    right: 0;
    background: white;
    padding: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    z-index: 100;
    margin-top: 0;
    border-top: 1px solid #d08c35;
  }

  .nav-links.active {
    display: flex;
  }

  .bar .active {
    opacity: 0.5;
  }

  /* Show hamburger on mobile (remains on the right) */
  .hamburger {
    display: flex;
    margin-right: 10px;
  }

  .hamburger .bar {
    width: 25px;
    height: 3px;
    background-color: #153353;
    margin: 4px 0;
    transition: 0.2s;
  }

  .logo {
    height: 30px; /* Adjust this value as needed */
    width: auto;
    margin: 0;
    margin-left: 10px;
  }

  .section {
    padding: 5px;
  }

  .card {
    padding: 5px;
  }

  #products .section {
    padding: 5px;
  }

  #services .grid,
  #products .grid {
    grid-template-columns: 1fr;
  }

  /* "Naše kvalitete" as 2x2 grid on small screens */
  #qualities .grid {
    display: grid;
    grid-template-columns: repeat(2, 2fr);
    gap: 10px;
  }

  #products .grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .contact-grid {
    justify-content: space-around;
    margin-top: 20px;
    text-align: center;
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 10px;
  }

  .hero h3 {
    color: white;
    transform: translateY(-180px);
  }

  .hero p {
    color: white;
    transform: translateY(-180px);
  }
  #about p {
    max-width: 300px;
    margin-left: auto;
    margin-right: auto;
  }
}

/* Stil za upload form */
.upload-form {
  background: #f7f7f7;
  border: 1px solid #ccc;
  padding: 20px;
  margin: 40px auto;
  max-width: 600px;
  border-radius: 10px;
}

#upload {
  scroll-margin-top: 100px; /* offset for smooth scrolling */
}

.upload-form span {
  padding: 5px;
}

.upload-form h2 {
  text-align: center;
  color: #153353;
  margin-bottom: 20px;
}

.upload-form form label {
  display: block;
  margin-bottom: 5px;
  font-weight: 500;
  color: #153353;
}

.upload-form form input[type="email"],
.upload-form form input[type="text"] {
  box-sizing: border-box;
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
  margin-bottom: 15px;
  font-family: inherit;
  font-size: 1rem;
}

.upload-form form input[type="file"] {
  display: none;
}

.upload-form form .file-label {
  display: inline-block;
  padding: 10px 20px;
  background: #153353;
  color: #ffffff;
  border-radius: 5px;
  cursor: pointer;
  margin-bottom: 15px;
  transition: background 0.3s ease;
}

.upload-form form .file-label:hover {
  background: #d08c35;
}

.upload-form form .file-list {
  margin-bottom: 15px;
  font-family: inherit;
  color: #153353;
  overflow: hidden;
}

.upload-form form .btn {
  display: block;
  width: 100%;
  padding: 10px;
  background: #153353;
  color: #ffffff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-family: inherit;
  font-size: 1rem;
  transition: background 0.3s ease;
}

.upload-form form .btn:hover {
  background: #d08c35;
}

/* Spinner overlay styles */
#spinner {
  display: none; /* Hidden by default */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.8); /* Semi-transparent background */
  z-index: 9999; /* Ensure it sits on top */
}

.spinner-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 60px;
  height: 60px;
  margin: -30px 0 0 -30px; /* Offset to center the spinner */
  border: 8px solid #f3f3f3; /* Light grey border */
  border-top: 8px solid #153353; /* Darker color for the spinning effect */
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

/* Keyframes for spinning animation */
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Existing CSS below... */
/* (Keep your other styles from your current styles.css file) */

/* Poravnava vsebine li na sredino */
#upload-button-nav {
  text-align: center;
  list-style: none;
}

/* Stil za gumb (anchor) */
#upload-button-nav a {
  display: inline-block;
  padding: 5px 10px;
  background-color: #153353;
  color: #d08c35;
  border: 1px solid #d08c35;
  border-radius: 5px;
  text-decoration: none;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Hover efekt */
#upload-button-nav a:hover {
  background-color: #d08c35;
  color: #ffffff;
}

img {
  user-select: none;
  -webkit-user-drag: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}
#progress-bar-container {
  position: absolute;
  top: 60%;
  left: 50%;
  transform: translateX(-50%);
  width: 300px;
  background: #ccc;
  border-radius: 10px;
  overflow: hidden;
  height: 20px;
  text-align: center;
}

#progress-bar-fill {
  background: #153353;
  height: 100%;
  width: 0%;
  transition: width 0.3s ease;
}

#progress-percent {
  position: absolute;
  top: 0;
  width: 100%;
  color: white;
  font-weight: bold;
  line-height: 20px;
}