/* =========================================================
   SATHI FOODS COMPACT HOME PAGE V4
   Scoped to .sf-home-compact to avoid panel/public conflicts.
========================================================= */

.sf-home-compact {
    --sf-orange: #f04414;
    --sf-orange-dark: #c92d08;
    --sf-cream: #fff8f0;
    --sf-brown: #3c190f;
    --sf-muted: #7d6259;
    --sf-line: rgba(82, 39, 23, 0.12);
    --sf-shadow: 0 18px 48px rgba(74, 28, 10, 0.12);

    width: 100%;
    padding: 20px clamp(14px, 3vw, 36px) 44px;
    overflow: hidden;
    background:
        radial-gradient(circle at 7% 7%, rgba(255, 157, 91, 0.14), transparent 22%),
        #fffaf6;
}

/* Slider */
.sf-home-slider {
    position: relative;
    width: min(1320px, 100%);
    height: 430px;
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid rgba(96, 43, 23, 0.1);
    border-radius: 28px;
    background: #f15b28;
    box-shadow: var(--sf-shadow);
}

.sf-home-slides,
.sf-home-slide {
    width: 100%;
    height: 100%;
}

.sf-home-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: scale(1.015);
    transition: opacity 0.45s ease, visibility 0.45s ease, transform 0.7s ease;
}

.sf-home-slide.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: scale(1);
}

.sf-home-slide-image {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    transform: scale(1.035);
    transition: transform 6s linear;
}

.sf-home-slide.is-active .sf-home-slide-image {
    transform: scale(1.095);
}

.sf-home-slide-placeholder {
    display: grid;
    place-items: center;
    background:
        radial-gradient(circle at 76% 42%, rgba(255,255,255,.32), transparent 22%),
        linear-gradient(135deg, #ffad72, #ff6631 52%, #ef3c0e);
}

.sf-home-slide-placeholder span {
    margin-left: 48%;
    font-size: clamp(90px, 13vw, 180px);
    filter: drop-shadow(0 20px 25px rgba(88, 18, 0, 0.2));
}

.sf-home-slide-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(37, 11, 4, 0.88) 0%, rgba(51, 14, 5, 0.75) 36%, rgba(55, 12, 2, 0.2) 68%, rgba(44, 7, 0, 0.05) 100%),
        linear-gradient(0deg, rgba(43, 9, 1, 0.18), transparent 42%);
}

