/*
Theme Name: Kickhammer News
Theme URI: https://kickhammernews.com
Author: Kickhammer News
Author URI: https://kickhammernews.com
Description: A dark tech-themed WordPress news theme for Kickhammer News — featuring electric blue accents, category-based article sections, and a professional technology news layout.
Version: 1.0.1
Requires at least: 6.0
Tested up to: 6.9.4
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: kickhammer-news
Tags: news, technology, dark, custom-menu, featured-images, threaded-comments, translation-ready, sidebar
*/

/* ============================================================
   CSS CUSTOM PROPERTIES — DARK TECH PALETTE
   ============================================================ */
:root {
  --kh-bg:              #0d1117;
  --kh-bg-secondary:    #161b22;
  --kh-bg-card:         #1c2128;
  --kh-bg-card-hover:   #21262d;
  --kh-accent:          #00d4ff;
  --kh-accent-hover:    #38e9ff;
  --kh-accent-dim:      rgba(0, 212, 255, 0.12);
  --kh-accent-2:        #0ea5e9;
  --kh-text:            #e6edf3;
  --kh-text-muted:      #8b949e;
  --kh-text-faint:      #484f58;
  --kh-border:          #30363d;
  --kh-border-light:    #21262d;
  --kh-nav-bg:          #010409;
  --kh-red:             #ef4444;
  --kh-green:           #22c55e;
  --kh-purple:          #a855f7;
  --kh-amber:           #f59e0b;
  --kh-tag-ai:          #7c3aed;
  --kh-tag-cyber:       #dc2626;
  --kh-tag-consumer:    #059669;
  --kh-tag-industry:    #d97706;
  --kh-tag-latest:      #0ea5e9;
  --kh-radius:          6px;
  --kh-radius-lg:       10px;
  --kh-shadow:          0 4px 24px rgba(0,0,0,0.5);
  --kh-shadow-glow:     0 0 20px rgba(0,212,255,0.15);
  --kh-font-sans:       'Inter', 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --kh-font-display:    'Inter', 'Roboto Condensed', 'Arial Narrow', sans-serif;
  --kh-max-width:       1280px;
  --kh-content-width:   860px;
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background-color: var(--kh-bg);
  color: var(--kh-text);
  font-family: var(--kh-font-sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--kh-accent); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--kh-accent-hover); }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--kh-font-display);
  font-weight: 700;
  line-height: 1.25;
  color: var(--kh-text);
}

p { margin-bottom: 1rem; }
p:last-child { margin-bottom: 0; }

input, textarea, select, button {
  font-family: var(--kh-font-sans);
  font-size: 1rem;
}

/* ============================================================
   LAYOUT UTILITIES
   ============================================================ */
.kh-container {
  max-width: var(--kh-max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.kh-container--narrow {
  max-width: var(--kh-content-width);
  margin: 0 auto;
  padding: 0 20px;
}

.screen-reader-text {
  position: absolute;
  left: -9999em;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ============================================================
   TOP BAR
   ============================================================ */
.kh-topbar {
  background: var(--kh-nav-bg);
  border-bottom: 1px solid var(--kh-border);
  padding: 6px 0;
  font-size: 0.75rem;
  color: var(--kh-text-muted);
}

.kh-topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.kh-topbar__date {
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.kh-topbar__social {
  display: flex;
  gap: 14px;
  align-items: center;
}

.kh-topbar__social a {
  color: var(--kh-text-muted);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 500;
}

.kh-topbar__social a:hover { color: var(--kh-accent); }

/* ============================================================
   SITE HEADER
   ============================================================ */
.kh-header {
  background: var(--kh-nav-bg);
  border-bottom: 3px solid var(--kh-accent);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--kh-shadow);
}

.kh-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  max-width: var(--kh-max-width);
  margin: 0 auto;
  gap: 20px;
}

/* Logo */
.kh-logo { display: flex; align-items: center; flex-shrink: 0; }
.kh-logo a { display: flex; align-items: center; }
.kh-logo img { height: 48px; width: auto; }
.kh-logo__text {
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--kh-text);
  text-transform: uppercase;
  line-height: 1;
}
.kh-logo__text span { color: var(--kh-accent); }

/* Primary Navigation */
.kh-nav { flex: 1; display: flex; justify-content: flex-end; align-items: center; }

.kh-nav__menu {
  display: flex;
  align-items: center;
  gap: 0;
}

.kh-nav__menu li { position: relative; }

.kh-nav__menu a {
  display: block;
  padding: 10px 16px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--kh-text);
  white-space: nowrap;
  transition: color 0.2s ease, background 0.2s ease;
  border-radius: var(--kh-radius);
}

