/* Custom CSS for Mortgage Calculator (Tailwind based) */
/* Based on IL_Web_OC/css/styles.css */

body {
  font-family: "Outfit", sans-serif;
  transition: background-color 0.2s, color 0.2s;
}
.custom-shadow {
  box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.05);
}
.material-symbols-outlined {
  font-variation-settings:
    "FILL" 0,
    "wght" 400,
    "GRAD" 0,
    "opsz" 24;
}
.dropdown:hover .dropdown-menu {
  display: block;
}

/* Range Slider Styling - Premium Emerald */
input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  background-color: #e2e8f0;
  border-radius: 5px;
  background-image: linear-gradient(#10b981, #10b981);
  background-repeat: no-repeat;
  cursor: pointer;
}
.dark input[type="range"] {
  background-color: #334155;
}

/* Thumb (Kropka) Stylizacja */
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  height: 20px;
  width: 20px;
  border-radius: 50%;
  background: #10b981;
  cursor: pointer;
  border: 2px solid #fff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: transform 0.1s ease;
}
.dark input[type="range"]::-webkit-slider-thumb {
  border-color: #1e293b;
}

/* Footer & Clause Animation */
.footer-content {
  transition:
    max-height 0.4s ease,
    opacity 0.4s ease;
  overflow: hidden;
  opacity: 0;
  max-height: 0;
}
.footer-content.open {
  opacity: 1;
  max-height: 2000px;
}
.footer-toggle {
  cursor: pointer;
  user-select: none;
}

/* Validation Errors */
input.cf-invalid,
select.cf-invalid,
textarea.cf-invalid {
  border-color: #dc2626 !important;
  box-shadow: 0 0 0 1px #dc2626 !important;
}
input.cf-valid,
select.cf-valid,
textarea.cf-valid {
  border-color: #10b981 !important;
  box-shadow: 0 0 0 1px #10b981 !important;
}

.cf-error {
  display: none;
  font-size: 11px;
  color: #dc2626;
  margin-top: 4px;
}
.cf-error.active {
  display: block;
}

/* Custom Scrollbar for Dropdown */
.custom-scrollbar::-webkit-scrollbar {
  width: 6px;
}
.custom-scrollbar::-webkit-scrollbar-track {
  background: transparent;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
  background-color: #cbd5e1;
  border-radius: 20px;
}
.dark .custom-scrollbar::-webkit-scrollbar-thumb {
  background-color: #475569;
}

/* --- Cookies Banner --- */
#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: #1e293b;
  color: #fff;
  padding: 15px 20px;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.2);
  z-index: 10000;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 1;
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
}
#cookie-banner.hide {
  opacity: 0;
  transform: translateY(100%);
  pointer-events: none;
}
#cookie-banner .cookie-content {
  max-width: 900px;
  display: flex;
  align-items: center;
  gap: 20px;
}
#cookie-banner p {
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
  color: #cbd5e1;
}
#cookie-banner button {
  background: #10b981;
  color: white;
  border: none;
  padding: 8px 20px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s;
}
#cookie-banner button:hover {
  background: #059669;
}
@media (max-width: 600px) {
  #cookie-banner .cookie-content {
    flex-direction: column;
    text-align: center;
  }
  #cookie-banner button {
    width: 100%;
  }
}
