
:root {
  --text-scale: 1;
}

html {
  font-size: calc(16px * var(--text-scale));
}

/* ===== FOCUS (ACCESSIBILITY) ===== */
:focus-visible {
  outline: 2px solid #00aaff;
  outline-offset: 3px;
  border-radius: 4px;
}

/* RESET */
* {
  box-sizing: border-box;
}

/* BASE */
body {
  margin: 0;
  font-family: "Segoe UI", Arial, sans-serif;
  color: #1e1e1e;
  background-color: #ffffff;
  line-height: 1.6;
}

/* (RESZTA TWOJEGO CSS BEZ ZMIAN) */

:root {
  --text-scale: 1;
}

html {
  font-size: calc(16px * var(--text-scale));
}

/* RESET */
* {
  box-sizing: border-box;
}

/* BASE */
body {
  margin: 0;
  font-family: "Segoe UI", Arial, sans-serif;
  color: #1e1e1e;
  background-color: #ffffff;
  line-height: 1.6;
}

h1 {
  font-size: 2.4rem;
  margin-bottom: 1rem;
}

h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.25rem;
}


/* HEADER */
.header {
  background: #0b3c5d;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
}

.nav {
  max-width: 1200px;
  margin: auto;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  color: #ffffff;
  font-weight: 700;
  font-size: 1.2rem;
  text-decoration: none;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

.nav-links a {
  color: #ffffff;
  text-decoration: none;
  font-weight: 500;
}

.nav-links a:hover {
  text-decoration: underline;
}

/* MAIN CONTAINER */
.container {
  max-width: 1100px;
  margin: auto;
  padding: 3rem 1.2rem;
}


/* HERO */
.hero {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2rem;
  align-items: center;
  margin-bottom: 3rem;
}

.hero-text h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.hero-text p {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.hero-image img {
  width: 100%;
  border-radius: 8px;
}

/* INTRO */
.intro {
  margin-bottom: 3rem;
  font-size: 1.1rem;
}

/* TILES */
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.tile {
  background: #f5f7f9;
  border-radius: 12px;
  padding: 2rem 1.8rem;
  text-decoration: none;
  color: inherit;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent, rgba(11, 60, 93, 0.08));
  opacity: 0;
  transition: opacity 0.25s ease;
}

.tile:hover::after {
  opacity: 1;
}

.tile:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.18);
}

.tile h3 {
  margin-top: 0;
  margin-bottom: 0.6rem;
}

.tile p {
  margin: 0;
}

.tile-icon {
  font-size: 1.8rem;
  display: block;
  margin-bottom: 0.8rem;
}


/* FOOTER */
.footer {
  margin-top: 5rem;
  padding: 2rem 1rem;
  background: #f5f7f9;
  text-align: center;
  font-size: 0.85rem;
  color: #555;
}


/* RESPONSIVE */
@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
  }
}


/* HERO OVERLAY */
/*
.hero-overlay {
  background:
    linear-gradient(rgba(11, 60, 93, 0.85), rgba(11, 60, 93, 0.85)),
    url("/WIM-AGH/images/wim-example.jpg") center/cover no-repeat;
  color: #ffffff;
  padding: 5rem 2rem;
  border-radius: 12px;
  margin-bottom: 4rem;
}
*/


/* HERO OVERLAY */
.hero-overlay {
  background:
    linear-gradient(rgba(11, 60, 93, 0.85), rgba(11, 60, 93, 0.85)),
    url("../images/wim-example.jpg") center/cover no-repeat;
  color: #ffffff;
  padding: 5rem 2rem;
  border-radius: 12px;
  margin-bottom: 4rem;
}


.hero-content {
  max-width: 700px;
  animation: fadeInUp 0.8s ease forwards;
}

.hero-overlay h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.hero-overlay p {
  font-size: 1.15rem;
  margin-bottom: 1rem;
}

/* ANIMATION */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.nav-links a.active {
  border-bottom: 2px solid #ffffff;
  padding-bottom: 2px;
}

/* TEAM SECTION */
.team-grid {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.team-card {
  background: #f5f7f9;
  border-radius: 14px;
  padding: 2rem 1.5rem;
  text-align: center;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.team-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.18);
}

.team-card img {
  width: 140px;
  height: 140px;
  object-fit: cover;
  border-radius: 50%;
  margin-bottom: 1rem;
}

.team-card h3 {
  margin: 0.5rem 0 0.3rem;
}

