/* Icon spacing in header navigation */
.site-header .nav-desktop .nav-link { display: inline-flex; align-items: center; gap: 8px; }

/* Container utility */
.container { max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* Section spacing */
.section { margin: 24px 0; }
.section-gap { height: 24px; }

/* Cards */
.section-card { background:#fff; border:1px solid #e2e8f0; border-radius:16px; box-shadow:0 8px 24px rgba(2,6,23,0.06); }
.section-card:hover { box-shadow:0 16px 36px rgba(2,6,23,0.12); transition: box-shadow .2s ease; }
.accent-line { height:4px; width:56px; background:#2563eb; border-radius:9999px; margin-bottom:14px; }

/* Buttons */
.btn { background:#0a2342; color:#fff; padding:10px 14px; border:none; border-radius:10px; cursor:pointer; font-weight:600; display:inline-flex; align-items:center; gap:8px; transition:transform var(--duration-base) var(--ease-premium), box-shadow var(--duration-base) var(--ease-premium); text-decoration:none; }
.btn:hover { transform:translateY(-1px); box-shadow:0 10px 24px rgba(2,6,23,.15); color:#fff; }
.btn:disabled { opacity: .6; cursor:not-allowed; }
.btn-secondary { background:#475569; color:#fff; }
.btn-danger { background:#dc2626; color:#fff; }
.btn-accent { background:#2563eb; color:#fff; }

/* Form controls */
input[type="text"], input[type="email"], input[type="tel"], input[type="date"], input[type="password"], textarea, select {
  border:1px solid #e2e8f0; border-radius:10px; padding:10px 12px; font-size:16px; font-family: inherit;
}
input:focus, textarea:focus, select:focus {
  outline:none; border-color:#2563eb; box-shadow:0 0 0 3px rgba(37,99,235,.15);
}

/* Tables */
.table { width:100%; border-collapse:separate; border-spacing:0; }
.table th, .table td { padding:12px 10px; text-align:left; vertical-align:top; }
.table thead th { border-bottom:1px solid #e2e8f0; color:#0a2342; font-weight:700; }
.table tbody tr { border-top:1px solid #e2e8f0; }
.table tbody tr:last-child { border-bottom:1px solid #e2e8f0; }
.site-header .nav-desktop .nav-link > i { margin-right: 0 !important; vertical-align: -1px; }
.offcanvas .offcanvas-body a { display: inline-flex; align-items: center; gap: 8px; }
.offcanvas .offcanvas-body i { margin-right: 0 !important; vertical-align: -1px; }

/* Header links: no underline on hover */
.site-header a { text-decoration: none; }
.site-header a:hover { text-decoration: none; }
.offcanvas .offcanvas-body a { text-decoration: none; }
.offcanvas .offcanvas-body a:hover { text-decoration: none; }

/* Accessible focus styles */
:focus-visible { outline: 3px solid #2563eb; outline-offset: 2px; }
.nav-link:focus-visible, .offcanvas-link:focus-visible, .offcanvas-group > summary:focus-visible,
button:focus-visible, a.button:focus-visible, .folder-card:focus-visible, .event-card:focus-visible { outline: 3px solid #2563eb; outline-offset: 2px; border-radius: 8px; }

/* Add spacing after sticky sub-navigation bar if present */
#subnav + .content { margin-top: 24px !important; }
/* Make subnav stick below sticky header */
#subnav {
  position: sticky; /* ensure it follows scroll */
  top: 72px;        /* height of .nav-container in header */
  z-index: 950;     /* above content, below page transition (99999) */
}
/* Mobile handling for subnav to prevent overflow */
@media (max-width: 400px) {
  #subnav { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  #subnav .flex { flex-wrap: nowrap; gap: 12px; padding: 0 12px; }
  #subnav .flex::after { content: ""; flex: 0 0 12px; }
  #subnav a { font-size: 0.95rem !important; white-space: nowrap; padding: 4px 0; }
  #subnav::-webkit-scrollbar { display: none; }
}
/* Subnav scroll hint on small screens */
@media (max-width: 400px) {
  #subnav { position: sticky; }
  #subnav::before, #subnav::after {
    content: ""; position: absolute; top: 0; bottom: 0; width: 28px; pointer-events: none; z-index: 951;
  }
  #subnav::before { left: 0; background: linear-gradient(90deg, rgba(245,245,245,1), rgba(245,245,245,0)); }
  #subnav::after { right: 0; background: linear-gradient(270deg, rgba(245,245,245,1), rgba(245,245,245,0)); }
}
/* Global resets for responsive */
*, *::before, *::after { box-sizing: border-box; }
img, video, iframe { max-width: 100%; }

/* Ogólne */
html { overflow-x: hidden; }
body {
  margin: 0;
  padding: 0;
  background-color: #f5f5f5;
  min-height: 100vh;
  overflow-x: hidden;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  max-width: 100vw;
}

/* Smooth scrolling for in-page anchors */
html { scroll-behavior: smooth; }
/* Ensure anchored sections are not hidden under sticky headers */
section[id] { scroll-margin-top: 110px; }
/* Klub subnav adds extra sticky bar; add a bit more margin on that page's sections */
#subnav + .content section[id] { scroll-margin-top: 140px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* Page Transition Overlay */
#pageTransition {
  position: fixed;
  inset: 0;
  background: #0a2342;
  z-index: 99999;
  display: grid;
  place-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-base) var(--ease-premium);
}
#pageTransition.active {
  opacity: 1;
  pointer-events: auto;
}
#pageTransition .boat {
  width: 96px;
  height: 96px;
  color: #ffffff;
  transform: translateY(20px);
  opacity: 0.9;
}
#pageTransition .boat img { width: 96px; height: 96px; display: block; }
#pageTransition .boat-wrap { transform: translateX(0); }
#pageTransition.enter .boat-wrap {
  animation: sailInX var(--duration-slow) var(--ease-premium) forwards;
}
#pageTransition.exit .boat-wrap {
  animation: sailOutX var(--duration-slow) var(--ease-premium) forwards;
}
#pageTransition .boat { animation: bob 2.4s ease-in-out infinite 400ms; }

@keyframes sailInX {
  from { transform: translateX(-60vw); }
  to   { transform: translateX(0); }
}
@keyframes sailOutX {
  from { transform: translateX(0); }
  to   { transform: translateX(60vw); }
}
@keyframes bob {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

@media (prefers-reduced-motion: reduce) {
  #pageTransition,
  #pageTransition .boat {
    transition: none !important;
    animation: none !important;
  }
}
/* Glass header on scroll */
header.scrolled {
  background: rgba(10,35,66,0.65);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

/* Magnetic CTA base (used by .join-btn via JS transforms) */
.join-btn {
  transition: transform var(--duration-fast) var(--ease-premium), box-shadow var(--duration-base) var(--ease-premium);
  will-change: transform;
}

/* Back-to-top floating action button */
.back-to-top {
  position: fixed;
  right: 20px;
  bottom: 24px;
  height: 44px;
  width: 44px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(10,35,66,0.9);
  color: white;
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 50;
}
.back-to-top.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Accessible focus states */
a:focus-visible,
button:focus-visible,
.join-btn:focus-visible,
.gallery-nav-btn:focus-visible,
article[role="link"]:focus-visible {
  outline: 3px solid #2563eb;
  outline-offset: 2px;
  box-shadow: 0 0 0 4px rgba(37,99,235,0.25);
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .card-elevate:hover,
  .feature-card:hover,
  .thumb-hover:hover { transform: none !important; box-shadow: none !important; }
}

/* ===== Nautical palette ===== */
:root {
  --navy: #0a2342;
  --ocean: #1e3a8a; /* indigo-800 */
  --ocean-600: #2563eb; /* blue-600 */
  --sail-white: #f8fafc; /* slate-50 */
  --deck-sand: #e5e7eb; /* gray-200 */
  --smoke: rgba(10,35,66,0.08);
  --accent: #f59e0b; /* amber-500 */
  --danger: #dc2626;
  --success: #16a34a;
  /* Motion tokens */
  --ease-premium: cubic-bezier(.22,.61,.36,1);
  --duration-fast: 150ms;
  --duration-base: 250ms;
  --duration-slow: 400ms;
}

/* ===== Premium desktop topbar ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--smoke);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--navy);
}
.nav-logo { height: 40px; width: 40px; object-fit: contain; }
.nav-title { font-family: 'Playfair Display', serif; font-weight: 700; font-size: 1.25rem; }

.nav-desktop {
  list-style: none;
  margin: 0;
  padding: 0;
  display: none; /* mobile-first */
  align-items: center;
  gap: 10px;
}

.nav-link {
  display: inline-block;
  padding: 10px 14px;
  text-decoration: none;
  color: var(--navy);
  border-radius: 10px;
  transition: background 0.2s, color 0.2s;
}
.nav-link:hover { background: var(--deck-sand); }

.has-children { position: relative; }
.has-children > .dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 240px;
  background: #fff;
  border: 1px solid var(--smoke);
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(10,35,66,0.08);
  padding: 8px;
  display: none;
}
.has-children:hover > .dropdown { display: block; }
.dropdown > li { list-style: none; }
.dropdown a { display:block; padding:10px 12px; border-radius:8px; color: var(--navy); text-decoration:none; }
.dropdown a:hover { background: var(--deck-sand); }

.text-success { color: var(--success); }
.text-danger  { color: var(--danger); }

/* ===== Mobile offcanvas ===== */
.nav-toggle {
  display: inline-flex;
  width: 44px; height: 44px;
  align-items: center; justify-content: center;
  gap: 5px; flex-direction: column;
  background: #fff; border: 1px solid var(--smoke);
  border-radius: 10px; cursor: pointer;
  transition: transform 0.2s;
}
.nav-toggle .bar { width: 20px; height: 2px; background: var(--navy); border-radius: 2px; transition: transform 0.25s, opacity 0.25s; }
.nav-toggle.active .bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle.active .bar:nth-child(2) { opacity: 0; }
.nav-toggle.active .bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.offcanvas {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: 78%; max-width: 360px;
  background: #fff;
  border-left: 1px solid var(--smoke);
  transform: translateX(100%);
  transition: transform 0.3s ease;
  z-index: 1001;
  display: flex; flex-direction: column;
}
.offcanvas.open { transform: translateX(0); }
.offcanvas-header { height: 64px; display: flex; align-items: center; justify-content: space-between; padding: 0 16px; font-weight: 600; color: var(--navy);}
.offcanvas-close { background: none; border: none; font-size: 2rem; line-height: 1; cursor: pointer; color: var(--navy); }
.offcanvas-body { display:flex; flex-direction: column; padding: 8px 12px; gap: 6px; overflow-y: auto; }
.offcanvas-link { display:block; padding: 12px; text-decoration:none; color: var(--navy); border-radius: 10px; }
.offcanvas-link:hover { background: var(--deck-sand); }
.offcanvas-group { padding: 0; }
.offcanvas-group > summary { list-style: none; cursor: pointer; padding: 12px; border-radius:10px; display:block; }
.offcanvas-group > summary::-webkit-details-marker { display: none; }
.offcanvas-group[open] > summary, .offcanvas-group > summary:hover { background: var(--deck-sand); }
.offcanvas-group a { display:block; padding: 10px 12px 10px 20px; border-radius:8px; text-decoration:none; color: var(--navy); }
.offcanvas-group a:hover { background: var(--deck-sand); }

.offcanvas-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.4);
  opacity: 0; pointer-events: none; transition: opacity 0.3s ease; z-index: 1000;
}
.offcanvas-overlay.show { opacity: 1; pointer-events: auto; }

/* ===== Responsive rules ===== */
@media (min-width: 1024px) {
  .nav-desktop { display: flex; }
  .nav-toggle { display: none; }
  .offcanvas, .offcanvas-overlay { display: none; }
}


/* Nagłówek */

header {
  position: relative;
  height: 100px;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  padding: 20px;
  align-items: center;
  
}


h1 {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-size: 3rem !important;
  align-items: center;
  font-weight: 700 !important;
  display: flex;
  text-align: center;
  flex-grow: 1;
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  white-space: nowrap;
}
@media (max-width: 768px) {
  h1 { font-size: 1.8rem !important; white-space: normal; }
}
@media (max-width: 480px) {
  h1 { font-size: 1.4rem !important; }
}


/* Logo */
.logo {
  height: 3rem;
  margin-right: 10px; /* Odstęp między logo a tekstem */
}

.logo-link {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  text-decoration: none;
  color: inherit;
  display: flex;
  align-items: center;
}

.logo-link h1 {
  position: static; 
  transform: none;
  margin: 0;
  padding: 0;
}

.logo-link:hover .logo {
  transform: scale(1.05); 
  transition: all 0.3s ease;
}

/* Banner */
.banner {
  position: relative;
  display: inline-block;
  text-align: center;
  color: white;
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  max-width: 80%;
}
.banner img{
  border-radius: 176px;
  box-shadow: 0px 8px 15px rgba(0, 0, 0, 0.2);
}

/* ===== Event image placeholder ===== */
.event-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 250px;
  background: linear-gradient(135deg, var(--deck-sand), #fff);
  color: var(--navy);
  font-weight: 600;
  border-bottom: 1px solid var(--smoke);
}
.join-btn {
    display: block;
    background-color: #1F1A17;
    color: white;
    padding: 8px 16px;
    margin-top: 8px;
    text-align: center;
    text-decoration: none;
    width: fit-content;
    border-radius: 20px;
    padding: 10px 20px;
    border: none;
    font-weight: 600;
    font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
    transition: all 0.2s;
    box-shadow: 0 4px 0 rgba(0, 0, 0, 0.2);

}
.join-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 0 rgba(0, 0, 0, 0.3);
}

.join-btn:active {
  transform: translateY(2px);
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.2);
}
  