.kh-nav__menu a:hover,
.kh-nav__menu li.current-menu-item > a,
.kh-nav__menu li.current-category-ancestor > a {
  color: var(--kh-accent);
  background: var(--kh-accent-dim);
}

/* Category color accents on nav */
.kh-nav__menu li.menu-ai > a:hover { color: #a855f7; background: rgba(168,85,247,0.1); }
.kh-nav__menu li.menu-cybersecurity > a:hover { color: #ef4444; background: rgba(239,68,68,0.1); }
.kh-nav__menu li.menu-consumer-tech > a:hover { color: #22c55e; background: rgba(34,197,94,0.1); }
.kh-nav__menu li.menu-industry-news > a:hover { color: #f59e0b; background: rgba(245,158,11,0.1); }

/* Dropdown */
.kh-nav__menu .sub-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 200px;
  background: var(--kh-bg-secondary);
  border: 1px solid var(--kh-border);
  border-radius: var(--kh-radius);
  box-shadow: var(--kh-shadow);
  padding: 6px 0;
  z-index: 100;
}

.kh-nav__menu li:hover > .sub-menu { display: block; }

.kh-nav__menu .sub-menu a {
  padding: 8px 16px;
  font-size: 0.8rem;
  border-radius: 0;
  border-bottom: 1px solid var(--kh-border-light);
}
.kh-nav__menu .sub-menu li:last-child a { border-bottom: none; }

/* Search button */
.kh-header__search {
  display: flex;
  align-items: center;
  margin-left: 8px;
}
.kh-header__search button {
  background: none;
  border: 1px solid var(--kh-border);
  color: var(--kh-text-muted);
  padding: 8px 10px;
  border-radius: var(--kh-radius);
  cursor: pointer;
  transition: all 0.2s;
  line-height: 1;
}
.kh-header__search button:hover { border-color: var(--kh-accent); color: var(--kh-accent); }

/* Hamburger (mobile) */
.kh-nav__toggle {
  display: none;
  background: none;
  border: 1px solid var(--kh-border);
  color: var(--kh-text);
  padding: 8px 10px;
  border-radius: var(--kh-radius);
  cursor: pointer;
  font-size: 1.2rem;
  line-height: 1;
}

/* ============================================================
   SEARCH OVERLAY
   ============================================================ */
.kh-search-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}
.kh-search-overlay.is-open { display: flex; }
.kh-search-overlay__box {
  width: 100%;
  max-width: 640px;
  padding: 0 20px;
}
.kh-search-overlay__form {
  display: flex;
  background: var(--kh-bg-secondary);
  border: 1px solid var(--kh-accent);
  border-radius: var(--kh-radius-lg);
  overflow: hidden;
}
.kh-search-overlay__input {
  flex: 1;
  background: none;
  border: none;
  padding: 16px 20px;
  color: var(--kh-text);
  font-size: 1.1rem;
  outline: none;
}
.kh-search-overlay__input::placeholder { color: var(--kh-text-muted); }
.kh-search-overlay__submit {
  background: var(--kh-accent);
  border: none;
  color: #000;
  padding: 0 20px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: background 0.2s;
}
.kh-search-overlay__submit:hover { background: var(--kh-accent-hover); }
.kh-search-overlay__close {
  display: block;
  margin: 14px auto 0;
  background: none;
  border: none;
  color: var(--kh-text-muted);
  cursor: pointer;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
}

/* ============================================================
   CATEGORY BADGE / TAG
   ============================================================ */
.kh-tag {
  display: inline-block;
  padding: 3px 10px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 3px;
  line-height: 1.6;
}
.kh-tag--ai          { background: var(--kh-tag-ai);       color: #fff; }
.kh-tag--cybersecurity { background: var(--kh-tag-cyber);   color: #fff; }
.kh-tag--consumer-tech { background: var(--kh-tag-consumer); color: #fff; }
.kh-tag--industry-news { background: var(--kh-tag-industry); color: #fff; }
.kh-tag--latest-news  { background: var(--kh-tag-latest);   color: #fff; }
.kh-tag--default      { background: var(--kh-bg-card);      color: var(--kh-accent); border: 1px solid var(--kh-accent); }

/* ============================================================
   SECTION HEADERS
   ============================================================ */
.kh-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--kh-border);
  position: relative;
}

.kh-section-header::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 60px;
  height: 2px;
  background: var(--kh-accent);
}

.kh-section-header--ai::after       { background: var(--kh-tag-ai); }
.kh-section-header--cybersecurity::after { background: var(--kh-tag-cyber); }
.kh-section-header--consumer::after { background: var(--kh-tag-consumer); }
.kh-section-header--industry::after { background: var(--kh-tag-industry); }

.kh-section-header__title {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--kh-text);
  display: flex;
  align-items: center;
  gap: 10px;
}

.kh-section-header__title::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 18px;
  background: var(--kh-accent);
  border-radius: 2px;
}
.kh-section-header--ai .kh-section-header__title::before       { background: var(--kh-tag-ai); }
.kh-section-header--cybersecurity .kh-section-header__title::before { background: var(--kh-tag-cyber); }
.kh-section-header--consumer .kh-section-header__title::before { background: var(--kh-tag-consumer); }
.kh-section-header--industry .kh-section-header__title::before { background: var(--kh-tag-industry); }

.kh-section-header__link {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--kh-text-muted);
  border: 1px solid var(--kh-border);
  padding: 5px 12px;
  border-radius: 3px;
  transition: all 0.2s;
}
.kh-section-header__link:hover { color: var(--kh-accent); border-color: var(--kh-accent); }

/* ============================================================
   HERO / FEATURED SECTION
   ============================================================ */
.kh-hero {
  padding: 30px 0 0;
  background: var(--kh-bg);
}

.kh-hero__grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 20px;
  align-items: start;
}

