html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  background-color: black;
}

h2 {
  margin: 0.5em;
}

.box h2 {
  font-size: 1em;
  font-weight: normal;
  margin: 1em 0;
}

#listen-heading {
  font-size: 1.5em;
  font-weight: bold;
  margin: 0.5em;
}

.container {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  padding: 0 0.5em;
  box-sizing: border-box;
}

.flex-col {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.box {
  width: fit-content;
  min-width: 50%;
  max-width: 100%;
  font-family: Superclarendon, "Bookman Old Style", "URW Bookman",
    "URW Bookman L", "Georgia Pro", Georgia, serif;
  font-weight: normal;
  font-size: 1.5em;
  padding: 0 1em;
  margin: 0.5em;
  z-index: 1;
  box-sizing: border-box;
}

.box1 {
  background-color: darkred;
  border: thick solid darkgreen;
  color: white;
}

.box1 a {
  color: white;
}

.box2 {
  background-color: darkblue;
  border: thick solid darkred;
  color: white;
}

.box3 {
  background-color: darkgreen;
  border: thick solid darkred;
  color: white;
}

#title {
  font-family: "UnifrakturCook", cursive;
  color: red;
  font-size: 10em;
  margin: 0;
}

#phone {
  font-family: "UnifrakturCook", cursive;
  font-size: 3.2em;
  margin: 0;
}

#countdown-box {
  text-align: center;
}

#countdown {
  display: flex;
  justify-content: center;
  gap: 1em;
  margin: 1em 0;
}

.countdown-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.countdown-number {
  font-family: "UnifrakturCook", cursive;
  font-size: 3.2em;
  margin: 0;
  font-variant-numeric: tabular-nums;
  min-width: 1.5em;
  text-align: center;
}

.countdown-label {
  font-size: 0.8em;
  margin-top: 0.25em;
}

/* Auto-generated phone number link */
a[href^="tel:"] {
  color: white;
}

@media screen and (max-width: 600px) {
  #title {
    font-size: 20vw;
  }

  #phone {
    font-size: 10vw;
    margin: 0.5em 0;
  }

  #countdown {
    gap: 0.8em;
  }

  .countdown-unit {
    flex: 1;
  }

  .countdown-number {
    font-size: 10vw;
    margin: 0;
    min-width: 0;
  }

  .countdown-label {
    font-size: 0.6em;
  }

  .box {
    width: 100%;
    min-width: 0;
  }
}

.small {
  font-size: 0.6em;
}

.big {
  font-size: 2em;
  margin: 0;
}

.gb-entry.htmx-added {
  background-color: lemonchiffon;
}

.gb-entry {
  background-color: darkred;
  border: 1px solid white;
  margin: 1em;
  padding: 0.5em;
  font-size: 0.9em;
  max-width: 40em;
  transition: background-color 1s ease-out;
}

.gb-comment {
  margin: 0.5em;
  font-family: "Nimbus Mono PS", "Courier New", monospace;
  font-weight: normal;
}

#load-more {
  margin: 1em;
  padding: 0.5em;
  font-size: 0.9em;
}

.a {
  --color-1: red;
  --color-2: limegreen;
}

.b {
  --color-1: limegreen;
  --color-2: red;
}

.a,
.b {
  animation: animate-title 2s linear infinite;
}

@keyframes animate-title {
  0% {
    color: var(--color-1);
  }
  49% {
    color: var(--color-1);
  }
  50% {
    color: var(--color-2);
  }
  99% {
    color: var(--color-2);
  }
  100% {
    color: var(--color-1);
  }
}

.lightrope {
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  position: fixed;
  z-index: 2;
  margin: -15px 0 0 0;
  padding: 0;
  pointer-events: none;
  width: 100%;
}

.lightrope li {
  position: relative;
  -webkit-animation-fill-mode: both;
  animation-fill-mode: both;
  -webkit-animation-iteration-count: infinite;
  animation-iteration-count: infinite;
  list-style: none;
  margin: 0;
  padding: 0;
  display: block;
  width: 12px;
  height: 28px;
  border-radius: 50%;
  margin: 20px;
  display: inline-block;
  background: #feb600;
  box-shadow: 0px 4.6666666667px 24px 3px #feb600;
  -webkit-animation-name: flash-1;
  animation-name: flash-1;
  -webkit-animation-duration: 2s;
  animation-duration: 2s;
}

