/*
|--------------------------------------------------------------------------
| LearnerBox Header for WordPress
|--------------------------------------------------------------------------
| Isolated header styles for the LearnerBox Insights blog.
|--------------------------------------------------------------------------
*/

@import url(
    'https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap'
);


/* ==========================================
   Header variables
========================================== */

.lb-blog-header {
    --lb-primary: #273466;
    --lb-primary-dark: #1d274f;
    --lb-primary-light: #33427d;

    --lb-secondary: #e91e73;
    --lb-secondary-dark: #c5165d;

    --lb-accent: #57f20d;

    --lb-white: #ffffff;
    --lb-font: 'Poppins', Arial, sans-serif;

    --lb-transition: all 0.3s ease;

    position: sticky;
    top: 0;
    z-index: 100000;

    width: 100%;

    background-color: var(--lb-primary);
    color: var(--lb-white);

    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.12);

    font-family: var(--lb-font);

    overflow: visible;
}


/* WordPress admin toolbar offset */

body.admin-bar .lb-blog-header {
    top: 32px;
}

@media screen and (max-width: 782px) {

    body.admin-bar .lb-blog-header {
        top: 46px;
    }

}


/* ==========================================
   Header container
========================================== */

.lb-blog-header *,
.lb-blog-header *::before,
.lb-blog-header *::after {
    box-sizing: border-box;
}

.lb-blog-header a {
    text-decoration: none;
}

.lb-blog-header button {
    font-family: inherit;
}

.lb-blog-header .lb-header-container {
    width: 90%;
    max-width: 1200px;

    margin: 0 auto;
}

.lb-blog-header .lb-header-inner {
    min-height: 62px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    overflow: visible;
}


/* ==========================================
   Logo
========================================== */

.lb-blog-header .lb-logo-wrap {
    display: flex;
    align-items: center;
    gap: 12px;

    flex-shrink: 0;

    color: var(--lb-white);
}

.lb-blog-header .lb-logo-wrap:hover {
    color: var(--lb-white);
}

.lb-blog-header .lb-logo-wrap img {
    display: block;

    width: 48px;
    height: 42px;

    margin: 0;

    object-fit: contain;
}

.lb-blog-header .lb-logo-text {
    display: flex;
    flex-direction: column;

    line-height: 1.1;
}

.lb-blog-header .lb-logo-title {
    color: var(--lb-white);

    font-family: var(--lb-font);
    font-size: 1rem;
    font-weight: 700;
}

.lb-blog-header .lb-logo-subtitle {
    color: #dce3ff;

    font-family: var(--lb-font);
    font-size: 0.72rem;
    font-weight: 400;
}


/* ==========================================
   Desktop navigation
========================================== */

.lb-blog-header .lb-main-nav {
    display: flex;
    align-items: center;
    gap: 28px;

    overflow: visible;
}

.lb-blog-header .lb-main-nav > a,
.lb-blog-header .lb-dropdown-toggle {
    position: relative;

    display: inline-flex;
    align-items: center;

    height: 24px;

    margin: 0;
    padding: 0;

    background: transparent;
    border: none;

    color: var(--lb-white);

    font-family: var(--lb-font);
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1;

    cursor: pointer;

    appearance: none;
    -webkit-appearance: none;
}

.lb-blog-header .lb-main-nav > a:hover,
.lb-blog-header .lb-dropdown-toggle:hover {
    color: var(--lb-white);
}

.lb-blog-header .lb-main-nav > a::after,
.lb-blog-header .lb-dropdown-toggle::after {
    content: '';

    position: absolute;
    left: 0;
    bottom: -6px;

    width: 0;
    height: 2px;

    background-color: var(--lb-accent);

    transition: var(--lb-transition);
}

.lb-blog-header .lb-main-nav > a:hover::after,
.lb-blog-header .lb-dropdown:hover
.lb-dropdown-toggle::after,
.lb-blog-header .lb-dropdown:focus-within
.lb-dropdown-toggle::after {
    width: 100%;
}

