/* ======================================================
   PROCuro APP CSS
   Niezależny od index.css
   ====================================================== */

/* ======================================================
   RESET + BASE
   ====================================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  background: var(--bg-light);
  color: var(--ink);
  line-height: 1.6;
}

/* Design tokens live in procuro-tokens.css (loaded first via <link>). */

/* ======================================================
   LAYOUT
   ====================================================== */
.container {
  max-width: 90%;
  margin-inline: auto;
  padding-inline: var(--space-xl);
  width: 100%;
}

.main-container {
  padding-top: var(--space-3xl);
}

.checkbox-group {
  display: flex;
  align-items: center;
  gap: var(--space-2xs-plus);
}

/* ======================================================
   HEADER
   ====================================================== */
.procuro-header-shell,
.procuro-header-shell * {
  box-sizing: border-box;
}

.procuro-header-shell {
  position: sticky;
  top: 0;
  z-index: var(--z-dropdown);

  height: 88px;
  background: var(--gradient-header);

  transition: height var(--transition-slow) ease,
    box-shadow var(--transition-slow) ease;

  box-shadow: none;
}

.procuro-header-shell.scrolled {
  height: 64px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.25);
}

/* accent line */
.procuro-header-shell::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--procuro-gradient);
}

/* container */
.header-container {
  height: 100%;
  max-width: 90%;
  margin: 0 auto;

  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* logo */
.procuro-logo {
  display: inline-flex;
  align-items: center;
  position: relative;
}

.logo-wordmark {
  height: 55px;
  transition: opacity var(--transition-medium) ease, transform var(--transition-medium) ease;
}

.logo-monogram {
  position: absolute;
  left: 0;
  height: 48px;
  opacity: 0;
  transform: scale(0.85);
  transition: opacity var(--transition-medium) ease, transform var(--transition-medium) ease;
}

.procuro-header-shell.scrolled .logo-wordmark {
  opacity: 0;
  transform: scale(0.9);
}

.procuro-header-shell.scrolled .logo-monogram {
  opacity: 1;
  transform: scale(1);
}

/* nav */
.main-nav {
  display: flex;
  align-items: center;
  gap: var(--space-2xl);
}

.main-nav a.active {
  color: #ffffff;
  font-weight: var(--font-weight-semibold);
  position: relative;
}

/* underline / active indicator */
.main-nav a.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  width: 100%;
  height: 3px;
  border-radius: 3px;
  background: var(--procuro-gradient);
}

.nav-left {
  display: flex;
  gap: var(--space-xl);
}

.nav-left a {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: var(--font-weight-semibold);
  position: relative;
  padding: var(--space-2xs) 0;
}

.nav-ai-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.nav-ai-link svg {
  flex-shrink: 0;
  opacity: 0.9;
}

.nav-left a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 3px;
  background: var(--procuro-gradient);
  border-radius: 3px;
  transition: width var(--transition-medium) ease;
}

.nav-left a:hover::after,
.nav-left a.active::after {
  width: 100%;
}

.nav-right {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

/* ======================================================
   USER TILE + DROPDOWN
   ====================================================== */
.user-tile {
  background: rgba(255,255,255,0.92);
  border: 1px solid rgba(255,255,255,0.25);

  padding: var(--space-2xs-plus) var(--space-sm-plus);
  border-radius: 10px;

  font-size: .85rem;
  font-weight: var(--font-weight-medium);
  color: var(--navy-800);

  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);

  cursor: pointer;
  position: relative;

  transition: background var(--transition-base) ease,
    box-shadow var(--transition-base) ease,
    transform var(--transition-fast) ease;
}

.user-tile:hover {
  background: #ffffff;
  box-shadow: 0 6px 18px rgba(0,0,0,.25);
}

.user-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;

  min-width: 220px;
  background: var(--gradient-header);

  border-radius: 14px;
  box-shadow: 0 16px 32px rgba(0,0,0,.35);
  z-index: var(--z-sticky);

  display: none;
  flex-direction: column;
  overflow: hidden;
}

.user-dropdown.show {
  display: flex;
}

.user-dropdown a,
.user-dropdown button {
  all: unset;
  padding: var(--space-sm) var(--space-md);
  font-size: .9rem;
  font-weight: var(--font-weight-medium);
  color: #ffffff;

  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
}

.user-dropdown a:hover,
.user-dropdown button:hover {
  background: rgba(255,255,255,.08);
}

.user-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.user-email {
  font-size: 0.85rem;
  font-weight: var(--font-weight-medium);
}

.user-context {
  font-size: 0.72rem;
  color: navy-900;
}

/* ======================================================
   TABS – Procuro buttons (primary / secondary)
   ====================================================== */
.tabs-container {
  margin: var(--space-2xl) 0 var(--space-xl);
  display: flex;
  gap: var(--space-sm);
}

/* tab = normalny procuro-btn */
.tab-button {
  flex: 1;
}

/* "Aktywne" (announcements) rośnie i wypełnia resztę (flex:1 powyżej).
   "Po terminie" (results) i "Rozstrzygnięte" (archive) — jednakowa, stała szerokość. */
.tab-button[data-tab="results"],
.tab-button[data-tab="archive"] {
  flex: 0 0 200px;
}

/* NIEAKTYWNY */
.tab-button.secondary {
  background: #ffffff;
  color: var(--navy-800);
  border: 1px solid var(--border);
  box-shadow: none;
}

.tab-button.secondary:hover {
  background: #f8fafc;
}

/* AKTYWNY */
.tab-button.primary {
  background: var(--procuro-gradient);
  color: #ffffff;
  border: none;
  box-shadow: 0 6px 20px rgba(14,165,164,0.35);
}


/* ======================================================
   WELCOME MODAL
   ====================================================== */

.welcome-modal {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xl);
  background: rgba(5, 12, 20, 0.72);
  backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-medium) ease;
}

