:root {
  --wedding-pink: #f14e95;
  --text: #ffffff;
  --text-soft: rgba(255, 255, 255, 0.72);
  --overlay-top: rgba(0, 0, 0, 0.46);
  --overlay-bottom: rgba(0, 0, 0, 0.22);
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  background: #111;
}

body {
  font-family: "Work Sans", Arial, sans-serif;
  font-weight: 300;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.wedding-screen {
  position: relative;
  width: 100vw;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  isolation: isolate;
  background: #111;
}

.background-video,
.video-fallback,
.video-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.background-video {
  z-index: -3;
  object-fit: cover;
  object-position: center center;
  background: #111;
}

.video-fallback {
  z-index: -4;
  background:
    radial-gradient(circle at 50% 35%, rgba(241, 78, 149, 0.18), transparent 35%),
    linear-gradient(135deg, #1c1c1c, #070707 70%);
}

.video-overlay {
  z-index: -2;
  pointer-events: none;
  background: linear-gradient(to bottom, var(--overlay-top), var(--overlay-bottom) 42%, rgba(0,0,0,.36));
}

.wedding-nav {
  position: absolute;
  z-index: 10;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(1560px, calc(100% - 64px));
  min-height: 92px;
  padding: max(18px, env(safe-area-inset-top)) 0 14px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: clamp(52px, 5vw, 110px);
}

.wedding-logo {
  flex: 0 0 auto;
  margin: 0;
  padding: 0;
  color: #fff;
  text-decoration: none;
  font-family: "Sacramento", cursive;
  font-size: clamp(38px, 3.1vw, 50px);
  line-height: 1;
  font-weight: 400;
  white-space: nowrap;
  text-align: left;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.34);
}

.wedding-date {
  display: inline-block;
  margin-left: .22em;
  color: #fff;
  font-family: "Work Sans", Arial, sans-serif;
  font-size: .23em;
  font-weight: 400;
  letter-spacing: .08em;
  vertical-align: .34em;
}

.wedding-menu {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  gap: clamp(20px, 2.1vw, 38px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.wedding-menu li {
  margin: 0;
  padding: 0;
}

.wedding-menu a {
  position: relative;
  display: block;
  padding: 10px 0;
  color: var(--text-soft);
  text-decoration: none;
  font-size: clamp(11px, .78vw, 14px);
  line-height: 1.25;
  font-weight: 400;
  letter-spacing: 0.01em;
  white-space: nowrap;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.5);
  transition: color 180ms ease, transform 180ms ease;
}

.wedding-menu a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: 3px;
  height: 1px;
  background: #fff;
  transition: right 180ms ease;
}

.wedding-menu a:hover,
.wedding-menu a:focus-visible {
  color: #fff;
  transform: translateY(-1px);
}

.wedding-menu a:hover::after,
.wedding-menu a:focus-visible::after {
  right: 0;
}

.wedding-menu a:focus-visible,
.wedding-logo:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 5px;
  border-radius: 2px;
}

/* Mniejszy laptop / tablet — logo nad menu, aby nic się nie ściskało. */
@media (max-width: 1120px) {
  .wedding-nav {
    width: min(820px, calc(100% - 36px));
    min-height: 162px;
    padding-top: max(16px, env(safe-area-inset-top));
    flex-direction: column;
    gap: 8px;
  }

  .wedding-logo {
    font-size: 45px;
    text-align: center;
  }

  .wedding-menu {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px 14px;
  }

  .wedding-menu a {
    padding: 8px 10px;
    text-align: center;
    white-space: normal;
    font-size: 13px;
  }

  .wedding-menu a::after {
    left: 16%;
    right: 84%;
  }

  .wedding-menu a:hover::after,
  .wedding-menu a:focus-visible::after {
    right: 16%;
  }
}

/* Telefon — cały ekran pozostaje nieruchomy */
@media (max-width: 520px) {
  .wedding-nav {
    width: calc(100% - 24px);
    min-height: 168px;
    gap: 6px;
    padding-top: max(12px, env(safe-area-inset-top));
  }

  .wedding-logo {
    font-size: clamp(35px, 10.5vw, 43px);
  }

  .wedding-date {
    display: inline-block;
    margin-left: .18em;
    font-size: .22em;
    vertical-align: .34em;
  }

  .wedding-menu {
    gap: 4px 8px;
  }

  .wedding-menu a {
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px 7px;
    font-size: 11.5px;
    line-height: 1.2;
  }
}

/* Bardzo niski ekran, np. telefon poziomo */
@media (max-height: 460px) {
  .wedding-nav {
    width: calc(100% - 28px);
    min-height: 92px;
    gap: 3px;
    padding-top: max(7px, env(safe-area-inset-top));
  }

  .wedding-logo {
    font-size: 31px;
  }

  .wedding-date {
    font-size: .22em;
  }

  .wedding-menu {
    display: flex;
    width: auto;
    gap: 12px;
  }

  .wedding-menu a {
    min-height: 0;
    padding: 5px 0;
    font-size: 10.5px;
    white-space: nowrap;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
