/**
 * Homepage (front-page.php)
 *
 * Phone layout first, then two and three columns on wider screens.
 * Everything is scoped to .maestro-home / .mh-* so other pages are untouched.
 *
 * @package Maestro
 * @version 1.1.0
 */

.maestro-home,
.mh-sticky {
    --mh-red: var(--primary-color, #c41e3a);
    --mh-red-dark: var(--primary-dark, #a01729);
    --mh-green: #2e8b3e;
    --mh-ink: #1d1d1f;
    --mh-muted: #5f5f66;
    --mh-cream: #fff7ec;
    --mh-line: #ece4d8;
    --mh-radius: 16px;
}

.maestro-home {
    color: var(--mh-ink);
    line-height: 1.5;
}

.maestro-home img {
    max-width: 100%;
    height: auto;
    display: block;
}

.mh-wrap {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 16px;
}

.maestro-home h1,
.maestro-home h2,
.maestro-home h3 {
    color: var(--mh-ink);
}

.maestro-home h2 {
    font-size: clamp(26px, 5.5vw, 36px);
    line-height: 1.15;
    margin: 0 0 8px;
    letter-spacing: -0.01em;
}

/* Buttons */
.mh-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 999px;
    font-weight: 700;
    text-decoration: none;
    padding: 12px 20px;
    font-size: 15px;
    line-height: 1.2;
    border: 2px solid transparent;
    white-space: nowrap;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.mh-btn-red,
.mh-btn-red:visited {
    background: var(--mh-red);
    color: #fff;
}

.mh-btn-red:hover,
.mh-btn-red:focus {
    background: var(--mh-red-dark);
    color: #fff;
}

.mh-btn-outline,
.mh-btn-outline:visited {
    border-color: var(--mh-ink);
    color: var(--mh-ink);
    background: #fff;
}

.mh-btn-outline:hover,
.mh-btn-outline:focus {
    background: var(--mh-ink);
    color: #fff;
}

.mh-btn-white,
.mh-btn-white:visited {
    background: #fff;
    color: var(--mh-red);
}

.mh-btn-white:hover,
.mh-btn-white:focus {
    background: #ffe9ec;
    color: var(--mh-red-dark);
}

.mh-btn-sm {
    padding: 9px 14px;
    font-size: 14px;
}

/* Hero */
.mh-hero {
    background: radial-gradient(circle at 85% 30%, #ffe2b8 0, var(--mh-cream) 55%);
    overflow: hidden;
}

.mh-hero-grid {
    display: grid;
    gap: 8px;
    padding-top: 28px;
    padding-bottom: 32px;
}

.mh-status {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    background: #fff;
    border: 1px solid var(--mh-line);
    border-radius: 999px;
    padding: 5px 14px 5px 5px;
    font-size: 14px;
    font-weight: 600;
    width: fit-content;
    margin: 0;
}

.mh-status .store-status {
    margin: 0;
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 13px;
}

.mh-since {
    color: var(--mh-green);
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 13px;
    margin: 14px 0 0;
}

.maestro-home h1 {
    font-size: clamp(32px, 8vw, 56px);
    line-height: 1.05;
    margin: 6px 0 10px;
    letter-spacing: -0.02em;
}

.maestro-home h1 em {
    color: var(--mh-red);
    font-style: normal;
}

.mh-lead {
    font-size: 17px;
    color: var(--mh-muted);
    max-width: 34em;
    margin: 0 0 18px;
}

.mh-ctas {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.mh-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
    margin: 18px 0 0;
    padding: 0;
    list-style: none;
    font-size: 14px;
    font-weight: 600;
}

.mh-hero-pic {
    position: relative;
    display: block;
    margin: 12px auto 0;
    width: min(420px, 92%);
}

.mh-hero-pic img {
    width: 100%;
    filter: drop-shadow(0 18px 30px rgba(120, 60, 0, 0.25));
}

.mh-price-tag {
    position: absolute;
    right: 2%;
    top: 6%;
    background: var(--mh-red);
    color: #fff;
    border-radius: 50%;
    width: 108px;
    height: 108px;
    display: grid;
    place-content: center;
    text-align: center;
    font-weight: 800;
    line-height: 1.1;
    padding: 8px;
    transform: rotate(8deg);
    box-shadow: 0 8px 18px rgba(200, 16, 46, 0.35);
}

.mh-price-tag small {
    display: block;
    font-size: 10px;
    font-weight: 600;
    opacity: 0.9;
}

.mh-price-tag b {
    font-size: 21px;
}

.mh-price-tag del {
    display: none;
}

/* WooCommerce sale prices include "Original price was..." text for screen readers only */
.maestro-home .screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
    word-wrap: normal !important;
}

.mh-price-tag ins {
    text-decoration: none;
}

/* Today's Special strip */
.mh-deal {
    background: var(--mh-red);
    color: #fff;
}

.mh-deal-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px 16px;
    padding-top: 14px;
    padding-bottom: 14px;
}

.mh-deal p {
    margin: 0;
    font-weight: 700;
    font-size: 16px;
}

.mh-deal p span {
    font-weight: 500;
    opacity: 0.92;
}

.mh-deal .amount,
.mh-deal ins {
    color: #fff;
    text-decoration: none;
}

/* Sections */
.mh-section {
    padding: 44px 0;
}

.mh-eyebrow {
    color: var(--mh-red);
    font-weight: 800;
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin: 0 0 6px;
}

.mh-sub {
    color: var(--mh-muted);
    margin: 0 0 22px;
}

.mh-center {
    text-align: center;
    margin: 18px 0 0;
}

/* Best sellers */
.mh-grid {
    display: grid;
    gap: 14px;
    grid-template-columns: 1fr;
}

.mh-card {
    background: #fff;
    border: 1px solid var(--mh-line);
    border-radius: var(--mh-radius);
    overflow: hidden;
    display: grid;
    grid-template-columns: 116px minmax(0, 1fr);
}

.mh-card-pic {
    background: #f6efe4;
    min-height: 116px;
    display: grid;
    place-items: center;
    overflow: hidden;
}

.mh-card-pic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mh-noimg {
    font-size: 38px;
    opacity: 0.55;
}

.mh-card-body {
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mh-card h3 {
    margin: 0;
    font-size: 16px;
    line-height: 1.25;
}

.mh-card h3 a {
    color: inherit;
}

.mh-card p {
    margin: 0;
    color: var(--mh-muted);
    font-size: 13px;
}

.mh-card-row {
    margin-top: auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding-top: 6px;
}

.mh-price {
    font-weight: 800;
    font-size: 17px;
}

.mh-price del {
    font-weight: 500;
    font-size: 13px;
    color: var(--mh-muted);
}

.mh-price ins {
    text-decoration: none;
}

.mh-rank {
    display: inline-block;
    background: #fff1d6;
    color: #8a5300;
    font-size: 11px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 999px;
    width: fit-content;
}

/* Ways to order */
.mh-ways {
    background: var(--mh-cream);
}

.mh-way {
    background: #fff;
    border-radius: var(--mh-radius);
    padding: 18px;
    border: 1px solid var(--mh-line);
}

.mh-way h3 {
    margin: 6px 0 4px;
    font-size: 18px;
}

.mh-way p {
    margin: 0;
    color: var(--mh-muted);
    font-size: 14px;
}

.mh-way-icon {
    font-size: 26px;
}

/* Reviews */
.mh-rating {
    font-weight: 700;
    margin: 0 0 16px;
}

.mh-rating span {
    color: #f5a400;
}

.mh-review {
    margin: 0;
    border: 1px solid var(--mh-line);
    border-radius: var(--mh-radius);
    padding: 16px;
    background: #fffdf9;
}

.mh-review p {
    margin: 0 0 10px;
}

.mh-review cite {
    font-style: normal;
    font-weight: 700;
    font-size: 14px;
    color: var(--mh-muted);
}

/* Order direct */
.mh-direct {
    background: #111;
    color: #fff;
    border-radius: 20px;
    padding: 26px 20px;
    display: grid;
    gap: 14px;
}

.maestro-home .mh-direct h2 {
    color: #fff;
}

.mh-direct p {
    color: #cfcfd4;
    margin: 0;
}

.mh-direct .mh-btn {
    width: fit-content;
}

/* Hours & location */
.mh-visit-grid {
    display: grid;
    gap: 18px;
}

.mh-hours .operating-hours {
    list-style: none;
    margin: 0;
    padding: 0;
    font-size: 15px;
}

.mh-hours .operating-hours li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 0;
    border-bottom: 1px solid var(--mh-line);
}

.mh-hours .operating-hours li:last-child {
    border-bottom: 0;
}

.mh-map {
    background: linear-gradient(135deg, #e9f2e7, #f6efe4);
    border-radius: var(--mh-radius);
    min-height: 200px;
    display: grid;
    place-content: center;
    justify-items: center;
    text-align: center;
    padding: 20px;
    border: 1px solid var(--mh-line);
}

.mh-map strong {
    font-size: 18px;
}

.mh-map p {
    margin: 4px 0 14px;
    color: var(--mh-muted);
}

/* FAQ */
.mh-faq details {
    border-bottom: 1px solid var(--mh-line);
    padding: 14px 0;
}

.mh-faq summary {
    font-weight: 700;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.mh-faq summary::-webkit-details-marker {
    display: none;
}

.mh-faq summary::after {
    content: "+";
    color: var(--mh-red);
    font-weight: 800;
}

.mh-faq details[open] summary::after {
    content: "\2013";
}

.mh-faq details p {
    color: var(--mh-muted);
    margin: 8px 0 0;
}

.mh-more {
    margin: 16px 0 0;
}

/* Phone: sticky Call / Order bar */
.mh-sticky {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999;
    background: #fff;
    border-top: 1px solid var(--mh-line);
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 10px;
    box-shadow: 0 -6px 20px rgba(0, 0, 0, 0.08);
}

.mh-sticky .mh-btn {
    width: 100%;
}

body.home {
    padding-bottom: 76px;
}

/* Wider screens */
@media (min-width: 720px) {
    .mh-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .mh-grid-3 {
        grid-template-columns: repeat(3, 1fr);
    }

    .mh-card {
        grid-template-columns: 1fr;
    }

    .mh-card-pic {
        min-height: 190px;
        max-height: 220px;
    }

    .mh-direct {
        grid-template-columns: 1.2fr auto;
        align-items: center;
        padding: 34px;
    }
}

@media (min-width: 960px) {
    body.home {
        padding-bottom: 0;
    }

    .mh-sticky {
        display: none;
    }

    .mh-hero-grid {
        grid-template-columns: 1.1fr 0.9fr;
        align-items: center;
        padding-top: 56px;
        padding-bottom: 64px;
    }

    .mh-hero-pic {
        margin: 0;
        width: 100%;
    }

    .mh-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .mh-visit-grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }
}
