/* ==========================================================================
   ATHLETIC TRAINING HOUSE — custom stylesheet
   Wyłącznie to, czego Tailwind nie potrafi zrobić utility'ami:
   - definicje @font-face
   - drobne dopalenia (scrollbar, selection, active state w nawigacji)
   ========================================================================== */

/* ---- Fonts ------------------------------------------------------------- */
@font-face {
  font-family: 'Sansation';
  src: url('../font/Sansation-Regular.woff2') format('woff2'),
       url('../font/Sansation-Regular.woff')  format('woff');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Sansation';
  src: url('../font/Sansation-Italic.woff2') format('woff2'),
       url('../font/Sansation-Italic.woff')  format('woff');
  font-weight: 400; font-style: italic; font-display: swap;
}
@font-face {
  font-family: 'Sansation';
  src: url('../font/Sansation-Bold.woff2') format('woff2'),
       url('../font/Sansation-Bold.woff')  format('woff');
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Sansation';
  src: url('../font/Sansation-Bold-Italic.woff2') format('woff2'),
       url('../font/Sansation-Bold-Italic.woff')  format('woff');
  font-weight: 700; font-style: italic; font-display: swap;
}
@font-face {
  font-family: 'Sansation';
  src: url('../font/Sansation-Light.woff2') format('woff2'),
       url('../font/Sansation-Light.woff')  format('woff');
  font-weight: 300; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Sansation';
  src: url('../font/Sansation-Light-Italic.woff2') format('woff2'),
       url('../font/Sansation-Light-Italic.woff')  format('woff');
  font-weight: 300; font-style: italic; font-display: swap;
}

/* ---- Selection --------------------------------------------------------- */
::selection { background-color: #dad7cd; color: #0a0a0a; }
.dark ::selection { background-color: #dad7cd; color: #0a0a0a; }

/* ---- Nav links (custom underline animation) ---------------------------- */
.nav-link {
  position: relative;
  padding: 0.5rem 1rem;
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  color: inherit;
  transition: color .2s ease;
}
.nav-link::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 4px;
  width: 0;
  height: 2px;
  background-color: #dad7cd;
  transition: all .3s ease;
  transform: translateX(-50%);
}
.nav-link:hover::after,
.nav-link.active::after { width: calc(100% - 2rem); }
.nav-link:hover { color: #941b0c; }
.dark .nav-link:hover { color: #dad7cd; }

.mobile-nav-link {
  display: block;
  padding: 0.9rem 1rem;
  font-weight: 500;
  border-radius: 0.5rem;
  transition: background-color .2s;
}
.mobile-nav-link:hover,
.mobile-nav-link.active {
  background-color: rgba(218, 215, 205, .35);
  color: #941b0c;
}
.dark .mobile-nav-link:hover,
.dark .mobile-nav-link.active {
  background-color: rgba(255,255,255,.06);
  color: #dad7cd;
}

/* ---- Header scrolled state --------------------------------------------- */
#site-header.is-scrolled {
  box-shadow: 0 4px 24px -12px rgba(0,0,0,.15);
}
.dark #site-header.is-scrolled {
  box-shadow: 0 4px 24px -12px rgba(0,0,0,.6);
}

/* ---- Cookies visible state --------------------------------------------- */
#cookies.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* ---- Gallery hover ----------------------------------------------------- */
.gallery-item {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 0.75rem;
  aspect-ratio: 1 / 1;
  background: #eee;
}
.dark .gallery-item { background: #1a1a1a; }
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .5s ease, filter .3s ease;
}
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(0,0,0,.35), transparent 40%);
  opacity: 0; transition: opacity .3s;
}
.gallery-item:hover::after { opacity: 1; }

/* ---- Scrollbar (dark mode) --------------------------------------------- */
.dark ::-webkit-scrollbar { width: 10px; height: 10px; }
.dark ::-webkit-scrollbar-track { background: #111; }
.dark ::-webkit-scrollbar-thumb { background: #3a3a3a; border-radius: 5px; }
.dark ::-webkit-scrollbar-thumb:hover { background: #555; }
