/* =========================================================
   PROJE TURAN
   KOYU TEMA

   <html data-theme="dark"> olduğunda devreye girer.
   Açık temadaki #302D55 / beyaz paletinin karşılıkları.
   ========================================================= */

:root[data-theme="dark"] {
    color-scheme: dark;

    --dk-bg: #15141f;
    --dk-surface: #1e1c2d;
    --dk-surface-2: #26243a;
    --dk-surface-glass: rgba(30, 28, 45, .82);
    --dk-text: #e8e6f5;
    --dk-text-soft: rgba(232, 230, 245, .78);
    --dk-text-muted: rgba(232, 230, 245, .56);
    --dk-text-faint: rgba(232, 230, 245, .40);
    --dk-border: rgba(255, 255, 255, .10);
    --dk-border-strong: rgba(255, 255, 255, .20);
    --dk-accent: #9fb0ff;
    --dk-shadow: 0 10px 24px -10px rgba(0, 0, 0, .55), 0 16px 40px -14px rgba(0, 0, 0, .45);
}


/* =========================================================
   GENEL
   ========================================================= */

[data-theme="dark"] body,
[data-theme="dark"] body.post-page,
[data-theme="dark"] body.static-page-body {
    background: var(--dk-bg);
    color: var(--dk-text);
}

[data-theme="dark"] ::selection {
    background: rgba(159, 176, 255, .32);
    color: #fff;
}

/* Arka plan dalgaları koyu zeminde daha yumuşak dursun */
[data-theme="dark"] .epcl-waves-page {
    opacity: .55;
}

/* Koyu temada altın yerine zeminin açık, serin lacivert tonu */
[data-theme="dark"] #bg-wave path {
    fill: #8a9cff;
    fill-opacity: .11;
}

[data-theme="dark"] #bg-wave2 path {
    fill: #6f86e8;
    fill-opacity: .07;
}


/* =========================================================
   HEADER
   ========================================================= */

/*
 * Açık temadaki gibi: ilk açılışta cam yok, scroll'da üst + menü
 * satırını tek cam yüzey kaplar. Menü satırına ayrı katman verilmez,
 * yoksa iki katman üst üste binip menü barı daha koyu görünür.
 */
[data-theme="dark"] .site-header.is-scrolled::after {
    background: rgba(21, 20, 31, .62);
}

[data-theme="dark"] .site-header__menu-row::before,
[data-theme="dark"] .site-header.is-scrolled .site-header__menu-row::before {
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

[data-theme="dark"] .site-header .site-header__menu-row::after {
    background: var(--dk-border);
}

[data-theme="dark"] .site-logo,
[data-theme="dark"] .site-nav > a,
[data-theme="dark"] .nav-dropdown__trigger,
[data-theme="dark"] .nav-dropdown__menu button,
[data-theme="dark"] .nav-dropdown__menu a,
[data-theme="dark"] .nav-dropdown__icon {
    color: var(--dk-text);
}

[data-theme="dark"] .nav-hover-pill,
[data-theme="dark"] .nav-dropdown__menu::before {
    border-color: var(--dk-border-strong);
    background: linear-gradient(180deg, rgba(255, 255, 255, .10), rgba(255, 255, 255, .04));
    box-shadow: 0 8px 22px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .08);
}

[data-theme="dark"] .nav-dropdown__menu {
    border-color: var(--dk-border);
    background: linear-gradient(180deg, rgba(38, 36, 58, .96), rgba(30, 28, 45, .94));
    box-shadow: 0 24px 55px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .06);
}

[data-theme="dark"] .nav-dropdown__menu button:hover,
[data-theme="dark"] .nav-dropdown__menu a:hover {
    background: rgba(255, 255, 255, .06);
}

[data-theme="dark"] .nav-dropdown__menu button:hover .nav-dropdown__icon,
[data-theme="dark"] .nav-dropdown__menu a:hover .nav-dropdown__icon {
    color: var(--dk-accent);
}

[data-theme="dark"] .header-button,
[data-theme="dark"] .header-search-input {
    border-color: var(--dk-border);
    background: rgba(38, 36, 58, .72);
    color: var(--dk-text);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .30), inset 0 1px 0 rgba(255, 255, 255, .06);
}

[data-theme="dark"] .header-button:hover {
    background: rgba(48, 45, 72, .92);
    box-shadow: 0 8px 18px rgba(0, 0, 0, .38), inset 0 1px 0 rgba(255, 255, 255, .08);
}

[data-theme="dark"] .header-search-input::placeholder {
    color: var(--dk-text-faint);
}

[data-theme="dark"] .theme-button i {
    color: #ffd27a;
}

[data-theme="dark"] .title-tooltip {
    background: rgba(48, 45, 72, .96);
}


/* =========================================================
   KARTLAR (ANA SAYFA)
   ========================================================= */

