/* =========================================
   THEME 
   ========================================= */

/* Theme Colors */
:root {
    --mint-green: #99e2d0;
    --light-blue: #eafBff;
    --sky: #89c8fa;
    --soft-blue: #c5e2f8;
    --pale-blue: #d5f0f8;
    --purple: #9356DC;
    --pink: #FF79DA;
    --dark-gray: #353535;
    --text-gray: #666;
}

/* =========================================================
     BASE + PAGE LAYOUT (mobile-first, 375px content column)
     ========================================================= */
html,
body {
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Roboto', sans-serif;
    background: #fff;
    color: #111;
}

/* Page Wrapper (mobile width centered) */
.page {
    width: 100%;
    max-width: 375px;
    /* Figma mobile width */
    margin: 0 auto;
    background: #fff;
}


/* =========================================
     LOADER (MOBILE-FIRST)
     ========================================= */

.loader {
    position: fixed;
    inset: 0;
    /* full screen overlay */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    /* keep logo visible at top */
    padding: 16px;
    background: linear-gradient(180deg, var(--pink), var(--purple));
    z-index: 9999;

    /* fade-out overlay after delay */
    animation: fadeOut 2s ease forwards;
    animation-delay: 1s;
}

/* Loader Logo (sticky near top) */
.loader__logo {
    font-family: 'Shrikhand', cursive;
    font-size: 55px;
    line-height: 1;
    color: #fff;
    margin: 0 0 12px 0;
    text-shadow: 0 2px 6px rgba(0, 0, 0, .18);
    position: sticky;
    /* stays visible if cards scroll */
    top: 8px;
    z-index: 1;
}

/* Loader Cards Container */
.loader__cards {
    width: 100%;
    max-width: 350px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Loader Card (distinct from page .card) */
.loadercard {
    background: #fff;
    color: #111;
    display: flex;
    flex-direction: column;
    /* media above text */
    border-radius: 12px;
    overflow: hidden;
    height: 175px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
}

/* Loader Card: Media */
.loadercard__media {
    flex: 1;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.loadercard__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 60%;
    display: block;
}

/* Loader Card: Body (centered text) */
.loadercard__body {
    height: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* center horizontally */
    justify-content: center;
    /* center vertically */
    text-align: center;
}

/* Loader Card: Title & Subtitle */
.loadercard__title {
    margin: 0 0 2px 0;
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
}

.loadercard__subtitle {
    margin: 0;
    font-size: 12px;
    font-weight: 400;
    color: #555;
    line-height: 1;
}

/* Loader Fade-out */
@keyframes fadeOut {
    to {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
    }
}


/* =========================================
     HEADER
     ========================================= */

.header {
    height: 60px;
    display: grid;
    place-items: center;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .08);
}

.logo-img {
    height: 32px;
    display: block;
}


/* =========================================
     LOCATION BAR
     ========================================= */

.location {
    width: 100%;
    /* full 375px */
    height: 50px;
    background: #ededed;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-top: 2px solid #d2d2d2;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.08);
    /* subtle top shadow */
}

.location__icon {
    width: 17px;
    height: 17px;
    opacity: 0.9;
    color: #000000;
}

.location__text {
    margin: 0;
    font-weight: 500;
    font-size: 16px;
    color: #353535;
    letter-spacing: 0.1px;
}


/* =========================================
     DISCOVER SECTION
     ========================================= */

.discover-section {
    text-align: center;
    background-color: #f6f6f6;
    padding: 40px 15px 60px 15px;
}

.discover-section__title {
    margin: 0 0 40px;
    font-weight: 700;
    font-size: 24px;
}

.discover-section__subtitle {
    margin: 0 0 25px;
    color: var(--text-gray);
    font-size: 18px;
    font-weight: 300;
}


/* =========================================
     BUTTONS
     ========================================= */

.btn {
    display: inline-block;
    padding: 13px 18px;
    width: 218px;
    height: 50px;
    border: 0;
    border-radius: 999px;
    font-weight: 500;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;

    /* Smooth transitions on all buttons */
    transition: filter .18s ease, box-shadow .18s ease, transform .18s ease;
}

.btn--primary {
    color: #fff;
    background: linear-gradient(180deg, var(--pink), var(--purple));
    box-shadow:
        0 8px 18px rgba(147, 86, 220, 0.25),
        0 2px 4px rgba(0, 0, 0, 0.12);
    transition: transform 0.08s ease;
}

.btn--primary:active {
    transform: translateY(1px);
}

