/****** RESET ******/

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

body,
h1,
h2,
h3,
h4,
h5,
h6,
p,
blockquote,
pre,
ul,
ol,
li,
figure,
figcaption,
hr {
    margin: 0;
    padding: 0;
}

ul,
ol {
    list-style: none;
}

/****** VARIABLES ******/

:root {
    /** COLORS **/
    --light-cream: #FFF8DE;
    --secondary-cream: #FFF2C6;
    --light-blue: #87adf3;

    /** BURGER MENU **/
    --burger-anim-duration: 0.3s;
}

/****** GENERAL STYLE ******/

html {
    scroll-behavior: smooth;
}

a {
    text-decoration: none;
    transition: 0.3s;
}

h1,
h2 {
    font-size: clamp(2rem, 5vw + 1rem, 2.5rem);
}

h2 {
    color: var(--light-blue);
    text-align: center;
    font-family: 'Brygada 1918', serif;
}

img {
    width: 100%;
    height: auto;
    display: block;
}

a,
button,
#burger-container,
.nav-links li a {
    -webkit-tap-highlight-color: transparent;
}

/****** LAYOUT ******/

body {
    background-color: var(--light-cream);
    font-family: 'PT Serif', serif;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.menu-open {
    overflow: hidden;
}

header,
#hero,
#products,
#product-content,
#aboutUsWrapper,
#contact,
footer {
    padding-inline: 1.5rem;
}

header>div,
footer {
    padding-block: 1rem;
}

header,
footer {
    background-color: var(--secondary-cream);
}

header {
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-evenly;
    align-content: center;
    box-shadow: rgba(99, 99, 99, 0.2) 0px 2px 8px 0px;
}

header,
.nav-links {
    gap: 2.5rem;
}

nav {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
}

nav a {
    color: var(--light-blue);
}

#title {
    width: 12.5rem;
    height: auto;
    /* To keep proportions */
    display: block;
    /* To avoid space below the image */
}

.nav-links {
    display: flex;
    font-size: 1.2rem;
    padding-top: 0.3125rem;
    align-items: center;
}

#burger-container {
    display: none;
}

#socialMediaHeader {
    display: flex;
    gap: 1.5rem;
    width: 8rem;
}

main {
    display: flex;
    flex-direction: column;
    flex: 1;
}

section, #socialMediaFooter {
    scroll-margin-top: 5rem;
}

#hero,
#products,
#product-content,
#aboutUs,
#contact {
    padding-block: 2rem;
}

#socialMediaFooter div {
    display: flex;
    justify-content: center;
    gap: 2rem;
}

footer {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

footer section {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem 3rem;
}

/****** COMPONENTS ******/

.product-cards {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.product-cards img {
    box-shadow: rgba(0, 0, 0, 0.24) 0px 3px 8px;
    /* #5 */
    transition: 0.1s;
}

/*.product-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.product-info h3 {
    flex-grow: 1;
}

.product-info p {
    font-size: 1.7rem;
}*/

.product-info {
    flex-basis: 100%;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
    justify-items: center;
    text-align: center;
    gap: 0.5rem;
}

.product-info > * {
    justify-self: stretch;
}

.product-info h3 {
    font-size: 1.5rem;
    grid-column: 1 / 2;
}

.product-price {
    grid-column: 2 / 3;
    font-size: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.product-delivery {
    color: #00000077;
    font-size: 0.9rem;
}

.product-description,
.product-buttons {
    grid-column: 1 / 3;
}

.product-description {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.product-description p {
    font-style: italic;
    color: var(--light-blue);
}

.product-buttons {
    align-self: end;
    min-width: 13rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.buttons {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    padding: 0.2rem 0;
    text-align: center;
    border: 1px solid var(--light-blue);
}

.detalles {
    color: var(--light-blue);
    border: 1px solid var(--light-blue);
}

.loquiero {
    color: var(--light-cream);
    background-color: var(--light-blue);
}

#tiktokWarning {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 242, 198, 0.9);
    z-index: 1000;
    overflow-y: auto;

    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    padding: 1rem;
    text-align: center;
}

#tiktokWarning > img {
    width: 90%;
}

#tiktokWarning div {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    font-size: 1.2rem;
}

.dismissTiktokWarning {
    border: none;
    background-color: transparent;
    color: var(--light-blue);
    font-style: italic;
    text-decoration: underline;
}

/****** COOKIE ******/

.klaro .cookie-notice:not(.cookie-modal-notice) {
    background-color: rgba(255, 242, 198, 0.9) !important;
    box-shadow: 0 4px 6px 0 rgba(0, 0, 0, 0.2), 5px 5px 10px 0 rgba(0, 0, 0, 0.19) !important;
}

.klaro .cookie-notice p {
    color: var(--light-blue) !important;
}

.klaro .cookie-notice a {
    color: #555 !important;
}

.klaro .cookie-notice .cm-btn.cm-btn-success {
    background-color: var(--light-blue) !important;
}

/****** SPECIFIC: INDEX.HTML ******/

#hero {
    background-image: linear-gradient(to bottom, rgba(255, 242, 198, 0.7), rgba(254, 247, 221, 1)), url('images/hero.png');
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    height: 600px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    gap: 2rem;
}

#hero h2 {
    font-size: clamp(1.8rem, 3.8vw + 1rem, 5rem);
}