[data-theme="dark"] .card,
[data-theme="dark"] .similar-post-card {
    background: var(--dk-surface);
    box-shadow: var(--dk-shadow);
}

[data-theme="dark"] .card:hover,
[data-theme="dark"] .similar-post-card:hover {
    box-shadow: 0 14px 28px -10px rgba(0, 0, 0, .65), 0 22px 48px -16px rgba(0, 0, 0, .50);
}


/* =========================================================
   ANA SAYFA DETAY PENCERESİ
   ========================================================= */

[data-theme="dark"] .detail-backdrop {
    background: rgba(5, 5, 10, .66);
}

[data-theme="dark"] .editorial-detail {
    border-color: var(--dk-border);
    background: var(--dk-surface);
    box-shadow: 0 35px 90px rgba(0, 0, 0, .6);
}

[data-theme="dark"] .editorial-left,
[data-theme="dark"] .editorial-cover {
    background-color: var(--dk-surface-2);
}

[data-theme="dark"] .editorial-cover::after {
    background: rgba(21, 20, 31, .18);
}

[data-theme="dark"] .editorial-content {
    background: var(--dk-surface);
}

[data-theme="dark"] .detail-close,
[data-theme="dark"] .editorial-date-month,
[data-theme="dark"] .editorial-text,
[data-theme="dark"] .editorial-text p {
    color: var(--dk-text-soft);
}

[data-theme="dark"] .detail-close:hover,
[data-theme="dark"] .editorial-date-day,
[data-theme="dark"] .editorial-title,
[data-theme="dark"] .editorial-text h2,
[data-theme="dark"] .editorial-text h3 {
    color: var(--dk-text);
}

[data-theme="dark"] .editorial-date-year,
[data-theme="dark"] .editorial-lead,
[data-theme="dark"] .editorial-tags span {
    color: var(--dk-text-muted);
}

[data-theme="dark"] .editorial-tags,
[data-theme="dark"] .editorial-popup-gallery {
    border-color: var(--dk-border);
}

[data-theme="dark"] .editorial-detail .editorial-action,
[data-theme="dark"] .editorial-detail .editorial-side-tags span {
    border-color: var(--dk-border-strong);
    background: rgba(255, 255, 255, .05);
    color: var(--dk-text-soft);
}

[data-theme="dark"] .editorial-detail .editorial-action:hover,
[data-theme="dark"] .editorial-detail .editorial-side-tags span:hover {
    background: rgba(255, 255, 255, .10);
    color: var(--dk-text);
}

[data-theme="dark"] .editorial-scroll::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .18);
}


/* =========================================================
   YAZI SAYFASI
   ========================================================= */

[data-theme="dark"] .post-article,
[data-theme="dark"] .post--portrait,
[data-theme="dark"] .post--landscape {
    border-color: var(--dk-border);
    background: var(--dk-surface-glass);
    box-shadow: var(--dk-shadow);
}

[data-theme="dark"] .post-title,
[data-theme="dark"] .post--portrait .post-title,
[data-theme="dark"] .post-body h1,
[data-theme="dark"] .post-body h2,
[data-theme="dark"] .post-body h3,
[data-theme="dark"] .post-body h4,
[data-theme="dark"] .post-body h5,
[data-theme="dark"] .post-body h6,
[data-theme="dark"] .similar-posts__title,
[data-theme="dark"] .similar-post-card__title,
[data-theme="dark"] .post-comments__title,
[data-theme="dark"] .comment-item__name {
    color: var(--dk-text);
}

[data-theme="dark"] .post-body,
[data-theme="dark"] .post--portrait .post-body,
[data-theme="dark"] .post-lead,
[data-theme="dark"] .post--portrait .post-lead,
[data-theme="dark"] .comment-item__text {
    color: var(--dk-text-soft);
}

[data-theme="dark"] .post-meta,
[data-theme="dark"] .post-meta__date,
[data-theme="dark"] .post--portrait .post-meta__date,
[data-theme="dark"] .similar-posts__eyebrow,
[data-theme="dark"] .similar-post-card__meta,
[data-theme="dark"] .post-comments__eyebrow,
[data-theme="dark"] .comment-new__eyebrow,
[data-theme="dark"] .comment-item__date,
[data-theme="dark"] .comment-empty,
[data-theme="dark"] .comment-form__field label {
    color: var(--dk-text-muted);
}

[data-theme="dark"] .post-body a,
[data-theme="dark"] .post-tags a,
[data-theme="dark"] .post--portrait .post-tags a,
[data-theme="dark"] .comment-reply-button {
    color: var(--dk-accent);
}

[data-theme="dark"] .post-tags a:hover {
    color: var(--dk-text);
}

[data-theme="dark"] .post--portrait .post-tags::before,
[data-theme="dark"] .post--portrait .post-lead::before {
    background: var(--dk-border-strong);
}

