@font-face {
  font-family: "Heebo";
  src: url("/regular-led-heebo.woff") format("woff");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* Approved regular LED calculator. All selectors are scoped to this section. */
#pxd-regular-calculator {
  --pxd-ink: #111126;
  --pxd-sub: #292942;
  --pxd-progress: 7.69%;
  position: relative;
  isolation: isolate;
  overflow: clip;
  background: #101728;
  color: #fff;
  scroll-margin-block-start: 5rem;
  font-family: "Heebo", Arial, sans-serif;
  font-weight: 400;

  &::before {
    content: "";
    position: absolute;
    z-index: -1;
    inset: 0;
    background: url("/regular-led-pool.webp") center / cover;
    filter: blur(8px);
    transform: scale(1.05);
  }

  & .pxd-layout {
    position: relative;
    isolation: isolate;
    container-type: inline-size;
    display: grid;
    grid-template-columns: minmax(0, 49.25%) minmax(0, 1fr);
    align-items: start;
    row-gap: 1rem;
    width: min(100%, 1254px);
    min-height: min(100vw, 1254px);
    margin-inline: auto;
    padding: min(13.6vw, 171px) min(1.25vw, 16px) min(8vw, 100px) min(4.25vw, 53px);
    background: #15223d url("/regular-led-pool.webp") center top / 100% auto no-repeat;
  }

  & .pxd-intro {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    width: min(100%, 24.4cqw);
    margin-block-start: -10.4cqw;
    text-align: right;
    text-shadow: 0 2px 12px #03070daf;
  }

  & .pxd-brand {
    display: block;
    width: 25cqw;
    height: auto;
    margin-inline-start: -.2cqw;
  }

  & .pxd-intro h2 {
    margin: 1.6cqw 0 0;
    color: #fff;
    font: 700 clamp(2.5rem, 6.15cqw, 4.65rem)/.94 "Heebo", Arial, sans-serif;
    letter-spacing: -.045em;
    text-align: left;
    white-space: nowrap;
  }

  & .pxd-description {
    margin: 0;
    color: #fff;
    font-size: clamp(1.125rem, 2.025cqw, 1.5625rem);
    line-height: 1.48;
    text-shadow: 0 1px 2px rgb(0 0 0 / 70%), 0 2px 6px rgb(0 0 0 / 35%);
  }

  & .pxd-description::before {
    content: "";
    display: block;
    width: 57%;
    margin: 2.35cqw auto 1.55cqw;
    height: .37em;
    max-height: 7px;
    border-radius: 1em;
    background: linear-gradient(90deg, #db00ee, #2e41f7, #00c8f5);
  }

  & .pxd-panel {
    position: relative;
    grid-column: 1;
    grid-row: 1;
    min-width: 0;
    padding: clamp(1.15rem, 1.9cqw, 1.55rem);
    padding-block: clamp(1.35rem, 2.65cqw, 2.1rem) clamp(1.5rem, 3.1cqw, 2.45rem);
    border: 1px solid #fff;
    border-radius: clamp(1.65rem, 3.55cqw, 2.9rem);
    background:
      radial-gradient(ellipse at 3% 65%, #f2ddfde8 0%, transparent 58%),
      linear-gradient(126deg, #e2e3f8f5, #e7def1f7 62%, #e8e8f5fa);
    box-shadow: 0 14px 42px #120a3280, inset 0 1px 0 #fff;
    color: var(--pxd-ink);
  }

  & .pxd-head { display: flex; align-items: start; gap: clamp(.65rem, 1.4cqw, 1.15rem); margin-block-end: 1.35rem; text-align: right; }
  & .pxd-head h2 { margin: 0 0 .4rem; color: var(--pxd-ink); font: 700 clamp(1.24rem, 2.45cqw, 1.88rem)/1.1 "Heebo", Arial, sans-serif; letter-spacing: -.045em; }
  & .pxd-head p { margin: 0; color: var(--pxd-sub); font-size: clamp(.88rem, 1.56cqw, 1.18rem); line-height: 1.3; }
  & .pxd-headicon {
    flex: none;
    display: grid;
    place-items: center;
    width: clamp(2.65rem, 4.55cqw, 3.5rem);
    aspect-ratio: 1;
    border-radius: 23%;
    color: #fff;
    background: linear-gradient(110deg, #bc00ef, #2935ff 57%, #008bff);
  }
  & .pxd-headicon svg { width: 65%; height: 65%; }

  & form { display: block; padding: 0; margin: 0; border: 0; color: inherit; background: none; }
  & .pxd-field {
    min-inline-size: 0;
    padding: 0;
    border: none;
    margin: 0 0 clamp(.95rem, 1.65cqw, 1.5rem);
  }
  & .pxd-fieldhead { display: block; padding: 0; margin: 0; color: var(--pxd-ink); font-size: clamp(.96rem, 1.66cqw, 1.27rem); font-weight: 500; line-height: 1.2; }
  & .pxd-location {
    display: grid;
    grid-template-columns: auto minmax(0,1fr);
    align-items: center;
    gap: .65rem;
  }
  & .pxd-location .pxd-fieldhead { font-size: clamp(.8rem, 1.3cqw, 1rem); }
  & .pxd-environments, & .pxd-sizegrid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(.52rem, 1.12cqw, .92rem);
  }

  & .pxd-choice, & .pxd-use {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pxd-ink);
    border: 2px solid transparent;
    background: #ffffffbf;
    cursor: pointer;
    text-align: center;
  }
  & .pxd-choice {
    min-height: 44px;
    border-radius: .75rem;
    padding: .27rem .38rem;
    gap: .36rem;
    font-size: clamp(.76rem, 1.3cqw, 1rem);
    line-height: 1.2;
    font-weight: 500;
  }
  & .pxd-choice svg { flex: none; width: 1.05rem; height: 1.05rem; fill: none; stroke: #393255; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
  & .pxd-choice:has(input:checked), & .pxd-use:has(input:checked) {
    background: linear-gradient(135deg,#edf4ff,#eae6ff) padding-box,
                linear-gradient(165deg,#009dff,#395cff 55%,#be15ff) border-box;
  }
  & .pxd-choice input, & .pxd-use input {
    position: absolute; width: 1px; height: 1px; inset: 0 auto auto 0; opacity: 0;
  }
  & .pxd-choice:has(input:focus-visible), & .pxd-use:has(input:focus-visible) {
    outline: 3px solid #3518a4;
    outline-offset: 2px;
  }

  & .pxd-sizebox {
    min-width: 0;
    padding: clamp(.57rem, 1.08cqw, .89rem);
    border-radius: clamp(.8rem, 1.68cqw, 1.25rem);
    background: #ffffffe0;
    box-shadow: 0 3px 9px #2b1c5420;
  }
  & .pxd-sizebox label { display: block; margin: 0 0 .48rem; font-size: clamp(.95rem, 1.84cqw, 1.42rem); line-height: 1.1; font-weight: 500; }
  & .pxd-sizeinput {
    display: flex; align-items: center; gap: .45rem; min-height: 44px;
    padding-inline: .56rem; border-radius: .74rem; background: #fff;
  }
  & .pxd-sizeinput:focus-within { box-shadow: 0 0 0 2px #6c49f4; }
  & .pxd-sizeinput input {
    width: 100%; min-width: 0; height: 44px; padding: 0; appearance: textfield;
    background: none; border: 0; color: inherit; direction: ltr; text-align: right;
    font: 500 clamp(1.1rem, 2.15cqw, 1.7rem)/1 "Heebo", Arial, sans-serif;
  }
  & .pxd-sizeinput input::-webkit-inner-spin-button, & .pxd-sizeinput input::-webkit-outer-spin-button {
    appearance: none; margin: 0;
  }
  & .pxd-sizeinput span { font-size: .92rem; white-space: nowrap; }

  & .pxd-distancebar { display: flex; align-items: center; justify-content: space-between; gap: .56rem; margin-block-end: .35rem; }
  & .pxd-distancevalue { white-space: nowrap; background: #ffffffc9; padding: .37rem .8rem; border-radius: .95rem; line-height: 1; font-size: .9rem; }
  & .pxd-distancevalue bdi { font-size: clamp(1.15rem, 2.05cqw, 1.6rem); font-weight: 500; }
  & .pxd-range {
    appearance: none;
    display: block;
    margin: 0;
    width: 100%;
    height: 30px;
    background: transparent;
    cursor: pointer;
  }
  & .pxd-range::-webkit-slider-runnable-track {
    height: 8px; border-radius: 999px;
    background: linear-gradient(to right,#c000ed,#6539ff) left / var(--pxd-progress) 100% no-repeat, #999fd2;
  }
  & .pxd-range::-moz-range-track {
    height: 8px; border-radius: 999px;
    background: linear-gradient(to right,#c000ed,#6539ff) left / var(--pxd-progress) 100% no-repeat, #999fd2;
  }
  & .pxd-range::-webkit-slider-thumb {
    appearance: none; width: 25px; height: 25px; margin-top: -8.5px;
    background: #fff; border: 4px solid #5324fd; border-radius: 50%;
    box-shadow: 0 2px 7px #512ef57a;
  }
  & .pxd-range::-moz-range-thumb {
    width: 17px; height: 17px; border: 4px solid #5324fd; border-radius: 50%; background: #fff;
  }
  & .pxd-rangeends { display: flex; justify-content: space-between; direction: ltr; font-size: .88rem; }

  & fieldset .pxd-fieldhead { font-size: clamp(1rem, 2.25cqw, 1.7rem); font-weight: 700; }
  & .pxd-usagegrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(.32rem, .83cqw, .67rem); margin-top: .94rem; }
  & .pxd-use {
    min-height: clamp(5.85rem, 10.6cqw, 8.15rem);
    flex-direction: column;
    gap: .46rem;
    padding: .65rem .27rem;
    border-radius: clamp(.65rem, 1.55cqw, 1.21rem);
    font-size: clamp(.75rem, 1.48cqw, 1.13rem);
    font-weight: 500;
    line-height: 1.25;
  }
  & .pxd-use .pxd-uicon { font-size: clamp(1.5rem, 2.85cqw, 2.25rem); line-height: 1; }
  & .pxd-use svg.pxd-uicon { width: 1.08em; height: 1.08em; fill: none; stroke: currentColor; stroke-width: 2.4; }
  & .pxd-use .pxd-tick {
    display: none; position: absolute; inset: -.57rem .17rem auto auto;
    width: clamp(1.3rem, 2.95cqw, 2.35rem); aspect-ratio: 1;
    place-items: center; border-radius: 50%; color: white; background: linear-gradient(125deg,#6338fb,#007ef4);
  }
  & .pxd-use:has(input:checked) .pxd-tick { display: grid; }

  & .pxd-submit {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .56rem;
    min-height: clamp(3.05rem, 5.65cqw, 4.35rem);
    border: 1px solid #f8f3ff;
    border-radius: 999px;
    background: linear-gradient(92deg,#bd00f0,#5621fb 37%,#0730ef 69%,#00a9f4);
    color: white;
    font: 600 clamp(1.07rem, 2.55cqw, 1.95rem)/1.12 "Heebo", Arial, sans-serif;
    margin-block-start: clamp(.2rem, 1.4cqw, 1rem);
    padding: .55rem .75rem;
    cursor: pointer;
  }
  & .pxd-submit svg { width: 1.13em; height: 1.13em; stroke: currentColor; fill: none; stroke-width: 2.7; stroke-linecap: round; stroke-linejoin: round; }
  & .pxd-submit:hover, & .pxd-copy:hover { filter: brightness(1.08); }
  & .pxd-panel :focus-visible { outline: 3px solid #3518a4 !important; outline-offset: 2px; }
  & .pxd-sizeinput input:focus-visible { outline-offset: -3px; }
  & .pxd-error{display:none;border:1px solid #ec98bb;background:#fff3f7;border-radius:12px;color:#9b1746;margin:10px 0;padding:10px;font-size:13px}
  & .pxd-error.pxd-show{display:block}
  & .pxd-results{display:none;margin-top:21px;padding:19px;border-radius:19px;background:#ffffffb3;border:1px solid #fff;box-shadow:0 8px 25px #9875c019}
  & .pxd-results.pxd-show{display:block}
  & .pxd-resulttop{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:12px}
  & .pxd-resulttop strong{font-size:16px;font-weight:700}
  & .pxd-status{font-size:11px;font-weight:500;background:#e5ddff;color:#5433aa;border-radius:20px;padding:7px 11px}
  & .pxd-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
  & .pxd-stat{padding:12px 8px;background:#ffffffc8;border-radius:13px;min-width:0}
  & .pxd-stat small{font-size:11px;color:#534b68;display:block;line-height:1.4;min-height:28px}
  & .pxd-stat strong{display:block;font-size:clamp(15px,1.55vw,21px);direction:ltr;text-align:right;white-space:nowrap;color:#262043;margin-top:5px;font-weight:500}
  & .pxd-stat.pxd-primary strong{font-size:clamp(24px,2.2vw,32px);background:linear-gradient(100deg,#0066e5,#8129ff,#c936da);-webkit-background-clip:text;background-clip:text;color:transparent}
  & .pxd-resulttext{font-size:13px;line-height:1.62;margin:12px 0 9px;color:#443a5d}
  & .pxd-alt{display:flex;flex-wrap:wrap;align-items:center;gap:9px;background:#ede7ff;border-radius:11px;padding:11px;color:#4e3a7b;font-size:12px;line-height:1.5;margin-top:8px}
  & .pxd-copy{margin:12px 0 0;display:block;width:100%;border:1px solid #b7a9eb;background:#f8f4ff;border-radius:11px;padding:12px 16px;color:#5a34b2;font-weight:600;font-family:inherit;font-size:13px;cursor:pointer}
  & .pxd-extra{font-size:12px;color:#60566e;margin-top:9px;line-height:1.5}
  & .pxd-extra summary{cursor:pointer;font-weight:600;color:#5c38ae}
  & .pxd-extra ul{padding-right:18px;margin:8px 0}
  & .pxd-alt[hidden] { display: none; }
  & .pxd-stat strong { white-space: normal; overflow-wrap: anywhere; }
  & .pxd-results { scroll-margin-block-start: 5rem; }
  & .pxd-results:focus { outline: 0 !important; box-shadow: none; }
}

html.contrast #pxd-regular-calculator .pxd-panel { color: #101020; }
html.contrast #pxd-regular-calculator form { background: transparent; color: inherit; }

@media (min-width: 851px) {
  #pxd-regular-calculator {
    /* Align the sharp-to-soft transition with the LED Film stage above. */
    --pxd-photo-width: min(100vw, 1672px, max(1120px, calc((100svh - 24px) * 1.7768)));
  }
  #pxd-regular-calculator::before {
    inset: -26px;
    filter: blur(20px) saturate(1.16);
    transform: none;
  }
  #pxd-regular-calculator::after {
    content: "";
    position: absolute;
    z-index: -1;
    inset: 0 0 auto;
    width: min(100%, var(--pxd-photo-width));
    aspect-ratio: 1;
    margin-inline: auto;
    background: url("/regular-led-pool.webp") center top / 100% auto no-repeat;
    pointer-events: none;
  }
  #pxd-regular-calculator .pxd-layout {
    min-height: var(--pxd-photo-width);
    background: transparent;
  }
}

@media (max-width: 850px) {
  #pxd-regular-calculator .pxd-layout {
    grid-template-columns: minmax(0,1fr);
    padding: 0 max(.75rem,env(safe-area-inset-right,0px)) 1.65rem max(.75rem,env(safe-area-inset-left,0px));
    background-size: auto max(36rem,100vw);
    background-position: 9% top;
  }
  #pxd-regular-calculator .pxd-intro {
    grid-column: 1;
    grid-row: 1;
    margin: 0;
    justify-self: stretch;
    width: 100%;
    min-height: clamp(22rem, 68vw, 33rem);
    padding: .85rem .5rem 6.1rem;
    text-align: right;
  }
  #pxd-regular-calculator .pxd-brand { width: 10.4rem; margin-inline-start: auto; }
  #pxd-regular-calculator .pxd-intro h2 { font-size: clamp(2.15rem, 9.5cqw, 4.75rem); text-align: right; }
  #pxd-regular-calculator .pxd-description { max-width: 15rem; font-size: 1.125rem; }
  #pxd-regular-calculator .pxd-description::before { margin: .76rem 0 .56rem auto; width: 62%; height: 4px; }
  #pxd-regular-calculator .pxd-panel {
    grid-column: 1;
    grid-row: 2;
    width: min(100%, 38rem);
    justify-self: center;
  }
}

@media (max-width: 420px) {
  #pxd-regular-calculator .pxd-location { grid-template-columns: minmax(0, 1fr); gap: .37rem; }
  #pxd-regular-calculator .pxd-head { margin-block-end: 1rem; }
  #pxd-regular-calculator .pxd-panel { padding-inline: .83rem; }
  #pxd-regular-calculator .pxd-results { padding: .64rem; }
  #pxd-regular-calculator .pxd-stat { padding-inline: .35rem; }
}

@media (prefers-reduced-motion: reduce) {
  #pxd-regular-calculator *, #pxd-regular-calculator *::before, #pxd-regular-calculator *::after {
    animation: none !important;
    transition: none !important;
  }
}