/* checkbox */
#checkbox {
  display: none;
}

.toggle {
  position: fixed;
  margin-left: 10px;
  top: 20px;
  z-index: 1010;
  width: 40px;
  height: 40px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition-duration: .5s;
  
}

.bars {
  width: 100%;
  height: 4px;
  background-color: #1F1A17;
  border-radius: 4px;
}

#bar2 {
  transition-duration: .8s;
}

#bar1,#bar3 {
  width: 70%;
}

#checkbox:checked + .toggle .bars {
  position: absolute;
  transition-duration: .5s;
  background-color: #ff0000;
}

#checkbox:checked + .toggle #bar2 {
  transform: scaleX(0);
  transition-duration: .5s;
}

#checkbox:checked + .toggle #bar1 {
  width: 100%;
  transform: rotate(45deg);
  transition-duration: .5s;
}

#checkbox:checked + .toggle #bar3 {
  width: 100%;
  transform: rotate(-45deg);
  transition-duration: .5s;
}

#checkbox:checked + .toggle {
  transition-duration: .5s;
  transform: rotate(180deg);
}

/* ikony */
.kolka {
  display: flex;
  justify-content: center;
  margin-top: 1.5rem;
}

.kolka > * {
  margin-right: 2rem;
}

.kolka > *:last-child {
  margin-right: 0;
}