/* Main featured article */
.kh-featured-main {
  position: relative;
  border-radius: var(--kh-radius-lg);
  overflow: hidden;
  background: var(--kh-bg-card);
  grid-row: 1 / 3;
}

.kh-featured-main__image {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.kh-featured-main:hover .kh-featured-main__image { transform: scale(1.03); }

.kh-featured-main__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.3) 55%, transparent 100%);
}

.kh-featured-main__body {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px;
}

.kh-featured-main__tag { margin-bottom: 10px; }

.kh-featured-main__title {
  font-size: 1.65rem;
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
  margin-bottom: 10px;
}

.kh-featured-main__title a { color: #fff; }
.kh-featured-main__title a:hover { color: var(--kh-accent); }

.kh-featured-main__meta {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.65);
  display: flex;
  align-items: center;
  gap: 14px;
}

/* Side stack (right column — 2 stacked smaller articles) */
.kh-featured-side {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.kh-featured-side-item {
  background: var(--kh-bg-card);
  border-radius: var(--kh-radius-lg);
  overflow: hidden;
  border: 1px solid var(--kh-border);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.kh-featured-side-item:hover { border-color: var(--kh-accent); box-shadow: var(--kh-shadow-glow); }

.kh-featured-side-item__image {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
}

.kh-featured-side-item__body { padding: 14px 16px 18px; }

.kh-featured-side-item__tag { margin-bottom: 8px; }

.kh-featured-side-item__title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 8px;
}
.kh-featured-side-item__title a { color: var(--kh-text); }
.kh-featured-side-item__title a:hover { color: var(--kh-accent); }

.kh-featured-side-item__meta {
  font-size: 0.75rem;
  color: var(--kh-text-muted);
}

/* ============================================================
   MAIN CONTENT AREA
   ============================================================ */
.kh-main {
  padding: 16px 0 50px;
}

.kh-content-area {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 30px;
  align-items: start;
  max-width: var(--kh-max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* ============================================================
   ARTICLE CARDS
   ============================================================ */
.kh-card {
  background: var(--kh-bg-card);
  border-radius: var(--kh-radius-lg);
  overflow: hidden;
  border: 1px solid var(--kh-border);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
  display: flex;
  flex-direction: column;
}
.kh-card:hover {
  border-color: var(--kh-accent);
  box-shadow: var(--kh-shadow-glow);
  transform: translateY(-2px);
}

.kh-card__thumbnail {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/9;
  flex-shrink: 0;
}

.kh-card__thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.kh-card:hover .kh-card__thumbnail img { transform: scale(1.05); }

.kh-card__thumbnail .kh-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
}

.kh-card__body {
  padding: 16px 18px 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.kh-card__tag { margin-bottom: 8px; }

.kh-card__title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 8px;
  flex: 1;
}
.kh-card__title a { color: var(--kh-text); }
.kh-card__title a:hover { color: var(--kh-accent); }

.kh-card__excerpt {
  font-size: 0.82rem;
  color: var(--kh-text-muted);
  line-height: 1.5;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.kh-card__meta {
  font-size: 0.75rem;
  color: var(--kh-text-muted);
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: auto;
}

.kh-card__meta .kh-meta-author { color: var(--kh-accent); }

/* Card grid variants */
.kh-card-grid {
  display: grid;
  gap: 20px;
}
.kh-card-grid--3 { grid-template-columns: repeat(3, 1fr); }
.kh-card-grid--4 { grid-template-columns: repeat(4, 1fr); }
.kh-card-grid--2 { grid-template-columns: repeat(2, 1fr); }

/* ============================================================
   HORIZONTAL LIST CARD (for compact lists)
   ============================================================ */
.kh-list-card {
  display: flex;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--kh-border-light);
  align-items: flex-start;
}
.kh-list-card:first-child { padding-top: 0; }
.kh-list-card:last-child { border-bottom: none; padding-bottom: 0; }

.kh-list-card__thumb {
  flex-shrink: 0;
  width: 90px;
  height: 68px;
  border-radius: var(--kh-radius);
  overflow: hidden;
}
.kh-list-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.kh-list-card:hover .kh-list-card__thumb img { transform: scale(1.06); }

.kh-list-card__body { flex: 1; min-width: 0; }

.kh-list-card__tag { margin-bottom: 4px; }

.kh-list-card__title {
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.kh-list-card__title a { color: var(--kh-text); }
.kh-list-card__title a:hover { color: var(--kh-accent); }

.kh-list-card__meta { font-size: 0.72rem; color: var(--kh-text-muted); }

/* ============================================================
   CATEGORY SECTIONS (on homepage)
   ============================================================ */
.kh-category-section { margin-bottom: 40px; }

.kh-category-section--featured {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: start;
}

.kh-category-section--featured .kh-card--lead {
  grid-row: 1 / 3;
}

.kh-category-section--featured .kh-card--lead .kh-card__title {
  font-size: 1.2rem;
}

/* ============================================================
   SIDEBAR
   ============================================================ */
.kh-sidebar { position: sticky; top: 80px; }

.kh-widget {
  background: var(--kh-bg-card);
  border: 1px solid var(--kh-border);
  border-radius: var(--kh-radius-lg);
  padding: 20px;
  margin-bottom: 24px;
}

.kh-widget__title {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--kh-text);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--kh-border);
  position: relative;
}
.kh-widget__title::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 36px;
  height: 2px;
  background: var(--kh-accent);
}

