/* ============================================================
   Public home page (Views/Home/Index.cshtml) — scoped under .hm-page.
   Header, video banner, marquee and footer come from _NewLayout.
   ============================================================ */

.hm-page {
    --hm-navy: #173a75;
    --hm-navy-2: #214687;
    --hm-blue: #3066be;
    --hm-light: #f0f5ff;
    --hm-chip: #dae7ff;
    --hm-yellow: #ffd812;
    --hm-green: #0bb17a;
    --hm-text: #2b3a55;
    --hm-muted: #5f6f8c;
    --hm-border: #e1e8f5;

    color: var(--hm-text);
    background: var(--hm-light);
    overflow-x: hidden;
}

.hm-section {
    padding: 64px 0;
}

.hm-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 28px;
}

.hm-kicker {
    display: inline-block;
    margin-bottom: 8px;
    padding: 5px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--hm-navy);
    background: var(--hm-chip);
}

.hm-kicker-light {
    align-self: flex-start;
    color: var(--hm-navy);
    background: var(--hm-yellow);
}

.hm-head h2,
.hm-story-body h2 {
    margin: 0;
    font-size: 34px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--hm-navy);
}

.hm-head h2 span {
    color: var(--hm-blue);
}

.hm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: 2px solid transparent;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    transition: transform .15s, background .2s, color .2s, border-color .2s;
}

.hm-btn:hover {
    transform: translateY(-2px);
    text-decoration: none;
}

.hm-btn-yellow {
    color: #1c2430;
    background: var(--hm-yellow);
}

.hm-btn-yellow:hover {
    color: #1c2430;
    background: #ffe04a;
}

.hm-btn-light {
    color: #fff;
    border-color: rgba(255, 255, 255, .7);
}

.hm-btn-light:hover {
    color: var(--hm-navy);
    background: #fff;
    border-color: #fff;
}

.hm-btn-ghost {
    color: var(--hm-navy);
    border-color: var(--hm-navy);
    background: transparent;
}

.hm-btn-ghost:hover {
    color: #fff;
    background: var(--hm-navy);
}

/* ---------- Trust strip ---------- */
.hm-trust {
    padding: 22px 0;
    background: #fff;
    border-bottom: 1px solid var(--hm-border);
}

.hm-trust-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.hm-trust-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hm-trust-item > i {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 18px;
    color: var(--hm-navy);
    background: var(--hm-chip);
}

.hm-trust-item strong {
    display: block;
    font-size: 15px;
    color: var(--hm-navy);
}

.hm-trust-item small {
    font-size: 13px;
    color: var(--hm-muted);
}

/* ---------- Categories ---------- */
/* carousel: scroll-snap track with arrows on both sides */
.hm-cat-carousel {
    position: relative;
    padding: 0 26px;
}

.hm-cat-row {
    display: flex;
    gap: 18px;
    padding: 6px 2px 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.hm-cat-row::-webkit-scrollbar {
    display: none;
}

.hm-cat-row:focus-visible {
    outline: 2px solid var(--hm-blue);
    outline-offset: 4px;
    border-radius: 12px;
}

/* 7 cards per view on desktop */
.hm-cat-row > .hm-cat {
    flex: 0 0 calc((100% - 6 * 18px) / 7);
    scroll-snap-align: start;
}

.hm-cat-arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--hm-border);
    border-radius: 50%;
    font-size: 15px;
    color: var(--hm-navy);
    background: #fff;
    box-shadow: 0 8px 20px rgba(23, 58, 117, .16);
    transform: translateY(-60%);
    cursor: pointer;
    transition: background .2s, color .2s, transform .15s;
}

.hm-cat-arrow:hover {
    color: #fff;
    background: var(--hm-navy);
}

.hm-cat-arrow:active {
    transform: translateY(-60%) scale(.94);
}

.hm-cat-prev { left: -4px; }
.hm-cat-next { right: -4px; }

/* all categories fit: no arrows needed */
.hm-cat-carousel.is-static {
    padding: 0;
}

.hm-cat-carousel.is-static .hm-cat-arrow {
    display: none;
}

.hm-cat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 18px 10px 16px;
    border: 1px solid var(--hm-border);
    border-radius: 20px;
    text-align: center;
    color: var(--hm-navy);
    background: #fff;
    text-decoration: none;
    transition: transform .2s, box-shadow .2s, border-color .2s;
}

.hm-cat:hover {
    transform: translateY(-4px);
    border-color: #c6d5ee;
    box-shadow: 0 16px 30px rgba(23, 58, 117, .12);
    color: var(--hm-navy);
    text-decoration: none;
}

.hm-cat-img {
    width: 92px;
    height: 92px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 50%;
    background: var(--hm-light);
}