.welcome-modal.is-visible {
  opacity: 1;
  pointer-events: all;
}

.welcome-modal-card {
  position: relative;
  background: linear-gradient(160deg, #0f2438 0%, #0b1c2d 100%);
  border: 1px solid rgba(14, 165, 164, 0.3);
  border-radius: 24px;
  padding: var(--space-4xl) var(--space-4xl) var(--space-3xl);
  max-width: 600px;
  width: 100%;
  box-shadow:
    0 0 0 1px rgba(14, 165, 164, 0.07),
    0 40px 80px rgba(0, 0, 0, 0.65);
  transform: translateY(14px);
  transition: transform var(--transition-slow) ease;
}

.welcome-modal.is-visible .welcome-modal-card {
  transform: translateY(0);
}

/* ── Close × button ── */
.welcome-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background var(--transition-base), color var(--transition-base);
}

.welcome-modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

/* ── Header ── */
.welcome-modal-header {
  margin-bottom: var(--space-xl-plus);
}

.welcome-modal-logo {
  display: block;
  margin-bottom: var(--space-md);
}

.welcome-modal-header h2 {
  font-size: 1.5rem;
  font-weight: var(--font-weight-extrabold);
  letter-spacing: -0.02em;
  color: #ffffff;
  margin: 0 0 var(--space-sm);
}

.welcome-modal-header p {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.58);
  line-height: 1.65;
  margin: 0;
}

.welcome-modal-header p strong {
  color: rgba(255, 255, 255, 0.85);
  font-weight: var(--font-weight-semibold);
}

/* ── Feature rows ── */
.welcome-modal-features {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs-plus);
  margin-bottom: var(--space-2xl);
}

.welcome-feature {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm-plus);
  padding: var(--space-sm-plus) var(--space-md);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  transition: background var(--transition-base);
}

.welcome-feature:hover {
  background: rgba(255, 255, 255, 0.07);
}

.welcome-feature-badge {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(14, 165, 164, 0.12);
  border: 1px solid rgba(14, 165, 164, 0.22);
  color: var(--teal-500);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}

.welcome-feature-badge--ai {
  background: rgba(14, 165, 164, 0.2);
  border-color: rgba(14, 165, 164, 0.4);
  color: #5eead4;
}

.welcome-feature strong {
  display: block;
  font-size: 0.87rem;
  font-weight: var(--font-weight-bold);
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 3px;
}

.welcome-feature p {
  font-size: 0.81rem;
  color: rgba(255, 255, 255, 0.48);
  line-height: 1.55;
  margin: 0;
}

/* ── Actions ── */
.welcome-modal-actions {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  flex-wrap: wrap;
}

.welcome-modal-help {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 0.87rem;
  font-weight: var(--font-weight-bold);
  color: var(--teal-500);
  text-decoration: none;
  padding: 0 var(--space-2xs);
  border-bottom: 1px solid rgba(14, 165, 164, 0.35);
  transition: color var(--transition-base), border-color var(--transition-base);
}

.welcome-modal-help::before {
  content: "";
  display: inline-block;
  width: 16px;
  height: 16px;
  background-color: var(--teal-500);
  opacity: 0.85;
  mask-image: url("../assets/help_icon.svg");
  mask-size: contain;
  mask-repeat: no-repeat;
  flex-shrink: 0;
  transition: opacity var(--transition-base);
}

.welcome-modal-help:hover {
  color: #5eead4;
  border-color: rgba(94, 234, 212, 0.5);
}

.welcome-modal-help:hover::before {
  opacity: 1;
  background-color: #5eead4;
}

@media (max-width: 640px) {
  .welcome-modal-card {
    padding: 36px var(--space-lg-plus) var(--space-xl-plus);
    border-radius: 18px;
  }

  .welcome-modal-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .welcome-modal-actions .procuro-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ======================================================
   SAVE SEARCH MODAL (nazwa zapisanego wyszukiwania)
   ====================================================== */
.save-search-modal {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-xl);
  background: rgba(5, 12, 20, 0.6);
  backdrop-filter: blur(4px);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-medium) ease;
}

.save-search-modal.is-visible {
  opacity: 1;
  pointer-events: all;
}

.save-search-modal-card {
  position: relative;
  width: 100%;
  max-width: 440px;
  background: var(--bg-white);
  border: 1px solid var(--procuro-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: var(--space-2xl) var(--space-2xl) var(--space-xl);
  transform: translateY(12px);
  transition: transform var(--transition-slow) ease;
}

.save-search-modal.is-visible .save-search-modal-card {
  transform: translateY(0);
}

.save-search-modal-close {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--procuro-border);
  background: var(--bg-white);
  color: var(--procuro-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color var(--transition-base), color var(--transition-base);
}

.save-search-modal-close:hover {
  border-color: var(--teal-500);
  color: var(--navy-900);
}

.save-search-modal-title {
  font-size: 1.2rem;
  font-weight: var(--font-weight-extrabold);
  letter-spacing: -0.01em;
  color: var(--navy-900);
  margin: 0 0 var(--space-2xs);
}

.save-search-modal-desc {
  font-size: 0.85rem;
  line-height: 1.55;
  color: var(--procuro-muted);
  margin: 0 0 var(--space-lg);
}

.save-search-modal-label {
  display: block;
  font-size: 0.8rem;
  font-weight: var(--font-weight-bold);
  color: var(--navy-900);
  margin-bottom: var(--space-2xs);
}

.save-search-modal-input {
  width: 100%;
  padding: var(--space-xs-plus) var(--space-sm-plus);
  border-radius: var(--radius-md);
  border: 1px solid var(--procuro-border);
  background: var(--procuro-surface);
  color: var(--navy-900);
  font-size: 0.9rem;
}

.save-search-modal-input:focus {
  outline: none;
  border-color: var(--teal-500);
  box-shadow: var(--shadow-focus-ring);
}

.save-search-modal-error {
  font-size: 0.78rem;
  color: #c0392b;
  margin: var(--space-2xs) 0 0;
}

.save-search-modal-alerts {
  margin-top: var(--space-lg);
  padding-top: var(--space-md);
  border-top: 1px solid var(--procuro-border);
}

.save-search-modal-alerts .toggle-label {
  font-size: 0.82rem;
  font-weight: var(--font-weight-semibold);
  color: var(--navy-900);
}

.save-search-modal-alerts-note {
  font-size: 0.75rem;
  color: var(--procuro-muted);
  margin: var(--space-2xs) 0 0;
}

.save-search-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-sm);
  margin-top: var(--space-xl);
}

