/* static/style.css - Główny plik stylów w pełni responsywny */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
  /* Kolory - ciemny motyw */
  --bg-deep: #0b0e12;
  --bg-surface: #141a1f;
  --bg-card: #1e262e;
  --bg-elevated: #2a343e;
  --bg-hover: #323e4a;
  
  /* Akcenty */
  --accent-orange: #ff7a3d;
  --accent-teal: #2dd4bf;
  --accent-blue: #3b82f6;
  --accent-purple: #a855f7;
  --accent-yellow: #eab308;
  --accent-red: #ef4444;
  
  /* Tekst */
  --text-primary: #f3f5f7;
  --text-secondary: #cbd5e1;
  --text-tertiary: #94a3b8;
  --text-muted: #64748b;
  
  /* Granice */
  --border-subtle: #2a343e;
  --border-strong: #3f4a55;
  
  /* Wymiary - responsywne */
  --header-h: clamp(60px, 10vw, 72px);
  --footer-h: clamp(60px, 10vw, 72px);
  
  /* Rozmiary - responsywne */
  --radius-xs: clamp(4px, 1vw, 6px);
  --radius-sm: clamp(6px, 1.5vw, 8px);
  --radius-md: clamp(8px, 2vw, 12px);
  --radius-lg: clamp(12px, 2.5vw, 16px);
  --radius-xl: clamp(16px, 3vw, 20px);
  --radius-2xl: clamp(20px, 4vw, 28px);
  
  /* Cienie - bez animacji */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.6);
}

/* =====================================================================
   JASNY MOTYW — nadpisuje zmienne z :root gdy data-theme="light"
   ===================================================================== */
[data-theme="light"] {
  --bg-deep:     #e8ecf1;
  --bg-surface:  #ffffff;
  --bg-card:     #f4f6f9;
  --bg-elevated: #e2e7ee;
  --bg-hover:    #d5dbe5;

  --text-primary:   #0f172a;
  --text-secondary: #1e293b;
  --text-tertiary:  #475569;
  --text-muted:     #94a3b8;

  --border-subtle: #dde2ea;
  --border-strong: #c8d0db;

  --shadow-xs: 0 1px 2px rgba(0,0,0,0.06);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.10);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.13);
}

/* Header — nadpisanie hardkodowanego rgba */
[data-theme="light"] .header {
  background: rgba(255,255,255,0.97) !important;
}

/* Footer — nadpisanie hardkodowanego rgba */
[data-theme="light"] .footer-nav {
  background: rgba(255,255,255,0.98) !important;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.07);
}

/* Inputy i selecty */
[data-theme="light"] .search-input,
[data-theme="light"] .sort-select {
  color: var(--text-primary);
  background-color: var(--bg-card);
}

[data-theme="light"] .search-input::placeholder {
  color: var(--text-muted);
}

[data-theme="light"] .sort-select option {
  background: var(--bg-card);
  color: var(--text-primary);
}

/* Tabela */
[data-theme="light"] .resource-table tr:hover td {
  background: var(--bg-elevated);
}


/* Scrollbar */
[data-theme="light"] ::-webkit-scrollbar-track {
  background: var(--bg-elevated);
}

/* =====================================================================
   Przycisk przełącznika motywu
   ===================================================================== */
.theme-toggle-btn {
  border: none;
  background: transparent;
  font-family: inherit;
  cursor: pointer;
  padding: 0;
  margin-left: clamp(2px, 1vw, 4px);
}

.theme-toggle-btn:hover {
  color: var(--accent-orange) !important;
  background: var(--bg-elevated) !important;
}

/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Reset linków */
a, a:hover, a:focus, a:active {
  text-decoration: none !important;
  outline: none;
  color: var(--text-primary);
}

body {
  font-family: 'Outfit', sans-serif;
  background: var(--bg-deep);
  color: var(--text-primary);
  font-size: clamp(13px, 2vw, 14px);
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Layout */
.app-shell {
  flex-direction: column;
  min-height: 100vh;
  width: 100%;
  overflow-x: hidden;
  position: relative;
}

.page-body {
  flex: 1;
  padding: 2px;
  max-width: min(1400px, 100% - 32px);
  margin: 0 auto;
  width: 100%;
  min-height: auto;
  flex-direction: column;
}

/* Header */
.header {
  height: var(--header-h);
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(12px, 4vw, 32px);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
  background: rgba(20, 26, 31, 0.95);
  width: 100%;
}


.header-icons {
  display: flex;
  align-items: center;
  gap: clamp(2px, 1vw, 6px);
  flex-wrap: wrap;
  justify-content: flex-end;
}

.icon-btn {
  width: clamp(36px, 8vw, 42px);
  height: clamp(36px, 8vw, 42px);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  background: transparent;
  color: var(--accent-teal);
  cursor: pointer;
  flex-shrink: 0;
}

.icon-btn:hover {
  background: var(--bg-elevated);
  color: var(--accent-orange);
}

.icon-btn i {
  font-size: clamp(16px, 4vw, 20px);
}

/* License bar */
.license-bar {
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  padding: clamp(8px, 2vw, 10px) clamp(12px, 4vw, 32px);
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: clamp(6px, 2vw, 10px);
  font-size: clamp(11px, 2.5vw, 13px);
  font-weight: 500;
  flex-wrap: wrap;
  text-align: right;
}

.license-bar.active {
  color: var(--accent-teal);
}

.license-bar.expired {
  color: var(--accent-red);
}

.license-bar a {
  color: var(--accent-blue);
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 3px;
}


/* Breadcrumb */
.breadcrumb {
  padding: clamp(12px, 3vw, 16px) clamp(12px, 4vw, 32px);
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: clamp(12px, 2.5vw, 14px);
  flex-wrap: wrap;
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}


.breadcrumb-left {
  display: flex;
  align-items: center;
  gap: clamp(6px, 2vw, 10px);
  flex-wrap: wrap;
}

.user-area {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: auto;
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: clamp(12px, 2.5vw, 13px);
  color: var(--text-secondary);
  background: var(--bg-elevated);
  padding: 6px 14px;
  border-radius: 40px;
  border: 1px solid var(--border-subtle);
}

.user-badge i {
  font-size: 16px;
  color: var(--accent-teal);
}

.user-badge strong {
  color: var(--text-primary);
  font-weight: 600;
}

.user-area .fa-bell {
  font-size: 18px;
  color: var(--text-tertiary);
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
}

.user-area .fa-bell:hover {
  color: var(--accent-orange);
  background: var(--bg-elevated);
}

@media (max-width: 600px) {
  .breadcrumb {
    flex-direction: column;
    align-items: stretch;
  }
  .user-area {
    margin-left: 0;
    justify-content: flex-start;
  }
  .user-badge {
    flex: 1;
    justify-content: center;
  }
}

/* Page header */
.page-header {

}

.page-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
}

.page-title i {
  font-size: 12px;
  color: var(--accent-orange);
  background: var(--bg-elevated);
  padding: 10px;
  border-radius: var(--radius-lg);
  margin: 5px;
  
}


.page-title i {
  background: var(--bg-elevated);
  color: var(--accent-orange);
}


.page-subtitle {
  color: var(--text-tertiary);
  font-size: clamp(13px, 3vw, 15px);
  margin-left: clamp(0px, 2vw, 54px);
}

/* Controls bar */
.controls-bar {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: clamp(12px, 3vw, 24px);
  margin-bottom: clamp(16px, 4vw, 32px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(12px, 3vw, 20px);
  flex-wrap: wrap;
}

.search-wrap {
  display: flex;
  align-items: center;
  gap: clamp(8px, 2vw, 12px);
  flex: 1 1 min(280px, 100%);
  min-width: min(280px, 100%);
}

.search-label {
  display: flex;
  align-items: center;
  gap: clamp(4px, 1.5vw, 8px);
  color: var(--text-secondary);
  font-weight: 500;
  background: var(--bg-card);
  padding: clamp(6px, 2vw, 8px) clamp(12px, 3vw, 16px);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-subtle);
  white-space: nowrap;
}

.search-label i {
  color: var(--accent-teal);
  font-size: clamp(12px, 2.5vw, 14px);
}

.search-input {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  color: var(--text-primary);
  padding: clamp(10px, 2.5vw, 12px) clamp(16px, 3vw, 20px);
  font-size: clamp(13px, 2.5vw, 14px);
  min-width: 200px;
  width: 100%;
}

.search-input:focus {
  outline: none;
  border-color: var(--accent-orange);
  box-shadow: 0 0 0 3px rgba(255, 122, 61, 0.15);
}

.sort-select {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  color: var(--text-primary);
  padding: clamp(10px, 2.5vw, 12px) clamp(40px, 8vw, 44px) clamp(10px, 2.5vw, 12px) clamp(16px, 3vw, 20px);
  font-size: clamp(13px, 2.5vw, 14px);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right clamp(12px, 3vw, 16px) center;
  min-width: min(160px, 100%);
  width: auto;
  flex: 0 1 auto;
}

.sort-select:focus {
  outline: none;
  border-color: var(--accent-orange);
}

/* Cards grid */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr));
  gap: clamp(16px, 4vw, 24px);
  margin: clamp(16px, 4vw, 24px) 0;
}

/* Navigation card */
.nav-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: hidden;
  display: block;
  height: 100%;
  min-height: 180px;
  display: flex;
  flex-direction: column;
}

.nav-card:hover {
  border-color: var(--accent-orange);
  box-shadow: var(--shadow-lg);
}

.nav-card-preview {
  height: clamp(100px, 25vw, 140px);
  background: linear-gradient(145deg, var(--bg-elevated), var(--bg-card));
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  border-bottom: 1px solid var(--border-subtle);
}

.nav-card-preview i {
  font-size: clamp(40px, 10vw, 56px);
  color: var(--accent-orange);
  opacity: 0.7;
  z-index: 1;
}

.nav-card:hover .nav-card-preview i {
  opacity: 1;
  color: var(--accent-teal);
}

.nav-card-content {
  padding: clamp(16px, 4vw, 20px);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.nav-card-title {
  font-size: clamp(16px, 4vw, 18px);
  font-weight: 600;
  margin-bottom: clamp(4px, 2vw, 6px);
  color: var(--text-primary);
}

.nav-card-subtitle {
  font-size: clamp(12px, 3vw, 13px);
  color: var(--text-tertiary);
  display: flex;
  align-items: center;
  gap: clamp(4px, 1.5vw, 8px);
  flex-wrap: wrap;
  margin-top: auto;
}

.nav-card-subtitle i {
  color: var(--accent-teal);
  font-size: clamp(10px, 2.5vw, 12px);
}

/* Branch card */
.branch-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: hidden;
  display: block;
  height: 100%;
}

.branch-card:hover {
  border-color: var(--accent-teal);
  box-shadow: var(--shadow-lg);
}

.branch-card-preview {
  height: clamp(80px, 20vw, 120px);
  background: linear-gradient(145deg, var(--bg-elevated), var(--bg-card));
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border-subtle);
}

.branch-card-preview i {
  font-size: clamp(36px, 9vw, 48px);
  color: var(--accent-teal);
  opacity: 0.5;
}

.branch-card:hover .branch-card-preview i {
  opacity: 1;
}

.branch-card-content {
  padding: clamp(12px, 3vw, 16px);
}

.branch-card-title {
  font-size: clamp(14px, 3.5vw, 16px);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: clamp(8px, 2vw, 12px);
}

.branch-card-stats {
  display: flex;
  justify-content: space-between;
  padding-top: clamp(8px, 2vw, 12px);
  border-top: 1px solid var(--border-subtle);
  font-size: clamp(12px, 3vw, 13px);
  flex-wrap: wrap;
  gap: 8px;
}

.branch-card-stats span {
  display: flex;
  align-items: center;
  gap: clamp(4px, 1.5vw, 6px);
  color: var(--text-tertiary);
}

.branch-card-stats i {
  color: var(--accent-teal);
}

/* Project card */
.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: clamp(16px, 4vw, 24px);
  display: flex;
  flex-direction: column;
  min-height: 140px;
  height: 100%;
  position: relative;
}

.project-card:hover {
  border-color: var(--accent-orange);
  box-shadow: var(--shadow-lg);
}