#hero div {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

#hero p {
    font-style: italic;
    font-size: 1.2rem;
    color: var(--light-blue);
}

#products {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.7rem;
}

#aboutUsWrapper {
    background-color: white;
    padding-block: 5rem;
}

#aboutUs {
    display: grid;
    grid-template-columns: 2fr 1fr;
    align-items: center;
    gap: 2rem;
    max-width: 80rem;
    margin: auto;
    padding-block: 2rem;
}

#aboutUs img {
    max-width: 20rem;
    justify-self: center;
    align-self: center;
}

#auDescription {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    justify-content: center;
    text-align: justify;
}

#contact {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    text-align: center;
}

#contact h3,
.shops h4 {
    font-size: 1.5rem;
}

.contact-cards {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.shops {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: clamp(30rem, 40rem, 100%);
}

.map-containers {
    grid-column: 1 / 3;
    min-height: 300px;
}

iframe {
    width: 100%;
    height: 100%;
    border-radius: 1rem;
}

.information {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
}

.information a,
footer a {
    color: var(--light-blue);
}

.horarios {
    display: grid;
    grid-template-columns: 1fr 1fr;
    justify-items: center;
    align-items: center;
    gap: 0.5rem 1rem;
}

.whatsapp {
    display: flex;
    flex-direction: column;
    text-align: center;
    gap: 1rem;
}

.whatsapp a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 1.7rem;
    color: #4cb550;
}

.whatsapp img {
    max-width: 2.5rem;
}

/****** SPECIFIC: PRODUCT PAGES ******/

#product-content {
    max-width: 80rem;
    margin: 0 auto;
    gap: 2rem;
}

#detailedProduct {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 1rem clamp(1rem, 2.5vw, 2rem);
}

#mainImageContainer {
    width: 100%;
    display: flex;
    scroll-snap-type: x mandatory;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    box-shadow: rgba(0, 0, 0, 0.24) 0px 3px 8px;
}

#mainImageContainer::-webkit-scrollbar {
    display: none;
}

#mainImageContainer img {
    flex: 0 0 100%;
    scroll-snap-align: center;
}

#thumbnails {
    grid-row: 2 / 3;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    gap: 0.5rem;
}

#thumbnails img {
    cursor: pointer;
    opacity: 0.7;
}

#thumbnails img:first-child {
    opacity: 1;
}

#productDescription {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 1rem 2rem;
}

#productDescription > p,
#productDescription > ul {
    font-size: 1.1rem;
}

#productDescription ul {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

#productTitle {
    text-align: center;
}

#productDescription > a {
    font-size: 1.5rem;
}

#otherProducts {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

#productsGallery {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem 2rem;
    max-width: 50rem;
    margin: 0 auto;
}

#productsGallery .product-info {
    display: flex;
    flex-direction: column;
}

#productsGallery .product-buttons {
    align-self: stretch;
}

/****** SPECIFIC: LEGAL ******/

#legal {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 2rem;
    padding-block: 2rem;
    padding-inline: 1.5rem;
    max-width: 80rem;
    margin: auto;
}

#legal h1 {
    font-size: 2rem;
    text-align: center;
}

#legal h2 {
    font-size: 1.5rem;
}

#legal h3 {
    text-align: center;
    font-family: 'Brygada 1918', serif;
}

.legal_sections {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.legal_sections ul {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

#cookies {
    scroll-margin-top: 7rem;
}

/****** HOVER EFFECT ******/

@media (hover: hover) {

    /* Hovering effect only on computer */

    nav a:hover {
        color: var(--light-blue);
    }

    .product-cards img:hover,
    .other-product-cards img:hover {
        transform: translateY(-0.3rem);
        box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;
        transition: 0.3s;
    }

    .buttons:hover,
    #productPrice a:hover {
        cursor: pointer;
        box-shadow: rgba(99, 99, 99, 0.2) 0px 2px 8px 0px;
    }

    .information a:hover,
    footer a:hover {
        color: var(--light-blue);
    }

    .whatsapp a:hover {
        font-size: 2rem;
    }

    #thumbnails img:hover {
        opacity: 1 !important;
    }
}

