/* Theme Name: Flavor Developer
Theme URI: https://example.com/flavor-developer
Author: Kiro
Author URI: https://example.com
Description: A high-contrast, minimal dark developer blog theme. Clean, readable, no nonsense.
Version: 2.0.0
Requires at least: 5.9
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: flavor-developer
Tags: blog, one-column, custom-menu, featured-images, translation-ready
*/

:root {
    --bg: #F8F5EF;
    --bg-alt: #111;
    --text: #252525;
    --text-dim: #000;
    --accent: #e8e8e8;
    --border: #222;
    --font: consolas;
    --font-mono: 'SFMono-Regular', Consolas, 'Courier New', monospace;
    --max-width: 900px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: "DM Sans", sans-serif;
	font-optical-sizing: auto;
	font-weight: 400px;
	font-style: normal;
    font-size: 17px;
    line-height: 1.7;
    color: var(--text);
    background: var(--bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--text); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: #444; }
a:hover { text-decoration-color: var(--text); }
img { max-width: 100%; height: auto; display: block; }

.site-wrapper { flex: 1; display: flex; flex-direction: column; }
.container { width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }

/* ===== Header ===== */
.site-header { padding: 20px 0; }
.header-inner { display: flex; align-items: baseline; justify-content: space-between; }
.site-branding .site-title { font-size: 15px; font-weight: 600; margin: 0; }
.site-branding .site-title a { font-size: 1.5em; color: var(--text); text-decoration: none; }
.site-description { display: none; }

.main-navigation { display: flex; align-items: baseline; }
.nav-menu { display: flex; list-style: none; gap: 0; }
.nav-menu li a { color: var(--text-dim); font-size: 14px; padding: 2px 8px; text-decoration: none; }
.nav-menu li a:hover, .nav-menu li.current-menu-item a { color: var(--text); }
.menu-toggle { display: none; background: none; border: none; color: var(--text); font-size: 20px; cursor: pointer; }
.theme-toggle { display: none; }

/* ===== Hero ===== */
.site-hero { padding: 48px 0 32px; }
.site-hero .hero-emoji { font-size: 28px; margin-bottom: 8px; display: block; }
.site-hero .hero-title { display:none }
.site-hero .hero-subtitle { font-size: 15px; color: var(--text-dim); margin-top: 4px; }

/* ===== Article List ===== */
.articles-section { padding: 0 0 48px; }
.section-heading { font-size: 12px; font-weight: 600; letter-spacing: 0.5px; text-transform: uppercase; color: var(--text-dim); margin-bottom: 16px; }

.article-list { list-style: none; }
.article-item { display: flex; align-items: baseline; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.article-item:last-child { border-bottom: none; }
.article-date { font-size: 13px; color: var(--text-dim); font-family: var(--font-mono); white-space: nowrap; }
.article-title { font-size: 16px; font-weight: 500; line-height: 1.4; }
.article-title a { color: var(--text); text-decoration: none; }
.article-title a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ===== Single Post ===== */
.post-header { padding: 48px 0 24px; }
.post-header .post-title { font-size: 28px; font-weight: 700; line-height: 1.25; letter-spacing: -0.5px; margin-bottom: 12px; }
.post-meta { color: var(--text-dim); font-size: 14px; display: flex; gap: 12px; flex-wrap: wrap; }

.post-content { padding: 0 0 48px; }
.post-content h2 { font-size: 22px; font-weight: 700; margin: 40px 0 12px; letter-spacing: -0.3px; }
.post-content h3 { font-size: 18px; font-weight: 600; margin: 32px 0 10px; }
.post-content h4 { font-size: 16px; font-weight: 600; margin: 24px 0 8px; }
.post-content p { margin-bottom: 16px; color: #000; }
.post-content ul, .post-content ol { margin-bottom: 16px; padding-left: 20px; color: #000; }
.post-content li { margin-bottom: 6px; }

.post-content blockquote {
    border-left: 3px solid #333;
    padding: 8px 16px;
    margin: 20px 0;
    color: #aaa;
    font-style: italic;
}
.post-content blockquote p { margin: 0; color: #aaa; }

.post-content pre {
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 14px;
    overflow-x: auto;
    margin: 20px 0;
    font-family: var(--font-mono);
    font-size: 14px;
    line-height: 1.5;
    color: #ccc;
}
.post-content code { font-family: var(--font-mono); font-size: 15px; background: var(--bg-alt); padding: 2px 5px; border-radius: 3px; }
.post-content pre code { background: none; padding: 0; }
.post-content img { margin: 24px 0; border-radius: 4px; }
.post-content a { text-decoration-color: #555; }
.post-content a:hover { text-decoration-color: var(--text);}

/* ===== Tags ===== */
.post-tags { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--border); }
.post-tags a { display: inline-block; font-size: 13px; color: var(--text-dim); margin-right: 8px; text-decoration: none; }
.post-tags a:hover { color: var(--text); }

/* ===== Post Nav ===== */
.post-navigation { padding: 20px 0 48px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; gap: 16px; }
.post-navigation .nav-previous, .post-navigation .nav-next { flex: 1; }
.post-navigation .nav-next { text-align: right; }
.post-navigation a { font-size: 14px; color: var(--text-dim); text-decoration: none; }
.post-navigation a:hover { color: var(--text); }
.post-navigation .nav-label { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-dim); opacity: 0.6; margin-bottom: 2px; }

/* ===== Page ===== */
.page-header { padding: 48px 0 24px; }
.page-header .page-title { font-size: 28px; font-weight: 700; letter-spacing: -0.5px; }
.page-content { padding: 0 0 48px; }
.page-content p { margin-bottom: 16px; color: #ccc; }

/* ===== Archive ===== */
.archive-header { padding: 48px 0 16px; margin-bottom: 16px; }
.archive-header .archive-title { font-size: 22px; font-weight: 700; }
.archive-header .archive-description { color: var(--text-dim); margin-top: 4px; font-size: 15px; }

/* ===== Pagination ===== */
.pagination { padding: 24px 0; display: flex; justify-content: center; gap: 6px; }
.pagination .page-numbers { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; font-size: 14px; color: var(--text-dim); text-decoration: none; }
.pagination .page-numbers.current { color: var(--text); font-weight: 600; }
.pagination .page-numbers:hover { color: var(--text); }

/* ===== Footer ===== */
.site-footer { padding: 24px 0; margin-top: auto; }
.footer-inner { text-align: center; color: var(--text-dim); font-size: 13px; }
.footer-inner a { color: var(--text-dim); text-decoration: none; }
.footer-inner a:hover { color: var(--text); }

/* ===== Search ===== */
.search-form { display: flex; gap: 6px; }
.search-form .search-field { flex: 1; padding: 8px 12px; border: 1px solid var(--border); background: var(--bg); color: var(--text); font-family: var(--font); font-size: 15px; border-radius: 4px; }
.search-form .search-field:focus { outline: none; border-color: #444; }
.search-form .search-submit { background: none; color: var(--text); border: 1px solid var(--border); padding: 8px 14px; font-size: 14px; cursor: pointer; border-radius: 4px; }
.search-form .search-submit:hover { border-color: #444; }

/* ===== 404 ===== */
.error-404 { padding: 64px 0; text-align: center; }
.error-404 .error-code { font-size: 56px; font-weight: 700; margin-bottom: 8px; }
.error-404 h1 { font-size: 18px; margin-bottom: 8px; }
.error-404 p { color: var(--text-dim); margin-bottom: 16px; }

/* ===== Widgets ===== */
.widget { margin-bottom: 20px; }
.widget-title { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-dim); margin-bottom: 6px; }
.widget ul { list-style: none; }
.widget ul li { padding: 4px 0; font-size: 14px; }
.widget ul li a { color: var(--text-dim); text-decoration: none; }
.widget ul li a:hover { color: var(--text); }

/* ===== A11y ===== */
.screen-reader-text { clip: rect(1px,1px,1px,1px); position: absolute !important; height: 1px; width: 1px; overflow: hidden; }
.skip-link { position: absolute; top: -100px; left: 0; background: var(--text); color: var(--bg); padding: 6px 12px; z-index: 10000; text-decoration: none; }
.skip-link:focus { top: 0; }

/* ===== Responsive ===== */
@media (max-width: 640px) {
    .header-inner { position: relative; }
    .menu-toggle { display: block; }
    .nav-menu { display: none; position: absolute; top: 100%; right: 0; background: var(--bg); border: 1px solid var(--border); padding: 8px; flex-direction: column; }
    .nav-menu.active { display: flex; }
    .site-hero .hero-title { font-size: 20px; }
    .post-header .post-title { font-size: 22px; }
    .post-navigation { flex-direction: column; }
    .post-navigation .nav-next { text-align: left; }
}

/* ===== Sidebar Layout ===== */
.content-with-sidebar {
    display: flex;
    gap: 40px;
    align-items: flex-start;
}

.content-area {
    flex: 1;
    min-width: 0;
}

.sidebar-categories {
    width: 240px;
    flex-shrink: 0;
    position: sticky;
	padding: 5px 10px;
    top: 80px;
	background: rgba(255,255,255,0.8);
	border-radius: 5px;
}

.sidebar-categories .sidebar-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-dim);
    margin-bottom: 10px;
}

.sidebar-categories ul {
    list-style: none;
}

.sidebar-categories ul li {
    padding: 4px 0;
}

.sidebar-categories ul li a {
    font-size: 14px;
    color: var(--text-dim);
    text-decoration: none;
}

.sidebar-categories ul li a:hover {
    color: var(--text);
}

.sidebar-categories ul li.current-cat a {
    color: var(--text);
    font-weight: 600;
}

.sidebar-categories ul li .cat-count {
    font-size: 12px;
    color: var(--text-dim);
    opacity: 0.6;
    margin-left: 4px;
}

@media (max-width: 768px) {
    .content-with-sidebar {
        flex-direction: column;
        gap: 24px;
    }
    .sidebar-categories {
        width: 100%;
        position: static;
        padding-top: 0;
        border-top: 1px solid var(--border);
        padding-top: 16px;
    }
}