.project-card-add {
  background: linear-gradient(135deg, var(--accent-orange), #ff9f6e);
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.project-card-add i {
  font-size: clamp(28px, 7vw, 36px);
  color: white;
}

.project-card-add span {
  font-size: clamp(12px, 3vw, 14px);
  font-weight: 600;
  color: white;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-align: center;
}

.project-card-name {
  font-size: clamp(16px, 4vw, 18px);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: clamp(6px, 2vw, 8px);
  line-height: 1.3;
  padding-right: 30px;
}

.project-card-meta {
  position: absolute;
  bottom: clamp(16px, 4vw, 20px);
  left: clamp(16px, 4vw, 20px);
  right: clamp(16px, 4vw, 20px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: clamp(12px, 3vw, 13px);
  flex-wrap: wrap;
  gap: 8px;
}

.project-card-time {
  color: var(--accent-teal);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
}

.project-card-status {
  width: clamp(24px, 6vw, 28px);
  height: clamp(24px, 6vw, 28px);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-deep);
  border-radius: 50%;
  color: var(--accent-orange);
  font-weight: 700;
}

/* Welcome section */
.welcome-section {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: clamp(16px, 2.5vw, 24px);
  justify-content: center;
  align-items: flex-start;
  margin: 0 auto;
  padding: clamp(50px, 4vh, 40px);
}

.welcome-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: clamp(20px, 3vw, 28px) clamp(16px, 3vw, 24px);
  text-align: center;
  flex: 1 1 min(240px, 100%);
  max-width: min(260px, 100%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 260px;
  height: auto;
  margin-bottom: 0;
}

.welcome-card:hover {
  border-color: var(--accent-orange);
  box-shadow: var(--shadow-sm);
}

.welcome-icon {
  width: clamp(50px, 10vw, 64px);
  height: clamp(50px, 10vw, 64px);
  background: linear-gradient(135deg, var(--accent-orange), var(--accent-teal));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto clamp(12px, 2vw, 16px);
  flex-shrink: 0;
}

.welcome-icon i {
  font-size: clamp(24px, 5vw, 32px);
  color: white;
}

.welcome-card h2 {
  font-size: clamp(16px, 3.5vw, 20px);
  margin-bottom: clamp(6px, 1.5vw, 10px);
  color: var(--text-primary);
  font-weight: 600;
  flex-shrink: 0;
}

.welcome-card p {
  color: var(--text-tertiary);
  margin-bottom: clamp(12px, 3vw, 20px);
  font-size: clamp(15px, 2.5vw, 16px);
  line-height: 1.4;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.welcome-card .btn {
  margin-top: auto;
  align-self: center;
  width: 100%;
  max-width: 160px;
  flex-shrink: 0;
  margin-bottom: 0;
  padding: clamp(8px, 2vw, 10px) clamp(12px, 3vw, 20px);
  font-size: clamp(15px, 2.5vw, 16px);
}

/* Resource table */
.table-container {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow-x: auto;
  margin: clamp(16px, 4vw, 24px) 0;
  -webkit-overflow-scrolling: touch;
  width: 100%;
}

.table-container:last-child {
  margin-bottom: 40px;
}

.resource-table {
  width: 100%;
  border-collapse: collapse;
  min-width: min(600px, 100%);
}

.resource-table th {
  padding: clamp(12px, 3vw, 18px) clamp(12px, 3vw, 20px);
  text-align: left;
  font-size: clamp(12px, 2.5vw, 13px);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-tertiary);
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  white-space: nowrap;
}

.resource-table td {
  padding: clamp(12px, 3vw, 16px) clamp(12px, 3vw, 20px);
  border-bottom: 1px solid var(--border-subtle);
}

.resource-table tbody tr:last-child td {
  border-bottom: none;
}

.resource-table tbody tr:hover td {
  background: var(--bg-elevated);
}

.col-thumb {
  width: clamp(50px, 10vw, 70px);
}

.media-icon {
  width: clamp(40px, 8vw, 48px);
  height: clamp(40px, 8vw, 48px);
  background: linear-gradient(135deg, var(--accent-orange), var(--accent-teal));
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.9;
  box-shadow: var(--shadow-sm);
}

.media-icon i {
  font-size: clamp(18px, 4vw, 22px);
  color: white;
}

.col-title .res-name {
  font-size: clamp(14px, 3.5vw, 16px);
  font-weight: 600;
  color: var(--text-primary);
  display: block;
  margin-bottom: clamp(4px, 1.5vw, 6px);
  word-break: break-word;
}

.col-title .res-name:hover {
  color: var(--accent-orange);
}

.res-tags {
  display: flex;
  gap: clamp(8px, 3vw, 16px);
  font-size: clamp(12px, 2.5vw, 13px);
  flex-wrap: wrap;
}

.res-tags span {
  display: flex;
  align-items: center;
  gap: clamp(4px, 1.5vw, 6px);
  padding: 2px 0;
}

.res-tags i {
  font-size: clamp(10px, 2.5vw, 12px);
}

.tag-category {
  color: var(--accent-teal);
  font-weight: 500;
}

.tag-detail {
  color: var(--text-tertiary);
}

.col-actions {
  text-align: right;
  white-space: nowrap;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: clamp(32px, 7vw, 38px);
  height: clamp(32px, 7vw, 38px);
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  margin-left: clamp(2px, 1.5vw, 6px);
  color: var(--text-tertiary);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
}

.action-btn:hover {
  background: var(--accent-orange);
  color: white;
  border-color: var(--accent-orange);
}

.action-btn i {
  font-size: clamp(14px, 3.5vw, 16px);
}

/* Detail page */
.detail-container {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: hidden;
  margin: clamp(16px, 4vw, 24px) 0 40px 0;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: clamp(16px, 4vw, 32px);
  padding: clamp(16px, 4vw, 32px);
}

.detail-cover {
  background: linear-gradient(145deg, var(--bg-elevated), var(--bg-card));
  border-radius: var(--radius-xl);
  padding: clamp(20px, 5vw, 40px) clamp(12px, 3vw, 20px);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-subtle);
  min-height: clamp(200px, 50vw, 300px);
}

.detail-cover i {
  font-size: clamp(60px, 15vw, 120px);
  color: var(--accent-teal);
  opacity: 0.8;
}

.detail-title {
  font-size: clamp(22px, 6vw, 32px);
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--text-primary);
  margin-bottom: clamp(12px, 3vw, 20px);
  word-break: break-word;
}

.detail-meta {
  display: flex;
  gap: clamp(8px, 2vw, 12px);
  margin-bottom: clamp(16px, 4vw, 28px);
  flex-wrap: wrap;
}

.meta-item {
  padding: clamp(6px, 2vw, 8px) clamp(12px, 3vw, 20px);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 40px;
  font-size: clamp(13px, 3vw, 14px);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: clamp(4px, 1.5vw, 8px);
  color: var(--text-secondary);
  white-space: nowrap;
}

.meta-item i {
  font-size: clamp(12px, 2.5vw, 14px);
}

.meta-item.category i { color: var(--accent-teal); }
.meta-item.time i { color: var(--accent-blue); }
.meta-item.size i { color: var(--accent-purple); }

.detail-actions {
  display: flex;
  gap: clamp(8px, 2vw, 12px);
  margin-bottom: clamp(16px, 4vw, 32px);
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: clamp(6px, 2vw, 10px);
  padding: clamp(10px, 2.5vw, 14px) clamp(16px, 4vw, 28px);
  border-radius: var(--radius-xl);
  font-weight: 600;
  font-size: clamp(13px, 3vw, 15px);
  cursor: pointer;
  border: none;
  min-width: clamp(100px, 25vw, 140px);
  flex: 0 1 auto;
}

.btn i {
  font-size: clamp(14px, 3.5vw, 18px);
}

.btn-primary {
  background: var(--accent-orange);
  color: white;
}

.btn-secondary {
  background: var(--bg-surface);
  color: var(--text-secondary);
  border: 1px solid var(--border-strong);
}

.btn-secondary:hover {
  background: var(--bg-elevated);
  color: var(--accent-orange);
}

.detail-section {
  margin-bottom: clamp(16px, 4vw, 28px);
}

.detail-section h4 {
  font-size: clamp(14px, 3.5vw, 16px);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--accent-teal);
  margin-bottom: clamp(12px, 3vw, 16px);
  display: flex;
  align-items: center;
  gap: clamp(6px, 2vw, 8px);
  flex-wrap: wrap;
}

.detail-section h4 i {
  font-size: clamp(14px, 3.5vw, 18px);
}

.detail-section ul {
  list-style: none;
}

.detail-section ul li {
  padding: clamp(6px, 2vw, 10px) 0;
  padding-left: clamp(16px, 4vw, 24px);
  position: relative;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-subtle);
  word-break: break-word;
}

.detail-section ul li:last-child {
  border-bottom: none;
}

.detail-section ul li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent-orange);
  font-weight: 600;
}

.detail-section p {
  color: var(--text-secondary);
  line-height: 1.8;
  word-break: break-word;
}

/* Sala section */
.sala-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: clamp(16px, 4vw, 32px);
  margin: clamp(16px, 4vw, 24px) 0 40px 0;
}

.sala-info-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: clamp(16px, 4vw, 28px);
  height: 100%;
}

.sala-info-title {
  font-size: clamp(18px, 5vw, 22px);
  font-weight: 600;
  margin-bottom: clamp(12px, 3vw, 16px);
  color: var(--accent-teal);
  display: flex;
  align-items: center;
  gap: clamp(6px, 2vw, 10px);
  flex-wrap: wrap;
}

.sala-info-text {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: clamp(16px, 4vw, 28px);
  padding: clamp(16px, 4vw, 20px);
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--accent-teal);
  word-break: break-word;
}

.sala-preview-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: clamp(20px, 6vw, 40px) clamp(16px, 4vw, 40px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: clamp(12px, 3vw, 20px);
  height: 100%;
  text-align: center;
}

.sala-preview-card i {
  font-size: clamp(60px, 15vw, 120px);
  color: var(--accent-orange);
  opacity: 0.5;
}

.sala-preview-card span {
  font-size: clamp(14px, 3.5vw, 16px);
  color: var(--text-tertiary);
  font-weight: 500;
}

/* Alphabet filter */
.alphabet-filter {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(4px, 1.5vw, 8px);
  margin-bottom: clamp(16px, 4vw, 24px);
  padding: clamp(12px, 3vw, 16px);
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-subtle);
  justify-content: center;
}

.alphabet-letter {
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(28px, 7vw, 36px);
  height: clamp(28px, 7vw, 36px);
  border-radius: var(--radius-md);
  background: var(--bg-card);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: clamp(12px, 3vw, 14px);
}

.alphabet-letter:hover {
  background: var(--accent-orange);
  color: white;
}

.alphabet-letter.active {
  background: var(--accent-teal);
  color: white;
}

/* Activation page */
.activation-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: clamp(300px, 60vh, 500px);
  padding: clamp(16px, 4vw, 24px);
  margin-bottom: 40px;
}

.activation-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: clamp(24px, 6vw, 48px) clamp(16px, 4vw, 48px);
  max-width: min(520px, 100%);
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.activation-icon {
  font-size: 28px;
  color: var(--accent-teal);
}

.activation-title {
  font-size: 25px;
  font-weight: 700;
  color: var(--text-primary);
}

.activation-desc {
  color: var(--text-tertiary);
  margin-bottom: clamp(20px, 5vw, 32px);
  font-size: clamp(14px, 3.5vw, 15px);
}

.activation-input {
  width: 100%;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  color: var(--text-primary);
  padding: clamp(12px, 3vw, 16px) clamp(16px, 4vw, 24px);
  font-size: clamp(14px, 3.5vw, 16px);
  letter-spacing: clamp(1px, 0.4vw, 2px);
  text-align: center;
  margin-bottom: clamp(16px, 4vw, 24px);
}

.activation-input:focus {
  outline: none;
  border-color: var(--accent-orange);
  box-shadow: 0 0 0 3px rgba(255, 122, 61, 0.15);
}

.activation-actions {
  display: flex;
  gap: clamp(8px, 2vw, 12px);
  justify-content: center;
  margin-bottom: clamp(16px, 4vw, 24px);
  flex-wrap: wrap;
}

.activation-help {
  color: var(--text-muted);
  font-size: clamp(12px, 3vw, 13px);
  padding: clamp(12px, 3vw, 16px) 0 0;
  border-top: 1px solid var(--border-subtle);
}

/* 404 page */
.error-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: clamp(300px, 60vh, 500px);
  text-align: center;
  padding: clamp(16px, 4vw, 24px);
  margin-bottom: 40px;
}

.error-code {
  font-size: clamp(60px, 20vw, 120px);
  font-weight: 800;
  background: linear-gradient(135deg, var(--accent-orange), var(--accent-teal));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1;
  margin-bottom: clamp(8px, 2vw, 16px);
  word-break: break-word;
}

.error-message {
  font-size: clamp(16px, 4vw, 20px);
  color: var(--text-secondary);
  margin-bottom: clamp(20px, 5vw, 32px);
}

/* Suma bar */
.suma-bar {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: clamp(12px, 3vw, 16px) clamp(16px, 4vw, 24px);
  margin: clamp(24px, 4vw, 32px) 0 40px 0;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: clamp(8px, 2vw, 12px);
  font-size: clamp(14px, 3.5vw, 15px);
  flex-wrap: wrap;
}

.suma-bar span {
  color: var(--accent-teal);
  font-weight: 700;
  font-size: clamp(16px, 4vw, 20px);
}

/* Empty state */
.empty-state {
  text-align: center;
  padding: clamp(40px, 10vw, 80px) clamp(16px, 4vw, 20px);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  margin-bottom: 40px;
}

.empty-icon {
  font-size: clamp(48px, 12vw, 72px);
  color: var(--text-muted);
  margin-bottom: clamp(12px, 3vw, 20px);
  opacity: 0.5;
}

.empty-state p {
  color: var(--text-tertiary);
  font-size: clamp(14px, 3.5vw, 16px);
}

/* Footer navigation */
.footer-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--footer-h);
  background: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(4px, 2vw, 12px);
  padding: 0 clamp(8px, 3vw, 20px);
  z-index: 1000;
  backdrop-filter: blur(12px);
  background: rgba(20, 26, 31, 0.98);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
}

.footer-nav::-webkit-scrollbar {
  display: none;
}

.footer-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(4px, 1vw, 6px);
  width: clamp(70px, 20vw, 110px);
  height: clamp(50px, 12vw, 60px);
  border-radius: var(--radius-xl);
  font-size: clamp(10px, 2.5vw, 13px);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-tertiary);
  flex-shrink: 0;
}

.footer-nav a i {
  font-size: clamp(18px, 4.5vw, 22px);
}

.footer-nav a:hover,
.footer-nav a.active {
  color: var(--accent-orange);
  background: var(--bg-elevated);
}

/* Scrollbar style do paska przewijania */
::-webkit-scrollbar {
  width: clamp(6px, 1.5vw, 10px);
  height: clamp(6px, 1.5vw, 10px);
}

::-webkit-scrollbar-thumb {
  background: var(--accent-orange);
  border-radius: 5px;
}



