/*
Theme Name: Katinka Baltazar
Theme URI: https://katinkabaltazar.com
Author: Katinka Baltazar
Description: A clean, magazine-style block theme for katinka.me. White pages, black footer, Fraunces + Inter typography, an Author’s Note intro, and a paged list of the latest posts with a Subscribe + Recent Comments footer.
Requires at least: 6.5
Tested up to: 6.8
Requires PHP: 7.4
Version: 1.1.0
License: All rights reserved
Text Domain: katinkabaltazar
*/

/* Most styling lives in theme.json. These rules cover details theme.json can't express. */

.kb-kicker,
.kb-kicker a,
.wp-block-post-terms.kb-kicker a {
	font-family: var(--wp--preset--font-family--inter);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .14em;
	text-transform: uppercase;
	color: var(--wp--preset--color--garnet);
	text-decoration: none;
}

.kb-pill {
	display: inline-block;
	background: var(--wp--preset--color--marigold);
	color: #fff;
	font: 700 11.5px/1 var(--wp--preset--font-family--inter);
	letter-spacing: .14em;
	text-transform: uppercase;
	padding: 8px 11px;
}

.kb-more a,
a.kb-more {
	font-family: var(--wp--preset--font-family--inter);
	font-size: 12.5px;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--wp--preset--color--garnet);
	text-decoration: none;
}