[data-theme="dark"] .post--portrait .post-actions {
    border-color: var(--dk-border);
}

[data-theme="dark"] .post-action,
[data-theme="dark"] .post--portrait .post-action {
    border-color: var(--dk-border-strong);
    background: rgba(255, 255, 255, .05);
    color: var(--dk-text);
    box-shadow: 0 8px 20px rgba(0, 0, 0, .25), inset 0 1px 0 rgba(255, 255, 255, .06);
}

[data-theme="dark"] .post-action:hover {
    border-color: rgba(159, 176, 255, .40);
    background: rgba(255, 255, 255, .10);
    color: var(--dk-accent);
}

[data-theme="dark"] .post-body blockquote {
    border-color: var(--dk-border);
    border-left-color: rgba(159, 176, 255, .55);
    background: rgba(255, 255, 255, .04);
    color: var(--dk-text-soft);
}

[data-theme="dark"] .post-share__item {
    border-color: var(--dk-border);
    background: var(--dk-surface-2);
    color: var(--dk-text);
    box-shadow: 0 8px 22px rgba(0, 0, 0, .35);
}

[data-theme="dark"] .post-share__item:hover {
    background: var(--dk-text);
    color: var(--dk-bg);
}

/* Önceki / sonraki yazı */
[data-theme="dark"] .post-sequence-nav {
    border-color: var(--dk-border);
}

[data-theme="dark"] .post-sequence-nav__link {
    color: var(--dk-text-soft) !important;
}

[data-theme="dark"] .post-sequence-nav__link:hover {
    color: var(--dk-text) !important;
}

[data-theme="dark"] .post-sequence-nav__arrow {
    background: rgba(255, 255, 255, .08);
    color: var(--dk-text);
}

[data-theme="dark"] .post-sequence-nav__link:hover .post-sequence-nav__arrow {
    background: var(--dk-text);
    color: var(--dk-bg);
}

/* Tüm etiketler */
[data-theme="dark"] .post-all-tags,
[data-theme="dark"] .post--landscape .post-all-tags,
[data-theme="dark"] .post--portrait .post-all-tags {
    border-top-color: var(--dk-border) !important;
}

[data-theme="dark"] .post-all-tags__label {
    color: var(--dk-text-muted) !important;
}

[data-theme="dark"] .post-all-tags__item,
[data-theme="dark"] .post-all-tags__item:nth-child(n) {
    border-color: var(--dk-border) !important;
    background: rgba(255, 255, 255, .06) !important;
    color: var(--dk-text-soft) !important;
    box-shadow: none;
}

[data-theme="dark"] .post-all-tags__item:hover {
    border-color: rgba(159, 176, 255, .40) !important;
    background: rgba(255, 255, 255, .12) !important;
    color: var(--dk-text) !important;
}

[data-theme="dark"] .similar-post-card__image {
    background: var(--dk-surface-2);
}


/* =========================================================
   YORUMLAR
   ========================================================= */

[data-theme="dark"] .comment-form {
    border-color: var(--dk-border);
    background: var(--dk-surface-glass);
    box-shadow: var(--dk-shadow);
}

[data-theme="dark"] .comment-form__field input,
[data-theme="dark"] .comment-form__field textarea {
    border-color: var(--dk-border);
    background: rgba(255, 255, 255, .05);
    color: var(--dk-text);
}

[data-theme="dark"] .comment-form__field input:focus,
[data-theme="dark"] .comment-form__field textarea:focus {
    border-color: rgba(159, 176, 255, .50);
    background: rgba(255, 255, 255, .08);
    box-shadow: 0 0 0 4px rgba(159, 176, 255, .12);
}

[data-theme="dark"] .comment-item,
[data-theme="dark"] .comment-item--reply,
[data-theme="dark"] .comment-reply-form {
    border-color: var(--dk-border);
    background: rgba(255, 255, 255, .05);
    box-shadow: 0 8px 22px rgba(0, 0, 0, .25);
}

[data-theme="dark"] .comment-replies::before,
[data-theme="dark"] .comment-replies > .comment-thread::before {
    background: var(--dk-border-strong);
}

[data-theme="dark"] .comment-replies > .comment-thread:last-child::after {
    background: var(--dk-bg);
}

[data-theme="dark"] .comment-notice--success,
[data-theme="dark"] .contact-form__status--success {
    color: #8fd3a8;
}

[data-theme="dark"] .comment-notice--error,
[data-theme="dark"] .contact-form__status--invalid {
    color: #f0a0a0;
}


/* =========================================================
   ANA RENKLİ BUTONLAR (#302D55 zemin → açık zemin)
   ========================================================= */

