/* Styl uniwersalny dla AP Instal */

.menu-toggle {
  display: none;
}

body {
  margin: 0;
  font-family: 'Poppins', Arial, Helvetica, sans-serif;
  background-color: #ffffff;
  color: #333;
  scroll-behavior: smooth;
}

header {
  background-color: #003366;
  color: white;
  padding: 10px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.logo {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: default;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.logo:hover {
  color: #66b3ff;
  text-shadow: 0 0 8px rgba(102, 179, 255, 0.7);
}

nav ul {
  list-style: none;
  display: flex;
  gap: 20px;
}

nav ul li a {
  color: white;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

nav ul li a:hover {
  color: #66b3ff;
  text-decoration: underline;
}

nav ul li a:focus,
button:focus,
a:focus {
  outline: 2px dashed #66b3ff;
  outline-offset: 4px;
}

.page-hero {
  background: linear-gradient(to right, #003366, #0059b3);
  color: white;
  text-align: center;
  padding: 120px 20px;
  margin: 30px auto;
  max-width: 1000px;
  border-radius: 15px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.page-hero h1 {
  font-size: 3rem;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.6);
  animation: fadeInDown 1s ease-out forwards, electricPulse 3s infinite;
}

.page-hero p {
  font-size: 1.6rem;
  animation: fadeInUp 1s ease-out forwards;
}

.content-section,
.contact-section,
.gallery-section {
  background: #f0f6ff;
  padding: 40px 20px;
  margin: 30px auto;
  max-width: 1000px;
  border-radius: 15px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

h2 {
  color: #003366;
  margin-bottom: 20px;
}

form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

input,
textarea {
  padding: 10px;
  font-size: 1rem;
  border: 1px solid #ccc;
  border-radius: 5px;
}

button {
  background-color: #003366;
  color: white;
  padding: 10px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

button:hover {
  background-color: #0059b3;
  transform: scale(1.05);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

footer {
  text-align: center;
  background-color: #003366;
  color: white;
  padding: 10px;
  margin-top: 30px;
}

.footer-phone,
.footer-email {
  color: white;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease;
}

.footer-phone:hover,
.footer-email:hover {
  color: #66b3ff;
  text-decoration: underline;
}

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

.project {
  background-color: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  text-align: center;
  display: flex;
  flex-direction: column;
}

.responsive-img,
.project img,
.img-wrapper img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

.animate {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease-out;
}

.animate.visible {
  opacity: 1;
  transform: translateY(0);
}

main,
.content-section p,
.contact-section p,
.gallery-section p,
.page-hero p {
  font-size: 1.125rem;
  font-weight: bold;
  line-height: 1.6;
}

main {
  font-size: 1.25rem;
  font-weight: bold;
  line-height: 2;
}

main a {
  color: #0059b3;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 2px solid #0059b3;
  transition: all 0.3s ease;
}

main a:hover {
  color: #003366;
  border-bottom: 2px solid #003366;
}

@keyframes fadeInDown {
  0% {
    opacity: 0;
    transform: translateY(-30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes electricPulse {
  0%, 100% {
    text-shadow: 0 0 10px rgba(0, 153, 255, 0.8), 0 0 20px rgba(0, 153, 255, 0.6);
  }
  50% {
    text-shadow: 0 0 5px rgba(0, 153, 255, 0.4), 0 0 10px rgba(0, 153, 255, 0.2);
  }
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.9);
}

.lightbox-content {
  display: block;
  margin: 50px auto;
  max-width: 90%;
  max-height: 80vh;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
  border-radius: 10px;
}

.close {
  position: absolute;
  top: 20px;
  right: 35px;
  color: white;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
}

.close:hover,
.close:focus {
  color: #bbb;
}

.img-wrapper {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 75%;
  overflow: hidden;
  border-radius: 8px;
}

.overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  color: #e6f0ff;
  background: rgba(0, 0, 0, 0.6);
  padding: 10px;
  font-size: 1.2rem;
  text-align: center;
  opacity: 0;
  transform: translateY(100%);
  transition: all 0.4s ease;
  pointer-events: none;
  border-bottom-left-radius: 8px;
  border-bottom-right-radius: 8px;
}

.img-wrapper:hover .overlay {
  opacity: 1;
  transform: translateY(0);
}

.hidden-form {
  display: none;
  visibility: hidden;
  opacity: 0;
  height: 0;
  overflow: hidden;
}

/* Tabela Cennika */
.cennik-header {
  display: grid;
  grid-template-columns: 5fr 1fr;

  gap: 20px;
  align-items: center;
  padding: 12px 10px;
  font-weight: bold;
  background-color: #f5f5f5;
  border-bottom: 2px solid #333;
  text-align: left;
}

.cennik-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 10px;
  border-bottom: 1px solid #ccc;
  background-color: #fff;
  transition: background-color 0.3s;
  gap: 10px;
  flex-wrap: nowrap;
}

.cennik-item:hover {
  background-color: #f0f0f0;
}

.cennik-item div:first-child {
  flex: 1 1 auto;
  font-size: 1rem;
  word-break: break-word;
  min-width: 0;
}

.cennik-item div:last-child {
  flex: 0 0 auto;
  font-size: 0.97rem;
  font-weight: bold;
  white-space: nowrap;
  margin-left: 10px;
}



/* Cookie banner */
#cookie-banner {
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;
  background-color: #003366;
  color: white;
  padding: 20px;
  border-radius: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  z-index: 9999;
}

#cookie-banner p {
  margin: 0;
  font-size: 1rem;
}

#accept-cookies,
#close-cookies {
  background-color: #66b3ff;
  border: none;
  color: white;
  padding: 10px 20px;
  border-radius: 5px;
  font-weight: bold;
  cursor: pointer;
  margin-left: 20px;
  transition: background-color 0.3s ease;
}

#accept-cookies:hover,
#close-cookies:hover {
  background-color: #0059b3;
}

/* Kategorie cennika */
#category-filter {
  margin-bottom: 20px;
  padding: 5px 10px;
  font-size: 1rem;
}

label[for="category-filter"] {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

.cennik-category {
  margin-bottom: 20px;
  border: 1px solid #ccc;
  border-radius: 6px;
  overflow: hidden;
}

.cennik-category-header {
  background-color: #003366;
  color: white;
  font-weight: bold;
  padding: 12px 16px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease;
}

.cennik-category-header:hover {
  background-color: #0059b3;
}

.cennik-list {
  display: none;
  background: #fff;
}

.cennik-category.open .cennik-list {
  display: block;
}

/* Update overlay */
.update-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(255, 255, 255, 0.97);
  z-index: 99999;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: 'Poppins', sans-serif;
  backdrop-filter: blur(3px);
  animation: fadeInDown 0.8s ease-out;
}

.update-message {
  text-align: center;
  font-size: 1.8rem;
  font-weight: bold;
  color: #003366;
  line-height: 1.6;
}

/* Responsive - max 992px */
@media (max-width: 992px) {
  .page-hero h1 {
    font-size: 2.4rem;
  }
}

/* Responsive - max 768px */
@media (max-width: 768px) {
  header {
    flex-direction: column;
    align-items: center;
  }

  .menu-toggle {
    display: block;
    font-size: 2rem;
    cursor: pointer;
    color: white;
    margin-top: 10px;
  }

  nav {
    width: 100%;
  }

  nav ul {
    overflow: hidden;
    max-height: 0;
    flex-direction: column;
    align-items: center;
    background-color: #003366;
    padding: 0;
    margin: 0;
    transition: max-height 0.5s ease-out;
  }

  nav ul.show {
    max-height: 500px;
  }

  nav ul li {
    width: 100%;
    text-align: center;
    border-top: 1px solid #0059b3;
  }

  nav ul li a {
    display: block;
    padding: 15px 0;
    font-size: 1.2rem;
    width: 100%;
  }

  .gallery {
    grid-template-columns: 1fr;
  }

  .cennik-header,
  .cennik-item {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .overlay {
    opacity: 1 !important;
    transform: translateY(0) !important;
    background: rgba(0, 0, 0, 0.5);
    font-size: 0.85rem !important;
    padding: 6px !important;
  }
}