@media (max-width: 480px) {
  .save-search-modal-card {
    padding: var(--space-xl) var(--space-lg) var(--space-lg);
  }

  .save-search-modal-actions {
    flex-direction: column-reverse;
  }

  .save-search-modal-actions .procuro-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ======================================================
   SEARCH BAR
   ====================================================== */
.search-bar {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-xl-plus);
  box-shadow: 0 12px 32px rgba(0,0,0,.06);
}

.form-group-inline {
  display: flex;
  flex-direction: column;
  gap: var(--space-2xs);
  flex: 1;
  min-width: 200px;
}

.search-bar label {
  font-size: .8rem;
  font-weight: var(--font-weight-bold);
  color: var(--muted);
}

.search-bar input,
.search-bar select {
  padding: var(--space-xs-plus) var(--space-sm-plus);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: #f9fafb;
  font-size: .85rem;
}

.search-bar input:focus,
.search-bar select:focus {
  outline: none;
  border-color: var(--teal-500);
  box-shadow: 0 0 0 4px rgba(14,165,164,.15);
}

.search-actions-row {
  display: grid;
  grid-template-columns: auto 1fr 1fr auto;
  align-items: start;
  gap: var(--space-xl-plus);
}

.search-actions-row.archive-mode {
  display: flex;
  align-items: center;
}

.search-actions-row.archive-mode .button-container {
  margin-left: auto;
}

.search-actions-row.archive-mode .button-container .procuro-btn {
  margin-top: 0;
}

.button-container {
  display: flex;
  align-items: center;
}

.search-actions-row .procuro-btn {
  height: 36px;
  padding: 0 var(--space-md);
  font-size: 0.85rem;
  margin-top: var(--space-md-plus);
  align-self: start;
}

/* Lewa kolumna: "Wyczyść filtry" + "Zapisz wyszukiwanie" zestackowane pionowo
   (jedna komórka grida — bez rozbijania układu auto 1fr 1fr auto). */
.search-side-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  margin-top: var(--space-md-plus);
}

.search-side-actions .procuro-btn {
  margin-top: 0;
  width: 100%;
}

/* Toggle "Uwzględnij zamówienia europejskie" / "Inteligentne dopasowanie"
   — wyśrodkowane pionowo w wierszu akcji. */
.search-actions-row .smart-ai-row {
  align-self: center;
}

/* "Wyszukaj" — wyśrodkowany pionowo w wierszu akcji (prawa kolumna). */
.search-actions-row .button-container {
  align-self: center;
}

.search-actions-row .button-container .procuro-btn {
  margin-top: 0;
}

/* .procuro-btn — przeniesiony do procuro-tokens.css */

/* ======================================================
   AI BANNER (Procuro)
   ====================================================== */
.ai-banner {
  display: flex;
  align-items: center;
  gap: var(--space-xs-plus);

  margin: var(--space-lg) 0 var(--space-xs);
  padding: var(--space-sm-plus) var(--space-md-plus);

  background: linear-gradient(
    135deg,
    rgba(14,165,164,0.12),
    rgba(8,145,178,0.12)
  );

  border: 1px solid rgba(14,165,164,0.35);
  border-left: 4px solid var(--teal-500);

  border-radius: var(--radius-md);

  font-size: 0.85rem;
  color: var(--navy-800);
  line-height: 1.45;
}

.ai-banner strong {
  color: var(--teal-600);
  font-weight: var(--font-weight-bold);
}

/* opcjonalna ikonka AI (bez emoji) */
.ai-banner::before {
  content: "AI";
  display: inline-flex;
  align-items: center;
  justify-content: center;

  min-width: 20px;
  height: 20px;

  border-radius: 999px;
  background: var(--procuro-gradient);
  color: #fff;

  font-size: 0.7rem;
  font-weight: var(--font-weight-extrabold);
  letter-spacing: 0.08em;
}

/* wariant ostrzegawczy — profil AI niewypełniony */
.ai-banner--warning {
  background: linear-gradient(
    135deg,
    rgba(234,179,8,0.12),
    rgba(249,115,22,0.12)
  );
  border-color: rgba(234,179,8,0.45);
  border-left-color: #eab308;
}

.ai-banner--warning a {
  color: var(--teal-600);
  font-weight: var(--font-weight-semibold);
  text-decoration: underline;
}

.ai-banner--warning a:hover {
  color: var(--teal-700);
}


/* ======================================================
   AI BANNER 3 — Profile Context (Baner 3 ✓ wybrany)
   ====================================================== */
.ai-banner-3 {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: var(--space-sm) var(--space-md);
  background: linear-gradient(135deg, rgba(14,165,164,.06), rgba(8,145,178,.03));
  border: 1px solid rgba(14,165,164,.2);
  border-radius: 10px;
  margin: var(--space-md) 0 var(--space-xs);
}

.ai-banner-3__text {
  flex: 1;
  min-width: 0;
}

.ai-banner-3__primary {
  margin: 0 0 var(--space-3xs);
  font-size: 0.82rem;
  font-weight: var(--font-weight-semibold);
  color: #102a43;
}