/****** MEDIA QUERIES ******/

@media (width < 1351px) {
    .product-info h3,
    .product-price {
        grid-column: 1 / 3 !important;
    }
}

@media (width < 1000px) {
    #productDescription {
        grid-row: 1 / 3;
    }
}

@media (width < 1091px) {
    
}

@media (width < 1091px) {
    #hero {
        height: calc(100dvh - 92px);
    }
    
    #products {
        grid-template-columns: 1fr;
    }

    .product-info h3 {
        grid-column: 1 / 2 !important;
    }

    .product-price {
        grid-column: 2 / 3 !important;
    }

    #aboutUsWrapper {
        padding-block: 0;
    }

    /**** BURGER MENU MANAGEMENT ****/

    header {
        gap: 0;
    }

    header>div {
        width: 100%;
        display: flex;
        justify-content: space-between;
        align-items: center;
        background-color: var(--secondary-cream);
        z-index: 999;
    }

    nav {
        justify-content: space-between;
    }

    .nav-links {
        position: fixed;
        top: 5.625rem;
        right: -100%;
        bottom: 0;
        width: 100%;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
        background-color: rgba(255, 242, 198, 0.95);
        padding: 2rem;
        transition: all 0.2s ease-out;
    }

    .nav-links.active {
        transform: translateX(-100%);
    }

    .nav-links li {
        padding: 0.3rem;
    }

    #nav-links li:last-child {
        margin-top: auto;
    }

    #burger-container {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 1.8rem;
        height: 1.2rem;
        margin-top: 0.35rem;
    }

    .line {
        width: 100%;
        height: 3px;
        background-color: var(--light-blue);
        border-radius: 2px;
    }

    .unclicked .line-1 {
        animation: burger-top-reverse var(--burger-anim-duration) forwards;
    }

    .line-2 {
        transition: all var(--burger-anim-duration) ease-in-out;
    }

    .unclicked .line-3 {
        animation: burger-bottom-reverse var(--burger-anim-duration) forwards;
    }

    .clicked .line-1 {
        animation: burger-top var(--burger-anim-duration) forwards;
    }

    .clicked .line-2 {
        opacity: 0;
    }

    .clicked .line-3 {
        animation: burger-bottom var(--burger-anim-duration) forwards;
    }

    @keyframes burger-top {
        0% {
            transform: translateY(0) rotate(0);
        }

        75% {
            transform: translateY(0.525rem) rotate(0);
        }

        100% {
            transform: translateY(0.525rem) rotate(45deg);
        }
    }

    @keyframes burger-bottom {
        0% {
            transform: translateY(0) rotate(0);
        }

        75% {
            transform: translateY(-0.49rem) rotate(0);
        }

        100% {
            transform: translateY(-0.49rem) rotate(-45deg);
        }
    }

    @keyframes burger-top-reverse {
        0% {
            transform: translateY(0.525rem) rotate(45deg);
        }

        75% {
            transform: translateY(0.525rem) rotate(0);
        }

        100% {
            transform: translateY(0) rotate(0);
        }
    }

    @keyframes burger-bottom-reverse {
        0% {
            transform: translateY(-0.49rem) rotate(-45deg);
        }

        75% {
            transform: translateY(-0.49rem) rotate(0);
        }

        100% {
            transform: translateY(0) rotate(0);
        }
    }

    #socialMediaHeader {
        gap: 2rem;
        width: 12rem;
    }

    /**** PRODUCT CARDS ****/

    .product-cards {
        opacity: 0;
        transform: translateY(1rem);
        transition: opacity 0.6s ease-out, transform 0.6s ease-out;
    }

    .visible {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (width < 890px) {
    #aboutUs {
        grid-template-columns: 1fr;
    }
}

@media (width < 830px) {
    #detailedProduct {
        display: flex;
        flex-direction: column;
    }

    #productsGallery {
        grid-template-columns: 1fr;
    }

    #productsGallery .product-info {
        flex-direction: row;
        flex-wrap: wrap;
    }

    #productsGallery .product-info h3,
    #productsGallery .product-info .product-price {
        flex-grow: 1;
    }

    #productsGallery .product-info .product-buttons {
        flex-basis: 100%;
    }
}

@media (width < 604px) {
    .product-info h3,
    .product-price {
        grid-column: 1 / 3 !important;
    }
}