/*
Theme Name: Discover Lite
Theme URI: https://example.com/discover-lite
Author: Your Name
Author URI: https://example.com/
Description: A fast, modern, and responsive theme optimized for Google Discover and high CTR.
Version: 1.1.0
Requires at least: 5.8
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: discover-lite
Tags: blog, one-column, two-columns, right-sidebar, custom-background, custom-colors, custom-logo, custom-menu, featured-images, block-styles, full-site-editing, sticky-post, threaded-comments, translation-ready, wide-blocks, block-editor-styles, accessibility-ready
*/

:root {
	--base-font-size: 17px; --main-content-width: 65%; --sidebar-width: 30%; --gap-width: 5%; --primary-color: #0073aa; --background-color: #f9f9f9; --content-bg-color: #ffffff; --text-color: #333333; --heading-color: #222222; --border-color: #e5e5e5; --subtle-bg-color: #f5f5f5; --meta-color: #666666;
}
body.dark-mode {
    --primary-color: #69b4de; --background-color: #121212; --content-bg-color: #1e1e1e; --text-color: #e0e0e0; --heading-color: #ffffff; --border-color: #333333; --subtle-bg-color: #2a2a2a; --meta-color: #999999;
}
body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif; line-height: 1.7; background-color: var(--background-color); color: var(--text-color); margin: 0; font-size: var(--base-font-size); transition: background-color 0.3s, color 0.3s; }
*, *:before, *:after { box-sizing: border-box; }
img { max-width: 100%; height: auto; vertical-align: middle; }
a { color: var(--primary-color); text-decoration: none; }
a:hover { text-decoration: underline; }
.screen-reader-text { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.screen-reader-text:focus { position: static; width: auto; height: auto; }
.site { max-width: 1200px; margin: 0 auto; background-color: var(--background-color); box-shadow: none; }
body.light-mode .site { background-color: var(--background-color); }
#page { background-color: var(--content-bg-color); }
.site-header { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; padding: 1rem 2rem; border-bottom: 1px solid var(--border-color); }
.site-title a { text-decoration: none; color: var(--heading-color); }
.site-description { font-size: 0.9rem; color: var(--meta-color); }
.header-navigation-area { display: flex; align-items: center; gap: 1.5rem; }
.main-navigation ul { list-style: none; margin: 0; padding: 0; display: flex; }
.main-navigation li { margin-left: 1.5rem; }
.main-navigation a { text-decoration: none; color: var(--text-color); font-weight: 500; }
.dark-mode-toggle { background: var(--subtle-bg-color); border: 1px solid var(--border-color); border-radius: 50%; cursor: pointer; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; padding: 0; }
.dark-mode-toggle .toggle-icon { width: 18px; height: 18px; border-radius: 50%; background: var(--heading-color); position: relative; transition: all 0.3s; }
body.dark-mode .dark-mode-toggle .toggle-icon { background: #f1c40f; box-shadow: 0 0 5px #f1c40f; }
.site-content { display: flex; flex-wrap: wrap; padding: 2rem; }
#primary, .content-area { width: 100%; }
#secondary { width: 100%; }
@media (min-width: 768px) { #primary, .content-area { width: var(--main-content-width); } #secondary { width: var(--sidebar-width); padding-left: var(--gap-width); } }
.list-layout-post { background-color: var(--content-bg-color); border: 1px solid var(--border-color); border-radius: 8px; padding: 1.5rem; margin-bottom: 1.5rem; box-shadow: 0 4px 12px rgba(0,0,0,0.05); }
body.dark-mode .list-layout-post { box-shadow: none; }
.list-layout-post .entry-wrapper { display: flex; gap: 1.5rem; align-items: flex-start; }
.list-layout-post .post-thumbnail-wrapper { flex-shrink: 0; width: 200px; }
.list-layout-post .post-thumbnail-wrapper img { border-radius: 8px; display: block; }
.list-layout-post .entry-title { font-size: 1.5rem; line-height: 1.3; margin: 0 0 0.5rem 0; }
.list-layout-post .entry-meta { font-size: 0.9em; color: var(--meta-color); margin-bottom: 0.75rem; }
.list-layout-post .entry-summary p { margin: 0; color: var(--text-color); }
article.post:not(.list-layout-post) { margin-bottom: 3rem; padding-bottom: 2rem; border-bottom: 1px solid var(--border-color); }
article.post:last-child { border-bottom: none; }
.entry-title { font-size: 2.2rem; line-height: 1.2; margin-top: 0; margin-bottom: 0.5rem; }
.entry-title a { color: var(--heading-color); }
.entry-meta { font-size: 0.9em; color: var(--meta-color); margin-bottom: 1rem; }
.post-thumbnail { margin: 1.5rem 0; }
.entry-content p, .entry-content ul, .entry-content ol { margin-bottom: 1.5em; }
.dl-toc { border: 1px solid var(--border-color); border-radius: 5px; margin-bottom: 2em; background-color: var(--subtle-bg-color); }
.dl-toc-toggle { font-size: 1.2rem; padding: 1rem; cursor: pointer; display: flex; justify-content: space-between; align-items: center; font-weight: bold; }
.dl-toc-icon { width: 0; height: 0; border-left: 5px solid transparent; border-right: 5px solid transparent; border-top: 5px solid currentColor; transition: transform 0.3s; }
.dl-toc.is-open .dl-toc-icon { transform: rotate(180deg); }
.dl-toc-list { list-style: decimal; padding: 0 1rem 1rem 3rem; margin: 0; max-height: 0; overflow: hidden; transition: all 0.3s ease-in-out; }
.dl-toc.is-open .dl-toc-list { max-height: 500px; overflow-y: auto; }
.dl-toc .dl-toc-sublist { padding-left: 1.5rem; list-style-type: lower-alpha; }
.dl-toc a { font-weight: 500; }
.dl-toc a:hover { text-decoration: underline; }
.entry-content .related-posts { background: var(--subtle-bg-color); border: 1px solid var(--border-color); padding: 1.5em; margin: 2em 0; }
.related-posts h3 { margin-top: 0; font-size: 1.2rem; }
.related-posts ul { list-style-type: none; margin: 0; padding: 0; }
.related-posts ul li { padding: 0.5em 0; border-bottom: 1px dotted #ccc; }
body.dark-mode .related-posts ul li { border-color: #444; }
.related-posts ul li:last-child { border-bottom: none; padding-bottom: 0; }
.entry-footer { font-size: 0.9em; color: var(--meta-color); }
.tags-links a { display: inline-block; background: var(--subtle-bg-color); padding: 4px 8px; margin: 2px; text-decoration: none; color: var(--text-color); border-radius: 3px; }
.widget { margin-bottom: 2rem; background-color: var(--subtle-bg-color); padding: 1.5rem; border-radius: 5px; }
.widget-title { font-size: 1.2rem; margin-top: 0; margin-bottom: 1rem; border-bottom: 2px solid var(--border-color); padding-bottom: 0.5rem; color: var(--heading-color); }
.widget ul { list-style: none; padding: 0; margin: 0; }
.widget_categories ul, .widget_tag_cloud .tagcloud { display: flex; flex-wrap: wrap; gap: 8px; }
.widget_categories li, .widget_tag_cloud .tag-cloud-link { padding: 0 !important; }
.widget_categories a, .widget_tag_cloud .tag-cloud-link { display: inline-flex; align-items: center; gap: 0.5em; padding: 5px 15px; border: 1px solid var(--border-color); border-radius: 20px; text-decoration: none; color: var(--text-color); font-size: 14px !important; }
.widget_categories a:hover, .widget_tag_cloud .tag-cloud-link:hover { background-color: var(--border-color); text-decoration: none; }
.widget_categories a .count { opacity: 0.7; }
.widget_archive ul { display: flex; flex-direction: column; gap: 8px; }
.widget_archive li { display: flex; justify-content: space-between; align-items: center; padding: 8px 15px; border: 1px solid var(--border-color); border-radius: 20px; text-decoration: none; }
.widget_archive li:hover { background-color: var(--border-color); }
.widget_archive li a { border: none; padding: 0; flex-grow: 1; text-decoration: none; }
.widget_archive li a:hover { background-color: transparent; }
.page-header { padding-bottom: 2rem; margin-bottom: 2rem; border-bottom: 1px solid var(--border-color); }
.page-header .page-title { font-size: 1.8rem; color: var(--heading-color); }
.archive-grid { display: grid; gap: 2rem; }
@media (min-width: 768px) { .archive-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .archive-grid { grid-template-columns: repeat(3, 1fr); } }
.archive-post-card { background: var(--content-bg-color); border: 1px solid var(--border-color); border-radius: 5px; box-shadow: 0 2px 8px rgba(0,0,0,0.08); overflow: hidden; transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out; margin-bottom: 0; padding-bottom: 0; display: flex; flex-direction: column; }
.archive-post-card .card-inner { display: flex; flex-direction: column; height: 100%; }
.archive-post-card .card-content { padding: 1rem 1.5rem; flex-grow: 1; }
.archive-post-card .entry-title { font-size: 1.2rem; line-height: 1.3; margin-bottom: 0.5rem; }
.archive-post-card .entry-meta { font-size: 0.8rem; }
.placeholder-thumbnail { width: 100%; padding-bottom: 75%; background-color: var(--subtle-bg-color); }
body.dark-mode .archive-post-card { box-shadow: none; }
.archive-post-card:hover { transform: translateY(-5px); box-shadow: 0 5px 15px rgba(0,0,0,0.12); }
body.dark-mode .archive-post-card:hover { box-shadow: 0 0 15px rgba(255, 255, 255, 0.05); }
.ad-container { margin: 2rem 0; text-align: center; }
.ad-container .ad-widget { background: transparent; padding: 0; }
.post-navigation-modern { display: flex; flex-wrap: wrap; gap: 2rem; border-top: 1px solid var(--border-color); padding-top: 2rem; margin-top: 2rem; }
.post-navigation-modern > div { flex: 1 1 300px; }
.post-navigation-modern a { display: block; background: var(--subtle-bg-color); padding: 1.5rem; border-radius: 5px; text-decoration: none; transition: background-color 0.3s; height: 100%; }
.post-navigation-modern a:hover { background-color: var(--border-color); text-decoration: none; }
.post-navigation-modern .nav-subtitle { font-size: 0.8em; color: var(--meta-color); text-transform: uppercase; letter-spacing: 1px; }
.post-navigation-modern .nav-post-thumb { margin: 1rem 0; }
.post-navigation-modern .nav-post-thumb img { border-radius: 3px; }
.post-navigation-modern .nav-title { font-size: 1.2rem; color: var(--heading-color); font-weight: bold; line-height: 1.3; }
.post-navigation-modern a.no-thumbnail { display: flex; flex-direction: column; justify-content: center; text-align: center; }
.post-navigation-modern a.no-thumbnail .nav-title { font-size: 1.5rem; }
.pagination { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: 2rem; }
.page-numbers-item .page-numbers { display: inline-block; padding: 8px 14px; border: 1px solid var(--border-color); background: var(--content-bg-color); text-decoration: none; color: var(--text-color); border-radius: 3px; }
.page-numbers-item .page-numbers:hover { background: var(--subtle-bg-color); border-color: var(--meta-color); }
.page-numbers-item .page-numbers.current { background: var(--primary-color); color: #fff; border-color: var(--primary-color); }
.comments-area { border-top: 1px solid var(--border-color); margin-top: 2rem; padding-top: 2rem; }
.comments-title { color: var(--heading-color); }
.comment-list { list-style: none; padding: 0; }
.comment-list .comment-body { border-bottom: 1px solid var(--border-color); padding-bottom: 1.5em; margin-bottom: 1.5em; }
.comment-author { font-weight: bold; color: var(--heading-color); }
.comment-metadata { font-size: 0.85em; color: var(--meta-color); }
.comment-reply-link { font-size: 0.85em; text-decoration: none; font-weight: bold; color: var(--primary-color); background: var(--subtle-bg-color); padding: 3px 8px; border-radius: 3px; }
.comment-form input, .comment-form textarea { width: 100%; padding: 10px; border: 1px solid var(--border-color); border-radius: 3px; background-color: var(--subtle-bg-color); color: var(--text-color); }
.comment-form .submit { background: var(--primary-color); color: #fff; border: none; padding: 10px 20px; cursor: pointer; border-radius: 5px; font-weight: bold; width: 100%; }
.comment-form p.comment-notes, .comment-form p.logged-in-as { color: var(--meta-color); }
.after-comments-popular { margin-top: 3rem; padding-top: 3rem; border-top: 1px solid var(--border-color); }
.after-comments-popular .section-title { font-size: 1.8rem; margin-bottom: 2rem; text-align: center; }
.after-comments-popular-list { list-style: none; padding: 0; margin: 0; }
.after-comments-popular-list li { display: flex; align-items: baseline; gap: 1rem; padding: 0.75rem 0; border-bottom: 1px solid var(--border-color); }
.after-comments-popular-list li:last-child { border-bottom: none; }
.popular-post-number { font-size: 1.5rem; font-weight: bold; color: var(--meta-color); min-width: 40px; text-align: right; }
.popular-post-title { font-weight: 500; font-size: 1rem; color: var(--text-color); }
.site-footer { padding: 2rem; text-align: center; background-color: var(--subtle-bg-color); font-size: 0.9rem; color: var(--text-color); border-top: 1px solid var(--border-color); }
@media (max-width: 767px) {
    .site-content { padding: 1rem; }
    .site-header { padding: 1rem; }
    .list-layout-post .entry-wrapper { flex-direction: column; }
    .list-layout-post .post-thumbnail-wrapper { width: 100%; }
    .list-layout-post .entry-title { font-size: 1.3rem; }
}