.ai-banner-3__secondary {
  margin: 0;
  font-size: 0.76rem;
  color: #6b7280;
}

.ai-banner-3__cpv-name {
  color: #0891b2;
  font-weight: var(--font-weight-semibold);
}

.ai-banner-3__edit {
  flex-shrink: 0;
  font-size: 0.76rem;
  font-weight: var(--font-weight-semibold);
  color: var(--teal-600);
  text-decoration: none;
  white-space: nowrap;
}

.ai-banner-3__edit:hover {
  text-decoration: underline;
}

@media (max-width: 640px) {
  .ai-banner-3 {
    gap: var(--space-xs-plus);
    padding: var(--space-xs-plus) 13px;
  }

  .ai-banner-3__secondary,
  .ai-banner-3__edit {
    display: none;
  }
}


/* =======================================================================
   COUNTER
   ======================================================================= */
.results-count {
  margin-top: var(--space-xl);
  margin-bottom: var(--space-xs);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: var(--font-weight-medium);
}

.results-count strong {
  color: var(--teal-600);
}

#results {
  margin-top: var(--space-2xl);
}

/* .button-small + variants — przeniesione do procuro-tokens.css */

/* ======================================================
   PAGINATION
   ====================================================== */
.pagination {
  display: flex;
  justify-content: center;
  gap: var(--space-xs);
  margin-top: var(--space-xl);
}

.pagination button {
  padding: var(--space-2xs-plus) var(--space-xs-plus);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: #ffffff;
  cursor: pointer;
}

.pagination button.active {
  background: var(--teal-500);
  color: #ffffff;
}

.pagination-info {
  margin-top: var(--space-sm);
  font-size: .85rem;
  color: var(--muted);
  text-align: center;
}

/* Desktop: ok. +2% vs baza (po obniżce -15% z poprzedniego +20%); mobile (<=480px) bez zmian */
@media (min-width: 481px) {
  .pagination {
    gap: var(--space-xs-plus);
  }

  .pagination button {
    padding: 6px var(--space-xs-plus);
  }

  .pagination-info {
    font-size: 0.85rem;
  }
}

/* ======================================================
   FOOTER
   ====================================================== */
footer {
  background: var(--procuro-bg-light);
  border-top: 1px solid var(--procuro-border);
  padding: var(--space-2xl) 0;
  font-size: 0.9rem;
}

.footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.footer-nav {
  display: flex;
  gap: var(--space-md-plus);
  flex-wrap: wrap;
}

.footer-nav a {
  color: var(--procuro-muted);
  text-decoration: none;
}

.footer-nav a:hover {
  text-decoration: underline;
}

.footer-copy {
  color: var(--procuro-muted);
}

/* ======================================================
   DROPDOWN CHECKBOX (Procuro style)
   ====================================================== */
.dropdown-checkbox {
  position: relative;
  width: 100%;
}

.dropdown-checkbox-toggle {
  width: 100%;
  padding: var(--space-xs-plus) var(--space-sm-plus);
  background: #f9fafb;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: .85rem;
  color: var(--navy-800);
  cursor: pointer;

  display: flex;
  justify-content: space-between;
  align-items: center;

  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;

  transition: border-color var(--transition-base) ease, box-shadow var(--transition-base) ease, background var(--transition-base) ease;
}

.dropdown-checkbox-toggle:hover,
.dropdown-checkbox.open .dropdown-checkbox-toggle {
  background: #ffffff;
  border-color: var(--teal-500);
  box-shadow: 0 0 0 3px rgba(14,165,164,.15);
}

.dropdown-checkbox-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  width: 100%;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: 0 16px 32px rgba(0,0,0,.12);
  z-index: 50;

  max-height: 0;
  opacity: 0;
  overflow: hidden;

  transition: max-height var(--transition-medium) ease, opacity var(--transition-fast) ease;
}

.dropdown-checkbox.open .dropdown-checkbox-menu {
  max-height: 320px;
  opacity: 1;
  overflow-y: auto;
}

.dropdown-checkbox-menu label {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-sm-plus);
  font-size: .8rem;
  color: var(--navy-800);
  cursor: pointer;
}

.dropdown-checkbox-menu label:hover {
  background: #f1fbf9;
}

.dropdown-checkbox-menu input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--teal-500);
}

/* scrollbar */
.dropdown-checkbox-menu::-webkit-scrollbar {
  width: 6px;
}
.dropdown-checkbox-menu::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 6px;
}

/* ======================================================
   NUTS CASCADE SELECTOR
====================================================== */
.nuts-cascade {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0;
  width: 100%;
}

.nuts-cascade-col {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border, #e2e8f0);
  min-height: 0;
}

.nuts-cascade-col:last-child {
  border-right: none;
}

.nuts-cascade-col-header {
  font-size: 0.72rem;
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-secondary, #64748b);
  padding: var(--space-xs) var(--space-xs-plus) var(--space-2xs);
  border-bottom: 1px solid var(--border, #e2e8f0);
}

.nuts-cascade-col-list {
  overflow-y: auto;
  max-height: 260px;
  min-height: 60px;
}

.nuts-cascade-col-list.nuts-cascade-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted, #94a3b8);
  font-size: 0.8rem;
}

.nuts-cascade-item {
  display: flex;
  align-items: center;
  gap: var(--space-2xs-plus);
  padding: 5px var(--space-xs-plus);
  cursor: pointer;
  font-size: 0.82rem;
  line-height: 1.3;
  white-space: nowrap;
}

.nuts-cascade-item:hover {
  background: #f1fbf9;
}

.nuts-cascade-item--active {
  background: #e6f7f4;
}

