/**
 * EMA Banner — front-end styles.
 *
 * Defaults match the original .hero section on the EMA Catering home page.
 * Three responsive tiers: desktop (default), tablet (<=1100px), mobile (<=780px).
 *
 * On mobile the photo opacity drops so it acts as a faded backdrop, the stamp
 * shrinks and tucks into the top-right corner, and the meta row stacks.
 */

/* =====================================================
 * Wrapper
 * ===================================================== */
body {
    font-family: var(--sans);
    color: var(--soot);
    background: var(--cream);
    -webkit-font-smoothing: antialiased;
    line-height: 1.5;
    font-size: 16px;
    overflow-x: hidden;
}
.ema-banner{
    position: relative;
    background: #12110F;
    color: #F5EFD9;
    padding: 0 32px 0;
    overflow: hidden;
    min-height: 90vh;
}

/* Grain overlay (subtle noise) */
.ema-banner-grain{
    position: absolute; inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.25'/%3E%3C/svg%3E");
    mix-blend-mode: overlay;
    opacity: .6;
    pointer-events: none;
    z-index: 1;
}

/* =====================================================
 * Side photo
 * ===================================================== */
.ema-banner-photo{
    --ema-photo-shadow: #A01428;
    --ema-photo-shadow-offset: 18px;
    --ema-photo-rotate: -3deg;

    position: absolute;
    right: -80px; top: 50%;
    transform: translateY(-48%) rotate(var(--ema-photo-rotate));
    width: 62%; max-width: 780px;
    aspect-ratio: 4/5;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: 6px solid #F5EFD9;
    box-shadow: var(--ema-photo-shadow-offset) var(--ema-photo-shadow-offset) 0 var(--ema-photo-shadow);
    z-index: 1;
    transition: transform .8s cubic-bezier(.6,.05,.2,.95);
}
.ema-banner-photo:hover{
    transform: translateY(-48%) rotate(calc(var(--ema-photo-rotate) * 0.33)) scale(1.01);
}

/* =====================================================
 * Stamp / Badge
 * ===================================================== */
.ema-banner-stamp{
    --ema-stamp-left: 50%;
    --ema-stamp-bottom: 14%;

    position: absolute;
    left: var(--ema-stamp-left);
    bottom: var(--ema-stamp-bottom);
    z-index: 3;
    width: 170px; height: 170px;
    background: #C2A862;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: rotate(-12deg);
    color: #12110F;
    font-family: 'Oswald', 'Arial Narrow', sans-serif;
    font-weight: 800;
    box-shadow: 6px 6px 0 #12110F;
}
.ema-banner--stamp-animate .ema-banner-stamp{
    animation: ema-banner-wobble 6s ease-in-out infinite;
}
@keyframes ema-banner-wobble{
    0%, 100% { transform: rotate(-12deg); }
    50%      { transform: rotate(-8deg); }
}
.ema-banner-stamp .top{
    text-align: center;
    line-height: 1;
}
.ema-banner-stamp .big{
    font-size: 46px;
    display: block;
    letter-spacing: -0.04em;
    color: inherit;
}
.ema-banner-stamp .lab{
    font-family: 'Oswald', 'Arial Narrow', sans-serif;
    font-weight: 800;
    font-size: 11px;
    letter-spacing: .18em;
    text-transform: uppercase;
    margin-top: 6px;
    display: block;
    color: inherit;
}

/* =====================================================
 * Content (inner)
 * ===================================================== */