.ikony{
  width: 48px;
  height: 48px;
}

.ikony-link{
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  border-radius: 100%;
  width: 6.5rem;
  height: 6.5rem;
  background-color: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem;
  transition: all 0.3s ease-in-out;
}

.ikony-link:hover{
  font-size: 1.2rem;
  width: 7rem;
  height: 7rem;
  box-shadow: 0px 8px 15px rgba(0, 0, 0, 0.2);
}



/* footer */
footer, .site-footer {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  padding: 1.25rem 1rem;
  background-color: var(--navy);
  width: 100%;
  box-sizing: border-box;
  color: white;
}
@media (max-width: 768px) {
  footer, .site-footer { padding: 1rem 12px; }
}

.site-footer a { color: #e2e8f0; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer .social {
  display: flex; gap: 12px; align-items: center;
}

/* Gap above footer */
.footer-gap {
  height: 96px;
}

/* Hide horizontal scrollbar but keep scroll functionality */
.hide-scrollbar {
  -ms-overflow-style: none; /* IE and Edge */
  scrollbar-width: none; /* Firefox */
}
.hide-scrollbar::-webkit-scrollbar { /* Chrome, Safari */
  display: none;
}

/* Pretty horizontal scrollbar for gallery strip */
.pretty-scrollbar {
  -ms-overflow-style: auto;
  scrollbar-width: thin;
  scrollbar-color: #2563eb rgba(255,255,255,0.15);
}
.pretty-scrollbar::-webkit-scrollbar {
  height: 10px;
}
.pretty-scrollbar::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.12);
  border-radius: 999px;
}
.pretty-scrollbar::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #3b82f6, #2563eb);
  border-radius: 999px;
  border: 2px solid rgba(255,255,255,0.25);
}
.pretty-scrollbar::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #2563eb, #1e40af);
}

