/* MX Design V2 - Editoryal arayuz katmani */
:root {
    --mx-v2-brand: #064e4f;
    --mx-v2-brand-soft: #0f766e;
    --mx-v2-page: #f6f8f7;
    --mx-v2-card: #ffffff;
    --mx-v2-text: #172321;
    --mx-v2-muted: #64736f;
    --mx-v2-border: #dfe8e5;
    --mx-v2-shadow: 0 12px 34px rgba(6, 78, 79, .09);
}

html.theme-dark {
    --mx-v2-page: #121212;
    --mx-v2-card: #2a2a2a;
    --mx-v2-text: #ffffff;
    --mx-v2-muted: #d3d3d3;
    --mx-v2-border: #414141;
    --mx-v2-shadow: 0 14px 36px rgba(0, 0, 0, .32);
}

/* Header: kaydirmada daha zarif ve kompakt gorunum */
#siteHeader,
#siteHeader .mx-site-header-row,
#siteHeader .mx-header-logo {
    transition: height .24s ease, background-color .24s ease, box-shadow .24s ease, transform .24s ease;
}

#siteHeader.mx-header-scrolled {
    box-shadow: 0 10px 30px rgba(6, 78, 79, .12);
}

@media (min-width: 1024px) {
    #siteHeader.mx-header-scrolled .mx-site-header-row {
        height: 4.25rem;
    }

    #siteHeader.mx-header-scrolled .mx-header-logo {
        height: 3.25rem;
    }
}

html.theme-dark #siteHeader.mx-header-scrolled {
    box-shadow: 0 10px 30px rgba(0, 0, 0, .38);
}

/* Tek tip icerik kartlari */
.post-card {
    background: var(--mx-v2-card) !important;
    border: 1px solid var(--mx-v2-border) !important;
    border-radius: 1.125rem !important;
    box-shadow: var(--mx-v2-shadow) !important;
    color: var(--mx-v2-text) !important;
    overflow: hidden;
    transform: translateZ(0);
}

main .post-card:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 20px 42px rgba(6, 78, 79, .14) !important;
}

html.theme-dark main .post-card:hover {
    box-shadow: 0 20px 42px rgba(0, 0, 0, .4) !important;
}

.post-card > a > .h-56 {
    height: auto !important;
    aspect-ratio: 4 / 3;
}

.post-card-image {
    transition: transform .35s cubic-bezier(.2, .75, .3, 1) !important;
}

main .post-card:hover .post-card-image {
    transform: scale(1.045) !important;
}

main .category-badge:hover {
    transform: translateY(-1px) !important;
    box-shadow: 0 9px 20px rgba(6, 78, 79, .24) !important;
}

.category-badge {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    background: linear-gradient(135deg, var(--mx-v2-brand), var(--mx-v2-brand-soft)) !important;
    border: 1px solid rgba(255, 255, 255, .2) !important;
    box-shadow: 0 7px 18px rgba(6, 78, 79, .2) !important;
    letter-spacing: .02em;
}

.category-badge > span {
    background: #ffffff !important;
}

.search-page-shell {
    background: var(--mx-v2-page) !important;
}

.search-result-card,
.search-empty-card {
    color: var(--mx-v2-text) !important;
    background: var(--mx-v2-card) !important;
    border: 1px solid var(--mx-v2-border) !important;
    border-radius: 1.125rem !important;
    box-shadow: var(--mx-v2-shadow) !important;
}

.search-result-card {
    transition: transform .25s ease, box-shadow .25s ease;
}

.search-result-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 42px rgba(6, 78, 79, .14) !important;
}

html.theme-dark .search-result-card:hover {
    box-shadow: 0 20px 42px rgba(0, 0, 0, .4) !important;
}

.search-result-card > img {
    height: auto !important;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.search-result-card div > span {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    background: linear-gradient(135deg, var(--mx-v2-brand), var(--mx-v2-brand-soft)) !important;
    border-radius: 999px !important;
}

.search-result-title,
.search-result-card h2 {
    color: var(--mx-v2-text) !important;
}

.search-result-excerpt,
.search-empty-card p {
    color: var(--mx-v2-muted) !important;
}

/* Ana sayfa editoryal hiyerarsi */
.home-page {
    background: var(--mx-v2-page);
}

.mx-home-intro {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.mx-home-intro h1 {
    color: var(--mx-v2-text);
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    line-height: 1.1;
    font-weight: 900;
    letter-spacing: -.035em;
}

.mx-home-intro p {
    color: var(--mx-v2-muted);
    font-size: .9rem;
    font-weight: 600;
}

.mx-featured-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(280px, .72fr);
    gap: 1.25rem;
}

.mx-featured-layout.mx-featured-solo {
    grid-template-columns: 1fr;
}

.mx-featured-main {
    min-height: 32rem;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 1.5rem;
    box-shadow: 0 18px 48px rgba(6, 78, 79, .16);
}

.mx-featured-side {
    display: grid;
    grid-template-rows: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.mx-side-story {
    position: relative;
    min-height: 15.5rem;
    border-radius: 1.25rem;
    overflow: hidden;
    background: var(--mx-v2-card);
    box-shadow: var(--mx-v2-shadow);
}

.mx-side-story img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s cubic-bezier(.2, .75, .3, 1);
}

.mx-side-story:hover img {
    transform: scale(1.045);
}

.mx-side-story-fallback {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--mx-v2-brand), var(--mx-v2-brand-soft));
}

.mx-side-story-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: end;
    padding: 1.25rem;
    color: #ffffff;
    background: linear-gradient(to top, rgba(3, 15, 14, .94), rgba(3, 15, 14, .18) 72%);
}