.lightrope li:nth-child(2n + 1) {
  background: #110bba;
  box-shadow: 0px 4.6666666667px 24px 3px rgba(17, 11, 186, 0.5);
  -webkit-animation-name: flash-2;
  animation-name: flash-2;
  -webkit-animation-duration: 0.4s;
  animation-duration: 0.4s;
}

.lightrope li:nth-child(4n + 2) {
  background: #ba0b0b;
  box-shadow: 0px 4.6666666667px 24px 3px #ba0b0b;
  -webkit-animation-name: flash-3;
  animation-name: flash-3;
  -webkit-animation-duration: 1.1s;
  animation-duration: 1.1s;
}

.lightrope li:nth-child(odd) {
  -webkit-animation-duration: 1.8s;
  animation-duration: 1.8s;
}

.lightrope li:nth-child(3n + 1) {
  -webkit-animation-duration: 1.4s;
  animation-duration: 1.4s;
}

.lightrope li:before {
  content: "";
  position: absolute;
  background: #222;
  width: 10px;
  height: 9.3333333333px;
  border-radius: 3px;
  top: -4.6666666667px;
  left: 1px;
}

.lightrope li:after {
  content: "";
  top: -14px;
  left: 9px;
  position: absolute;
  width: 52px;
  height: 18.6666666667px;
  border-bottom: solid #222 2px;
  border-radius: 50%;
}

.lightrope li:last-child:after {
  content: none;
}

.lightrope li:first-child {
  margin-left: -40px;
}

@-webkit-keyframes flash-1 {
  0%,
  100% {
    background: #feb600;
    box-shadow: 0px 4.6666666667px 24px 3px #feb600;
  }
  50% {
    background: rgba(254, 182, 0, 0.4);
    box-shadow: 0px 4.6666666667px 24px 3px rgba(254, 182, 0, 0.2);
  }
}

@keyframes flash-1 {
  0%,
  100% {
    background: #feb600;
    box-shadow: 0px 4.6666666667px 24px 3px #feb600;
  }
  50% {
    background: rgba(254, 182, 0, 0.4);
    box-shadow: 0px 4.6666666667px 24px 3px rgba(254, 182, 0, 0.2);
  }
}

@-webkit-keyframes flash-2 {
  0%,
  100% {
    background: #110bba;
    box-shadow: 0px 4.6666666667px 24px 3px #110bba;
  }
  50% {
    background: rgba(17, 11, 186, 0.4);
    box-shadow: 0px 4.6666666667px 24px 3px rgba(17, 11, 186, 0.2);
  }
}

@keyframes flash-2 {
  0%,
  100% {
    background: #110bba;
    box-shadow: 0px 4.6666666667px 24px 3px #110bba;
  }
  50% {
    background: rgba(17, 11, 186, 0.4);
    box-shadow: 0px 4.6666666667px 24px 3px rgba(17, 11, 186, 0.2);
  }
}

@-webkit-keyframes flash-3 {
  0%,
  100% {
    background: #ba0b0b;
    box-shadow: 0px 4.6666666667px 24px 3px #ba0b0b;
  }
  50% {
    background: rgba(186, 11, 11, 0.4);
    box-shadow: 0px 4.6666666667px 24px 3px rgba(186, 11, 11, 0.2);
  }
}

@keyframes flash-3 {
  0%,
  100% {
    background: #ba0b0b;
    box-shadow: 0px 4.6666666667px 24px 3px #ba0b0b;
  }
  50% {
    background: rgba(186, 11, 11, 0.4);
    box-shadow: 0px 4.6666666667px 24px 3px rgba(186, 11, 11, 0.2);
  }
}

.bzzz {
  opacity: 0;
  position: absolute;
  top: 0;
  left: 0;
  height: 0;
  width: 0;
  z-index: -1;
}

html {
  background: #000;
  min-height: 100vh;
}

body {
  background: #000;
  min-height: 100vh;
  margin: 0;
  position: relative;
}

.snow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

