/* Ana sayfa duyuru şeridi — marka neon-green (#dbf227) */

body[data-page="home"] {
    --announcement-bar-h: 3rem;
    --brand-green: #dbf227;
    --brand-green-dark: #c5db20;
    --brand-green-light: #e8ff4a;
}

#announcementBar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 60;
    height: var(--announcement-bar-h);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 max(1rem, env(safe-area-inset-right, 0px)) 0 max(1rem, env(safe-area-inset-left, 0px));
    background: linear-gradient(
        90deg,
        #d0de68 0%,
        #d6e47a 28%,
        #dce88e 50%,
        #d6e47a 72%,
        #d0de68 100%
    );
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    font-family: 'Inter', sans-serif;
    font-size: 0.8125rem;
    line-height: 1.3;
    color: #09090b;
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
    transition:
        transform 0.18s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.18s ease;
}

#announcementBar.announcement-bar--scrolled {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

.announcement-bar__inner {
    width: 100%;
    max-width: 80rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.announcement-bar__promo {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.375rem;
    color: #09090b;
    text-decoration: none;
    border-radius: 0.375rem;
    transition: opacity 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.announcement-bar__promo:hover {
    opacity: 0.82;
}

.announcement-bar__promo:focus-visible {
    outline: 2px solid #09090b;
    outline-offset: 2px;
}

.announcement-bar__gift {
    flex-shrink: 0;
    font-size: 0.9375rem;
    line-height: 1;
}

/* —— Promo message (unified typography) —— */

.announcement-bar__message {
    min-width: 0;
    font-family: 'Poppins', sans-serif;
    line-height: 1.25;
}

.announcement-bar__message--desktop {
    display: none;
    align-items: center;
    gap: 0.625rem;
}

.announcement-bar__message--mobile {
    position: relative;
    display: block;
    flex: 1;
    min-width: 0;
    height: 1.2em;
    overflow: hidden;
}

@keyframes announcement-gift-pulse {
    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

@media (max-width: 639px) {
    .announcement-bar__inner {
        justify-content: center;
    }

    .announcement-bar__promo {
        position: relative;
        flex: 1;
        min-width: 0;
        justify-content: center;
        gap: 0;
        max-width: 100%;
    }

    .announcement-bar__gift {
        position: absolute;
        left: 0;
        top: 0;
        bottom: 0;
        display: inline-flex;
        align-items: center;
    }

    .announcement-bar__message--mobile {
        flex: 1;
        min-width: 0;
        height: 1.35em;
        text-align: center;
    }

    .announcement-bar__message--mobile .announcement-bar__rotate-item {
        left: 0;
        right: 0;
        top: 50%;
        text-align: center;
        will-change: transform, opacity;
        transform: translate(115%, -50%);
        transition:
            opacity 0.16s cubic-bezier(0.22, 1, 0.36, 1),
            transform 0.16s cubic-bezier(0.22, 1, 0.36, 1);
    }

    .announcement-bar__message--mobile .announcement-bar__rotate-item.is-active {
        opacity: 1;
        transform: translate(0, -50%);
    }

    .announcement-bar__message--mobile .announcement-bar__rotate-item.is-exit {
        opacity: 0;
        transform: translate(-115%, -50%);
    }

    #announcementBar .announcement-bar__actions {
        display: none;
    }

    .announcement-bar__gift {
        font-size: 0.9375rem;
        animation: announcement-gift-pulse 2.6s ease-in-out infinite;
    }

    #announcementBar.announcement-bar--scrolled .announcement-bar__gift {
        animation-play-state: paused;
    }

    .announcement-bar__message--mobile .announcement-bar__mobile-text {
        font-size: 0.8125rem;
        font-weight: 600;
        color: #09090b;
        letter-spacing: 0.01em;
        white-space: nowrap;
    }
}

.announcement-bar__headline {
    flex-shrink: 0;
}

.announcement-bar__headline-text {
    font-size: 0.8125rem;
    font-weight: 500;
    color: rgba(9, 9, 11, 0.82);
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.announcement-bar__headline-text strong {
    font-weight: 700;
    color: #09090b;
}

.announcement-bar__text-divider {
    flex-shrink: 0;
    width: 1px;
    height: 0.875rem;
    background: rgba(9, 9, 11, 0.18);
}

.announcement-bar__subline {
    min-width: 0;
    font-size: 0.8125rem;
    font-weight: 500;
    color: rgba(9, 9, 11, 0.58);
    letter-spacing: 0.01em;
}

.announcement-bar__subline-text {
    font-size: 0.8125rem;
    font-weight: 500;
    color: rgba(9, 9, 11, 0.58);
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.announcement-bar__subline--rotate {
    position: relative;
    display: block;
    min-width: 9.5rem;
    height: 1.25em;
    overflow: hidden;
}

.announcement-bar__rotate-item {
    position: absolute;
    left: 0;
    top: 0;
    white-space: nowrap;
    opacity: 0;
    transform: translateY(110%);
    transition:
        opacity 0.22s ease,
        transform 0.22s cubic-bezier(0.2, 0.8, 0.2, 1);
    pointer-events: none;
}

.announcement-bar__rotate-item.is-active {
    opacity: 1;
    transform: translateY(0);
}

.announcement-bar__rotate-item.is-exit {
    opacity: 0;
    transform: translateY(-110%);
}

@media (prefers-reduced-motion: reduce) {
    .announcement-bar__rotate-item {
        position: static;
        opacity: 1;
        transform: none;
        transition: none;
        will-change: auto;
    }

    .announcement-bar__rotate-item:not(:first-child) {
        display: none;
    }

    .announcement-bar__message--mobile,
    .announcement-bar__subline--rotate {
        min-width: 0;
        height: auto;
        overflow: visible;
    }

    .announcement-bar__message--mobile .announcement-bar__rotate-item {
        left: auto;
        top: auto;
    }

    .announcement-bar__gift {
        animation: none;
    }
}

.announcement-bar__actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.announcement-bar__divider {
    flex-shrink: 0;
    color: rgba(9, 9, 11, 0.35);
    font-size: 0.875rem;
    font-weight: 300;
    line-height: 1;
    user-select: none;
    display: none;
}

.announcement-bar__social {
    display: none;
    align-items: center;
    gap: 0.5rem;
}

.announcement-bar__social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 9999px;
    color: #09090b;
    background: #fff;
    border: 1px solid rgba(9, 9, 11, 0.12);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
    transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.announcement-bar__social-link:hover {
    color: #000;
    background: #fff;
    border-color: rgba(9, 9, 11, 0.22);
    transform: translateY(-1px);
}

.announcement-bar__social-link:focus-visible {
    outline: 2px solid #09090b;
    outline-offset: 2px;
}

.announcement-bar__social-icon {
    width: 0.9375rem;
    height: 0.9375rem;
}

.announcement-bar__social-link--email {
    display: none;
}

.announcement-bar__cta {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 0.4375rem;
    padding: 0.4375rem 0.875rem;
    border: none;
    border-radius: 9999px;
    background: #09090b;
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    box-shadow: 0 2px 0 #000;
    transition:
        opacity 0.25s ease,
        transform 0.2s ease,
        background-color 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.announcement-bar__cta:hover {
    background: #000;
}

.announcement-bar__cta:focus {
    outline: none;
}

.announcement-bar__cta:focus-visible {
    outline: 2px solid #09090b;
    outline-offset: 2px;
}

.announcement-bar__cta-icon {
    flex-shrink: 0;
    width: 0.9375rem;
    height: 0.9375rem;
    color: var(--brand-green);
}

body[data-page="home"] #mainHeader {
    top: var(--announcement-bar-h);
    transform: none;
    transition: top 0.18s cubic-bezier(0.4, 0, 0.2, 1), padding 0.18s cubic-bezier(0.4, 0, 0.2, 1);
}

body[data-page="home"]:not(.announcement-bar--scrolled) #mainHeader {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

body[data-page="home"].announcement-bar--scrolled #mainHeader {
    top: 0;
}

@media (prefers-reduced-motion: reduce) {
    #announcementBar,
    body[data-page="home"] #mainHeader {
        transition: none;
    }
}

body[data-page="home"] #home.hero-with-announcement {
    padding-top: calc(6rem + var(--announcement-bar-h));
}