.hm-cat-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hm-cat-name {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
}

/* ---------- Promo carousel ---------- */
.hm-promo {
    padding-bottom: 8px;
}

.hm-promo-carousel {
    overflow: hidden;
    border-radius: 24px;
    box-shadow: 0 18px 40px rgba(23, 58, 117, .14);
    background: #fff;
}

.hm-promo-carousel .carousel-item img {
    aspect-ratio: 1187 / 335;
    object-fit: cover;
}

/* bootstrap controls restyled (style.css forces odd sizes on these) */
.hm-promo-carousel .carousel-control-prev,
.hm-promo-carousel .carousel-control-next {
    top: 50% !important;
    width: 42px !important;
    height: 42px !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 50% !important;
    align-items: center;
    justify-content: center;
    color: var(--hm-navy);
    background: rgba(255, 255, 255, .9) !important;
    box-shadow: 0 6px 16px rgba(0, 0, 0, .15);
    opacity: 1;
    transform: translateY(-50%);
}

.hm-promo-carousel .carousel-control-prev { left: 14px; }
.hm-promo-carousel .carousel-control-next { right: 14px; }

.hm-promo-carousel .carousel-indicators {
    left: 0 !important;
    right: 0;
    width: auto !important;
    height: auto !important;
    margin-bottom: 12px;
    border-radius: 0 !important;
    background: transparent !important;
}

.hm-promo-carousel .carousel-indicators [data-bs-target] {
    width: 8px;
    height: 8px;
    margin: 0 4px;
    border: 0;
    border-radius: 50%;
    background: #fff;
    opacity: .6;
}

.hm-promo-carousel .carousel-indicators .active {
    width: 22px;
    border-radius: 999px;
    opacity: 1;
}

/* ---------- Collections ---------- */
/* collection switcher: every collection visible at once (wraps onto more lines, no scrolling) */
.hm-tabbar {
    margin-bottom: 26px;
}

.hm-tabs {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
}

/* sizes are 10% larger than the previous compact version */
.hm-tab {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 15px;
    border: 0;
    border-radius: 999px;
    font-size: 14.3px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    color: var(--hm-navy);
    background: var(--hm-chip);
    cursor: pointer;
    transition: background .2s, color .2s, box-shadow .2s;
}

.hm-tab span {
    min-width: 22px;
    padding: 1px 7px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    text-align: center;
    color: var(--hm-navy);
    background: #fff;
}

.hm-tab:hover {
    color: var(--hm-navy);
    background: #c8dbff;
}

.hm-tab.active {
    color: #fff;
    background: var(--hm-navy);
    box-shadow: 0 4px 10px rgba(23, 58, 117, .25);
}

.hm-tab.active span {
    color: var(--hm-navy);
    background: var(--hm-yellow);
}

.hm-products {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
}

.hm-product {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--hm-border);
    border-radius: 20px;
    color: var(--hm-text);
    background: #fff;
    text-decoration: none;
    transition: transform .2s, box-shadow .2s;
}

.hm-product:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 36px rgba(23, 58, 117, .12);
    color: var(--hm-text);
    text-decoration: none;
}

.hm-product-img {
    position: relative;
    display: block;
    aspect-ratio: 1 / 1;
    background: #fff;
}

.hm-product-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 12px;
    transition: transform .3s;
}

.hm-product:hover .hm-product-img img {
    transform: scale(1.04);
}

.hm-save {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    background: var(--hm-green);
}

.hm-product-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 14px 16px 16px;
    border-top: 1px solid #eef2f9;
}

.hm-product-name {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 15.5px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--hm-navy);
}

.hm-product-desc {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 13px;
    line-height: 1.5;
    color: var(--hm-muted);
}

.hm-price {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-top: auto;
    padding-top: 4px;
}

.hm-price b {
    font-size: 20px;
    color: var(--hm-navy);
}

.hm-price s {
    font-size: 14px;
    color: #9aa4b8;
}

.hm-product-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    color: #1c2430;
    background: var(--hm-yellow);
    transition: background .2s;
}

.hm-product:hover .hm-product-cta {
    background: #ffe04a;
}

.hm-more {
    margin-top: 28px;
    text-align: center;
}

/* ---------- Range tiles ---------- */
.hm-range {
    padding-top: 8px;
}

.hm-range-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}

.hm-range-tile {
    display: block;
    overflow: hidden;
    border-radius: 22px;
    aspect-ratio: 800 / 1280;
    background: var(--hm-chip);
}

.hm-range-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s;
}

.hm-range-tile:hover img {
    transform: scale(1.05);
}

