/**
 * Homepage Styles
 * Homepage style file
 */

:root {
    --co-bg: #f3f7ff;
    --co-text: #0f172a;
    --co-muted: rgba(15, 23, 42, 0.65);
    --co-border: rgba(15, 23, 42, 0.08);
    --co-card: #ffffff;
    --co-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
    --co-radius-lg: 24px;
    --co-radius-md: 18px;
    --co-radius-sm: 14px;
}

/* =========================================================
   Storefront overrides (front page only)
   - Remove default header/nav/slogan/menus
   - Make content full-width like prototype
   ========================================================= */
body.home .site-header,
body.home .storefront-primary-navigation,
body.home .woocommerce-breadcrumb,
body.home .storefront-breadcrumb,
body.home .site-footer {
    display: none !important;
}

/* Hide Storefront skip-link spacing on front page */
body.home a.skip-link {
    display: none !important;
}

body.home #page,
body.home #content,
body.home .site-content,
body.home .site-content .col-full {
    max-width: none !important;
    width: 100% !important;
}

body.home .site-content {
    padding-top: 0 !important;
}

body.home .site-content .col-full {
    margin: 0 !important;
    padding: 0 !important;
}

.co-home {
    margin: 0;
}

.co-home {
    background: var(--co-bg);
    padding-bottom: 56px;
}

.co-home__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Topbar */
.co-home__topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(243, 247, 255, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.co-home__topbarInner {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 0;
}

.co-home__brand {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.co-home__brandLogo {
    height: 28px;
    width: auto;
    display: block;
}

.co-home__nav {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 0 0 auto;
    overflow: auto hidden;
    padding: 2px 2px;
    scrollbar-width: none;
}

.co-home__nav::-webkit-scrollbar {
    height: 0;
}

.co-home__navLink {
    display: inline-flex;
    align-items: center;
    height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: rgba(255, 255, 255, 0.85);
    color: rgba(15, 23, 42, 0.78);
    text-decoration: none;
    font-weight: 900;
    font-size: 13px;
    white-space: nowrap;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
    transition: transform 160ms ease, background 160ms ease, color 160ms ease;
}

.co-home__navLink:hover {
    background: #ffffff;
    color: var(--co-text);
    transform: translateY(-1px);
}

.co-home__navLink.is-active {
    background: rgba(255, 255, 255, 0.96);
    color: var(--co-text);
    border-color: rgba(15, 23, 42, 0.12);
}

.co-home__search {
    flex: 1;
    min-width: 220px;
}

.co-home__search form {
    position: relative;
    margin: 0;
}

.co-home__search input[type="search"] {
    width: 100%;
    height: 40px;
    border-radius: 999px;
    border: 1px solid var(--co-border);
    padding: 0 46px 0 16px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06);
    color: var(--co-text);
}

.co-home__search button[type="submit"],
.co-home__search input[type="submit"] {
    position: absolute;
    top: 50%;
    right: 6px;
    transform: translateY(-50%);
    height: 30px;
    width: 36px;
    padding: 0;
    border-radius: 999px;
    border: 1px solid rgba(15, 23, 42, 0.06);
    background: #ffffff;
    text-indent: -9999px;
    overflow: hidden;
}

.co-home__search button[type="submit"]::after,
.co-home__search input[type="submit"]::after {
    content: "⌕";
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    text-indent: 0;
    font-size: 14px;
    color: rgba(15, 23, 42, 0.75);
}

.co-home__icons {
    display: flex;
    align-items: center;
    gap: 10px;
}

.co-home__iconBtn {
    height: 34px;
    width: 34px;
    padding: 0;
    border-radius: 10px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.co-home__iconBtn img,
.co-home__badge img {
    height: 18px;
    width: auto;
    display: block;
}

.co-home__badge {
    height: 34px;
    padding: 0 10px;
    border-radius: 999px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: rgba(255, 255, 255, 0.95);
    display: inline-flex;
    align-items: center;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

/* Hero */
.co-home__hero {
    padding: 18px 0 12px;
}

.co-home__heroBanner {
    position: relative;
    border-radius: var(--co-radius-lg);
    overflow: hidden;
    box-shadow: var(--co-shadow);
    background: #ffffff;
}

.co-home__heroImg {
    width: 100%;
    height: auto;
    display: block;
}

/* Clickable hotspots for embedded CTA text in banner */
.co-home__heroHotspot {
    position: absolute;
    display: block;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.01);
    border: 0;
}

.co-home__heroHotspot:focus-visible {
    outline: 3px solid rgba(59, 130, 246, 0.9);
    outline-offset: 2px;
}

/* These percentages match the Web1x banner (1440x400) */
.co-home__heroHotspot--shopNow {
    left: 10.2%;
    top: 62.5%;
    width: 11.8%;
    height: 12.0%;
}

.co-home__heroHotspot--offerDetails {
    left: 23.0%;
    top: 62.5%;
    width: 14.0%;
    height: 12.0%;
}

/* Sections */
.co-home__section {
    padding: 22px 0;
}

.co-home__sectionHead {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin: 8px 0 14px;
}

.co-home__sectionTitle {
    margin: 0;
    font-size: 18px;
    letter-spacing: 0.08em;
    font-weight: 900;
    color: var(--co-text);
}

.co-home__viewAll {
    text-decoration: none;
    color: rgba(15, 23, 42, 0.7);
    font-weight: 700;
    font-size: 13px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    background: rgba(255, 255, 255, 0.75);
}

.co-home__viewAll:hover {
    background: #ffffff;
    color: var(--co-text);
}

.co-home__viewAllImg {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 34px;
    width: 120px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(15, 23, 42, 0.12);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05);
    text-decoration: none;
}

.co-home__viewAllImg img {
    height: 34px;
    width: 120px;
    display: block;
}

/* Process */
.co-home__processMedia {
    border-radius: var(--co-radius-lg);
    overflow: hidden;
    box-shadow: var(--co-shadow);
}

.co-home__processImg {
    width: 100%;
    height: auto;
    display: block;
}

/* Category */
.co-home__categoryGrid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 14px;
}

