@charset "utf-8";

/* ==========================================================================
   1. GLOBALNE I STRUKTURALNE
   ========================================================================== */

/* Focus dla przycisku zmiany motywu */
#theme-toggle:focus {
  box-shadow: none;
}

/* Kolor ikony przełącznika w trybie jasnym */
#theme-toggle {
  color: rgba(70, 130, 180, 0.85) !important;
}

/* Kolor ikony przełącznika w trybie ciemnym */
[data-bs-theme="dark"] #theme-toggle {
 color: rgba(140, 180, 214, 0.85) !important;
}

/* Efekt najechania dziennego - powiększenie ikony */
#theme-toggle:hover {
  transform: scale(1.2);
  color: rgba(26, 58, 90, 0.85) !important;
}

/* Zielony blask w nocy przy najechaniu */
[data-bs-theme="dark"] #theme-toggle:hover {
  color: rgba(152, 251, 152, 0.7) !important;
}

/* Globalne ustawienie płynności dla WSZYSTKICH elementów strony */
body,
.navbar,
img,
.card-cover::after,
a,
.nav-link,
.btn,
#theme-toggle,
.linki,
.linki span,
.linki2,
.form-control {
  transition: all 0.3s ease-in-out !important;
}

/* Płynne przewijanie do kotwic (np. #formularz-kontaktowy) */
html {
  scroll-behavior: smooth;
}

/* Margines dla kotwic - zapobiega chowaniu się nagłówka pod menu */
#formularz-kontaktowy {
  scroll-margin-top: 100px;
}

/* Animacja wejścia dla powiadomień po wysłaniu formularza */
#status-alert-container .alert {
  animation: slideInAndFade 0.6s ease-in-out forwards;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

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

/* Utrzymanie wysokości kart w Prezentacji i zdjęć w Social Media */
@media (min-width: 768px) {
  .h-md-250 { height: 250px; }
}


/* ==========================================================================
   2. TYPOGRAFIA I KOLORY - KLASY
   ========================================================================== */

/* #8cb4d6 (140,180,214) jasny niebieski
   #4682b4 (70, 130, 180) steelblue
   #1a3a5a (26, 58, 90) ciemny niebieski
   #a5d6a7 (165, 214, 167) jasny zielony
   #98fb98 (152, 251, 152) palegreen
   #2e7d32 (46, 125, 50) ciemny zielony
*/

/* Steelblue i akcentujący błękit - tylko jasny motyw */
.text-steelblue,
.text-accent-blue {
  color: steelblue !important;
}

/* Nadpisanie: Tylko akcentujący błękit jaśnieje w nocy */
[data-bs-theme="dark"] .text-accent-blue {
  color: #8cb4d6 !important;
}

/* Klasyczny SteelBlue jako background */
.bg-accent-blue {
  background-color: steelblue !important;
}

/* Zielone akcenty i tło przycisu Nasza Oferta */
.bg-accent-green {
  border-radius: 8px !important;
  padding-top: 4px !important;
  padding-bottom: 4px !important;
  margin-top: 4px;
  margin-bottom: 4px;
  display: inline-block;
}

/* Zielony kolor tła dla jasnego motywu */
[data-bs-theme="light"] .bg-accent-green {
  background-color: rgba(152, 251, 152, 0.85) !important;
  box-shadow: 0 0 15px rgba(152, 251, 152, 0.6);
}

/* Soczysta zieleń w nocy bez wpływu filtrów */
[data-bs-theme="dark"] .bg-accent-green {
  background-color: rgba(46, 125, 50, 0.85) !important;
  box-shadow: 0 0 15px rgba(46, 125, 50, 0.6);
  filter: none !important;
}


/* ==========================================================================
   3. ELEMENTY INTERAKTYWNE (.LINKI)
   ========================================================================== */

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

[data-bs-theme="dark"] a {
  color: #8cb4d6;
}

a:hover {
  color: #8cb4d6;
  box-shadow: 0 0 10px rgba(152, 251, 152, 0.4);
}

.linki {
  padding: 2px 6px;
}

[data-bs-theme="dark"] .linki {
  color: #8cb4d6 !important;
}

.linki:hover {
  color: #ffffff !important;
  background-color: steelblue;
  border-radius: 8px;
}

[data-bs-theme="dark"] .linki:hover {
  color: #ffffff !important;
  background-color: #1a3a5a;
}

/* Nowoczesna transformacja strzałek w Ofercie */
.linki span {
  display: inline-block; /* Pozwala na animację ruchu */
}

/* Efekt po najechaniu na link - odjazd strzałek */
.linki:hover span {
  transform: translateX(5px); /* Strzałka lekko "ucieka" w prawo */
}

[data-bs-theme="dark"] .linki:hover span {
  color: #a5d6a7 !important; /* Delikatniejsza zieleń w nocy */
}

/* Linki2 to trzy fotki obok siebie w Prezentacji */
[data-bs-theme="dark"] .linki2 {
  color: steelblue !important;
}