/* Rodzic aktywnie zawężający kolejne kolumny (drill-down widoku). */
.nuts-cascade-item--drilled {
  font-weight: var(--font-weight-semibold);
  box-shadow: inset 2px 0 0 var(--teal-600, #0d9488);
}

.nuts-cascade-item input[type="checkbox"] {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.nuts-cascade-drilldown {
  cursor: pointer;
  flex: 1;
}

.nuts-cascade-drilldown:hover {
  text-decoration: underline;
  color: var(--teal-600, #0d9488);
}

/* Wider dropdown for NUTS — clamped to viewport */
#nutsDropdown .dropdown-checkbox-menu {
  width: min(720px, calc(100vw - 32px));
  max-width: calc(100vw - 32px);
  right: auto;
  left: 50%;
  transform: translateX(-50%);
}

.nuts-cascade-col-list::-webkit-scrollbar {
  width: 5px;
}
.nuts-cascade-col-list::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 5px;
}

@media (max-width: 700px) {
  .nuts-cascade {
    grid-template-columns: 1fr;
    min-width: 0;
  }
  #nutsDropdown .dropdown-checkbox-menu {
    width: calc(100vw - 24px);
    left: 0;
    transform: none;
  }
  .nuts-cascade-col {
    border-right: none;
    border-bottom: 1px solid var(--border, #e2e8f0);
  }
  .nuts-cascade-col:last-child {
    border-bottom: none;
  }
}

/* ======================================================
   KEYWORDS + ORDER NUMBER – alignment
====================================================== */
.filters-grid-keywords {
  grid-template-columns: repeat(5, 1fr);
}

/* słowa kluczowe zajmują 3 kolumny */
.filters-grid-keywords .keyword-search {
  grid-column: span 3;
}

/* identyfikator postępowania – 2 kolumny */
.filters-grid-keywords .tender-id-group {
  grid-column: span 2;
}

@media (max-width: 1100px) {
  .filters-grid-keywords {
    grid-template-columns: repeat(3, 1fr);
  }

  .filters-grid-keywords .keyword-search,
  .filters-grid-keywords .tender-id-group {
    grid-column: span 3;
  }
}

@media (max-width: 700px) {
  .filters-grid-keywords {
    grid-template-columns: 1fr;
  }
}

/* ======================================================
   EXTRA FILTERS
   ====================================================== */
.extra-filters {
  width: 100%;
  margin-top: var(--space-sm-plus);
  pointer-events: none;
}

.extra-filters-toggle {
  width: 100%;
  background: #ffffff;
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-sm) var(--space-md);
  font-size: .85rem;
  font-weight: var(--font-weight-semibold);
  color: var(--navy-800);
  cursor: pointer;
}

.extra-filters-toggle:hover {
  background: #f1fbf9;
  border-color: var(--teal-500);
}

.extra-filters-content {
  display: none;
  margin-top: var(--space-sm);
  margin-bottom: var(--space-sm);
  padding: var(--space-lg);
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: 0 12px 28px rgba(0,0,0,.06);

  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-md);
}

.extra-filters.open .extra-filters-content {
  display: grid;
}


.extra-filters-heading {
  grid-column: 1 / -1;
  margin: var(--space-2xs) 0 0;
  font-size: 0.82rem;
  font-weight: var(--font-weight-semibold);
  color: var(--text-secondary, #64748b);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.extra-filters-content,
.extra-filters.open .extra-filters-content {
  pointer-events: auto;
}

.filters-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

@media (max-width: 1100px) {
  .filters-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 700px) {
  .filters-grid {
    grid-template-columns: 1fr;
  }
}

/* ======================================================
   TOGGLE SWITCH (AI / TED)
   ====================================================== */
.toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs-plus);
  min-height: 40px;
}

.toggle input {
  display: none;
}

.slider {
  width: 42px;
  height: 22px;
  background: #d1d5db;
  border-radius: 999px;
  position: relative;
  transition: background var(--transition-base) ease;
}

.slider::before {
  content: "";
  width: 18px;
  height: 18px;
  background: #ffffff;
  border-radius: 50%;
  position: absolute;
  top: 2px;
  left: 2px;
  transition: transform var(--transition-base) ease;
  box-shadow: 0 2px 6px rgba(0,0,0,.25);
}

.toggle input:checked + .slider {
  background: var(--teal-500);
}

.toggle input:checked + .slider::before {
  transform: translateX(20px);
}


.smart-ai-row,
.ted-row {
  display: grid;
  grid-template-rows: 40px auto;
  align-items: start;
}

.smart-ai-row .toggle,
.ted-row .toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs-plus);

  height: 40px;
}

.smart-ai-note,
.ted-note {
  margin-top: var(--space-2xs-plus);
  font-size: .75rem;
  line-height: 1.4;
}

/* ======================================================
   STATUS BADGES
   ====================================================== */
.status-badge {
  display: inline-block;
  min-width: 120px;
  padding: 5px var(--space-xs-plus);
  border-radius: 999px;
  font-size: .72rem;
  font-weight: var(--font-weight-bold);
  color: #ffffff;
  text-align: center;
}

.status-opublikowane {
  background: rgba(15,76,117,.1);
  color: #0f4c75;
}

.status-w-trakcie-skladania-ofert {
  background: rgba(14,165,164,.15);
  color: var(--teal-600);
}

.status-zmienione {
  background: rgba(255,170,0,.15);
  color: #b26a00;
}

.status-rozstrzygnięte {
  background: rgba(80,200,120,.15);
  color: #2e7d32;
}

.status-zrealizowane {
  background: rgba(100,100,100,.12);
  color: #444;
}

.status-oferty-zamkniete {
  background: rgba(220, 38, 38, 0.1);
  color: #b91c1c;
}

.status-cancelled {
  background: rgba(220, 38, 38, 0.1);
  color: #b91c1c;
}

/* ======================================================
   SORTABLE TABLE HEADERS (GLOBAL)
   ====================================================== */
