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

:root {
  --cord: hsl(210, 0%, calc((40 + (var(--on, 0) * 50)) * 1%));
  --opening: hsl(50, calc((10 + (var(--on, 0) * 80)) * 1%), calc((20 + (var(--on, 0) * 70)) * 1%));
  --feature: #0a0a0a;
  --accent: 210;
  --tongue: #e06952;
  --base-top: hsl(var(--accent), 0%, calc((40 + (var(--on, 0) * 40)) * 1%));
  --base-side: hsl(var(--accent), 0%, calc((20 + (var(--on, 0) * 40)) * 1%));
  --post: hsl(var(--accent), 0%, calc((20 + (var(--on, 0) * 40)) * 1%));
  --b-1: hsla(45, calc((0 + (var(--on, 0) * 0)) * 1%), calc((50 + (var(--on, 0) * 50)) * 1%), 0.85);
  --b-2: hsla(45, calc((0 + (var(--on, 0) * 0)) * 1%), calc((20 + (var(--on, 0) * 30)) * 1%), 0.25);
  --b-3: hsla(45, calc((0 + (var(--on, 0) * 0)) * 1%), calc((20 + (var(--on, 0) * 30)) * 1%), 0.5);
  --b-4: hsla(45, calc((0 + (var(--on, 0) * 0)) * 1%), calc((20 + (var(--on, 0) * 30)) * 1%), 0.25);
  --l-1: hsla(45, calc((0 + (var(--on, 0) * 20)) * 1%), calc((50 + (var(--on, 0) * 50)) * 1%), 0.85);
  --l-2: hsla(45, calc((0 + (var(--on, 0) * 20)) * 1%), calc((50 + (var(--on, 0) * 50)) * 1%), 0.85);
  --shade-hue: 320;
  --t-1: hsl(var(--shade-hue), calc((0 + (var(--on, 0) * 20)) * 1%), calc((30 + (var(--on, 0) * 60)) * 1%));
  --t-2: hsl(var(--shade-hue), calc((0 + (var(--on, 0) * 20)) * 1%), calc((20 + (var(--on, 0) * 35)) * 1%));
  --t-3: hsl(var(--shade-hue), calc((0 + (var(--on, 0) * 20)) * 1%), calc((10 + (var(--on, 0) * 20)) * 1%));
}

html, body {
  width: 100%;
  height: 100%;
}

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #121921;
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
}

.wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 600px;
  padding: 24px 16px;
}

.lamp-stage {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  width: 100%;
}

.lamp-form {
  display: contents;
}

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

.lamp {
  display: none;
  height: clamp(273px, 47.25vh, 441px);
  width: auto;
  overflow: visible !important;
  cursor: pointer;
}

.cord {
  stroke: var(--cord);
}

.cord--rig {
  display: none;
}

.lamp__tongue {
  fill: var(--tongue);
}

.lamp__hit {
  cursor: grab;
  touch-action: none;
  pointer-events: all !important;
  fill: #ffffff;
  opacity: 0.001;
  -webkit-tap-highlight-color: transparent;
}

.lamp__hit:active {
  cursor: grabbing;
}

.lamp__feature {
  fill: var(--feature);
}

.lamp__stroke {
  stroke: var(--feature);
}

.lamp__mouth {
  opacity: var(--on, 0);
  transition: opacity 0.25s ease;
}

.lamp__light {
  opacity: var(--on, 0);
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.shade__opening {
  fill: var(--opening);
}

.shade__opening-shade {
  opacity: calc(1 - var(--on, 0));
  transition: opacity 0.25s ease;
}

.post__body {
  fill: var(--post);
}

.base__top {
  fill: var(--base-top);
}

.base__side {
  fill: var(--base-side);
}

.top__body {
  fill: var(--t-3);
}

/* Typografia lightITup.pl */
.brand-container {
  margin-top: clamp(14px, 3vh, 32px);
  text-align: center;
}

.brand-title {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(2.4rem, 6vw, 3.8rem);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: #4b5b6d;
  transition: color 0.4s ease, text-shadow 0.4s ease;
}

.brand-link {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  outline: none;
  -webkit-tap-highlight-color: transparent;
  transition: none;
}

.brand-link:hover,
.brand-link:focus,
.brand-link:active,
.brand-link:visited {
  color: inherit;
  text-decoration: none;
  outline: none;
  box-shadow: none;
}

.brand-accent {
  display: inline-block;
  color: #1a2e47; /* Kolor kropki przy wyłączonej lampce */
  will-change: transform, color, text-shadow;
  transition: color 0.4s ease, text-shadow 0.4s ease;
}

.brand-dot {
  display: inline-block;
  color: #1a2e47; /* O wiele ciemniejsza i subtelniejsza przy wyłączonej lampce */
  font-weight: 400;
  will-change: transform, color, text-shadow;
  transition: color 0.4s ease, text-shadow 0.4s ease, font-weight 0.4s ease;
}

/* Animacja podskakiwania it oraz kropki po włączeniu lampki */
@keyframes bounce-it {
  0% {
    transform: translateY(0);
    animation-timing-function: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  }
  6% {
    transform: translateY(-7px);
    animation-timing-function: cubic-bezier(0.55, 0.085, 0.68, 0.53);
  }
  11% {
    transform: translateY(0);
    animation-timing-function: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  }
  15% {
    transform: translateY(-3px);
    animation-timing-function: cubic-bezier(0.55, 0.085, 0.68, 0.53);
  }
  19% {
    transform: translateY(0);
    animation-timing-function: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  }
  22% {
    transform: translateY(-1px);
    animation-timing-function: cubic-bezier(0.55, 0.085, 0.68, 0.53);
  }
  25%, 100% {
    transform: translateY(0);
  }
}

@keyframes bounce-dot {
  0%, 4% {
    transform: translateY(0) scale(1);
    animation-timing-function: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  }
  11% {
    transform: translateY(-10px) scale(0.95, 1.05);
    animation-timing-function: cubic-bezier(0.55, 0.085, 0.68, 0.53);
  }
  16% {
    transform: translateY(0) scale(1.08, 0.92);
    animation-timing-function: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  }
  21% {
    transform: translateY(-4.5px) scale(0.98, 1.02);
    animation-timing-function: cubic-bezier(0.55, 0.085, 0.68, 0.53);
  }
  25% {
    transform: translateY(0) scale(1.04, 0.96);
    animation-timing-function: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  }
  28% {
    transform: translateY(-1.5px) scale(1);
    animation-timing-function: cubic-bezier(0.55, 0.085, 0.68, 0.53);
  }
  31%, 100% {
    transform: translateY(0) scale(1);
  }
}

/* Stan włączonej lampki */
body.is-on .brand-title {
  color: #ffffff;
  text-shadow: 0 0 24px rgba(255, 255, 255, 0.25);
}

body.is-on .brand-accent {
  color: #3783f0; /* Kolor kropki po włączeniu */
  text-shadow:
    0 0 10px rgba(55, 131, 240, 0.9),
    0 0 24px rgba(55, 131, 240, 0.6),
    0 0 45px rgba(55, 131, 240, 0.35);
  animation: bounce-it 3.6s infinite;
}

body.is-on .brand-dot {
  color: #3783f0; /* Niebieska 3783f0 po włączeniu */
  font-weight: 600;
  text-shadow:
    0 0 10px rgba(55, 131, 240, 0.9),
    0 0 24px rgba(55, 131, 240, 0.6),
    0 0 45px rgba(55, 131, 240, 0.35);
  animation: bounce-dot 3.6s infinite;
}
