/* ===== Тёмная тема для всех страниц ===== */

/* --- Основной фон для всех страниц в тёмной теме --- */
.dark-theme body {
    background: radial-gradient(circle at 20% 30%, #0f172a, #020617) !important;
    background-attachment: fixed !important;
    color: #e2e8f0 !important;
}

.dark-theme .container {
    background: transparent !important;
}

/* --- Шапка и навигация --- */
.dark-theme header {
    background: rgba(2, 6, 23, 0.7) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}
.dark-theme .logo {
    color: #f1f5f9 !important;
}
.dark-theme .nav-links a,
.dark-theme .dropbtn,
.dark-theme .btn-donate-nav {
    color: #cbd5e1 !important;
}
.dark-theme .nav-links a:hover,
.dark-theme .dropbtn:hover {
    color: #b45f2b !important;
}
.dark-theme .btn-donate-nav:hover {
    background: #dc3232 !important;
    color: white !important;
    border-color: #dc3232 !important;
}
.dark-theme .dropdown-content {
    background: #1e293b !important;
}
.dark-theme .dropdown-content a {
    color: #cbd5e1 !important;
}
.dark-theme .dropdown-content a:hover {
    background: #b45f2b !important;
    color: white !important;
}

/* --- Основной контент (статья, комментарии) --- */
.dark-theme article,
.dark-theme #comments-section {
    background: rgba(15, 23, 42, 0.8) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #e2e8f0 !important;
}
.dark-theme article h1 {
    color: #f1f5f9 !important;
    border-left-color: #b45f2b !important;
}
.dark-theme .content p,
.dark-theme .content li,
.dark-theme .content td,
.dark-theme .content th {
    color: #cbd5e1 !important;
}
.dark-theme .content h2,
.dark-theme .content h3 {
    color: #f1f5f9 !important;
    border-bottom-color: rgba(180, 95, 43, 0.4) !important;
}
.dark-theme .content a:not(.back-link):not(.interview-link) {
    color: #b45f2b !important;
}
.dark-theme .content a:not(.back-link):not(.interview-link):hover {
    color: #f1f5f9 !important;
}
.dark-theme .content blockquote {
    background: rgba(180, 95, 43, 0.1) !important;
    color: #e2e8f0 !important;
    border-left-color: #b45f2b !important;
}
.dark-theme .content code {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #f1f5f9 !important;
}
.dark-theme .content table {
    background: rgba(15, 23, 42, 0.6) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}
.dark-theme .content th {
    background: rgba(30, 41, 59, 0.6) !important;
    color: #f1f5f9 !important;
}
.dark-theme .content td {
    border-bottom-color: rgba(255, 255, 255, 0.05) !important;
}
.dark-theme .content img {
    border-color: rgba(255, 255, 255, 0.1) !important;
}
.dark-theme .back-link {
    color: #b45f2b !important;
}
.dark-theme .back-link:hover {
    color: #f1f5f9 !important;
}

/* --- Комментарии --- */
.dark-theme #comments-section h2 {
    color: #f1f5f9 !important;
}
.dark-theme .comment-item {
    background: rgba(15, 23, 42, 0.6) !important;
    border-left: 3px solid #b45f2b !important;
    color: #e2e8f0 !important;
}
.dark-theme .comment-item:hover {
    background: rgba(15, 23, 42, 0.8) !important;
}
.dark-theme .comment-item strong {
    color: #f1f5f9 !important;
}
.dark-theme .comment-item .comment-date {
    color: #94a3b8 !important;
}
.dark-theme .reply-btn {
    color: #b45f2b !important;
    background: rgba(180, 95, 43, 0.15) !important;
}
.dark-theme .reply-btn:hover {
    background: rgba(180, 95, 43, 0.3) !important;
}
.dark-theme .loading-comments,
.dark-theme .error-feedback {
    color: #94a3b8 !important;
}

