/* ==========================================================================
   SPRYTNY SZOP EDU – BAZOWY CSS (MINIMALNY, 100% TAILWIND W DOMENOWYCH KLASACH)
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --brand-primary: #25ACB3;
  --brand-primary-hover: #1E8E94;
  --brand-primary-light: #E9F7F8;
  --brand-primary-dark: #176F74;
}

/* Klasy pomocnicze marki */
.bg-brand { background-color: #25ACB3 !important; }
.hover\:bg-brand-hover:hover { background-color: #1E8E94 !important; }
.bg-brand-light { background-color: #E9F7F8 !important; }
.text-brand { color: #25ACB3 !important; }
.text-brand-dark { color: #176F74 !important; }
.border-brand { border-color: #25ACB3 !important; }

/* Klasa uniwersalna stanu zablokowanego (D_C) na elementy, kafelki i przyciski */
.D_C,
button.D_C,
a.D_C {
  pointer-events: none !important;
  opacity: 0.45 !important;
  cursor: not-allowed !important;
  filter: grayscale(40%) !important;
  user-select: none !important;
}

/* Zabezpieczenie przed rozpychaniem SVG przy opóźnieniach CDN */
svg {
  display: inline-block;
  vertical-align: middle;
}

[x-cloak] {
  display: none !important;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  margin: 0;
  padding: 0;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* HTMX Transition & Indicator */
.htmx-indicator {
  display: none;
}
.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator {
  display: inline-flex;
}

/* ==========================================================================
   JEDNOLITY SYSTEM MODALI (Odporny na blokady CDN / Adblockery)
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  overflow-y: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  margin: 0 !important;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 10;
  margin: 0 !important;
}

.modal-panel {
  position: relative;
  width: 100%;
  max-width: 32rem; /* domyślnie max-w-lg */
  max-height: 90vh;
  overflow-y: auto;
  background-color: #ffffff;
  border-radius: 1rem;
  border: 1px solid #e2e8f0;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  padding: 1.5rem;
  z-index: 30;
  margin-left: auto;
  margin-right: auto;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #f1f5f9;
}

.modal-footer {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
}

.modal-close-btn {
  padding: 0.375rem;
  border-radius: 0.5rem;
  color: #94a3b8;
  background: transparent;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.15s, color 0.15s;
}

.modal-close-btn:hover {
  color: #334155;
  background-color: #f1f5f9;
}

@media print {
  @page {
    size: A4 landscape;
    margin: 0;
  }
  .no-print {
    display: none !important;
  }
}