.mx-side-story-overlay h2 {
    margin-top: .7rem;
    color: #ffffff !important;
    font-size: 1.12rem;
    line-height: 1.28;
    font-weight: 800;
}

.mx-side-story-overlay .category-badge {
    align-self: flex-start;
}

.mx-side-story-overlay time {
    margin-top: .65rem;
    color: rgba(255, 255, 255, .76) !important;
    font-size: .75rem;
}

.mx-section-heading {
    display: flex;
    align-items: center;
    gap: .75rem;
}

.mx-section-heading::before {
    content: '';
    width: .28rem;
    height: 2rem;
    border-radius: 999px;
    background: linear-gradient(to bottom, var(--mx-v2-brand), var(--mx-v2-brand-soft));
}

.mx-section-heading h2 {
    color: var(--mx-v2-text);
    font-size: 1.55rem;
    font-weight: 900;
    letter-spacing: -.025em;
}

/* Okuma sayfasi tipografisi */
.post-page .post-header-card,
.post-page .post-content-card,
.post-page aside > div {
    background: var(--mx-v2-card) !important;
    border: 1px solid var(--mx-v2-border) !important;
    box-shadow: var(--mx-v2-shadow) !important;
}

.post-page .post-header-card h1 {
    color: var(--mx-v2-text) !important;
    letter-spacing: -.035em;
}

.post-page .post-header-card > p {
    color: var(--mx-v2-muted) !important;
}

.post-page .post-featured-media {
    aspect-ratio: 16 / 9;
    border-radius: 1.5rem;
    overflow: hidden;
    box-shadow: var(--mx-v2-shadow);
}

.post-page .post-featured-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-page .prose {
    width: min(100%, 47rem);
    margin-inline: auto;
    color: var(--mx-v2-text) !important;
    font-size: 1.1rem !important;
    line-height: 1.88 !important;
}

.post-page .prose :where(h1, h2, h3, h4) {
    color: var(--mx-v2-text) !important;
    letter-spacing: -.025em;
}

.post-page .prose h2 {
    margin-top: 1.75em !important;
    margin-bottom: .72em !important;
}

.post-page .prose h3 {
    margin-top: 1.5em !important;
    margin-bottom: .65em !important;
}

.post-page .prose blockquote {
    color: var(--mx-v2-text) !important;
    background: rgba(15, 118, 110, .1) !important;
    background: color-mix(in srgb, var(--mx-v2-brand-soft) 10%, var(--mx-v2-card)) !important;
    border-left-color: var(--mx-v2-brand-soft) !important;
    border-radius: 0 .9rem .9rem 0 !important;
}

/* Mobil alt gezinme */
.mx-mobile-bottom-nav {
    display: none;
}

@media (max-width: 1023px) {
    body {
        padding-bottom: 4.4rem;
    }

    .mx-mobile-bottom-nav {
        position: fixed;
        right: .65rem;
        bottom: max(.65rem, env(safe-area-inset-bottom));
        left: .65rem;
        z-index: 35;
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        min-height: 3.75rem;
        color: var(--mx-v2-muted);
        background: rgba(255, 255, 255, .95);
        border: 1px solid var(--mx-v2-border);
        border-radius: 1.15rem;
        box-shadow: 0 14px 35px rgba(6, 78, 79, .18);
        backdrop-filter: blur(18px);
        -webkit-backdrop-filter: blur(18px);
        overflow: hidden;
        transition: opacity .2s ease, transform .2s ease, background-color .2s ease;
    }

    html.theme-dark .mx-mobile-bottom-nav {
        color: #d7d7d7;
        background: rgba(28, 28, 28, .96);
        box-shadow: 0 14px 35px rgba(0, 0, 0, .48);
    }

    .mx-mobile-bottom-nav :where(a, button) {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: .22rem;
        min-width: 0;
        padding: .5rem .2rem;
        color: inherit;
        background: transparent;
        font-size: .68rem;
        font-weight: 700;
    }

    .mx-mobile-bottom-nav :where(a, button).is-active,
    .mx-mobile-bottom-nav :where(a, button):hover {
        color: var(--mx-v2-brand-soft);
        background: rgba(15, 118, 110, .08);
    }

    html.theme-dark .mx-mobile-bottom-nav :where(a, button).is-active,
    html.theme-dark .mx-mobile-bottom-nav :where(a, button):hover {
        color: #43c7ba !important;
        -webkit-text-fill-color: #43c7ba !important;
        background: #242424;
    }

    .mx-mobile-bottom-nav svg {
        width: 1.2rem;
        height: 1.2rem;
    }

    body.mx-mobile-menu-open .mx-mobile-bottom-nav {
        opacity: 0;
        pointer-events: none;
        transform: translateY(.5rem);
    }

    .mx-featured-layout {
        grid-template-columns: 1fr;
    }

    .mx-featured-main {
        min-height: 28rem;
    }

    .mx-featured-side {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-template-rows: none;
    }
}

@media (max-width: 640px) {
    .mx-home-intro {
        align-items: start;
        flex-direction: column;
    }

    .mx-featured-main {
        min-height: 25rem;
        border-radius: 1.25rem;
    }

    .mx-featured-side {
        grid-template-columns: 1fr;
    }

    .mx-side-story {
        min-height: 13.5rem;
    }

    .post-page .prose {
        font-size: 1.02rem !important;
        line-height: 1.78 !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    #siteHeader,
    #siteHeader *,
    .post-card,
    .post-card-image,
    .mx-side-story img {
        transition: none !important;
    }
}

@media print {
    .mx-mobile-bottom-nav {
        display: none !important;
    }

    body {
        padding-bottom: 0 !important;
    }
}