/* Standard WordPress widget selectors */
.widget { }
.widget-title {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--kh-text);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--kh-border);
}

.kh-sidebar .wp-block-widget-area > div,
.kh-sidebar .widget {
  background: var(--kh-bg-card);
  border: 1px solid var(--kh-border);
  border-radius: var(--kh-radius-lg);
  padding: 20px;
  margin-bottom: 24px;
}

.kh-sidebar .widget_title,
.kh-sidebar .widgettitle {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--kh-text);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--kh-border);
  position: relative;
}

.kh-sidebar ul li {
  padding: 7px 0;
  border-bottom: 1px solid var(--kh-border-light);
  font-size: 0.875rem;
}
.kh-sidebar ul li:last-child { border-bottom: none; }
.kh-sidebar ul li a { color: var(--kh-text-muted); }
.kh-sidebar ul li a:hover { color: var(--kh-accent); }

/* ============================================================
   TRENDING / POPULAR WIDGET
   ============================================================ */
.kh-trending-list { }

.kh-trending-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 10px 0;
  border-bottom: 1px solid var(--kh-border-light);
}
.kh-trending-item:last-child { border-bottom: none; padding-bottom: 0; }

.kh-trending-item__num {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 4px;
  background: var(--kh-accent-dim);
  color: var(--kh-accent);
  font-size: 0.75rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--kh-accent);
}