/* Utility classes */
.mt-8 { margin-top: clamp(4px, 2vw, 8px); }
.mt-16 { margin-top: clamp(8px, 4vw, 16px); }
.mt-24 { margin-top: clamp(12px, 6vw, 24px); }
.mb-8 { margin-bottom: clamp(4px, 2vw, 8px); }
.mb-16 { margin-bottom: clamp(8px, 4vw, 16px); }
.mb-24 { margin-bottom: clamp(12px, 6vw, 24px); }
.mb-40 { margin-bottom: 40px; }
.ml-8 { margin-left: clamp(4px, 2vw, 8px); }
.mr-8 { margin-right: clamp(4px, 2vw, 8px); }
.text-center { text-align: center; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.gap-8 { gap: clamp(4px, 2vw, 8px); }
.gap-16 { gap: clamp(8px, 4vw, 16px); }

/* Dodatkowe poprawki dla bardzo małych ekranów */
@media (max-width: 360px) {
  .logo-text {
    display: none;
  }
  
  .meta-item {
    white-space: normal;
    word-break: break-word;
  }
  
  .detail-meta {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .btn {
    width: 100%;
  }
  
  .detail-actions {
    flex-direction: column;
  }
  
  .footer-nav a {
    width: 60px;
    font-size: 9px;
  }
  
  .footer-nav a i {
    font-size: 16px;
  }
  
  .welcome-section {
    margin-bottom: 60px;
    gap: 16px;
  }
  
  .welcome-card {
    min-height: 260px;
    padding: 20px 16px;
  }
}

/* Poprawki dla małych ekranów */
@media (max-width: 480px) {
  .welcome-section {
    gap: 20px;
    margin-bottom: 60px;
    padding-bottom: 20px;
  }
  
  .welcome-card {
    max-width: 100%;
    min-height: 280px;
    padding: 24px 20px;
  }
  
  .welcome-card h2 {
    font-size: 20px;
  }
  
  .welcome-card p {
    font-size: 14px;
    margin-bottom: 20px;
  }
  
  .welcome-card .btn {
    max-width: 160px;
    padding: 10px 16px;
  }
  
  .page-title {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  
  .page-subtitle {
    margin-left: 0;
  }
  
  .controls-bar {
    flex-direction: column;
    align-items: stretch;
  }
  
  .search-wrap {
    flex-direction: column;
    align-items: stretch;
  }
  
  .search-label {
    justify-content: center;
  }
  
  .suma-bar {
    margin-bottom: 50px;
  }
  
  .table-container:last-child,
  .detail-container,
  .sala-container,
  .activation-wrapper,
  .error-wrapper {
    margin-bottom: 50px;
  }
}

/* Poprawki dla ekranów średnich */
@media (min-width: 768px) and (max-width: 1024px) {
  .cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }
  
  .detail-grid {
    grid-template-columns: 1fr;
  }
  
  .detail-cover {
    max-width: 300px;
    margin: 0 auto;
  }
  
  .welcome-section {
    margin-bottom: 50px;
  }
  
  .welcome-card {
    min-height: 280px;
  }
}

/* Poprawki dla ekranów bardzo dużych */
@media (min-width: 1600px) {
  .page-body {
    max-width: 1600px;
    padding: 0px;
  }
  
  .cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  }
  
  .welcome-section {
    margin-bottom: 60px;
    gap: 40px;
  }
  
  .welcome-card {
    min-height: 320px;
  }
}

/* Wydruk */
@media print {
  .header,
  .footer-nav,
  .license-bar,
  .breadcrumb,
  .detail-actions,
  .btn {
    display: none !important;
  }
  
  .page-body {
    padding: 0;
    padding-bottom: 0;
  }
  
  .detail-container {
    box-shadow: none;
    border: 1px solid #ccc;
    margin-bottom: 0;
  }
}

/* Footer copyright */
.footer-copyright {
  left: 0;
  right: 0;
  text-align: center;
  font-size: clamp(10px, 2vw, 11px);
  color: var(--text-muted);
  z-index: 999;
  letter-spacing: 0.2px;
  margin-top: 5px;
}

[data-theme="light"] .footer-copyright {

}

/* Footer wersja */
.footer-wersja {
  text-align: right;
  font-size: 14px;
  color: var(--text-muted);
  padding: 5px;
}

.termin-licencji {
  text-align: right;
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
  white-space: nowrap;
  margin: 0;
}

margin: 0;
white-space: nowrap;
font-size: 14px;
color: var(--text-muted);




/* Strona: strona.glowna.klasyfikacja.html (wyszukiwarka paragrafów) */
.search-paragraph-section {
  margin-bottom: clamp(24px, 5vw, 40px);
}

.search-paragraph-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: clamp(20px, 4vw, 32px);
  text-align: center;
}

.search-paragraph-title {
  font-size: clamp(18px, 4vw, 24px);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: clamp(8px, 2vw, 12px);
}

.search-paragraph-subtitle {
  font-size: clamp(13px, 3vw, 15px);
  color: var(--text-tertiary);
  margin-bottom: clamp(20px, 4vw, 28px);
}

.search-paragraph-form {
  max-width: 600px;
  margin: 0 auto;
}

.search-paragraph-input-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: clamp(16px, 3vw, 20px);
}

.search-paragraph-input {
  flex: 1;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  color: var(--text-primary);
  padding: clamp(12px, 3vw, 16px) clamp(16px, 3vw, 24px);
  font-size: clamp(14px, 3.5vw, 16px);
}

.search-paragraph-input:focus {
  outline: none;
  border-color: var(--accent-orange);
  box-shadow: 0 0 0 3px rgba(255, 122, 61, 0.15);
}

.search-paragraph-btn {
  background: linear-gradient(135deg, var(--accent-orange), #ff9f6e);
  color: white;
  border: none;
  padding: clamp(12px, 3vw, 16px) clamp(24px, 5vw, 36px);
  border-radius: var(--radius-xl);
  font-weight: 600;
  font-size: clamp(14px, 3.5vw, 16px);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.search-paragraph-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: clamp(20px, 4vw, 28px) 0 clamp(16px, 3vw, 20px);
  color: var(--text-muted);
  font-size: clamp(13px, 3vw, 14px);
}

.search-paragraph-divider::before,
.search-paragraph-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-subtle);
}

.search-paragraph-menu {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(12px, 3vw, 20px);
  margin-top: clamp(8px, 2vw, 12px);
}

.search-paragraph-menu-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: clamp(8px, 2vw, 10px) clamp(16px, 3vw, 24px);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  color: var(--text-secondary);
  font-weight: 500;
  font-size: clamp(13px, 3vw, 14px);
  text-decoration: none;
}

.search-paragraph-menu-link i {
  font-size: clamp(12px, 2.5vw, 14px);
  color: var(--accent-teal);
}

.search-paragraph-menu-link:hover {
  border-color: var(--accent-orange);
  color: var(--accent-orange);
  background: var(--bg-elevated);
}

/* ============================================================
   STYLE DLA OKNA WYNIKÓW WYSZUKIWANIA (WIDOK 2026 → 2027)
   ============================================================ */

.results-shell {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: visible;
  margin: 10px;
}

.results-shell-full {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: visible;
  box-shadow: var(--shadow-md);
  margin: clamp(16px, 3vw, 24px) 0;
}

.results-body {
  display: grid;
  grid-template-columns: 1fr min(280px, 30%);
  gap: clamp(16px, 3vw, 24px);
  padding: clamp(16px, 3vw, 24px);
}

@media (max-width: 1280px) {
  .results-body { grid-template-columns: 1fr; }
}

.results-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: clamp(14px, 3vw, 20px);
  margin-bottom: clamp(12px, 2vw, 16px);
}


.results-card-dzial {
  background: #fbfdff;
  margin-bottom: clamp(12px, 2vw, 16px);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;

}
.results-head-dzial {
	font-size: clamp(14px, 3.5vw, 16px);
	font-weight: 600;
    padding: clamp(10px, 3vw, 10px);
}

.results-title-dzial {
  color: var(--text-secondary);
  margin-bottom: clamp(12px, 2vw, 16px);
  padding: 0px 20px;
  font-size: 16px;
  line-height: 1.58;
  font-weight: 500;
}

.search-result-dzial {
	display: inline-flex;
    background: rgba(59, 130, 246, 0.12);
	border-radius: 40px;
    padding: 6px 16px;
    height: 32px;
}




.results-card-objasnienie {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: clamp(14px, 3vw, 20px);
  margin-bottom: clamp(12px, 2vw, 16px);
}

.results-card:last-child { margin-bottom: 0; }

.card-title {
  font-size: clamp(14px, 3.5vw, 16px);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.card-sub {
  font-size: clamp(11px, 2.5vw, 12px);
  color: var(--text-muted);
  margin-bottom: clamp(12px, 2.5vw, 16px);
}

.search-header-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.search-top-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-field-container {
  flex: 1 1 300px;
  min-width: 0;
}

.clf-container {
  flex: 0 0 auto;
  min-width: 0;
}

/* Na szerokości < 860px clf schodzi pod pole wyszukiwania */
@media (max-width: 860px) {
  .search-top-row { flex-wrap: wrap; }
  .search-field-container { flex: 1 1 100%; }
  .clf-container { flex: 1 1 100%; }
  .clf-buttons-row { justify-content: flex-start; }
}



.search-input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  color: var(--text-primary);
  padding: clamp(10px, 2.5vw, 12px) clamp(36px, 5vw, 44px) clamp(10px, 2.5vw, 12px) clamp(14px, 3vw, 18px);
  font-size: clamp(13px, 3vw, 14px);
  font-weight: 500;
  box-sizing: border-box;
}

.search-input:focus {
  outline: none;
  border-color: var(--accent-orange);
  box-shadow: 0 0 0 3px rgba(255, 122, 61, 0.15);
}

.search-clear-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: var(--bg-elevated);
  border: none;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 11px;
  opacity: 0;
  visibility: hidden;
}

.search-clear-btn.visible { opacity: 1; visibility: visible; }
.search-clear-btn:hover { background: var(--accent-orange); color: white; }

.search-options {
  display: flex;
  gap: 12px;
  margin-top: 8px;
  flex-wrap: wrap;
}

.search-option {
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  font-size: 14px;
  color: var(--text-secondary);
}

.search-option input {
  accent-color: var(--accent-orange);
  width: 14px;
  height: 14px;
  cursor: pointer;
}

.clf-buttons-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
}

@media (max-width: 860px) {
  .clf-buttons-row { justify-content: flex-start; }
}

.clf-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 7px 11px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  white-space: nowrap;
  user-select: none;
}

.clf-btn:hover { border-color: var(--accent-orange); background: var(--bg-hover); }

.clf-btn.selected {
  border-color: var(--accent-teal);
  background: var(--bg-elevated);
  color: var(--accent-teal);
}

.clf-radio {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  border: 2px solid var(--border-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.clf-btn.selected .clf-radio { border-color: var(--accent-teal); }

.clf-radio-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-teal);
  display: none;
}

.clf-btn.selected .clf-radio-dot { display: block; }

.clf-new-badge-new {
  font-size: 12px;
  font-weight: 700;
  background: var(--accent-teal);
  color: #fff;
  padding: 1px 5px;
  border-radius: 4px;
  letter-spacing: 0.3px;
}
.clf-new-badge-old {
  font-size: 12px;
  font-weight: 700;
  background: var(--text-muted);
  color: #fff;
  padding: 1px 5px;
  border-radius: 4px;
  letter-spacing: 0.3px;
}


/* --- Wspólne style --- */
.clf-old-badge-wynik,
.clf-new-badge-wynik {
  font-size: 14px;
  padding: 1px 5px;
  border-radius: 4px;
  letter-spacing: 0.3px;
  
  /* Domyślnie (dark) */
  background: #2a5550;
  color: #b8d4cf;
  font-weight: 600;
  opacity: 0.85;
}

/* Jasny motyw – nadpisujemy tylko zmienne */
[data-theme="light"] .clf-old-badge-wynik {
  background: var(--text-muted);
  color: #ffffff;
  font-weight: 700;
  opacity: 1;
}

[data-theme="light"] .clf-new-badge-wynik {
  background: var(--accent-teal);
  color: #ffffff;
  font-weight: 700;
  opacity: 1;
}




/* NOWY UKŁAD FILTRÓW - wszystkie bloki obok siebie */
.filters-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 16px;
}

.filter-block {
  flex: 1;
  min-width: 160px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 12px 16px;
}

.filter-block-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 12px;
  border-left: 3px solid var(--accent-teal);
  padding-left: 8px;
}

.filter-check-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.filter-check-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.filter-check-item input {
  accent-color: var(--accent-teal);
  width: 16px;
  height: 16px;
  cursor: pointer;
  margin: 0;
}

.filter-check-item label {
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
}

/* Blok opcji dodatkowych - też jako osobny blok obok */
.extra-block {
  flex: 1;
  min-width: 180px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 12px 16px;
}

.extra-block-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 12px;
  border-left: 3px solid var(--accent-teal);
  padding-left: 8px;
}

.extra-check {
  display: flex;
  align-items: center;
  gap: 10px;
}

.extra-check input {
  accent-color: var(--accent-teal);
  width: 16px;
  height: 16px;
  cursor: pointer;
  margin: 0;
}

.extra-check label {
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  line-height: 1.4;
}

/* Style dla nieaktywnych bloków filtrów */
.filter-block.filter-disabled {
  opacity: 0.6;
  background: var(--bg-elevated);
}

.filter-block.filter-disabled .filter-check-item input:disabled {
  cursor: not-allowed;
}

.filter-block.filter-disabled .filter-check-item label {
  cursor: not-allowed;
  color: var(--text-muted);
}

.filter-check-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.filter-check-grid .filter-check-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Widoczność bloków */
.filter-block.hidden {
  display: none;
}

.validation-msg {
  display: none;
  margin-top: 8px;
  padding: 6px 10px;
  background: rgba(239,68,68,.1);
  border: 1px solid rgba(239,68,68,.3);
  border-radius: var(--radius-md);
  font-size: 11px;
  color: var(--accent-red);
}

.validation-msg.visible { display: block; }

