/* ==========================================================================
   HERO HEADER, NAVIGATION & LANGUAGE SELECTOR
   ========================================================================== */
.hero-carousel-header {
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 500;
    border-bottom: 4px solid var(--kliq-main);
    display: flex;
    align-items: flex-start;
    transition: padding 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.3s ease,
                min-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: padding, min-height;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    min-height: 120px;
    background-color: white;
}

/* Background Layer */
.header-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;    
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    overflow: hidden;
}

.header-background picture {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.header-background picture img {
    width: 50%;
    height: auto;
    object-fit: contain;
    object-position: center;
    margin: auto;
}

/* Floating Overlay Content Structure */
.header-content-overlay {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    height: 100%;
    padding: 0;
    box-sizing: border-box;
    pointer-events: none;
}

.header-top-bar,
.header-main-content,
.hero-hero-tagline,
.lang-dropdown {
    pointer-events: auto;
}

/* Logo (Absolute Top-Left) */
.logo-wrapper {
    position: absolute;
    top: 2px;
    left: 2px;
    z-index: 20;
    flex-shrink: 0;
    margin: 0;
    padding: 0;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.logo-wrapper img.logo {
    display: block;
    height: auto;
    max-height: 100px;
    width: auto;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.08));
    transition: height 0.3s cubic-bezier(0.4, 0, 0.2, 1), transform 0.3s ease, filter 0.3s ease;
}

.logo-wrapper img.logo:hover {
    transform: scale(1.04) rotate(-1.5deg);
    filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.15));
}

/* ==========================================================================
   LANGUAGE DROPDOWN SELECTOR (ABSOLUTE TOP-RIGHT)
   ========================================================================== */
.lang-dropdown {
    position: absolute;
    top: 2px;
    right: 2px;
    z-index: 700;
    margin: 0;
    padding: 0;
}

.lang-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background-color: var(--kliq-scoreboard-bg);
    color: var(--kliq-white);
    border: 2px solid var(--kliq-main);
    border-radius: 6px;
    padding: 2px 8px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    line-height: 1.2;
}

.lang-btn:hover {
    border-color: var(--kliq-alert);
    box-shadow: 0 0 8px rgba(247, 193, 7, 0.4);
}

.chevron {
    color: var(--kliq-main);
    font-size: 0.7rem;
    transition: transform 0.2s ease;
}

.lang-dropdown.open .chevron {
    transform: rotate(180deg);
}

.lang-menu {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    background-color: var(--kliq-scoreboard-bg);
    border: 2px solid var(--kliq-main);
    border-radius: 8px;
    list-style: none;
    padding: 6px 0;
    min-width: 140px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

.lang-dropdown.open .lang-menu {
    display: block;
}

.lang-menu li a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    color: var(--kliq-white);
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    transition: background 0.15s ease, color 0.15s ease;
}

.lang-menu li a:hover,
.lang-menu li a.active {
    background-color: var(--kliq-main);
    color: var(--kliq-text);
}

/* ==========================================================================
   TOP-CENTERED PRODUCT ANNOUNCEMENT HEADER
   ========================================================================== */
.hero-hero-tagline {
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    width: max-content;
    max-width: calc(100% - 280px);
    z-index: 15;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
}

.hero-hero-tagline h1 {
    color: var(--kliq-main, #F7C107);
    font-size: 1.5rem; /* BUMPED UP from 1.25rem */
    font-weight: 900;
    line-height: 1.15;
    margin: 0 0 2px 0;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    -webkit-text-stroke: 1px var(--kliq-accent, #1B7170);
}

.hero-hero-tagline .tagline {
    font-size: 1rem; /* BUMPED UP from 0.82rem */
    line-height: 1.2;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    margin: 0;
    color: #ffffff;
    font-weight: 900; /* MAX WEIGHT (already set to heavy, ensure font family supports 900) */
    letter-spacing: 0.4px;
    /* Increased stroke slightly to 1px so it stays proportional with larger font size */
    -webkit-text-stroke: 1px var(--kliq-accent, #1B7170);
}

.hero-hero-tagline .tagline strong {
    color: #ffffff;
    font-weight: inherit; /* Inherits the 900 weight from parent */
}

.tagline {
    padding-top: 55px;
}

.divider-ball {
    width: 16px;
    height: 16px;
    display: inline-block;
    vertical-align: middle;
}

/* Main Body Content Top Alignment */
.header-main-content {
    padding-top: 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
}

.header-main-content .button-cluster-wrapper {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 5px;
    flex-wrap: wrap;
    transition: gap 0.3s ease, padding 0.3s ease;
}

/* Store Badges Container */
.store-badges {
    display: flex;
    gap: 5px;
    align-items: flex-start;
}

.apple-badge-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 6px;
}

.apple-badge-wrapper .apple-badge[disabled],
.apple-badge-wrapper .apple-badge[aria-disabled="true"] {
    opacity: 0.45;
    filter: grayscale(40%);
    cursor: not-allowed;
    pointer-events: none;
    user-select: none;
    border: 1px solid rgba(0, 0, 0, 0.15);
}

.dev-ribbon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-8deg);
    background: var(--kliq-main);
    color: var(--kliq-accent);
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    padding: 2px 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    white-space: nowrap;
    z-index: 2;
    pointer-events: none;
    border: 1px solid #ffffff;
}

.amazon-affiliate-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}

.store-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background-color: var(--kliq-scoreboard-bg);
    color: var(--kliq-white);
    text-decoration: none;
    padding: 4px 4px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 700;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-bottom: 2px solid var(--kliq-main);
    white-space: nowrap;
    box-sizing: border-box;
    overflow: hidden;
}