[data-theme="dark"] .comment-form__submit,
[data-theme="dark"] .contact-form__button,
[data-theme="dark"] .yuri-newsletter__form button,
[data-theme="dark"] .error-page__home {
    background: var(--dk-text);
    color: var(--dk-bg);
}


/* =========================================================
   SABİT SAYFALAR VE İLETİŞİM
   ========================================================= */

[data-theme="dark"] .static-page__header {
    border-color: var(--dk-border);
}

[data-theme="dark"] .static-page__title,
[data-theme="dark"] .contact-page__title,
[data-theme="dark"] .contact-form label {
    color: var(--dk-text);
}

[data-theme="dark"] .static-page__body,
[data-theme="dark"] .contact-page__intro,
[data-theme="dark"] .contact-page__note {
    color: var(--dk-text-soft);
}

[data-theme="dark"] .contact-form {
    border-color: var(--dk-border);
    background: var(--dk-surface-glass);
    box-shadow: var(--dk-shadow);
}

[data-theme="dark"] .contact-form input,
[data-theme="dark"] .contact-form textarea {
    border-color: var(--dk-border);
    background: rgba(255, 255, 255, .05);
    color: var(--dk-text);
}

[data-theme="dark"] .contact-form input:focus,
[data-theme="dark"] .contact-form textarea:focus {
    border-color: rgba(159, 176, 255, .50);
    background: rgba(255, 255, 255, .08);
}


/* =========================================================
   FOOTER VE YURI BÜLTEN
   ========================================================= */

[data-theme="dark"] .site-footer,
[data-theme="dark"] .site-footer__logo {
    color: var(--dk-text);
}

[data-theme="dark"] .site-footer::after,
[data-theme="dark"] .site-footer__bottom {
    border-color: var(--dk-border);
}

[data-theme="dark"] .site-footer::after {
    background: var(--dk-border);
}

[data-theme="dark"] .site-footer__socials a {
    border-color: var(--dk-border-strong);
    background: rgba(255, 255, 255, .05);
    color: var(--dk-text);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06);
}

[data-theme="dark"] .yuri-newsletter__panel {
    border-color: var(--dk-border);
    background: rgba(30, 28, 45, .97);
    color: var(--dk-text);
    box-shadow: 0 18px 50px rgba(0, 0, 0, .5);
}

[data-theme="dark"] .yuri-newsletter__close,
[data-theme="dark"] .yuri-newsletter__text {
    color: var(--dk-text-muted);
}

[data-theme="dark"] .yuri-newsletter__privacy {
    color: var(--dk-text-faint);
}

[data-theme="dark"] .yuri-newsletter__form input {
    border-color: var(--dk-border);
    background: rgba(255, 255, 255, .06);
    color: var(--dk-text);
}

[data-theme="dark"] .yuri-newsletter__form input:focus {
    border-color: rgba(159, 176, 255, .50);
    box-shadow: 0 0 0 3px rgba(159, 176, 255, .12);
}

[data-theme="dark"] .yuri-newsletter__status.is-success {
    color: #8fd3a8;
}


/* =========================================================
   DUYURU POPUP VE ADMIN GİRİŞ
   ========================================================= */

[data-theme="dark"] .site-announcement__dialog--text,
[data-theme="dark"] .site-announcement__dialog--image_text .site-announcement__content {
    border-color: var(--dk-border);
    background: rgba(30, 28, 45, .97);
}

[data-theme="dark"] .site-announcement__title {
    color: var(--dk-text) !important;
}

[data-theme="dark"] .site-announcement__text {
    color: var(--dk-text-soft) !important;
}

[data-theme="dark"] .admin-login-box {
    border-color: var(--dk-border);
    background: rgba(30, 28, 45, .94);
    color: var(--dk-text);
}

[data-theme="dark"] .admin-password-input {
    border-color: var(--dk-border);
    background: rgba(255, 255, 255, .06);
    color: var(--dk-text);
}

[data-theme="dark"] .admin-password-input::placeholder {
    color: var(--dk-text-faint);
}

/* Mobil hamburger paneli */
@media (max-width: 800px) {
    [data-theme="dark"] .site-header .site-nav {
        border-color: var(--dk-border);
        background: linear-gradient(180deg, rgba(38, 36, 58, .96), rgba(30, 28, 45, .94));
        box-shadow: 0 24px 55px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .06);
    }

    [data-theme="dark"] .site-header .site-nav > a:hover,
    [data-theme="dark"] .site-header .nav-dropdown__trigger:hover,
    [data-theme="dark"] .site-header .nav-dropdown.is-open .nav-dropdown__trigger,
    [data-theme="dark"] .site-header .nav-dropdown__menu button:hover,
    [data-theme="dark"] .site-header .nav-dropdown__menu a:hover {
        background: rgba(255, 255, 255, .06);
    }
}

[data-theme="dark"] .site-header .nav-toggle {
    color: var(--dk-text);
}