.btn-show {
  background: linear-gradient(135deg, var(--accent-orange), #ff9f6e);
  color: white;
  border: none;
  border-radius: var(--radius-xl);
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  width: auto;        /* zmiana z 100% na auto */
  min-width: 160px;   /* opcjonalnie - minimalna szerokość */
  margin-top: 14px;
  margin-left: auto;  /* wyśrodkowanie */
  margin-right: auto; /* wyśrodkowanie */
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-show:disabled {
  background: var(--text-muted);
  opacity: 0.5;
  cursor: not-allowed;
}

.url-preview-wrap {
  margin-top: 12px;
  display: none;
}

.url-preview-wrap.visible { display: block; }

.url-preview-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 5px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.url-preview-row {
  display: flex;
  gap: 6px;
  align-items: center;
}

.url-preview-input {
  flex: 1;
  min-width: 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  color: var(--accent-teal);
  font-family: monospace;
  font-size: 11px;
  padding: 8px 12px;
  word-break: break-all;
  cursor: text;
  outline: none;
}

.url-preview-input:focus {
  border-color: var(--accent-teal);
  box-shadow: 0 0 0 2px rgba(45,212,191,.15);
}

.url-copy-btn {
  flex-shrink: 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  color: var(--text-secondary);
  font-size: 12px;
  padding: 8px 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.url-copy-btn:hover {
  background: var(--accent-teal);
  color: #fff;
  border-color: var(--accent-teal);
}

.url-copy-btn.copied {
  background: var(--accent-teal);
  color: #fff;
  border-color: var(--accent-teal);
}

/* porównanie */
.comparison-container {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 20px;
  align-items: stretch;
}

@media (max-width: 700px) {
  .comparison-container { grid-template-columns: 1fr; gap: 30px; }
  .comparison-arrow { transform: rotate(90deg); text-align: center; margin: 0 auto; }
}

.col-source, .col-target {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.col-header .left,
.col-header .right {
  background: transparent !important;
  padding: 12px 16px;
  border-bottom: 2px solid var(--accent-teal);
  font-weight: 700;
  font-size: 14px;
  color: var(--text-primary);
  text-align: center;
}

[data-theme="light"] .col-header .left {
  background: rgba(59, 130, 246, 0.08) !important;
  border-bottom-color: var(--accent-blue);
}

:root:not([data-theme="light"]) .col-header .left {
  background: rgba(59, 130, 246, 0.15) !important;
  border-bottom-color: var(--accent-blue);
}

[data-theme="light"] .col-header .right {
  background: rgba(45, 212, 191, 0.08) !important;
  border-bottom-color: var(--accent-teal);
}

:root:not([data-theme="light"]) .col-header .right {
  background: rgba(45, 212, 191, 0.12) !important;
  border-bottom-color: var(--accent-teal);
}

.col-header small {
  font-weight: 400;
  font-size: 11px;
  color: var(--text-muted);
  display: block;
  margin-top: 2px;
}

.result-item {
  padding: 15px;
  border: 1px solid var(--border-subtle);
  margin: 10px;
  border-radius: 10px;
  cursor: pointer;
}

.result-item:last-child {  }
.result-item:hover { background: var(--bg-hover); }

.result-code {
  font-size: 24px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.result-code i {
  font-size: 20px;
  color: var(--accent-teal);
}

.result-type-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
}


.result-name {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 12px;
}

/* ============================================================
   STYLE DLA LINKÓW ZAŁĄCZNIKÓW
   ============================================================ */

.result-attachment-link {
  text-decoration: none;
  display: inline-flex;
}

.result-attachment {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 10px;
  background: var(--bg-elevated);
  border-radius: 20px;
  font-size: 14px;
  color: var(--accent-elevated);
  text-decoration: none;
}

.result-attachment i {
  font-size: 14px;
}


/* Style dla linków w jasnym motywie */
[data-theme="light"] a {
  color: var(--accent-teal);
}
[data-theme="light"] a:hover {
  color: var(--accent-orange);
}


[data-theme="light"] .breadcrumb a {
  color: var(--accent-blue);
}

[data-theme="light"] .breadcrumb a:hover {
  color: var(--accent-orange);
}

[data-theme="light"] .res-name:hover {
  color: var(--accent-orange);
}

/* Style dla legend */
.legend-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 12px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  color: var(--text-secondary);
}

.legend-badge {
  width: 20px;
  height: 20px;
  border-radius: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  font-weight: 700;
}

/* Nowa kompaktowa legenda - pills */
.legend-compact {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.legend-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  cursor: default;
}

.legend-pill .legend-pill-label {
  font-weight: 400;
  font-size: 10px;
  opacity: 0.85;
}

.legend-pill-icon {
  background: var(--bg-elevated);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
}

.legend-pill-icon i {
  font-size: 10px;
  color: var(--accent-teal);
}

.results-summary {
  margin-top: 16px;
  padding: 12px;
  background: rgba(45,212,191,.1);
  border-radius: var(--radius-lg);
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-teal);
}

.action-buttons {
  display: flex;
  gap: 20px;
  justify-content: flex-end;
  margin: 0 clamp(16px,3vw,24px) 16px clamp(16px,3vw,24px);
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
}

.change-search-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 8px 16px;
  font-size: 12px;
  cursor: pointer;
  width: 100%;
  text-align: center;
  margin-top: 12px;
  color: var(--text-secondary);
}

.change-search-btn:hover { background: var(--accent-orange); color: white; border-color: var(--accent-orange); }

/* Klasy dochody/wydatki dla ikon — definicje w sekcji result-type-badge powyżej */

.result-circle {
  font-size: 12px;
  color: var(--accent-teal);
}

.result-circle i {
  font-size: 20;
}


.type-D  { background: rgba(59,130,246,.15); color: var(--accent-blue); }
.type-W  { background: rgba(234,179,8,.15);  color: var(--accent-yellow); }
.type-P  { background: rgba(168,85,247,.15); color: var(--accent-purple); }
.type-R  { background: rgba(239,68,68,.15);  color: var(--accent-red); }
.type-DW { background: linear-gradient(rgba(59,130,246,0.15) 0%, rgba(234,179,8,0.15) 100%); color: var(--accent-teal); }
.type-PR  { background: linear-gradient(rgba(168,85,247,0.15) 0%, rgba(239,68,68,0.15) 100%);  color: var(--accent-red); }



/* Gradient tekstu dla typów mieszanych */
.type-DWx {
  background: linear-gradient(135deg, rgba(59,130,246,0.15) 0%, rgba(234,179,8,0.15) 100%);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  margin: 2px;
  border: 0px solid rgba(59,130,246,0.2);
  position: relative;
  overflow: hidden;
}


.type-PRx {
  background: linear-gradient(135deg, rgba(168,85,247,0.15) 0%, rgba(239,68,68,0.15) 100%);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  margin: 2px;
  border: 0px solid rgba(168,85,247,0.2);
  position: relative;
  overflow: hidden;
}

.type-Bezp {
  background: rgba(59,130,246,0.1);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  margin: 2px;
  border: 1px solid rgba(168,85,247,0.2);
  position: relative;
  overflow: hidden;
}



.dochodowy {
  background: #3b82f626;
  color: var(--accent-blue);;
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
  line-height: 1;
}
.wydatki {
  background: #eab30826;
  color: var(--accent-yellow);
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
  line-height: 1;
}
.przychody {
  background: #a855f726;
  color: var(--accent-purple);
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
  line-height: 1;
}

.rozchody {
  background: #ef444426;
  color:  var(--accent-red);
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
  line-height: 1;
}

.dochodowowydatkowy {
  background: linear-gradient(rgba(59,130,246,0.15) 0%, rgba(234,179,8,0.15) 100%);
  color: var(--accent-teal);
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
 
  font-size: 14px;
  line-height: 1;
}

.przychodoworozchodowy {
  background: linear-gradient(rgba(168,85,247,0.15) 50%, rgba(239,68,68,0.15) 50%);
  color: var(--accent-red);
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
  line-height: 1;
}


.type-JST {
  background: #3A4556;
  color: #EEF2F6;
  display: inline-block;
  padding: 2px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.type-BP {
  background: #1F3A5F;
  color: #EAF1FF;
  display: inline-block;
  padding: 2px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

/* W pliku style.css */
.type-BP:empty,
.type-JST:empty {
  display: none;
}


.sidebar-panel {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: clamp(14px, 3vw, 18px);
}

.info-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-teal);
  font-size: 16px;
  margin-bottom: 12px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-subtle);
  font-size: 12px;
}

.summary-label {
  color: var(--text-muted);
  flex-shrink: 0;
  white-space: nowrap;
}

.summary-value {
  color: var(--text-primary);
  font-weight: 500;
  text-align: right;
  word-break: break-word;
  min-width: 0;
}


/* Jasny motyw (domyślny) */
.explanation-panel {
  background: #f1f7ff;
  border: 1px solid #cbdfff;
  padding: 16px;
  border-radius: var(--radius-lg);
  margin-top: 16px;
}

/* Ciemny motyw */
[data-theme="dark"] .explanation-panel,
:root:not([data-theme="light"]) .explanation-panel {
  background: rgba(45, 212, 191, 0.1);
  border: 1px solid rgba(45, 212, 191, 0.3);
}

.explanation-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--accent-teal);
  margin-bottom: 8px;
}

.explanation-text {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Poprawki dla kontenera porównania */
.comparison-container .left,
.comparison-container .right {
  
}

.col-header .left small,
.col-header .right small {
  color: var(--text-tertiary);
}

[data-theme="light"] .col-header .left small,
[data-theme="light"] .col-header .right small {
  color: var(--text-muted);
}

/* Poprawki dla strzałki któa wskazuje na nową klasyfikacje */
.comparison-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--accent-teal);
  padding: 0 8px;
}

@media (max-width: 700px) {
  .comparison-container {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  .comparison-arrow {
    transform: rotate(90deg);
    margin: 0 auto;
    padding: 16px 0;
  }
}

/* Dodatkowe wsparcie dla jasnego motywu */
[data-theme="light"] .comparison-arrow {
  color: var(--accent-orange);
}

.comparison-container {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 10px;
  align-items: center;
}

/* Wyśrodkowanie sidebar - panel po prawej stronie z legendą */
.col-right {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  align-self: flex-start;
  position: sticky;
  top: 16px;
}

@media (max-width: 1280px) {
  .col-right {
    position: static;
    align-self: stretch;
  }
}

/* Style dla trybu testowego badge */
[data-test-badge] {
  position: fixed;
  bottom: 10px;
  right: 10px;
  background: #ff6b6b;
  color: white;
  padding: 5px 10px;
  border-radius: 5px;
  font-size: 12px;
  z-index: 9999;
  font-family: sans-serif;
}



/* ============================================================
   STYLE DLA STRONY SZCZEGOLY.HTML
   ============================================================ */

.content-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  padding: 0 10px;
  gap: 4px;
}

.content-tabs .nav-link {
  border: 0;
  border-radius: 12px 12px 0 0;
  margin-top: 8px;
  padding: 10px 16px;
  color: var(--text-tertiary);
  font-size: 14px;
  font-weight: 700;
  background: transparent;
  cursor: pointer;
}

.content-tabs .nav-link.active {
  background: var(--bg-card);
  color: var(--accent-teal);
  border: 1px solid var(--border-subtle);
  border-bottom-color: var(--bg-card);
  margin-bottom: -1px;
}

.tab-pane-content {
  min-height: 200px;
  max-height: 310px;
  overflow: auto;
  padding: 18px 20px;
  font-size: 14px;
  line-height: 1.75;
  color: var(--text-secondary);
}

.tab-pane-content h3 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.example-card {
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  background: #fbfdff;
  padding: 14px;
  margin-bottom: 8px;
}

[data-theme="light"] .example-card {
  background: #fbfdff;
}

:root:not([data-theme="light"]) .example-card {
  background: var(--bg-elevated);
}

.variant-grid {
  display: grid;
  gap: 16px;
  margin-bottom: 10px;
}

.variant-card {
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  background: var(--bg-surface);
  padding: 14px;
}

.variant-head {
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.variant-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  color: var(--text-primary);
}

.round {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.round.d {
  background: var(--accent-blue);
  color: #fff;
}

.round.w {
  background: var(--accent-yellow);
  color: #07162f;
}

.round.dw {
  background: var(--accent-teal);
  color: #061634;
}

.variant-text {
  font-size: 16px;
  line-height: 1.58;
  color: var(--text-secondary);
  font-weight: 500;
}

.hero {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 18px;
  align-items: start;
  margin-bottom: 22px;
}

.code-box {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #0b55d9;
}

.code-box .sign {
  font-size: 15px;
  font-weight: 500;
  color: var(--accent-orange);
}
.code-box .number {
  font-size: 24px;
  font-weight: 900;
  line-height: 1.05;
}

.paragraph-note-result {
  background: rgba(45, 212, 191, 0.08);
  color: var(--text-primary); 
  font-size: 16px;
  line-height: 1.60;
  margin-bottom: 10px;
  padding: 10px;
  border-left: 4px solid var(--accent-teal);
  border-radius: var(--radius-lg);
}

/* Opcjonalnie: delikatne wyróżnienie w trybie ciemnym */
[data-theme="dark"] .paragraph-note-result,
:root:not([data-theme="light"]) .paragraph-note-result {
  color: var(--text-primary);
  font-weight: 500;
}


.paragraph-title {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.28;
  margin-bottom: 6px;
  color: var(--text-primary);
}

.paragraph-note {
  background: rgba(45, 212, 191, 0.08);
  font-size: 16px;
  line-height: 1.60;
  margin-bottom: 10px;
  padding: 10px;
  border-left: 4px solid var(--accent-teal);
  border-radius: var(--radius-lg);
}

.paragraph-note-full {
  font-size: 16px;
  line-height: 1.55;
  color: var(--text-tertiary);
  margin-bottom: 10px;
}

.pill_zal_klas.zal {
    background: rgba(107,114,128,0.12);
    color: var(--accent-elevated);
    border-color: rgba(59, 130, 246, 0.25);
}

.pill_zal_klas.klas {
    background: rgba(45, 212, 191, 0.1);
    color: var(--accent-teal);
    border-color: rgba(45, 212, 191, 0.2);
}


/* Style dla etykiety "Rodzaje:" w sekcji hero */
.rodzaje-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-right: 8px;
    flex-shrink: 0;
}

.rodzaje-pills-container {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
}


/* Wyrównanie wysokości elementów w hero */
.meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.pill-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 0;
}

.all-pills-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin: 0;
  padding: 0;
}

.pill_zal_klas,
.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 40px;
  padding: 6px 16px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  height: 32px; /* Stała wysokość dla wszystkich */
  box-sizing: border-box;
}


.pill.d {
  background: rgba(59, 130, 246, 0.15);
  color: var(--accent-blue);
  border-color: rgba(59, 130, 246, 0.3);
}

.pill.w {
  background: rgba(234, 179, 8, 0.15);
  color: var(--accent-yellow);
  border-color: rgba(234, 179, 8, 0.3);
}

.pill.dw {
  background: rgba(45, 212, 191, 0.15);
  color: var(--accent-teal);
  border-color: rgba(45, 212, 191, 0.3);
}

.pill.bp {
  background: #1F3A5F;
  color: #EAF1FF;
}

.pill.jst {
  background: #3A4556;
  color: #EEF2F6;
}

.pill.status {
  background: var(--bg-elevated);
  color: var(--text-secondary);
  border-color: var(--border-subtle);
}

.history-strip {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--border-subtle);
  background: rgba(59, 130, 246, 0.15);
  border-radius: 14px;
  padding: 12px 16px;
  margin-bottom: 20px;
}