.co-home__categoryCard {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px 12px;
    border-radius: var(--co-radius-md);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(15, 23, 42, 0.08);
    text-decoration: none;
    color: var(--co-text);
    box-shadow: 0 12px 22px rgba(15, 23, 42, 0.06);
    transition: transform 160ms ease, box-shadow 160ms ease;
}

.co-home__categoryCard:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.12);
}

.co-home__categoryThumb {
    border-radius: 14px;
    overflow: hidden;
    background: rgba(15, 23, 42, 0.04);
    aspect-ratio: 1 / 1;
    display: block;
}

.co-home__categoryThumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.co-home__categoryName {
    font-weight: 800;
    font-size: 13px;
    line-height: 1.2;
}

/* Products (Woo) */
.co-home__products .woocommerce {
    margin: 0;
}

.co-home__products ul.products {
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.co-home__products ul.products li.product {
    margin: 0 !important;
    padding: 14px !important;
    border-radius: var(--co-radius-md);
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: 0 12px 22px rgba(15, 23, 42, 0.06);
}

.co-home__products ul.products li.product a {
    text-decoration: none;
}

.co-home__products ul.products li.product img {
    border-radius: 14px;
    overflow: hidden;
}

.co-home__products ul.products li.product .woocommerce-loop-product__title {
    font-size: 14px;
    font-weight: 800;
    color: var(--co-text);
    margin: 10px 0 6px !important;
}

.co-home__products ul.products li.product .price {
    color: rgba(15, 23, 42, 0.75) !important;
    font-weight: 800;
}

/* Deal banner */
.co-home__dealBanner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-radius: var(--co-radius-lg);
    padding: 22px;
    background: linear-gradient(135deg, #3aa9ff 0%, #6aa7ff 40%, #f7c1d1 100%);
    box-shadow: var(--co-shadow);
    margin: 8px 0 18px;
}

.co-home__dealText {
    color: #ffffff;
    text-shadow: 0 10px 28px rgba(15, 23, 42, 0.25);
}

.co-home__dealKicker {
    font-weight: 900;
    letter-spacing: 0.08em;
    font-size: 14px;
    opacity: 0.95;
}

.co-home__dealTitle {
    font-weight: 1000;
    font-size: 28px;
    margin-top: 6px;
    letter-spacing: 0.06em;
}

.co-home__dealBtn {
    display: inline-flex;
    margin-top: 12px;
    padding: 10px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.96);
    color: var(--co-text);
    font-weight: 900;
    text-decoration: none;
    border: 1px solid rgba(15, 23, 42, 0.12);
}