/* Wave dividers */
.wave-divider {
  line-height: 0;
}
.wave-divider svg {
  display: block;
  width: 100%;
  height: 80px;
}

/* Card elevation hover animation */
.card-elevate {
  transition: transform var(--duration-base) var(--ease-premium), box-shadow var(--duration-base) var(--ease-premium);
}
.card-elevate:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 40px rgba(0,0,0,0.12);
}

/* Gallery thumbnail hover */
.thumb-hover {
  transition: transform var(--duration-base) var(--ease-premium), box-shadow var(--duration-base) var(--ease-premium);
}
.thumb-hover:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 14px 30px rgba(0,0,0,0.18);
}

/* Feature cards (Dlaczego JKL?) */
.feature-card {
  transition: transform var(--duration-base) var(--ease-premium), box-shadow var(--duration-base) var(--ease-premium);
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 40px rgba(0,0,0,0.12);
}
.feature-card .accent-line {
  height: 4px;
  width: 48px;
  background: #2563eb;
  border-radius: 999px;
  margin-bottom: 12px;
  transition: width var(--duration-base) var(--ease-premium), background var(--duration-base) var(--ease-premium);
}
.feature-card:hover .accent-line {
  width: 72px;
  background: #1e40af;
}

/* Gallery edge fades and nav */
.gallery-wrapper {
  position: relative;
}