.team-role {
  display: block;
  font-size: 0.9rem;
  color: #0b3c5d;
  font-weight: 600;
  margin-bottom: 0.8rem;
}

.team-card p {
  font-size: 0.95rem;
}

/* PARTNERS SECTION */
.partners-grid {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.partner-card {
  background: #ffffff;
  border-radius: 14px;
  padding: 2rem 1.5rem;
  text-align: center;
  border: 1px solid #e0e0e0;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.partner-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

.partner-card img {
  max-width: 180px;
  max-height: 80px;
  object-fit: contain;
  margin-bottom: 1.2rem;
}

.partner-card h3 {
  margin: 0.5rem 0 0.8rem;
}

.partner-card p {
  font-size: 0.95rem;
  color: #333;
}


/* EVENTS / TIMELINE */
.events-section {
  margin-top: 3rem;
}

.events-section h2 {
  margin-bottom: 2rem;
  color: #0b3c5d;
}

.timeline {
  position: relative;
  margin-left: 1rem;
  padding-left: 2rem;
  border-left: 3px solid #0b3c5d;
}

.timeline-item {
  position: relative;
  margin-bottom: 2.5rem;
}

.timeline-marker {
  position: absolute;
  left: -11px;
  top: 0.3rem;
  width: 18px;
  height: 18px;
  background: #0b3c5d;
  border-radius: 50%;
}

.timeline-content h3 {
  margin: 0 0 0.3rem;
}

.event-meta {
  display: block;
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 0.6rem;
}

.timeline-content p {
  margin: 0;
  font-size: 0.95rem;
}

/* LIBRARY SECTION */
.library-list {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.library-card {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-left: 6px solid #0b3c5d;
  border-radius: 10px;
  padding: 1.8rem 2rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.library-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 24px rgba(0,0,0,0.15);
}

.library-type {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  color: #0b3c5d;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.library-card h3 {
  margin: 0.4rem 0 0.6rem;
}

.library-authors {
  font-size: 0.95rem;
  font-style: italic;
  margin-bottom: 0.3rem;
}

.library-meta {
  font-size: 0.9rem;
  color: #555;
  margin-bottom: 1rem;
}

.library-link {
  display: inline-block;
  text-decoration: none;
  font-weight: 600;
  color: #0b3c5d;
  border: 2px solid #0b3c5d;
  padding: 0.4rem 0.9rem;
  border-radius: 6px;
  transition: background 0.2s ease, color 0.2s ease;
}

.library-link:hover {
  background: #0b3c5d;
  color: #ffffff;
}


.fade-in {
  animation: fadeIn 0.8s ease forwards;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}


.card {
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.12);
}


/* CONTACT BLOCK */
.contact-block p {
  margin: 0.2rem 0;
}


/* GOOGLE MAP */
.map-container {
  margin-top: 2rem;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(0,0,0,0.15);
}

/* CONTACT LAYOUT */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

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


/* MEASUREMENT STATION */
/*.station-content {
 /* max-width: 800px; */
/*}*/

.station-content p {
  margin-bottom: 1.2rem;
}

.station-list {
  margin: 1.5rem 0 1.8rem;
  padding-left: 1.2rem;
}

.station-list li {
  margin-bottom: 0.8rem;
}

/* MEASUREMENT STATION – GALLERY */
.station-gallery {
  margin-top: 3rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.station-gallery img {
  width: 100%;
  height: 220px;              /* 👈 IDENTYCZNY ROZMIAR */
  object-fit: cover;          /* 👈 PRZYCINANIE */
  border-radius: 14px;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(0,0,0,0.15);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.station-gallery img:hover {
  transform: scale(1.03);
  box-shadow: 0 14px 30px rgba(0,0,0,0.25);
}

/* LIGHTBOX */
#lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 1000;
}

#lightbox.active {
  opacity: 1;
  pointer-events: all;
}

#lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  border-radius: 10px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

/* MOBILE */
@media (max-width: 900px) {
  .station-gallery {
    grid-template-columns: 1fr;
  }

  .station-gallery img {
    height: 240px;
  }
}

/* EFFECTS SECTION */
/*.effects-content {
 /* max-width: 900px; */
/*}*/

.effects-lead {
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
}

.effects-grid {
  margin: 2rem 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.8rem;
}

.effect-card {
  background: #f5f7f9;
  border-radius: 14px;
  padding: 1.6rem 1.4rem;
  box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

.effect-card h3 {
  margin-top: 0;
  margin-bottom: 0.6rem;
}

.effects-summary {
  margin-top: 2rem;
  font-weight: 500;
}

/* IMAGE */
.effects-image {
  margin-top: 3rem;
}

.effects-image img {
  width: 100%;
  border-radius: 16px;
  box-shadow: 0 14px 32px rgba(0,0,0,0.2);
  object-fit: cover;
}

/* FAQ */
.faq-intro {
  /*max-width: 900px;*/
  margin-bottom: 2rem;
  font-size: 1.05rem;
}

.faq details {
  background: #f5f7f9;
  border-radius: 12px;
  padding: 1.2rem 1.4rem;
  margin-bottom: 1rem;
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
  cursor: pointer;
}

.faq summary {
  font-weight: 600;
  font-size: 1.05rem;
  list-style: none;
}

.faq summary::marker {
  display: none;
}

.faq details p {
  margin-top: 0.8rem;
  line-height: 1.6;
}

/* NEWS */
.news-item {
  max-width: 1000px;
}

.news-image {
  width: 100%;
  border-radius: 16px;
  box-shadow: 0 14px 32px rgba(0,0,0,0.2);
  margin-bottom: 1.8rem;
}

.news-meta {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 0.8rem;
  font-size: 0.95rem;
  opacity: 0.8;
}

.news-lead {
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 1.2rem;
}

.event-details,
.event-program {
  margin-top: 2.5rem;
}

.event-details ul,
.event-program ol {
  margin-top: 0.8rem;
  padding-left: 1.2rem;
}

.event-program li {
  margin-bottom: 0.4rem;
}

.rsvp {
  margin-top: 2rem;
  font-weight: 600;
}


/* PROJECTS */
.project-card {
  margin-top: 3rem;
  background: #ffffff;
  border-radius: 14px;
  padding: 2.5rem 2rem;
  box-shadow: 0 10px 26px rgba(0,0,0,0.12);
}

.project-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.project-logo {
  max-height: 90px;
  object-fit: contain;
}

.project-content p {
  margin-bottom: 1.2rem;
  max-width: 900px;
}

.project-partners {
  margin-top: 2.5rem;
  display: flex;
  gap: 2.5rem;
  align-items: center;
  flex-wrap: wrap;
}

.project-partners img {
  max-height: 130px;
  object-fit: contain;
  opacity: 0.9;
}

/* ABOUT WIM SECTIONS */
.about-section {
  margin-top: 4rem;
  max-width: 1200px;
}

.about-section h2 {
  margin-bottom: 1rem;
  color: #0b3c5d;
}

.about-section p,
.about-section li {
  margin-bottom: 0.8rem;
}

/* DROPDOWN MENU */
html {
  scroll-behavior: smooth;
}


.nav-links li.dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background: #ffffff;
  padding: 0.5rem 0;
  list-style: none;
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  border-radius: 8px;
  min-width: 240px;
  display: none;
  z-index: 999;
}

.dropdown-menu li a {
  display: block;
  padding: 0.5rem 1rem;
  text-decoration: none;
  color: #1e1e1e;
  font-size: 0.9rem;
}

.dropdown-menu li a:hover {
  background: #f5f7f9;
}

.nav-links li.dropdown:hover .dropdown-menu {
  display: block;
}


/* ABOUT – TEXT + IMAGE LAYOUT */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2.5rem;
  align-items: center;
}

.about-grid img {
  width: 100%;
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.15);
}