.kh-trending-item__title {
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.35;
}
.kh-trending-item__title a { color: var(--kh-text); }
.kh-trending-item__title a:hover { color: var(--kh-accent); }

/* ============================================================
   CATEGORIES WIDGET
   ============================================================ */
.kh-cat-list {}
.kh-cat-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border-radius: var(--kh-radius);
  margin-bottom: 4px;
  background: var(--kh-bg-secondary);
  transition: background 0.2s;
}
.kh-cat-item:hover { background: var(--kh-accent-dim); }
.kh-cat-item a { color: var(--kh-text); font-size: 0.85rem; font-weight: 600; flex: 1; }
.kh-cat-item a:hover { color: var(--kh-accent); }
.kh-cat-item__count {
  font-size: 0.72rem;
  color: var(--kh-text-muted);
  background: var(--kh-bg-card);
  border: 1px solid var(--kh-border);
  padding: 2px 7px;
  border-radius: 10px;
}

/* ============================================================
   SINGLE POST
   ============================================================ */
.kh-single { padding: 30px 0 60px; }

.kh-single__header { margin-bottom: 28px; }

.kh-single__tags { margin-bottom: 14px; display: flex; gap: 8px; flex-wrap: wrap; }

.kh-single__title {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
  color: var(--kh-text);
}

.kh-single__meta {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 0.82rem;
  color: var(--kh-text-muted);
  padding: 14px 0;
  border-top: 1px solid var(--kh-border);
  border-bottom: 1px solid var(--kh-border);
  flex-wrap: wrap;
}

.kh-single__meta .kh-meta-author { color: var(--kh-accent); font-weight: 600; }

.kh-single__featured-image {
  margin: 24px 0;
  border-radius: var(--kh-radius-lg);
  overflow: hidden;
  max-height: 520px;
}
.kh-single__featured-image img { width: 100%; object-fit: cover; }

/* Single post content */
.kh-entry-content {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--kh-text);
}
.kh-entry-content p { margin-bottom: 1.4em; }
.kh-entry-content h2 { font-size: 1.5rem; font-weight: 700; margin: 1.8em 0 0.6em; color: var(--kh-text); }
.kh-entry-content h3 { font-size: 1.25rem; font-weight: 700; margin: 1.5em 0 0.5em; color: var(--kh-text); }
.kh-entry-content h4 { font-size: 1.1rem; font-weight: 700; margin: 1.2em 0 0.4em; }
.kh-entry-content ul, .kh-entry-content ol { margin: 0 0 1.4em 1.5em; }
.kh-entry-content ul { list-style: disc; }
.kh-entry-content ol { list-style: decimal; }
.kh-entry-content li { margin-bottom: 0.4em; }
.kh-entry-content blockquote {
  border-left: 4px solid var(--kh-accent);
  margin: 1.5em 0;
  padding: 14px 20px;
  background: var(--kh-bg-secondary);
  border-radius: 0 var(--kh-radius) var(--kh-radius) 0;
  font-style: italic;
  color: var(--kh-text-muted);
}
.kh-entry-content a { color: var(--kh-accent); text-decoration: underline; text-underline-offset: 2px; }
.kh-entry-content a:hover { color: var(--kh-accent-hover); }
.kh-entry-content img {
  border-radius: var(--kh-radius);
  margin: 1em 0;
}
.kh-entry-content pre, .kh-entry-content code {
  font-family: 'Fira Code', 'Consolas', 'Monaco', monospace;
  background: var(--kh-nav-bg);
  border: 1px solid var(--kh-border);
  border-radius: var(--kh-radius);
  font-size: 0.875rem;
}
.kh-entry-content pre { padding: 16px 20px; overflow-x: auto; margin: 1.4em 0; }
.kh-entry-content code { padding: 2px 6px; }
.kh-entry-content pre code { padding: 0; border: none; background: none; }
.kh-entry-content hr {
  border: none;
  border-top: 1px solid var(--kh-border);
  margin: 2em 0;
}
.kh-entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.4em 0;
  font-size: 0.9rem;
}
.kh-entry-content th, .kh-entry-content td {
  padding: 10px 14px;
  border: 1px solid var(--kh-border);
  text-align: left;
}
.kh-entry-content th { background: var(--kh-bg-secondary); font-weight: 700; }

