/* ==========================================================================
   Unbranded Digital — Custom Header
   Clean custom-coded header, no Astra Header Builder dependency
   v3.0.2
   ========================================================================== */

/* --- Hide Astra's header completely --- */
#masthead {
    display: none !important;
}

/* --- Header base --- */
#ud-header {
    z-index: 999;
    position: relative;
}

.ud-header-pad {
    padding: 12px 20px;
    max-width: 1240px;
    margin: 0 auto;
}

.ud-header-card {
    background: #FFFFFF;
    border-radius: 16px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.ud-header-bar {
    display: flex;
    align-items: center;
    padding: 10px 20px;
    gap: 16px;
}

/* --- Logo --- */
.ud-logo {
    text-decoration: none;
    flex-shrink: 0;
}

.ud-logo img {
    max-height: 50px;
    width: auto;
    display: block;
    transition: opacity 0.3s ease;
}

.ud-logo .ud-site-title {
    font-size: 18px;
    font-weight: 700;
    color: #212252;
}

/* --- Desktop nav pill --- */
.ud-nav-desktop {
    flex: 1;
    display: flex;
    justify-content: center;
}

.ud-nav-pill {
    border-radius: 50px;
    padding: 0 10px;
    height: 50px;
    display: flex;
    align-items: center;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06);
}

.ud-nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
}

.ud-nav-list li {
    display: flex;
    align-items: center;
}

.ud-nav-list li a {
    color: #212252;
    font-weight: 400;
    font-size: 14px;
    text-decoration: none;
    padding: 0 12px;
    line-height: 50px;
    height: 50px;
    display: block;
    transition: color 0.3s ease;
    white-space: nowrap;
}

.ud-nav-list li a:hover {
    color: #0565FF;
}

/* --- Right side: CTA + cart --- */
.ud-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.ud-cta-btn {
    background-color: #0565FF;
    color: #FFFFFF !important;
    border: none;
    border-radius: 60px;
    padding: 12px 32px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color 0.3s ease, transform 0.2s ease;
    display: inline-block;
}

.ud-cta-btn:hover {
    background-color: #0450CC;
    transform: translateY(-1px);
    color: #FFFFFF !important;
}

.ud-cart-icon {
    color: #212252;
    text-decoration: none;
    display: flex;
    align-items: center;
    position: relative;
    padding: 8px;
    transition: color 0.3s ease;
}

.ud-cart-icon:hover {
    color: #0565FF;
}

.ud-cart-icon svg {
    display: block;
}

.ud-cart-count {
    position: absolute;
    top: 0;
    right: 0;
    background: #0565FF;
    color: #FFF;
    font-size: 10px;
    font-weight: 700;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* --- Mobile controls (hidden on desktop) --- */
.ud-mobile-right {
    display: none;
}

/* --- Mobile dropdown (hidden by default) --- */
.ud-mobile-dropdown {
    display: none;
    padding: 8px 16px 16px;
    border-top: 1px solid #f0f0f5;
}

.ud-mobile-nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.ud-mobile-nav-list li a {
    color: #212252;
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
    display: block;
    padding: 10px 0;
    transition: color 0.3s ease;
}

.ud-mobile-nav-list li a:hover {
    color: #0565FF;
}

.ud-mobile-cart {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #212252;
    text-decoration: none;
    padding: 10px 0;
    font-size: 15px;
    font-weight: 500;
    border-top: 1px solid #f0f0f5;
    margin-top: 4px;
}

.ud-mobile-cart:hover {
    color: #0565FF;
}

.ud-mobile-cart svg {
    display: block;
    flex-shrink: 0;
}

/* --- Hamburger icon --- */
.ud-hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    padding: 8px;
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
    outline: none !important;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.05);
    -webkit-appearance: none;
    appearance: none;
    position: relative;
    z-index: 10;
}

.ud-hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: #212252;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Hamburger to X animation when menu is open */
#ud-header.ud-menu-open .ud-hamburger span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
#ud-header.ud-menu-open .ud-hamburger span:nth-child(2) {
    opacity: 0;
}
#ud-header.ud-menu-open .ud-hamburger span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* --- Sticky state --- */
#ud-header.ud-sticky {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    background: #edf1f7;
    animation: udSlideDown 0.4s ease forwards;
}

.admin-bar #ud-header.ud-sticky {
    top: 32px;
}

@keyframes udSlideDown {
    from { transform: translateY(-100%); }
    to   { transform: translateY(0); }
}

.ud-header-spacer {
    display: none;
}
.ud-header-spacer.active {
    display: block;
}

#ud-header.ud-sticky .ud-header-card {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}


/* ===== Mobile (max-width: 921px) ===== */
@media (max-width: 921px) {
    .ud-header-pad {
        padding: 8px 12px;
    }

    .ud-header-bar {
        padding: 8px 12px;
    }

    .ud-header-card {
        border-radius: 12px;
    }

    /* Hide desktop nav and CTA */
    .ud-nav-desktop,
    .ud-header-right {
        display: none !important;
    }

    /* Show mobile controls */
    .ud-mobile-right {
        display: flex;
        align-items: center;
        gap: 4px;
        margin-left: auto;
    }

    /* Logo smaller on mobile */
    .ud-logo img {
        max-height: 40px;
    }

    /* Mobile connect phone icon */
    .ud-mob-connect {
        display: block;
        width: 34px;
        height: 34px;
        min-width: 34px;
        background-color: #0565FF;
        border-radius: 50%;
        text-decoration: none;
        text-indent: -9999px;
        overflow: hidden;
        transition: background-color 0.3s ease;
        flex-shrink: 0;
        background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23FFFFFF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E");
        background-repeat: no-repeat;
        background-position: center;
        background-size: 16px 16px;
    }

    .ud-mob-connect:hover,
    .ud-mob-connect:focus {
        background-color: #0450CC;
    }

    /* Admin bar offset */
    .admin-bar #ud-header.ud-sticky {
        top: 46px;
    }
}

/* Mobile connect button hidden on desktop (no media query fallback) */
@media (min-width: 922px) {
    .ud-mob-connect {
        display: none !important;
    }
}


/* ==========================================================================
   Reviews Section (Above Footer)
   Dark navy background, branded heading
   Widget styling handled entirely by Trustindex shortcode
   ========================================================================== */

.site-above-footer-wrap {
    padding: 60px 0 40px !important;
}

.ud-reviews-header {
    text-align: center;
    margin-bottom: 32px;
}

.ud-reviews-header h2 {
    color: #FFFFFF !important;
    font-size: 32px;
    font-weight: 700;
    margin: 0 0 12px;
    line-height: 1.3;
}

.ud-reviews-header p {
    color: rgba(255, 255, 255, 0.7) !important;
    font-size: 16px;
    font-weight: 400;
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.6;
}

@media (max-width: 921px) {
    .site-above-footer-wrap {
        padding: 40px 0 30px !important;
    }
    .ud-reviews-header h2 {
        font-size: 26px;
    }
    .ud-reviews-header p {
        font-size: 15px;
        padding: 0 20px;
    }
}