/* Hover: slightly lighter + punchier shadow */
.btn:hover {
    filter: brightness(1.06);
    box-shadow:
        0 12px 26px rgba(147, 86, 220, .33),
        0 4px 8px rgba(0, 0, 0, .14);
}


/* =========================================
     HOW IT WORKS SECTION
     ========================================= */

.how-section__title {
    font-size: 24px;
    font-weight: 700;
    padding: 30px 0 15px 10px;
}

.how-list {
    list-style: none;
    margin: 0;
    padding: 0 23px 45px 30px;
    display: grid;
    gap: 16px;
}

.how {
    --n: "1";
    position: relative;
    display: grid;
    grid-template-columns: 44px 1fr;
    align-items: center;
    background: #f4f4f4;
    border-radius: 16px;
    padding: 0px 0px 0px 40px;
    height: 72px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.how::before {
    content: var(--n);
    position: absolute;
    left: -10px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    border-radius: 999px;
    display: grid;
    place-items: center;
    background: var(--purple);
    color: #fff;
    font-weight: 400;
    font-size: 14px;
}

.how-1 {
    --n: "1";
}

.how-2 {
    --n: "2";
}

.how-3 {
    --n: "3";
}

.how__icon {
    display: block;
}

.how__text {
    font-weight: 500;
    font-size: 16px;
    color: #1b1b1b;
}


/* =========================================
     RESTAURANTS
     ========================================= */

.restaurants {
    background-color: #f6f6f6;
    padding-bottom: 55px;
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    padding-top: 50px;
    margin: 18px 0 20px 16px;
}

/* Card (mobile) */
.card {
    width: 340px;
    height: 251px;
    margin: 0 auto 16px;
    background: #fff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .10);
    display: flex;
    flex-direction: column;
}

.card__media {
    position: relative;
    overflow: hidden;
    margin: 0;
}

.card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center bottom;
    /* shift crop focus downward */
    display: block;
}

/* fine-tune just Elderflower */
.card--elderflower .card__media img {
    object-position: 50% 62%;
}

.badge {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 80px;
    height: 29px;
    line-height: 29px;
    /* centers text vertically */
    background: var(--mint-green);
    color: #1a7a66;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    border-radius: 2px;
    /* match Figma (not rounded pill) */
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.card__body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 14px 16px 16px;
}

.card__title {
    margin: 0 0 4px;
    font-size: 18px;
    font-weight: 700;
}

.card__subtitle {
    margin: 0;
    font-size: 17px;
    font-weight: 300;
    color: #000000;
}

.card__title,
.card__subtitle {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}


/* =========================================
     HEART (LIKE BUTTON) ANIMATION
     ========================================= */

.heart {
    background: none;
    border: none;
    padding-right: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    isolation: isolate;
    /* keeps stacking clean */
    width: 22px;
    height: 22px;
}

/* Outline heart (always visible) */
.heart__icon {
    position: absolute;
    inset: 0;
    width: 22px;
    height: 22px;
    z-index: 1;
    display: block;
}

/* Filled heart (hidden until hover) */
.heart__icon--filled {
    position: absolute;
    inset: 0;
    width: 22px;
    height: 22px;
    z-index: 2;
    opacity: 0;
    transition: opacity 0.8s ease;
    /* smooth fade-in */
}

/* On hover or focus, fade the filled heart in */
.heart:hover .heart__icon--filled,
.heart:focus .heart__icon--filled {
    opacity: 1;
}



/* ======================
     Footer (mobile)
  ====================== */
.footer {
    width: 100%;
    max-width: 375px;
    max-height: 186px;
    background: var(--dark-gray);
    color: #fff;
    padding: 22px 25px;
    box-sizing: border-box;
}

.footer__inner {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer__brand {
    font-family: 'Shrikhand', cursive;
    font-size: 18px;
    /* matches menu pages */
    font-weight: 400;
    margin: 0;
}

/* Links list */
.footer__links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 7px;
}

.footer__links a {
    color: #fff;
    text-decoration: none;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    /* space between icon and text */
}

.footer__links a:hover {
    text-decoration: none;
}

/* Icons */
.footer__icon {
    width: 15px;
    height: 15px;
    display: block;
}
















/* =========================================================
     DESKTOP LAYOUT (mobile-first ≥ 1024px)
   Target mock width 1440px, centered content 
     ========================================================= */