/* Post tags */
.kh-single__post-tags {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--kh-border);
}
.kh-single__post-tags h4 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 12px; color: var(--kh-text-muted); }
.kh-tag-list { display: flex; flex-wrap: wrap; gap: 8px; }
.kh-tag-list a {
  padding: 5px 12px;
  border-radius: var(--kh-radius);
  border: 1px solid var(--kh-border);
  font-size: 0.8rem;
  color: var(--kh-text-muted);
  background: var(--kh-bg-secondary);
}
.kh-tag-list a:hover { border-color: var(--kh-accent); color: var(--kh-accent); }

/* Author box */
.kh-author-box {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  background: var(--kh-bg-card);
  border: 1px solid var(--kh-border);
  border-radius: var(--kh-radius-lg);
  padding: 24px;
  margin-top: 36px;
}
.kh-author-box__avatar img { width: 70px; height: 70px; border-radius: 50%; border: 2px solid var(--kh-accent); }
.kh-author-box__name { font-size: 1rem; font-weight: 700; margin-bottom: 4px; }
.kh-author-box__bio { font-size: 0.85rem; color: var(--kh-text-muted); line-height: 1.5; }

/* Related posts */
.kh-related { margin-top: 48px; }

/* Post navigation */
.kh-post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid var(--kh-border);
}
.kh-post-nav__item {
  background: var(--kh-bg-card);
  border: 1px solid var(--kh-border);
  border-radius: var(--kh-radius-lg);
  padding: 16px 18px;
  transition: border-color 0.2s;
}
.kh-post-nav__item:hover { border-color: var(--kh-accent); }
.kh-post-nav__item--next { text-align: right; }
.kh-post-nav__label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--kh-accent); font-weight: 600; margin-bottom: 4px; }
.kh-post-nav__title { font-size: 0.875rem; font-weight: 700; color: var(--kh-text); }
.kh-post-nav__item a:hover .kh-post-nav__title { color: var(--kh-accent); }

/* ============================================================
   ARCHIVE / CATEGORY PAGE
   ============================================================ */
.kh-archive { padding: 30px 0 60px; }

.kh-archive__header {
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--kh-border);
  position: relative;
}
.kh-archive__header::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 80px;
  height: 2px;
  background: var(--kh-accent);
}
.kh-archive__label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--kh-accent); font-weight: 700; margin-bottom: 6px; }
.kh-archive__title { font-size: 2rem; font-weight: 800; }
.kh-archive__description { color: var(--kh-text-muted); margin-top: 8px; font-size: 0.9rem; }

/* ============================================================
   SEARCH RESULTS
   ============================================================ */
.kh-search-results { padding: 30px 0 60px; }
.kh-search-header { margin-bottom: 28px; }
.kh-search-header__query { font-size: 1.6rem; font-weight: 700; }
.kh-search-header__query span { color: var(--kh-accent); }
.kh-search-header__count { color: var(--kh-text-muted); font-size: 0.9rem; margin-top: 6px; }

/* ============================================================
   PAGINATION
   ============================================================ */
.kh-pagination {
  margin-top: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}