/* kolumny sortowalne */
th[data-sort] {
  cursor: pointer;
  position: relative;
  padding-right: var(--space-lg-plus);
  user-select: none;
}

/* neutralna ikona */
th[data-sort]::after {
  content: "↕";
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.7rem;
  font-weight: var(--font-weight-bold);
  color: var(--procuro-muted);
  opacity: 0.5;
}

/* sort ASC */
th[data-sort].sorted-asc::after {
  content: "↑";
  color: var(--teal-500);
  opacity: 1;
}

/* sort DESC */
th[data-sort].sorted-desc::after {
  content: "↓";
  color: var(--teal-500);
  opacity: 1;
}

/* hover feedback */
th[data-sort]:hover::after {
  opacity: 0.9;
}

/* ======================================================
   LINK ŹRÓDŁA
   ====================================================== */
.source-link {
  font-weight: var(--font-weight-medium);
  color: var(--teal-600);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ======================================================
   IFRAME NOTICE HTML
   ====================================================== */
.notice-html-frame {
  width: 100%;
  height: 520px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #f1f5f9;
}

/* ======================================================
   NOTICE SECTIONS
   ====================================================== */
.notice-section {
  margin-top: var(--space-lg);
  padding: var(--space-md) var(--space-md-plus);
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.notice-section p {
  font-size: .85rem;
  color: var(--navy-800);
  line-height: 1.55;
}

.notice-section .label {
  font-weight: var(--font-weight-bold);
  color: var(--navy-700);
}

.notice-section h3 {
  margin: 0 0 var(--space-xs-plus);
  font-size: .95rem;
  font-weight: var(--font-weight-extrabold);
  color: var(--navy-800);
  border-left: 4px solid var(--teal-500);
  padding-left: var(--space-xs-plus);
}

.notice-section ul {
  margin: var(--space-xs) 0 0 var(--space-md-plus);
  padding: 0;
}

.notice-section li {
  font-size: .85rem;
  margin-bottom: var(--space-2xs);
}

/* .premium-badge — przeniesiony do procuro-tokens.css */

/* ======================================================
   NAV PRO BADGE (header — widoczne tylko dla PRO)
   ====================================================== */
.nav-pro-badge {
  display: inline-block;
  padding: var(--space-3xs) 7px;
  border-radius: 999px;
  background: linear-gradient(90deg, #1fb6ff, #3ddc97);
  color: #fff;
  font-size: 0.63rem;
  font-weight: var(--font-weight-extrabold);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-left: var(--space-xs);
  vertical-align: middle;
  position: relative;
  top: -1px;
}

/* ======================================================
   FOLLOW / UNFOLLOW BUTTONS
   ====================================================== */
.follow-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2xs-plus);
  padding: var(--space-2xs-plus) var(--space-xs-plus);
  font-size: .7rem;
  font-weight: var(--font-weight-bold);
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid var(--border);
  background: #ffffff;
  color: var(--navy-800);
  transition: all var(--transition-fast) ease;
}

.follow-btn:hover {
  background: #f1fbf9;
  border-color: var(--teal-500);
}

.follow-btn.following {
  background: var(--teal-500);
  color: #ffffff;
  border-color: var(--teal-500);
}

.follow-btn.following:hover {
  background: var(--teal-600);
}

/* ======================================================
   GLOBAL LOADER / SPINNER
   ====================================================== */
.procuro-loader {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs-plus);

  font-size: .85rem;
  font-weight: var(--font-weight-semibold);
  color: var(--procuro-muted);
}

/* spinner */
.procuro-loader .spinner {
  width: 20px;
  height: 20px;
  border-radius: 50%;

  background:
    conic-gradient(
      from 0deg,
      var(--teal-500),
      var(--teal-600),
      var(--teal-500)
    );

  -webkit-mask: radial-gradient(
    farthest-side,
    transparent 62%,
    #000 63%
  );
  mask: radial-gradient(
    farthest-side,
    transparent 62%,
    #000 63%
  );

  box-shadow:
  0 0 6px rgba(20, 184, 166, 0.35);

  animation: procuro-spin .9s linear infinite;
}

@keyframes procuro-spin {
  to { transform: rotate(360deg); }
}

/* ======================================================
   GLOBAL FOOTER SPACING + SCROLLBAR SPACE
   ====================================================== */

main {
  padding-bottom: var(--space-xl);
}

footer {
  margin-top: var(--space-xl);
}

html {
  scrollbar-gutter: stable;
}

/* ======================================================
   HAMBURGER BUTTON (mobile only)
   ====================================================== */
.nav-hamburger {
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 10px;
  background: rgba(255,255,255,0.08);
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: background var(--transition-fast);
}

.nav-hamburger:hover {
  background: rgba(255,255,255,0.14);
}

.nav-hamburger-bar {
  display: block;
  width: 18px;
  height: 2px;
  background: #ffffff;
  border-radius: 2px;
  transition: transform 0.22s ease, opacity var(--transition-fast) ease;
}

.nav-hamburger.is-open .nav-hamburger-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-hamburger.is-open .nav-hamburger-bar:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.nav-hamburger.is-open .nav-hamburger-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ======================================================
   MOBILE NAV DRAWER
   ====================================================== */
