/* Front page: hide hero/page-title section completely */
.home .hero-section {
    display: none !important;
    height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
}
.home .entry-header {
    display: none !important;
}

/* Front page: hide comments section */
.home .ct-comments-container,
.home #comments,
.home #respond {
    display: none !important;
}


/* 2. "Alive" Category Cards (Home) */
.home .wp-block-group[style*="border-radius"] {
    overflow: hidden !important; 
    position: relative;
    display: block;
}

/* Add a subtle gradient overlay for text legibility */
.home .wp-block-group[style*="border-radius"]::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60%;
    background: linear-gradient(to top, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0) 100%);
    pointer-events: none;
    z-index: 1;
    transition: opacity 0.3s ease;
}

.home .wp-block-group[style*="border-radius"] img {
    transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1) !important;
    width: 100%;
}

.home .wp-block-group[style*="border-radius"]:hover img {
    transform: scale(1.12);
}

.home .wp-block-group[style*="border-radius"] .wp-block-heading {
    position: relative;
    z-index: 2; /* Sit above the gradient */
}

.home .wp-block-group[style*="border-radius"] .wp-block-heading a {
    color: #fff !important;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
    transition: transform 0.3s ease;
}

.home .wp-block-group[style*="border-radius"]:hover .wp-block-heading a {
    transform: translateY(-5px);
}


/* ==========================================================================
   Business Badges (Ideal for...) & Trust Signals
   ========================================================================== */

.mg-business-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 15px 0 20px;
    font-size: 14px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.mg-business-tags__label {
    color: var(--theme-palette-color-4);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
}

.mg-business-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f8f6fb;
    color: var(--theme-palette-color-1);
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid rgba(82, 4, 125, 0.08);
}

.mg-business-tag:hover {
    background: var(--theme-palette-color-1);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(82, 4, 125, 0.15);
}

.mg-business-tag svg {
    opacity: 0.8;
}

/* Home: Equipa tu Negocio Section */
.mg-equipa-negocio {
    max-width: 1200px;
    margin: 80px auto;
    padding: 0 20px;
}

.mg-equipa-negocio__title {
    text-align: center;
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 10px;
    color: var(--theme-palette-color-4);
}

.mg-equipa-negocio__subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 40px;
    font-size: 16px;
}

.mg-equipa-negocio__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
}

.mg-equipa-card {
    background: #fff;
    border: 1px solid rgba(0,0,0,0.06);
    border-radius: 16px;
    padding: 30px 20px;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mg-equipa-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(82, 4, 125, 0.1);
    border-color: var(--theme-palette-color-1);
}

.mg-equipa-card__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    margin: 0 auto 15px;
    background: #f8f6fb;
    color: var(--theme-palette-color-1);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.mg-equipa-card:hover .mg-equipa-card__icon {
    background: var(--theme-palette-color-1);
    color: #fff;
    transform: rotate(5deg) scale(1.1);
}

.mg-equipa-card__name {
    display: block;
    font-size: 17px;
    font-weight: 700;
    color: var(--theme-palette-color-4);
    margin-bottom: 5px;
}

.mg-equipa-card__count {
    font-size: 13px;
    color: #888;
}

@media (max-width: 768px) {
    .mg-equipa-negocio { margin: 50px auto; }
    .mg-equipa-negocio__grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .mg-equipa-card { padding: 20px 10px; }
}

/* ==========================================================================
   End of Premium Enhancements
   ========================================================================== */


/* ==========================================================================
   Homepage Redesign: Layout Overrides
   Kill Blocksy's 60px content-vertical-spacing on the homepage
   and remove WP block content-spacing between homepage sections
   ========================================================================== */
.home .ct-container-full {
    --theme-content-vertical-spacing: 0px;
}

.home .entry-content.is-layout-constrained > * {
    margin-block-start: 0;
}

@media (max-width: 768px) {
    body.home #main > .ct-container-full,
    body.home #main-container > .ct-container-full {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }

    body.home #main #post-9,
    body.home #post-9 {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
}

/* Make wp:html blocks (pills, trust strip, WhatsApp CTA) full-width — DESKTOP ONLY.
   calc(-50vw + 50%) causes horizontal overflow on mobile. */