.sf-home-slide-content {
    position: relative;
    z-index: 2;
    width: min(620px, 58%);
    height: 100%;
    padding: clamp(36px, 5vw, 64px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.sf-home-eyebrow {
    display: inline-flex;
    min-height: 32px;
    padding: 0 13px;
    align-items: center;
    border: 1px solid rgba(255,255,255,.32);
    border-radius: 999px;
    color: #fff9f1;
    background: rgba(255,255,255,.12);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
    backdrop-filter: blur(8px);
}

.sf-home-slide-content h1 {
    max-width: 590px;
    margin: 16px 0 12px;
    color: #fff;
    font-family: Manrope, Inter, sans-serif;
    font-size: clamp(34px, 4.2vw, 59px);
    line-height: 1.02;
    letter-spacing: -2.6px;
    font-weight: 900;
}

.sf-home-slide-content > p {
    max-width: 540px;
    margin: 0;
    color: rgba(255,255,255,.84);
    font-size: 15px;
    line-height: 1.65;
}

.sf-home-slide-actions {
    margin-top: 23px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.sf-home-slide-actions a {
    min-height: 46px;
    padding: 0 19px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border-radius: 13px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 900;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.sf-home-slide-actions a:hover {
    transform: translateY(-2px);
}

.sf-home-primary-btn {
    color: #fff !important;
    background: var(--sf-orange);
    box-shadow: 0 12px 25px rgba(175, 41, 5, 0.34);
}

.sf-home-secondary-btn {
    color: #3a170e !important;
    background: rgba(255,255,255,.92);
}

.sf-home-search {
    width: min(500px, 100%);
    min-height: 50px;
    margin-top: 19px;
    padding: 5px 6px 5px 15px;
    display: flex;
    align-items: center;
    gap: 9px;
    border: 1px solid rgba(255,255,255,.22);
    border-radius: 14px;
    background: rgba(255,255,255,.94);
    box-shadow: 0 13px 28px rgba(37, 8, 0, 0.17);
}

.sf-home-search > span {
    color: #b55231;
    font-size: 21px;
}

.sf-home-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #3c190f;
    font-size: 13px;
}

.sf-home-search button {
    min-height: 40px;
    padding: 0 17px;
    border: 0;
    border-radius: 10px;
    color: #fff !important;
    background: var(--sf-orange);
    font-weight: 900;
    cursor: pointer;
}

.sf-slider-arrow {
    position: absolute;
    top: 50%;
    z-index: 5;
    width: 42px;
    height: 42px;
    padding: 0;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255,255,255,.35);
    border-radius: 50%;
    color: #fff !important;
    background: rgba(26, 6, 0, .36);
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    transform: translateY(-50%);
    backdrop-filter: blur(7px);
}

.sf-slider-arrow:hover {
    background: var(--sf-orange);
}

.sf-slider-prev { left: 15px; }
.sf-slider-next { right: 15px; }

.sf-slider-dots {
    position: absolute;
    left: 50%;
    bottom: 16px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 7px;
    transform: translateX(-50%);
}

.sf-slider-dots button {
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255,255,255,.52);
    cursor: pointer;
    transition: width .2s ease, background .2s ease;
}

.sf-slider-dots button.is-active {
    width: 26px;
    background: #fff;
}

/* Sections */
.sf-home-categories,
.sf-home-products,
.sf-home-trust {
    width: min(1320px, 100%);
    margin-left: auto;
    margin-right: auto;
}

.sf-home-categories {
    padding: 31px 0 12px;
}

.sf-home-section-head {
    margin-bottom: 17px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
}

.sf-home-section-head-centered {
    display: block;
    text-align: center;
}

.sf-home-section-head > div > span,
.sf-home-section-head-centered > span {
    display: block;
    margin-bottom: 4px;
    color: var(--sf-orange);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.sf-home-section-head h2 {
    margin: 0;
    color: var(--sf-brown);
    font-family: Manrope, Inter, sans-serif;
    font-size: clamp(24px, 3vw, 36px);
    letter-spacing: -1.2px;
    font-weight: 900;
}

.sf-home-section-head > a {
    color: var(--sf-orange-dark);
    font-size: 13px;
    font-weight: 900;
    text-decoration: none;
}

.sf-category-list {
    display: grid;
    grid-template-columns: repeat(9, minmax(90px, 1fr));
    gap: 11px;
}

.sf-category-card {
    min-width: 0;
    padding: 9px 8px 11px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--sf-line);
    border-radius: 16px;
    color: var(--sf-brown);
    background: #fff;
    box-shadow: 0 8px 20px rgba(87, 39, 18, 0.06);
    text-decoration: none;
    transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.sf-category-card:hover {
    transform: translateY(-4px);
    border-color: rgba(240,68,20,.35);
    box-shadow: 0 14px 30px rgba(96, 41, 17, 0.12);
}

.sf-category-media,
.sf-category-icon {
    width: 100%;
    height: 68px;
    margin-bottom: 8px;
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 12px;
    background: #fff0e5;
}

.sf-category-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sf-category-media b,
.sf-category-icon {
    font-size: 31px;
}

.sf-category-card strong {
    max-width: 100%;
    overflow: hidden;
    color: #4b1e12;
    font-size: 11px;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sf-category-card small {
    margin-top: 3px;
    color: #a37d70;
    font-size: 9px;
}

.sf-category-all,
.sf-category-more {
    border-color: rgba(240,68,20,.25);
    background: #fff7f0;
}

.sf-home-products {
    padding: 28px 0 18px;
}

.sf-home-food-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 17px;
}

/* Compact existing food cards only inside this page */
.sf-home-food-grid .food-product-card {
    min-width: 0;
    border-radius: 17px;
    box-shadow: 0 10px 28px rgba(73, 34, 17, .08);
}

.sf-home-food-grid .food-product-media {
    height: 165px;
}

.sf-home-food-grid .food-product-content {
    padding: 13px;
}

.sf-home-food-grid .food-product-content h3 {
    margin: 6px 0;
    font-size: 15px;
}

.sf-home-food-grid .food-product-content > p {
    display: -webkit-box;
    min-height: 34px;
    overflow: hidden;
    font-size: 11px;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.sf-home-food-grid .food-kitchen-name {
    display: none;
}

.sf-home-food-grid .food-product-price strong {
    font-size: 15px;
}

.sf-home-food-grid .food-product-bottom form button {
    min-height: 37px;
    padding: 0 12px;
    font-size: 11px;
}

.sf-home-empty {
    grid-column: 1 / -1;
    padding: 48px 20px;
    border: 1px dashed rgba(240,68,20,.3);
    border-radius: 20px;
    text-align: center;
    background: #fff;
}

.sf-home-empty span { font-size: 46px; }
.sf-home-empty h3 { margin: 10px 0 5px; color: var(--sf-brown); }
.sf-home-empty p { color: var(--sf-muted); }

.sf-home-trust {
    margin-top: 23px;
    padding: 17px 20px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    border: 1px solid var(--sf-line);
    border-radius: 20px;
    background: #fff1e4;
}

.sf-home-trust > div {
    min-width: 0;
    padding: 4px 18px;
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 11px;
    align-items: center;
    border-right: 1px solid rgba(102,48,27,.1);
}

.sf-home-trust > div:last-child { border-right: 0; }
.sf-home-trust > div > span { grid-row: 1 / 3; font-size: 29px; }
.sf-home-trust strong { color: var(--sf-brown); font-size: 12px; }
.sf-home-trust small { color: var(--sf-muted); font-size: 9px; }

@media (max-width: 1150px) {
    .sf-category-list {
        grid-template-columns: repeat(5, minmax(100px, 1fr));
    }

    .sf-home-food-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .sf-home-compact {
        padding: 14px 14px 94px;
    }

    .sf-home-slider {
        height: 410px;
        border-radius: 22px;
    }

    .sf-home-slide-content {
        width: 72%;
        padding: 38px 34px;
    }

    .sf-home-slide-overlay {
        background: linear-gradient(90deg, rgba(35,9,2,.88), rgba(43,10,2,.66) 58%, rgba(43,10,2,.15));
    }

    .sf-home-slide-content h1 {
        font-size: clamp(33px, 6vw, 48px);
    }

    .sf-category-list {
        display: flex;
        gap: 10px;
        overflow-x: auto;
        padding: 2px 2px 9px;
        scroll-snap-type: x proximity;
        scrollbar-width: thin;
    }

    .sf-category-card {
        flex: 0 0 112px;
        scroll-snap-align: start;
    }

    .sf-home-food-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sf-home-trust {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px 0;
    }

    .sf-home-trust > div:nth-child(2) { border-right: 0; }
}

@media (max-width: 640px) {
    .sf-home-slider {
        height: 470px;
        border-radius: 19px;
    }

    .sf-home-slide-image {
        background-position: 62% center;
    }

    .sf-home-slide-overlay {
        background:
            linear-gradient(0deg, rgba(39,9,2,.95) 0%, rgba(45,10,2,.80) 56%, rgba(49,12,2,.28) 100%);
    }

    .sf-home-slide-content {
        width: 100%;
        padding: 28px 22px 38px;
        justify-content: flex-end;
    }

    .sf-home-slide-content h1 {
        margin-top: 12px;
        font-size: clamp(30px, 10vw, 42px);
        letter-spacing: -1.7px;
    }

    .sf-home-slide-content > p {
        font-size: 13px;
        line-height: 1.55;
    }

    .sf-home-slide-actions {
        width: 100%;
        margin-top: 17px;
    }

    .sf-home-slide-actions a {
        flex: 1 1 130px;
        min-height: 43px;
        padding: 0 12px;
        font-size: 12px;
    }

    .sf-home-search {
        min-height: 47px;
        margin-top: 13px;
    }

    .sf-home-search button {
        min-height: 37px;
        padding: 0 12px;
        font-size: 11px;
    }

    .sf-slider-arrow {
        top: 30%;
        width: 37px;
        height: 37px;
    }

    .sf-slider-prev { left: 9px; }
    .sf-slider-next { right: 9px; }

    .sf-home-categories {
        padding-top: 26px;
    }

    .sf-home-section-head {
        align-items: flex-start;
    }

    .sf-home-section-head h2 {
        font-size: 25px;
    }

    .sf-home-food-grid {
        gap: 11px;
    }

    .sf-home-food-grid .food-product-media {
        height: 132px;
    }

    .sf-home-food-grid .food-product-content {
        padding: 10px;
    }

    .sf-home-food-grid .food-product-meta {
        font-size: 9px;
    }

    .sf-home-food-grid .food-product-content h3 {
        font-size: 13px;
    }

    .sf-home-food-grid .food-product-content > p {
        display: none;
    }

    .sf-home-food-grid .food-product-bottom {
        align-items: flex-end;
        gap: 7px;
    }

    .sf-home-food-grid .food-product-bottom form button {
        min-width: 39px;
        padding: 0 8px;
    }

    .sf-home-food-grid .food-product-bottom form button span {
        display: none;
    }

    .sf-home-trust {
        padding: 14px 8px;
    }

    .sf-home-trust > div {
        padding: 4px 10px;
    }

    .sf-home-trust > div > span {
        font-size: 24px;
    }
}

@media (max-width: 390px) {
    .sf-home-slider {
        height: 490px;
    }

    .sf-home-slide-content {
        padding-left: 18px;
        padding-right: 18px;
    }

    .sf-home-food-grid {
        grid-template-columns: 1fr 1fr;
    }

    .sf-home-section-head > a {
        font-size: 11px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .sf-home-slide,
    .sf-home-slide-image,
    .sf-slider-dots button,
    .sf-category-card,
    .sf-home-slide-actions a {
        transition: none !important;
    }
}