.snow:after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 640px 480px' width='640px' height='480px'>   %3Cstyle> circle { r: 3px; } %3C/style>   %3Cg fill='%239098a0'> %3Ccircle cx='591px' cy='99px' /> %3Ccircle cx='591px' cy='363px' /> %3Ccircle cx='543px' cy='123px' /> %3Ccircle cx='525px' cy='15px' /> %3Ccircle cx='519px' cy='195px' /> %3Ccircle cx='501px' cy='183px' /> %3Ccircle cx='465px' cy='231px' /> %3Ccircle cx='465px' cy='375px' /> %3Ccircle cx='453px' cy='159px' /> %3Ccircle cx='447px' cy='435px' /> %3Ccircle cx='435px' cy='3px' /> %3Ccircle cx='399px' cy='123px' /> %3Ccircle cx='387px' cy='171px' /> %3Ccircle cx='381px' cy='207px' /> %3Ccircle cx='63px' cy='111px' /> %3Ccircle cx='357px' cy='471px' /> %3Ccircle cx='345px' cy='279px' /> %3Ccircle cx='345px' cy='63px' /> %3Ccircle cx='333px' cy='111px' /> %3Ccircle cx='321px' cy='183px' /> %3Ccircle cx='219px' cy='243px' /> %3Ccircle cx='213px' cy='375px' /> %3Ccircle cx='207px' cy='171px' /> %3Ccircle cx='189px' cy='111px' /> %3Ccircle cx='189px' cy='351px' /> %3Ccircle cx='177px' cy='423px' /> %3Ccircle cx='177px' cy='327px' /> %3Ccircle cx='141px' cy='171px' /> %3Ccircle cx='111px' cy='339px' /> %3Ccircle cx='93px' cy='255px' /> %3Ccircle cx='81px' cy='39px' /> %3Ccircle cx='57px' cy='447px' /> %3Ccircle cx='57px' cy='351px' /> %3Ccircle cx='75px' cy='411px' /> %3Ccircle cx='33px' cy='225px' /> %3Ccircle cx='33px' cy='279px' /> %3Ccircle cx='165px' cy='15px' /> %3Ccircle cx='27px' cy='387px' /> %3Ccircle cx='21px' cy='39px' />   %3C/g>%3C/svg>"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 640px 480px' width='640px' height='480px'>   %3Cstyle> circle { r: 3px; } %3C/style>   %3Cg fill='%236e757c'> %3Ccircle cx='591px' cy='99px' /> %3Ccircle cx='591px' cy='363px' /> %3Ccircle cx='543px' cy='123px' /> %3Ccircle cx='525px' cy='15px' /> %3Ccircle cx='519px' cy='195px' /> %3Ccircle cx='501px' cy='183px' /> %3Ccircle cx='465px' cy='231px' /> %3Ccircle cx='465px' cy='375px' /> %3Ccircle cx='453px' cy='159px' /> %3Ccircle cx='447px' cy='435px' /> %3Ccircle cx='435px' cy='3px' /> %3Ccircle cx='399px' cy='123px' /> %3Ccircle cx='387px' cy='171px' /> %3Ccircle cx='381px' cy='207px' /> %3Ccircle cx='63px' cy='111px' /> %3Ccircle cx='357px' cy='471px' /> %3Ccircle cx='345px' cy='279px' /> %3Ccircle cx='345px' cy='63px' /> %3Ccircle cx='333px' cy='111px' /> %3Ccircle cx='321px' cy='183px' /> %3Ccircle cx='219px' cy='243px' /> %3Ccircle cx='213px' cy='375px' /> %3Ccircle cx='207px' cy='171px' /> %3Ccircle cx='189px' cy='111px' /> %3Ccircle cx='189px' cy='351px' /> %3Ccircle cx='177px' cy='423px' /> %3Ccircle cx='177px' cy='327px' /> %3Ccircle cx='141px' cy='171px' /> %3Ccircle cx='111px' cy='339px' /> %3Ccircle cx='93px' cy='255px' /> %3Ccircle cx='81px' cy='39px' /> %3Ccircle cx='57px' cy='447px' /> %3Ccircle cx='57px' cy='351px' /> %3Ccircle cx='75px' cy='411px' /> %3Ccircle cx='33px' cy='225px' /> %3Ccircle cx='33px' cy='279px' /> %3Ccircle cx='165px' cy='15px' /> %3Ccircle cx='27px' cy='387px' /> %3Ccircle cx='21px' cy='39px' />   %3C/g>%3C/svg>"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 640px 480px' width='640px' height='480px'>   %3Cstyle> circle { r: 3px; } %3C/style>   %3Cg fill='%233e434a'> %3Ccircle cx='591px' cy='99px' /> %3Ccircle cx='591px' cy='363px' /> %3Ccircle cx='543px' cy='123px' /> %3Ccircle cx='525px' cy='15px' /> %3Ccircle cx='519px' cy='195px' /> %3Ccircle cx='501px' cy='183px' /> %3Ccircle cx='465px' cy='231px' /> %3Ccircle cx='465px' cy='375px' /> %3Ccircle cx='453px' cy='159px' /> %3Ccircle cx='447px' cy='435px' /> %3Ccircle cx='435px' cy='3px' /> %3Ccircle cx='399px' cy='123px' /> %3Ccircle cx='387px' cy='171px' /> %3Ccircle cx='381px' cy='207px' /> %3Ccircle cx='63px' cy='111px' /> %3Ccircle cx='357px' cy='471px' /> %3Ccircle cx='345px' cy='279px' /> %3Ccircle cx='345px' cy='63px' /> %3Ccircle cx='333px' cy='111px' /> %3Ccircle cx='321px' cy='183px' /> %3Ccircle cx='219px' cy='243px' /> %3Ccircle cx='213px' cy='375px' /> %3Ccircle cx='207px' cy='171px' /> %3Ccircle cx='189px' cy='111px' /> %3Ccircle cx='189px' cy='351px' /> %3Ccircle cx='177px' cy='423px' /> %3Ccircle cx='177px' cy='327px' /> %3Ccircle cx='141px' cy='171px' /> %3Ccircle cx='111px' cy='339px' /> %3Ccircle cx='93px' cy='255px' /> %3Ccircle cx='81px' cy='39px' /> %3Ccircle cx='57px' cy='447px' /> %3Ccircle cx='57px' cy='351px' /> %3Ccircle cx='75px' cy='411px' /> %3Ccircle cx='33px' cy='225px' /> %3Ccircle cx='33px' cy='279px' /> %3Ccircle cx='165px' cy='15px' /> %3Ccircle cx='27px' cy='387px' /> %3Ccircle cx='21px' cy='39px' />   %3C/g>%3C/svg>");
  background-size:
    640px 480px,
    480px 360px,
    256px 192px;
  background-repeat: repeat;
  background-position: 0 0;
  --snowfall-pos-x: 0;
  --snowfall-pos-y: 0;
  animation: snowfall-no-composition 96s linear infinite;
  will-change: background-position;
  transform: translateZ(0);
  contain: layout style paint;
}