.history-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.history-text {
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-tertiary);
}

.btn-history,
.btn-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 36px;
  padding: 8px 18px;
  border-radius: var(--radius-xl);
  font-family: 'Outfit', sans-serif;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
}

.btn-history {
  border: 1px solid var(--border-strong);
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.btn-history:hover {
  background: var(--bg-hover);
  border-color: var(--accent-teal);
  color: var(--accent-teal);
}

.btn-back {
  border: 1px solid rgba(255, 122, 61, 0.45);
  background: linear-gradient(135deg, var(--accent-orange), #ff9f6e);
  color: #fff !important;
}

.btn-back:hover {
  background: linear-gradient(135deg, #e86a2c, var(--accent-orange));
  border-color: var(--accent-orange);
  color: #fff !important;
}

.btn-history i,
.btn-back i {
  font-size: 13px;
}


.action-row {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 12px;
}

@media (max-width: 780px) {
  .variant-grid {
    grid-template-columns: 1fr;
  }
  .hero {
    grid-template-columns: 70px 1fr;
  }
  .history-strip {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

/* Modal styles */
.modal-content {
  border-radius: 18px;
}

.modal-header {
  border-bottom-color: var(--border-subtle);
}

.modal-title {
  font-weight: 700;
  color: var(--text-primary);
}

.modal-body {
  background: var(--bg-card);
}

.modal-footer {
  border-top-color: var(--border-subtle);
}





/* system.wyniki_dzial.html */

.dynamic-select-group {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 16px;
  margin-bottom: 8px;
}
.dynamic-select-box {
  flex: 1;
  min-width: 200px;
}
.dynamic-select-box label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  letter-spacing: 0.3px;
}
.selectx {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  color: var(--text-primary);
  padding: 10px 12px;
  font-size: 13px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
}
.selectx:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background: var(--bg-elevated);
}








/* Przycisk POKAŻ - szerokość 100px, zmiana w trybie dzień/noc */
.btn-show {
  border: none;
  border-radius: var(--radius-xl);
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  width: 100px;
  min-width: 100px;
  margin-top: 14px;
  margin-left: auto;
  margin-right: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none !important;
}

.btn-show i {
  font-size: 13px;
}

.btn-show:hover {
  text-decoration: none !important;
}

.btn-show-disabled {
  pointer-events: none;
  cursor: not-allowed;
}

/* JASNY MOTYW - żywy pomarańczowy */
[data-theme="light"] .btn-show {
  background: #ff9f6e;
  color: white !important;
}

[data-theme="light"] .btn-show:hover {
  background: #ff6a2c;
}

/* CIEMNY MOTYW - stonowany, szaro-pomarańczowy */
[data-theme="dark"] .btn-show,
:root:not([data-theme="light"]) .btn-show {
  background: #5a4a3a;
  color: #d4c5b5 !important;
}

[data-theme="dark"] .btn-show:hover,
:root:not([data-theme="light"]) .btn-show:hover {
  background: #6a5a4a;
  color: #e8d5c0 !important;

}

/* tryb DZIEŃ (light) - przycisk NIEAKTYWNY */
[data-theme="light"] .btn-show.btn-show-disabled {
  background: #e9ecf0 !important;
  color: #8a94a6 !important;
  border: none;
  box-shadow: none;
}


/* Nieaktywny typ wyszukiwania po słowie */
.search-option-disabled {
  opacity: 0.5;
  cursor: not-allowed;
}




/* Style dla autocomplete */
.autocomplete-list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  max-height: 250px;
  overflow-y: auto;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  display: none;
}

.autocomplete-list.active {
  display: block;
}

.autocomplete-item {
  padding: 10px 12px;
  cursor: pointer;
  border-bottom: 1px solid #eee;
  transition: background 0.2s;
}

.autocomplete-item:hover {
  background: #f0f7ff;
}

.autocomplete-item.selected {
  background: #e3f0ff;
}

.autocomplete-item .code {
  font-weight: bold;
  color: #0066cc;
}

.autocomplete-item .name {
  font-size: 0.85em;
  color: #666;
  margin-left: 8px;
}

.search-input-wrapper {
  position: relative;
  width: 100%;
}

/* === SMART SELECT – dwuetapowy wybór działu i rozdziału === */
.smart-select-row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: nowrap;
  margin: 0;
}

.smart-select-box {
  flex: 1 1 0;
  min-width: 0;
}

.smart-step-badge {
  width: 20px;
  height: 20px;
  background: var(--accent-orange);
  color: #fff;
  border-radius: 50%;
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  flex-shrink: 0;
}

.smart-field.is-disabled .smart-step-badge {
  background: var(--text-muted);
}

.smart-field {
  position: relative;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  background: var(--bg-card);
  transition: border-color .18s, box-shadow .18s;
  display: flex;
  align-items: center;
}

.smart-field.has-value {
  border-color: var(--accent-orange);
}

.smart-field.focused {
  border-color: var(--accent-orange);
  box-shadow: 0 0 0 3px rgba(255, 122, 61, 0.15);
}

.smart-field.is-disabled {
  opacity: .5;
  pointer-events: none;
  background: var(--bg-elevated);
  border-color: var(--border-subtle);
}

.smart-input-area {
  display: flex;
  align-items: center;
  width: 100%;
  padding: clamp(10px, 2.5vw, 12px) clamp(10px, 2vw, 12px);
  gap: 6px;
  cursor: text;
  flex-wrap: wrap;
}

.smart-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255, 122, 61, 0.12);
  color: var(--accent-orange);
  border: 1px solid rgba(255, 122, 61, 0.3);
  padding: 4px 10px 4px 12px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  max-width: 100%;
}

.smart-chip-code {
  opacity: .75;
  font-size: 11px;
  font-weight: 700;
}

.smart-chip-name {
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
  font-size: 12px;
}

.smart-chip-clear {
  background: none;
  border: none;
  color: rgba(255, 122, 61, 0.6);
  cursor: pointer;
  padding: 0 2px;
  font-size: 17px;
  line-height: 1;
  flex-shrink: 0;
  transition: color .15s;
}

.smart-chip-clear:hover {
  color: var(--accent-orange);
}

.smart-text-input {
  border: none;
  outline: none;
  background: transparent;
  font-size: 14px;
  flex: 1;
  min-width: 60px;
  padding: 4px 2px;
  color: var(--text-primary);
}

.smart-text-input::placeholder {
  color: var(--text-muted);
}

.smart-dropdown {
  position: absolute;
  top: calc(100% + 5px);
  left: 0;
  right: 0;
  background: var(--bg-surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-xl);
  max-height: 260px;
  overflow-y: auto;
  z-index: 1100;
  box-shadow: var(--shadow-lg);
  display: none;
}

.smart-dropdown.open {
  display: block;
}

.smart-dd-item {
  padding: 10px 14px;
  cursor: pointer;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: baseline;
  gap: 8px;
  transition: background .12s;
}

.smart-dd-item:last-child {
  border-bottom: none;
}

.smart-dd-item:hover,
.smart-dd-item.hovered {
  background: var(--bg-hover);
}

.smart-dd-item .dd-code {
  font-weight: 700;
  color: var(--accent-orange);
  font-size: 13px;
  flex-shrink: 0;
  font-family: monospace;
}

.smart-dd-item .dd-name {
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.35;
}

.smart-dd-item .dd-name mark {
  background: rgba(255, 122, 61, 0.2);
  color: var(--text-primary);
  border-radius: 2px;
  font-weight: 700;
  font-style: normal;
}

.smart-dd-empty {
  padding: 14px 16px;
  color: var(--text-muted);
  font-size: 13px;
  font-style: italic;
}

.smart-connect-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--border-strong);
  font-size: 13px;
  flex-shrink: 0;
  padding: 0 2px;
}

/* Blok filter-disabled */
.filter-disabled .extra-check label {
  color: var(--text-muted, #999) !important;
  opacity: 0.45;
  cursor: not-allowed;
}

.filter-disabled .extra-check input[type="checkbox"] {
  opacity: 0.45;
  cursor: not-allowed;
}

@media (max-width: 560px) {
  .smart-select-row {
    flex-direction: column;
    align-items: stretch;
  }
  .smart-connect-arrow {
    display: none;
  }
  .smart-chip-name {
    max-width: 120px;
  }
  .smart-select-box {
    flex: 1 1 100%;
  }
}

/* Styl dla całego bloku opcji dodatkowych gdy nieaktywny */
.extra-block.filter-disabled {
    opacity: 0.6;
    pointer-events: none;
    user-select: none;
    background: var(--bg-elevated);
}

/* Opcjonalnie: dodanie ikony kursora dla lepszego UX */
.extra-block.filter-disabled .extra-check label,
.extra-block.filter-disabled .extra-check input {
    cursor: not-allowed;
}



/* ============================================================
   STYLE DLA STRONY O PROGRAMIE (about.html)
   ============================================================ */

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: clamp(16px, 4vw, 28px);
  margin-top: 20px;

}

.about-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: hidden;
}

.about-card-header {
  padding: clamp(16px, 4vw, 22px) clamp(16px, 4vw, 24px);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: clamp(8px, 2vw, 14px);
  background: var(--bg-surface);
}

.about-card-header i {
  font-size: clamp(18px, 4vw, 22px);
  color: var(--accent-orange);
  width: 28px;
  text-align: center;
}

.about-card-header h3 {
  font-size: clamp(14px, 3.5vw, 16px);
  font-weight: 600;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.about-card-body {
  padding: clamp(12px, 3vw, 20px) clamp(16px, 4vw, 24px);
}

.info-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: clamp(8px, 2vw, 12px) 0;
  border-bottom: 1px solid var(--border-subtle);
  gap: 16px;
}

.info-row:last-child {
  border-bottom: none;
}

.info-label {
  font-size: clamp(12px, 2.8vw, 13px);
  color: var(--text-tertiary);
  font-weight: 500;
  flex-shrink: 0;
  min-width: 130px;
}

.info-value {
  font-size: clamp(12px, 2.8vw, 13px);
  color: var(--text-primary);
  font-weight: 600;
  text-align: right;
  word-break: break-all;
}

.info-value.accent {
  color: var(--accent-teal);
}

.info-value.warning {
  color: var(--accent-yellow);
}

.info-value.ok {
  color: var(--accent-teal);
}

/* Hero banner */
.about-hero {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: 20px;
  margin-bottom: clamp(20px, 4vw, 28px);
  display: flex;
  align-items: center;
  gap: clamp(20px, 5vw, 40px);
  flex-wrap: wrap;
  position: relative;
  overflow: hidden;
   margin: clamp(16px, 3vw, 24px) 0;
}

.about-hero::before {
  content: '';
  position: absolute;
  top: -60px;
  right: -60px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,122,61,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.about-hero::after {
  content: '';
  position: absolute;
  bottom: -40px;
  left: 30%;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(45,212,191,0.06) 0%, transparent 70%);
  pointer-events: none;
}

.about-hero-logo {
  width: clamp(64px, 15vw, 96px);
  height: clamp(64px, 15vw, 96px);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}


.about-hero-info {
  flex: 1;
  min-width: 200px;
}

.about-hero-title {
  font-size: clamp(22px, 6vw, 32px);
  font-weight: 500;
  color: var(--accent-teal);
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}

.about-hero-version {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  border-radius: 40px;
  padding: 5px 16px;
  font-size: clamp(12px, 3vw, 13px);
  font-weight: 600;
  color: var(--accent-teal);
  margin-bottom: 12px;
}

.about-hero-desc {
  color: var(--text-tertiary);
  font-size: clamp(13px, 3vw, 14px);
  line-height: 1.6;
}

.badge-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 40px;
  font-size: 12px;
  font-weight: 600;
}

.badge-orange {
  background: rgba(255,122,61,0.12);
  color: var(--accent-orange);
  border: 1px solid rgba(255,122,61,0.25);
}

.badge-teal {
  background: rgba(45,212,191,0.10);
  color: var(--accent-teal);
  border: 1px solid rgba(45,212,191,0.2);
}

.badge-blue {
  background: rgba(59,130,246,0.10);
  color: var(--accent-blue);
  border: 1px solid rgba(59,130,246,0.2);
}

/* Copyright footer */
.about-copyright {
  text-align: center;
  padding: 20px 0 40px;
  color: var(--text-muted);
  font-size: 13px;
}

.about-copyright a {
  color: var(--accent-orange);
  font-weight: 600;
}

.spinner-inline {
  display: inline-block;
  width: 10px;
  height: 10px;
  border: 2px solid var(--border-strong);
  border-top-color: var(--accent-teal);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  vertical-align: middle;
  margin-right: 4px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Jasny motyw dla about-hero */
[data-theme="light"] .about-hero::before {
  background: radial-gradient(circle, rgba(255,122,61,0.12) 0%, transparent 70%);
}

[data-theme="light"] .about-hero::after {
  background: radial-gradient(circle, rgba(45,212,191,0.1) 0%, transparent 70%);
}





/* ============================================================
   DASHBOARD PARAGRAFU (system.szczegoly.html)
   ============================================================ */
/* Karty informacyjne */
.info-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: hidden;
  height: fit-content;
  margin-bottom: 24px;
}

.panel-header {
  padding: 16px 20px;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.panel-title {
  font-weight: 700;
  font-size: 16px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.panel-title i {
  color: var(--accent-orange);
  font-size: 18px;
}

.panel-badge-light {
  background: var(--bg-elevated);
  color: var(--text-secondary);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid var(--border-subtle);
}


/* Full width card - link */
.full-width-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 8px;
}


/* Safety box */
.safety-box {
  background: rgba(45, 212, 191, 0.08);
  border-left: 4px solid var(--accent-teal);
  padding: 16px 20px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.safety-box i {
  font-size: 18px;
  color: var(--accent-teal);
}

.safety-box p {
  margin: 0;
  flex: 1;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Tabela podparagrafów */
.subparagraph-table {
  width: 100%;
  border-collapse: collapse;
}

.subparagraph-table th {
  text-align: left;
  padding: 12px 8px 12px 0;
  font-weight: 600;
  color: var(--text-tertiary);
  font-size: 12px;
  border-bottom: 1px solid var(--border-subtle);
}

.subparagraph-table td {
  padding: 12px 8px 12px 0;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 13px;
}

.subparagraph-table tr:last-child td {
  border-bottom: none;
}



/* Mapping rows */
.mapping-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--border-subtle);
}

.mapping-row:last-child {
  border-bottom: none;
}

/* Panel kluczy przejścia */
.info-panel .panel-content {
  padding: 20px;
}


/* Nagłówek z dwiema kolumnami */
.mapping-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border-strong);
}