/* MOBILE */
@media (max-width: 1200px) {
  .about-grid {
    grid-template-columns: 1fr;
  }

  .about-grid img {
    margin-top: 1.5rem;
  }
}


/* LIBRARY FILTERS */

.library-filters {
  display: flex;
  gap: 3rem;
  margin: 2rem 0 3rem;
  flex-wrap: wrap;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.year-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(60px, 1fr));
  gap: 0.4rem 1rem;
}

.filter-group label {
  font-size: 0.9rem;
  cursor: pointer;
}


/* FILTER DROPDOWNS */
.library-filters {
  display: flex;
  gap: 1.5rem;
  margin: 2rem 0 3rem;
}

.filter-dropdown {
  position: relative;
}

.filter-toggle {
  background: #f5f7f9;
  border: 1px solid #ccc;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
}

.filter-menu {
  position: absolute;
  top: 110%;
  left: 0;
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.15);
  padding: 0.8rem 1rem;
  display: none;
  z-index: 1000;
  min-width: 180px;
}

.filter-menu label {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
  cursor: pointer;
}

.filter-dropdown.open .filter-menu {
  display: block;
}


/* ================= LIBRARY SEARCH ================= */

.library-filters {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.library-search input {
  height: 35px;
  min-width: 280px;
  padding: 0 12px;

  font-size: 0.95rem;
  font-family: inherit;

  border: 1px solid #ccc;
  border-radius: 6px;
  background: #f5f7f9;

  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.library-search input::placeholder {
  color: #777;
}

.library-search input:focus {
  outline: none;
  border-color: #003a8f; /* dopasuj do koloru site */
  box-shadow: 0 0 0 2px rgba(0, 58, 143, 0.15);
}


/* ================= LIBRARY CARD – FINAL STABLE LAYOUT ================= */

.library-card {
  display: grid;
  grid-template-columns: auto auto 1fr auto;
  grid-template-rows: auto auto auto;
  column-gap: 0.4rem;
  row-gap: 0.4rem;
}

/* -------- LINE 1: TYPE + DOT + YEAR -------- */
.library-type {
  grid-row: 1;
  grid-column: 1;
  margin: 0;
}

.library-type::after {
  content: " ·";
}

.library-meta {
  grid-row: 1;
  grid-column: 2;
  margin: 0;
}

/* -------- LINE 2: TITLE -------- */
.library-card h3 {
  grid-row: 2;
  grid-column: 1 / 4;
  margin: 0;
}

/* -------- DETAILS BUTTON (RIGHT) -------- */
.library-card .library-link {
  grid-row: 2;
  grid-column: 4;
  align-self: start;
  justify-self: end;
}

/* -------- LINE 3: AUTHORS -------- */
.library-authors {
  grid-row: 3;
  grid-column: 1 / 4;
  margin: 0;
}

/* -------- CLEANUP -------- */
.library-card p {
  margin: 0;
}


/* --------- FLAGS ----------*/
.lang-switch {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.lang-switch img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  opacity: 0.6;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.lang-switch a:hover img {
  opacity: 1;
  transform: scale(1.05);
}

.lang-switch .active-lang img {
  opacity: 1;
  outline: 2px solid white;
}

/* ===== ACCESSIBILITY BAR ===== */
.accessibility-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;

  background: #0b3c5d;
  display: flex;
  justify-content: center;
  gap: 0.5rem;

  padding: 0.4rem;
  z-index: 9999;
}

.accessibility-bar button {
  background: white;
  border: none;
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
}

.accessibility-bar button:hover {
  background: #ddd;
}

/* IKONA KONTRASTU */
.contrast-btn {
  background: #ffffff;
  color: #000;
  border: 2px solid #000;
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s ease;
}

/* ===== HIGH CONTRAST MODE ===== */
.high-contrast {
  background: #000 !important;
  color: #fff !important;
}

.high-contrast * {
  background-color: transparent !important;
  color: #fff !important;
  border-color: #fff !important;
}

/* wyjątek: header i pasek */
.high-contrast .header,
.high-contrast .accessibility-bar {
  background: #000 !important;
}

/* ===== NAV FIX FOR BIG TEXT ===== */
.nav-links {
  flex-wrap: wrap;
}


/* ===== HIGH CONTRAST – HERO FIX ===== */
.high-contrast .hero-overlay {
  background: #000 !important;
}

/* layout paska */
.accessibility-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;

  background: #0b3c5d;
  padding: 0.4rem;

  display: flex;
  align-items: center;
  justify-content: center;

  z-index: 9999;
}

/* grupa środkowa */
.a11y-center {
  display: flex;
  gap: 0.5rem;
}

/* przycisk po prawej */
.a11y-right {
  position: absolute;
  right: 10px;
}


/* ===== ACCESSIBILITY PANEL ===== */
.a11y-panel {
  position: fixed;
  bottom: 50px;
  right: 10px;                 /* 👈 zamiast centrowania */

  background: #ffffff !important;   /* 👈 nadpisuje global */
  color: #000 !important;

  padding: 1rem 1.2rem;
  border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.2);

  max-width: 420px;
  width: auto;

  z-index: 9998;
}

/* żeby globalne * nie psuło wnętrza */
.a11y-panel * {
  background: transparent !important;
  color: inherit !important;
}

/* HIGH CONTRAST */
.high-contrast .a11y-panel {
  background: #000 !important;
  color: #fff !important;
  border: 2px solid #fff;
}