/* Header */
header.wp-block-template-part {
	position: sticky;
	top: 0;
	z-index: 50;
	background: var(--wp--preset--color--paper);
}
.admin-bar header.wp-block-template-part { top: 32px; }
.kb-header { border-bottom: 2px solid var(--wp--preset--color--ink); }
.kb-header .wp-block-site-title a { text-decoration: none; }
/* Menu links: hover and current page change color only, no underline */
.wp-block-navigation .wp-block-navigation-item__content { text-decoration: none !important; }
.wp-block-navigation .wp-block-navigation-item__content:hover,
.wp-block-navigation .wp-block-navigation-item__content:focus,
.wp-block-navigation .current-menu-item > .wp-block-navigation-item__content {
	color: var(--wp--preset--color--garnet) !important;
}
.kb-footer .wp-block-navigation .wp-block-navigation-item__content:hover { color: #e05a6c !important; }

/* Search in the menu bar: just an icon until clicked, then the field slides open */
.kb-nav-search .wp-block-search__button {
	background: transparent !important;
	color: var(--wp--preset--color--ink) !important;
	border: 0 !important;
	padding: 6px !important;
}
.kb-nav-search .wp-block-search__button:hover { color: var(--wp--preset--color--garnet) !important; }
.kb-nav-search .wp-block-search__input {
	border: 1px solid var(--wp--preset--color--ink);
	border-radius: 999px;
	padding: 6px 14px;
	font-size: 14px;
}
/* Closed search takes only the icon's width, so the menu lines up with the page edge.
   When opened, the field slides out to the left over the menu instead of pushing it. */
.kb-nav-search { position: relative; }
.kb-nav-search .wp-block-search__inside-wrapper { width: auto !important; }
.kb-nav-search:not(.wp-block-search__searchfield-hidden) .wp-block-search__input {
	position: absolute;
	right: 100%;
	top: 50%;
	transform: translateY(-50%);
	width: 240px !important;
	margin-right: 6px;
	background: var(--wp--preset--color--paper);
	z-index: 5;
}
@media (max-width: 600px) {
	.admin-bar header.wp-block-template-part { top: 0; }
}

/* Section heads */
.kb-sec-head { border-top: 2px solid var(--wp--preset--color--ink); }
.kb-sec-head em { color: var(--wp--preset--color--garnet); font-weight: 500; }

/* Card hover */
.wp-block-post-title a { text-decoration: none; }
.wp-block-post-title a:hover { color: var(--wp--preset--color--garnet); }
.wp-block-post-featured-image img { transition: opacity .2s; }
.wp-block-post-featured-image a:hover img { opacity: .88; }

/* Footer (black, New Yorker style) */
.kb-footer a { color: #fff; text-decoration: none; }
/* Lighter garnet so the hover color reads on black */
.kb-footer a:hover,
.kb-footer a:focus { color: #e05a6c !important; text-decoration: none !important; }
.kb-footer h2.wp-block-heading {
	padding-bottom: 12px;
	border-bottom: 1px solid #333;
}
.kb-footer ul { list-style: none; padding-left: 0; }
.kb-footer li { padding: 4px 0; }
.kb-footer .wp-block-categories,
.kb-footer .wp-block-latest-comments { color: #bdbdbd; }
.kb-footer .wp-block-latest-comments__comment { margin: 0 0 10px; line-height: 1.45; font-size: 14.5px; }
.kb-footer .wp-block-latest-comments__comment-link { font-family: var(--wp--preset--font-family--fraunces); font-style: italic; }

/* Year → month archive accordion (from the [kb_yearly_archives] shortcode) */
.kb-archives details { border-bottom: 1px solid #222; }
.kb-archives summary {
	cursor: pointer;
	list-style: none;
	display: flex;
	justify-content: space-between;
	padding: 8px 0;
	font: 600 16px var(--wp--preset--font-family--fraunces);
	color: #fff;
}
.kb-archives summary::-webkit-details-marker { display: none; }
.kb-archives summary::after { content: "+"; color: #d6475a; }
.kb-archives details[open] summary::after { content: "–"; }
.kb-archives ul { padding: 0 0 10px 2px; margin: 0; }
.kb-archives .count { color: #777; font-size: 13px; }

/* Single post */
.kb-single .wp-block-post-content > p:first-of-type::first-letter {
	float: left;
	font: 700 4.6em/.82 var(--wp--preset--font-family--fraunces);
	padding: .06em .08em 0 0;
	color: var(--wp--preset--color--garnet);
}
.kb-author-box { border-top: 1px solid var(--wp--preset--color--rule); border-bottom: 1px solid var(--wp--preset--color--rule); }

/* Tagline band ornament: sampaguita between two short rules */
.kb-orn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 14px;
	color: var(--wp--preset--color--garnet);
}
.kb-orn i { display: block; width: 60px; height: 1px; background: currentColor; }

/* Subscribe form in the footer */
.kb-sub-box .wp-block-jetpack-subscriptions input[type="email"] {
	background: transparent;
	border: 1px solid #555;
	color: #fff;
	padding: 12px;
}
.kb-sub-box .wp-block-jetpack-subscriptions button {
	background: #fff !important;
	color: #000 !important;
	border-radius: 0 !important;
	text-transform: uppercase;
	letter-spacing: .12em;
	font-weight: 700;
}
.kb-sub-box .wp-block-jetpack-subscriptions button:hover { background: #e05a6c !important; color: #fff !important; }

/* Homepage latest posts: thin rule between posts */
.kb-latest .wp-block-post-template > li { padding: 40px 0; border-top: 1px solid var(--wp--preset--color--rule); }
.kb-latest .wp-block-post-template > li:first-child { padding-top: 0; border-top: 0; }

/* Page numbers under the latest posts */
.kb-pager {
	gap: 6px;
	margin-top: 24px;
	padding-top: 28px;
	border-top: 2px solid var(--wp--preset--color--ink);
	font: 700 12.5px/1 var(--wp--preset--font-family--inter);
	letter-spacing: .12em;
	text-transform: uppercase;
}
.kb-pager a,
.kb-pager .page-numbers { padding: 10px 12px; color: var(--wp--preset--color--ink); text-decoration: none; }
.kb-pager a:hover { color: var(--wp--preset--color--garnet); }
.kb-pager .page-numbers.current { background: var(--wp--preset--color--ink); color: #fff; }
.kb-pager .wp-block-query-pagination-previous { margin-right: 10px; }
.kb-pager .wp-block-query-pagination-next { margin-left: 10px; }