/* --- Формы, поля ввода, кнопки --- */
.dark-theme .modal-input,
.dark-theme input:not(.search-input):not(.premium-input):not([type="checkbox"]),
.dark-theme textarea,
.dark-theme select {
    background: #1e293b !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #e2e8f0 !important;
}
.dark-theme .modal-input:focus,
.dark-theme input:not(.search-input):not(.premium-input):focus,
.dark-theme textarea:focus {
    border-color: #b45f2b !important;
    outline: none !important;
}
.dark-theme .modal-input::placeholder,
.dark-theme input::placeholder,
.dark-theme textarea::placeholder {
    color: #94a3b8 !important;
}
.dark-theme label {
    color: #e2e8f0 !important;
}
.dark-theme .btn-feedback,
.dark-theme .btn-primary,
.dark-theme button:not(.view-btn):not(.page-btn):not(.modal-btn):not(.search-btn):not(.premium-btn) {
    background: linear-gradient(135deg, #b45f2b, #8a451f) !important;
    color: white !important;
}
.dark-theme .btn-feedback:hover,
.dark-theme .btn-primary:hover {
    background: linear-gradient(135deg, #c96d33, #9e5228) !important;
}
.dark-theme .btn-feedback[style*="background: #aaa"] {
    background: #4a4a4a !important;
    color: #cbd5e1 !important;
}
.dark-theme #commentFormMessage,
.dark-theme #captchaQuestion {
    color: #e2e8f0 !important;
}

/* --- Страница списка статей (articles.html) --- */
.dark-theme .articles-content {
    background: transparent !important;
}
.dark-theme .header-container {
    background: transparent !important;
}
.dark-theme .thesaurus-nav-item {
    color: #cbd5e1 !important;
}
.dark-theme .thesaurus-nav-item:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #b45f2b !important;
}
.dark-theme .thesaurus-nav-item.active {
    background: #b45f2b !important;
    color: white !important;
}
.dark-theme .premium-label {
    color: #e2e8f0 !important;
}
.dark-theme .premium-input {
    background: #1e293b !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #e2e8f0 !important;
}
.dark-theme .premium-input::placeholder {
    color: #94a3b8 !important;
}
.dark-theme .premium-btn {
    background: #b45f2b !important;
    color: white !important;
}
.dark-theme .premium-status {
    color: #94a3b8 !important;
}
.dark-theme .premium-status.error {
    color: #f87171 !important;
}
.dark-theme .view-btn {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #cbd5e1 !important;
}
.dark-theme .view-btn.active {
    background: #b45f2b !important;
    color: white !important;
}
.dark-theme .list-mode li {
    border-bottom-color: rgba(255, 255, 255, 0.05) !important;
}
.dark-theme .list-mode li a {
    color: #b45f2b !important;   /* яркий оранжевый */
}
.dark-theme .list-mode li a:hover {
    color: #f59e0b !important;   /* золотистый при наведении */
}
.dark-theme .list-mode .premium-locked a {
    color: #94a3b8 !important;
    opacity: 0.7 !important;
}
.dark-theme .icon-card {
    background: rgba(15, 23, 42, 0.6) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #b45f2b !important;   /* яркий оранжевый */
}
.dark-theme .icon-card:hover {
    border-color: #b45f2b !important;
    color: #f59e0b !important;   /* золотистый при наведении */
}
.dark-theme .icon-card.premium-locked {
    background: rgba(15, 23, 42, 0.3) !important;
    opacity: 0.7 !important;
}
.dark-theme .icon-card .book-icon {
    background: rgba(15, 23, 42, 0.4) !important;
    color: #b45f2b !important;
}
.dark-theme .icon-card .article-preview {
    background: rgba(15, 23, 42, 0.4) !important;
}
.dark-theme .icon-card .download-trigger {
    color: #94a3b8 !important;
}
.dark-theme .page-btn {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #cbd5e1 !important;
}
.dark-theme .page-btn.active-page {
    background: #b45f2b !important;
    color: white !important;
}
.dark-theme .search-input {
    background: #1e293b !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #e2e8f0 !important;
}
.dark-theme .search-input::placeholder {
    color: #94a3b8 !important;
}
.dark-theme .search-btn {
    background: #b45f2b !important;
    color: white !important;
}

/* --- Заметки (notes.html) в тёмной теме --- */
.dark-theme .note-item {
    background: rgba(15, 23, 42, 0.6) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}
.dark-theme .note-item h2 {
    color: #b45f2b !important;
}
.dark-theme .note-item .content {
    color: #e2e8f0 !important;
}
.dark-theme .note-item .meta {
    color: #94a3b8 !important;
}

/* --- Футер --- */
.dark-theme footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
    background: rgba(2, 6, 23, 0.5) !important;
}
.dark-theme .footer-links a {
    color: #cbd5e1 !important;
}
.dark-theme .footer-links a:hover {
    color: #b45f2b !important;
}
.dark-theme footer p {
    color: #94a3b8 !important;
}

/* --- Модальные окна --- */
.dark-theme .modal {
    background: rgba(0, 0, 0, 0.9) !important;
}
.dark-theme .modal-content {
    background: #1e293b !important;
    color: #e2e8f0 !important;
}
.dark-theme .modal-btn {
    background: #4a4a4a !important;
    color: #e2e8f0 !important;
}
.dark-theme .modal-btn.primary {
    background: #b45f2b !important;
    color: white !important;
}

/* --- Подсказки (tooltip) --- */
.dark-theme .tooltip-item .tooltip-text {
    background: #1e293b !important;
    color: #f1f5f9 !important;
}

/* --- Подкасты (podcasts.html) в тёмной теме --- */
.dark-theme .podcast-card {
    background: rgba(15, 23, 42, 0.6) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}
.dark-theme .podcast-title {
    color: #b45f2b !important;   /* яркий оранжевый */
}
.dark-theme .podcast-date {
    color: #94a3b8 !important;
    border-left-color: #b45f2b !important;
}
.dark-theme .podcast-description {
    color: #e2e8f0 !important;
}
.dark-theme audio {
    background: #1e293b !important;
    border-radius: 40px !important;
}

/* === Капча в тёмной теме === */
.dark-theme #captchaQuestion {
    color: #e2e8f0 !important;
}
.dark-theme #captchaInput {
    background: #1e293b !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #e2e8f0 !important;
}
.dark-theme #captchaInput::placeholder {
    color: #94a3b8 !important;
}
/* Переопределяем фон и рамку блока капчи (у него инлайн-стиль) */
.dark-theme div[style*="background: #f0ebe6;"] {
    background: rgba(15, 23, 42, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