@keyframes snowfall-no-composition {
  0% {
    background-position:
      0 0,
      0 0,
      0 0;
  }
  3.125% {
    background-position:
      -60px 480px,
      -45px 360px,
      -24px 192px;
  }
  33.3333333333% {
    background-position:
      -640px 5120px,
      -480px 3840px,
      -256px 2048px;
  }
  100% {
    background-position:
      -1920px 15360px,
      -1440px 11520px,
      -768px 6144px;
  }
}

@supports (animation-composition: replace, add, add) {
  .snow::after {
    animation:
      snowfall-x 32s linear infinite,
      snowfall-y 3s linear infinite,
      snowfall-x-wobble-1 8s cubic-bezier(0.35, 0, 0.65, 0.99) infinite,
      snowfall-x-wobble-2 8s cubic-bezier(0.35, 0, 0.65, 0.99) infinite;
    animation-composition: replace, add, add, add;
    animation-delay: 0s, 0s, 0s, 0.23s;
  }
}

@keyframes snowfall-y {
  from {
    background-position:
      0 0,
      0 0,
      0 0;
  }
  to {
    background-position:
      0 480px,
      0 360px,
      0 192px;
  }
}

@keyframes snowfall-x {
  from {
    background-position:
      0 0,
      0 0,
      0 0;
  }
  to {
    background-position:
      -640px 0,
      -480px 0,
      -256px 0;
  }
}

@keyframes snowfall-x-wobble-1 {
  0% {
    background-position: 16px 0;
  }
  50% {
    background-position: -16px 0;
  }
  100% {
    background-position: 16px 0;
  }
}

@keyframes snowfall-x-wobble-2 {
  0% {
    background-position:
      0 0,
      12px 0;
  }
  50% {
    background-position:
      0 0,
      -12px 0;
  }
  100% {
    background-position:
      0 0,
      12px 0;
  }
}

@keyframes snowfall-x-wobble {
  0% {
    background-position:
      16px 0,
      12px 0,
      6.4px 0;
  }
  50% {
    background-position:
      -16px 0,
      -12px 0,
      -6.4px 0;
  }
  100% {
    background-position:
      16px 0,
      12px 0,
      6.4px 0;
  }
}

/* SNOW ON TOP */
.box {
  position: relative;
}