[data-bs-theme="dark"] .linki2:hover {
  color: #a5d6a7 !important;
}


/* ==========================================================================
   4. NAWIGACJA I RESPONSYWNE LOGO
   ========================================================================== */

/* Bazowe ustawienia logo SVG */
.navbar-brand svg {
  width: 215px;
  height: auto;
}

.navbar-brand svg .fil0,
.navbar-brand svg .fil1,
.navbar-brand svg .fil2 {
  fill: steelblue !important;
}

/* Ośmiościan - litera S */
[data-bs-theme="dark"] .navbar-brand svg .fil0 {
  fill: steelblue !important;
}

/* Zabudowy balkonów i tarasów */
[data-bs-theme="dark"] .navbar-brand svg .fil1 {
  fill: #8cb4d6 !important;
}

/* tarasysuperson.pl */
[data-bs-theme="dark"] .navbar-brand svg .fil2 {
  fill: #a5d6a7 !important;
}

/* Moment krytyczny: Tablet / Mały laptop (pomiędzy 992px lg - 1250px xl) */
@media (min-width: 992px) and (max-width: 1250px) {
  .navbar-brand svg {
    width: 160px; /* Zmniejszenie loga o 55px - to da miejsce dla "O FIRMIE" */
  }
  .navbar-nav .nav-link {
    padding-left: 10px !important;
    padding-right: 10px !important;
  }
}

/* Logo na telefonach */
@media (max-width: 991px) {
  .navbar-brand svg {
    width: 150px;
  }
}


/* ==========================================================================
   5. FILTRY I NAKŁADKI NA KARTY
   ========================================================================== */

/* Nakładki na zdjęcia (Card Cover) */
.card-cover {
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  position: relative; /* Ważne dla nakładki ::after */
}

.card-cover::after {
  content: "";
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  z-index: 1;
  pointer-events: none;
}

/* Tryb jasny: Przyciemnienie kart dla czytelności tekstu */
.card-cover::after {
  background-color: rgba(0, 0, 0, 0.5);
}

/* Tryb ciemny: lżejsza nakładka, bo dochodzi Filtr IMG/SVG */
[data-bs-theme="dark"] .card-cover::after {
  background-color: rgba(0, 0, 0, 0.3);
}

/* Cień dla czytelności tekstów na kartach */
.text-shadow-2 {
  text-shadow: 0 .25rem .5rem rgba(0, 0, 0, 1);
}


/* ==========================================================================
   6. TRYB CIEMNY - SPECYFICZNE NADPISANIA
   ========================================================================== */

/* Globalne tonowanie TYLKO zdjęć w nocy (obsługuje .jpg, .webp itd.) */
[data-bs-theme="dark"] img {
  filter: brightness(0.8) contrast(1.05) saturate(0.9);
}

/* Wyjątek: wyłączenie filtrów dla wszystkich zdjęć (odkomentuj poniższą linię) */
/* [data-bs-theme="dark"] img { filter: none !important; } */

/* Wyjątek: Zdjęcia w karuzeli mogą być ciut jaśniejsze niż reszta */
[data-bs-theme="dark"] .carousel-item img {
  filter: brightness(0.9);
}

/* Globalne tonowanie SVG w nocy (ikony, logotyp) */
[data-bs-theme="dark"] svg {
  filter: brightness(0.8) contrast(1.05) saturate(0.9);
}

/* Wyjątek: wyłączenie tonowania dla wszystkich grafik SVG
[data-bs-theme="dark"] svg {
  filter: none !important;
} */

/* Widoczne cienie sekcji w trybie ciemnym
[data-bs-theme="dark"] .shadow-lg {
  box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.5) !important;
  border: 1px solid rgba(255, 255, 255, 0.05) !important;
} */

/* Szklany, mglisty wygląd formularza w trybie ciemnym */
[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select {
  background-color: rgba(255, 255, 255, 0.05) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  color: #dee2e6 !important;
  backdrop-filter: blur(4px);
}

/* Stan focus - gdy użytkownik klika w pole formularza */
[data-bs-theme="dark"] .form-control:focus {
  background-color: rgba(255, 255, 255, 0.1) !important;
  border-color: #a5d6a7 !important; /* Twój zielony akcent */
  box-shadow: 0 0 0 0.25rem rgba(165, 214, 167, 0.2) !important;
}

/* Naprawienie koloru placeholderów w nocy */
[data-bs-theme="dark"] .form-control::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

/* Przyciemnienie mapy w nocy */
[data-bs-theme="dark"] iframe {
  filter: grayscale(0.5) invert(0.9) hue-rotate(180deg) brightness(0.8);
}

/* Sekcja HR dostosowana do ciemnego motywu */
[data-bs-theme="dark"] hr {
  background-image: linear-gradient(to right, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0)) !important;
  opacity: 0.15;
  border: 0;
  height: 1px;
}