.ema-banner-inner{
    position: relative;
    z-index: 2;
    max-width: 1440px;
    margin: 0 auto;
    padding: 80px 0 100px;
    min-height: 90vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Eyebrow */
.ema-banner-eyebrow{
        font-family: 'Oswald', 'Arial Narrow', sans-serif;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    font-weight: 700;
    font-size: 12px;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: #C2A862;
    margin-bottom: 30px;
    animation: ema-banner-slide .8s .1s both;
}
.ema-banner-eyebrow::before{
    content: "";
    width: 32px;
    height: 2px;
    background: #C2A862;
    flex-shrink: 0;
}
.ema-banner-eyebrow.no-line::before{ display: none; }

/* Heading */
.ema-banner-h{
    font-family: 'Oswald', 'Arial Narrow', sans-serif;
    font-weight: 800;
    font-size: clamp(56px, 13vw, 200px);
    line-height: .84;
    letter-spacing: -0.05em;
    color: #F5EFD9;
    margin: 0 0 48px 0;
    max-width: 1100px;
}
.ema-banner-h .l1{
    display: block;
    animation: ema-banner-slide .9s .2s both;
}
.ema-banner-h .l2{
    display: block;
    font-style: italic;
    color: #A01428;
    font-weight: 400;
    animation: ema-banner-slide .9s .4s both;
}

@keyframes ema-banner-slide{
    from { opacity: 0; transform: translateY(40px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Meta row (subtitle + buttons) */
.ema-banner-meta{
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
    align-items: flex-end;
    justify-content: space-between;
    padding-top: 36px;
    border-top: 1px solid rgba(245,239,217,.2);
    animation: ema-banner-slide .9s .6s both;
}
.ema-banner-meta.no-divider{
    border-top: 0;
    padding-top: 0;
}

.ema-banner-sub{
    font-family: 'Oswald', 'Arial Narrow', sans-serif;
    font-style: italic;
    font-weight: 400;
    font-size: 22px;
    line-height: 1.4;
    color: #F5EFD9;
    max-width: 480px;
    opacity: .92;
    margin: 0;
}

.ema-banner-ctas{
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

/* =====================================================
 * Banner buttons
 * ===================================================== */
.ema-banner-btn,
.ema-banner-btn:link,
.ema-banner-btn:visited{
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 18px 28px;
    border-radius: 50px;
    font-family: 'Oswald', 'Arial Narrow', sans-serif;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    text-decoration: none;
    transition: all .25s cubic-bezier(.4,0,.2,1);
    border: 2px solid transparent;
    line-height: 1;
}
.ema-banner-btn .arr{
    display: inline-block;
    transition: transform .25s;
}
.ema-banner-btn:hover .arr{
    transform: translateX(4px);
}

/* Primary (red, shadow) */
.ema-banner-btn--primary,
.ema-banner-btn--primary:link,
.ema-banner-btn--primary:visited{
    background-color: #A01428;
    color: #F5EFD9;
    box-shadow: 4px 4px 0 #12110F;
    border-color: transparent;
}
.ema-banner-btn--primary:hover,
.ema-banner-btn--primary:focus,
.ema-banner-btn--primary:active{
    background-color: #7E0F1F;
    color: #F5EFD9;
    transform: translate(-2px,-2px);
    box-shadow: 6px 6px 0 #12110F;
}

/* Ghost (transparent, border) */
.ema-banner-btn--ghost,
.ema-banner-btn--ghost:link,
.ema-banner-btn--ghost:visited{
    background-color: transparent;
    color: #F5EFD9;
    border-color: #F5EFD9;
}
.ema-banner-btn--ghost:hover,
.ema-banner-btn--ghost:focus,
.ema-banner-btn--ghost:active{
    background-color: #F5EFD9;
    color: #12110F;
}

/* =====================================================
 * RESPONSIVE — Tablet (≤1100px)
 * ===================================================== */
@media (max-width: 1100px){
    .ema-banner{ padding: 0 24px; min-height: 720px; }
    .ema-banner-inner{ min-height: 720px; padding: 60px 0 80px; }
    .ema-banner-photo{
        right: -120px;
        width: 60%;
        opacity: .7;
    }
    .ema-banner-stamp .big{ font-size: 36px; }
    .ema-banner-stamp .lab{ font-size: 10px; }
}

/* =====================================================
 * RESPONSIVE — Mobile (≤780px)
 * ===================================================== */
@media (max-width: 780px){
    .ema-banner{
        padding: 0 16px;
        min-height: 560px;
    }
    .ema-banner-inner{
        padding: 50px 0 70px;
        min-height: 560px;
    }

    /* Photo becomes a faded backdrop */
    .ema-banner-photo{
        width: 88%;
        right: -18%;
        top: 38%;
        max-width: none;
        box-shadow: 8px 8px 0 var(--ema-photo-shadow, #A01428);
        opacity: .32;
        border-width: 4px;
    }

    /* Stamp shrinks and moves to top-right */
    .ema-banner-stamp{
        width: 88px; height: 88px;
        left: auto !important;
        right: 14px;
        top: 14px;
        bottom: auto !important;
        box-shadow: 3px 3px 0 #12110F;
    }
    .ema-banner-stamp .big{ font-size: 24px; }
    .ema-banner-stamp .lab{ font-size: 8px; letter-spacing: .12em; }

    /* Smaller heading + eyebrow */
    .ema-banner-eyebrow{
        font-size: 10.5px;
        letter-spacing: .18em;
        margin-bottom: 18px;
    }
    .ema-banner-eyebrow::before{ width: 22px; }

    .ema-banner-h{
        font-size: 64px;
        line-height: .88;
        margin-bottom: 32px;
    }

    /* Meta row stacks vertically */
    .ema-banner-meta{
        flex-direction: column;
        align-items: flex-start;
        gap: 22px;
        padding-top: 28px;
    }
    .ema-banner-sub{ font-size: 17px; }

    /* Buttons more compact */
    .ema-banner-ctas{ gap: 10px; }
    .ema-banner-btn, .ema-banner-btn:link, .ema-banner-btn:visited{
        padding: 14px 22px;
        font-size: 11px;
        letter-spacing: .06em;
    }

}

/* Very narrow phones (<420px) — keep text legible */
@media (max-width: 420px){
    .ema-banner-stamp .big{ font-size: 22px; }
}

/* =====================================================
 * Reduced motion
 * ===================================================== */
@media (prefers-reduced-motion: reduce){
    .ema-banner-photo,
    .ema-banner-h .l1,
    .ema-banner-h .l2,
    .ema-banner-eyebrow,
    .ema-banner-meta,
    .ema-banner--stamp-animate .ema-banner-stamp{
        animation: none !important;
        transition: none !important;
    }
}