.kh-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  border-radius: var(--kh-radius);
  border: 1px solid var(--kh-border);
  background: var(--kh-bg-card);
  color: var(--kh-text-muted);
  font-size: 0.875rem;
  font-weight: 600;
  transition: all 0.2s;
}
.kh-pagination .page-numbers:hover { border-color: var(--kh-accent); color: var(--kh-accent); background: var(--kh-accent-dim); }
.kh-pagination .page-numbers.current { background: var(--kh-accent); color: #000; border-color: var(--kh-accent); font-weight: 700; }
.kh-pagination .page-numbers.dots { cursor: default; border: none; background: none; }

/* ============================================================
   COMMENTS
   ============================================================ */
.kh-comments { margin-top: 48px; padding-top: 36px; border-top: 1px solid var(--kh-border); }
.kh-comments__title { font-size: 1.2rem; font-weight: 700; margin-bottom: 24px; }
.comment-list { }
.comment {
  padding: 20px 0;
  border-bottom: 1px solid var(--kh-border-light);
}
.comment .comment-body { display: flex; gap: 14px; }
.comment .comment-author .avatar { border-radius: 50%; width: 42px; height: 42px; }
.comment .comment-meta { font-size: 0.78rem; color: var(--kh-text-muted); margin-bottom: 6px; }
.comment .comment-meta a { color: var(--kh-accent); font-weight: 600; }
.comment .comment-content { font-size: 0.9rem; line-height: 1.6; }
.comment .reply a { font-size: 0.78rem; color: var(--kh-accent); font-weight: 600; margin-top: 8px; display: inline-block; }
.comment-form input, .comment-form textarea {
  width: 100%;
  background: var(--kh-bg-secondary);
  border: 1px solid var(--kh-border);
  border-radius: var(--kh-radius);
  padding: 10px 14px;
  color: var(--kh-text);
  margin-bottom: 14px;
  outline: none;
  transition: border-color 0.2s;
}
.comment-form input:focus, .comment-form textarea:focus { border-color: var(--kh-accent); }
.comment-form textarea { min-height: 120px; resize: vertical; }
.comment-form .submit {
  background: var(--kh-accent);
  color: #000;
  border: none;
  border-radius: var(--kh-radius);
  padding: 10px 24px;
  font-weight: 700;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s;
}
.comment-form .submit:hover { background: var(--kh-accent-hover); }

/* ============================================================
   404 PAGE
   ============================================================ */
.kh-404 {
  padding: 80px 0;
  text-align: center;
}
.kh-404__code {
  font-size: 8rem;
  font-weight: 900;
  color: var(--kh-accent);
  line-height: 1;
  opacity: 0.2;
  margin-bottom: -30px;
}
.kh-404__title { font-size: 2rem; font-weight: 800; margin-bottom: 14px; }
.kh-404__text { color: var(--kh-text-muted); margin-bottom: 28px; }
.kh-btn {
  display: inline-block;
  padding: 12px 28px;
  background: var(--kh-accent);
  color: #000;
  border-radius: var(--kh-radius);
  font-weight: 700;
  font-size: 0.875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: background 0.2s, transform 0.1s;
}
.kh-btn:hover { background: var(--kh-accent-hover); color: #000; transform: translateY(-1px); }

/* ============================================================
   FOOTER
   ============================================================ */
.kh-footer {
  background: var(--kh-nav-bg);
  border-top: 3px solid var(--kh-accent);
  padding: 48px 0 0;
  margin-top: 40px;
}

.kh-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 36px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--kh-border);
}

.kh-footer__brand {}

.kh-footer__logo { margin-bottom: 14px; }
.kh-footer__logo img { height: 44px; }

.kh-footer__tagline { font-size: 0.85rem; color: var(--kh-text-muted); line-height: 1.6; margin-bottom: 18px; }

.kh-footer__social {
  display: flex;
  gap: 10px;
}
.kh-footer__social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--kh-radius);
  border: 1px solid var(--kh-border);
  color: var(--kh-text-muted);
  font-size: 0.85rem;
  font-weight: 700;
  transition: all 0.2s;
}
.kh-footer__social a:hover { border-color: var(--kh-accent); color: var(--kh-accent); background: var(--kh-accent-dim); }

.kh-footer__col-title {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--kh-text);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--kh-border);
}

.kh-footer__links { }
.kh-footer__links li { padding: 5px 0; }
.kh-footer__links a { color: var(--kh-text-muted); font-size: 0.875rem; transition: color 0.2s; }
.kh-footer__links a:hover { color: var(--kh-accent); }