/* ---------- Story ---------- */
.hm-story-card {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    overflow: hidden;
    border-radius: 28px;
    color: #fff;
    background:
        radial-gradient(circle at 100% 0%, rgba(255, 216, 18, .18), transparent 40%),
        linear-gradient(135deg, var(--hm-navy), var(--hm-blue));
}

.hm-story-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hm-story-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 44px 48px;
}

.hm-story-body h2 {
    color: #fff;
}

.hm-story-body h2 span {
    color: var(--hm-yellow);
}

.hm-story-body p {
    margin: 16px 0 26px;
    font-size: 16px;
    line-height: 1.75;
    color: rgba(255, 255, 255, .88);
}

.hm-story-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.hm-videos {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
    margin-top: 28px;
}

.hm-video {
    overflow: hidden;
    border: 1px solid var(--hm-border);
    border-radius: 18px;
    background: #fff;
}

.hm-video-frame {
    aspect-ratio: 16 / 9;
    background: #0d1f45;
}

.hm-video-frame iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
}

.hm-video p {
    margin: 0;
    padding: 12px 14px;
    font-size: 14px;
    font-weight: 600;
    color: var(--hm-navy);
}

/* ---------- Join CTA ---------- */
.hm-join {
    padding-top: 0;
}

.hm-join-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 40px 44px;
    border-radius: 24px;
    color: #fff;
    background:
        radial-gradient(circle at 0% 100%, rgba(255, 216, 18, .2), transparent 40%),
        linear-gradient(120deg, #0f2a57, var(--hm-navy-2));
}

.hm-join-text h2 {
    margin: 0 0 8px;
    font-size: 28px;
    font-weight: 700;
    color: #fff;
}

.hm-join-text p {
    max-width: 560px;
    margin: 0;
    font-size: 15px;
    line-height: 1.6;
    color: rgba(255, 255, 255, .85);
}

.hm-join-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    flex: 0 0 auto;
}

