/* Reset box-sizing */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Base page styles */
body {
  font-family: system-ui, sans-serif;
  margin: 0;
  padding: 0;
  background: #f9f9f9;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow-x: hidden;
}

/* Remove link underlines, inherit color */
a {
  text-decoration: none;
  color: inherit;
}
a:hover {
  text-decoration: underline;
}

/* Main container */
main {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1em;
}

/* Generic panels */
.panel {
  padding: 1em;
  margin: 1em auto;
  background: #fff;
  max-width: 95%;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  border-radius: 10px;
  scroll-margin-top: 80px;
}

/* Headings */
h1, h2 {
  font-size: 1.5em;
  text-align: center;
  color: #006699;
}

/* Navigation – two rows: theme toggle + links */
.nav-fixed {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: #006699;
  width: 100vw;
  padding: 0.3em 0.5em;
  gap: 0.3em;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.nav-theme {
  width: 100%;
  display: flex;
  justify-content: center;
}
.nav-links {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 0.3em;
  overflow: hidden;
  width: 100%;
}

/* Navigation links */
.nav-links a {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: #ffffff;     
  font-size: 0.85em;
  padding: 0.4em;
  border-radius: 6px;
  min-width: 62px;
  flex-shrink: 1;
}
.nav-links i {
  font-size: 1.1em;
}
.nav-links span {
  font-size: 0.75em;
  color: #ffffff;     
}
.nav-links a:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* Section titles (to be used on <h3>) */
.section-title {
  font-size: 1.4em;
  font-weight: bold;
  margin: 1.5em 0 0.5em;
  color: #003366;
  text-transform: none;
  letter-spacing: 0.5px;
}

/* Lists */
ul {
  list-style: none;
  margin: 0;
  padding-left: 1em;
}
ul li {
  font-size: 0.95em;
  line-height: 1.4em;
  margin-bottom: 0.9em;
}

/* Images */
img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 8px;
}

/* Forms */
form {
  display: flex;
  flex-direction: column;
  gap: 1em;
  padding: 1em;
  margin: 1em auto;
  max-width: 500px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.05);
}
form input,
form textarea {
  width: 100%;
  padding: 0.75em;
  border: 1px solid #ccc;
  border-radius: 5px;
}
form button {
  background-color: #006699;
  color: white;
  padding: 0.8em 1.2em;
  border: none;
  border-radius: 4px;
  font-weight: bold;
  cursor: pointer;
}
form button:hover {
  background-color: #004466;
}

/* Status message */
#status {
  font-weight: bold;
  text-align: center;
  opacity: 0;
  transition: opacity 0.5s ease;
  background: #e0f7fa;
  padding: 1em;
  border-radius: 5px;
  margin-top: 1em;
}

/* Footer */
footer {
  background: #006699;
  color: white;
  text-align: center;
  padding: 1.5em 1em;
  font-size: 0.9em;
  width: 100%;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5em;
}

/* Scroll-to-top button */
#topBtn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 999;
  background-color: #006699;
  color: white;
  border: none;
  padding: 0.6em 0.9em;
  font-size: 1.2em;
  border-radius: 50%;
  cursor: pointer;
  display: none;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
#topBtn:hover {
  background-color: #004466;
}

/* Fade-in animations */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.show {
  opacity: 1;
  transform: translateY(0);
}

/* Dark mode */
body.dark {
  background: #121212;
  color: #eee;
}
body.dark .panel {
  background: #1e1e1e;
  color: #eee;
}
body.dark footer {
  background: #003366;
}
body.dark #topBtn {
  background: #003366;
}
body.dark .nav-fixed {
  background: #003366;
}
body.dark .nav-links a {
  color: #ffffff;
}
body.dark .nav-links a:hover {
  background: rgba(255,255,255,0.15);
}

/* Theme toggle button */
#themeToggle {
  background: none;
  border: none;
  color: #fff;
  font-size: 1.2em;
  cursor: pointer;
}

/* Responsive adjustments */
@media (min-width: 1024px) {
  .nav-links a {
    font-size: 1.3em;
    padding: 0.6em;
    min-width: 80px;
  }
  .nav-links i {
    font-size: 1.3em;
  }
  .nav-links span {
    font-size: 0.9em;
  }
}
@media (min-width: 768px) {
  .panel {
    max-width: 700px;
  }
  h1, h2 {
    font-size: 2em;
  }
}
@media (max-width: 480px) {
  h1, h2 {
    font-size: 1.3em;
  }
  .section-title {
    font-size: 1.1em;
  }
  .panel, form {
    padding: 0.8em;
    margin: 0.5em;
  }
  #topBtn {
    padding: 0.5em;
    font-size: 1em;
    bottom: 20px;
    right: 20px;
  }
  #themeToggle {
    font-size: 1em;
    padding: 0.3em;
    margin-left: auto;
  }
}

/* Visually hidden helper */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* Pasja icons */
.icon-farm   { color: #4caf50; }
.icon-garden { color: #8bc34a; }
.icon-bee    { color: #ffc107; }
.icon-nature { color: #009688; }
.icon-idea   { color: #ff5722; }

/* Usługi icons */
.icon-it       { color: #2196f3; }
.icon-hardware { color: #4caf50; }
.icon-data     { color: #9c27b0; }
.icon-security { color: #f44336; }
.icon-software { color: #ff9800; }
.icon-internet { color: #3f51b5; }

/* ================================
   KONTRASTOWE „PIGUŁKI” DANYCH KONTAKTOWYCH
   ================================ */
.icon-contact-item {
  display: inline-block;
  padding: 0.1em 0.4em;
  background-color: #fff;
  border-radius: 4px;
  font-weight: bold;
}
.icon-name   { color: #880e4f; }
.icon-email  { color: #1565c0; }
.icon-phone  { color: #2e7d32; }
.icon-bank   { color: #6a1b9a; }

.icon-home   { color: #ff9800 !important; }
.icon-services{ color: #4caf50 !important; }
.icon-passion{ color: #00bcd4 !important; }
.icon-contact{ color: #e91e63 !important; }