/*
 * ÇandName CSS modülü: İçerik sayfaları
 * Yazı, sayfa, arşiv, arama, yorumlar.
 * Bu dosya diğer CSS dosyalarından bağımsızdır; hata yalnızca bu alanı etkiler.
 * Yükleme sırası: inc/assets.php
 */

/* ------------------------------------------------------------------
   9. Single, page, archive
------------------------------------------------------------------ */
.layout { display: grid; gap: 40px; padding-block: 40px 8px; padding-inline: var(--gutter); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 960px) { .layout.has-sidebar { grid-template-columns: minmax(0, 1fr) 300px; } }
/* Single post, widgets under the featured image: title, bar and image are full width; text and sidebar share the row below. */
.entry-split { display: grid; gap: 40px; grid-template-columns: minmax(0, 1fr); }
.entry-main { min-width: 0; }
@media (min-width: 960px) { .entry-split.has-sidebar { grid-template-columns: minmax(0, 1fr) 300px; } }
.entry { min-width: 0; }
.entry > * { max-width: 100%; }
.entry-header { margin-bottom: 24px; display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.entry-title { font-size: calc(clamp(30px, 4.4vw, 46px) * var(--fs, 1)); font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; }
.entry-meta { color: var(--muted); font-size: calc(13px * var(--fs, 1)); display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; }
.entry-meta .meta-item { display: inline-flex; align-items: center; gap: 6px; }
.entry-meta .meta-icon { font-size: calc(13px * var(--fs, 1)); color: var(--muted); }
.entry-meta .meta-photo { width: 22px; height: 22px; border-radius: 50%; object-fit: cover; flex: none; }
.entry-meta a { color: var(--green); font-weight: 600; }
.entry-thumb { margin: 0 0 28px; border-radius: 4px; overflow: hidden; }
.entry-thumb img { display: block; width: 100%; height: auto; }
.entry-content { font-size: calc(18px * var(--fs, 1) * var(--reader-fs, 1)); line-height: 1.75; color: #2b312d; overflow-wrap: break-word; }
.entry-content > * { max-width: 100%; margin-inline: 0; }
.entry-content > .alignwide, .entry-content > .alignfull, .entry-content > figure, .entry-content > .wp-block-image { max-width: 100%; }
.entry-content p { margin: 0 0 1.3em; }
/* In-post headings: 1 px steps above the normal text (18 px): h6 19 px up to h1 24 px. */
.entry-content h5, .entry-content h6 { font-family: var(--serif); line-height: 1.2; margin: 1.3em 0 0.5em; }
.entry-content h1 { font-size: calc(24px * var(--fs, 1)); margin: 1.7em 0 0.6em; }
.entry-content h2 { font-size: calc(23px * var(--fs, 1)); margin: 1.6em 0 0.6em; }
.entry-content h3 { font-size: calc(22px * var(--fs, 1)); margin: 1.5em 0 0.5em; }
.entry-content h4 { font-size: calc(21px * var(--fs, 1)); margin: 1.4em 0 0.5em; }
.entry-content h5 { font-size: calc(20px * var(--fs, 1)); }
.entry-content h6 { font-size: calc(19px * var(--fs, 1)); }
.entry-content a { color: var(--green); text-decoration: underline; text-underline-offset: 3px; }
.entry-content ul, .entry-content ol { padding-inline-start: 1.2em; margin-block: 0 1.3em; list-style-position: outside; }
.entry-content li { margin: 0 0 0.4em; padding-inline-start: 0.1em; }
.entry-content li > ul, .entry-content li > ol { margin: 0.4em 0 0.2em; padding-inline-start: 1.1em; }
.entry-content li > p { margin: 0 0 0.5em; }
.entry-content blockquote { margin: 1.6em 0; padding: 4px 0 4px 22px; border-inline-start: 4px solid var(--gold); font-family: var(--serif); font-size: calc(22px * var(--fs, 1)); line-height: 1.5; color: var(--ink); }
.entry-content img { border-radius: 3px; }
.entry-content figcaption { font-size: calc(13px * var(--fs, 1)); color: var(--muted); margin-top: 8px; }
.entry-content pre { background: var(--surface); padding: 16px; overflow-x: auto; border: 1px solid var(--line); font-size: calc(14px * var(--fs, 1)); }
.entry-content table { width: 100%; border-collapse: collapse; font-size: calc(15px * var(--fs, 1)); display: block; overflow-x: auto; }
.entry-content th, .entry-content td { border: 1px solid var(--line); padding: 8px 12px; text-align: start; }
.entry-content iframe, .entry-content embed, .entry-content object, .entry-content video, .entry-content figure, .entry-content .wp-caption, .entry-content .wp-block-embed { max-width: 100%; }
.entry-content .wp-caption { width: auto; }
.entry-content img { height: auto; }
.entry-footer { max-width: 100%; margin: 28px 0 0; }
.tag-list { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-list a { background: var(--surface); border: 1px solid var(--line); padding: 4px 12px; border-radius: 999px; font-size: calc(13px * var(--fs, 1)); }
.tag-list a:hover { border-color: var(--green); color: var(--green); }
.post-nav, .author-box, .related, .comments { max-width: 100%; margin-inline: 0; }

.author-box { margin-top: 40px; background: var(--surface); border-radius: 4px; padding: 14px; display: flex; gap: 16px; align-items: flex-start; }
/* Initials avatar (no photo): a round badge, letters centred. */
.avatar-initials { display: inline-flex; align-items: center; justify-content: center; flex: none; box-sizing: border-box; border-radius: 50%; background: var(--mint); color: var(--green); font-weight: 700; line-height: 1; text-align: center; text-transform: uppercase; overflow: hidden; }
.avatar-photo { flex: none; border-radius: 50%; object-fit: cover; }
.author-box .avatar-initials { width: 56px; height: 56px; font-size: calc(18px * var(--fs, 1)); }
.author-box h2 { font-size: calc(20px * var(--fs, 1)); margin-bottom: 4px; }
.author-box p { margin: 0; color: var(--body); }
.author-box + .author-box { margin-top: 12px; }
.author-box-all { margin-inline-start: auto; align-self: center; color: var(--green); font-size: calc(13px * var(--fs, 1)); font-weight: 600; white-space: nowrap; }
.author-box-all:hover { text-decoration: underline; }
@media (max-width: 520px) { .author-box { flex-wrap: wrap; } .author-box-all { flex-basis: 100%; margin-inline-start: 0; } }
.author-box .author-role { font-size: calc(13px * var(--fs, 1)); color: var(--muted); margin-bottom: 6px; }

.author-stats { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 0; font-size: calc(14px * var(--fs, 1)); color: var(--muted); }
.author-stats strong { color: var(--ink); }
.authors-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; margin: 24px 0 48px; }
.author-card { background: var(--surface); border-radius: 4px; padding: 12px; display: flex; gap: 16px; align-items: flex-start; }
.author-card .avatar-initials { width: 64px; height: 64px; font-size: calc(20px * var(--fs, 1)); flex: 0 0 auto; }
@media (max-width: 599px) { .authors-grid { grid-template-columns: minmax(0, 1fr); } }
@media (min-width: 600px) and (max-width: 959px) { .authors-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.author-card h2 { font-size: calc(18px * var(--fs, 1)); margin-bottom: 4px; }
.author-card .author-role { font-size: calc(13px * var(--fs, 1)); color: var(--muted); margin: 0 0 6px; }

.related { margin-top: 48px; max-width: none; }
.related .cards { margin-top: 20px; }
/* Related posts: 4 posts. 4 columns when the column is wide, 2 columns on tablets (or next to the sidebar), 1 column on phones. Measured on the box itself (container query), not on the screen, because the sidebar takes part of the width. Browsers without container queries show 1 column. */
.related { container-type: inline-size; }
.related .cards--related { grid-template-columns: minmax(0, 1fr); }
.related .cards--related .card-title { font-size: calc(16px * var(--fs, 1)); }
@container (min-width: 440px) { .related .cards--related { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container (min-width: 840px) { .related .cards--related { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.page-header { padding: 40px var(--gutter) 0; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.page-title { font-size: calc(clamp(28px, 4vw, 40px) * var(--fs, 1)); font-weight: 700; letter-spacing: -0.02em; }
.page-description { color: var(--body); max-width: 680px; margin: 0; }
.author-header { display: flex; gap: 20px; align-items: center; }
.author-header .avatar-initials { width: 72px; height: 72px; font-size: calc(24px * var(--fs, 1)); }
.archive-wrap { padding: 0 var(--gutter); }
.archive-wrap .search { margin-top: 12px; width: 100%; }
/* Search form inside page headers (search, 404): a column flex container must not stretch it to 320px tall. */
.page-header .search { flex: 0 0 auto; width: 100%; max-width: 720px; margin-top: 8px; }
/* Empty search page: nothing but a centered search box (Google style). */
.search-landing { display: flex; align-items: center; justify-content: center; min-height: 60vh; min-height: 60svh; padding: 0 var(--gutter); }
.search-landing .search { flex: 1 1 auto; width: 100%; max-width: 640px; height: 52px; border-radius: 26px; }
.search-browse-title { margin: 28px 0 12px; font-weight: 600; color: var(--ink); }

.pagination { margin: 40px 0 0; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.page-numbers { padding: 8px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 3px; }
.page-numbers.current { background: var(--green); border-color: var(--green); color: #fff; }
a.page-numbers:hover { border-color: var(--green); color: var(--green); }
.no-results { padding: 28px 0 0; color: var(--body); }
.main-end { padding-bottom: 8px; }

/* Comments */
.comments { margin-top: 48px; }
.comments-title, .comment-reply-title { font-size: calc(24px * var(--fs, 1)); margin-bottom: 16px; }
.comment-list { list-style: none; margin: 0 0 24px; padding: 0; }
.comment-list .children { list-style: none; padding-inline-start: 24px; }
.comment-body { background: var(--surface); border-radius: 4px; padding: 16px 20px; margin-bottom: 12px; }
.comment-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; font-size: calc(13px * var(--fs, 1)); color: var(--muted); margin-bottom: 8px; }
.comment-author { display: flex; align-items: center; gap: 10px; font-weight: 600; color: var(--ink); }
.comment-author img { border-radius: 50%; }
.comment-form label { display: block; font-weight: 600; margin-bottom: 4px; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea {
	width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 3px; font: inherit; background: var(--surface);
}
.comment-form .submit { background: var(--green); color: #fff; border: 0; padding: 12px 24px; border-radius: 3px; font-weight: 600; cursor: pointer; }