.kh-footer__bottom {
  padding: 18px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--kh-text-faint);
  flex-wrap: wrap;
  gap: 10px;
}
.kh-footer__bottom a { color: var(--kh-text-muted); }
.kh-footer__bottom a:hover { color: var(--kh-accent); }

/* ============================================================
   UTILITY CLASSES
   ============================================================ */
.kh-no-thumb {
  background: linear-gradient(135deg, var(--kh-bg-secondary) 0%, var(--kh-bg-card) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--kh-text-faint);
  font-size: 2rem;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1100px) {
  .kh-footer__grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .kh-card-grid--4 { grid-template-columns: repeat(2, 1fr); }
  .kh-hero__grid { grid-template-columns: 1fr 280px; }
}

@media (max-width: 900px) {
  .kh-content-area { grid-template-columns: 1fr; }
  .kh-sidebar { position: static; }
  .kh-hero__grid { grid-template-columns: 1fr; }
  .kh-featured-side { flex-direction: row; }
  .kh-card-grid--3 { grid-template-columns: repeat(2, 1fr); }
  .kh-category-section--featured { grid-template-columns: 1fr; }
  .kh-post-nav { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .kh-header__inner { padding: 12px 16px; }
  .kh-nav__menu { display: none; }
  .kh-nav__menu.is-open {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: 0;
    top: 0;
    background: var(--kh-nav-bg);
    z-index: 999;
    padding: 80px 24px 24px;
    gap: 4px;
    overflow-y: auto;
  }
  .kh-nav__menu.is-open a { font-size: 1.1rem; padding: 14px 16px; }
  .kh-nav__toggle { display: block; }
  .kh-topbar__social { display: none; }
  .kh-hero { padding: 16px 0 0; }
  .kh-featured-main__title { font-size: 1.3rem; }
  .kh-featured-side { flex-direction: column; }
  .kh-footer__grid { grid-template-columns: 1fr; gap: 24px; }
  .kh-single__title { font-size: 1.5rem; }
  .kh-single__meta { gap: 10px; }
  .kh-author-box { flex-direction: column; }
}

@media (max-width: 560px) {
  .kh-card-grid--3,
  .kh-card-grid--2 { grid-template-columns: 1fr; }
  .kh-card-grid--4 { grid-template-columns: 1fr; }
  .kh-footer__bottom { flex-direction: column; text-align: center; }
  .kh-404__code { font-size: 5rem; }
}

/* ============================================================
   WORDPRESS CORE ALIGNMENTS & CLASSES
   ============================================================ */
.alignleft  { float: left; margin: 0.5em 1.5em 1em 0; }
.alignright { float: right; margin: 0.5em 0 1em 1.5em; }
.aligncenter { display: block; margin: 1em auto; }
.wp-caption { text-align: center; }
.wp-caption-text { font-size: 0.8rem; color: var(--kh-text-muted); margin-top: 6px; }
.sticky { border-left: 3px solid var(--kh-accent); padding-left: 12px; }
.gallery-caption { font-size: 0.8rem; color: var(--kh-text-muted); }
.bypostauthor { }

/* ============================================================
   AUTHOR PAGE & AUTHOR BOX ADDITIONS
   ============================================================ */
.kh-author-header { display: flex; gap: 24px; align-items: flex-start; }
.kh-author-header__avatar img { width: 120px; height: 120px; border-radius: 50%; border: 3px solid var(--kh-accent); object-fit: cover; }
.kh-author-header__title { color: var(--kh-accent); font-weight: 600; margin-top: 4px; }
.kh-author-header__bio p { margin: 8px 0 0; }
.kh-author-links { display: flex; flex-wrap: wrap; gap: 14px; list-style: none; padding: 0; margin: 14px 0 0; font-size: 0.85rem; }
.kh-author-box__role { display: block; font-size: 0.8rem; font-weight: 500; color: var(--kh-accent); }
.kh-author-box__links { font-size: 0.8rem; margin-top: 8px; }
@media (max-width: 600px) { .kh-author-header { flex-direction: column; } }