/* Responsive improvements for Klub page grids */
@media (max-width: 768px) {
  .skipper-grid { grid-template-columns: 1fr !important; }
}
@media (max-width: 400px) {
  .gallery-grid { grid-template-columns: 1fr !important; gap: 14px !important; }
}

/* Ensure images do not overflow their containers */
.folder-card img,
.gallery-item img,
.skipper-card img {
  max-width: 100%;
  height: auto;
}
@media (max-width: 400px) {
  /* Limit image height only in gallery cards to avoid cutting skippers */
  .gallery-grid .folder-card img { height: 180px; object-fit: cover; }
  .skipper-grid .folder-card img { height: auto; object-fit: cover; }
}

/* Reduce content padding on very small screens */
@media (max-width: 400px) {
  .content { padding: 24px 12px !important; }
}

/* Improve readability on very small screens (iPhone SE) */
@media (max-width: 400px) {
  /* General copy uses system stack for clarity */
  body, p, li, input, textarea {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    font-size: 16px; /* avoid iOS auto-zoom on inputs and too thin text */
    line-height: 1.6;
  }
  /* Keep UI labels/links/buttons/tables in Inter as wcześniej */
  a, button, table, th, td {
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif !important;
    font-size: 16px;
  }
  /* Preserve stylistic font for "Zobacz więcej..." */
  .read-more { font-family: 'Irish Grover', cursive !important; }
  h1, h2, h3, h4 {
    font-family: 'Instrument Serif', Georgia, 'Times New Roman', serif;
    letter-spacing: 0.1px;
  }
  .join-btn { font-size: 16px; }
}
.gallery-fade-left,
.gallery-fade-right {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 64px;
  pointer-events: none;
  z-index: 2;
}
.gallery-fade-left { left: 0; background: linear-gradient(90deg, rgba(10,35,66,0.8), rgba(10,35,66,0)); }
.gallery-fade-right { right: 0; background: linear-gradient(270deg, rgba(10,35,66,0.8), rgba(10,35,66,0)); }

.gallery-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  height: 40px;
  width: 40px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.35);
  color: #fff;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}