.lb-blog-header .lb-main-nav > a.lb-active,
.lb-blog-header .lb-dropdown-toggle.lb-active {
    color: var(--lb-accent);
}


/* ==========================================
   Desktop dropdown
========================================== */

.lb-blog-header .lb-dropdown {
    position: relative;

    overflow: visible;
}

.lb-blog-header .lb-dropdown-toggle {
    gap: 6px;
}

.lb-blog-header .lb-dropdown-arrow {
    display: inline-block;

    transition: transform 0.25s ease;
}

.lb-blog-header .lb-dropdown-menu {
    position: absolute;
    top: calc(100% + 14px);
    left: 0;

    z-index: 100010;

    min-width: 360px;

    margin: 0;
    padding: 12px 0;

    background-color: var(--lb-primary);
    border:
        1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;

    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.25);

    opacity: 0;
    visibility: hidden;

    transform: translateY(10px);

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease,
        transform 0.25s ease;

    overflow: visible;
}

.lb-blog-header .lb-dropdown-menu a {
    display: flex;
    align-items: center;

    min-height: 42px;

    padding: 0 24px;

    color: var(--lb-white) !important;

    font-family: var(--lb-font);
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.4;

    white-space: nowrap;

    transition:
        background-color 0.25s ease,
        color 0.25s ease;
}

.lb-blog-header .lb-dropdown-menu a::after {
    display: none;
}

.lb-blog-header .lb-dropdown-menu a:hover,
.lb-blog-header .lb-dropdown-menu a.lb-active {
    background-color:
        rgba(255, 255, 255, 0.08);

    color: var(--lb-accent) !important;
}

.lb-blog-header .lb-dropdown:hover
.lb-dropdown-menu,
.lb-blog-header .lb-dropdown:focus-within
.lb-dropdown-menu,
.lb-blog-header .lb-dropdown.lb-open
.lb-dropdown-menu {
    opacity: 1;
    visibility: visible;

    transform: translateY(0);
}

.lb-blog-header .lb-dropdown.lb-open
.lb-dropdown-arrow {
    transform: rotate(180deg);
}


/* ==========================================
   Register/Login button
========================================== */

.lb-blog-header
.lb-main-nav > a.lb-header-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: auto;
    height: 24px;
    min-height: 0;

    margin-left: 8px;
    padding: 15px 26px;

    background-color: var(--lb-secondary);
    color: var(--lb-white) !important;

    border: none;
    border-radius: 10px;

    font-family: var(--lb-font);
    font-size: 0.85rem;
    font-weight: 400;
    line-height: 1;

    white-space: nowrap;

    transition: var(--lb-transition);
}

.lb-blog-header
.lb-main-nav > a.lb-header-cta:hover,
.lb-blog-header
.lb-main-nav > a.lb-header-cta:focus {
    background-color: var(--lb-secondary-dark);
    color: var(--lb-white) !important;

    transform: translateY(-2px);

    box-shadow:
        0 12px 30px rgba(0, 0, 0, 0.18);
}

.lb-blog-header
.lb-main-nav > a.lb-header-cta::after {
    display: none;
}



/* ==========================================
   Mobile menu button
========================================== */

.lb-blog-header .lb-mobile-menu-btn {
    display: none;

    margin: 0;
    padding: 5px;

    background: transparent;
    border: none;

    color: var(--lb-white);

    font-family: var(--lb-font);
    font-size: 1.8rem;
    line-height: 1;

    cursor: pointer;
}


/* ==========================================
   Tablet and mobile navigation
========================================== */