/* Feature cards */
.co-home__featureGrid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.co-home__featureCard {
    position: relative;
    border-radius: var(--co-radius-md);
    overflow: hidden;
    text-decoration: none;
    box-shadow: 0 12px 22px rgba(15, 23, 42, 0.06);
    border: 1px solid rgba(15, 23, 42, 0.06);
    background: #ffffff;
    min-height: 120px;
    transform: translateY(0);
    transition: transform 160ms ease, box-shadow 160ms ease;
}

.co-home__featureBg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.co-home__featureText {
    position: absolute;
    left: 16px;
    top: 16px;
    right: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.co-home__featureCard.is-visible {
    animation: coFadeUp 420ms ease both;
}

.co-home__categoryCard.is-hover,
.co-home__featureCard.is-hover,
.co-home__commentCard.is-hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(15, 23, 42, 0.12);
}

@keyframes coFadeUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.co-home__featureTitle {
    font-weight: 900;
    color: var(--co-text);
    font-size: 14px;
}

.co-home__featureDesc {
    color: var(--co-muted);
    font-size: 12px;
    line-height: 1.35;
}

/* Comments */
.co-home__commentGrid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.co-home__commentCard {
    border-radius: var(--co-radius-md);
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: 0 12px 22px rgba(15, 23, 42, 0.06);
    padding: 14px 14px 16px;
}

.co-home__commentHead {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.co-home__commentAuthor {
    font-weight: 900;
    font-size: 13px;
    color: var(--co-text);
}

.co-home__commentBody {
    color: rgba(15, 23, 42, 0.8);
    font-size: 13px;
    line-height: 1.55;
}

.co-home__empty {
    padding: 14px 0;
    color: var(--co-muted);
}

/* Footer */
.co-home__footer {
    padding-top: 26px;
}

.co-home__footerInner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-radius: var(--co-radius-lg);
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(15, 23, 42, 0.06);
    padding: 16px 18px;
    box-shadow: 0 12px 22px rgba(15, 23, 42, 0.06);
}

.co-home__footerLogo {
    height: 24px;
    width: auto;
    display: block;
}

.co-home__footerSocial {
    display: flex;
    gap: 10px;
    align-items: center;
}

.co-home__socialLink {
    height: 34px;
    width: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
}

.co-home__socialLink img {
    height: 18px;
    width: auto;
    display: block;
}

/* Responsive */
@media (max-width: 1024px) {
    .co-home__categoryGrid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .co-home__featureGrid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .co-home__topbarInner {
        flex-wrap: wrap;
    }

    .co-home__nav {
        order: 2;
        width: 100%;
        padding-bottom: 6px;
    }

    .co-home__search {
        order: 3;
        width: 100%;
    }

    .co-home__products ul.products {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .co-home__commentGrid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .co-home__products ul.products {
        grid-template-columns: 1fr;
    }

    .co-home__commentGrid {
        grid-template-columns: 1fr;
    }

    .co-home__categoryGrid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
