.page {
}

.page-error {
    height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.page-error-text {
    margin-bottom: 2rem;
    font-size: var(--text-btn1);
    text-transform: uppercase;
}

.page-error-bg {
    position: absolute;
    bottom: 0;
    z-index: -1;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.page-error-bg-text {
    font-size: 25vw;
    color: var(--color-green);
    text-align: center;
    translate: 0 2%;
}

.page-error-bg-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(9, 43, 57, 0.75), rgba(9, 43, 57, 0));
}

@media screen and (min-width: 768px) {
    .page-error-bg{
        inset: 0;
    }

    .page-error-bg-text {
        font-size: 90vw;
    }
}

/* Hero */
.hero {
    
}

.hero-media {
    grid-column: 1/-1;
    height: 100dvh;
    width: 100%;
    object-fit: cover;
    filter: brightness(0.8);
    clip-path: inset(0);
    transition: clip-path 1.2s ease;
}

.hero-media--mobile {
    display: block;
}

.hero-media--desktop {
    display: none;
}

body.hero-shrunk .hero-media {
    clip-path: inset(0 1.5rem);
}

@media screen and (min-width: 768px) {
    .hero-media--mobile {
        display: none;
    }

    .hero-media--desktop {
        display: block;
    }

    body.hero-shrunk .hero-media {
        clip-path: inset(0 2rem);
    }
}

.hero-copy {
    position: absolute;
    left: 1.5rem;
    top: 50%;
    max-width: calc(100% - 3rem);
    translate: 0 -50%;
    transition: 1.2s ease;
}

body.hero-shrunk .hero-copy {
    left: 3rem;
}

.hero-headline {
    font-size: var(--text-h1);
    letter-spacing: -1%;
}

@media screen and (min-width: 768px) {
    .hero-copy {
        left: 2rem;
        max-width: calc(100% - 4rem);
    }

    body.hero-shrunk .hero-copy {
        left: 4rem;
    }
}

/* Section: Science */
.science {
    padding: 6rem 0 3rem;
    scroll-margin-top: 4rem;
}

.science-copy {
    padding: 1.5rem;
    margin-bottom: 4rem;
}

.science-headline {
    margin-bottom: 6rem;
    font-size: var(--text-h2);
}

.science-body {
    padding: 1.5rem;
    font-size: var(--text-p1);
    margin-bottom: 3.5rem;
    line-height: 140%;
}

.science-patents {
    margin: 0;
    padding: 0;
    display: flex;
    list-style-type: none;
    flex-wrap: wrap;
    gap: 1rem;
}

/* Mobile: horizontal scroll strip with snap-align */
.science-gallery-pin {
    grid-column: 1/-1;
    width: 100%;
}

.science-gallery {
    display: flex;
    width: 100%;
    gap: 2rem;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-right: 2rem;
}

.science-gallery::-webkit-scrollbar {
    display: none;
}

.science-gallery-picture {
    flex: 0 0 90vw;
    scroll-snap-align: start;
    height: 50vh;
}

.science-gallery-picture-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.science-gallery-controls {
    display: none;
}