.box::before {
  content: "";
  position: absolute;
  left: -5px;
  right: -5px;
  top: -15px;
  height: 15px;
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: 100% 100% 0 0;
  filter: blur(2px);

  background-image: radial-gradient(
      circle at 30% 100%,
      rgba(255, 255, 255, 0.8) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 70% 100%,
      rgba(255, 255, 255, 0.7) 0%,
      transparent 50%
    );

  box-shadow:
    0 -1px 4px rgba(255, 255, 255, 0.5),
    0 -2px 8px rgba(255, 255, 255, 0.4);
}

.box:nth-child(odd)::before {
  height: 18px;
  top: -18px;
}

.box:nth-child(3n)::before {
  height: 12px;
  top: -12px;
}

.box::after {
  content: "";
  position: absolute;
  left: -3px;
  right: -3px;
  top: -13px;
  height: 13px;
  background-image: radial-gradient(
      circle at 20% 50%,
      rgba(255, 255, 255, 0.8) 0%,
      transparent 15%
    ),
    radial-gradient(
      circle at 50% 50%,
      rgba(255, 255, 255, 0.7) 0%,
      transparent 10%
    ),
    radial-gradient(
      circle at 80% 50%,
      rgba(255, 255, 255, 0.8) 0%,
      transparent 15%
    );
  filter: blur(1px);
}

/* END SNOW ON TOP */

/* Main page navigation buttons */
.main-nav-buttons {
  display: flex;
  gap: 0.5em;
  justify-content: center;
  flex-wrap: wrap;
}

.main-nav-button {
  display: inline-block;
  margin: 0.5em;
  padding: 0.75em 1.5em;
  background-color: darkred;
  color: white;
  text-decoration: none;
  border-radius: 3px;
  border: 2px solid white;
  font-family: Superclarendon, "Bookman Old Style", "URW Bookman",
    "URW Bookman L", "Georgia Pro", Georgia, serif;
  font-size: 1.5em;
}

.main-nav-button:hover {
  background-color: red;
}

/* Visitor Counter - Geocities style */
.visitor-counter {
  text-align: center;
  padding: 1em 0;
}

.counter-label {
  font-size: 0.9em;
  margin: 0 0 0.5em 0;
  font-style: italic;
}

.counter-digits {
  display: inline-flex;
  gap: 2px;
  background-color: #000;
  padding: 8px 12px;
  border: 2px solid #333;
  border-radius: 4px;
  box-shadow: inset 0 0 10px rgba(0, 255, 0, 0.3);
}

.counter-digit {
  display: inline-block;
  font-family: "UnifrakturCook", cursive;
  font-size: 2em;
  font-weight: bold;
  background: linear-gradient(180deg, #0f0 0%, #0a0 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 0 5px rgba(0, 255, 0, 0.5);
  min-width: 0.6em;
  text-align: center;
  color: #0f0;
}

/* Screen reader only - visually hidden but accessible */
.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;
}

/* Accessibility: Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
  /* Disable snow animation */
  .snow:after {
    animation: none !important;
  }

  /* Make title colors static (alternating but not animated) */
  .a {
    animation: none !important;
    color: red;
  }

  .b {
    animation: none !important;
    color: limegreen;
  }

  /* Hide the animated lightrope */
  .lightrope {
    display: none;
  }

  /* Disable guestbook entry transition */
  .gb-entry {
    transition: none !important;
  }
}

/* GALLERY STYLES */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 300px));
  gap: 1.5em;
  padding: 1em;
  justify-content: center;
  max-width: 1000px;
  margin: 0 auto;
  box-sizing: border-box;
}

.gallery-item {
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.gallery-photo-box {
  background-color: darkred;
  border: 4px solid darkgreen;
  color: white;
  padding: 0.5em;
  box-sizing: border-box;
  position: relative;
  width: 300px;
  height: 300px;
}

.gallery-item:hover {
  transform: scale(1.05);
}

.gallery-item a {
  display: block;
  line-height: 0;
  width: 100%;
  height: 100%;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border: 2px solid white;
  box-sizing: border-box;
}

#upload-area {
  display: block;
}

#upload-area label {
  font-weight: bold;
}

#upload-area input[type="file"] {
  margin-bottom: 0.5em;
}

#upload-status {
  margin-top: 0.5em;
}

@media (max-width: 768px) {
  .gallery-grid {
    grid-template-columns: 1fr;
    gap: 1em;
    padding: 0 1em;
    max-width: 100%;
  }

  .gallery-item {
    width: 100%;
    aspect-ratio: 1 / 1;
  }

  .gallery-photo-box {
    width: 100%;
    height: 100%;
    padding: 0.5em;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
  }

  .gallery-item a {
    flex: 1;
    display: flex;
    min-height: 0;
  }

  .gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
}