.mapping-header-left,
.mapping-header-right {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 13px;
}

.mapping-header-left {
  color: var(--accent-orange);
  justify-content: flex-start;
}

.mapping-header-right {
  color: var(--accent-teal);
  justify-content: flex-end;
}

/* Kontener dla listy mapowań */
.mappings-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Pojedynczy wiersz mapowania */
.mapping-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
}

/* Stary kod (stary paragraf/podparagraf) */
.mapping-old {
  font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
  font-weight: 700;
  font-size: 15px;
  color: white;
  background: var(--accent-orange);
  padding: 6px 16px;
  border-radius: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 100px;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Strzałka */
.mapping-arrow {
  color: var(--accent-teal);
  font-size: 18px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Nowy kod (nowy paragraf) */
.mapping-new {
  font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
  font-weight: 700;
  font-size: 15px;
  color: white;
  background: var(--accent-teal);
  padding: 6px 16px;
  border-radius: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 100px;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}





/* Responsywność dashboardu */
@media (max-width: 900px) {
  .two-column-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 550px) {
  .code-header-left {
    flex-direction: column;
    align-items: flex-start;
  }
  .panel-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .legend-grid {
    grid-template-columns: 1fr;
  }
}








/* ikonka bezpieczeństwo szczegoly.html */
.pill.safety-pill {
  background: var(--accent-teal);
  color: white;
}


.safety-icon-inline i {
  font-size: 14px;
  margin-left: 8px;
}






/* ============================================================
   STYLE DLA PODPARAGRAFÓW - SPÓJNE Z KLAUCZAMI PRZEJŚCIA
   ============================================================ */

/* Nagłówek podparagrafów */
.subparagraph-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border-strong);
}

.subparagraph-header-left,
.subparagraph-header-right {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.subparagraph-header-left {
  color: var(--accent-orange);
  justify-content: flex-start;
}

.subparagraph-header-right {
  color: var(--accent-teal);
  justify-content: flex-start;
  padding-left: 20px;
}

.subparagraph-header-left i,
.subparagraph-header-right i {
  font-size: 14px;
  opacity: 0.8;
}

/* Kontener dla listy podparagrafów */
.subparagraphs-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 5px;
}

/* Pojedynczy wiersz podparagrafu */
.subparagraph-row {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 10px;
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-subtle);
  transition: all 0.2s ease;
  cursor: pointer;
}

.subparagraph-row:hover {
  border-color: var(--accent-teal);
  background: var(--bg-hover);
  box-shadow: var(--shadow-sm);
}





/* Responsywność dla podparagrafów */
@media (max-width: 768px) {
  .subparagraph-row {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 16px;
  }
  
  .subparagraph-code {
    align-self: flex-start;
    min-width: auto;
    padding: 6px 16px;
    font-size: 14px;
  }
  
  .subparagraph-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  
  .subparagraph-header-right {
    padding-left: 0;
  }
}

/* Ciemny motyw - dodatkowe dostrojenia */
[data-theme="dark"] .subparagraph-row,
:root:not([data-theme="light"]) .subparagraph-row {
  background: var(--bg-card);
}

[data-theme="dark"] .subparagraph-row:hover,
:root:not([data-theme="light"]) .subparagraph-row:hover {
  background: var(--bg-elevated);
}


[data-theme="light"] .subparagraph-row:hover {
  background: #f8f9fa;
  border-color: var(--accent-orange);
}


.number {
  font-size: 10px;
  color: var(--accent-orange);
  font-weight: 500;

}




/* ============================================================
   STYLE DLA KLAUCZY PRZEJŚCIA - NOWA WERSJA PREMIUM
   ============================================================ */

/* Badges w nagłówku */
.panel-badge-group {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.mapping-badge-old,
.mapping-badge-new {
  font-size: 9px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  margin-left: 8px;
}

.mapping-badge-old {
  background: rgba(255, 122, 61, 0.15);
  color: var(--accent-orange);
  border: 1px solid rgba(255, 122, 61, 0.3);
}

.mapping-badge-new {
  background: rgba(45, 212, 191, 0.15);
  color: var(--accent-teal);
  border: 1px solid rgba(45, 212, 191, 0.3);
}

/* Nagłówek z trzema kolumnami */
.mapping-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--border-strong);
  gap: 16px;
  flex-wrap: wrap;
}

.mapping-header-left,
.mapping-header-right {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.3px;
}

.mapping-header-left {
  color: var(--accent-orange);
  justify-content: flex-start;
}

.mapping-header-right {
  color: var(--accent-teal);
  justify-content: flex-end;
}

.mapping-header-center {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 20px;
  flex-shrink: 0;
}

/* Statystyki przejść */
.mapping-stats {
  display: flex;
  gap: 16px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.stat-card {
  flex: 1;
  min-width: 120px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 12px 16px;
  transition: all 0.2s ease;
}

.stat-card:hover {
  border-color: var(--accent-teal);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.stat-card i {
  font-size: 24px;
  color: var(--accent-teal);
  opacity: 0.8;
}

.stat-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-label {
  font-size: 11px;
  color: var(--text-tertiary);
  font-weight: 500;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.stat-number {
  font-size: 18px;
  font-weight: 800;
  color: var(--text-primary);
}

.stat-number.status-ok {
  color: var(--accent-teal);
  font-size: 14px;
}

/* Karty mapowań */
.mappings-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 5px;
}

.mapping-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 20px 24px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}


.mapping-card:hover {
  border-color: var(--accent-orange);
  box-shadow: var(--shadow-md);
}

.mapping-card.secondary {
  background: var(--bg-card);
}

/* Dodatkowe style dla nagłówka kluczy przejścia (bez strzałki) */
.mapping-header-labels {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  padding-bottom: 16px;
  gap: 10px;
}



/* Lewa strona karty */
.mapping-card-left {
  flex: 1;
  display: flex;
  justify-content: center;
}

.mapping-old-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}


.mapping-type-badge {
  font-size: 13px;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.mapping-type-badge.old {
  background: rgba(255, 122, 61, 0.15);
  color: var(--accent-orange);
  border: 1px solid rgba(255, 122, 61, 0.3);
}

.mapping-type-badge.new {
  background: rgba(45, 212, 191, 0.15);
  color: var(--accent-teal);
  border: 1px solid rgba(45, 212, 191, 0.3);
}

.mapping-old-value,
.mapping-new-value {
  font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 1px;
  padding: 8px 24px;
  border-radius: 60px;
  display: inline-block;
}

.mapping-old-value {
  background: linear-gradient(135deg, var(--accent-orange), #ff9f6e);
  color: white;
  box-shadow: 0 4px 12px rgba(255, 122, 61, 0.3);
}

.mapping-new-value {
  background: linear-gradient(135deg, var(--accent-teal), #2b9b8a);
  color: white;
  box-shadow: 0 4px 12px rgba(45, 212, 191, 0.3);
}

.mapping-old-desc,
.mapping-new-desc {
  font-size: 11px;
  color: var(--text-tertiary);
  font-weight: 500;
}

/* Strzałka w środku */
.mapping-card-arrow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 0 20px;
  flex-shrink: 0;
}

.arrow-icon {
  width: 48px;
  height: 48px;
  background: var(--bg-elevated);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-subtle);
  transition: all 0.2s ease;
}

.mapping-card:hover .arrow-icon {
  background: var(--accent-teal);
  border-color: var(--accent-teal);
  transform: scale(1.1);
}

.mapping-card:hover .arrow-icon i {
  color: white;
}

.arrow-icon i {
  font-size: 20px;
  color: var(--accent-teal);
  transition: color 0.2s ease;
}

.arrow-label {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
}

/* Prawa strona karty */
.mapping-card-right {
  flex: 1;
  display: flex;
  justify-content: center;
}

.mapping-new-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

/* Stopka z informacją */
.mapping-footer {
  margin-top: 20px;
  padding: 14px 18px;
  background: rgba(45, 212, 191, 0.06);
  border-radius: var(--radius-lg);
  border-left: 3px solid var(--accent-teal);
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--text-tertiary);
  line-height: 1.5;
}

.mapping-footer i {
  font-size: 18px;
  color: var(--accent-teal);
  flex-shrink: 0;
}

/* Responsywność dla kluczy przejścia */
@media (max-width: 900px) {
  .mapping-card {
    flex-direction: column;
    gap: 20px;
    padding: 20px;
  }
  
  .mapping-card-arrow {
    transform: rotate(90deg);
    padding: 10px 0;
  }
  
  .mapping-header {
    flex-direction: column;
    text-align: center;
  }
  
  .mapping-header-left,
  .mapping-header-right {
    justify-content: center;
  }
  
  .mapping-header-center {
    order: -1;
  }
  
  .stat-card {
    min-width: 100%;
  }
  
  .mapping-old-value,
  .mapping-new-value {
    font-size: 22px;
    padding: 6px 18px;
  }
}

@media (max-width: 480px) {
  .mapping-stats {
    flex-direction: column;
  }
  
  .mapping-old-value,
  .mapping-new-value {
    font-size: 18px;
    padding: 5px 14px;
  }
  
  .mapping-card {
    padding: 16px;
  }
}

/* Jasny motyw - dostrojenia */
[data-theme="light"] .stat-card {
  background: white;
}

[data-theme="light"] .mapping-card {
  background: white;
}

[data-theme="light"] .mapping-card.secondary {
  background: #f8f9fa;
}

[data-theme="light"] .arrow-icon {
  background: #f0f2f5;
}

/* Animacja dla nowych elementów */
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mapping-card {
  animation: slideIn 0.3s ease forwards;
}

.mapping-card:nth-child(1) { animation-delay: 0.05s; }
.mapping-card:nth-child(2) { animation-delay: 0.1s; }
.mapping-card:nth-child(3) { animation-delay: 0.15s; }



/* ============================================================
   STYLE DLA STRONY SZCZEGOLY.HTML - UKŁAD JEDNOKOLUMNOWY
   ============================================================ */

/* Przełączenie układu z dwukolumnowego na jednokolumnowy */
.results-body {
  display: block !important;
  grid-template-columns: none !important;
}

/* Ukrycie prawej kolumny (legenda) */
.col-right {
  display: none !important;
}

/* Lewa kolumna zajmuje całą szerokość */
.col-left {
  width: 100%;
  max-width: 100%;
}

/* Wewnętrzne odstępy w kontenerze wyników */
.results-shell-full .results-body {
  padding: clamp(16px, 3vw, 24px);
}

/* Hero na pełnej szerokości */
.hero {
  max-width: 100%;
}

/* Wszystkie karty i panele zajmują pełną szerokość */
.results-card,
.info-panel,
.history-strip,
.full-width-card {
  width: 100%;
}

/* Przycisk powrotu - margines górny */
.btn-show {

}

/* Responsywność dla bardzo małych ekranów */
@media (max-width: 480px) {
  .results-shell-full .results-body {
    padding: clamp(12px, 3vw, 16px);
  }
}



.notification-icon {
  opacity: 0.7;
  cursor: pointer;
}


.error-icon {
  font-size: 48px;
  color: var(--accent-orange);
  margin-bottom: 24px;
}