@media (min-width: 1024px) {

    /* Page spans wider; still centered */
    .page {
        max-width: 1440px;
    }

    /* Widen the loader container */
    .loader__cards {
        max-width: 800px;
        /* enough space for 2 columns */
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        grid-gap: 50px;
        /* spacing between cards */
        justify-content: center;
        /* center the grid */
    }

    /* Slightly larger cards for desktop */
    .loadercard {
        height: 200px;
        /* taller for bigger screens */
    }

    .loadercard__body {
        height: 50px;
        /* allow text a bit more breathing room */
    }

    .loadercard__title {
        font-size: 16px;
    }

    .loadercard__subtitle {
        font-size: 14px;
    }

    /* Logo larger on desktop */
    .loader__logo {
        font-size: 72px;
        margin-top: 30px;
        margin-bottom: 60px;
    }

    /* Header taller on desktop */
    .header {
        height: 96px;
    }

    .logo-img {
        height: 40px;
        /* slightly larger logo */
    }

    /* Location strip is not shown in desktop mock */
    .location {
        border: none;
        box-shadow: none;
    }

    /* ---------- Discover ---------- */
    .discover-section {
        background: #f6f6f6;
        /* wide light band like mock */
        padding: 30px 0 30px;
        text-align: center;
    }

    .discover-section__title {
        font-size: 40px;
        /* bigger title */
        margin: 0 0 25px;
    }

    .discover-section__subtitle {
        font-size: 18px;
        font-weight: 300;
        margin: 0 0 25px;
    }

    /* On desktop, hide the <br> so text stays in one line */
    .discover-section__subtitle br {
        display: none;
    }

    /* ---------- How it works row ---------- */

    .how-section {
        padding: 50px 180px 50px 180px;
    }

    .how-section__title {
        padding: 0 0 25px;
        margin: 0 90px;
        /* align with content band */
    }

    .how-list {
        padding: 0;
        /* reset mobile padding */
        margin: 0 96px 0;
        /* left/right gutters */
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 24px;
        /* space between the 3 pills */
    }

    .how {
        background: #f4f4f4;
        padding-left: 35px;
        /* room for icon/number */
        height: 72px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    }

    .how-1 .how__icon {
        width: 13px;
        height: 20px;
    }

    .how-2 .how__icon {
        width: 16px;
        height: 16px;
    }

    .how-3 .how__icon {
        width: 18px;
        height: 18px;
    }

    /* ---------- Restaurants grid ---------- */
    .restaurants {
        background: #f6f6f6;
        padding: 30px 0 30px;
    }

    /* Section title sits above the grid */
    .restaurants .section-title {
        margin: 0 0 25px 180px;
        padding: 0;
        font-size: 24px;
    }

    /* Grid wrapper controls only cards */
    .restaurants__grid {
        display: grid;
        grid-template-columns: repeat(2, 490px);
        justify-content: center;
        column-gap: 100px;
        /* horizontal spacing between columns */
        row-gap: 50px;
        /* vertical spacing between rows only */
    }

    /* Cards match Figma size */
    .restaurants__grid .card {
        width: 490px;
        height: 251px;
        margin: 0 auto;
        /* keep centered in column */
    }

    .restaurants__grid .card__media {
        height: 231px;
        /* image area */
    }

    .restaurants__grid .card__body {
        height: 75px;
        /* text/heart area */
    }

    .card__media img {
        object-position: 50% 65%;
    }

    /* fine-tune just Elderflower */
    .card--elderflower .card__media img {
        object-position: 50% 57%;
    }

    /* Badge unchanged */
    .badge {
        top: 12px;
        right: 12px;
    }

    .heart {
        padding-right: 30px;
    }

    .heart__icon--filled {
        padding-right: 30px;
    }

    /* ---------- Footer (desktop) ---------- */
    .footer {
        max-width: 100%;
        padding: 45px 25px 45px 25px;
    }

    .footer__inner {
        display: flex;
        align-items: center;
        justify-content: center;
        /* keeps links centered */
        position: relative;
        /* allows logo absolute positioning */
        gap: 30px;
    }

    /* Center the link group */
    .footer__links {
        display: flex;
        align-items: right;
        gap: 32px;
        /* spacing between links */
        margin-left: 500px;
        /* push links toward the right side */
        padding: 0;
        list-style: none;
    }

    /* Push logo all the way right */
    .footer__brand {
        margin: 0;
        font-family: 'Shrikhand', cursive;
        font-size: 18px;
        position: absolute;
        right: 25px;
        /* matches padding */
        top: 50%;
        transform: translateY(-50%);
    }
}