@media (max-width: 768px) {

    .lb-blog-header .lb-header-container {
        width: 92%;
    }

    .lb-blog-header .lb-header-inner {
        position: relative;

        min-height: 64px;
    }

    .lb-blog-header .lb-logo-wrap {
        max-width: 220px;

        gap: 10px;
    }

    .lb-blog-header .lb-logo-wrap img {
        width: 42px;
        height: 42px;
    }

    .lb-blog-header .lb-logo-title {
        font-size: 0.95rem;
        line-height: 1;
    }

    .lb-blog-header .lb-logo-subtitle {
        font-size: 0.68rem;
        line-height: 1;
    }

    .lb-blog-header .lb-mobile-menu-btn {
        position: relative;
        z-index: 100021;

        display: block;

        margin-left: auto;
    }

    .lb-blog-header .lb-main-nav {
        position: absolute;
        top: 64px;
        left: 0;

        z-index: 100020;

        display: none;
        flex-direction: column;
        align-items: flex-start;

        width: 100%;

        padding: 22px 5%;

        gap: 8px;

        background-color:
            var(--lb-primary-dark);

        box-shadow:
            0 14px 28px
            rgba(0, 0, 0, 0.18);

        overflow: visible;
    }

    .lb-blog-header .lb-main-nav.lb-active {
        display: flex;
    }

    .lb-blog-header .lb-main-nav > a,
    .lb-blog-header .lb-dropdown-toggle {
        display: flex;
        align-items: center;

        width: 100%;
        height: auto;
        min-height: 44px;

        font-size: 1rem;
        line-height: 1.3;
    }

    .lb-blog-header .lb-main-nav > a::after,
    .lb-blog-header .lb-dropdown-toggle::after {
        display: none;
    }

    .lb-blog-header .lb-dropdown {
        width: 100%;
    }

    .lb-blog-header .lb-dropdown-toggle {
        justify-content: space-between;

        text-align: left;
    }

    .lb-blog-header .lb-dropdown.lb-open
    .lb-dropdown-arrow {
        transform: rotate(180deg);
    }

    .lb-blog-header .lb-dropdown-menu {
        position: static;

        display: block;

        width: 100%;
        min-width: 100%;
        max-height: 0;

        margin-top: 0;
        padding: 0;

        background-color:
            rgba(255, 255, 255, 0.05);

        border: none;
        border-radius: 8px;

        box-shadow: none;

        opacity: 1;
        visibility: visible;

        transform: none;

        overflow: hidden;

        transition:
            max-height 0.3s ease,
            padding 0.3s ease,
            margin-top 0.3s ease;
    }

    .lb-blog-header .lb-dropdown.lb-open
    .lb-dropdown-menu {
        max-height: 520px;

        margin-top: 8px;
        padding: 6px 0;
    }

    .lb-blog-header .lb-dropdown:hover
    .lb-dropdown-menu,
    .lb-blog-header .lb-dropdown:focus-within
    .lb-dropdown-menu {
        transform: none;
    }

    .lb-blog-header .lb-dropdown-menu a {
        display: flex;
        align-items: center;

        width: 100%;
        min-height: 42px;

        padding: 10px 18px;

        color: var(--lb-white) !important;

        font-size: 0.95rem;

        white-space: normal;
    }

    .lb-blog-header .lb-dropdown-menu a:hover,
    .lb-blog-header .lb-dropdown-menu a.lb-active {
        background-color:
            rgba(255, 255, 255, 0.08);

        color: var(--lb-accent) !important;
    }

    .lb-blog-header .lb-main-nav > a.lb-header-cta {
    width: 100%;

    margin-left: 0;
    margin-top: 6px;

    justify-content: center;

    background-color: var(--lb-secondary);
    color: var(--lb-white) !important;

    border-radius: 10px;
    padding: 12px 20px;
}

}


/* ==========================================
   Small phones
========================================== */

@media (max-width: 480px) {

    .lb-blog-header .lb-logo-wrap {
        max-width: 210px;
    }

    .lb-blog-header .lb-logo-title {
        font-size: 0.9rem;
    }

    .lb-blog-header .lb-logo-subtitle {
        font-size: 0.64rem;
    }

}


/* ==========================================
   Accessibility
========================================== */

.lb-blog-header a:focus-visible,
.lb-blog-header button:focus-visible {
    outline:
        3px solid rgba(87, 242, 13, 0.65);

    outline-offset: 3px;
}


/* ==========================================
   Reduced motion
========================================== */

@media (prefers-reduced-motion: reduce) {

    .lb-blog-header *,
    .lb-blog-header *::before,
    .lb-blog-header *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

}