/* Dodatkowe style dla przycisku historii i modala */

	 .page-body-historii {
		max-width: min(1400px, 100% - 32px);
		margin: 0 auto;
	 }

	 .results-body-historii {
		padding: 0px;
	 }

    .btn-history-custom {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      background: linear-gradient(135deg, var(--accent-teal), #2b9b8a);
      color: white !important;
      border: none;
      border-radius: 40px;
      padding: 8px 20px;
      font-size: 13px;
      font-weight: 600;
      cursor: pointer;
      transition: all 0.2s ease;
      text-decoration: none !important;
      box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    
    .btn-history-custom:hover {
      background: linear-gradient(135deg, var(--accent-orange), #ff9f6e);
      box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
      color: white !important;
    }
    
    .btn-history-custom i {
      font-size: 14px;
    }
    
    /* Poprawka dla modala - zapewnienie prawidłowego zamykania */
    .modal {
      background-color: rgba(0, 0, 0, 0.5);
    }
    
    .modal-backdrop {
      z-index: 1040;
    }
    
    #historyModalIframe {
      z-index: 1050;
    }
    
    /* Style dla przycisku zamykania */
    .btn-close-custom {
      background: var(--bg-elevated);
      border: 1px solid var(--border-subtle);
      border-radius: 50%;
      width: 32px;
      height: 32px;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: all 0.2s ease;
    }
    
    .btn-close-custom:hover {
      background: var(--accent-orange);
      color: white;
      transform: rotate(90deg);
    }
    
    /* Responsywność */
    @media (max-width: 768px) {
      .btn-history-custom {
        padding: 6px 16px;
        font-size: 12px;
      }
    }



/* ============================================================
   PODPARAGRAFY - UKŁAD W JEDNEJ LINII
   ============================================================ */

.subparagraph-grid {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 0px;
}

.subparagraph-tile {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0px;
  border: 1px solid var(--border-subtle);
  border-radius: 15px;
  cursor: default;
}

.subparagraph-code {
  font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
  font-weight: 700;
  font-size: 14px;
  padding: 4px 12px;
  border-radius: 28px;
  background: var(--text-muted);
  color: white;
  white-space: nowrap;
  flex-shrink: 0;
  display: inline-block;
  text-align: center;
}

/* Tryb JASNY */
[data-theme="light"] .subparagraph-code {
  background: var(--text-muted);
  color: white;
}

[data-theme="light"] .subparagraph-tile {
  border-color: #e2e6ea;
}

[data-theme="light"] .subparagraph-tile:hover {
  background: #f8f9fa;
  border-color: #cbd0d6;
}

/* Tryb CIEMNY */
[data-theme="dark"] .subparagraph-code {
  background: var(--bg-hover);
  color: var(--text-secondary);
}

[data-theme="dark"] .subparagraph-tile {
  background: #1a2026;
  border-color: #2a333d;
}

[data-theme="dark"] .subparagraph-tile:hover {
  background: #1f262e;
  border-color: #3a4552;
}

/* Responsywność - na małych ekranach dopuszczamy zawijanie */
@media (max-width: 560px) {
  .subparagraph-tile {
    flex-wrap: wrap;
    gap: 8px;
  }
  
  .subparagraph-code {
    white-space: normal;
    font-size: 12px;
    padding: 3px 10px;
  }
  
  .subparagraph-name {
    font-size: 13px;
  }
}


/* ============================================================
   KLUCZE PRZEJŚCIA - UKŁAD TABELARYCZNY (SYMETRYCZNY)
   ============================================================ */

/* Nagłówek z dwiema kolumnami */
.mapping-header-full {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 5px;
  margin: 0;
  padding: 8px;
  border-bottom: 1px solid var(--border-subtle);
}

.mapping-header-old,
.mapping-header-new {
  flex: 1;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: center;
  padding: 6px 8px;
  border-radius: 24px;
}

/* Tryb JASNY */
[data-theme="light"] .mapping-header-old {
  background: rgba(255, 122, 61, 0.1);
  color: #e8672c;
  border: 1px solid rgba(255, 122, 61, 0.25);
}

[data-theme="light"] .mapping-header-new {
  background: rgba(45, 212, 191, 0.1);
  color: #1aa899;
  border: 1px solid rgba(45, 212, 191, 0.25);
}

/* Tryb Ciemny */
[data-theme="dark"] .mapping-header-old {
  background: linear-gradient(135deg, #b84d24, #963b18);
  color: #f0f0f0;
  border: 1px solid rgba(255, 122, 61, 0.25);
}

[data-theme="dark"] .mapping-header-new {
  background: linear-gradient(135deg, #157a6b, #0f5f53);
  color: #f0f0f0;
  border: 1px solid rgba(45, 212, 191, 0.3);
}



/* Kontener tabeli */
.mapping-table {
  width: 100%;
  display: flex;
  flex-direction: column;
  padding: 8px 0;
}

/* Wiersz tabeli */
.mapping-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

/* Tryb JASNY - hover wiersza */
[data-theme="light"] .mapping-row:hover {
  background: var(--border-subtle);
}

/* Lewa kolumna (stary kod) */
.mapping-old-cell {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 0;
}

/* Prawa kolumna (nowy kod) */
.mapping-new-cell {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 0;
}

/* Strzałka w środku */
.mapping-arrow-cell {
  flex-shrink: 0;
  width: 48px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 18px;
}

/* Tryb CIEMNY - strzałka */
.mapping-arrow-cell {
  color: var(--accent-teal);
}

/* Tryb JASNY - strzałka */
[data-theme="light"] .mapping-arrow-cell {
  color: var(--accent-orange);
}

/* Kody - zawsze dopasowane do treści i wyśrodkowane */
.mapping-old-code,
.mapping-new-code {
  font-family: 'Monaco', 'Menlo', 'Consolas', monospace;
  font-weight: 700;
  font-size: 14px;
  padding: 4px 12px;
  border-radius: 28px;
  text-align: center;
  display: inline-block;
  white-space: nowrap;
  letter-spacing: 0.3px;
}

/* Tryb JASNY - gradienty (żywsze kolory) */
[data-theme="light"] .mapping-old-code {
  background: linear-gradient(135deg, #ff8c42, #ff6a2c);
  color: white;
  box-shadow: 0 1px 3px rgba(255, 122, 61, 0.2);
}

[data-theme="light"] .mapping-new-code {
  background: linear-gradient(135deg, #2dd4bf, #1a9e8c);
  color: white;
  box-shadow: 0 1px 3px rgba(45, 212, 191, 0.2);
}

/* Tryb CIEMNY - alternatywne gradienty (stonowane) */
[data-theme="dark"] .mapping-old-code {
  background: linear-gradient(135deg, #b84d24, #963b18);
  color: #f0f0f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .mapping-new-code {
  background: linear-gradient(135deg, #157a6b, #0f5f53);
  color: #f0f0f0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}


/* ============================================================
   UKRYCIE PANELU GDY BRAK DANYCH
   ============================================================ */
.mapping-panel.hidden,
#kluczePrzejsciaPanel.hidden {
  display: none;
}




/* ============================================================
  SEKCJA WYNIKI DZIAŁU
============================================================ */
/* ============================================================
   METADANE WYNIKÓW (DZIAŁ, ROZDZIAŁ, ILOŚĆ) - NOWA NAZWA KLASY
============================================================ */

/* ========== WSPÓLNE STYLE ========== */
.result-dzial,
.result-rozdzial,
.result-rozdzialy-count {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 2px;
  font-size: 14px;

}

.result-dzial i,
.result-rozdzial i,
.result-rozdzialy-count i {
  font-size: 14px;
  width: 14px;
  text-align: center;
}


.result-dzial .value,
.result-rozdzial .value,
.result-rozdzialy-count .value {
  font-weight: 600;
  font-size: 14px;
  color: var(--accent-teal);
}


.result-dzial {
  color: white;
  font-weight: 600;
}

.result-dzial i {
  color: white;
}

.result-rozdzial {
  color: white;
  font-weight: 600;
}

.result-rozdzial i {
  color: white;
}

.result-rozdzial .value {
  color: var(--accent-teal);
}

.result-rozdzialy-count {
  color: white;
  font-weight: 600;
}

.result-rozdzialy-count i {
  color: white;
}

.result-rozdzialy-count .value {
  color: var(--accent-teal);
}

/* ============================================================
   TRYB JASNY
   ============================================================ */

/* DZIAŁ - jasny */
[data-theme="light"] .result-dzial{
  color: var(--accent-teal);
}

[data-theme="light"] .result-dzial i {
  color: var(--accent-teal);
}

[data-theme="light"] .result-dzial .value {
  color: var(--accent-orange);
}

/* ROZDZIAŁ - jasny */
[data-theme="light"] .result-rozdzial {
  color: var(--accent-teal);
}

[data-theme="light"] .result-rozdzial i {
  color: var(--accent-teal);
}

[data-theme="light"] .result-rozdzial .value {
  color: var(--accent-orange);
}

/* SUMA ROZDZIAŁÓW - jasny */
[data-theme="light"] .result-rozdzialy-count {
  color: var(--accent-teal);
}

[data-theme="light"] .result-rozdzialy-count i {
  color: var(--accent-teal);
}

[data-theme="light"] .result-rozdzialy-count .value {
  color: var(--accent-orange);
}










/* ============================================================
   ZAKŁADKI (TABS) — system nawigacji
   ============================================================ */
.tabs-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0 20px;
  flex-wrap: wrap;
}

.tabs-left {
  display: flex;
  gap: 4px;
}

.tabs-right {
  display: flex;
  gap: 4px;
  margin-right: 150px;
}

.tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-tertiary);
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
}

.tab-btn i {
  font-size: 14px;
}


.tab-btn-right {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-tertiary);
  border: none;
  cursor: pointer;
}

.tab-btn-right:hover {

}
.tab-btn-right.active {
  color: var(--accent-orange);
  border-bottom-color: var(--accent-orange);
}


.tab-btn:hover {
  color: var(--text-primary);
  background: var(--bg-elevated);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
}

.tab-btn.active {
  color: var(--accent-orange);
  border-bottom-color: var(--accent-orange);
}

.tab-btn.active i {
  color: var(--accent-orange);
}

[data-theme="light"] .tab-btn.active {
  color: var(--accent-orange);
  border-bottom-color: var(--accent-orange);
}

.tab-content > .tab-pane {
  display: none;
}

.tab-content > .tab-pane.active {
  display: block;
}


/* ============================================================
   PRZEGLĄDAJ KLASYFIKACJĘ — style z beta.html
   ============================================================ */
.app-window {
  max-width: 1540px;
  margin: 10px auto;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.page-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 14px;
  padding: 14px;
}

@media (max-width: 900px) {
  .page-layout {
    grid-template-columns: 1fr;
  }
}

.main-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.side-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 20px 18px;
  align-self: start;
}

.module-header {
  padding: 22px 24px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.module-title {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -.2px;
  color: var(--text-primary);
  margin: 0;
}

.module-description {
  margin-top: 6px;
  color: var(--text-tertiary);
  line-height: 1.45;
}

.btn-soft {
  height: 38px;
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-secondary);
  border-radius: 20px;
  padding: 0 16px;
  font-weight: 600;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
}

.btn-soft:hover {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.filters-panel {
  padding: 18px 24px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.filters-grid {
  display: grid;
  grid-template-columns: 1.2fr 1.1fr 1fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}

@media (max-width: 900px) {
  .filters-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .filters-grid {
    grid-template-columns: 1fr;
  }
}

.filter-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 15px;
  padding: 13px 14px;
}

.filter-title {
  font-size: 12px;
  color: var(--text-tertiary);
  font-weight: 700;
  margin-bottom: 9px;
}

.segmented-control {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.segment {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  border-radius: 13px;
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  color: var(--text-secondary);
  padding: 5px 10px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.segment.active {
  background: rgba(59, 130, 246, 0.12);
  border-color: var(--accent-blue);
  color: var(--accent-blue);
}

.segment:hover:not(.active) {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.field-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.select-field,
.search-field {
  height: 38px;
  border: 1px solid var(--border-subtle);
  border-radius: 13px;
  padding: 0 12px;
  width: 100%;
  font-weight: 600;
  background: var(--bg-card);
  color: var(--text-primary);
  font-family: 'Outfit', sans-serif;
}

.select-field:focus,
.search-field:focus {
  outline: none;
  border-color: var(--accent-orange);
}

.results-panel {
  padding: 18px 24px 22px;
}

.results-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  flex-wrap: wrap;
  gap: 12px;
}

.table-frame {
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  overflow-x: auto;
  background: var(--bg-card);
}

.table-frame table {
  width: 100%;
  border-collapse: collapse;
  min-width: 700px;
}

.table-frame thead th {
  background: var(--bg-surface);
  color: var(--text-tertiary);
  font-size: 12px;
  padding: 13px 12px;
  border-bottom: 1px solid var(--border-subtle);
  font-weight: 700;
  text-align: left;
}

.table-frame tbody td {
  padding: 10px;
  vertical-align: middle;
}

.table-frame tbody tr:hover td {
  background: var(--bg-elevated);
}

.code-badge-table {
  min-width: 58px;
  height: 38px;
  border-radius: 12px;
  background: rgba(59, 130, 246, 0.12);
  color: var(--accent-blue);
  border: 1px solid rgba(59, 130, 246, 0.2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 800;
  padding: 0 12px;
}

.badge-soft {
  display: inline-flex;
  align-items: center;
  border-radius: 11px;
  padding: 5px 9px;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.badge-attach {
  background: var(--bg-elevated);
  color: var(--text-tertiary);
  border: 1px solid var(--border-subtle);
}

.side-title {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.side-text {
  color: var(--text-tertiary);
  line-height: 1.65;
  font-size: 12px;
  margin-bottom: 16px;
}

.side-note {
  background: rgba(45, 212, 191, 0.08);
  color: var(--accent-teal);
  border-radius: 14px;
  padding: 13px;
  font-size: 11px;
  line-height: 1.55;
  margin-bottom: 18px;
}

.side-section {
  padding-top: 10px;
  margin-top: 10px;
  border-top: 1px solid var(--border-subtle);
}

.odbiorca-disabled {
  opacity: 0.5;
  pointer-events: none;
}

/* summary-row już istnieje w style.css — nie duplikujemy */

/* ============================================================
   POPRAWKA: tab-content wrapper — padding zamiast min-height
   ============================================================ */
.tab-content {
  padding: 0;
}

.tab-content .app-window {
  margin: 10px auto;
}


/* ============================================================
   LOGO - przełączanie między trybami (CSS)
   ============================================================ */
   
.logo {
  display: flex;
  align-items: center;
  gap: clamp(6px, 2vw, 12px);
  flex-shrink: 0;
}

/* Domyślnie (tryb ciemny) - pokaż logo ciemne, ukryj jasne */
.logo-dark {
  display: inline-block;
}

.logo-light {
  display: none;
}

/* Tryb jasny - pokaż logo jasne, ukryj ciemne */
[data-theme="light"] .logo-dark {
  display: none;
}

[data-theme="light"] .logo-light {
  display: inline-block;
}


/* Jeśli obrazy się nie ładują - pokaż tekst */
.logo-dark[src=""]:not([src]), 
.logo-light[src=""]:not([src]) {
  display: none !important;
}








/* ============================================================
   NOWE KLASY DLA PODSTRONY PODGLAD PLIKU
   ============================================================ */
.department-metric {
  margin: 16px 24px 0 24px;
}

.department-metric .metric-content {
  display: flex;
  align-items: center;
  gap: 14px;
}

/* Numer działu */
.department-number-wrap {
  display: flex;
  flex-direction: column;
}

.department-number-wrap .label {
  font-size: 14;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
}

.department-number-wrap .number {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-primary);
}

/* Separator pionowy */
.divider-vertical {
  width: 1px;
  height: 40px;
  background: var(--border-subtle);
}

.department-name-wrap .label {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  font-weight: 600;
}

.department-name-wrap .name {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
}

/* Sekcja komentarza */
.comment-section {
  padding: 16px 24px 24px 24px;
}

/* Treść komentarza */
.comment-body {
  padding: 24px 28px;
  color: var(--text-secondary);
  line-height: 1.8;
  font-size: 15px;
}




/* ============================================================
   Style do podstron historia zmian, instrukcja, licencja
   ============================================================ */
.modal-overlay {
  position:fixed; 
  inset:0; 
  background:rgba(0,0,0,0.6);
  z-index:9998;
}

.modal-box {
  position: fixed;
  top: 50%;
  left: 50%;
  max-width: 1200px;
  min-width: 800px;
  transform: translate(-50%, -50%);
  max-width: 1200px;    
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  
}

.modal-head {
  display:flex; justify-content:space-between; align-items:center;
  padding:16px 24px; background:var(--bg-surface);
  border-bottom:1px solid var(--border-subtle);
  border-radius:var(--radius-2xl) var(--radius-2xl) 0 0;
}
.modal-head span { font-weight:700; font-size:20px; color:var(--text-primary); }
.modal-head button {
  background:var(--bg-elevated); border:1px solid var(--border-subtle);
  border-radius:50%; width:36px; height:36px;
  cursor:pointer; font-size:20px; color:var(--text-secondary);
}
.modal-head button:hover { background:var(--accent-orange); color:white; }
.modal-body {
  padding:24px; overflow-y:auto; flex:1;
  background:var(--bg-deep); max-height:65vh;
}
.modal-foot {
  display:flex; justify-content:flex-end; gap:12px;
  padding:12px 24px; background:var(--bg-surface);
  border-top:1px solid var(--border-subtle);
  border-radius:0 0 var(--radius-2xl) var(--radius-2xl);
}
.modal-foot button {
  padding:8px 20px; border-radius:var(--radius-xl);
  font-weight:600; cursor:pointer; border:none;
  font-family:'Outfit',sans-serif;
}
.modal-foot button:first-child {
  background:var(--bg-elevated); color:var(--text-secondary);
  border:1px solid var(--border-subtle);
}
.modal-foot button:last-child {
  background:var(--accent-orange); color:white;
}
.modal-foot button:last-child:hover { background:#e86a2c; }
.loader { text-align:center; padding:40px; color:var(--text-tertiary); }
.loader i { color:var(--accent-teal); }

/* Ikony w breadcrumb */
.icon-btn.theme-aware {
  color:var(--accent-teal); background:transparent; border:none;
  width:clamp(36px,8vw,42px); height:clamp(36px,8vw,42px);
  border-radius:var(--radius-lg); cursor:pointer;
  transition:all 0.2s ease;
}
.icon-btn.theme-aware:hover {
  background:var(--bg-elevated); color:var(--accent-orange);
  transform:translateY(-1px);
}


/* ============================================================
   Style dla Zobacz informacje o dziale
   ============================================================ */
#departmentInfoLink {
  margin: 12px 0 16px 0;
  display: none;
}

#departmentInfoLink .icon-btn.theme-aware {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 30px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 500;
  width: auto;
  cursor: pointer;
}

.icon-oddk {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: #23cbbb;
  border-radius: 50%;
}


#departmentInfoLink .icon-btn.theme-aware .icon-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--accent-teal);
  border-radius: 50%;
}

#departmentInfoLink .icon-btn.theme-aware .icon-circle i {
  color: white;
  font-size: 14px;
}

#departmentInfoLink .icon-btn.theme-aware .info-text {
  display: flex;
  flex-direction: column;
}

#departmentInfoLink .icon-btn.theme-aware .info-text .label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
}

#departmentInfoLink .icon-btn.theme-aware .arrow-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-elevated);
}

#departmentInfoLink .icon-btn.theme-aware .arrow-circle i {
  font-size: 12px;
  color: var(--text-tertiary);
}


/* Ukryte pola */
.hidden-data-fields {
  display: none;
}
	




/* ============================================================
   STYLE DLA PODSTRONY system.objasnienia.rozporzadzenia.2026.html
   ============================================================ */

/* Source box - pole z rozporządzeniem (zielone tło + lewe podkreślenie) */
.source-box {
  background: linear-gradient(90deg, #e7fbf8, #f5fbfd);
  border-radius: 15px;
  padding: 16px 20px;
  margin-bottom: 22px;
  border-left: 4px solid #23cbbb;
  color: #23344d;
  line-height: 1.62;
}

.source-box strong {
  display: block;
  font-weight: 850;
  margin-bottom: 3px;
  color: #20304a;
}

/* Nowy kontener źródła z etykietą DOTYCHCZASOWA */
.source-box-container {
  background: linear-gradient(90deg, #e7fbf8, #f5fbfd);
  border-left: 4px solid #23cbbb;
  border-radius: 15px;
  padding: 12px 24px 16px;
  margin-bottom: 22px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px;
}

.source-box-text span {
  color: #64748b;
  display: block;
  margin-top: 2px;
}

.source-box-badge {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  padding-top: 10px;
}

.source-box-badge.dotychczasowa span {
  background: #ff7a3d;
  color: white;
  font-weight: 800;
  font-size: 13px;
  padding: 6px 18px;
  border-radius: 40px;
  letter-spacing: 0.5px;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(255, 122, 61, 0.25);
}

.source-box-badge.nowa span {
  background: #22c55e;
  color: white;
  font-weight: 800;
  font-size: 13px;
  padding: 6px 18px;
  border-radius: 40px;
  letter-spacing: 0.5px;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(34, 197, 94, 0.25);
}

.source-box-badge span i {
  font-size: 11px;
  margin-right: 6px;
}

/* Nawigacja zakładek - układ w jednym rzędzie */
.tabs-nav-custom {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  padding: 8px;
  margin: 0 0 16px 0;
  list-style: none;
  background: #f8fafc;
  border-radius: 12px;
  border: 1px solid #e9edf2;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.tabs-nav-custom .nav-item {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
}

.tabs-nav-custom .nav-link-custom {
  width: 100%;
  border: none;
  background: transparent;
  font-weight: 600;
  color: #64748b;
  padding: 10px 14px;
  border-radius: 8px;
  font-family: 'Outfit', sans-serif;
  transition: all 0.2s ease;
  cursor: pointer;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  white-space: nowrap;
  min-height: 64px;
}

.tabs-nav-custom .nav-link-custom i {
  font-size: 16px;
}

.tabs-nav-custom .nav-link-custom span {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.tabs-nav-custom .nav-link-custom small {
  font-size: 14px;
  display: block;
  font-weight: 400;
  color: #94a3b8;
  line-height: 1.2;
  margin-top: 1px;
}

.tabs-nav-custom .nav-link-custom.active {
  background: white;
  color: #ff7a3d;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.tabs-nav-custom .nav-link-custom:not(.active):hover {
  background: #f1f5f9;
  color: #0f172a;
}

/* Treść zakładek */
.tab-pane-wrap {
  background: white;
  border: 1px solid #e9edf2;
  border-radius: 12px;
  padding: 20px 24px;
}

.tab-pane-wrap .content-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  border-bottom: 1px solid #e9edf2;
  padding-bottom: 12px;
}

.tab-pane-wrap .content-title .symbol {
  font-size: 22px;
  font-weight: 800;
  color: #ff7a3d;
}

.tab-pane-wrap .content-title span {
  font-weight: 600;
  color: #0f172a;
  font-size: 15px;
}

.tab-pane-wrap .text-panel {
  color: #334155;
  line-height: 1.7;
  font-size: 14px;
}

.tab-pane-wrap .text-panel h3 {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 10px;
}

/* ===== DODATKOWE STYLE (z pierwszego pliku) ===== */

/* Style dla sekcji informacyjnej w załączniku 2 */
.info-section {
  padding: 20px;
  background: #f8fafc;
  border-radius: 12px;
  margin-bottom: 20px;
}

.info-section:last-child {
  margin-bottom: 0;
}

.info-section h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid #e9edf2;
}

.info-section p {
  font-size: 0.95rem;
  color: #334155;
  line-height: 1.6;
  margin-bottom: 6px;
}

.info-section p strong {
  color: #0f172a;
}

.digit-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.digit-card {
  display: flex;
  gap: 16px;
  background: white;
  padding: 18px 20px;
  border-radius: 10px;
  border: 1px solid #e9edf2;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  transition: box-shadow 0.2s;
}

.digit-card:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.digit-no {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background: #2563eb;
  color: white;
  font-weight: 700;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  margin-top: 2px;
}

.digit-card > div:last-child {
  flex: 1;
}

.digit-card strong {
  font-size: 0.95rem;
  color: #0f172a;
  margin-bottom: 8px;
}

.digit-card p {
  font-size: 0.9rem;
  color: #334155;
  line-height: 1.6;
  margin-bottom: 8px;
}

.digit-card p:last-child {
  margin-bottom: 0;
}

/* Style dla tabeli */
.table-wrap {
  overflow-x: auto;
  margin: 16px 0 20px 0;
  border-radius: 10px;
  border: 1px solid #e9edf2;
  background: white;
}

.mock-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  min-width: 700px;
}

.mock-table thead {
  background: #f1f5f9;
}

.mock-table thead th {
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
  color: #0f172a;
  border-bottom: 2px solid #e2e8f0;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.mock-table tbody td {
  padding: 10px 16px;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
  vertical-align: middle;
}

.mock-table tbody tr:last-child td {
  border-bottom: none;
}

.mock-table .group-row {
  background: #e7fbf8;
  font-weight: 600;
}

.mock-table .group-row td {
  font-size: 15px;
  color: #0b8178;
}

.mock-table .sub-row td {
  padding-left: 32px;
  font-size: 14px;
}

.mock-table .sub-row .num-cell {
  text-align: center;
  font-weight: 600;
}

.mock-table .num-cell {
  text-align: center;
  font-weight: 850;
  color: #0a2b43;
  white-space: nowrap;
}

.mock-table .range-cell {
  font-weight: 500;
  color: #0f172a;
  white-space: nowrap;
}




.info-box {
  background: #f8fafc;
  border-left: 4px solid #2563eb;
  padding: 1rem 1.25rem;
  margin-top: 1.25rem;
  border-radius: 0 8px 8px 0;
}

.info-box p {
  margin-bottom: 0.4rem;
}

.info-box i {
  color: #2563eb;
  margin-right: 0.5rem;
}

.note-box{
  border-left:4px solid #3b78ff;
  background:#f4f8ff;
  padding:12px 14px;
  margin:10px 0;
  color:#253854
 }
 
 
 
 
 
 
 /* ============================================================
   STYLE DLA FORMULARZA KONTAKTOWEGO (zakładka Uwagi)
   ============================================================ */

/* Kompaktowy nagłówek */
.page-header-compact {
  background: var(--bg-surface);
  border-radius: var(--radius-2xl);
  padding: 18px 28px;
  margin-bottom: 18px;
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.page-header-compact .header-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, rgba(255,122,61,0.15), rgba(255,122,61,0.05));
  border-radius: var(--radius-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.page-header-compact .header-icon i {
  font-size: 24px;
  color: var(--accent-orange);
}

.page-header-compact .header-text h1 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  line-height: 1.2;
}

.page-header-compact .header-text p {
  font-size: 13px;
  color: var(--text-tertiary);
  margin: 2px 0 0 0;
  line-height: 1.4;
}

/* Kompaktowy formularz */
.form-card-compact .form-card-body {
  padding: 18px 22px 22px 22px;
}

.form-card-compact .form-group {
  margin-bottom: 10px;
  gap: 4px;
}

.form-card-compact .form-label {
  font-size: 11px;
  letter-spacing: 0.3px;
  font-weight: 600;
}

.form-card-compact .form-label i {
  font-size: 11px;
}

.form-card-compact .form-control {
  padding: 9px 14px;
  font-size: 13px;
  border-radius: var(--radius-lg);
}

.form-card-compact textarea.form-control {
  min-height: 90px;
}

.form-card-compact .form-row-compact {
  display: flex;
  gap: 10px;
}

.form-card-compact .form-row-compact .form-group {
  flex: 1;
  min-width: 0;
}

.form-card-compact .recaptcha-wrapper {
  margin: 10px 0 8px 0;
}

.form-card-compact .form-footer {
  margin: 8px 0 0 0;
}

.form-card-compact .form-footer .btn {
  padding: 10px 28px;
  font-size: 13px;
}

.form-card-compact .form-card-header {
  padding: 12px 22px;
}

.form-card-compact .form-card-header h2 {
  font-size: 17px;
}

.form-card-compact .form-card-header p {
  font-size: 12px;
}

.form-card-compact .char-counter {
  font-size: 10px;
  margin-top: 2px;
}

.form-card-compact .form-alert {
  padding: 10px 16px;
  font-size: 13px;
  margin-bottom: 12px;
}

.form-card-compact .form-alert i {
  font-size: 16px !important;
}

/* Alerty */
.form-alert {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
}

.form-alert i {
  font-size: 20px;
  flex-shrink: 0;
}

.form-alert.show {
  display: flex;
}

.form-alert-success {
  background: rgba(45, 212, 191, 0.12);
  border: 1px solid rgba(45, 212, 191, 0.3);
  color: var(--accent-teal);
}

.form-alert-success i {
  color: var(--accent-teal);
}

.form-alert-error {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: var(--accent-red);
}

.form-alert-error i {
  color: var(--accent-red);
}

/* Formularz */
.form-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: hidden;
}

