:root {
    color-scheme: light;
    --navy: #1c3f79;
    --blue: #4682b4;
    --charcoal: #404040;
    --ink: #fff;
    --serif: Georgia, 'Times New Roman', serif;
    --sans: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --ease-out: cubic-bezier(.22, .61, .36, 1);
}

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

html { background: var(--navy); }
body { margin: 0; color: var(--ink); font-family: var(--serif); }
img { display: block; max-width: 100%; }
h1, h2, p, figure { margin: 0; }
a { color: inherit; }
button { font: inherit; }

:focus-visible {
    outline: 3px solid #ffd56a;
    outline-offset: 4px;
}

.skip-link {
    position: absolute;
    z-index: 3;
    top: .5rem;
    left: .5rem;
    padding: .65rem .85rem;
    transform: translateY(calc(-100% - .6rem));
    background: var(--navy);
    font: 600 1rem var(--sans);
}

.skip-link:focus { transform: none; }

.masthead {
    position: absolute;
    z-index: 2;
    inset: 0 0 auto;
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    min-height: clamp(3.75rem, 7vw, 5.75rem);
    padding: .45rem clamp(1rem, 4.25vw, 4.5rem);
    background: rgb(255 249 224 / .35);
    backdrop-filter: blur(4px);
}

.languages { display: flex; align-items: center; gap: .2rem; }

.language-link {
    display: grid;
    width: 2.75rem;
    height: 2.75rem;
    place-items: center;
    border: 1px solid transparent;
    border-radius: 7px;
    transition: background-color .22s ease, border-color .22s ease;
}

.language-link:hover { background: rgb(255 255 255 / .4); }
.language-link[aria-current] { background: rgb(255 255 255 / .64); border-color: rgb(28 63 121 / .27); }
.language-link:focus-visible { outline-color: var(--navy); }

.flag {
    position: relative;
    display: block;
    width: 24px;
    height: 16px;
    overflow: hidden;
    border-radius: 1px;
    box-shadow: 0 0 0 1px rgb(0 0 0 / .15);
}