.store-badge:hover {
    background-color: var(--kliq-accent);
    transform: translateY(-1px);
}

.btn-amazon-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background-color: var(--kliq-main);
    color: #111111;
    font-weight: 800;
    font-size: 0.7rem;
    padding: 4px 4px;
    border-radius: 6px !important;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 3px 0px #C79A00;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    box-sizing: border-box;
    overflow: hidden;
}

.btn-amazon-header:hover {
    background-color: var(--kliq-alert);
    transform: translateY(-1px);
    box-shadow: 0 4px 0px #C79A00;
}

.store-badge span,
.btn-amazon-header span {
    display: inline-block;
    max-width: 200px;
    opacity: 1;
    transition: max-width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.2s ease,
                font-size 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                margin 0.3s ease;
    white-space: nowrap;
    overflow: hidden;
}

.amazon-icon,
.btn-amazon-header .amazon-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    transition: opacity 0.25s ease, width 0.3s ease, height 0.3s ease;
}

.affiliate-disclosure {
    font-size: 0.65rem;
    color: #777777;
    margin-top: 3px;
    font-style: italic;
    white-space: nowrap;
    transition: opacity 0.2s ease, max-height 0.2s ease, margin 0.2s ease;
}

/* ==========================================================================
   MEDIUM / TABLET BREAKPOINT (≤ 950px)
   ========================================================================== */
@media screen and (max-width: 950px) {
    .hero-carousel-header {
        min-height: 140px;
    }

    .header-background picture img {
        width: 70%;
        height: auto;
        object-fit: contain;
        object-position: center;
        margin: auto;
        max-height: 180px;
    }

    .logo-wrapper {
        top: 2px;
        left: 2px;
    }

    .logo-wrapper img.logo {
        max-height: 70px;
    }

    .lang-dropdown {
        top: 2px;
        right: 4px;
    }

    .lang-btn {
        padding: 2px 6px;
        font-size: 0.72rem;
    }

    .hero-hero-tagline {
        position: relative;
        top: 0;
        left: 0;
        transform: none;
        max-width: 100%;
        margin-top: 5px;
        margin-bottom: 4px;
    }

    .hero-hero-tagline h1 {
        font-size: 0.9rem;
    }

    .hero-hero-tagline .tagline {
        font-size: 0.68rem;
    }

    .header-main-content {
        padding-top: 0;
        gap: 8px;
    }
}

/* ==========================================================================
   MOBILE PORTRAIT BREAKPOINT (≤ 600px)
   ========================================================================== */
@media screen and (max-width: 600px) {
    .hero-carousel-header {
        min-height: 100px;
    }

    /* Expand image width relative to screen width for mobile visibility */
    .header-background picture img {
        width: 85%;
        max-height: 110px;
    }

    .logo-wrapper img.logo {
        max-height: 65px;
    }

    .lang-btn {
        padding: 1px 5px;
        font-size: 0.68rem;
    }

    .hero-hero-tagline h1 {
        font-size: 0.78rem;
        letter-spacing: 0.4px;
    }

    .hero-hero-tagline .tagline {
        font-size: 0.62rem;
        gap: 0.2rem;
    }

    .tagline {
        padding-top: 0px;
    }

    .divider-ball {
        width: 6px;
        height: 6px;
    }
}

/* ==========================================================================
   TIGHT MOBILE BREAKPOINT (≤ 400px)
   ========================================================================== */
@media screen and (max-width: 400px) {
    .hero-carousel-header {
        min-height: 70px;
    }

    .header-background picture img {
        width: 92%;
        max-height: 70px;
    }

    .logo-wrapper {
        top: 1px;
        left: 1px;
    }

    .logo-wrapper img.logo {
        max-height: 50px;
    }

    .lang-dropdown {
        top: 1px;
        right: 1px;
    }

    .lang-btn {
        padding: 1px 4px;
        font-size: 0.62rem;
    }

    .hero-hero-tagline h1 {
        font-size: 0.7rem;
    }

    .hero-hero-tagline .tagline {
        font-size: 0.58rem;
    }

    .tagline {
        padding-top: 35px;
    }
}

/* ==========================================================================
   MOBILE LANDSCAPE & SHORT VIEWPORT BREAKPOINT (orientation: landscape)
   ========================================================================== */
@media screen and (orientation: landscape) and (max-height: 500px) {
    .hero-carousel-header {
        min-height: 55px;
    }

    .header-background picture img {
        width: 80%;
        max-height: 87px;
    }

    .logo-wrapper {
        top: 2px;
        left: 4px;
    }

    .logo-wrapper img.logo {
        max-height: 42px;
    }

    .lang-dropdown {
        top: 2px;
        right: 4px;
    }

    .lang-btn {
        padding: 1px 5px;
        font-size: 0.65rem;
    }

    .hero-hero-tagline {
        position: relative;
        top: 0;
        left: 0;
        transform: none;
        margin-top: 2px;
        margin-bottom: 2px;
    }

    .hero-hero-tagline h1 {
        font-size: 0.9rem;
        letter-spacing: 0.3px;
    }

    .hero-hero-tagline .tagline {
        font-size: 0.8rem;
        gap: 0.2rem;
    }

    .divider-ball {
        width: 5px;
        height: 5px;
    }

    .header-main-content {
        padding-top: 0;
        gap: 4px;
    }

    .store-badge,
    .btn-amazon-header {
        padding: 4px 10px;
        font-size: 0.72rem;
    }

    .affiliate-disclosure {
        font-size: 0.55rem;
        margin-top: 1px;
    }

    .tagline {
        padding-top: 14px;
    }
}