.form-card-body {
  padding: 24px 28px 28px 28px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

.form-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  letter-spacing: 0.3px;
}

.form-label .required {
  color: var(--accent-orange);
  margin-left: 2px;
}

.form-control {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  color: var(--text-primary);
  padding: 10px 16px;
  font-size: 14px;
  font-family: 'Outfit', sans-serif;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-orange);
  box-shadow: 0 0 0 3px rgba(255, 122, 61, 0.12);
}

.form-control::placeholder {
  color: var(--text-muted);
}

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
  cursor: pointer;
}

.form-select option {
  background: var(--bg-surface);
  color: var(--text-primary);
}

.char-counter {
  text-align: right;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
  transition: color 0.2s;
}

.char-counter.warn {
  color: var(--accent-yellow);
}

.char-counter.over {
  color: var(--accent-red);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-orange), #ff9f6e);
  color: white;
  border: none;
  border-radius: var(--radius-xl);
  padding: 12px 32px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: all 0.2s ease;
  font-family: 'Outfit', sans-serif;
}

.btn-primary:hover:not(:disabled) {
  background: linear-gradient(135deg, #e86a2c, #ff7a3d);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(255, 122, 61, 0.3);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-primary i {
  font-size: 14px;
}

.recaptcha-wrapper {
  margin: 14px 0 10px 0;
}

@media (max-width: 480px) {
  .page-header-compact {
    padding: 14px 16px;
    gap: 12px;
  }
  .page-header-compact .header-icon {
    width: 40px;
    height: 40px;
  }
  .page-header-compact .header-icon i {
    font-size: 18px;
  }
  .page-header-compact .header-text h1 {
    font-size: 17px;
  }
  .page-header-compact .header-text p {
    font-size: 12px;
  }
  .form-card-compact .form-card-body {
    padding: 14px 14px 18px 14px;
  }
  .form-card-compact .form-row-compact {
    flex-direction: column;
    gap: 0;
  }
  .form-card-compact .form-control {
    padding: 8px 12px;
    font-size: 12px;
  }
}
 