.flag--en { background: repeating-linear-gradient(#b22234 0 calc(100% / 13), #fff calc(100% / 13) calc(200% / 13)); }
.flag--en::before {
    content: '';
    position: absolute;
    inset: 0 auto auto 0;
    width: 40%;
    height: calc(700% / 13);
    background: radial-gradient(circle, #fff .3px, transparent .55px) 0 0 / 1.6px 1.4px, #3c3b6e;
}
.flag--es { background: linear-gradient(#aa151b 25%, #f1bf00 25% 75%, #aa151b 75%); }
.flag--es::before {
    content: '';
    position: absolute;
    top: 36%;
    left: 27%;
    width: 14%;
    height: 27%;
    border-radius: 1px 1px 2px 2px;
    background: #a9201b;
    border: 1px solid #c26328;
}
.flag--fr { background: linear-gradient(90deg, #002395 33.333%, #fff 33.333% 66.666%, #ed2939 66.666%); }
.flag--it { background: linear-gradient(90deg, #009246 33.333%, #fff 33.333% 66.666%, #ce2b37 66.666%); }

.hero {
    position: relative;
    display: grid;
    place-items: center;
    min-height: clamp(36rem, 52vw, 48rem);
    overflow: clip;
    isolation: isolate;
    padding: 6rem 1.25rem;
    background: #102d5b;
}

.hero-art, .hero-backgrounds, .hero-products {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.hero-art { z-index: -1; }

.hero-backgrounds::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, #102d5b 0%, rgb(16 45 91 / .96) 24%, rgb(16 45 91 / .65) 54%, transparent 90%);
}

.hero-background {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-background--pineapple { opacity: 1; }
.hero-background--banana { opacity: 0; animation: hero-crossfade 22s ease-in-out infinite; }

.hero-product {
    position: absolute;
    bottom: 1.5rem;
    width: min(28vw, 28rem);
    height: calc(100% - 8rem);
}

.hero-fruit {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center bottom;
}

.hero-product--pineapple { left: clamp(1.25rem, 4.5vw, 6rem); }
.hero-product--banana { right: clamp(1.25rem, 4.5vw, 6rem); }
.hero.is-loading .hero-products { visibility: hidden; }

.hero.is-ready .hero-product--pineapple {
    animation: pineapple-enter 1.6s var(--ease-out) .12s both;
}

.hero.is-ready .hero-product--banana {
    animation: banana-enter 1.6s var(--ease-out) .28s both;
}

.hero.is-ready .hero-product--pineapple .hero-fruit {
    animation: pineapple-float 8s ease-in-out 1.72s infinite both;
}

.hero.is-ready .hero-product--banana .hero-fruit {
    animation: banana-float 9.5s ease-in-out 1.88s infinite both;
}

.hero.is-paused .hero-background,
.hero.is-paused .hero-product,
.hero.is-paused .hero-product .hero-fruit { animation-play-state: paused; }

@keyframes pineapple-enter {
    from { transform: translateX(calc(-100% - 12vw)); }
    to { transform: translateX(0); }
}

@keyframes banana-enter {
    from { transform: translateX(calc(100% + 12vw)); }
    to { transform: translateX(0); }
}

@keyframes hero-crossfade {
    0%, 35%, 100% { opacity: 0; }
    45%, 85% { opacity: 1; }
}

@keyframes pineapple-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-16px); }
}

@keyframes banana-float {
    0%, 100% { transform: translateY(-10px); }
    50% { transform: translateY(6px); }
}

.hero-inner { width: min(46%, 45rem); }

.hero-title {
    width: fit-content;
    max-width: 100%;
    margin-inline: auto;
    font-size: clamp(1.85rem, 3.55vw, 3.45rem);
    font-weight: 400;
    line-height: 1.18;
    text-align: center;
    text-wrap: balance;
    animation: reveal .9s var(--ease-out) both;
}

.hero-title span {
    padding: .07em .2em .12em;
    background: var(--navy);
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
}

.hero-motion-toggle {
    position: absolute;
    right: 1.25rem;
    bottom: 1.25rem;
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 1px solid rgb(255 255 255 / .6);
    border-radius: 50%;
    background: rgb(16 45 91 / .88);
    color: white;
    cursor: pointer;
}

.hero-motion-toggle[hidden] { display: none; }
.hero-motion-toggle:hover { background: var(--navy); }

.hero-motion-icon {
    display: block;
    width: .75rem;
    height: .875rem;
    border-inline: 3px solid currentColor;
}

.hero-motion-toggle[data-paused='true'] .hero-motion-icon {
    width: .875rem;
    height: 1rem;
    border: 0;
    background: currentColor;
    clip-path: polygon(15% 0, 100% 50%, 15% 100%);
}

.text-band {
    display: grid;
    place-items: center;
    min-height: clamp(20rem, 32.8vw, 29rem);
    padding: clamp(3.75rem, 7vw, 7.25rem) 1.5rem;
    background: var(--navy);
    text-align: center;
}

.text-band-inner { width: min(100%, 46rem); }

.section-title {
    font-size: clamp(1.6rem, 2.8vw, 2.4rem);
    line-height: 1.15;
    font-weight: 400;
    text-wrap: balance;
}

.section-title::after {
    content: '';
    display: block;
    width: min(72%, 25rem);
    height: 1px;
    margin: .65em auto 0;
    background: rgb(255 255 255 / .86);
}

.text-band p {
    max-width: 35rem;
    margin: clamp(1.35rem, 3vw, 2.4rem) auto 0;
    font-size: clamp(1.02rem, 1.5vw, 1.22rem);
    line-height: 1.72;
    text-wrap: pretty;
}

.gallery-band { padding: clamp(1.75rem, 3.3vw, 3.5rem) clamp(1rem, 3vw, 4rem); background: var(--blue); }

.gallery {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(.75rem, 1.5vw, 1.5rem);
    max-width: 96rem;
    padding: 0;
    margin: 0 auto;
    list-style: none;
}

.gallery-link {
    display: block;
    aspect-ratio: 4 / 5;
    overflow: clip;
    background: #2f6287;
    border-radius: 12px;
    box-shadow: 0 8px 22px rgb(10 31 52 / .2);
    transition: transform .4s var(--ease-out), box-shadow .4s var(--ease-out);
}

.gallery img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .5s var(--ease-out);
}

.gallery-link:focus-visible { box-shadow: 0 10px 24px rgb(10 31 52 / .35); }

@media (hover: hover) and (pointer: fine) {
    .gallery-link:hover { transform: translateY(-5px); box-shadow: 0 12px 26px rgb(10 31 52 / .35); }
    .gallery-link:hover img { transform: scale(1.06); }
}

.logistics { min-height: clamp(19rem, 29vw, 27rem); }
.logistics .section-title::after { width: clamp(5.25rem, 17%, 7rem); }

.footer {
    display: grid;
    justify-items: center;
    padding: clamp(1.6rem, 3vw, 2.65rem) 1.25rem;
    background: var(--charcoal);
    font-family: var(--sans);
}

.footer-inner { max-width: 100%; }
.footer h2 { margin-block-end: .75rem; font-size: 1.125rem; text-align: center; }
.footer address { font-style: normal; }

.contact-list {
    display: grid;
    gap: .4rem;
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: .875rem;
    line-height: 1.4;
}

.contact-list li { display: flex; align-items: center; gap: .6rem; }
.contact-list a { display: inline-block; min-width: 0; padding: .25rem 0; overflow-wrap: anywhere; text-underline-offset: .2em; }
.contact-list a:hover { color: #ffe3a0; }

.contact-icon {
    position: relative;
    display: grid;
    place-items: center;
    flex: 0 0 1.15rem;
    height: 1.15rem;
    border-radius: 50%;
    background: white;
    color: var(--charcoal);
    font-size: .72rem;
    line-height: 1;
}

.contact-icon--location::before {
    content: '';
    width: .48rem;
    height: .48rem;
    border: 1.5px solid currentColor;
    border-radius: 50% 50% 50% 0;
    transform: translateY(-1px) rotate(-45deg);
}

.lightbox {
    position: fixed;
    max-width: min(calc(100% - 1.5rem), 68rem);
    max-height: calc(100% - 1.5rem);
    overflow: auto;
    margin: auto;
    padding: .75rem;
    border: 0;
    border-radius: 14px;
    background: #101b2c;
    color: white;
    box-shadow: 0 24px 85px #0008;
}

.lightbox[open] { animation: reveal .3s var(--ease-out) both; }
.lightbox::backdrop { background: #081222dd; backdrop-filter: blur(7px); }
.lightbox-media { margin: 0; }
.lightbox-image { width: min(85vw, 64rem); height: min(68vh, 42rem); object-fit: contain; }
.lightbox-caption { padding: .65rem 3rem .3rem; text-align: center; font: 500 .875rem var(--sans); }

.lightbox-button {
    position: absolute;
    display: grid;
    place-items: center;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 1px solid #fff5;
    border-radius: 50%;
    background: #101b2ce8;
    color: white;
    font: 1.6rem/1 var(--sans);
    cursor: pointer;
}

.lightbox-button:hover { background: var(--navy); }
.lightbox-close { top: .75rem; right: .75rem; }
.lightbox-prev, .lightbox-next { top: 50%; translate: 0 -50%; }
.lightbox-prev { left: .75rem; }
.lightbox-next { right: .75rem; }
html:has(.lightbox[open]) { overflow: hidden; }

.revealed { animation: reveal .75s var(--ease-out) both; }

@keyframes reveal {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 52rem) {
    .hero { min-height: 42rem; padding: 7.5rem 1rem 28rem; }
    .hero-inner { width: 100%; }
    .hero-backgrounds::after { background: radial-gradient(ellipse at 50% 60%, #102d5b 0%, rgb(16 45 91 / .9) 38%, transparent 100%); }
    .hero-product { width: 62%; height: 65%; bottom: 1.5rem; }
    .hero-product--pineapple { left: -5%; }
    .hero-product--banana { right: -5%; }
    .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .hero-product, .hero-fruit { transform: none; }
    .hero.is-loading .hero-products { visibility: visible; }
    .hero-background--banana { opacity: 0; }
    .hero-motion-toggle { display: none; }
    .gallery-link:hover, .gallery-link:hover img { transform: none; }
}