@media (min-width: 769px) {
    .home .entry-content.is-layout-constrained > .mg-cat-pills,
    .home .entry-content.is-layout-constrained > .mg-trust-strip,
    .home .entry-content.is-layout-constrained > .mg-whatsapp-cta {
        max-width: none !important;
        margin-left: calc(-50vw + 50%) !important;
        margin-right: calc(-50vw + 50%) !important;
        width: 100vw;
    }
}

/* Mobile: full-width without the calc trick */
@media (max-width: 768px) {
    .home .entry-content.is-layout-constrained > .mg-cat-pills,
    .home .entry-content.is-layout-constrained > .mg-trust-strip,
    .home .entry-content.is-layout-constrained > .mg-whatsapp-cta {
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100%;
    }
}

/* Prevent any horizontal overflow on home */
body.home,
body.home .site-main,
body.home .entry-content {
    overflow-x: clip;
}

/* ==========================================================================
   Homepage Redesign: Category Pills
   ========================================================================== */
.mg-cat-pills {
    background: #fff;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    padding: 12px 0;
}

.mg-cat-pills__inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 4px 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.mg-cat-pills__inner::-webkit-scrollbar {
    display: none;
}

.mg-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.7);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    color: #333;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s ease;
    border: 1px solid rgba(82, 4, 125, 0.1);
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}

.mg-pill:hover {
    background: var(--theme-palette-color-1, #490D78);
    color: #fff;
    border-color: var(--theme-palette-color-1, #490D78);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(82, 4, 125, 0.2);
}

.mg-pill--shop {
    background: #fff !important;
    color: #333 !important;
    border-color: rgba(82, 4, 125, 0.1) !important;
}

.mg-pill--shop:hover {
    background: var(--theme-palette-color-1, #490D78) !important;
    color: #fff !important;
    border-color: var(--theme-palette-color-1, #490D78) !important;
}

@media (max-width: 768px) {
    .mg-cat-pills__inner {
        justify-content: center;
        flex-wrap: wrap;
        gap: 8px;
        padding: 0 12px;
        overflow-x: visible;
    }
    .mg-pill {
        font-size: 12px;
        padding: 6px 12px;
    }
}

/* ==========================================================================
   Homepage Redesign: Section Headers
   ========================================================================== */
.mg-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto 16px;
    padding: 0 16px;
}

.mg-section-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--theme-palette-color-4, #1a1a2e);
    margin: 0;
}

.mg-section-link {
    font-size: 14px;
    font-weight: 600;
    color: var(--theme-palette-color-1, #490D78);
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.2s;
}

.mg-section-link:hover {
    color: var(--theme-palette-color-3, #d69942);
}

@media (max-width: 768px) {
    .mg-section-title {
        font-size: 18px;
    }
    .mg-section-link {
        font-size: 13px;
    }
}

/* ==========================================================================
   Homepage Redesign: Trust Strip (compact)
   ========================================================================== */
.mg-trust-strip {
    background: #faf8fc;
    padding: 24px 16px;
    border-top: 1px solid rgba(82, 4, 125, 0.06);
    border-bottom: 1px solid rgba(82, 4, 125, 0.06);
}

.mg-trust-strip__inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.mg-trust-strip__item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #444;
}

.mg-trust-strip__icon {
    font-size: 22px;
}

@media (max-width: 768px) {
    .mg-trust-strip__inner {
        gap: 16px 24px;
        justify-content: center;
    }
    .mg-trust-strip__item {
        font-size: 13px;
    }
}

/* ==========================================================================
   Homepage Redesign: WhatsApp CTA
   ========================================================================== */
.mg-whatsapp-cta {
    background: linear-gradient(120deg, #2f0a49 0%, #490D78 55%, #7931a9 100%);
    color: #fff;
    padding: 32px 16px;
}

.mg-whatsapp-cta__inner {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    text-align: center;
    flex-wrap: wrap;
}

.mg-whatsapp-cta__text {
    font-size: 16px;
    line-height: 1.5;
}

.mg-whatsapp-cta__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 14px 28px;
    border-radius: 999px;
    background: #25d366;
    color: #0f301f;
    font-weight: 700;
    font-size: 15px;
    text-decoration: none;
    transition: background 0.2s, transform 0.2s;
    white-space: nowrap;
}

.mg-whatsapp-cta__btn:hover {
    background: #1db455;
    transform: translateY(-2px);
    color: #082011;
}