@media screen and (min-width: 768px) {
    .science {
        padding: 0;
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .science-copy {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        padding: 12rem 2rem;
        margin-bottom: 0;
    }

    .science-body {
        padding: 12rem 2rem;
        margin-bottom: 0;
    }

    .science-headline {
        margin-bottom: 2rem;
    }

    .science-gallery-pin {
        position: relative;
    }

    .science-gallery {
        position: relative;
        display: block;
        width: 100vw;
        max-width: 100vw;
        height: 100vh;
        overflow: hidden;
        scroll-snap-type: none;
    }

    .science-gallery-picture {
        position: absolute;
        flex: initial;
        scroll-snap-align: none;
        top: 33.33vh;
        left: 100%;
        width: 100vw;
        height: 100%;
        transform: translateX(100%);
        transition: 1.2s cubic-bezier(0.54, 0.02, 0.48, 0.99);
    }

    .science-gallery-picture.is-active {
        top: 0;
        left: 0;
        transform: translateX(0);
    }

    .science-gallery-picture.is-prev {
        top: 0;
        left: -100%;
        transform: translateX(0);
    }

    /* Peek mode: active fills 75vw on the left, next slide peeks on the right */
    .science-gallery.has-peek .science-gallery-picture.is-active {
        width: calc(75vw - 1rem);
        top: 0;
        left: 0;
    }

    .science-gallery.has-peek .science-gallery-picture.is-peek {
        transform: translateX(0);
        top: 33.33vh;
        left: calc(75vw + 1rem);
        width: calc(75vw - 1rem);
        height: 100vh;
    }

    .science-gallery-controls {
        position: absolute;
        z-index: 2;
        bottom: calc(66.66vh + 2rem);
        right: 2rem;
        display: flex;
        gap: 2rem;
        align-items: center;
        opacity: 0;
        pointer-events: none;
        transform: translateX(calc(100% + 2rem));
        transition: opacity 0.4s ease, transform 0.6s ease;
    }

    .science-gallery.has-peek .science-gallery-controls {
        opacity: 1;
        pointer-events: auto;
        transform: translateX(0);
        transition: opacity 0.4s ease, transform 0.6s ease 1s;
    }
}

/* Section: Products */
.products {
    scroll-margin-top: 8rem;
    
}

.products-intro {
    text-align: center;
    padding: 1.5rem;
    margin: 4rem auto 2rem;
    max-width: 1024px;
    font-size: var(--text-p1);
    line-height: 130%;
    text-align: left;
}

.products-pin {
    position: relative;
    width: 100%;
    margin-bottom: 5rem;
}

.products-track {
    position: sticky;
    top: 0;
    width: 100vw;
    height: 100dvh;
    overflow: hidden;
    margin-bottom: 4rem;
}

.products-list {
    display: flex;
    width: max-content;
    height: 100%;
    --list-x: 0vw;
    transform: translateX(var(--list-x));
    transition: transform 700ms cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}


/* Mobile: step 0 = P1 no title, step 1 = P1 with title, step 2-8 = P2..P8 */
.products-list[data-step="0"],
.products-list[data-step="1"] { --list-x: 0vw; }
.products-list[data-step="2"] { --list-x: -100vw; }
.products-list[data-step="3"] { --list-x: -200vw; }
.products-list[data-step="4"] { --list-x: -300vw; }
.products-list[data-step="5"] { --list-x: -400vw; }
.products-list[data-step="6"] { --list-x: -500vw; }
.products-list[data-step="7"] { --list-x: -600vw; }
.products-list[data-step="8"] { --list-x: -700vw; }

@media screen and (min-width: 768px) {
    .products {
        scroll-margin-top: 6rem;
    }

    /* Desktop: P1 hero at step 0/1 (100vw), sliding window of 3 at step 2-7 (each 33vw), one extra slide at step 8 to center P8 */
    .products-list[data-step="0"],
    .products-list[data-step="1"] { --list-x: 0vw; }
    .products-list[data-step="2"] { --list-x: 0vw; }
    .products-list[data-step="3"] { --list-x: calc(-100vw / 3); }
    .products-list[data-step="4"] { --list-x: calc(-200vw / 3); }
    .products-list[data-step="5"] { --list-x: calc(-300vw / 3); }
    .products-list[data-step="6"] { --list-x: calc(-400vw / 3); }
    .products-list[data-step="7"] { --list-x: calc(-500vw / 3); }
    .products-list[data-step="8"] { --list-x: calc(-600vw / 3); }

    .products-intro {
        font-size: var(--text-h3);
        text-align: center;
        padding: 1rem;
        margin: 12rem auto 6rem;
    }

    .products-pin {
        margin-bottom: 25vh;
    }
}

/* Product */
.product {
    position: relative;
    min-width: 100vw;
    width: 100vw;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-bottom: 3rem;
    flex-shrink: 0;
}

.product.last {
    display: none;
}

@media screen and (min-width: 768px) {
    .product {
        min-width: calc(100vw / 3);
        width: calc(100vw / 3);
        transition: width 700ms cubic-bezier(0.4, 0, 0.2, 1),
                    min-width 700ms cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Hero: first product fills viewport at step 0/1 */
    .products-list[data-step="0"] .product:first-child,
    .products-list[data-step="1"] .product:first-child {
        min-width: 100vw;
        width: 100vw;
    }
}

.product-cover {
    position: relative;
    height: 70vh;
    width: 100%;
    overflow: hidden;
    flex-grow: 1;
}

.product-image {
    transform: translateX(2rem);
    transition:
        transform 600ms ease-out var(--reveal-delay, 0ms),
        opacity 900ms ease var(--reveal-delay, 0ms);
}

.product-image.is-revealed {
    transform: translateX(0);
}

.product-packaging {
    --reveal-delay: 200ms;
}

.product-image {
    position: absolute;
    top: 50%;
    left: 50%;
    translate: -50% -50%;
    z-index: 1;
    height: 52.5vh;
    width: auto;
}

.product.two-images .product-image {
    translate: -25% -40%;
    /* filter: drop-shadow(0px 0px 24px rgba(0, 0, 0, 0.25)); */
}

.product-packaging {
    position: absolute;
    top: 50%;
    left: 50%;
    translate: -50% -50%;
    height: 65vh;
    scale: 1;
    width: auto;
}

.product.two-images .product-packaging {
    translate: -75% -50%;
}

.product-packaging.landscape {
    width: 100%;
    height: auto;
}

.product-image-img,
.product-packaging-img {
    width: 80%;
    height: 100%;
    object-fit: contain;
    margin: auto;
}

.product-title {
    text-align: center;
    font-size: var(--text-p2);
    text-transform: uppercase;
    opacity: 0;
    transition: 300ms ease;
    padding: 0 2rem;
    text-wrap: balance;
}

.product-line {
    width: 1px;
    height: 1rem;
    background-color: var(--color-green);
    position: absolute;
    bottom: 0;
    left: 50%;
    opacity: 0;
    transition: 300ms ease;
}

/* Title hidden at step 0, visible from step 1+ on both breakpoints */
.products-list[data-step]:not([data-step="0"]) .product-line,
.products-list[data-step]:not([data-step="0"]) .product-title {
    opacity: 1;
    transition: opacity 300ms ease 200ms;
}


@media screen and (min-width:768px) {
    .product-image-img,
    .product-packaging-img {
        width: 90%;
        height: 100%;
        object-fit: contain;
        margin: auto;
    }
}


/* Section: About */
.about {
    position: relative;
    height: 300svh;
    margin-bottom: 3.5rem;
    background-color: var(--color-blue);
    scroll-margin-top: 6rem;
}

.about-pin {
    position: sticky;
    top: 0;
    height: 100dvh;
    overflow: hidden;
}

.about-block {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    transition: transform 0.8s cubic-bezier(0.65, 0, 0.35, 1);
    will-change: transform;
}

.about-block--1 {
    justify-content: flex-end;
}

.about-block--2 {
    justify-content: flex-start;
    transform: translateY(100%);
}

.about.is-half .about-block--1 {
    transform: translateY(-100%);
}

.about.is-half .about-block--2 {
    transform: translateY(0);
}

.about-headline {
    padding: 1.5rem;
    font-size: var(--text-h2);
    margin: 3rem 0;
    flex: 0 0 auto;
}

.about-text {
    padding: 1.5rem;
    font-size: var(--text-p1);
    line-height: 140%;
    flex: 0 0 auto;
}

.about-image-wrap {
    flex: 0 0 auto;
    width: 100%;
    aspect-ratio: 1/1;
    overflow: hidden;
}

.about-block--2 .about-image-wrap {
    order: -1;
}

.about-image,
.about-image-wrap > picture,
.about-image-wrap > picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

@media screen and (min-width: 768px) {
    .about {
        position: relative;
        height: 300svh;
        scroll-margin-top: 0;
    }

    .about-pin {
        position: sticky;
        top: 0;
        height: 100svh;
        overflow: hidden;
        display: grid;
        grid-template-columns: 50vw 50vw;
        grid-template-rows: 100svh;
    }

    .about-block {
        display: contents;
    }

    .about-headline,
    .about-text {
        grid-column: 1;
        grid-row: 1;
        align-self: center;
        padding: 4rem 2rem;
        margin: 0;
        transition: 0.6s cubic-bezier(0.65, 0, 0.35, 1);
    }

    .about-headline {
        opacity: 1;
        translate: 0 0;
    }

    .about-text {
        translate: 0 25%;
        opacity: 0;
        padding-right: 132px;
    }

    .about.is-half .about-headline {
        opacity: 0;
        translate: 0 -25%;
    }

    .about.is-half .about-text {
        opacity: 1;
        translate: 0 0;
        transition: 0.6s 0.6s cubic-bezier(0.65, 0, 0.35, 1);
    }

    .about-image-wrap {
        position: absolute;
        top: 0;
        right: 0;
        width: 50vw;
        height: 100svh;
        flex: initial;
        aspect-ratio: auto;
        overflow: hidden;
        transition: transform 1.2s cubic-bezier(0.65, 0, 0.35, 1);
    }

    .about-image-wrap--2 {
        transform: translateY(100%);
    }

    .about.is-half .about-image-wrap--1 {
        transform: translateY(-100%);
    }

    .about.is-half .about-image-wrap--2 {
        transform: translateY(0);
    }

    .about-image,
    .about-image-wrap > picture,
    .about-image-wrap > picture img {
        height: 100%;
        width: 100%;
        object-fit: cover;
        aspect-ratio: unset;
    }
}

/* Section: Contact */
.contact {
    position: relative;
    padding: 8rem 1.5rem 4rem;
    transition: 0.6s;
    /* overflow: hidden; */
}

.contact-title,
.contact-form {
    transition: opacity 0.4s ease;
}

.contact-success {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    translate: 0 -50%;
    text-align: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.contact.is-success .contact-title,
.contact.is-success .contact-form {
    opacity: 0;
    pointer-events: none;
}

.contact.is-success .contact-success {
    opacity: 1;
    pointer-events: auto;
}

.contact-title {
    font-size: var(--text-h2);
    z-index: 1;
}

.contact-form {
    z-index: 1;
}

.contact-form label {
    display: block;
    margin: 3rem 0;
    width: 100%;
    position: relative;
}

.contact-form label span {
    display: block;
    width: 100%;
    position: absolute;
    bottom: 50%;
    opacity: 0.5;
    transition: 300ms;
    font-size: var(--text-p1);
}

.contact-form label.is-focused span,
.contact-form label.has-value span {
    bottom: calc(100% + 0.5rem);
    opacity: 1;
}

.contact-form input {
    display: block;
    width: 100%;
    background: transparent;
    border: 0;
    border-bottom: 1px solid white;
    padding: 0.25rem 0;
    font-size: var(--text-p1);
    color: white;
    transition: border-color 200ms ease;
}

.contact-form input.error {
    border-bottom-color: #ff4d4d;
}

.contact-error {
    position: absolute;
    top: calc(100% + 0.25rem);
    left: 0;
    margin: 0;
    font-size: var(--text-btn1);
    color: #ff4d4d;
    opacity: 0;
    pointer-events: none;
    transition: opacity 200ms ease;
}

.contact-form label:has(input.error) .contact-error {
    opacity: 1;
}

.contact-form label.contact-consent {
    margin: 0 0 1.5rem;
}

.contact-consent-inner {
    display: flex;
    gap: 0.75rem;
    font-size: var(--text-btn1);
    line-height: 1.4;
    opacity: 0.85;
}

.contact-consent-inner input[type="checkbox"] {
    flex: 0 0 auto;
    width: 1rem;
    height: 1rem;
    margin: 0;
    accent-color: var(--color-green);
    cursor: pointer;
}

.contact-consent-inner a {
    color: inherit;
    text-decoration: underline;
}

.contact-consent-inner div {
    opacity: 0.5;
}

.contact-consent .contact-error {
    position: static;
    margin-top: 0.5rem;
}

@media screen and (min-width: 768px) {
    .contact {
        display: grid;
        grid-template-columns: repeat(8, 1fr);
        grid-template-rows: 1fr 4fr;
        padding: 16rem 1rem 8rem;
    }

    .contact-title,
    .contact-alert {
        grid-column: 3/-3;
    }

    .contact-success-icon {
        width: 4rem;
        height: 4rem;
        margin: 0 auto 2rem;
    }

    .contact-success-message {
        font-size: var(--text-h2);
    }

    .contact-title {
        text-align: center;
    }

    .contact-form {
        grid-column: 4/-4;
    }
}

/* Page: Default */

.page-default {
    min-height: 100svh;
    padding: 8rem 0;
}

.page-default-title {
    text-align: center;
    padding: 1.5rem;
}

.page-default-content {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
}

.block-text {
    padding: 1.5rem;
    grid-column: 1/-1;
    font-size: var(--text-p1);
    line-height: 1.4;
}

.block-text p {
    margin-bottom: 1em;
}

.block-text ul,
.block-text ol {
    list-style: none;
    padding-inline-start: 0;
    margin-block-start: 1em;
    margin-block-end: 1em;
}

.block-text ul li,
.block-text ol li {
    position: relative;
    padding-left: 2.5rem;
    margin-bottom: 0.5em;
}

.block-text ul li::before {
    content: "·";
    position: absolute;
    left: 0.5rem;
    top: 0;
}

.block-text ol {
    counter-reset: block-text-list;
}

.block-text ol li {
    counter-increment: block-text-list;
}

.block-text ol li::before {
    content: counter(block-text-list) ".";
    position: absolute;
    left: 0.5rem;
    top: 0;
}

.block-heading {
    padding: 0 1.5rem;
    margin: 3rem 0;
    grid-column: 1/-1;
    font-size: var(--text-h3);
    font-weight: 400;
}

.block-heading strong {
    font-weight: 400;
}

.block-table {
    grid-column: 1/-1;
    margin: 3rem 0;
    padding: 1.5rem 0;
}

.block-table-scroll {
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: 0 1.5rem;
}

.block-table-scroll::-webkit-scrollbar {
    display: none;
}

.block-table-slider {
    display: block;
    width: calc(100% - 3rem);
    margin: 1rem 1.5rem 2rem;
    appearance: none;
    -webkit-appearance: none;
    height: 2px;
    background: linear-gradient(to right, var(--color-green) var(--slider-value, 0%), rgba(255, 255, 255, 0.2) var(--slider-value, 0%));
    cursor: pointer;
    
}

.block-table-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 2rem;
    height: 0.75rem;
    background: white;
    border: 0;
    border-radius: 0;
}

.block-table-slider::-moz-range-thumb {
    width: 2rem;
    height: 0.75rem;
    background: white;
    border: 0;
    border-radius: 0;
}

@media screen and (max-width: 47.99rem) {
    .block-table .table th,
    .block-table .table td {
        min-width: 50vw;
    }
}

@media screen and (min-width: 48rem) {
    .block-table-slider {
        display: none;
    }
}

@media screen and (min-width: 768px) {
    .block-text {
        grid-column: 2/-2;
        padding: 0;
    }

    .block-heading {
        grid-column: 2/-2;
        text-align: center;
        padding: 0;
    }

    .block-table {
        grid-column: 1/-1;
    }
}

@media screen and (min-width: 1024px) {
    .block-text {
        grid-column: 3/-3;
    }
    
    .block-heading {
        grid-column: 3/-3;
    }

    .block-table {
        grid-column: 2/-2;
        padding: 0;
    }
}


/* 
    Components 
*/

/* Components: Tag */
.tag {
    background-color: var(--color-green);
    padding: 0.25rem 0.5rem;
    color: black;
}

/* Components: Button */
.button {
    padding: 0.75rem;
    position: relative;
    text-transform: uppercase;
    color: var(--color-green);
    font-size: var(--text-btn1);
    text-decoration: none;
    transition: 0.3s;
}

.button.disabled,
.button:disabled {
    opacity: 0.5;
    pointer-events: none;
    cursor: not-allowed;
}

.button::before,
.button::after {
    content: "";
    position: absolute;
    width: 12px;
    height: 12px;
    transition: width 300ms ease;
}

.button::before {
    top: 0;
    right: 0;
    border-top: 1px solid var(--color-green);
    border-right: 1px solid var(--color-green);
}

.button::after {
    bottom: 0;
    left: 0;
    border-bottom: 1px solid var(--color-green);
    border-left: 1px solid var(--color-green);
}

@media (hover: hover) {
    .button:hover::before,
    .button:hover::after {
        width: calc(100% - 12px);
    }
}

/* Components: Table */
.table {
    width: 100%;
    border-collapse: collapse;
}

.table tr {
    width: 100%;
}


.table td,
.table th {
    padding: 1.5rem 0;
    border-bottom: 1px solid white;
    vertical-align: top;
    text-align: left;
}

.table td {
    padding: 1.5rem 1rem 1.5rem 0;
}

@media screen and (min-width: 768px) {
    .table th {
        text-align: center;
        padding: 1.5rem;
    }
}