.mobile-nav-drawer {
  position: fixed;
  inset: 0;
  z-index: 98;
  background: linear-gradient(180deg, #0b1c2d 0%, #0f2438 100%);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;

  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity var(--transition-base) ease, transform 0.22s ease;
}

.mobile-nav-drawer.is-open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.mobile-nav-spacer {
  height: 88px;
  flex-shrink: 0;
  transition: height var(--transition-slow) ease;
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: var(--space-3xs);
  padding: var(--space-sm) var(--space-md) var(--space-4xl);
}

.mobile-nav-links a,
.mobile-nav-logout {
  display: flex;
  align-items: center;
  gap: var(--space-xs-plus);
  padding: var(--space-sm-plus) var(--space-md);
  border-radius: 12px;
  color: rgba(255,255,255,0.82);
  text-decoration: none;
  font-size: 1rem;
  font-weight: var(--font-weight-semibold);
  font-family: 'Poppins', sans-serif;
  background: transparent;
  border: none;
  cursor: pointer;
  width: 100%;
  text-align: left;
  transition: background var(--transition-fast), color var(--transition-fast);
  -webkit-tap-highlight-color: transparent;
}

.mobile-nav-links a:hover,
.mobile-nav-links a.active,
.mobile-nav-logout:hover {
  background: rgba(255,255,255,0.07);
  color: #ffffff;
}

.mobile-nav-links a.active {
  color: #ffffff;
}

.mobile-nav-divider {
  height: 1px;
  background: rgba(255,255,255,0.08);
  margin: var(--space-xs) 0;
}

.mobile-nav-logout {
  color: rgba(255,110,110,0.9);
}

.mobile-nav-logout:hover {
  background: rgba(239,68,68,0.1) !important;
  color: #fca5a5 !important;
}

/* ── Responsive ── */
@media (max-width: 900px) {
  .search-actions-row {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
  }
}

/* Collapse desktop nav to hamburger */
@media (max-width: 840px) {
  .main-nav .nav-left,
  .main-nav .nav-right {
    display: none;
  }

  .nav-hamburger {
    display: flex;
  }
}

@media (max-width: 700px) {
  .container {
    padding-inline: var(--space-md);
  }

  .main-container {
    padding-top: var(--space-lg);
  }

  .search-bar {
    padding: var(--space-md);
  }

  .search-actions-row {
    grid-template-columns: 1fr;
    gap: var(--space-sm);
  }

  .search-actions-row .procuro-btn {
    margin-top: 0;
    width: 100%;
  }

  .tabs-container {
    margin: var(--space-lg) 0 var(--space-md);
    gap: var(--space-xs);
    flex-direction: column;
  }

  .tab-button {
    flex: 1 1 auto;
    width: 100%;
    justify-content: center;
  }

  .tab-button[data-tab="results"],
  .tab-button[data-tab="archive"] {
    flex: 1 1 auto;
  }

  .footer-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-nav {
    gap: var(--space-sm);
  }
}

@media (max-width: 480px) {
  .search-bar {
    padding: var(--space-sm-plus) var(--space-sm);
  }

  .pagination {
    gap: var(--space-2xs-plus);
    flex-wrap: wrap;
  }

  .pagination button {
    min-width: 44px;
    min-height: 44px;
    padding: 0 var(--space-xs-plus);
    font-size: 0.88rem;
  }

  .procuro-btn {
    min-height: 44px;
  }
}


/* ======================================================
   NOTIFICATION BELL (nav)
   ====================================================== */
.notif-bell {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255,255,255,0.92);
  border: 1px solid rgba(255,255,255,0.25);
  backdrop-filter: blur(6px);
  transition: background var(--transition-fast), box-shadow var(--transition-fast);
  text-decoration: none;
}

.notif-bell:hover {
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(0,0,0,.18);
}

.notif-bell-icon {
  width: 18px;
  height: 18px;
  opacity: .8;
}

.notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  padding: 0 var(--space-2xs);
  border-radius: 8px;
  background: #ef4444;
  color: #fff;
  font-size: 0.65rem;
  font-weight: var(--font-weight-bold);
  line-height: 16px;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0,0,0,.2);
}


/* ======================================================
   NOTIFICATION INBOX SECTION
   ====================================================== */
.notif-inbox-section {
  padding: var(--space-lg) 0 0;
}

.notif-inbox-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-sm);
}

.notif-inbox-title {
  font-size: 1.1rem;
  font-weight: var(--font-weight-bold);
  color: var(--navy-900);
  margin: 0;
}


/* ======================================================
   NOTIFICATION LIST
   ====================================================== */
.notif-list {
  background: #ffffff;
  border: 1px solid var(--procuro-border);
  border-radius: 12px;
  overflow: hidden;
}

.notif-item {
  display: grid;
  grid-template-columns: 10px 1fr auto;
  align-items: center;
  gap: var(--space-sm-plus);
  padding: var(--space-sm) var(--space-md);
  border-bottom: 1px solid var(--procuro-border);
  transition: background .12s;
}

.notif-item:last-child {
  border-bottom: none;
}

.notif-item--unread {
  background: #f0f9ff;
}

.notif-item:hover {
  background: #f8fafc;
}


/* Dot indicator */
.notif-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #f59e0b;
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(245,158,11,.18);
}

.notif-dot--deadline {
  background: #f59e0b;
  box-shadow: 0 0 0 3px rgba(245,158,11,.18);
}