@media (max-width: 767px) {
    body[data-page="home"] #home.hero-with-announcement {
        min-height: 100vh;
        min-height: 100dvh;
    }
}

@media (min-width: 640px) {
    body[data-page="home"] {
        --announcement-bar-h: 3.25rem;
    }

    .announcement-bar__message--desktop {
        display: inline-flex;
    }

    .announcement-bar__message--mobile {
        display: none;
    }

    .announcement-bar__headline-text {
        font-size: 0.875rem;
    }

    .announcement-bar__subline,
    .announcement-bar__subline--rotate {
        font-size: 0.875rem;
    }

    .announcement-bar__subline--rotate {
        min-width: 11rem;
    }

    .announcement-bar__divider {
        display: inline;
    }

    .announcement-bar__social {
        display: flex;
    }

    #announcementBar {
        font-size: 0.875rem;
    }

    .announcement-bar__cta {
        font-size: 0.875rem;
        padding: 0.5rem 1rem;
    }

    .announcement-bar__gift {
        font-size: 1rem;
    }

    .announcement-bar__social-link--email {
        display: inline-flex;
    }

    .announcement-bar__actions {
        gap: 0.75rem;
    }
}

@media (min-width: 768px) {
    body[data-page="home"] #home.hero-with-announcement {
        padding-top: calc(10rem + var(--announcement-bar-h));
    }
}