/* ---------- Responsive ---------- */
@media (max-width: 1199px) {
    .hm-cat-row > .hm-cat {
        flex-basis: calc((100% - 5 * 18px) / 6);
    }

    .hm-products {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 991px) {
    .hm-section {
        padding: 48px 0;
    }

    .hm-head h2,
    .hm-story-body h2 {
        font-size: 28px;
    }

    .hm-trust-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hm-cat-row > .hm-cat {
        flex-basis: calc((100% - 3 * 18px) / 4);
    }

    .hm-story-card {
        grid-template-columns: 1fr;
    }

    .hm-story-media img {
        aspect-ratio: 16 / 9;
        height: auto;
    }

    .hm-story-body {
        padding: 32px 28px;
    }

    .hm-join-card {
        flex-direction: column;
        align-items: flex-start;
        padding: 32px 28px;
    }
}

@media (max-width: 767px) {
    .hm-section {
        padding: 36px 0;
    }

    .hm-page .container {
        padding-left: 16px;
        padding-right: 16px;
    }

    .hm-head {
        margin-bottom: 18px;
    }

    .hm-head h2,
    .hm-story-body h2 {
        font-size: 24px;
    }

    .hm-trust {
        padding: 16px 0;
    }

    .hm-trust-row {
        gap: 12px;
    }

    .hm-trust-item {
        gap: 10px;
    }

    .hm-trust-item > i {
        flex-basis: 38px;
        width: 38px;
        height: 38px;
        font-size: 15px;
    }

    .hm-trust-item strong {
        font-size: 13.5px;
    }

    .hm-trust-item small {
        font-size: 11.5px;
    }

    .hm-cat-carousel {
        padding: 0 18px;
    }

    .hm-cat-row {
        gap: 10px;
    }

    .hm-cat-row > .hm-cat {
        flex-basis: calc((100% - 2 * 10px) / 3);
        padding: 14px 6px 12px;
    }

    .hm-cat-arrow {
        width: 34px;
        height: 34px;
        font-size: 12px;
    }

    .hm-cat-prev { left: -8px; }
    .hm-cat-next { right: -8px; }

    .hm-cat-img {
        width: 72px;
        height: 72px;
    }

    .hm-cat-name {
        font-size: 12.5px;
    }

    .hm-tabbar {
        margin-bottom: 18px;
    }


    .hm-promo-carousel {
        border-radius: 16px;
    }

    .hm-promo-carousel .carousel-control-prev,
    .hm-promo-carousel .carousel-control-next {
        display: none !important;
    }

    .hm-products {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .hm-product {
        border-radius: 16px;
    }

    .hm-product-img img {
        padding: 8px;
    }

    .hm-save {
        top: 8px;
        left: 8px;
        padding: 3px 8px;
        font-size: 11px;
    }

    .hm-product-body {
        gap: 4px;
        padding: 10px 10px 12px;
    }

    .hm-product-name {
        font-size: 14px;
    }

    .hm-product-desc {
        display: none;
    }

    .hm-price b {
        font-size: 17px;
    }

    .hm-price s {
        font-size: 12.5px;
    }

    .hm-product-cta {
        padding: 8px 10px;
        font-size: 13px;
    }

    .hm-product-cta i {
        display: none;
    }

    .hm-range-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }

    .hm-range-tile {
        border-radius: 16px;
    }

    .hm-story-card {
        border-radius: 20px;
    }

    .hm-story-body {
        padding: 26px 20px;
    }

    .hm-story-body p {
        font-size: 15px;
    }

    .hm-story-actions .hm-btn,
    .hm-join-actions .hm-btn {
        flex: 1 1 auto;
    }

    .hm-join-card {
        padding: 26px 20px;
        border-radius: 18px;
    }

    .hm-join-text h2 {
        font-size: 22px;
    }

    .hm-join-actions {
        width: 100%;
    }
}

/* ---------- Collection tabs: responsive grid (all collections always visible) ----------
   >= 992px : centred wrapping pills (desktop, see base rules)
   768-991  : 3-column grid (Bootstrap container is only 540px below 768)
   < 768    : 2-column grid
   < 400    : 2-column grid, compact text */
@media (max-width: 991px) {
    .hm-tabs {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
    }

    .hm-tab {
        justify-content: space-between;
        min-width: 0;
        padding: 9px 12px;
        border-radius: 12px;
        font-size: 14px;
        text-align: left;
        white-space: normal;
    }

    .hm-tab span {
        flex: 0 0 auto;
    }
}

@media (max-width: 767px) {
    .hm-tabs {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
    }

    .hm-tab {
        gap: 6px;
        padding: 8px 10px;
        font-size: 13.2px;
        line-height: 1.25;
    }

    .hm-tab span {
        min-width: 20px;
        padding: 1px 6px;
        font-size: 11.5px;
    }
}

@media (max-width: 399px) {
    .hm-tabs {
        gap: 5px;
    }

    .hm-tab {
        gap: 4px;
        padding: 7px 8px;
        border-radius: 10px;
        font-size: 12.2px;
        letter-spacing: -.1px;
    }

    .hm-tab span {
        min-width: 18px;
        padding: 1px 5px;
        font-size: 10.5px;
    }
}

/* ---------- "Perfected For Indian" product rails ---------- */
.hm-top {
    padding-top: 8px;
}

.hm-top-alt {
    padding-top: 0;
}

.hm-head-link {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 18px;
    border: 2px solid var(--hm-navy);
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    color: var(--hm-navy);
    text-decoration: none;
    transition: background .2s, color .2s;
}

.hm-head-link:hover {
    color: #fff;
    background: var(--hm-navy);
    text-decoration: none;
}

.hm-rail {
    position: relative;
    padding: 0 26px;
}

.hm-rail-track {
    display: flex;
    gap: 20px;
    padding: 6px 2px 16px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.hm-rail-track::-webkit-scrollbar {
    display: none;
}

.hm-rail-track:focus-visible {
    outline: 2px solid var(--hm-blue);
    outline-offset: 4px;
    border-radius: 16px;
}

/* 4 cards per view on desktop */
.hm-rail-track > .hm-product {
    flex: 0 0 calc((100% - 3 * 20px) / 4);
    scroll-snap-align: start;
}

.hm-rail-arrow {
    position: absolute;
    top: 40%;
    z-index: 2;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--hm-border);
    border-radius: 50%;
    font-size: 15px;
    color: var(--hm-navy);
    background: #fff;
    box-shadow: 0 8px 20px rgba(23, 58, 117, .16);
    transform: translateY(-50%);
    cursor: pointer;
    transition: background .2s, color .2s;
}

.hm-rail-arrow:hover {
    color: #fff;
    background: var(--hm-navy);
}

.hm-rail-prev { left: -4px; }
.hm-rail-next { right: -4px; }

.hm-rail.is-static {
    padding: 0;
}

.hm-rail.is-static .hm-rail-arrow {
    display: none;
}

@media (max-width: 1199px) {
    .hm-rail-track > .hm-product {
        flex-basis: calc((100% - 2 * 20px) / 3);
    }
}

@media (max-width: 767px) {
    .hm-head-link {
        padding: 7px 12px;
        font-size: 12.5px;
    }

    .hm-rail {
        padding: 0 16px;
    }

    .hm-rail-track {
        gap: 12px;
    }

    .hm-rail-track > .hm-product {
        flex-basis: calc((100% - 12px) / 2);
    }

    .hm-rail-arrow {
        width: 34px;
        height: 34px;
        font-size: 12px;
    }

    .hm-rail-prev { left: -10px; }
    .hm-rail-next { right: -10px; }
}
