:root {
  --green-primary: #3b9471;
  --green-light: #52b78e;
  --green-dark: #1f4e3d;
  --text-dark: #111111;
  --text-white: #ffffff;
  --font-main: 'Open Sans', system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { overflow-x: hidden; }
body { font-family: var(--font-main); color: var(--text-dark); background-color: #ffffff; display: flex; flex-direction: column; min-height: 100vh; }
main#site-content { flex: 1; }
.container { max-width: 1240px; margin: 0 auto; padding: 0 20px; }
.skip-link { position: absolute; top: -100px; left: 16px; background: var(--green-dark); color: #fff; padding: 10px 18px; border-radius: 0 0 8px 8px; text-decoration: none; font-weight: 700; font-size: 14px; z-index: 10000; transition: top 0.2s ease; }
.skip-link:focus { top: 0; }

/* TOPBAR */
.topbar { background: linear-gradient(180deg, #57b992 0%, #3b9471 100%); color: var(--text-white); font-size: 14px; padding: 9px 0; }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.topbar-left, .topbar-right { display: flex; align-items: center; gap: 24px; }
.topbar a { color: var(--text-white); text-decoration: none; display: inline-flex; align-items: center; gap: 7px; font-weight: 500; transition: opacity 0.2s ease; }
.topbar a:hover { opacity: 0.85; }
.topbar-icon { width: 16px; height: 16px; flex-shrink: 0; display: block; opacity: 0.95; }
.topbar-theme-toggle { appearance: none; background: rgba(255, 255, 255, 0.16); border: 1px solid rgba(255, 255, 255, 0.34); color: var(--text-white); font-family: inherit; font-size: 13px; font-weight: 600; padding: 3px 11px; border-radius: 999px; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; white-space: nowrap; transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease; }
.topbar-theme-toggle:hover { background: rgba(255, 255, 255, 0.26); border-color: rgba(255, 255, 255, 0.55); transform: translateY(-1px); }
.topbar-theme-toggle:hover .theme-icon { transform: rotate(-12deg) scale(1.06); }

/* HEADER & NAWIGACJA */
.main-header { background-color: #ffffff; padding: 12px 0; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05); position: relative; z-index: 100; transition: background-color 0.25s ease, box-shadow 0.25s ease; }
.header-inner { display: flex; justify-content: flex-start; align-items: center; flex-wrap: nowrap; gap: clamp(18px, 2.4vw, 34px); }
.brand-logo { order: 1; display: inline-flex; align-items: center; flex-shrink: 0; }
.brand-logo img { height: clamp(52px, 4.8vw, 66px); width: auto; display: block; transition: filter 0.25s ease; }
.header-tools { order: 3; display: none; align-items: center; gap: 10px; }
.theme-toggle { appearance: none; display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 40px; padding: 0 14px; background: #f2f9f5; color: var(--green-dark); border: 1px solid #d4e8de; border-radius: 999px; font-family: inherit; font-size: 13px; font-weight: 700; cursor: pointer; white-space: nowrap; transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.15s ease; }
.theme-toggle:hover { background: #e3f3ec; border-color: var(--green-primary); color: var(--green-primary); transform: translateY(-1px); }
.theme-icon { flex-shrink: 0; display: block; transition: transform 0.25s ease; }
.theme-toggle:hover .theme-icon { transform: rotate(-12deg) scale(1.06); }
.theme-icon-sun { display: none; color: #fbbf24; }
html[data-theme="dark"] .theme-icon-moon { display: none; }
html[data-theme="dark"] .theme-icon-sun { display: block; }
.nav-toggle { display: none; flex-direction: column; justify-content: center; align-items: center; gap: 5px; width: 44px; height: 44px; background: #f2f9f5; border: 1px solid #d4e8de; border-radius: 10px; cursor: pointer; padding: 0; transition: background 0.2s ease, border-color 0.2s ease; }
.nav-toggle:hover { background: #e3f3ec; border-color: var(--green-primary); }
.nav-toggle-bar { display: block; width: 22px; height: 2.5px; background-color: var(--green-dark); border-radius: 2px; transition: transform 0.25s ease, opacity 0.2s ease; }
.nav-toggle.is-open .nav-toggle-bar:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle.is-open .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle.is-open .nav-toggle-bar:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
.main-nav { order: 2; margin-left: 0; }
.main-nav > ul { list-style: none; display: flex; align-items: center; gap: clamp(12px, 1.5vw, 22px); flex-wrap: nowrap; }
.main-nav li { position: relative; }
.main-nav a { text-decoration: none; color: var(--text-dark); font-size: clamp(14px, 1.15vw, 15.5px); font-weight: 500; padding: 8px 0; display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; transition: color 0.2s ease; }
.main-nav a.active { color: var(--green-primary); border-bottom: 2px solid var(--green-primary); }
.main-nav a:hover:not(.btn-contact) { color: var(--green-primary); }
.main-nav a.btn-contact { background-color: var(--green-primary); color: var(--text-white); padding: 9px 20px; border-radius: 6px; box-shadow: 0 3px 6px rgba(0, 0, 0, 0.16); border-bottom: none; transition: background-color 0.2s ease, transform 0.15s ease; }
.main-nav a.btn-contact:hover { background-color: #2f7a5c; transform: translateY(-1px); }
.chevron { display: inline-block; transition: transform 0.2s ease; font-size: 13px; }
.has-dropdown.dropdown-open > a .chevron { transform: rotate(180deg); }

/* DROPDOWN */
.dropdown-menu { position: absolute; top: 100%; left: 0; background: #ffffff; min-width: 220px; list-style: none; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12); border-radius: 6px; padding: 8px 0; opacity: 0; visibility: hidden; transform: translateY(8px); transition: all 0.2s ease; z-index: 200; }
.has-dropdown:hover .dropdown-menu,
.has-dropdown.dropdown-open .dropdown-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown-menu li a { padding: 10px 18px; display: block; font-size: 14px; white-space: nowrap; }

/* PASEK WAŻNEGO KOMUNIKATU (ALERT BAR) */
.site-alert-bar { padding: 11px 0; color: #ffffff; font-size: 14.5px; border-bottom: 1px solid rgba(255, 255, 255, 0.18); position: relative; z-index: 90; transition: opacity 0.25s ease, transform 0.25s ease; }
.site-alert-bar.is-dismissing { opacity: 0; transform: translateY(-10px); pointer-events: none; }
.site-alert-bar.alert-style-green { background: linear-gradient(90deg, #1b4334 0%, #2a6a50 100%); }
.site-alert-bar.alert-style-amber { background: linear-gradient(90deg, #92400e 0%, #d97706 100%); }
.site-alert-bar.alert-style-navy { background: linear-gradient(90deg, #1e3a8a 0%, #2563eb 100%); }
.site-alert-bar.alert-style-crimson { background: linear-gradient(90deg, #881337 0%, #dc2626 100%); }
.site-alert-inner { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; }
.site-alert-text { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-weight: 500; line-height: 1.45; flex: 1 1 320px; }
.site-alert-icon { width: 26px; height: 26px; border-radius: 50%; background: rgba(255, 255, 255, 0.18); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.site-alert-icon svg { width: 15px; height: 15px; display: block; }
.site-alert-badge { display: inline-flex; align-items: center; gap: 6px; background: rgba(255, 255, 255, 0.22); border: 1px solid rgba(255, 255, 255, 0.3); color: #ffffff; font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.5px; padding: 3px 10px; border-radius: 20px; white-space: nowrap; }
.site-alert-pulse-dot { width: 7px; height: 7px; border-radius: 50%; background: #ffffff; display: inline-block; animation: slo-alert-pulse 1.8s infinite ease-in-out; }
@keyframes slo-alert-pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.45; transform: scale(0.8); } }
.site-alert-msg { color: #ffffff; }
.site-alert-countdown { display: inline-flex; align-items: center; gap: 5px; background: rgba(0, 0, 0, 0.24); border: 1px solid rgba(255, 255, 255, 0.25); padding: 2px 10px; border-radius: 20px; font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.site-alert-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.site-alert-link { display: inline-flex; align-items: center; gap: 6px; color: #ffffff; font-weight: 700; font-size: 13.5px; text-decoration: none; background: rgba(255, 255, 255, 0.16); border: 1px solid rgba(255, 255, 255, 0.32); padding: 5px 14px; border-radius: 20px; white-space: nowrap; transition: background 0.2s ease, transform 0.15s ease; }
.site-alert-link:hover { background: rgba(255, 255, 255, 0.28); transform: translateY(-1px); }
.site-alert-close { background: rgba(255, 255, 255, 0.12); border: 1px solid rgba(255, 255, 255, 0.24); color: #ffffff; width: 28px; height: 28px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; transition: background 0.2s ease, transform 0.15s ease; }
.site-alert-close:hover { background: rgba(255, 255, 255, 0.28); transform: scale(1.06); }

/* HERO SECTION */
.hero { position: relative; min-height: 480px; background-color: #1f4e3d; display: flex; align-items: center; overflow: hidden; }
.hero::before { content: ''; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, rgba(24, 62, 43, 0.88) 0%, rgba(46, 98, 63, 0.72) 55%, rgba(72, 118, 52, 0.65) 100%); mix-blend-mode: multiply; }
.hero-overlay-tint { position: absolute; inset: 0; z-index: 1; background: rgba(38, 89, 60, 0.35); }
/* Tło hero: statyczne zdjęcie (fallback) + płótno WebGL z morphingiem twarzy (assets/js/site.js) */
.hero-slide { position: absolute; inset: 0; z-index: 0; background: url('../img/hero-tischner.jpg') no-repeat 70% 20% / cover; }
.hero-morph { position: absolute; inset: 0; z-index: 0; display: block; width: 100%; height: 100%; opacity: 0; transition: opacity 0.6s ease; }
.hero-morph.is-ready { opacity: 1; }
/* Tytuł przesunięty w lewo, aby nie zasłaniał twarzy na żadnym zdjęciu */
.hero > .container { max-width: none; width: 100%; margin: 0; padding-left: clamp(20px, 4vw, 64px); }
.hero-content { position: relative; z-index: 2; color: var(--text-white); max-width: 680px; padding-top: 60px; padding-bottom: 60px; }
.hero-content h1 { font-size: 46px; font-weight: 700; line-height: 1.22; margin-bottom: 18px; letter-spacing: -0.5px; }
.hero-content p { font-size: 26px; font-weight: 400; opacity: 0.95; }

/* PODSTRONY I KAFELKI */
.subpage-banner { background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-primary) 100%); color: var(--text-white); padding: 34px 0; margin-bottom: 40px; position: relative; overflow: hidden; }
.subpage-banner-inner { display: flex; align-items: center; justify-content: space-between; gap: 36px; }
.subpage-banner-head { flex: 1 1 360px; min-width: 260px; }
.subpage-banner h1 { font-size: 34px; margin-bottom: 8px; line-height: 1.22; }
.breadcrumbs { font-size: 14px; opacity: 0.9; }
.breadcrumbs a { color: var(--text-white); text-decoration: underline; }

/* Rotator cytatów ks. prof. Józefa Tischnera po prawej stronie zielonego banera podstron */
.subpage-banner-quote { flex: 0 1 620px; max-width: 620px; margin-left: auto; }
.subpage-quote-card {
  display: flex;
  align-items: center;
  gap: 15px;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-left: 3px solid rgba(255, 255, 255, 0.65);
  border-radius: 12px;
  padding: 12px 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: opacity 0.34s ease, transform 0.34s ease, background-color 0.25s ease;
}
.subpage-quote-card:hover {
  background: rgba(255, 255, 255, 0.125);
}
.subpage-quote-card.is-switching {
  opacity: 0;
  transform: translateY(4px);
}
.subpage-quote-cover-wrap {
  flex: 0 0 58px;
  width: 58px;
  height: 82px;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(10, 35, 26, 0.5);
}
.subpage-quote-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.subpage-quote-content {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.subpage-banner blockquote.subpage-quote-text {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  margin: 0;
  color: #ffffff;
  font-size: 13.8px;
  line-height: 1.46;
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0.01em;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.subpage-banner blockquote.subpage-quote-text.is-long {
  font-size: 12.6px;
  line-height: 1.42;
  -webkit-line-clamp: 5;
}
.subpage-quote-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 2px;
}
.subpage-quote-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  font-size: 11.8px;
  color: rgba(255, 255, 255, 0.88);
  min-width: 0;
}
.subpage-quote-author {
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
}
.subpage-quote-source {
  font-style: normal;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.16);
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.92);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 310px;
}
.subpage-quote-source.is-hidden {
  display: none;
}
.subpage-quote-next {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.92);
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.25s ease, border-color 0.2s ease;
}
.subpage-quote-next:hover,
.subpage-quote-next:focus-visible {
  background: rgba(255, 255, 255, 0.24);
  border-color: rgba(255, 255, 255, 0.5);
  transform: rotate(90deg);
  outline: none;
}
.page-content { max-width: 1240px; margin: 0 auto 60px; padding: 0 20px; line-height: 1.7; }
.info-block { margin-bottom: 36px; }
.info-block h2 { color: var(--green-primary); font-size: 24px; margin-bottom: 14px; border-bottom: 2px solid #eef5f2; padding-bottom: 8px; }
.info-block h3 { color: var(--green-dark); font-size: 19px; margin: 18px 0 8px; }
.info-block p { margin-bottom: 14px; }
.info-block ul, .info-block ol { padding-left: 22px; margin-bottom: 16px; }
.info-block li { margin-bottom: 8px; }
blockquote { background: #f4faf7; border-left: 4px solid var(--green-primary); padding: 18px 24px; margin: 20px 0; font-style: italic; border-radius: 0 8px 8px 0; }

.quick-links-section { margin-top: -55px; position: relative; z-index: 10; margin-bottom: 65px; }
.quick-links-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 24px; }
.quick-card { background: #ffffff; padding: 28px; border-radius: 10px; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12); text-decoration: none; color: var(--text-dark); border-bottom: 4px solid var(--green-primary); transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease; }
.quick-card:hover { transform: translateY(-6px) scale(1.015); box-shadow: 0 16px 34px rgba(0, 0, 0, 0.18); }
.quick-card-icon { font-size: 32px; margin-bottom: 12px; }
.quick-card h3 { color: var(--green-primary); margin-bottom: 8px; font-size: 20px; }

.quick-card-photo { position: relative; min-height: 220px; background-size: cover; background-position: center; overflow: hidden; display: flex; align-items: flex-end; color: #ffffff; border-bottom: 4px solid var(--green-light); }
.quick-card-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 52, 39, 0.35) 0%, rgba(20, 52, 39, 0.88) 100%); transition: background 0.3s ease; }
.quick-card-photo:hover .quick-card-overlay { background: linear-gradient(180deg, rgba(31, 78, 61, 0.25) 0%, rgba(20, 52, 39, 0.94) 100%); }
.quick-card-content { position: relative; z-index: 2; width: 100%; }
.quick-card-photo h3 { color: #ffffff; font-size: 24px; font-weight: 700; margin-bottom: 6px; text-shadow: 0 2px 6px rgba(0, 0, 0, 0.35); }
.quick-card-photo p { color: rgba(255, 255, 255, 0.92); font-size: 14px; line-height: 1.45; }

.home-news-section { margin-bottom: 70px; }
.section-heading { text-align: center; margin-bottom: 36px; }
.section-heading h2 { font-size: 32px; color: var(--text-dark); display: inline-block; border-bottom: 3px solid var(--green-primary); padding-bottom: 8px; }
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 28px; margin-bottom: 40px; }
.news-card { background: #ffffff; border-radius: 8px; overflow: hidden; box-shadow: 0 4px 16px rgba(0, 0, 0, 0.07); display: flex; flex-direction: column; }
.news-card-thumb { display: block; height: 200px; overflow: hidden; background: #e9f2ee; text-decoration: none; }
.news-card-thumb.placeholder-thumb { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #2b6e54, #3b9471); color: #ffffff; font-weight: 700; font-size: 20px; letter-spacing: 0.5px; }
.news-card-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; }
.news-card:hover .news-card-thumb img { transform: scale(1.04); }
.news-card-body { padding: 20px; display: flex; flex-direction: column; flex: 1; }
.news-date { font-size: 13px; color: #666; margin-bottom: 6px; display: block; }
.news-card-body h3, .news-card-body h2 { font-size: 19px; margin-bottom: 10px; line-height: 1.35; }
.news-card-body h3 a, .news-card-body h2 a { color: var(--text-dark); text-decoration: none; }
.news-card-body h3 a:hover, .news-card-body h2 a:hover { color: var(--green-primary); }
.news-card-body p { font-size: 14px; color: #444; margin-bottom: 16px; flex: 1; }
.read-more { color: var(--green-primary); font-weight: 600; text-decoration: none; font-size: 14px; }
.section-cta { text-align: center; margin-top: 10px; }
.btn-primary { display: inline-block; background: var(--green-primary); color: #ffffff; padding: 12px 28px; border-radius: 6px; text-decoration: none; font-weight: 600; border: none; cursor: pointer; transition: background 0.2s ease; }
.btn-primary:hover { background: var(--green-dark); }

/* PAGINACJA I POJEDYNCZY WPIS */
.pagination { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 32px; }
.pagination a { display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 6px; background: #f0f5f2; color: var(--text-dark); text-decoration: none; font-weight: 600; transition: all 0.2s ease; }
.pagination a.active, .pagination a:hover { background: var(--green-primary); color: #ffffff; }
.post-header { margin-bottom: 24px; padding-bottom: 16px; border-bottom: 2px solid #eef5f2; }
.post-header h1 { font-size: 32px; color: var(--green-dark); margin-bottom: 8px; }
.post-content p { margin-bottom: 16px; }
.post-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 16px 0; }

/* PODSTRONA GALERIA – CENTRUM FOTOGRAFICZNE */
.gallery-intro { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 20px; margin-bottom: 28px; padding-bottom: 18px; border-bottom: 2px solid #eef5f2; }
.gallery-intro h2 { color: var(--green-primary); font-size: 26px; margin-bottom: 6px; }
.gallery-intro p { color: #555; font-size: 15px; max-width: 680px; }
.gallery-stats { display: flex; flex-wrap: wrap; gap: 12px; }
.stat-pill { background: #f0f7f4; border: 1px solid #d5eadd; color: var(--green-dark); padding: 8px 16px; border-radius: 30px; font-size: 14px; }
.stat-pill strong { color: var(--green-primary); font-size: 16px; }

.gallery-filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 32px; }
.filter-btn { background: #f3f7f5; color: var(--text-dark); border: 1px solid #dcebe3; padding: 10px 18px; border-radius: 30px; font-size: 14px; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; transition: all 0.2s ease; font-family: inherit; }
.filter-btn:hover { border-color: var(--green-primary); color: var(--green-primary); }
.filter-btn.active { background: var(--green-primary); color: #ffffff; border-color: var(--green-primary); box-shadow: 0 4px 12px rgba(59, 148, 113, 0.25); }
.filter-count { background: rgba(0, 0, 0, 0.08); padding: 2px 8px; border-radius: 20px; font-size: 12px; }
.filter-btn.active .filter-count { background: rgba(255, 255, 255, 0.22); color: #fff; }

.albums-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 28px; margin-bottom: 60px; }
.album-card { background: #ffffff; border-radius: 12px; overflow: hidden; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.07); border: 1px solid #edf3f0; display: flex; flex-direction: column; transition: transform 0.25s ease, box-shadow 0.25s ease; }
.album-card:hover { transform: translateY(-5px); box-shadow: 0 14px 30px rgba(0, 0, 0, 0.12); }

.album-cover { position: relative; height: 220px; overflow: hidden; cursor: pointer; background: #dfeee7; }
.album-main-img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.4s ease; }
.album-cover:hover .album-main-img { transform: scale(1.06); }
.album-badge { position: absolute; top: 12px; right: 12px; background: rgba(20, 52, 39, 0.86); backdrop-filter: blur(4px); color: #fff; padding: 5px 12px; border-radius: 20px; font-size: 12px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; z-index: 2; }
.album-hover-overlay { position: absolute; inset: 0; background: rgba(20, 52, 39, 0.48); display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.25s ease; }
.album-cover:hover .album-hover-overlay { opacity: 1; }
.album-play-btn { background: var(--green-primary); color: #fff; padding: 10px 20px; border-radius: 30px; font-weight: 600; font-size: 14px; display: inline-flex; align-items: center; gap: 8px; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3); transform: translateY(6px); transition: transform 0.25s ease; }
.album-cover:hover .album-play-btn { transform: translateY(0); }

.album-mini-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 4px 4px 0; background: #f8fbf9; }
.album-mini-thumb { height: 54px; border: none; padding: 0; border-radius: 4px; overflow: hidden; cursor: pointer; background: #e2eee8; }
.album-mini-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: opacity 0.2s ease, transform 0.2s ease; }
.album-mini-thumb:hover img { transform: scale(1.08); opacity: 0.9; }
.album-mini-more { height: 54px; border: none; border-radius: 4px; background: #e6f2ec; color: var(--green-dark); font-weight: 700; font-size: 13px; cursor: pointer; transition: background 0.2s ease, color 0.2s ease; }
.album-mini-more:hover { background: var(--green-primary); color: #fff; }

.album-body { padding: 16px 20px 18px; display: flex; flex-direction: column; flex: 1; }
.album-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; font-size: 12px; color: #666; }
.album-year-tag { background: #eef6f2; color: var(--green-dark); padding: 2px 8px; border-radius: 4px; font-weight: 600; }
.album-title { font-size: 18px; margin-bottom: 14px; line-height: 1.35; flex: 1; }
.album-title-btn { background: none; border: none; padding: 0; text-align: left; font-family: inherit; font-size: inherit; font-weight: 700; color: var(--text-dark); cursor: pointer; transition: color 0.2s ease; }
.album-title-btn:hover { color: var(--green-primary); }
.album-footer { display: flex; justify-content: space-between; align-items: center; padding-top: 12px; border-top: 1px solid #eef5f2; }
.album-open-link { background: none; border: none; padding: 0; color: var(--green-primary); font-weight: 600; font-size: 13px; cursor: pointer; font-family: inherit; }
.album-open-link:hover { text-decoration: underline; }
.album-article-link { color: #666; font-size: 13px; text-decoration: none; font-weight: 500; }
.album-article-link:hover { color: var(--green-primary); }
.slo-lb-article-btn { background: rgba(255, 255, 255, 0.14); color: #fff; text-decoration: none; padding: 8px 14px; border-radius: 20px; font-size: 13px; font-weight: 600; transition: background 0.2s ease; }
.slo-lb-article-btn:hover { background: var(--green-primary); }

.gallery-preview-grid, .post-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; margin: 24px 0 50px; }
.gallery-preview-card, .gallery-item { position: relative; height: 220px; border-radius: 10px; overflow: hidden; display: block; background: #dfeee7; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08); }
.gallery-preview-card img, .gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.35s ease; }
.gallery-preview-card:hover img, .gallery-item:hover img { transform: scale(1.06); }
.gallery-preview-caption { position: absolute; inset: auto 0 0 0; background: linear-gradient(transparent, rgba(0, 0, 0, 0.82)); color: #fff; padding: 28px 16px 14px; font-size: 15px; font-weight: 600; }

/* HOVER KAFELKÓW W GALERII ARTYKUŁU */
.post-featured-wrapper { margin-bottom: 28px; position: relative; border-radius: 12px; overflow: hidden; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.1); }
.post-featured-link { display: block; position: relative; max-height: 480px; overflow: hidden; }
.post-featured-link img { width: 100%; max-height: 480px; object-fit: cover; display: block; transition: transform 0.4s ease; }
.post-featured-link:hover img { transform: scale(1.02); }
.zoom-badge { position: absolute; right: 16px; bottom: 16px; background: rgba(20, 52, 39, 0.85); backdrop-filter: blur(6px); color: #fff; padding: 8px 16px; border-radius: 30px; font-size: 13px; font-weight: 600; display: inline-flex; align-items: center; gap: 7px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25); transition: background 0.2s ease, transform 0.2s ease; }
.post-featured-link:hover .zoom-badge { background: var(--green-primary); transform: translateY(-2px); }

.gallery-header-row { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; border-bottom: 2px solid #eef5f2; padding-bottom: 10px; margin-bottom: 20px; }
.gallery-header-row h2 { border-bottom: none; padding-bottom: 0; margin-bottom: 0; }
.btn-slideshow { display: inline-flex; align-items: center; gap: 8px; background: var(--green-primary); color: #fff; border: none; padding: 9px 18px; border-radius: 6px; font-size: 14px; font-weight: 600; cursor: pointer; transition: background 0.2s ease, transform 0.15s ease; }
.btn-slideshow:hover { background: var(--green-dark); transform: translateY(-1px); }

.gallery-item-hover { position: absolute; inset: 0; background: rgba(20, 52, 39, 0.55); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; opacity: 0; transition: opacity 0.25s ease; font-size: 13px; font-weight: 600; }
.gallery-item:hover .gallery-item-hover { opacity: 1; }

/* NOWOCZESNY LIGHTBOX GALERII */
.slo-lightbox[hidden] { display: none !important; }
.slo-lightbox { position: fixed; inset: 0; z-index: 9999; display: flex; flex-direction: column; justify-content: space-between; user-select: none; }
.slo-lb-backdrop { position: absolute; inset: 0; background: rgba(12, 20, 17, 0.94); backdrop-filter: blur(10px); }
.slo-lb-progress-track { position: absolute; top: 0; left: 0; right: 0; height: 4px; background: rgba(255, 255, 255, 0.12); z-index: 5; overflow: hidden; }
.slo-lb-progress-bar { height: 100%; width: 0%; background: linear-gradient(90deg, var(--green-primary), var(--green-light)); transition: width 0.1s linear; }
.slo-lb-topbar { position: relative; z-index: 3; display: flex; justify-content: space-between; align-items: center; padding: 16px 24px 14px; color: #fff; background: linear-gradient(180deg, rgba(0, 0, 0, 0.65) 0%, transparent 100%); }
.slo-lb-counter { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.slo-lb-title { margin-left: 14px; padding-left: 14px; border-left: 1px solid rgba(255, 255, 255, 0.25); font-weight: 400; color: rgba(255, 255, 255, 0.85); font-size: 14px; max-width: 50vw; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.slo-lb-actions { display: flex; align-items: center; gap: 10px; }
.slo-lb-icon-btn { background: rgba(255, 255, 255, 0.12); color: #fff; border: none; width: 42px; height: 42px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; transition: background 0.2s ease, transform 0.15s ease; }
.slo-lb-icon-btn:hover, .slo-lb-icon-btn.is-playing { background: var(--green-primary); transform: scale(1.06); }

.slo-lb-stage { position: relative; z-index: 2; flex: 1; display: flex; align-items: center; justify-content: center; padding: 10px 80px; overflow: hidden; }
.slo-lb-stage img { max-width: 100%; max-height: calc(100vh - 175px); object-fit: contain; border-radius: 6px; box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55); transition: transform 0.28s ease, opacity 0.18s ease; cursor: zoom-in; }
.slo-lb-stage img.is-switching { opacity: 0.25; transform: scale(0.98); }
.slo-lb-stage img.is-zoomed { transform: scale(1.65); cursor: zoom-out; }

.slo-lb-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 4; background: rgba(255, 255, 255, 0.14); color: #fff; border: none; width: 52px; height: 52px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: background 0.2s ease, transform 0.2s ease; }
.slo-lb-nav:hover { background: var(--green-primary); transform: translateY(-50%) scale(1.08); }
.slo-lb-prev { left: 22px; }
.slo-lb-next { right: 22px; }

.slo-lb-thumbs-bar { position: relative; z-index: 3; background: rgba(10, 16, 14, 0.85); padding: 12px 20px; border-top: 1px solid rgba(255, 255, 255, 0.1); }
.slo-lb-thumbs { display: flex; gap: 10px; overflow-x: auto; max-width: 1100px; margin: 0 auto; padding-bottom: 4px; scrollbar-width: thin; scrollbar-color: var(--green-primary) transparent; }
.slo-lb-thumb { flex: 0 0 74px; height: 54px; border-radius: 6px; overflow: hidden; border: 2px solid transparent; padding: 0; background: #1a2621; cursor: pointer; opacity: 0.55; transition: all 0.2s ease; }
.slo-lb-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.slo-lb-thumb:hover { opacity: 0.85; }
.slo-lb-thumb.active { opacity: 1; border-color: var(--green-light); transform: translateY(-2px); box-shadow: 0 4px 10px rgba(82, 183, 142, 0.35); }
@media (max-width: 768px) {
  .slo-lb-stage { padding: 10px 16px; }
  .slo-lb-nav { width: 42px; height: 42px; }
  .slo-lb-prev { left: 10px; }
  .slo-lb-next { right: 10px; }
  .slo-lb-title { display: none; }
}

/* KONTAKT */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 40px; }
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; } }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 14px; }
.form-group input, .form-group textarea { width: 100%; padding: 10px 14px; border: 1px solid #ccc; border-radius: 6px; font-family: inherit; font-size: 15px; }
.alert-success { background: #dcfce7; color: #166534; padding: 14px 18px; border-radius: 6px; margin-bottom: 20px; border-left: 4px solid #22c55e; }
.alert-error { background: #fee2e2; color: #991b1b; padding: 14px 18px; border-radius: 6px; margin-bottom: 20px; border-left: 4px solid #ef4444; }

/* KARTY DOKUMENTÓW I NOWOCZESNY HUB DLA UCZNIA I RODZICA */
.docs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 20px; margin-top: 20px; }
.doc-card { background: #f8fbf9; border: 1px solid #dcebe3; border-radius: 8px; padding: 20px; display: flex; flex-direction: column; justify-content: space-between; }
.doc-card h3 { font-size: 17px; color: var(--green-dark); margin-bottom: 8px; }
.doc-card p { font-size: 14px; color: #555; margin-bottom: 14px; }

.bar-heading { font-size: 24px; font-weight: 700; color: #111; border-left: 4px solid var(--green-primary); padding-left: 14px; line-height: 1.25; margin-bottom: 14px; }
.hub-subtitle { color: #5b6b63; font-size: 14px; margin-bottom: 20px; padding-left: 18px; }

/* SEKCJA 3-KOLUMNOWA: ROZKŁAD ZAJĘĆ, SAMORZĄD, PEDAGOG, BIBLIOTEKA */
.school-info-grid { display: grid; grid-template-columns: 0.9fr 1.15fr 1fr; gap: 26px; align-items: start; margin-bottom: 48px; }
@media (max-width: 980px) { .school-info-grid { grid-template-columns: 1fr; } }
.school-info-stack { display: flex; flex-direction: column; gap: 24px; }
.school-info-card { background: #ffffff; border: 1px solid #e2eee8; border-radius: 14px; padding: 26px; box-shadow: 0 6px 22px rgba(20, 52, 39, 0.05); }
.wf-card { background: linear-gradient(135deg, #f3faf6 0%, #ffffff 100%); border-left: 4px solid var(--green-primary); }
.wf-card p { font-size: 14.5px; color: #2b3a33; line-height: 1.6; margin: 0; }

.bells-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.bells-list li { display: flex; justify-content: space-between; align-items: center; padding: 8px 14px; border-radius: 8px; background: #f8fbf9; font-size: 14.5px; border: 1px solid #edf5f0; }
.bells-list li:nth-child(even) { background: #ffffff; }
.bells-list li.long-break-after { margin-bottom: 8px; border-bottom: 2px dashed #bfe0d0; position: relative; }
.bell-num { font-weight: 700; color: var(--green-primary); width: 28px; }
.bell-time { font-weight: 600; color: #1e2924; font-variant-numeric: tabular-nums; }

.roles-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; font-size: 14.5px; }
.roles-list li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px; padding-bottom: 8px; border-bottom: 1px solid #f0f6f3; }
.roles-list li:last-child { border-bottom: none; padding-bottom: 0; }
.role-label { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.4px; color: #5a6e64; }
.role-guardian { margin-top: 14px; padding: 10px 14px; background: #f2f9f5; border-radius: 8px; font-size: 13.5px; color: var(--green-dark); }

.specialist-badge { display: inline-flex; align-items: center; gap: 8px; background: #e8f5ee; color: var(--green-dark); padding: 8px 14px; border-radius: 8px; font-size: 15px; margin-bottom: 16px; }
.hours-subheading { font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px; color: #5a6e64; margin: 0 0 10px; }
.hours-table { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 7px; font-size: 14px; }
.hours-table li { display: flex; justify-content: space-between; padding: 7px 12px; background: #f8fbf9; border-radius: 6px; }
.hours-table li strong { color: var(--green-dark); font-variant-numeric: tabular-nums; }
.library-hours-box { display: flex; justify-content: space-between; align-items: center; background: #f2f9f5; border: 1px solid #d8ede2; padding: 12px 16px; border-radius: 10px; font-size: 14.5px; }
.library-hours-box strong { color: var(--green-primary); font-size: 16px; }

/* PODSTRONA EDUKACJA DOMOWA – INFORMACJE I EGZAMINY */
.ed-section-header { margin-bottom: 22px; }
.ed-general-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 24px; margin-bottom: 26px; }
.ed-card-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.ed-card-head h3 { font-size: 20px; color: #111; margin: 0; }
.ed-icon-box { width: 44px; height: 44px; border-radius: 10px; background: #e6f4ee; color: var(--green-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }

.ed-check-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; font-size: 15px; line-height: 1.6; color: #26332d; }
.ed-check-list > li { position: relative; padding-left: 26px; }
.ed-check-list > li::before { content: '✓'; position: absolute; left: 0; top: 1px; width: 18px; height: 18px; border-radius: 50%; background: #e3f3ec; color: var(--green-primary); font-size: 11px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.ed-Check-list a, .ed-check-list a { color: var(--green-primary); font-weight: 600; text-decoration: underline; }
.ed-sublist { list-style: disc; padding-left: 20px; margin-top: 6px; display: flex; flex-direction: column; gap: 4px; color: #3a4b43; }

.ed-dual-diploma { background: linear-gradient(135deg, #1b4334 0%, #2d7257 60%, #3b9471 100%); color: #ffffff; border-radius: 16px; padding: 32px 36px; box-shadow: 0 12px 30px rgba(24, 62, 43, 0.18); }
.ed-dual-badge { display: inline-block; background: rgba(255, 255, 255, 0.16); color: #d8f5e8; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.7px; padding: 4px 12px; border-radius: 20px; margin-bottom: 12px; }
.ed-dual-grid { display: grid; grid-template-columns: 1fr auto; gap: 28px; align-items: center; }
@media (max-width: 768px) { .ed-dual-grid { grid-template-columns: 1fr; } .ed-dual-icon { display: none; } }
.ed-dual-grid h3 { font-size: 24px; margin-bottom: 10px; color: #fff; }
.ed-dual-grid p { font-size: 15px; line-height: 1.65; color: rgba(255, 255, 255, 0.92); margin-bottom: 10px; }
.ed-dual-grid p:last-child { margin-bottom: 0; }
.ed-dual-icon { color: rgba(255, 255, 255, 0.22); padding: 10px; }

.ed-exam-highlights { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin-bottom: 28px; }
.ed-highlight-box { background: #f6fbf8; border: 1px solid #d8ece2; border-top: 4px solid var(--green-primary); border-radius: 12px; padding: 22px 24px; }
.ed-hl-label { display: block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--green-primary); margin-bottom: 4px; }
.ed-highlight-box strong { display: block; font-size: 20px; color: var(--green-dark); margin-bottom: 8px; }
.ed-highlight-box p { font-size: 14px; color: #4a5a52; line-height: 1.5; margin: 0; }

.ed-exam-main-grid { display: grid; grid-template-columns: 1.35fr 0.85fr; gap: 28px; align-items: start; }
@media (max-width: 940px) { .ed-exam-main-grid { grid-template-columns: 1fr; } }
.ed-exam-main-grid h3 { font-size: 19px; color: var(--green-dark); margin-bottom: 14px; }

.ed-grading-desc { font-size: 14px; color: #555; line-height: 1.5; margin-bottom: 16px; }
.ed-grading-scale { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.ed-grading-scale li { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-radius: 8px; font-size: 14.5px; background: #f8fbf9; border-left: 4px solid var(--green-primary); }
.ed-grading-scale li.grade-6 { background: #eaf7f1; border-left-color: #15803d; }
.ed-grading-scale li.grade-5 { background: #f0f9f4; border-left-color: #22c55e; }
.ed-grading-scale li.grade-4 { background: #f5fbf8; border-left-color: #3b9471; }
.ed-grading-scale li.grade-3 { background: #f9fbf9; border-left-color: #65a30d; }
.ed-grading-scale li.grade-2 { background: #fffbeb; border-left-color: #f59e0b; }
.ed-grading-scale li.grade-1 { background: #fef2f2; border-left-color: #ef4444; }
.grade-pct { font-weight: 700; color: #1f2937; font-variant-numeric: tabular-nums; }
.grade-name { color: var(--green-dark); }
.grade-1 .grade-name { color: #991b1b; }

.ed-contact-card { background: #1f4e3d; color: #ffffff; }
.ed-contact-card h3 { color: #ffffff; margin-bottom: 8px; }
.ed-contact-card p { font-size: 14px; color: rgba(255, 255, 255, 0.86); line-height: 1.5; margin-bottom: 16px; }
.ed-mail-btn { display: inline-flex; align-items: center; gap: 10px; background: #ffffff; color: var(--green-dark); text-decoration: none; font-weight: 700; font-size: 14px; padding: 11px 18px; border-radius: 8px; width: 100%; justify-content: center; transition: transform 0.2s ease, background 0.2s ease; }
.ed-mail-btn:hover { background: #e8f5ee; transform: translateY(-2px); }

/* PODSTRONA HISTORIA SZKOŁY */
.history-intro { margin-bottom: 24px; }
.history-lead { font-size: 16px; color: #3a4a42; line-height: 1.65; margin-top: 10px; max-width: 880px; }

.history-timeline-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-bottom: 36px; }
.ht-item { background: #f5faf7; border: 1px solid #d8ece2; border-top: 4px solid var(--green-primary); border-radius: 12px; padding: 18px 20px; }
.ht-year { display: inline-block; font-size: 15px; font-weight: 700; color: var(--green-primary); margin-bottom: 6px; }
.ht-item p { font-size: 13.5px; color: #394840; line-height: 1.45; margin: 0; }

.history-main-grid { display: grid; grid-template-columns: 1.35fr 0.9fr; gap: 32px; align-items: start; }
@media (max-width: 960px) { .history-main-grid { grid-template-columns: 1fr; } }

.history-memoir-card { position: relative; background: #ffffff; border: 1px solid #e0eee7; border-left: 5px solid var(--green-primary); border-radius: 14px; padding: 36px 38px; box-shadow: 0 8px 28px rgba(20, 52, 39, 0.06); overflow: hidden; }
.memoir-quote-mark { position: absolute; top: -18px; right: 24px; font-size: 140px; font-family: Georgia, serif; color: rgba(59, 148, 113, 0.09); line-height: 1; pointer-events: none; }
.memoir-content { position: relative; z-index: 1; }
.memoir-content p { font-size: 15.5px; line-height: 1.78; color: #24302a; margin-bottom: 18px; text-align: justify; }
.memoir-closing { background: #f3faf6; padding: 16px 20px; border-radius: 10px; font-style: italic; color: var(--green-dark) !important; border: 1px solid #dcefe5; }
.memoir-author { display: flex; flex-direction: column; margin-top: 22px; padding-top: 16px; border-top: 1px solid #eaf2ee; }
.memoir-author strong { font-size: 17px; color: var(--green-dark); }
.memoir-author span { font-size: 13px; color: #607269; }

.history-statute-card h3 { font-size: 20px; color: var(--green-dark); margin-bottom: 8px; }
.statute-pillars { display: flex; flex-direction: column; gap: 16px; }
.statute-pillar-item { display: flex; gap: 14px; align-items: flex-start; background: #f8fbf9; border: 1px solid #e5f0eb; border-radius: 10px; padding: 14px 16px; font-size: 14.5px; line-height: 1.55; }
.statute-pillar-item p { margin: 0; color: #24302a; }
.statute-num { width: 28px; height: 28px; border-radius: 50%; background: var(--green-primary); color: #fff; font-weight: 700; font-size: 14px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 1px; }

.history-tto-card { background: linear-gradient(150deg, #1b4334 0%, #2a6a50 100%); color: #ffffff; }
.history-tto-card h3 { font-size: 20px; color: #ffffff; margin-bottom: 12px; }
.history-tto-card p { font-size: 14.5px; line-height: 1.65; color: rgba(255, 255, 255, 0.92); margin-bottom: 14px; }
.tto-committee-box { background: rgba(255, 255, 255, 0.12); border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 10px; padding: 14px 18px; margin-bottom: 14px; font-size: 14px; }
.tto-committee-box strong { display: block; margin-bottom: 6px; color: #d8f5e8; }
.tto-committee-box ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }

.history-section { margin-top: 52px; padding-top: 42px; border-top: 1px solid #e2eee8; }
.history-campus-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 28px; align-items: stretch; }
.campus-card { display: flex; flex-direction: column; gap: 14px; border-top: 4px solid var(--green-primary); }
.campus-card p { font-size: 14.5px; line-height: 1.68; color: #2b3932; margin: 0; }
.campus-card-head { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 4px; }
.campus-icon { width: 48px; height: 48px; border-radius: 12px; background: #e6f4ee; color: var(--green-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.campus-date { display: inline-block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--green-primary); margin-bottom: 3px; }
.campus-card-head h3 { font-size: 19px; color: var(--green-dark); margin: 0; line-height: 1.3; }
.campus-features-box { background: #f6fbf8; border: 1px solid #dfeee6; border-radius: 10px; padding: 16px 18px; font-size: 14px; }
.campus-features-box strong { color: var(--green-dark); }
.campus-note { margin-top: auto !important; background: #eff8f3; border-left: 3px solid var(--green-primary); padding: 12px 15px; border-radius: 6px; font-size: 13.5px !important; color: #35473e !important; }

.directors-layout { display: grid; grid-template-columns: 1.3fr 0.9fr; gap: 28px; align-items: start; margin-top: 10px; }
@media (max-width: 960px) { .directors-layout { grid-template-columns: 1fr; } }
.directors-era-box { background: #f5faf7; border: 1px solid #dcefe5; border-radius: 12px; padding: 18px 20px; margin-bottom: 20px; }
.era-badge { display: inline-block; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--green-primary); background: #e3f3ec; padding: 3px 10px; border-radius: 20px; margin-bottom: 10px; }
.era-roles { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.role-label { display: block; font-size: 13px; color: #52635a; margin-bottom: 3px; }
.era-roles strong { font-size: 16px; color: var(--green-dark); }
.reorg-desc { font-size: 14.5px; color: #3a4a42; line-height: 1.6; margin-bottom: 16px; }
.reorg-schools-grid { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 18px; }
@media (max-width: 680px) { .reorg-schools-grid { grid-template-columns: 1fr; } }
.reorg-school-box { background: #f9fcfa; border: 1px solid #e2eee8; border-radius: 12px; padding: 18px; }

.directors-timeline-list { list-style: none; padding: 0; margin: 6px 0 0; display: flex; flex-direction: column; gap: 8px; }
.directors-timeline-list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 12px; background: #ffffff; border: 1px solid #e7f1ec; border-radius: 8px; font-size: 14px; }
.directors-timeline-list li.dir-current { background: #eaf7f1; border-color: var(--green-primary); }
.dir-years { font-size: 12.5px; font-weight: 700; color: var(--green-primary); font-variant-numeric: tabular-nums; white-space: nowrap; }
.directors-timeline-list strong { color: var(--green-dark); text-align: right; }

.secretariat-group h4 { font-size: 14.5px; color: #35473e; margin-bottom: 8px; font-weight: 700; }

.history-patron-banner { margin-top: 28px; background: linear-gradient(135deg, #1b4334 0%, #2d7357 100%); color: #ffffff; border-radius: 14px; padding: 24px 30px; display: flex; align-items: center; gap: 20px; box-shadow: 0 10px 28px rgba(24, 62, 43, 0.16); }
.hpb-icon { width: 56px; height: 56px; border-radius: 14px; background: rgba(255, 255, 255, 0.14); color: #cbeee0; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.history-patron-banner p { margin: 0; font-size: 15.5px; line-height: 1.65; color: rgba(255, 255, 255, 0.95); }

/* PODSTRONA PATRON I HYMN */
.patron-hero-card { display: grid; grid-template-columns: 380px 1fr; gap: 38px; align-items: center; background: linear-gradient(135deg, #ffffff 0%, #f4faf6 100%); border: 1px solid #d9ebe2; border-radius: 18px; padding: 34px; box-shadow: 0 12px 34px rgba(20, 52, 39, 0.07); margin-bottom: 48px; }
@media (max-width: 920px) { .patron-hero-card { grid-template-columns: 1fr; padding: 24px; } }
.patron-portrait-frame { background: #1c2622; border-radius: 14px; overflow: hidden; box-shadow: 0 14px 32px rgba(0, 0, 0, 0.18); border: 4px solid #ffffff; }
.patron-portrait-frame img { width: 100%; height: auto; display: block; }
.patron-portrait-caption { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; background: #1c2622; color: #dce8e2; font-size: 12.5px; }
.patron-portrait-caption strong { color: #8ad6b5; font-variant-numeric: tabular-nums; }

.patron-role-pills { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; }
.patron-role-pills .hub-badge { margin-bottom: 0; }
.patron-pill-subtle { font-size: 11.5px; font-weight: 600; color: #3d5248; background: #e8f2ed; padding: 3px 11px; border-radius: 20px; }
.patron-story-p { font-size: 15.5px; line-height: 1.75; color: #2b3932; margin-bottom: 18px; text-align: justify; }
.patron-story-highlight { background: #ffffff; border-left: 4px solid var(--green-primary); border-radius: 10px; padding: 18px 22px; box-shadow: 0 4px 16px rgba(20, 52, 39, 0.05); }
.patron-story-highlight p { margin: 0; font-size: 15px; line-height: 1.72; color: #1f2d26; text-align: justify; }

.patron-bio-section { background: #f2f8f5; border: 1px solid #dcece4; border-radius: 18px; padding: 36px; margin-bottom: 48px; }
@media (max-width: 680px) { .patron-bio-section { padding: 22px; } }
.patron-lifespan { font-size: 16px; font-weight: 600; color: #42584d; margin-bottom: 24px; }
.patron-bio-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 26px; align-items: stretch; }
@media (max-width: 960px) { .patron-bio-grid { grid-template-columns: 1fr; } }
.patron-pillars-cards { display: flex; flex-direction: column; gap: 16px; }
.patron-pillar-card { display: flex; gap: 16px; align-items: flex-start; padding: 20px 22px; margin: 0; }
.pp-icon { width: 46px; height: 46px; border-radius: 12px; background: #e5f4ed; color: var(--green-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.patron-pillar-card h3 { font-size: 16.5px; color: var(--green-dark); margin: 0 0 6px; }
.patron-pillar-card p { font-size: 14px; line-height: 1.6; color: #35463e; margin: 0; }

.patron-summary-card { display: flex; flex-direction: column; justify-content: space-between; border-top: 4px solid var(--green-primary); }
.patron-summary-card h3 { font-size: 19px; color: var(--green-dark); margin-bottom: 12px; }
.patron-summary-card p { font-size: 14.5px; line-height: 1.7; color: #2b3932; margin-bottom: 14px; text-align: justify; }
.patron-tribute-footer { margin-top: auto; background: linear-gradient(135deg, #1b4334 0%, #2c6e53 100%); color: #ffffff; padding: 16px 20px; border-radius: 10px; font-size: 14.5px; line-height: 1.55; text-align: center; }
.patron-tribute-footer strong { font-size: 16px; color: #b8f2d8; display: inline-block; margin-top: 3px; }

.patron-quotes-section { margin-bottom: 52px; }
.patron-quotes-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; margin-top: 12px; }
@media (max-width: 820px) { .patron-quotes-grid { grid-template-columns: 1fr; } }
.patron-quote-card { position: relative; margin: 0; background: #ffffff; border: 1px solid #dfeee7; border-left: 5px solid var(--green-primary); border-radius: 14px; padding: 28px 30px; box-shadow: 0 6px 22px rgba(20, 52, 39, 0.05); display: flex; flex-direction: column; justify-content: space-between; overflow: hidden; }
.patron-quote-card.pq-accent { background: linear-gradient(145deg, #1e4b3a 0%, #2d7056 100%); color: #ffffff; border-left-color: #8ee0bc; }
.pq-mark { position: absolute; top: -14px; right: 20px; font-size: 110px; font-family: Georgia, serif; color: rgba(59, 148, 113, 0.1); line-height: 1; pointer-events: none; }
.patron-quote-card.pq-accent .pq-mark { color: rgba(255, 255, 255, 0.12); }
.patron-quote-card p { position: relative; z-index: 1; font-size: 15px; line-height: 1.72; color: #24322b; font-style: italic; margin: 0 0 16px; }
.patron-quote-card.pq-accent p { color: #ffffff; }
.pq-large-text { font-size: 21px !important; font-weight: 600; line-height: 1.5 !important; }
.patron-quote-card footer { position: relative; z-index: 1; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 12px; border-top: 1px solid #e9f2ee; font-size: 13px; margin-top: auto; }
.patron-quote-card.pq-accent footer { border-top-color: rgba(255, 255, 255, 0.2); }
.patron-quote-card cite { font-style: normal; font-weight: 700; color: var(--green-dark); }
.patron-quote-card.pq-accent cite { color: #c4f5df; }
.patron-quote-card footer span { color: #687c72; font-weight: 600; white-space: nowrap; }
.patron-quote-card.pq-accent footer span { color: rgba(255, 255, 255, 0.82); }

.patron-naming-section { background: linear-gradient(180deg, #f6fbf8 0%, #edf6f1 100%); border: 1px solid #d7eae0; border-radius: 18px; padding: 40px 34px; text-align: center; margin-bottom: 52px; }
.patron-naming-header h2 { font-size: 26px; color: #16261f; line-height: 1.38; margin: 6px 0 10px; }
.patron-naming-header h2 span { color: var(--green-primary); }
.patron-naming-header p { font-size: 14.5px; color: #52665c; max-width: 640px; margin: 0 auto 28px; }
.patron-docs-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 360px)); justify-content: center; gap: 28px; }
.patron-doc-card { background: #ffffff; border: 1px solid #dcece3; border-radius: 14px; padding: 16px; cursor: pointer; text-align: center; transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease; box-shadow: 0 8px 24px rgba(20, 52, 39, 0.07); font-family: inherit; }
.patron-doc-card:hover { transform: translateY(-5px); border-color: var(--green-primary); box-shadow: 0 16px 36px rgba(20, 52, 39, 0.14); }
.patron-doc-img-wrap { position: relative; border-radius: 10px; overflow: hidden; background: #f4f7f5; aspect-ratio: 316 / 450; display: flex; align-items: center; justify-content: center; }
.patron-doc-img-wrap img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.35s ease; }
.patron-doc-card:hover .patron-doc-img-wrap img { transform: scale(1.03); }
.patron-doc-zoom { position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); background: rgba(24, 58, 44, 0.9); color: #ffffff; font-size: 12.5px; font-weight: 600; padding: 8px 16px; border-radius: 24px; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25); transition: background 0.2s ease; }
.patron-doc-card:hover .patron-doc-zoom { background: var(--green-primary); }
.patron-doc-meta { padding: 14px 8px 4px; display: flex; flex-direction: column; gap: 3px; }
.patron-doc-meta strong { font-size: 14.5px; color: var(--green-dark); }
.patron-doc-meta span { font-size: 12.5px; color: #687c72; }

.hymn-showcase-section { display: grid; grid-template-columns: 0.85fr 1.35fr; gap: 32px; align-items: stretch; }
@media (max-width: 920px) { .hymn-showcase-section { grid-template-columns: 1fr; } }
.hymn-brand-card { height: 100%; background: #ffffff; border: 1px solid #dfeee7; border-radius: 18px; padding: 34px 28px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; box-shadow: 0 8px 26px rgba(20, 52, 39, 0.05); }
.hymn-logo-img { max-width: 190px; height: auto; display: block; }
.hymn-brand-card h3 { font-size: 22px; color: var(--green-dark); margin: 4px 0 10px; }
.hymn-brand-card p { font-size: 14.5px; line-height: 1.65; color: #495c53; margin-bottom: 20px; }
.hymn-author-box { width: 100%; background: #f3faf6; border: 1px solid #d9ece2; border-radius: 12px; padding: 14px 18px; margin-top: auto; }
.hymn-author-box span { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; color: #5c7066; margin-bottom: 3px; }
.hymn-author-box strong { font-size: 16px; color: var(--green-dark); }

.hymn-sheet-card { background: #ffffff; border: 1px solid #dcece3; border-top: 5px solid var(--green-primary); border-radius: 18px; padding: 36px 38px; box-shadow: 0 14px 38px rgba(20, 52, 39, 0.08); }
@media (max-width: 600px) { .hymn-sheet-card { padding: 24px 20px; } }
.hymn-sheet-header { display: flex; align-items: center; gap: 16px; margin-bottom: 26px; padding-bottom: 18px; border-bottom: 1px solid #e7f1ec; }
.hymn-musical-icon { width: 50px; height: 50px; border-radius: 14px; background: #e5f4ed; color: var(--green-primary); font-size: 26px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.hymn-sheet-header h2 { font-size: 26px; color: var(--green-dark); margin: 0; }
.hymn-stanzas-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
@media (max-width: 680px) { .hymn-stanzas-grid { grid-template-columns: 1fr; } }
.hymn-stanza { background: #f8fcfa; border: 1px solid #e4f0ea; border-radius: 12px; padding: 20px 22px; position: relative; }
.stanza-num { display: inline-block; font-size: 12px; font-weight: 700; color: var(--green-primary); background: #e3f3ec; padding: 2px 10px; border-radius: 12px; margin-bottom: 10px; }
.hymn-stanza p { margin: 0; font-size: 15px; line-height: 1.85; color: #1f2e27; font-weight: 500; }
.hymn-sheet-footer { margin-top: 24px; padding-top: 16px; border-top: 1px solid #e7f1ec; text-align: right; font-size: 14.5px; color: #42564c; }

.patron-doc-modal { position: fixed; inset: 0; background: rgba(12, 24, 19, 0.88); backdrop-filter: blur(5px); z-index: 9999; display: none; align-items: center; justify-content: center; padding: 24px; }
.patron-doc-modal.active { display: flex; }
.patron-doc-modal-inner { position: relative; max-width: 760px; max-height: 92vh; display: flex; flex-direction: column; align-items: center; }
.patron-doc-modal-inner img { max-width: 100%; max-height: 82vh; width: auto; height: auto; border-radius: 10px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); background: #fff; }
.patron-doc-modal-inner p { color: #e5f2ec; font-size: 14px; margin-top: 12px; text-align: center; }
.patron-doc-close { position: absolute; top: -16px; right: -16px; width: 40px; height: 40px; border-radius: 50%; border: none; background: var(--green-primary); color: #fff; font-size: 24px; line-height: 1; cursor: pointer; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35); display: flex; align-items: center; justify-content: center; }

/* PODSTRONA AKTY PRAWNE */
.legal-intro { margin-bottom: 30px; }
.legal-statute-hero { display: grid; grid-template-columns: 160px 1fr; gap: 30px; align-items: center; background: linear-gradient(140deg, #1b4334 0%, #2a6a50 60%, #368767 100%); color: #ffffff; border-radius: 18px; padding: 34px 38px; box-shadow: 0 14px 36px rgba(24, 62, 43, 0.2); margin-bottom: 34px; }
@media (max-width: 760px) { .legal-statute-hero { grid-template-columns: 1fr; padding: 26px 24px; gap: 20px; } }
.lsh-badge-box { background: rgba(255, 255, 255, 0.12); border: 1px solid rgba(255, 255, 255, 0.22); border-radius: 16px; padding: 24px 16px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; text-align: center; color: #c7f5df; }
.lsh-badge-box span { font-size: 12px; font-weight: 700; letter-spacing: 0.4px; color: #ffffff; }
.lsh-meta-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 10px; }
.lsh-pill-primary { background: rgba(255, 255, 255, 0.2); color: #d8f8e8; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.6px; padding: 4px 12px; border-radius: 20px; }
.lsh-pill-date { font-size: 12.5px; color: rgba(255, 255, 255, 0.82); font-weight: 500; }
.lsh-content-col h3 { font-size: 25px; color: #ffffff; margin: 0 0 10px; line-height: 1.3; }
.lsh-content-col p { font-size: 15px; line-height: 1.68; color: rgba(255, 255, 255, 0.9); margin: 0 0 22px; max-width: 820px; }
.lsh-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.lsh-btn-primary { display: inline-flex; align-items: center; gap: 9px; background: #ffffff; color: var(--green-dark); text-decoration: none; font-weight: 700; font-size: 14.5px; padding: 12px 22px; border-radius: 10px; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.16); transition: transform 0.2s ease, background 0.2s ease; }
.lsh-btn-primary:hover { background: #e8f6ef; transform: translateY(-2px); }
.lsh-btn-preview { display: inline-flex; align-items: center; gap: 8px; background: rgba(255, 255, 255, 0.14); color: #ffffff; border: 1px solid rgba(255, 255, 255, 0.32); font-family: inherit; font-weight: 600; font-size: 14px; padding: 11px 20px; border-radius: 10px; cursor: pointer; transition: background 0.2s ease, transform 0.2s ease; }
.lsh-btn-preview:hover { background: rgba(255, 255, 255, 0.24); transform: translateY(-2px); }

.legal-docs-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; margin-bottom: 36px; }
@media (max-width: 820px) { .legal-docs-grid { grid-template-columns: 1fr; } }
.legal-doc-card { background: #ffffff; border: 1px solid #dfeee7; border-top: 4px solid var(--green-primary); border-radius: 14px; padding: 26px 28px; box-shadow: 0 6px 22px rgba(20, 52, 39, 0.05); display: flex; flex-direction: column; transition: transform 0.22s ease, box-shadow 0.22s ease; }
.legal-doc-card:hover { transform: translateY(-4px); box-shadow: 0 14px 32px rgba(20, 52, 39, 0.11); }
.ldc-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; margin-bottom: 16px; }
.ldc-icon { width: 50px; height: 50px; border-radius: 12px; background: #e6f4ee; color: var(--green-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.ldc-badges { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.ldc-badges .hub-badge { margin-bottom: 0; }
.ldc-size { font-size: 12px; font-weight: 600; color: #687c72; font-variant-numeric: tabular-nums; }
.legal-doc-card h3 { font-size: 19px; color: var(--green-dark); margin: 0 0 10px; line-height: 1.35; }
.legal-doc-card p { font-size: 14.5px; line-height: 1.65; color: #465850; margin: 0 0 22px; flex: 1; }
.ldc-footer { display: flex; align-items: center; gap: 10px; padding-top: 16px; border-top: 1px solid #ebf3ef; }
.ldc-preview-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; background: #f2f9f5; color: var(--green-dark); border: 1px solid #d4e8de; font-family: inherit; font-weight: 600; font-size: 13.5px; padding: 9px 16px; border-radius: 8px; cursor: pointer; white-space: nowrap; transition: all 0.2s ease; }
.ldc-preview-btn:hover { background: #e1f2e9; border-color: var(--green-primary); }

.legal-helper-bar { background: #f5faf7; border: 1px solid #daece2; border-radius: 14px; padding: 22px 28px; display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.lhb-text { display: flex; flex-direction: column; gap: 4px; }
.lhb-text strong { font-size: 16px; color: var(--green-dark); }
.lhb-text span { font-size: 14px; color: #52655c; }

.pdf-preview-modal { position: fixed; inset: 0; background: rgba(14, 28, 22, 0.85); backdrop-filter: blur(4px); z-index: 9999; display: none; align-items: center; justify-content: center; padding: 24px; }
.pdf-preview-modal.active { display: flex; }
.pdf-preview-dialog { width: 100%; max-width: 1020px; height: 88vh; background: #ffffff; border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45); }
.pdf-preview-header { background: #1c2622; color: #ffffff; padding: 14px 22px; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.pdf-preview-header strong { font-size: 15.5px; color: #e6f4ee; }
.pdf-preview-actions { display: flex; align-items: center; gap: 12px; }
.pdf-modal-dl { background: var(--green-primary); color: #ffffff; text-decoration: none; font-size: 13px; font-weight: 600; padding: 7px 14px; border-radius: 6px; }
.pdf-modal-dl:hover { background: var(--green-light); color: #111; }
.pdf-modal-close { width: 34px; height: 34px; border-radius: 50%; border: none; background: rgba(255, 255, 255, 0.14); color: #fff; font-size: 22px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.pdf-modal-close:hover { background: #e11d48; }
.pdf-preview-body { flex: 1; background: #2d3732; }
.pdf-preview-body iframe { width: 100%; height: 100%; border: none; display: block; }

/* PODSTRONA JAK WYCHOWUJEMY */
.upbringing-hero { display: grid; grid-template-columns: 1.2fr 1fr; gap: 28px; align-items: stretch; margin-bottom: 48px; }
@media (max-width: 940px) { .upbringing-hero { grid-template-columns: 1fr; } }
.uh-main-card { background: linear-gradient(145deg, #1b4334 0%, #2a6a50 58%, #3b9471 100%); color: #ffffff; border-radius: 18px; padding: 36px 38px; box-shadow: 0 14px 36px rgba(24, 62, 43, 0.18); display: flex; flex-direction: column; justify-content: center; }
.uh-main-card h2 { font-size: 23px; font-weight: 600; color: rgba(255, 255, 255, 0.92); line-height: 1.4; margin: 4px 0 18px; }
.uh-main-card h2 span { display: inline-block; font-size: 28px; font-weight: 800; color: #c4f7df; letter-spacing: 0.4px; margin-top: 4px; }
.uh-main-card p { font-size: 15.5px; line-height: 1.76; color: rgba(255, 255, 255, 0.93); margin: 0; text-align: justify; }

.uh-side-card { background: #ffffff; border: 1px solid #d9ebe2; border-top: 4px solid var(--green-primary); border-radius: 18px; padding: 32px 34px; box-shadow: 0 8px 26px rgba(20, 52, 39, 0.06); display: flex; flex-direction: column; }
.uh-side-card h3 { font-size: 21px; color: var(--green-dark); margin: 4px 0 12px; }
.uh-side-card p { font-size: 15px; line-height: 1.7; color: #2d3c34; margin: 0 0 18px; text-align: justify; }
.uh-side-highlight { margin-top: auto; background: #f3faf6; border-left: 4px solid var(--green-primary); border-radius: 10px; padding: 15px 18px; font-size: 14.5px; line-height: 1.62; color: #1f3329; }

.upbringing-pillars-section { margin-bottom: 52px; }
.upbringing-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 26px; }
@media (max-width: 1080px) { .upbringing-grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .upbringing-grid-4 { grid-template-columns: 1fr; } }
.upbringing-card { background: #ffffff; border: 1px solid #dfeee7; border-radius: 14px; padding: 24px 22px; box-shadow: 0 6px 20px rgba(20, 52, 39, 0.05); transition: transform 0.22s ease, box-shadow 0.22s ease; display: flex; flex-direction: column; }
.upbringing-card:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(20, 52, 39, 0.11); border-color: var(--green-primary); }
.uc-icon { width: 48px; height: 48px; border-radius: 12px; background: #e5f4ed; color: var(--green-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; margin-bottom: 14px; }
.upbringing-card h3 { font-size: 15.5px; color: var(--green-dark); margin: 0 0 10px; line-height: 1.35; letter-spacing: 0.2px; }
.upbringing-card p { font-size: 14px; line-height: 1.65; color: #3a4b43; margin: 0; }

.upbringing-grid-wide { display: grid; grid-template-columns: 1fr 1.1fr; gap: 26px; align-items: stretch; }
@media (max-width: 940px) { .upbringing-grid-wide { grid-template-columns: 1fr; } }
.upbringing-feature-card { border-left: 5px solid var(--green-primary); }
.ufc-head { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.ufc-head .uc-icon { margin-bottom: 0; }
.ufc-head .hub-badge { margin-bottom: 4px; }
.ufc-head h3 { font-size: 18px; color: var(--green-dark); margin: 0; }
.upbringing-feature-card p { font-size: 14.8px; line-height: 1.72; color: #2b3a32; margin-bottom: 14px; text-align: justify; }
.upbringing-safety-box { background: #f2faf5; border: 1px solid #d7ece1; border-radius: 10px; padding: 14px 18px; margin-top: 12px; }
.upbringing-safety-box p { margin: 0; font-size: 14px; line-height: 1.6; color: #21362c; }

.prevention-section { background: linear-gradient(180deg, #f3faf6 0%, #ebf6f0 100%); border: 1px solid #d5e9de; border-radius: 18px; padding: 38px 36px; }
@media (max-width: 680px) { .prevention-section { padding: 24px 20px; } }
.prevention-grid { display: grid; grid-template-columns: 0.85fr 1.35fr 0.95fr; gap: 22px; margin-top: 16px; align-items: stretch; }
@media (max-width: 980px) { .prevention-grid { grid-template-columns: 1fr; } }
.prevention-card { background: #ffffff; border: 1px solid #dcece3; border-radius: 14px; padding: 26px; box-shadow: 0 6px 20px rgba(20, 52, 39, 0.05); display: flex; flex-direction: column; }
.prev-badge-num { width: 38px; height: 38px; border-radius: 10px; background: var(--green-primary); color: #ffffff; font-weight: 800; font-size: 14px; display: flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.prevention-card h3 { font-size: 18px; color: var(--green-dark); margin: 0 0 10px; }
.prevention-card p { font-size: 14.5px; line-height: 1.68; color: #2f3f37; margin: 0 0 12px; text-align: justify; }
.prevention-card p:last-child { margin-bottom: 0; }

/* PODSTRONA CZYM JEST SPOŁECZNE */
.social-genesis-hero { display: grid; grid-template-columns: 1.35fr 0.85fr; gap: 28px; align-items: stretch; margin-bottom: 44px; }
@media (max-width: 940px) { .social-genesis-hero { grid-template-columns: 1fr; } }
.sgh-main { background: linear-gradient(145deg, #1b4334 0%, #2a6a50 58%, #3b9471 100%); color: #ffffff; border-radius: 18px; padding: 38px 40px; box-shadow: 0 14px 36px rgba(24, 62, 43, 0.18); display: flex; flex-direction: column; justify-content: space-between; }
.sgh-main h2 { font-size: 27px; line-height: 1.42; color: #ffffff; margin: 6px 0 24px; font-weight: 700; }
.sgh-main h2 span { color: #b7f5d8; text-decoration: underline; text-decoration-color: rgba(183, 245, 216, 0.45); text-underline-offset: 5px; }
.sgh-rule-pill { background: rgba(255, 255, 255, 0.14); border: 1px solid rgba(255, 255, 255, 0.24); border-radius: 12px; padding: 16px 20px; display: flex; align-items: center; gap: 14px; font-size: 15px; line-height: 1.55; color: #f0fbf5; }
.sgh-rule-pill svg { flex-shrink: 0; color: #a7f0ce; }

.sgh-class-size-card { background: #ffffff; border: 1px solid #d9ebe2; border-top: 5px solid var(--green-primary); border-radius: 18px; padding: 32px 30px; box-shadow: 0 8px 26px rgba(20, 52, 39, 0.06); display: flex; flex-direction: column; align-items: center; text-align: center; justify-content: center; }
.sgh-number-badge { font-size: 48px; font-weight: 800; color: var(--green-primary); line-height: 1; margin-bottom: 4px; }
.sgh-number-label { font-size: 12.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.7px; color: var(--green-dark); background: #e6f4ee; padding: 4px 14px; border-radius: 20px; margin-bottom: 16px; }
.sgh-class-size-card p { font-size: 14.5px; line-height: 1.65; color: #2f3f37; margin: 0; }

.social-relations-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 28px; align-items: stretch; margin-bottom: 48px; }
@media (max-width: 940px) { .social-relations-grid { grid-template-columns: 1fr; } }
.social-story-card h3 { font-size: 19px; color: var(--green-dark); margin: 4px 0 10px; }
.social-story-card p { font-size: 15px; line-height: 1.72; color: #2b3a32; margin: 0; text-align: justify; }

.social-partnership-card { display: flex; flex-direction: column; justify-content: space-between; border-left: 5px solid var(--green-primary); }
.spc-quote-box { position: relative; background: linear-gradient(135deg, #f1faf5 0%, #e4f4ec 100%); border: 1px solid #cfe7db; border-radius: 14px; padding: 24px 26px; margin-bottom: 24px; overflow: hidden; }
.spc-quote-mark { position: absolute; top: -16px; right: 18px; font-size: 110px; font-family: Georgia, serif; color: rgba(59, 148, 113, 0.14); line-height: 1; pointer-events: none; }
.spc-quote-intro { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--green-primary); margin: 0 0 8px; }
.spc-quote-box blockquote { position: relative; z-index: 1; margin: 0; font-size: 19px; font-weight: 700; font-style: italic; line-height: 1.48; color: var(--green-dark); }
.spc-principles h3 { font-size: 19px; color: var(--green-dark); margin: 0 0 10px; }
.spc-principles p { font-size: 15px; line-height: 1.7; color: #2b3a32; margin: 0 0 18px; text-align: justify; }
.spc-pillars-mini { display: flex; flex-direction: column; gap: 8px; }
.spc-mini-item { display: flex; align-items: center; gap: 10px; background: #f7fbf9; border: 1px solid #e3efe9; border-radius: 8px; padding: 10px 14px; font-size: 14px; color: var(--green-dark); }
.spc-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green-primary); flex-shrink: 0; }

.social-care-section { background: #f4faf7; border: 1px solid #daece2; border-radius: 18px; padding: 38px 36px; }
@media (max-width: 680px) { .social-care-section { padding: 24px 20px; } }
.social-care-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 18px; }
@media (max-width: 920px) { .social-care-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .social-care-grid { grid-template-columns: 1fr; } }
.social-care-card { background: #ffffff; border: 1px solid #dcece3; border-radius: 14px; padding: 24px; box-shadow: 0 6px 18px rgba(20, 52, 39, 0.04); transition: transform 0.2s ease, box-shadow 0.2s ease; }
.social-care-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(20, 52, 39, 0.1); border-color: var(--green-primary); }
.social-care-card.scc-wide { grid-column: span 2; }
@media (max-width: 920px) { .social-care-card.scc-wide { grid-column: span 1; } }
.scc-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.scc-num { font-size: 13px; font-weight: 800; color: var(--green-primary); background: #e6f4ee; padding: 4px 10px; border-radius: 8px; }
.scc-icon { width: 42px; height: 42px; border-radius: 10px; background: #f2f9f5; color: var(--green-dark); display: flex; align-items: center; justify-content: center; }
.social-care-card h3 { font-size: 17px; color: var(--green-dark); margin: 0 0 6px; }
.social-care-card p { font-size: 14.5px; line-height: 1.58; color: #3d4f46; margin: 0; }

/* PODSTRONA FILOZOFIA EDUKACJI */
.philo-main-section { margin-bottom: 48px; }
.philo-pillars-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 14px; }
@media (max-width: 960px) { .philo-pillars-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .philo-pillars-grid { grid-template-columns: 1fr; } }
.philo-pillar-card { background: #ffffff; border: 1px solid #dfeee7; border-top: 4px solid var(--green-primary); border-radius: 14px; padding: 24px; box-shadow: 0 6px 20px rgba(20, 52, 39, 0.05); display: flex; flex-direction: column; gap: 12px; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.philo-pillar-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(20, 52, 39, 0.1); }
.ppc-num { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 10px; background: #e6f4ee; color: var(--green-primary); font-weight: 800; font-size: 13.5px; }
.philo-pillar-card p { font-size: 14.8px; line-height: 1.65; color: #2b3a32; margin: 0; }
.philo-pillar-card.ppc-featured { grid-column: span 3; background: linear-gradient(140deg, #1b4334 0%, #2a6a50 65%, #3b9471 100%); color: #ffffff; border: none; flex-direction: row; align-items: center; gap: 22px; padding: 26px 32px; }
@media (max-width: 960px) { .philo-pillar-card.ppc-featured { grid-column: span 2; } }
@media (max-width: 620px) { .philo-pillar-card.ppc-featured { grid-column: span 1; flex-direction: column; align-items: flex-start; } }
.philo-pillar-card.ppc-featured .ppc-num { width: 48px; height: 48px; font-size: 16px; background: rgba(255, 255, 255, 0.16); color: #c7f7e0; flex-shrink: 0; }
.philo-pillar-card.ppc-featured strong { font-size: 17px; color: #c7f7e0; display: block; margin-bottom: 4px; }
.philo-pillar-card.ppc-featured p { color: rgba(255, 255, 255, 0.94); font-size: 15.5px; }

.philo-support-grid { display: grid; grid-template-columns: 1.08fr 0.92fr; gap: 28px; align-items: stretch; margin-bottom: 48px; }
@media (max-width: 960px) { .philo-support-grid { grid-template-columns: 1fr; } }
.philo-student-card { border-left: 5px solid var(--green-primary); display: flex; flex-direction: column; }
.psc-head { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.psc-badge-24 { background: linear-gradient(135deg, var(--green-primary), var(--green-dark)); color: #ffffff; font-weight: 800; font-size: 16px; padding: 12px 16px; border-radius: 12px; white-space: nowrap; box-shadow: 0 6px 16px rgba(59, 148, 113, 0.24); }
.psc-head .hub-badge { margin-bottom: 4px; }
.psc-head h3 { font-size: 22px; color: var(--green-dark); margin: 0; }
.psc-lead { font-size: 15px; color: #36473e; margin: 0 0 16px; }
.philo-check-list { gap: 11px; }
.philo-check-list li { background: #f7fbf9; border: 1px solid #e4f0ea; border-radius: 10px; padding: 11px 14px 11px 36px; font-size: 14.5px; line-height: 1.52; }
.philo-check-list li::before { left: 12px; top: 13px; }

.philo-parent-col { display: flex; flex-direction: column; gap: 22px; }
.philo-parent-hero { background: linear-gradient(145deg, #1b4334 0%, #2d7055 100%); color: #ffffff; border-radius: 16px; padding: 30px 32px; box-shadow: 0 12px 30px rgba(24, 62, 43, 0.16); }
.philo-parent-hero h3 { font-size: 22px; color: #ffffff; margin: 4px 0 12px; }
.pph-highlight { font-size: 15.5px; line-height: 1.72; color: rgba(255, 255, 255, 0.93); margin: 0; }
.pph-highlight strong { color: #b9f6d9; }

.philo-parent-body { flex: 1; display: flex; flex-direction: column; justify-content: space-between; }
.philo-parent-body h4 { font-size: 18px; color: var(--green-dark); margin: 0 0 10px; }
.philo-parent-body p { font-size: 14.8px; line-height: 1.7; color: #2d3d35; margin: 0 0 18px; text-align: justify; }
.ppb-hosts-box { background: #f1faf5; border: 1px solid #d5ebe0; border-radius: 12px; padding: 16px 18px; display: flex; align-items: center; gap: 14px; margin-top: auto; }
.ppb-hosts-box svg { color: var(--green-primary); flex-shrink: 0; }
.ppb-hosts-box p { margin: 0; font-size: 14.5px; line-height: 1.55; color: #1e3329; text-align: left; }

.philo-future-section { background: #f4faf7; border: 1px solid #daece2; border-radius: 18px; padding: 38px 36px; }
@media (max-width: 680px) { .philo-future-section { padding: 24px 20px; } }
.philo-future-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 18px; }
@media (max-width: 1020px) { .philo-future-steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 580px) { .philo-future-steps { grid-template-columns: 1fr; } }
.pfs-card { background: #ffffff; border: 1px solid #dcece3; border-radius: 14px; padding: 24px 22px; box-shadow: 0 6px 18px rgba(20, 52, 39, 0.04); display: flex; flex-direction: column; gap: 10px; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.pfs-card:hover { transform: translateY(-4px); box-shadow: 0 12px 26px rgba(20, 52, 39, 0.1); border-color: var(--green-primary); }
.pfs-icon { width: 46px; height: 46px; border-radius: 12px; background: #e6f4ee; color: var(--green-primary); display: flex; align-items: center; justify-content: center; }
.pfs-step-label { font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.6px; color: var(--green-primary); }
.pfs-card p { font-size: 14.5px; line-height: 1.62; color: #2b3a32; margin: 0; }

/* PODSTRONY REKRUTACJI (STACJONARNA I DOMOWA) */
.rec-header-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-bottom: 38px; }
@media (max-width: 900px) { .rec-header-strip { grid-template-columns: 1fr; } }
.rec-step-item { background: #f5faf7; border: 1px solid #d8ece2; border-left: 4px solid var(--green-primary); border-radius: 12px; padding: 18px 20px; display: flex; align-items: center; gap: 16px; }
.rec-step-num { width: 40px; height: 40px; border-radius: 10px; background: var(--green-primary); color: #ffffff; font-weight: 800; font-size: 14px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.rec-step-item strong { display: block; font-size: 15.5px; color: var(--green-dark); margin-bottom: 2px; }
.rec-step-item span { display: block; font-size: 13px; color: #4e6258; line-height: 1.4; }

.rec-primary-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 720px) { .rec-primary-cards { grid-template-columns: 1fr; } }
.rec-doc-card { background: #ffffff; border: 1px solid #dfeee7; border-top: 4px solid var(--green-primary); border-radius: 14px; padding: 24px; box-shadow: 0 6px 20px rgba(20, 52, 39, 0.05); display: flex; flex-direction: column; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.rec-doc-card:hover { transform: translateY(-3px); box-shadow: 0 12px 28px rgba(20, 52, 39, 0.11); }
.rec-doc-card.rdc-featured { background: linear-gradient(145deg, #f3faf6 0%, #ffffff 100%); border-top-color: var(--green-dark); }
.rdc-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.rdc-icon { width: 48px; height: 48px; border-radius: 12px; background: #e5f4ed; color: var(--green-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.rdc-meta { display: block; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.4px; color: #64786e; margin-bottom: 2px; }
.rdc-title-wrap h3 { font-size: 18px; color: var(--green-dark); margin: 0; line-height: 1.3; }
.rec-doc-card p { font-size: 14px; line-height: 1.62; color: #44574e; margin: 0 0 18px; flex: 1; }
.rdc-actions { display: flex; flex-wrap: wrap; gap: 10px; padding-top: 14px; border-top: 1px solid #ebf3ef; }

.rec-form-row { display: flex; align-items: center; gap: 18px; background: #ffffff; border: 1px solid #dfeee6; border-radius: 12px; padding: 18px 20px; transition: all 0.2s ease; box-shadow: 0 4px 14px rgba(20, 52, 39, 0.04); }
.rec-form-row:hover { border-color: var(--green-primary); background: #f7fcf9; transform: translateX(3px); }
@media (max-width: 640px) { .rec-form-row { flex-direction: column; align-items: flex-start; } }
.rec-form-btns { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.rec-form-btns .form-doc-action { text-decoration: none; }
.rec-form-btns .form-doc-action:hover { background: var(--green-primary); color: #ffffff; }

.rec-contact-box { margin-top: 24px; border-top: 4px solid var(--green-primary); }
.rec-contact-box h3 { font-size: 19px; color: var(--green-dark); margin: 4px 0 8px; }
.rec-contact-box p { font-size: 14px; line-height: 1.6; color: #495c53; margin: 0 0 16px; }
.rec-contact-links { display: flex; flex-direction: column; gap: 10px; }
.rec-contact-item { display: flex; align-items: center; gap: 12px; background: #f4faf7; border: 1px solid #dcece3; border-radius: 10px; padding: 11px 16px; text-decoration: none; color: var(--green-dark); font-weight: 700; font-size: 14.5px; transition: all 0.2s ease; }
.rec-contact-item:hover { background: var(--green-primary); color: #ffffff; border-color: var(--green-primary); }
.rec-contact-item svg { color: var(--green-primary); flex-shrink: 0; transition: color 0.2s ease; }
.rec-contact-item:hover svg { color: #ffffff; }

/* REKRUTACJA EDUKACJA DOMOWA */
.ed-rec-hero { display: grid; grid-template-columns: 1.35fr 0.85fr; gap: 32px; align-items: stretch; margin-bottom: 48px; }
@media (max-width: 960px) { .ed-rec-hero { grid-template-columns: 1fr; } }
.ed-rec-hero-text { background: #ffffff; border: 1px solid #d9ebe2; border-radius: 18px; padding: 34px 36px; box-shadow: 0 8px 26px rgba(20, 52, 39, 0.05); display: flex; flex-direction: column; }
.ed-rec-hero-text p { font-size: 15px; line-height: 1.72; color: #2b3a32; margin: 0 0 18px; text-align: justify; }
.ed-inline-link { color: var(--green-primary); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.ed-inline-link:hover { color: var(--green-dark); }
.ed-platform-box { background: #f2faf5; border: 1px solid #d4eae0; border-left: 4px solid var(--green-primary); border-radius: 12px; padding: 18px 20px; display: flex; align-items: flex-start; gap: 16px; margin-bottom: 18px; }
.epb-icon { width: 46px; height: 46px; border-radius: 12px; background: #e1f3ea; color: var(--green-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.ed-platform-box p { margin: 0; font-size: 14.5px; line-height: 1.65; color: #1f3329; text-align: left; }
.ed-friendly-note { margin-top: auto !important; margin-bottom: 0 !important; background: #fafdfb; border: 1px dashed #beddcd; border-radius: 10px; padding: 14px 18px; font-size: 14.5px !important; color: #24382e !important; }

.ed-rec-partner-card { background: #ffffff; border: 1px solid #d9ebe2; border-top: 5px solid var(--green-primary); border-radius: 18px; padding: 28px; box-shadow: 0 10px 28px rgba(20, 52, 39, 0.06); display: flex; flex-direction: column; justify-content: space-between; text-align: center; }
.erpc-logo-wrap { background: #f7fbf9; border: 1px solid #e4f0ea; border-radius: 14px; padding: 24px 20px; margin-bottom: 20px; display: flex; align-items: center; justify-content: center; }
.erpc-logo-wrap img { max-width: 100%; height: auto; max-height: 110px; display: block; transition: transform 0.25s ease; }
.erpc-logo-wrap a:hover img { transform: scale(1.03); }
.erpc-body h3 { font-size: 20px; color: var(--green-dark); margin: 4px 0 10px; }
.erpc-body p { font-size: 14px; line-height: 1.6; color: #4a5d54; margin: 0 0 20px; }

.ed-questionnaire-banner { background: linear-gradient(140deg, #1b4334 0%, #2b6c52 60%, #3b9471 100%); color: #ffffff; border-radius: 16px; padding: 28px 30px; box-shadow: 0 12px 32px rgba(24, 62, 43, 0.18); display: flex; flex-direction: column; gap: 18px; }
.eqb-icon { width: 52px; height: 52px; border-radius: 14px; background: rgba(255, 255, 255, 0.16); color: #c7f7e0; display: flex; align-items: center; justify-content: center; }
.eqb-badge { display: inline-block; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: #c7f7e0; margin-bottom: 4px; }
.eqb-body h3 { font-size: 22px; color: #ffffff; margin: 0 0 6px; }
.eqb-body p { font-size: 14.5px; color: rgba(255, 255, 255, 0.9); margin: 0; line-height: 1.55; }
.eqb-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* NOWOCZESNA PODSTRONA KONTAKT */
.contact-quick-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 38px; }
@media (max-width: 1080px) { .contact-quick-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 580px) { .contact-quick-grid { grid-template-columns: 1fr; } }
.cq-card { background: #ffffff; border: 1px solid #dfeee7; border-top: 4px solid var(--green-primary); border-radius: 14px; padding: 24px 22px; box-shadow: 0 6px 20px rgba(20, 52, 39, 0.05); display: flex; flex-direction: column; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.cq-card:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(20, 52, 39, 0.11); }
.cq-icon { width: 46px; height: 46px; border-radius: 12px; background: #e5f4ed; color: var(--green-primary); display: flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.cq-label { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: #60756b; margin-bottom: 6px; }
.cq-main-link, .cq-main-text { font-size: 18px; font-weight: 800; color: var(--green-dark); text-decoration: none; margin-bottom: 8px; line-height: 1.3; word-break: break-word; }
.cq-email-link { font-size: 15.5px; }
.cq-main-link:hover { color: var(--green-primary); }
.cq-sub { font-size: 13px; color: #52665c; margin-top: auto; line-height: 1.45; }
.cq-sub a { color: var(--green-primary); font-weight: 600; text-decoration: none; }
.cq-sub a:hover { text-decoration: underline; }
.cq-action-link { margin-top: auto; font-size: 13.5px; font-weight: 700; color: var(--green-primary); text-decoration: none; display: inline-flex; align-items: center; gap: 4px; }
.cq-action-link:hover { color: var(--green-dark); text-decoration: underline; }
.cq-bank-num { font-size: 14px; font-weight: 800; color: var(--green-dark); font-variant-numeric: tabular-nums; letter-spacing: 0.2px; margin-bottom: 10px; line-height: 1.4; }
.cq-copy-btn { margin-top: auto; display: inline-flex; align-items: center; justify-content: center; gap: 7px; background: #f1faf5; color: var(--green-dark); border: 1px solid #cfe6db; border-radius: 8px; padding: 8px 12px; font-family: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer; transition: all 0.2s ease; }
.cq-copy-btn:hover, .cq-copy-btn.copied { background: var(--green-primary); color: #ffffff; border-color: var(--green-primary); }

.contact-modern-layout { display: grid; grid-template-columns: 1fr 1.15fr; gap: 28px; align-items: stretch; }
@media (max-width: 960px) { .contact-modern-layout { grid-template-columns: 1fr; } }

.contact-institution-card { border-left: 5px solid var(--green-primary); display: flex; flex-direction: column; justify-content: space-between; }
.cic-header { display: flex; align-items: center; gap: 18px; margin-bottom: 22px; padding-bottom: 18px; border-bottom: 1px solid #e8f1ec; }
.cic-logo { height: 54px; width: auto; flex-shrink: 0; }
.cic-header h2 { font-size: 19px; color: var(--green-dark); margin: 2px 0 0; line-height: 1.35; }
.cic-details-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 22px; }
@media (max-width: 540px) { .cic-details-grid { grid-template-columns: 1fr; } }
.cic-detail-box { background: #f6fbf8; border: 1px solid #e1efe8; border-radius: 12px; padding: 16px 18px; display: flex; flex-direction: column; gap: 4px; }
.cic-label { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: var(--green-primary); }
.cic-detail-box strong { font-size: 15.5px; color: var(--green-dark); }
.cic-detail-box small { font-size: 13px; color: #5b6e64; }
.cic-quick-routes { margin-top: auto; padding-top: 18px; border-top: 1px solid #e8f1ec; }
.cic-social-row { display: flex; flex-wrap: wrap; gap: 10px; }
.cic-pill-btn { display: inline-flex; align-items: center; gap: 8px; background: #edf7f2; color: var(--green-dark); text-decoration: none; font-size: 13px; font-weight: 700; padding: 9px 15px; border-radius: 10px; border: 1px solid #d5e9df; transition: all 0.2s ease; }
.cic-pill-btn:hover { background: var(--green-primary); color: #ffffff; border-color: var(--green-primary); }

.contact-map-card { border-top: 5px solid var(--green-primary); display: flex; flex-direction: column; }
.cmc-head { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 10px; flex-wrap: wrap; }
.cmc-head h3 { font-size: 20px; color: var(--green-dark); margin: 2px 0 0; }
.cmc-sub { font-size: 14px; color: #4d6057; margin: 0 0 16px; line-height: 1.55; }
.cmc-frame-wrap { flex: 1; min-height: 330px; border-radius: 12px; overflow: hidden; border: 1px solid #d7e8df; }
.cmc-frame-wrap iframe { width: 100%; height: 100%; min-height: 330px; border: 0; display: block; }

.hub-top-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 24px; margin-bottom: 44px; }
.hub-feature-card { background: #ffffff; border-radius: 14px; padding: 28px; border: 1px solid #e2eee8; box-shadow: 0 8px 26px rgba(20, 52, 39, 0.06); display: flex; gap: 20px; align-items: flex-start; transition: transform 0.25s ease, box-shadow 0.25s ease; }
.hub-feature-card:hover { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(20, 52, 39, 0.11); }
.hub-card-drive { background: linear-gradient(135deg, #f3faf6 0%, #ffffff 100%); border-left: 5px solid var(--green-primary); }
.hub-card-calendar { background: linear-gradient(135deg, #f7fbf9 0%, #ffffff 100%); border-left: 5px solid var(--green-dark); }
.hub-feature-icon { width: 54px; height: 54px; border-radius: 12px; background: #e3f3ec; color: var(--green-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.hub-card-calendar .hub-feature-icon { background: #e0ece6; color: var(--green-dark); }
.hub-feature-body { flex: 1; }
.hub-badge { display: inline-block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.6px; color: var(--green-primary); background: #e6f4ee; padding: 3px 10px; border-radius: 20px; margin-bottom: 8px; }
.hub-feature-body h2 { font-size: 21px; color: #111; margin-bottom: 8px; }
.hub-feature-body p { font-size: 14px; color: #555; line-height: 1.55; margin-bottom: 18px; }
.hub-btn-primary { display: inline-flex; align-items: center; gap: 8px; background: var(--green-primary); color: #fff; text-decoration: none; font-weight: 600; font-size: 14px; padding: 10px 20px; border-radius: 8px; transition: background 0.2s ease, transform 0.15s ease; }
.hub-btn-primary:hover { background: var(--green-dark); transform: translateY(-1px); }
.hub-btn-outline { display: inline-flex; align-items: center; gap: 8px; background: #fff; color: var(--green-dark); border: 1.5px solid var(--green-primary); text-decoration: none; font-weight: 600; font-size: 14px; padding: 9px 18px; border-radius: 8px; transition: all 0.2s ease; }
.hub-btn-outline:hover { background: var(--green-primary); color: #fff; }

.hub-main-grid { display: grid; grid-template-columns: 1.15fr 0.95fr; gap: 40px; align-items: start; }
@media (max-width: 960px) { .hub-main-grid { grid-template-columns: 1fr; } }

.textbooks-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
@media (max-width: 560px) { .textbooks-grid { grid-template-columns: 1fr; } }
.textbook-card { display: flex; align-items: center; gap: 14px; background: #ffffff; border: 1px solid #dfeee6; border-radius: 12px; padding: 16px; text-decoration: none; color: var(--text-dark); box-shadow: 0 3px 12px rgba(0, 0, 0, 0.03); transition: all 0.2s ease; }
.textbook-card:hover { border-color: var(--green-primary); background: #f6fbf8; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(59, 148, 113, 0.12); }
.textbook-card-with-actions { flex-direction: column; align-items: stretch; gap: 12px; }
.textbook-card-main { display: flex; align-items: center; gap: 14px; }
.textbook-actions { display: flex; align-items: center; gap: 8px; padding-top: 10px; border-top: 1px solid #ebf4ef; }
.textbook-actions .ldc-preview-btn,
.textbook-actions .form-doc-action { flex: 1; text-align: center; justify-content: center; text-decoration: none; font-size: 12.5px; padding: 7px 10px; border-radius: 8px; }
.textbook-actions .form-doc-action:hover { background: var(--green-primary); color: #fff; }
.textbook-num { width: 46px; height: 46px; border-radius: 10px; background: linear-gradient(135deg, var(--green-primary), var(--green-dark)); color: #fff; font-weight: 700; font-size: 17px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.textbook-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.textbook-info strong { font-size: 15px; color: #111; }
.textbook-info span { font-size: 12px; color: #666; }
.textbook-dl { color: var(--green-primary); opacity: 0.7; transition: opacity 0.2s ease, transform 0.2s ease; }
.textbook-card:hover .textbook-dl { opacity: 1; transform: translateY(2px); }

.forms-list { display: flex; flex-direction: column; gap: 14px; }
.form-doc-row { display: flex; align-items: center; gap: 18px; background: #ffffff; border: 1px solid #dfeee6; border-radius: 12px; padding: 18px 20px; text-decoration: none; color: var(--text-dark); transition: all 0.2s ease; }
.form-doc-row:hover { border-color: var(--green-primary); background: #f6fbf8; transform: translateX(4px); box-shadow: 0 6px 18px rgba(59, 148, 113, 0.1); }
.form-doc-icon { color: var(--green-dark); display: flex; flex-shrink: 0; }
.form-doc-body { flex: 1; }
.form-doc-body h3 { font-size: 16px; color: #111; margin-bottom: 3px; }
.form-doc-body p { font-size: 13px; color: #5b6b63; margin: 0; line-height: 1.4; }
.form-doc-action { display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: var(--green-primary); white-space: nowrap; background: #ebf6f1; padding: 8px 15px; border-radius: 8px; transition: background 0.2s ease, color 0.2s ease; }
.form-doc-row:hover .form-doc-action { background: var(--green-primary); color: #fff; }

.uonet-panel { background: linear-gradient(155deg, #1f4e3d 0%, #2f7a5c 55%, #3b9471 100%); color: #ffffff; border-radius: 16px; padding: 34px 30px; box-shadow: 0 14px 36px rgba(24, 62, 43, 0.22); }
.uonet-pill { display: inline-block; background: rgba(255, 255, 255, 0.16); color: #e2f5ec; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.7px; padding: 4px 12px; border-radius: 20px; margin-bottom: 12px; }
.uonet-panel-top h2 { font-size: 24px; margin-bottom: 10px; color: #fff; }
.uonet-panel-top p { font-size: 14px; color: rgba(255, 255, 255, 0.88); line-height: 1.55; margin-bottom: 20px; }
.uonet-login-btn { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; background: #ffffff; color: var(--green-dark); text-decoration: none; font-weight: 700; font-size: 15px; padding: 13px 20px; border-radius: 10px; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18); transition: transform 0.2s ease, box-shadow 0.2s ease; }
.uonet-login-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0, 0, 0, 0.26); }

.uonet-guides-divider { margin: 26px 0 18px; border-top: 1px solid rgba(255, 255, 255, 0.18); padding-top: 16px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.6px; color: rgba(255, 255, 255, 0.78); font-weight: 600; text-align: center; }
.uonet-banners-modern { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
@media (max-width: 480px) { .uonet-banners-modern { grid-template-columns: 1fr; } }
.uonet-guide-card { background: rgba(255, 255, 255, 0.1); border: 1px solid rgba(255, 255, 255, 0.18); border-radius: 12px; padding: 12px; text-decoration: none; color: #fff; display: flex; flex-direction: column; align-items: center; text-align: center; transition: transform 0.25s ease, background 0.25s ease; }
.uonet-guide-card:hover { transform: translateY(-4px); background: rgba(255, 255, 255, 0.18); }
.uonet-guide-card img { width: 100%; max-width: 175px; height: auto; border-radius: 6px; margin-bottom: 10px; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2); }
.uonet-guide-caption { display: flex; flex-direction: column; gap: 3px; }
.uonet-guide-caption strong { font-size: 13px; color: #fff; }
.uonet-guide-caption span { font-size: 11.5px; color: #b9ebd4; }
.uonet-guide-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; width: 100%; margin-top: 10px; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, 0.16); }
.uonet-preview-btn { flex: 1; justify-content: center; font-size: 12px; padding: 6px 10px; border-radius: 7px; }
.uonet-dl-btn { flex: 1; display: inline-flex; align-items: center; justify-content: center; background: #ffffff; color: var(--green-dark); text-decoration: none; font-size: 12px; font-weight: 700; padding: 6px 10px; border-radius: 7px; white-space: nowrap; transition: background 0.2s ease; }
.uonet-dl-btn:hover { background: #e6f5ee; }

/* STOPKA */
.site-footer { background-color: #1c2622; color: #e0e8e4; padding-top: 50px; font-size: 14px; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; padding-bottom: 40px; }
.site-footer h3 { color: var(--green-light); font-size: 16px; margin: 16px 0 6px; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 6px; }
.site-footer a { color: #ffffff; text-decoration: none; }
.site-footer a:hover { color: var(--green-light); }
.footer-bottom { background-color: #141c19; padding: 18px 0; text-align: center; font-size: 13px; color: #9cb0a7; }

.cookie-banner { position: fixed; bottom: 0; left: 0; right: 0; background: #ffffff; box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15); padding: 16px 0; z-index: 999; }
.cookie-inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; font-size: 14px; }

/* ==========================================================================
   ANIMACJE WEJŚCIA (lekkie: CSS + IntersectionObserver, bez bibliotek)
   Działają tylko gdy <html> ma klasę .motion (ustawianą w <head> przy braku
   prefers-reduced-motion). Animowane są wyłącznie transform, opacity i filter.
   ========================================================================== */
@keyframes m-in-left { from { opacity: 0; transform: translateX(-28px); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes m-in-up { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes m-slide-up { from { transform: translateY(100%); } to { transform: none; } }
@keyframes m-slide-out { to { transform: translateY(100%); opacity: 0; } }

/* 1. Hero – napis wjeżdża z lewej z wyostrzeniem */
.motion .hero-content h1,
.motion .hero-content p { animation: m-in-left 0.9s cubic-bezier(0.22, 1, 0.36, 1) both; }
.motion .hero-content h1 { animation-delay: 0.1s; }
.motion .hero-content p { animation-delay: 0.32s; }

/* 4. Baner podstron – tytuł, okruszki i karta cytatu */
.motion .subpage-banner h1 { animation: m-in-up 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.05s both; }
.motion .subpage-banner .breadcrumbs { animation: m-in-up 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.2s both; }
.motion .subpage-banner-quote { animation: m-in-up 0.75s cubic-bezier(0.22, 1, 0.36, 1) 0.16s both; }

/* 2, 3, 5. Odsłanianie elementów przy przewijaniu (atrybut nadawany w site.js, zdejmowany po animacji) */
.motion [data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity 0.6s ease, transform 0.75s cubic-bezier(0.22, 1, 0.36, 1); transition-delay: calc(var(--reveal-i, 0) * 80ms); }
.motion [data-reveal].is-inview { opacity: 1; transform: none; }

/* 3. Nagłówek sekcji – podkreślenie „rysowane” od lewej */
.motion .section-heading h2 { position: relative; border-bottom-color: transparent; }
.motion .section-heading h2::after { content: ''; position: absolute; left: 0; right: 0; bottom: -3px; height: 3px; background: var(--green-primary); transform: scaleX(0); transform-origin: left center; transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.25s; }
.motion .section-heading.is-inview h2::after,
.motion .section-heading.is-revealed h2::after { transform: scaleX(1); }

/* 11. Baner cookies – wjazd z dołu i płynne schowanie */
.motion .cookie-banner { animation: m-slide-up 0.55s cubic-bezier(0.22, 1, 0.36, 1) 0.8s both; }
.motion .cookie-banner.is-leaving { animation: m-slide-out 0.3s ease forwards; }

/* 12. Pasek postępu czytania (dłuższe podstrony) */
.scroll-progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 1000; background: linear-gradient(90deg, var(--green-primary), var(--green-light)); transform: scaleX(0); transform-origin: left center; pointer-events: none; will-change: transform; }

/* ==========================================================================
   RESPONSYWNOŚĆ (RWD) – TABLETY (<= 980px), SMARTFONY (<= 768px I <= 480px)
   ========================================================================== */
@media (max-width: 980px) {
  .header-inner { flex-wrap: wrap; justify-content: space-between; gap: 16px; }
  .brand-logo img { height: 64px; }
  .topbar-theme-toggle { display: none; }
  .header-tools { display: flex; order: 2; margin-left: auto; }
  .nav-toggle { display: inline-flex; }
  .main-nav { order: 3; margin-left: 0; display: none; width: 100%; padding-top: 12px; margin-top: 8px; border-top: 1px solid #e6f0eb; }
  .main-nav.is-open { display: block; }
  .main-nav > ul { flex-direction: column; align-items: stretch; gap: 4px; flex-wrap: nowrap; }
  .main-nav > ul > li { width: 100%; }
  .main-nav a { width: 100%; justify-content: space-between; padding: 11px 14px; border-radius: 8px; font-size: 15.5px; white-space: normal; }
  .main-nav a.active { border-bottom: none; background: #edf7f2; font-weight: 700; }
  .main-nav a.btn-contact { justify-content: center; margin-top: 6px; padding: 12px 20px; }

  .dropdown-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; background: #f6fbf8; border: 1px solid #e1efe8; border-radius: 8px; padding: 6px; margin: 4px 0 6px; display: none; }
  .has-dropdown.dropdown-open > .dropdown-menu { display: block; }
  .dropdown-menu li a { padding: 10px 14px; border-radius: 6px; white-space: normal; }
  .dropdown-menu li a:hover { background: #e6f4ee; }

  .hero { min-height: 390px; }
  .hero-content { padding-top: 44px; padding-bottom: 54px; }
  .hero-content h1 { font-size: 36px; }
  .hero-content p { font-size: 21px; }

  .subpage-banner-inner { flex-direction: column; align-items: stretch; gap: 18px; }
  .subpage-banner-head { flex: none; min-width: 0; }
  .subpage-banner-quote { flex: none; max-width: 100%; width: 100%; margin-left: 0; }
}

@media (max-width: 768px) {
  .topbar { font-size: 13px; padding: 8px 0; }
  .topbar-inner { justify-content: center; gap: 8px 18px; text-align: center; }
  .topbar-left, .topbar-right { flex-wrap: wrap; justify-content: center; gap: 8px 16px; }

  .hero { min-height: 330px; }
  .hero-content { padding-top: 34px; padding-bottom: 44px; }
  .hero-content h1 { font-size: 29px; margin-bottom: 12px; }
  .hero-content p { font-size: 18px; }
  .quick-links-section { margin-top: -28px; margin-bottom: 44px; }
  .quick-card { padding: 22px 20px; }
  .quick-card-photo { min-height: 190px; }
  .quick-card-photo h3 { font-size: 21px; }

  .subpage-banner { padding: 24px 0; margin-bottom: 28px; }
  .subpage-banner h1 { font-size: 26px; line-height: 1.28; }
  .subpage-quote-card { padding: 11px 13px; gap: 12px; }
  .subpage-quote-cover-wrap { flex: 0 0 48px; width: 48px; height: 68px; }
  .subpage-banner blockquote.subpage-quote-text { font-size: 13px; }
  .subpage-quote-source { max-width: 210px; }
  .page-content { margin-bottom: 42px; }
  .section-heading h2 { font-size: 26px; }
  .post-header h1 { font-size: 25px; line-height: 1.3; }
  .bar-heading { font-size: 21px; }

  /* Wyrównanie wyjustowanych akapitów na wąskich ekranach (zapobiega lukom między wyrazami) */
  .memoir-content p,
  .patron-story-p,
  .patron-story-highlight p,
  .patron-summary-card p,
  .uh-main-card p,
  .uh-side-card p,
  .upbringing-feature-card p,
  .prevention-card p,
  .social-story-card p,
  .spc-principles p,
  .philo-parent-body p,
  .ed-rec-hero-text p { text-align: left; }

  /* Wygodne odstępy w dużych kartach na ekranach mobilnych */
  .history-memoir-card,
  .patron-naming-section,
  .uh-main-card,
  .uh-side-card,
  .sgh-main,
  .ed-rec-hero-text,
  .ed-dual-diploma,
  .uonet-panel,
  .philo-parent-hero,
  .ed-questionnaire-banner { padding: 24px 20px; }

  .history-patron-banner { flex-direction: column; align-items: flex-start; padding: 22px 20px; gap: 14px; }
  .sgh-main h2 { font-size: 22px; }
  .uh-main-card h2 { font-size: 20px; }
  .uh-main-card h2 span { font-size: 23px; }
  .patron-naming-header h2 { font-size: 22px; }
  .lsh-content-col h3 { font-size: 21px; }
  .pq-large-text { font-size: 18px !important; }

  /* Dokumenty, wiersze formularzy i banery pomocnicze */
  .form-doc-row { flex-wrap: wrap; gap: 12px; padding: 16px; }
  .form-doc-action { width: 100%; text-align: center; }
  .rec-form-btns { width: 100%; flex-wrap: wrap; }
  .rec-form-btns .form-doc-action,
  .rec-form-btns .ldc-preview-btn { flex: 1; text-align: center; justify-content: center; }
  .legal-helper-bar { flex-direction: column; align-items: flex-start; padding: 20px; }
  .legal-helper-bar .hub-btn-primary { width: 100%; justify-content: center; }

  /* Okna modalne PDF i dokumentów Patrona na telefonie */
  .pdf-preview-modal { padding: 10px; }
  .pdf-preview-dialog { height: 92vh; border-radius: 10px; }
  .pdf-preview-header { flex-wrap: wrap; padding: 12px 14px; gap: 10px; }
  .pdf-preview-header strong { font-size: 14px; }
  .patron-doc-modal { padding: 14px; }
  .patron-doc-close { top: 8px; right: 8px; }

  /* Lightbox galerii na urządzeniach mobilnych */
  .slo-lb-topbar { padding: 10px 14px; flex-wrap: wrap; gap: 8px; }
  .slo-lb-title { display: none; }
  .slo-lb-stage { padding: 58px 16px 86px; }
  .slo-lb-nav { width: 42px; height: 42px; }
  .slo-lb-prev { left: 8px; }
  .slo-lb-next { right: 8px; }

  /* Baner cookies */
  .cookie-inner { flex-direction: column; text-align: center; gap: 12px; }
  .cookie-inner .btn-primary { width: 100%; max-width: 280px; }
}

/* ==========================================================================
   INTERAKTYWNY PLAN LEKCJI (ZAKŁADKA „DLA UCZNIA” – NA GÓRZE STRONY)
   ========================================================================== */
.student-schedule-card {
  background: #ffffff;
  border: 1px solid #dcebe3;
  border-radius: 18px;
  box-shadow: 0 12px 34px rgba(15, 78, 55, 0.06);
  padding: 28px 30px;
  margin-bottom: 34px;
  position: relative;
  overflow: hidden;
}
.student-schedule-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 5px;
  background: linear-gradient(90deg, #0f4e37 0%, #197a56 55%, #d97706 100%);
}
.student-schedule-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  flex-wrap: wrap;
  padding-bottom: 22px;
  border-bottom: 1px solid #e6f0eb;
  margin-bottom: 22px;
}
.student-schedule-title-col {
  flex: 1;
  min-width: 280px;
}
.student-schedule-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #0f4e37;
  background: #eaf5f0;
  border: 1px solid #cce3d8;
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 10px;
}
.live-indicator-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.22);
  display: inline-block;
}
.student-schedule-title-col h2 {
  font-size: 26px;
  font-weight: 800;
  color: #112a21;
  margin: 0 0 6px;
  letter-spacing: -0.02em;
}
.student-schedule-sub {
  font-size: 14.5px;
  color: #4b635a;
  margin: 0;
  line-height: 1.55;
}
.student-schedule-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 24px;
  align-items: flex-end;
  background: #f6fbf8;
  border: 1px solid #e2efe9;
  padding: 14px 18px;
  border-radius: 14px;
}
.sched-filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.sched-filter-label {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #527064;
}
.sched-pills-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.sched-pill {
  appearance: none;
  border: 1px solid #cfe2d9;
  background: #ffffff;
  color: #1e3a2f;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 600;
  padding: 7px 13px;
  border-radius: 9px;
  cursor: pointer;
  transition: all 0.18s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  line-height: 1.2;
}
.sched-pill:hover {
  border-color: #197a56;
  background: #edf7f2;
  color: #0f4e37;
  transform: translateY(-1px);
}
.sched-pill.active {
  background: #0f4e37;
  border-color: #0f4e37;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(15, 78, 55, 0.24);
}
.sched-pill-class.active {
  background: linear-gradient(135deg, #0f4e37, #197a56);
}
.sched-pill-weekend {
  border-style: dashed;
  border-color: #d97706;
  color: #92400e;
  background: #fffbeb;
}
.sched-pill-weekend.active {
  background: #d97706;
  border-color: #d97706;
  border-style: solid;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(217, 119, 6, 0.25);
}
.pill-today-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  display: inline-block;
}
.sched-pill.active .pill-today-dot {
  background: #6ee7b7;
}
.sched-pill-long { display: inline; }
.sched-pill-short { display: none; }

/* Panele widoku planu */
.sched-view-panel {
  display: none;
  animation: schedFadeIn 0.22s ease;
}
.sched-view-panel.active {
  display: block;
}
@keyframes schedFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Widok weekendowy (wolne od zajęć) */
.sched-weekend-banner {
  background: linear-gradient(135deg, #f3faf6 0%, #fffbeb 100%);
  border: 1px solid #d7ebe1;
  border-radius: 16px;
  padding: 36px 28px;
  text-align: center;
  max-width: 780px;
  margin: 8px auto 12px;
}
.sched-weekend-icon {
  font-size: 46px;
  line-height: 1;
  margin-bottom: 12px;
}
.sched-weekend-banner h3 {
  font-size: 23px;
  font-weight: 800;
  color: #0f4e37;
  margin: 0 0 10px;
}
.sched-weekend-banner p {
  font-size: 15px;
  color: #466056;
  max-width: 600px;
  margin: 0 auto 22px;
  line-height: 1.6;
}
.sched-weekend-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.sched-weekend-class-btn {
  appearance: none;
  background: #ffffff;
  border: 1px solid #bfd8cc;
  color: #0f4e37;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  padding: 10px 18px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.18s ease;
}
.sched-weekend-class-btn:hover {
  background: #edf7f2;
  border-color: #0f4e37;
  transform: translateY(-1px);
}
.sched-weekend-class-btn.primary {
  background: #0f4e37;
  border-color: #0f4e37;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(15, 78, 55, 0.2);
}
.sched-weekend-class-btn.primary:hover {
  background: #146346;
}

/* Tabela planu lekcji */
.sched-table-wrap {
  overflow-x: auto;
  border: 1px solid #dfe9e4;
  border-radius: 14px;
  background: #ffffff;
}
.student-schedule-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
  font-size: 13.5px;
}
.student-schedule-table thead th {
  background: #124d38;
  color: #ffffff;
  font-weight: 700;
  text-align: left;
  padding: 12px 14px;
  font-size: 13px;
  letter-spacing: 0.02em;
  border-right: 1px solid rgba(255, 255, 255, 0.12);
}
.student-schedule-table thead th:last-child {
  border-right: none;
}
.student-schedule-table thead th.col-nr {
  width: 58px;
  text-align: center;
}
.student-schedule-table thead th.col-time {
  width: 118px;
  text-align: center;
}
.student-schedule-table thead th.col-class,
.student-schedule-table thead th.col-day {
  width: calc((100% - 176px) / 4);
}
.student-schedule-table.class-week-table thead th.col-day {
  width: calc((100% - 176px) / 5);
}
.student-schedule-table thead th.is-today-col {
  background: #0c3b2a;
  box-shadow: inset 0 -3px 0 #fbbf24;
}
.th-class-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.16);
  padding: 3px 10px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 13px;
}
.today-col-tag {
  display: inline-block;
  margin-left: 6px;
  background: #fbbf24;
  color: #112a21;
  font-size: 10.5px;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 999px;
  vertical-align: middle;
}
.student-schedule-table tbody td {
  padding: 9px 11px;
  border-bottom: 1px solid #e9f1ed;
  border-right: 1px solid #eef4f1;
  vertical-align: middle;
}
.student-schedule-table tbody td:last-child {
  border-right: none;
}
.student-schedule-table tbody tr:last-child td {
  border-bottom: none;
}
.student-schedule-table tbody tr:nth-child(even) {
  background: #fafdfc;
}
.student-schedule-table tbody td.is-today-col {
  background: rgba(16, 185, 129, 0.04);
}
.sched-row-quiet {
  opacity: 0.72;
}
.sched-lesson-row.is-live-lesson {
  background: #ecfdf5 !important;
  box-shadow: inset 4px 0 0 #10b981;
}
.sched-nr-cell {
  text-align: center;
}
.sched-nr-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: #eef5f1;
  color: #0f4e37;
  font-weight: 800;
  font-size: 12.5px;
}
.sched-lesson-row.is-live-lesson .sched-nr-pill {
  background: #10b981;
  color: #ffffff;
}
.sched-time-cell {
  text-align: center;
  white-space: nowrap;
}
.sched-time-range {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12.5px;
  font-weight: 600;
  color: #3b554a;
  background: #f3f8f5;
  padding: 4px 8px;
  border-radius: 6px;
  border: 1px solid #e2ede7;
}
.sched-long-break-row td {
  background: #fffbeb !important;
  color: #92400e;
  text-align: center;
  font-size: 12.5px;
  padding: 6px 12px !important;
  border-top: 1px dashed #fcd34d;
  border-bottom: 1px dashed #fcd34d;
}

/* Kafelki przedmiotów wewnątrz komórki */
.sched-cell-stack {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.sched-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 9px;
  border-radius: 8px;
  border-left: 3.5px solid #197a56;
  background: #f4faf7;
  line-height: 1.25;
}
.sched-cat-stem {
  border-left-color: #2563eb;
  background: #eff6ff;
}
.sched-cat-human {
  border-left-color: #7c3aed;
  background: #f5f3ff;
}
.sched-cat-lang {
  border-left-color: #0891b2;
  background: #ecfeff;
}
.sched-cat-nature {
  border-left-color: #059669;
  background: #ecfdf5;
}
.sched-cat-sport {
  border-left-color: #d97706;
  background: #fffbeb;
}
.sched-cat-general {
  border-left-color: #64748b;
  background: #f8fafc;
}
.sched-subj {
  font-weight: 600;
  color: #162e25;
  font-size: 13px;
}
.sched-meta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}
.sched-lvl {
  font-size: 10.5px;
  font-weight: 800;
  padding: 1.5px 6px;
  border-radius: 5px;
  letter-spacing: 0.02em;
}
.sched-lvl-p {
  background: #dbeafe;
  color: #1e40af;
}
.sched-lvl-r {
  background: #fae8ff;
  color: #86198f;
}
.sched-lvl-fak {
  background: #fef3c7;
  color: #92400e;
}
.sched-room {
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  color: #334155;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(148, 163, 184, 0.42);
  padding: 1.5px 6px;
  border-radius: 5px;
  white-space: nowrap;
  transition: all 0.15s ease;
}
button.sched-room {
  cursor: pointer;
}
button.sched-room:hover {
  background: #0f4e37;
  border-color: #0f4e37;
  color: #ffffff;
}
.sched-empty {
  color: #cbd5e1;
  font-weight: 500;
  display: block;
  text-align: center;
  user-select: none;
}

/* Pasek narzędzi wybranej klasy (pobieranie do pliku PDF i drukowanie) */
.sched-class-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px 20px;
  background: linear-gradient(135deg, #f1faf5 0%, #f8fafc 100%);
  border: 1px solid #cce3d8;
  border-radius: 13px;
  padding: 14px 18px;
  margin-bottom: 14px;
}
.sched-class-toolbar-info {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.sched-class-toolbar-info strong {
  display: block;
  font-size: 14.5px;
  color: #112a21;
}
.sched-class-toolbar-sub {
  display: block;
  font-size: 12.5px;
  color: #4b635a;
}
.sched-class-toolbar-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #0f4e37;
  color: #ffffff;
  font-weight: 800;
  font-size: 13px;
  padding: 6px 13px;
  border-radius: 9px;
  white-space: nowrap;
}
.sched-class-toolbar-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.sched-pdf-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #0f4e37;
  color: #ffffff !important;
  text-decoration: none !important;
  font-size: 13.5px;
  font-weight: 700;
  padding: 9px 16px;
  border-radius: 9px;
  border: 1px solid #0f4e37;
  box-shadow: 0 4px 12px rgba(15, 78, 55, 0.2);
  transition: all 0.18s ease;
}
.sched-pdf-download-btn:hover {
  background: #146346;
  border-color: #146346;
  transform: translateY(-1px);
}
.sched-print-direct-btn {
  appearance: none;
  background: #ffffff;
  color: #1e3a2f;
  border: 1px solid #bfd8cc;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  padding: 9px 14px;
  border-radius: 9px;
  cursor: pointer;
  transition: all 0.18s ease;
}
.sched-print-direct-btn:hover {
  background: #edf7f2;
  border-color: #0f4e37;
  color: #0f4e37;
}

/* Widok przez sale – dostępność sal lekcyjnych */
.sched-pill-room-map {
  background: #f0fdf4;
  border-color: #86efac;
  color: #14532d;
}
.sched-pill-room {
  padding: 6px 10px;
  font-size: 12.5px;
}
.sched-rooms-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px 20px;
  background: #f6fbf8;
  border: 1px solid #dbece3;
  border-radius: 13px;
  padding: 14px 18px;
  margin-bottom: 14px;
}
.sched-rooms-bar-left strong {
  display: block;
  font-size: 15px;
  color: #0f4e37;
  margin-bottom: 2px;
}
.sched-rooms-bar-left span {
  font-size: 12.5px;
  color: #4b635a;
}
.sched-rooms-day-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.sched-room-day-btn {
  appearance: none;
  background: #ffffff;
  border: 1px solid #cfe2d9;
  color: #1e3a2f;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.16s ease;
}
.sched-room-day-btn:hover {
  background: #edf7f2;
  border-color: #197a56;
}
.sched-room-day-btn.active {
  background: #0f4e37;
  border-color: #0f4e37;
  color: #ffffff;
}
.sched-rooms-day-matrix {
  display: none;
}
.sched-rooms-day-matrix.active {
  display: block;
}
.rooms-matrix-table {
  min-width: 980px;
}
.rooms-matrix-table thead th.col-room {
  text-align: center;
  padding: 9px 6px;
}
.th-room-btn {
  appearance: none;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 7px;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.th-room-btn:hover {
  background: #fbbf24;
  border-color: #fbbf24;
  color: #112a21;
}
.room-cell-free {
  text-align: center;
  vertical-align: middle;
  background: linear-gradient(180deg, rgba(236, 253, 245, 0.78) 0%, rgba(209, 250, 229, 0.44) 100%) !important;
  box-shadow: inset 0 0 0 1px rgba(16, 185, 129, 0.16);
  transition: background 0.16s ease, box-shadow 0.16s ease;
}
.room-cell-free:hover {
  background: rgba(209, 250, 229, 0.75) !important;
  box-shadow: inset 0 0 0 1px rgba(16, 185, 129, 0.34);
}
.room-free-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.86);
  color: #047857;
  border: 1px solid rgba(16, 185, 129, 0.28);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
  box-shadow: 0 1px 2px rgba(16, 185, 129, 0.06);
}
.room-free-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
  flex-shrink: 0;
}
.room-cell-busy {
  background: #ffffff;
}
.room-busy-chip {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-left: 3px solid #94a3b8;
  border-radius: 6px;
  padding: 4px 7px;
  font-size: 11.5px;
  line-height: 1.25;
}
.room-busy-chip-lg {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding: 6px 9px;
  font-size: 12.5px;
}
.room-busy-cls {
  appearance: none;
  border: none;
  font-family: inherit;
  font-weight: 800;
  font-size: 11px;
  color: #334155;
  background: #e2e8f0;
  padding: 1.5px 6px;
  border-radius: 4px;
  align-self: flex-start;
  cursor: pointer;
  transition: all 0.15s ease;
}
button.room-busy-cls:hover {
  background: #0f4e37;
  color: #ffffff;
}
.room-busy-subj {
  color: #475569;
  font-weight: 600;
}

/* Wydruk bezpośredni (@media print) dla planu wybranej klasy */
@media print {
  @page { size: A4 landscape; margin: 10mm; }
  .topbar, .site-header, .subpage-banner, .site-footer, .cookie-banner, .site-alert-bar,
  .student-schedule-controls, .sched-class-toolbar-actions, .school-info-grid, .edziennik-banner {
    display: none !important;
  }
  .page-content, .container {
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  .student-schedule-card {
    box-shadow: none !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  .student-schedule-table {
    min-width: 100% !important;
    font-size: 11px !important;
  }
}

/* Stopka / legenda pod planem lekcji */
.student-schedule-legend {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px 20px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #edf4f0;
  font-size: 12.5px;
  color: #526b60;
}
.legend-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

/* Elementy pomocnicze dla widoku mobilnego (ukryte na komputerze) */
.mob-lesson-title {
  display: none;
}

@media (max-width: 768px) {
  .student-schedule-card {
    padding: 18px 14px;
    border-radius: 14px;
  }
  .student-schedule-header {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding-bottom: 16px;
    margin-bottom: 16px;
  }
  .student-schedule-controls {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding: 12px;
  }
  .sched-pills-row {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }
  .sched-pill {
    flex-shrink: 0;
    font-size: 13px;
    padding: 7px 11px;
  }
  .sched-pill-long { display: none; }
  .sched-pill-short { display: inline; }
  .sched-weekend-banner { padding: 24px 16px; }

  /* Pasek akcji PDF wybranej klasy lub sali na telefonie */
  .sched-class-toolbar,
  .sched-rooms-bar {
    flex-direction: column;
    align-items: stretch;
    padding: 12px 14px;
    gap: 10px;
  }
  .sched-class-toolbar-actions {
    width: 100%;
  }
  .sched-pdf-download-btn {
    flex: 1;
    justify-content: center;
    text-align: center;
  }
  .sched-rooms-day-tabs {
    width: 100%;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
  }
  .sched-room-day-btn {
    flex-shrink: 0;
  }

  /* ========================================================================
     GŁÓWNA TABELA PLANU LEKCJI NA TELEFONIE -> CZYTELNE KARTY LEKCYJNE (0 PX PRZEWIJANIA POZIOMEGO)
     ======================================================================== */
  .sched-table-wrap {
    overflow-x: visible;
    border: none;
    background: transparent;
  }
  .student-schedule-table,
  .student-schedule-table.rooms-matrix-table,
  .student-schedule-table.class-week-table {
    display: block;
    min-width: 0 !important;
    width: 100% !important;
  }
  .student-schedule-table thead {
    display: none;
  }
  .student-schedule-table tbody {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }
  .student-schedule-table tbody tr.sched-lesson-row {
    display: grid;
    grid-template-columns: 1fr auto;
    border: 1px solid #d5e6dd;
    border-radius: 12px;
    background: #ffffff !important;
    box-shadow: 0 3px 10px rgba(15, 78, 55, 0.05);
    overflow: hidden;
  }
  .student-schedule-table tbody tr.sched-lesson-row.is-live-lesson {
    border-color: #10b981;
    box-shadow: 0 4px 16px rgba(16, 185, 129, 0.18);
  }

  /* Nagłówek pojedynczej karty lekcji (Nr lekcji po lewej + Godziny dzwonków po prawej) */
  .student-schedule-table tbody td.col-nr {
    grid-column: 1 / 2;
    grid-row: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    background: #124d38;
    color: #ffffff;
    padding: 8px 12px;
    border: none;
    text-align: left;
  }
  .student-schedule-table tbody tr.sched-lesson-row.is-live-lesson td.col-nr {
    background: #059669;
  }
  .student-schedule-table tbody td.col-nr .sched-nr-pill {
    width: 24px;
    height: 24px;
    font-size: 12px;
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
  }
  .mob-lesson-title {
    display: inline;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.01em;
  }
  .student-schedule-table tbody td.col-time {
    grid-column: 2 / 3;
    grid-row: 1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    background: #124d38;
    padding: 8px 12px;
    border: none;
  }
  .student-schedule-table tbody tr.sched-lesson-row.is-live-lesson td.col-time {
    background: #059669;
  }
  .student-schedule-table tbody td.col-time .sched-time-range {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.25);
    color: #ffffff;
    font-size: 12px;
    padding: 3px 8px;
  }

  /* Wiersze danych wewnątrz karty lekcji (Klasy / Dni tygodnia) */
  .student-schedule-table tbody td:not(.col-nr):not(.col-time) {
    grid-column: 1 / -1;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 12px;
    border-bottom: 1px solid #edf4f0;
    border-right: none;
    text-align: left;
  }
  .student-schedule-table tbody td:not(.col-nr):not(.col-time)::before {
    content: attr(data-label);
    font-size: 11.5px;
    font-weight: 800;
    color: #0f4e37;
    background: #eaf5f0;
    border: 1px solid #cde4d9;
    padding: 3px 8px;
    border-radius: 6px;
    white-space: nowrap;
    flex-shrink: 0;
    margin-top: 2px;
  }
  .student-schedule-table tbody td:not(.col-nr):not(.col-time) .sched-cell-stack {
    flex: 1;
    min-width: 0;
  }
  .student-schedule-table tbody td:not(.col-nr):not(.col-time) .sched-empty {
    text-align: right;
    flex: 1;
    font-size: 12.5px;
  }

  /* Mapa wszystkich sal (Sale 1–10) na telefonie: dwukolumnowa siatka kafelków sal wewnątrz karty lekcji */
  .rooms-matrix-table tbody tr.sched-lesson-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .rooms-matrix-table tbody td.col-nr {
    grid-column: 1 / 2;
  }
  .rooms-matrix-table tbody td.col-time {
    grid-column: 2 / 3;
  }
  .rooms-matrix-table tbody td[data-col-room] {
    grid-column: span 1 !important;
    flex-direction: column;
    align-items: stretch;
    gap: 5px;
    padding: 8px 10px;
    border-right: 1px solid #edf4f0;
  }
  .rooms-matrix-table tbody td[data-col-room]::before {
    align-self: flex-start;
    font-size: 11px;
    padding: 2px 7px;
  }
  .rooms-matrix-table tbody td.room-cell-free {
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
  }

  /* Wiersz długiej przerwy na telefonie */
  .student-schedule-table tbody tr.sched-long-break-row {
    display: block;
    border-radius: 10px;
    overflow: hidden;
  }
  .student-schedule-table tbody tr.sched-long-break-row td {
    display: block;
    width: 100%;
    border-radius: 10px;
    padding: 8px 12px !important;
  }
  .student-schedule-table tbody tr.sched-long-break-row td::before {
    display: none !important;
  }
}

@media (max-width: 480px) {
  .container, .page-content { padding-left: 16px; padding-right: 16px; }
  .brand-logo img { height: 54px; }
  .hero-content h1 { font-size: 25px; }
  .hero-content p { font-size: 16px; }
  .subpage-banner h1 { font-size: 22px; }

  .hub-feature-card { flex-direction: column; padding: 20px 18px; gap: 14px; }
  .hub-btn-primary, .hub-btn-outline { width: 100%; justify-content: center; text-align: center; }

  .psc-head { flex-direction: column; align-items: flex-start; gap: 10px; }
  .cic-header { flex-direction: column; align-items: flex-start; gap: 12px; }
  .hymn-sheet-header { flex-direction: column; align-items: flex-start; gap: 10px; }
  .hymn-sheet-header h2 { font-size: 22px; }
  .ed-platform-box { flex-direction: column; gap: 12px; }
  .ppb-hosts-box { flex-direction: column; align-items: flex-start; }
  .sgh-rule-pill { flex-direction: column; align-items: flex-start; gap: 10px; }

  .lsh-actions, .eqb-actions, .rdc-actions, .ldc-footer { flex-direction: column; align-items: stretch; }
  .lsh-btn-primary, .lsh-btn-preview, .ldc-preview-btn { width: 100%; justify-content: center; text-align: center; }

  .directors-timeline-list li { flex-direction: column; align-items: flex-start; gap: 4px; }
  .directors-timeline-list strong { text-align: left; }
  .patron-quote-card { padding: 22px 18px; }
  .patron-quote-card footer { flex-direction: column; align-items: flex-start; gap: 4px; }

  .slo-lb-article-btn { font-size: 12px; padding: 6px 10px; }

  .site-alert-inner { gap: 10px; }
  .site-alert-actions { width: 100%; justify-content: space-between; }
  .site-alert-link { flex: 1; justify-content: center; text-align: center; }

  .theme-toggle { height: 38px; padding: 0 11px; font-size: 12px; }
}

@media (max-width: 380px) {
  .theme-toggle-label { display: none; }
  .theme-toggle { width: 38px; padding: 0; }
}

/* ==========================================================================
   TRYB NOCNY (DARK MODE) – AUTOMATYCZNY PO ZMIERZCHU W TARNOWIE LUB RĘCZNY
   Stonowana, ciepła paleta ciemnego grafitu i leśnej zieleni chroniąca wzrok
   uczniów przeglądających stronę i plan lekcji wieczorem / przed snem.
   ========================================================================== */
html[data-theme="dark"] {
  color-scheme: dark;
  --green-primary: #46b88a;
  --green-light: #72e0b1;
  --green-dark: #9ef0cb;
  --text-dark: #e6f0ec;
  --text-white: #ffffff;
}

html[data-theme="dark"] body {
  background-color: #0e1613;
  color: var(--text-dark);
}

/* Topbar, Header i Nawigacja */
html[data-theme="dark"] .topbar {
  background: linear-gradient(180deg, #163d2e 0%, #102b20 100%);
  border-bottom: 1px solid #1f3d31;
}
html[data-theme="dark"] .topbar-theme-toggle {
  background: rgba(114, 224, 177, 0.14);
  border-color: rgba(114, 224, 177, 0.34);
  color: #e6f4ee;
}
html[data-theme="dark"] .topbar-theme-toggle:hover {
  background: rgba(114, 224, 177, 0.25);
  border-color: var(--green-light);
  color: #ffffff;
}
html[data-theme="dark"] .main-header {
  background-color: #131e1a;
  border-bottom: 1px solid #1f332b;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.42);
}
html[data-theme="dark"] .brand-logo img {
  filter: invert(0.925) hue-rotate(180deg) saturate(1.15) contrast(1.05);
  mix-blend-mode: lighten;
  border-radius: 6px;
}
html[data-theme="dark"] .theme-toggle,
html[data-theme="dark"] .nav-toggle {
  background: #1b2c25;
  border-color: #2c473c;
  color: #d8eee4;
}
html[data-theme="dark"] .theme-toggle:hover,
html[data-theme="dark"] .nav-toggle:hover {
  background: #233930;
  border-color: var(--green-primary);
  color: var(--green-light);
}
html[data-theme="dark"] .dropdown-menu {
  background: #16241f;
  border: 1px solid #263d33;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}
html[data-theme="dark"] .dropdown-menu li a:hover {
  background: #1f332b;
  color: var(--green-light);
}
html[data-theme="dark"] .main-nav a.btn-contact {
  background-color: #2b7a5b;
  color: #ffffff;
}
html[data-theme="dark"] .main-nav a.btn-contact:hover {
  background-color: #35946f;
}
html[data-theme="dark"] .skip-link {
  background: #1b4334;
  color: #ffffff;
}
html[data-theme="dark"] .subpage-banner {
  background: linear-gradient(135deg, #112e23 0%, #1d543e 100%);
  border-bottom: 1px solid #25493b;
}
html[data-theme="dark"] .subpage-quote-card {
  background: rgba(11, 24, 19, 0.42);
  border-color: rgba(116, 198, 157, 0.24);
  border-left-color: #74c69d;
}
html[data-theme="dark"] .subpage-quote-card:hover {
  background: rgba(11, 24, 19, 0.56);
}
html[data-theme="dark"] .subpage-banner blockquote.subpage-quote-text {
  background: transparent;
  border: none;
  color: #eef7f2;
}

@media (max-width: 980px) {
  html[data-theme="dark"] .main-nav {
    border-top-color: #22382f;
  }
  html[data-theme="dark"] .main-nav a.active {
    background: #1c3028;
    color: var(--green-light);
  }
  html[data-theme="dark"] .dropdown-menu {
    background: #111b17;
    border-color: #22362e;
  }
}

/* Główne powierzchnie kart i kontenerów */
html[data-theme="dark"] .quick-card:not(.quick-card-photo),
html[data-theme="dark"] .news-card,
html[data-theme="dark"] .album-card,
html[data-theme="dark"] .school-info-card:not(.ed-contact-card):not(.history-tto-card),
html[data-theme="dark"] .doc-card,
html[data-theme="dark"] .legal-doc-card,
html[data-theme="dark"] .rec-doc-card,
html[data-theme="dark"] .cq-card,
html[data-theme="dark"] .hub-feature-card,
html[data-theme="dark"] .textbook-card,
html[data-theme="dark"] .form-doc-row,
html[data-theme="dark"] .rec-form-row,
html[data-theme="dark"] .upbringing-card,
html[data-theme="dark"] .prevention-card,
html[data-theme="dark"] .sgh-class-size-card,
html[data-theme="dark"] .social-care-card,
html[data-theme="dark"] .philo-pillar-card:not(.ppc-featured),
html[data-theme="dark"] .pfs-card,
html[data-theme="dark"] .patron-quote-card:not(.pq-accent),
html[data-theme="dark"] .patron-doc-card,
html[data-theme="dark"] .hymn-brand-card,
html[data-theme="dark"] .hymn-sheet-card,
html[data-theme="dark"] .history-memoir-card,
html[data-theme="dark"] .ed-rec-hero-text,
html[data-theme="dark"] .ed-rec-partner-card {
  background: #15211c !important;
  border-color: #243830;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.35);
  color: var(--text-dark);
}

html[data-theme="dark"] .textbook-card:hover,
html[data-theme="dark"] .form-doc-row:hover,
html[data-theme="dark"] .rec-form-row:hover {
  background: #1a2a23 !important;
  border-color: var(--green-primary);
}

/* Sekcje i boksy pomocnicze (drugi plan) */
html[data-theme="dark"] blockquote,
html[data-theme="dark"] .stat-pill,
html[data-theme="dark"] .filter-btn:not(.active),
html[data-theme="dark"] .album-mini-strip,
html[data-theme="dark"] .bells-list li,
html[data-theme="dark"] .role-guardian,
html[data-theme="dark"] .specialist-badge,
html[data-theme="dark"] .hours-table li,
html[data-theme="dark"] .library-hours-box,
html[data-theme="dark"] .ed-highlight-box,
html[data-theme="dark"] .ht-item,
html[data-theme="dark"] .memoir-closing,
html[data-theme="dark"] .statute-pillar-item,
html[data-theme="dark"] .campus-features-box,
html[data-theme="dark"] .campus-note,
html[data-theme="dark"] .directors-era-box,
html[data-theme="dark"] .reorg-school-box,
html[data-theme="dark"] .directors-timeline-list li,
html[data-theme="dark"] .patron-hero-card,
html[data-theme="dark"] .patron-story-highlight,
html[data-theme="dark"] .patron-bio-section,
html[data-theme="dark"] .patron-naming-section,
html[data-theme="dark"] .hymn-author-box,
html[data-theme="dark"] .hymn-stanza,
html[data-theme="dark"] .ldc-preview-btn,
html[data-theme="dark"] .legal-helper-bar,
html[data-theme="dark"] .uh-side-card,
html[data-theme="dark"] .uh-side-highlight,
html[data-theme="dark"] .upbringing-safety-box,
html[data-theme="dark"] .prevention-section,
html[data-theme="dark"] .spc-quote-box,
html[data-theme="dark"] .spc-mini-item,
html[data-theme="dark"] .social-care-section,
html[data-theme="dark"] .philo-check-list li,
html[data-theme="dark"] .ppb-hosts-box,
html[data-theme="dark"] .philo-future-section,
html[data-theme="dark"] .rec-step-item,
html[data-theme="dark"] .rec-contact-item,
html[data-theme="dark"] .ed-platform-box,
html[data-theme="dark"] .ed-friendly-note,
html[data-theme="dark"] .cic-detail-box,
html[data-theme="dark"] .cic-pill-btn,
html[data-theme="dark"] .cq-copy-btn,
html[data-theme="dark"] .pagination a:not(.active),
html[data-theme="dark"] .form-doc-action {
  background: #1a2a23 !important;
  border-color: #2a4238 !important;
  color: #d6e8df !important;
}

html[data-theme="dark"] .bells-list li:nth-child(even) {
  background: #16231d !important;
}
html[data-theme="dark"] .bells-list li.long-break-after {
  border-bottom-color: #396050 !important;
}
html[data-theme="dark"] .directors-timeline-list li.dir-current {
  background: #1e382d !important;
  border-color: var(--green-primary) !important;
}
html[data-theme="dark"] .filter-btn:hover,
html[data-theme="dark"] .ldc-preview-btn:hover,
html[data-theme="dark"] .cic-pill-btn:hover,
html[data-theme="dark"] .rec-contact-item:hover,
html[data-theme="dark"] .cq-copy-btn:hover,
html[data-theme="dark"] .cq-copy-btn.copied {
  background: #245c46 !important;
  border-color: var(--green-primary) !important;
  color: #ffffff !important;
}

/* Skala ocen Edukacji Domowej w trybie ciemnym */
html[data-theme="dark"] .ed-grading-scale li {
  background: #192821;
  color: #e2f0ea;
}
html[data-theme="dark"] .ed-grading-scale li.grade-6 { background: #143325; border-left-color: #22c55e; }
html[data-theme="dark"] .ed-grading-scale li.grade-5 { background: #162e23; border-left-color: #34d399; }
html[data-theme="dark"] .ed-grading-scale li.grade-4 { background: #182b23; border-left-color: #46b88a; }
html[data-theme="dark"] .ed-grading-scale li.grade-3 { background: #212b19; border-left-color: #84cc16; }
html[data-theme="dark"] .ed-grading-scale li.grade-2 { background: #2b2313; border-left-color: #f59e0b; }
html[data-theme="dark"] .ed-grading-scale li.grade-1 { background: #2d1818; border-left-color: #ef4444; }
html[data-theme="dark"] .grade-pct { color: #f0f9f4; }
html[data-theme="dark"] .grade-1 .grade-name { color: #fca5a5; }

/* Typografia i kontrasty tekstów na ciemnych tłach */
html[data-theme="dark"] .bar-heading,
html[data-theme="dark"] .ed-card-head h3,
html[data-theme="dark"] .hub-feature-body h2,
html[data-theme="dark"] .textbook-info strong,
html[data-theme="dark"] .form-doc-body h3,
html[data-theme="dark"] .patron-naming-header h2,
html[data-theme="dark"] .bell-time {
  color: #eef6f2;
}

html[data-theme="dark"] .news-card-body p,
html[data-theme="dark"] .news-date,
html[data-theme="dark"] .gallery-intro p,
html[data-theme="dark"] .album-meta,
html[data-theme="dark"] .album-article-link,
html[data-theme="dark"] .doc-card p,
html[data-theme="dark"] .hub-subtitle,
html[data-theme="dark"] .wf-card p,
html[data-theme="dark"] .role-label,
html[data-theme="dark"] .hours-subheading,
html[data-theme="dark"] .ed-check-list,
html[data-theme="dark"] .ed-sublist,
html[data-theme="dark"] .ed-highlight-box p,
html[data-theme="dark"] .ed-grading-desc,
html[data-theme="dark"] .history-lead,
html[data-theme="dark"] .ht-item p,
html[data-theme="dark"] .memoir-content p,
html[data-theme="dark"] .memoir-author span,
html[data-theme="dark"] .statute-pillar-item p,
html[data-theme="dark"] .campus-card p,
html[data-theme="dark"] .reorg-desc,
html[data-theme="dark"] .secretariat-group h4,
html[data-theme="dark"] .patron-story-p,
html[data-theme="dark"] .patron-story-highlight p,
html[data-theme="dark"] .patron-lifespan,
html[data-theme="dark"] .patron-pillar-card p,
html[data-theme="dark"] .patron-summary-card p,
html[data-theme="dark"] .patron-quote-card:not(.pq-accent) p,
html[data-theme="dark"] .patron-quote-card:not(.pq-accent) footer span,
html[data-theme="dark"] .patron-naming-header p,
html[data-theme="dark"] .patron-doc-meta span,
html[data-theme="dark"] .hymn-brand-card p,
html[data-theme="dark"] .hymn-author-box span,
html[data-theme="dark"] .hymn-stanza p,
html[data-theme="dark"] .hymn-sheet-footer,
html[data-theme="dark"] .ldc-size,
html[data-theme="dark"] .legal-doc-card p,
html[data-theme="dark"] .lhb-text span,
html[data-theme="dark"] .uh-side-card p,
html[data-theme="dark"] .upbringing-card p,
html[data-theme="dark"] .upbringing-feature-card p,
html[data-theme="dark"] .upbringing-safety-box p,
html[data-theme="dark"] .prevention-card p,
html[data-theme="dark"] .sgh-class-size-card p,
html[data-theme="dark"] .social-story-card p,
html[data-theme="dark"] .spc-principles p,
html[data-theme="dark"] .social-care-card p,
html[data-theme="dark"] .philo-pillar-card:not(.ppc-featured) p,
html[data-theme="dark"] .psc-lead,
html[data-theme="dark"] .philo-parent-body p,
html[data-theme="dark"] .ppb-hosts-box p,
html[data-theme="dark"] .pfs-card p,
html[data-theme="dark"] .rec-step-item span,
html[data-theme="dark"] .rdc-meta,
html[data-theme="dark"] .rec-doc-card p,
html[data-theme="dark"] .rec-contact-box p,
html[data-theme="dark"] .ed-rec-hero-text p,
html[data-theme="dark"] .ed-platform-box p,
html[data-theme="dark"] .erpc-body p,
html[data-theme="dark"] .cq-label,
html[data-theme="dark"] .cq-sub,
html[data-theme="dark"] .cic-detail-box small,
html[data-theme="dark"] .cmc-sub,
html[data-theme="dark"] .hub-feature-body p,
html[data-theme="dark"] .textbook-info span,
html[data-theme="dark"] .form-doc-body p,
html[data-theme="dark"] .page-content p[style*="color"] {
  color: #b5cbc0 !important;
}

/* Linie podziału i obramowania wewnętrzne */
html[data-theme="dark"] .info-block h2,
html[data-theme="dark"] .post-header,
html[data-theme="dark"] .gallery-intro,
html[data-theme="dark"] .album-footer,
html[data-theme="dark"] .gallery-header-row,
html[data-theme="dark"] .roles-list li,
html[data-theme="dark"] .memoir-author,
html[data-theme="dark"] .history-section,
html[data-theme="dark"] .patron-quote-card:not(.pq-accent) footer,
html[data-theme="dark"] .hymn-sheet-header,
html[data-theme="dark"] .hymn-sheet-footer,
html[data-theme="dark"] .ldc-footer,
html[data-theme="dark"] .rdc-actions,
html[data-theme="dark"] .cic-header,
html[data-theme="dark"] .cic-quick-routes,
html[data-theme="dark"] .textbook-actions,
html[data-theme="dark"] .secretariat-group[style*="border-top"] {
  border-color: #23382f !important;
}

/* Ikony w boksach, pigułki i przyciski */
html[data-theme="dark"] .ed-icon-box,
html[data-theme="dark"] .ed-check-list > li::before,
html[data-theme="dark"] .campus-icon,
html[data-theme="dark"] .era-badge,
html[data-theme="dark"] .pp-icon,
html[data-theme="dark"] .hymn-musical-icon,
html[data-theme="dark"] .stanza-num,
html[data-theme="dark"] .ldc-icon,
html[data-theme="dark"] .uc-icon,
html[data-theme="dark"] .sgh-number-label,
html[data-theme="dark"] .scc-num,
html[data-theme="dark"] .scc-icon,
html[data-theme="dark"] .ppc-num,
html[data-theme="dark"] .pfs-icon,
html[data-theme="dark"] .rdc-icon,
html[data-theme="dark"] .epb-icon,
html[data-theme="dark"] .cq-icon,
html[data-theme="dark"] .hub-feature-icon,
html[data-theme="dark"] .hub-badge,
html[data-theme="dark"] .album-year-tag,
html[data-theme="dark"] .patron-pill-subtle {
  background: #1e362c;
  color: #72e0b1;
}
html[data-theme="dark"] .album-mini-more {
  background: #1f382e;
  color: #8ee8c2;
}
html[data-theme="dark"] .btn-primary,
html[data-theme="dark"] .btn-slideshow,
html[data-theme="dark"] .hub-btn-primary {
  background: #2b7d5d;
  color: #ffffff;
}
html[data-theme="dark"] .btn-primary:hover,
html[data-theme="dark"] .btn-slideshow:hover,
html[data-theme="dark"] .hub-btn-primary:hover {
  background: #359670;
  color: #ffffff;
}
html[data-theme="dark"] .hub-btn-outline {
  background: #172620;
  color: #8ee8c2;
  border-color: #358766;
}
html[data-theme="dark"] .hub-btn-outline:hover {
  background: #2b7d5d;
  color: #ffffff;
}
html[data-theme="dark"] .psc-badge-24,
html[data-theme="dark"] .textbook-num {
  background: linear-gradient(135deg, #2b7d5d, #1b4d39);
  color: #ffffff;
}
html[data-theme="dark"] .ed-mail-btn,
html[data-theme="dark"] .lsh-btn-primary,
html[data-theme="dark"] .uonet-login-btn,
html[data-theme="dark"] .uonet-dl-btn {
  background: #ffffff;
  color: #14382a;
}
html[data-theme="dark"] .cic-logo,
html[data-theme="dark"] .hymn-logo-img {
  filter: invert(0.92) hue-rotate(180deg) saturate(1.2);
  mix-blend-mode: lighten;
}
html[data-theme="dark"] .erpc-logo-wrap {
  background: #f2f8f5;
  border-color: #2b453a;
}
html[data-theme="dark"] .cmc-frame-wrap {
  border-color: #263c33;
}
html[data-theme="dark"] .cmc-frame-wrap iframe {
  filter: invert(0.9) hue-rotate(180deg) brightness(0.95) contrast(0.92);
}

/* Baner cookies i okno modalne PDF */
html[data-theme="dark"] .cookie-banner {
  background: #16241f;
  border-top: 1px solid #284036;
  box-shadow: 0 -8px 28px rgba(0, 0, 0, 0.55);
  color: #dcebe4;
}
html[data-theme="dark"] .pdf-preview-dialog {
  background: #16241f;
  border: 1px solid #2a4238;
}

/* ==========================================================================
   PLAN LEKCJI I MACIERZ SAL W TRYBIE NOCNYM („DLA UCZNIA” I „DLA NAUCZYCIELA”)
   ========================================================================== */
html[data-theme="dark"] .student-schedule-card {
  background: #14201b;
  border-color: #243830;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.42);
}
html[data-theme="dark"] .student-schedule-header {
  border-bottom-color: #23362e;
}
html[data-theme="dark"] .student-schedule-eyebrow {
  background: #1b332a;
  border-color: #2b5243;
  color: #72e0b1;
}
html[data-theme="dark"] .student-schedule-title-col h2 {
  color: #eef6f2;
}
html[data-theme="dark"] .student-schedule-sub {
  color: #9cb5aa;
}
html[data-theme="dark"] .student-schedule-controls,
html[data-theme="dark"] .sched-rooms-bar,
html[data-theme="dark"] .sched-class-toolbar {
  background: #192822;
  border-color: #283f36;
}
html[data-theme="dark"] .sched-filter-label,
html[data-theme="dark"] .sched-class-toolbar-sub,
html[data-theme="dark"] .sched-rooms-bar-left span,
html[data-theme="dark"] .student-schedule-legend {
  color: #9cb5aa;
  border-top-color: #22362e;
}
html[data-theme="dark"] .sched-class-toolbar-info strong,
html[data-theme="dark"] .sched-rooms-bar-left strong {
  color: #e6f2ed;
}
html[data-theme="dark"] .sched-pill,
html[data-theme="dark"] .sched-room-day-btn,
html[data-theme="dark"] .sched-print-direct-btn,
html[data-theme="dark"] .sched-weekend-class-btn {
  background: #131e1a;
  border-color: #2b443a;
  color: #d6e8df;
}
html[data-theme="dark"] .sched-pill:hover,
html[data-theme="dark"] .sched-room-day-btn:hover,
html[data-theme="dark"] .sched-print-direct-btn:hover,
html[data-theme="dark"] .sched-weekend-class-btn:hover {
  background: #1f352c;
  border-color: #46b88a;
  color: #8ee8c2;
}
html[data-theme="dark"] .sched-pill.active,
html[data-theme="dark"] .sched-room-day-btn.active,
html[data-theme="dark"] .sched-weekend-class-btn.primary {
  background: #236b50;
  border-color: #359672;
  color: #ffffff;
}
html[data-theme="dark"] .sched-pill-class.active {
  background: linear-gradient(135deg, #1b5740, #2b8260);
}
html[data-theme="dark"] .sched-pill-weekend {
  background: #292012;
  border-color: #d97706;
  color: #fcd34d;
}
html[data-theme="dark"] .sched-pill-weekend.active {
  background: #b45309;
  border-color: #d97706;
  color: #ffffff;
}
html[data-theme="dark"] .sched-pill-room-map {
  background: #162e24;
  border-color: #2e6f54;
  color: #8ee8c2;
}
html[data-theme="dark"] .sched-weekend-banner {
  background: linear-gradient(135deg, #172620 0%, #241e14 100%);
  border-color: #2d443a;
}
html[data-theme="dark"] .sched-weekend-banner h3 {
  color: #72e0b1;
}
html[data-theme="dark"] .sched-weekend-banner p {
  color: #b8cfc5;
}

/* Tabela planu lekcji w trybie nocnym */
html[data-theme="dark"] .sched-table-wrap {
  background: #14201b;
  border-color: #253931;
}
html[data-theme="dark"] .student-schedule-table thead th {
  background: #103829;
  border-right-color: rgba(255, 255, 255, 0.1);
}
html[data-theme="dark"] .student-schedule-table thead th.is-today-col {
  background: #0c2c20;
}
html[data-theme="dark"] .student-schedule-table tbody td {
  border-bottom-color: #20322b;
  border-right-color: #1e2f28;
  color: #dcebe4;
}
html[data-theme="dark"] .student-schedule-table tbody tr:nth-child(even) {
  background: #17241f;
}
html[data-theme="dark"] .student-schedule-table tbody td.is-today-col {
  background: rgba(16, 185, 129, 0.07);
}
html[data-theme="dark"] .sched-lesson-row.is-live-lesson {
  background: rgba(16, 185, 129, 0.15) !important;
  box-shadow: inset 4px 0 0 #34d399;
}
html[data-theme="dark"] .sched-nr-pill {
  background: #1e322a;
  color: #72e0b1;
}
html[data-theme="dark"] .sched-time-range {
  background: #1b2c25;
  border-color: #2b4239;
  color: #b7d1c5;
}
html[data-theme="dark"] .sched-long-break-row td {
  background: #271f12 !important;
  color: #fcd34d;
  border-top-color: #92400e;
  border-bottom-color: #92400e;
}

/* Kafelki przedmiotów w komórkach planu */
html[data-theme="dark"] .sched-chip {
  background: #1b2d26;
  border-left-color: #34d399;
}
html[data-theme="dark"] .sched-cat-stem {
  background: #162438;
  border-left-color: #60a5fa;
}
html[data-theme="dark"] .sched-cat-human {
  background: #241c36;
  border-left-color: #a78bfa;
}
html[data-theme="dark"] .sched-cat-lang {
  background: #142a30;
  border-left-color: #22d3ee;
}
html[data-theme="dark"] .sched-cat-nature {
  background: #152d25;
  border-left-color: #34d399;
}
html[data-theme="dark"] .sched-cat-sport {
  background: #292012;
  border-left-color: #fbbf24;
}
html[data-theme="dark"] .sched-cat-general {
  background: #1d262f;
  border-left-color: #94a3b8;
}
html[data-theme="dark"] .sched-subj {
  color: #eef6f2;
}
html[data-theme="dark"] .sched-lvl-p {
  background: #1e3a5f;
  color: #93c5fd;
}
html[data-theme="dark"] .sched-lvl-r {
  background: #4a1d54;
  color: #f0abfc;
}
html[data-theme="dark"] .sched-lvl-fak {
  background: #452b0d;
  color: #fcd34d;
}
html[data-theme="dark"] .sched-room {
  background: rgba(14, 22, 19, 0.78);
  border-color: rgba(148, 163, 184, 0.32);
  color: #cbd5e1;
}
html[data-theme="dark"] button.sched-room:hover {
  background: #2b7d5d;
  border-color: #46b88a;
  color: #ffffff;
}
html[data-theme="dark"] .sched-empty {
  color: #42584f;
}

/* Mapa dostępności sal (Dla nauczyciela) */
html[data-theme="dark"] .room-cell-free {
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.13) 0%, rgba(16, 185, 129, 0.06) 100%) !important;
  box-shadow: inset 0 0 0 1px rgba(52, 211, 153, 0.18);
}
html[data-theme="dark"] .room-cell-free:hover {
  background: rgba(16, 185, 129, 0.22) !important;
}
html[data-theme="dark"] .room-free-badge {
  background: #132a21;
  color: #6ee7b7;
  border-color: rgba(52, 211, 153, 0.35);
}
html[data-theme="dark"] .room-cell-busy {
  background: #14201b;
}
html[data-theme="dark"] .room-busy-chip {
  background: #1b2a24;
  border-color: #2b4138;
  border-left-color: #64748b;
}
html[data-theme="dark"] .room-busy-cls {
  background: #263b32;
  color: #e2f1ea;
}
html[data-theme="dark"] .room-busy-subj {
  color: #b4cabe;
}

/* Mobilne karty planu lekcji w trybie nocnym */
@media (max-width: 768px) {
  html[data-theme="dark"] .sched-table-wrap {
    background: transparent;
  }
  html[data-theme="dark"] .student-schedule-table tbody tr.sched-lesson-row {
    background: #15221d !important;
    border-color: #263c33;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
  }
  html[data-theme="dark"] .student-schedule-table tbody td:not(.col-nr):not(.col-time) {
    border-bottom-color: #21342c;
  }
  html[data-theme="dark"] .student-schedule-table tbody td:not(.col-nr):not(.col-time)::before {
    background: #1c3229;
    border-color: #2d4c40;
    color: #72e0b1;
  }
  html[data-theme="dark"] .rooms-matrix-table tbody td[data-col-room] {
    border-right-color: #21342c;
  }
}

/* ==========================================================================
   FORMULARZ KONTAKTOWY (ZAKŁADKA KONTAKT) + TRYB NOCNY (DARK MODE)
   ========================================================================== */
.contact-form-section {
  margin-bottom: 28px;
  padding: 28px 30px;
  border-top: 4px solid var(--green-primary);
}
.cfs-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.cfs-header h2 {
  margin: 4px 0 6px;
  font-size: 24px;
  color: var(--green-dark);
}
.cfs-sub {
  margin: 0;
  font-size: 14.5px;
  color: var(--text-muted);
  max-width: 680px;
  line-height: 1.55;
}
.cfs-security-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #eff7f3;
  color: var(--green-primary);
  border: 1px solid #cce3d7;
  padding: 7px 13px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
}
.cfs-hp-wrap {
  position: absolute !important;
  left: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}
.cfs-alert {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 10px;
  margin-bottom: 20px;
  font-size: 14px;
  line-height: 1.5;
}
.cfs-alert p {
  margin: 4px 0 0;
}
.cfs-alert ul {
  margin: 6px 0 0;
  padding-left: 18px;
}
.cfs-alert-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  flex-shrink: 0;
}
.cfs-alert-success {
  background: #ecfdf5;
  border: 1px solid #6ee7b7;
  color: #065f46;
}
.cfs-alert-success .cfs-alert-icon {
  background: #10b981;
  color: #ffffff;
}
.cfs-alert-error {
  background: #fef2f2;
  border: 1px solid #fca5a5;
  color: #991b1b;
}
.cfs-alert-error .cfs-alert-icon {
  background: #dc2626;
  color: #ffffff;
}
.cfs-row-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 18px;
  margin-bottom: 18px;
}
.cfs-field {
  display: flex;
  flex-direction: column;
}
.cfs-field label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}
.cfs-req {
  color: #dc2626;
  font-weight: 800;
}
.cfs-field input[type="text"],
.cfs-field input[type="email"],
.cfs-field input[type="tel"],
.cfs-field textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14.5px;
  color: var(--text-main);
  background: #ffffff;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}
.cfs-field input:focus,
.cfs-field textarea:focus {
  outline: none;
  border-color: var(--green-primary);
  box-shadow: 0 0 0 3px rgba(31, 106, 78, 0.15);
}
.cfs-topic-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
}
.cfs-chips-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
}
.cfs-topic-chip {
  background: #f1f6f3;
  border: 1px solid #d5e4dc;
  color: var(--green-dark);
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.cfs-topic-chip:hover {
  background: var(--green-primary);
  border-color: var(--green-primary);
  color: #ffffff;
}
.cfs-contact-choice-box {
  background: #f8fbf9;
  border: 1.5px solid #d4e4dc;
  border-radius: 12px;
  padding: 16px 18px;
  margin-bottom: 18px;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
.cfs-contact-choice-box.is-valid {
  border-color: #34d399;
  background: #f2fbf7;
}
.cfs-contact-choice-box.is-invalid {
  border-color: #f87171;
  background: #fef7f7;
}
.cfs-contact-choice-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 12px;
}
.cfs-choice-title {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--green-dark);
}
.cfs-choice-hint {
  display: block;
  font-size: 12.5px;
  color: var(--text-muted);
  margin-top: 2px;
}
.cfs-choice-status {
  font-size: 12px;
  font-weight: 700;
  padding: 4px 11px;
  border-radius: 999px;
  background: #e2ece7;
  color: #2c5243;
}
.cfs-contact-choice-box.is-valid .cfs-choice-status {
  background: #d1fae5;
  color: #065f46;
}
.cfs-contact-choice-box.is-invalid .cfs-choice-status {
  background: #fee2e2;
  color: #991b1b;
}
.cfs-contact-choice-grid {
  display: grid;
  grid-template-columns: 1.15fr auto 1fr;
  align-items: center;
  gap: 14px;
}
.cfs-or-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 20px;
}
.cfs-or-divider span {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  background: #ffffff;
  border: 1px solid #d5e2dc;
  padding: 4px 10px;
  border-radius: 999px;
}
.cfs-badge-preferred {
  background: #dcfce7;
  color: #166534;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.cfs-badge-alt {
  background: #e2e8f0;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
}
.cfs-inline-error {
  margin-top: 10px;
  font-size: 13px;
  font-weight: 700;
  color: #dc2626;
}
.cfs-antibot-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 14px;
  padding: 12px 16px;
  background: #f4f8f6;
  border: 1px solid #d5e4dc;
  border-radius: 10px;
}
.cfs-antibot-label-wrap {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.cfs-antibot-badge {
  display: inline-block;
  background: #e2efe8;
  color: var(--green-dark);
  font-size: 11.5px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
}
.cfs-antibot-question {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-main);
}
.cfs-antibot-input-wrap input[type="number"] {
  width: 150px;
  padding: 9px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--text-main);
  background: #ffffff;
}
.cfs-antibot-input-wrap input[type="number"]:focus {
  outline: none;
  border-color: var(--green-primary);
  box-shadow: 0 0 0 3px rgba(31, 106, 78, 0.15);
}
.cfs-footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 16px;
}
.cfs-rodo-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--text-muted);
  max-width: 680px;
  cursor: pointer;
}
.cfs-rodo-label input[type="checkbox"] {
  margin-top: 3px;
  width: 17px;
  height: 17px;
  accent-color: var(--green-primary);
  flex-shrink: 0;
}
.cfs-rodo-label a {
  color: var(--green-primary);
  font-weight: 600;
}
.cfs-submit-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}

@media (max-width: 860px) {
  .contact-form-section {
    padding: 20px 18px;
  }
  .cfs-row-grid-2,
  .cfs-contact-choice-grid {
    grid-template-columns: 1fr;
  }
  .cfs-or-divider {
    padding-top: 0;
  }
  .cfs-submit-btn {
    width: 100%;
    justify-content: center;
  }
}

/* Tryb nocny (Dark Mode) dla formularza kontaktowego */
html[data-theme="dark"] .cfs-header h2,
html[data-theme="dark"] .cfs-choice-title {
  color: #e8f3ee;
}
html[data-theme="dark"] .cfs-security-badge {
  background: rgba(43, 125, 93, 0.2);
  border-color: rgba(82, 183, 136, 0.35);
  color: #6ee7b7;
}
html[data-theme="dark"] .cfs-field input[type="text"],
html[data-theme="dark"] .cfs-field input[type="email"],
html[data-theme="dark"] .cfs-field input[type="tel"],
html[data-theme="dark"] .cfs-field textarea {
  background: #101a16;
  border-color: #2b4238;
  color: #e6f0ec;
}
html[data-theme="dark"] .cfs-field input:focus,
html[data-theme="dark"] .cfs-field textarea:focus {
  border-color: #46b88a;
  box-shadow: 0 0 0 3px rgba(70, 184, 138, 0.22);
}
html[data-theme="dark"] .cfs-topic-chip {
  background: #1a2b24;
  border-color: #2d473c;
  color: #cbe3d8;
}
html[data-theme="dark"] .cfs-topic-chip:hover {
  background: #2b7d5d;
  border-color: #46b88a;
  color: #ffffff;
}
html[data-theme="dark"] .cfs-contact-choice-box {
  background: #13201b;
  border-color: #284036;
}
html[data-theme="dark"] .cfs-contact-choice-box.is-valid {
  background: #11261e;
  border-color: #2b7d5d;
}
html[data-theme="dark"] .cfs-contact-choice-box.is-invalid {
  background: #261619;
  border-color: #dc2626;
}
html[data-theme="dark"] .cfs-choice-status {
  background: #1e332a;
  color: #b4d6c7;
}
html[data-theme="dark"] .cfs-contact-choice-box.is-valid .cfs-choice-status {
  background: #13392a;
  color: #6ee7b7;
}
html[data-theme="dark"] .cfs-contact-choice-box.is-invalid .cfs-choice-status {
  background: #451a1d;
  color: #fca5a5;
}
html[data-theme="dark"] .cfs-or-divider span {
  background: #182821;
  border-color: #2d473c;
  color: #a3bfb2;
}
html[data-theme="dark"] .cfs-badge-preferred {
  background: #143d2b;
  color: #6ee7b7;
}
html[data-theme="dark"] .cfs-badge-alt {
  background: #23332c;
  color: #b8cfc4;
}
html[data-theme="dark"] .cfs-alert-success {
  background: #112e23;
  border-color: #2b7d5d;
  color: #a7f3d0;
}
html[data-theme="dark"] .cfs-alert-error {
  background: #2c1518;
  border-color: #991b1b;
  color: #fecaca;
}
html[data-theme="dark"] .cfs-antibot-row {
  background: #13201b;
  border-color: #284036;
}
html[data-theme="dark"] .cfs-antibot-badge {
  background: #1e332a;
  color: #6ee7b7;
}
html[data-theme="dark"] .cfs-antibot-question {
  color: #e6f0ec;
}
html[data-theme="dark"] .cfs-antibot-input-wrap input[type="number"] {
  background: #101a16;
  border-color: #2b4238;
  color: #e6f0ec;
}
