/* Mikołajkowy Rajd Uśmiechu 2026 - prosty, lekki styling bez zależności. */

:root {
  color-scheme: light dark;

  /* Paleta wyciągnięta z logo i bannera (zmień wartości tutaj, jeśli zajdzie potrzeba). */
  --red: #c81f2b;
  --red-deep: #a51620;
  --red-bright: #ff6b6b;
  --cream: #fff8ee;
  --ink: #24171a;

  --bg: var(--cream);
  --surface: #ffffff;
  --surface-2: #fbe9e5;
  --border: #efdcd6;
  --text: var(--ink);
  --text-muted: #5a4a4d;
  --shadow: 0 18px 50px -24px rgba(75, 20, 25, .28);
  --snow-rgb: 132, 158, 178;
  --snow-alpha: .52;

  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-soft: cubic-bezier(.4, 0, .2, 1);
  --wrap: 1120px;
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #120a0f;
    --surface: #1d1218;
    --surface-2: #29161d;
    --border: #44252d;
    --text: #f7ebe5;
    --text-muted: #c8b9b9;
    --red: #ff5a5f;
    --red-deep: #ff6b6b;
    --red-bright: #ff9999;
    --shadow: 0 18px 50px -24px rgba(0, 0, 0, .75);
    --snow-rgb: 255, 255, 255;
    --snow-alpha: .74;
  }
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, p, ul, ol { margin: 0; }
img, svg, video, canvas { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; }

/* Feather: stroke icons. Brand and solid icons are explicitly exempted. */
svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.brand-icon, .icon-fill { fill: currentColor; stroke: none; }

:focus-visible {
  outline: 3px solid var(--red-deep);
  outline-offset: 3px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform .18s var(--ease-soft);
}
.skip-link:focus { transform: none; }

#snow {
  position: fixed;
  inset: 0;
  z-index: 20;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* Animacje wejścia: tylko opacity i transform. */
@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}
.fade-in {
  animation: rise .65s var(--ease) both;
  animation-delay: var(--delay, 0ms);
}

.fade-up {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity .6s var(--ease) var(--delay, 0ms),
    transform .6s var(--ease) var(--delay, 0ms);
}
.fade-up.is-visible { opacity: 1; transform: none; }

/* ---------- HERO ---------- */

.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;
  padding: calc(104px + env(safe-area-inset-top)) clamp(20px, 5vw, 72px) calc(104px + env(safe-area-inset-bottom));
  overflow: hidden;
  color: #fff;
  text-align: center;
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: #0b0709;
}

.hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Telefon: cały kadr widoczny, wypełnienie po bokach statycznie rozmytym posterem. */
.hero__backdrop {
  display: none;
  position: absolute;
  inset: -48px;
  background: url("assets/poster.jpg") center / cover no-repeat;
  filter: blur(28px);
  transform: scale(1.08);
  opacity: .9;
}

.hero__tint {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(11, 5, 8, .68) 0%, rgba(11, 5, 8, .28) 44%, rgba(11, 5, 8, .82) 100%),
    radial-gradient(ellipse at 50% 42%, rgba(200, 31, 43, .22), transparent 68%);
}

@media (max-width: 700px), (max-aspect-ratio: 4 / 5) {
  .hero__backdrop { display: block; }
  .hero__video { object-fit: contain; }
}

.hero__top {
  position: absolute;
  top: calc(20px + env(safe-area-inset-top));
  left: clamp(16px, 5vw, 72px);
  right: clamp(16px, 5vw, 72px);
  z-index: 3;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  width: clamp(64px, 8vw, 92px);
  padding: 6px;
  border-radius: 18px;
  background: var(--cream);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .3);
  transition: transform .18s var(--ease-soft);
}
.brand:hover { transform: translateY(-2px); }
.brand img { width: 100%; height: auto; border-radius: 12px; }

.social-top { display: flex; gap: 8px; }
.social-top a {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(20, 8, 12, .58);
  border: 1px solid rgba(255, 255, 255, .32);
  color: #fff;
  transition: transform .18s var(--ease-soft), background-color .18s var(--ease-soft);
}
.social-top a:hover { transform: translateY(-2px); background: rgba(200, 31, 43, .85); }