.notif-dot--update {
  background: var(--teal-500, #0ea5a4);
  box-shadow: 0 0 0 3px rgba(14,165,164,.18);
}

.notif-dot--result {
  background: #6366f1;
  box-shadow: 0 0 0 3px rgba(99,102,241,.18);
}


/* Body */
.notif-body {
  min-width: 0;
}

.notif-title {
  font-size: 0.875rem;
  font-weight: var(--font-weight-semibold);
  color: var(--navy-900);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notif-meta {
  font-size: 0.78rem;
  color: var(--procuro-muted);
  margin-top: var(--space-3xs);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notif-meta-sep {
  margin: 0 var(--space-2xs);
  opacity: .5;
}

.notif-time {
  color: var(--procuro-muted);
}

.notif-deadline {
  color: #dc2626;
  font-weight: var(--font-weight-semibold);
}


/* Type badge */
.notif-type-badge {
  flex-shrink: 0;
  padding: 3px var(--space-xs-plus);
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: var(--font-weight-semibold);
  white-space: nowrap;
  background: #fef3c7;
  color: #92400e;
  border: 1px solid #fde68a;
}

.notif-type-badge--deadline {
  background: #fef3c7;
  color: #92400e;
  border-color: #fde68a;
}

.notif-type-badge--update {
  background: #e0f7f6;
  color: #0e7490;
  border-color: #99e6e4;
}

.notif-type-badge--result {
  background: #eef2ff;
  color: #4338ca;
  border-color: #c7d2fe;
}


/* Empty state */
.notif-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--space-2xl) var(--space-md);
  color: var(--procuro-muted);
}

.notif-empty-icon {
  font-size: 1.6rem;
  margin-bottom: var(--space-xs);
  opacity: .5;
}

.notif-empty-text {
  font-size: 0.9rem;
  margin: 0;
}


/* Responsive */
@media (max-width: 700px) {
  .notif-item {
    grid-template-columns: 8px 1fr;
    gap: var(--space-xs-plus);
  }

  .notif-type-badge {
    display: none;
  }
}

/* ======================================================
   AI CARD ICON  (moved from procuro-tokens.css)
   ====================================================== */
.ai-card__icon {
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px;
  border-radius: var(--radius-md);
  background: var(--procuro-gradient);
  color: var(--bg-white);
  flex-shrink: 0;
}

.ai-card__icon--sm {
  width: 22px;
  height: 22px;
  border-radius: var(--radius-sm, 6px);
}

.toggle-label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2xs-plus);
}

/* ======================================================
   PREMIUM BADGE  (moved from procuro-tokens.css)
   ====================================================== */
.premium-badge {
  display: inline-block;
  padding: 1px var(--space-2xs-plus);
  border-radius: 4px;
  background: linear-gradient(130deg, #1fb6ff, #3ddc97);
  color: var(--bg-white);
  font-size: 0.65rem;
  font-weight: var(--font-weight-bold);
  letter-spacing: 0.04em;
  vertical-align: middle;
}

/* ======================================================
   PAGE HEADER  (moved from procuro-tokens.css)
   ====================================================== */
.profile-page-header { margin: var(--space-xs-plus) 0 var(--space-lg-plus); }

.profile-page-title-row {
  display: flex;
  align-items: center;
  gap: var(--space-xs-plus);
}

.profile-page-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: var(--font-weight-extrabold);
  color: var(--navy-900);
  letter-spacing: -0.01em;
}

.profile-page-subtitle {
  margin: var(--space-2xs-plus) 0 0;
  font-size: .9rem;
  color: var(--muted);
}

/* ======================================================
   BUTTON SYSTEM — .procuro-btn  (moved from procuro-tokens.css)
   ====================================================== */
.procuro-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding: 0 var(--space-lg-plus);
  font-family: 'Poppins', sans-serif;
  font-size: 0.95rem;
  font-weight: var(--font-weight-semibold);
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform var(--transition-fast) ease,
    box-shadow var(--transition-base) ease,
    background var(--transition-base) ease,
    color var(--transition-base) ease;
}

.procuro-btn.primary {
  background: var(--procuro-gradient);
  color: var(--bg-white);
  box-shadow: 0 6px 20px rgba(14,165,164,0.35);
}
.procuro-btn.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 28px rgba(14,165,164,0.45);
}

.procuro-btn.secondary {
  background: var(--bg-white);
  color: var(--navy-800);
  border: 1px solid var(--border);
}
.procuro-btn.secondary:hover {
  background: var(--bg-soft);
}

.procuro-btn.ghost {
  background: transparent;
  color: rgba(255,255,255,0.85);
  height: auto;
  padding: var(--space-2xs-plus) var(--space-xs);
}
.procuro-btn.ghost:hover {
  color: var(--bg-white);
}

.procuro-btn.outline {
  background: transparent;
  color: var(--bg-white);
  border: 2px solid rgba(255,255,255,0.55);
}
.procuro-btn.outline:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.85);
}

.procuro-btn.cta-outline {
  background: transparent;
  color: rgba(255,255,255,0.75);
  border: 2px solid rgba(255,255,255,0.2);
}
.procuro-btn.cta-outline:hover {
  background: rgba(255,255,255,0.07);
  color: var(--bg-white);
  border-color: rgba(255,255,255,0.45);
}

.procuro-btn.sm {
  height: 32px;
  padding: 0 var(--space-sm);
  font-size: 0.8rem;
}
.procuro-btn.lg {
  height: 56px;
  font-size: 1rem;
}

/* ======================================================
   SMALL BUTTON VARIANTS  (moved from procuro-tokens.css)
   ====================================================== */
.button-small {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  padding: 0 var(--space-sm-plus);
  font-size: 0.75rem;
  font-weight: var(--font-weight-semibold);
  line-height: 1;
  border-radius: 10px;
  cursor: pointer;
  border: none;
  text-decoration: none;
  white-space: nowrap;
  transition: background var(--transition-base) ease,
    color var(--transition-base) ease,
    box-shadow var(--transition-base) ease;
}

.button-follow {
  background: var(--teal-500);
  color: var(--bg-white);
  box-shadow: 0 4px 12px rgba(14,165,164,.35);
}
.button-follow:hover { background: var(--teal-600); }

.button-unfollow {
  background: #64748b;
  color: var(--bg-white);
}
.button-unfollow:hover { background: #475569; }

.button-outline {
  background: var(--bg-white);
  color: var(--navy-800);
  border: 1px solid var(--border);
}
.button-outline:hover { background: var(--bg-soft); }

/* ======================================================
   UTILITY — ukrywanie elementów
   Zastępuje inline style="display:none" (wymóg CSP: usunięcie
   'unsafe-inline' ze style-src). Przełączane w JS przez
   classList.add/remove/toggle("is-hidden").
   ====================================================== */
.is-hidden { display: none !important; }