.gallery-nav-btn:hover { background: rgba(255,255,255,0.3); transform: translateY(-50%) scale(1.06); }
.gallery-nav-prev { left: 12px; }
.gallery-nav-next { right: 12px; }



/* Wysuwane menu */
.sidenav {
  height: 100%;
  width: 300px;
  position: fixed;
  z-index: 1000;
  top: 0;
  left: -300px; /* Ukryte poza ekranem */
  background-color: rgba(31, 26, 23, 0.9);

  overflow-x: hidden;
  transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
  opacity: 0;
  padding-top: 5rem;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
}

/* ===== Desktop Top Navigation ===== */
.topnav {
  display: none; /* mobile-first hidden */
  position: sticky;
  top: 0;
  z-index: 900;
  background: #ffffffcc;
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(0,0,0,0.08);
  text-decoration: none;
  font-size: 20px;
  color: white;
  display: block;
  transition: all 0.3s ease;
  padding: 15px 25px;
}

.sidenav a:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Przycisk zamykający */
.sidenav .closebtn {
  position: absolute;
  top: 10px;
  right: 25px;
  font-size: 36px;
  color: white;
  border: none;
  background: none;
  cursor: pointer;
}

.sidenav .nav-link {
  font-size: 0.9rem;
  color: #2d3748 !important; /* Ciemny odcień */
  text-decoration: none;
  padding: 4px 0;
  display: block;
  transition: color 0.2s;
}

.sidenav .nav-link:hover {
  color: #1a202c !important; /* Jeszcze ciemniejszy przy hover */
}

/* Główna zawartość strony */
.content { padding: 60px 20px; max-width: 100%; box-sizing: border-box; }
@media (max-width: 600px) { .content { padding: 30px 12px; } }

/* Klasa aktywnego menu */
.sidenav.active {
  transform: translateX(300px);
  opacity: 1;
}

.sidenav .text-yellow-400 {
  color: #f6e05e;
}

.sidenav .text-red-400 {
  color: #f87171;
}

.sidenav .text-green-400 {
  color: #68d391;
}

.sidenav .border-t {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ===== Panel Administracyjny ===== */

/* Kontener główny (nad `<div class="content">`) */
.content { padding: 2rem; max-width: 1200px; margin: 0 auto; box-sizing: border-box; }

/* Nagłówki sekcji */
.content h1,
.content section h2 {
  font-family: 'Instrument Serif', serif;
  color: #1F1A17;
  margin-bottom: 1rem;
}

/* Formularz dodawania członka */
.content form {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}
.content input[type="text"],
.content input[type="password"],
.content select {
  flex: 1 1 200px;
  padding: 0.5rem;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-family: 'Itim', cursive;
}

/* Przycisk główny */
.btn-primary {
  background-color: #1F1A17;
  color: #fff;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 9999px;
  font-family: 'Itim', cursive;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Przycisk usuwania */
.btn-danger {
  background-color: #dc3545;
  color: #fff;
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Itim', cursive;
  transition: transform 0.2s;
}
.btn-danger:hover {
  transform: translateY(-1px);
}

/* Style tabel */
.content table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 2rem;
}
.content table th,
.content table td {
  padding: 0.75rem 1rem;
  border: 1px solid #eee;
  text-align: left;
  font-family: 'Itim', cursive;
}
.content table thead {
  background-color: #f0f0f0;
}
@media (max-width: 768px) {
  .content table th, .content table td { padding: 0.5rem; font-size: 0.85rem; }
}
/* Ensure all tables on mobile are scrollable */
.table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; max-width: 100%; }

/* Alerty (sukces / błąd) */
.alert {
  padding: 1rem 1.5rem;
  border-radius: 6px;
  margin-bottom: 1.5rem;
  font-family: 'Itim', cursive;
}
.alert-success {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}
.alert-error {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* Overlay i modal edycji */
.overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}
.modal {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  background: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  max-width: 90%;
  max-height: 85%;
  overflow-y: auto;
  display: none;
  z-index: 2001;
}
.close-btn {
  position: absolute;
  top: 1rem; right: 1rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
}