.hero__content {
  position: relative;
  z-index: 2;
  width: min(100%, 860px);
  margin-inline: auto;
}

.eyebrow {
  font-size: clamp(.7rem, 1.2vw, .84rem);
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #ffd8c7;
}

.hero__title {
  margin-top: 14px;
  font-family: "Luckiest Guy", cursive;
  font-weight: 400;
  font-size: clamp(2.6rem, 8.5vw, 6.6rem);
  line-height: .98;
  letter-spacing: .01em;
  text-shadow: 0 6px 30px rgba(0, 0, 0, .5);
}
.hero__title span { color: var(--red-bright); }

.hero__lead {
  margin-top: 22px;
  font-size: clamp(.98rem, 2vw, 1.2rem);
  color: #fff2e9;
}

.countdown {
  display: inline-flex;
  align-items: center;
  gap: clamp(8px, 2vw, 18px);
  margin-top: 28px;
  padding: 14px clamp(16px, 3vw, 28px);
  border-radius: 999px;
  background: rgba(20, 8, 12, .58);
  border: 1px solid rgba(255, 255, 255, .24);
}
.countdown__unit { display: grid; justify-items: center; min-width: 3.4ch; }
.countdown__unit strong {
  min-width: 2.6ch;
  font-family: "Luckiest Guy", cursive;
  font-weight: 400;
  font-size: clamp(1.55rem, 4vw, 2.35rem);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  color: #fff;
}
.countdown__unit span {
  font-size: .66rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #ffd8c7;
}
.countdown__sep { font-size: 1.35rem; color: var(--red-bright); }

.hero__note { margin-top: 18px; color: #fff2e9; font-size: .95rem; }

.video-toggle {
  position: absolute;
  right: clamp(16px, 5vw, 72px);
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 4;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .35);
  background: rgba(20, 8, 12, .58);
  color: #fff;
  cursor: pointer;
  transition: background-color .18s var(--ease-soft);
}
.video-toggle:hover { background: rgba(200, 31, 43, .85); }
.video-toggle .icon-play { display: none; }
.video-toggle[aria-pressed="true"] .icon-play { display: block; }
.video-toggle[aria-pressed="true"] .icon-pause { display: none; }

.scroll-cue {
  position: absolute;
  left: 0;
  right: 0;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 4;
  width: max-content;
  margin-inline: auto;
  display: grid;
  justify-items: center;
  gap: 2px;
  color: #fff;
  font-size: .68rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  text-decoration: none;
}
.scroll-cue svg { animation: bob 2.2s var(--ease-soft) infinite; }
@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(5px); }
}

/* ---------- NAWIGACJA KROPKAMI ---------- */

.dots {
  position: fixed;
  right: clamp(8px, 2vw, 22px);
  top: 50%;
  z-index: 15;
  display: grid;
  gap: 4px;
  transform: translateY(-50%);
}
.dots a {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
}
.dots a::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(120, 70, 70, .35);
  transition: transform .2s var(--ease-soft), background-color .2s var(--ease-soft);
}
.dots a:hover::after, .dots a.is-active::after {
  background: var(--red-deep);
  transform: scale(1.4);
}

/* ---------- SEKCJE ---------- */

.section { padding: clamp(72px, 10vw, 132px) 0; scroll-margin-top: 20px; }
.wrap { width: min(100% - 40px, var(--wrap)); margin-inline: auto; }

.kicker {
  margin-bottom: 14px;
  color: var(--red-deep);
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.section h2 {
  margin-bottom: 22px;
  font-family: "Luckiest Guy", cursive;
  font-weight: 400;
  font-size: clamp(1.9rem, 4.4vw, 3.2rem);
  line-height: 1.1;
}
.section p { color: var(--text-muted); }

.section--about { background: var(--bg); }
.about-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: clamp(36px, 6vw, 84px);
  align-items: center;
}
.about-grid p + p { margin-top: 16px; }
.about-grid__highlight { color: var(--text); font-weight: 700; }

.facts { display: grid; gap: 14px; padding: 0; list-style: none; }
.facts li {
  display: flex;
  gap: 16px;
  padding: 20px;
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.facts__icon {
  flex: 0 0 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: var(--surface-2);
  color: var(--red-deep);
}
.facts strong { display: block; margin-bottom: 3px; }
.facts li div > span { font-size: .92rem; color: var(--text-muted); }

.section--program { background: var(--surface-2); }
.section-head { max-width: 720px; }
.timeline { display: grid; gap: 16px; padding: 0; list-style: none; }
.timeline li {
  display: grid;
  grid-template-columns: minmax(90px, 130px) 48px 1fr;
  gap: 18px;
  align-items: center;
  padding: 22px;
  border-radius: 22px;
  background: var(--surface);
  border: 1px solid var(--border);
}
.timeline__time {
  color: var(--red-deep);
  font-family: "Luckiest Guy", cursive;
  font-size: 1.1rem;
}
.timeline__icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: var(--surface-2);
  color: var(--red-deep);
}
.timeline h3 { margin-bottom: 4px; font-size: 1.05rem; }

.section--map { background: var(--bg); }
.map-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  color: var(--red-deep);
  font-weight: 700;
  text-underline-offset: 4px;
}
.map-frame {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.map-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.section--final {
  background: linear-gradient(150deg, #8e1620, var(--red) 60%, #e33a3f);
  color: #fff;
}
.section--final .kicker { color: #ffe0d3; }
.section--final p { color: rgba(255, 255, 255, .9); }
.final-card { max-width: 980px; margin-inline: auto; text-align: center; }
.final-card__image {
  width: 100%;
  height: auto;
  margin-top: 28px;
  border-radius: 20px;
  box-shadow: 0 24px 60px -20px rgba(0, 0, 0, .55);
}
.final-card__text {
  display: inline-block;
  margin-top: 22px;
  padding: 12px 24px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .35);
  color: #fff;
  font-weight: 700;
}

.section--contact { background: var(--bg); }
.contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 36px; }
.contact-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  transition: transform .18s var(--ease-soft), border-color .18s var(--ease-soft), box-shadow .18s var(--ease-soft);
}
.contact-card:hover { transform: translateY(-3px); border-color: var(--red); box-shadow: var(--shadow); }
.contact-card > svg { flex: 0 0 auto; color: var(--red-deep); }
.contact-card small {
  display: block;
  color: var(--text-muted);
  font-size: .68rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.contact-card span { overflow-wrap: anywhere; }

.contact-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; margin-top: 28px; }
.button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  background: var(--red-deep);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  transition: transform .18s var(--ease-soft), filter .18s var(--ease-soft);
}
.button:hover { transform: translateY(-2px); filter: brightness(1.08); }
.hashtags { font-size: .85rem; }

.footer { border-top: 1px solid var(--border); padding: 28px 0 calc(28px + env(safe-area-inset-bottom)); }
.footer__inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--text-muted);
  font-size: .85rem;
}
.footer a { color: var(--red-deep); font-weight: 700; text-decoration: none; }

/* ---------- MOBILE ---------- */

@media (max-width: 760px) {
  .hero { padding-inline: 20px; }
  .hero__title { font-size: clamp(2.5rem, 11vw, 4rem); }
  .hero__lead { margin-top: 18px; }
  .countdown { gap: 6px; padding: 12px 14px; }
  .social-top a { width: 40px; height: 40px; }
  .dots { display: none; }

  .about-grid, .map-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .timeline li { grid-template-columns: 44px 1fr; gap: 12px; }
  .timeline__time { grid-column: 1 / -1; }
}

@media (max-width: 380px) {
  .hero__top { gap: 8px; }
  .brand { width: 60px; }
  .social-top a { width: 38px; height: 38px; }
}

/* ---------- REDUCED MOTION ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .fade-up { opacity: 1; transform: none; }
}
