/*
Theme Name: Kathe Khola
Theme URI: https://kathekhola.com
Author: Bigyan Kandel
Description: A custom editorial theme for Kathe Khola -- opinion pieces and inspiring news on education, youth, business, and technology.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: katha-khola
*/

:root {
  --accent: #a91e1e;
  --accent-dark: #7a1515;
  --near-black: #17110f;
  --cream: #faf7f4;
  --border: #e6ded9;
  --muted: #6b615c;
  --ink: #1a1512;
  --font-serif: 'Lora', Georgia, serif;
  --font-logo: 'Playfair Display', Georgia, serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: var(--font-sans); color: var(--ink); background: var(--cream); }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
ul { list-style: none; margin: 0; padding: 0; }

.topline { background: var(--near-black); color: #cfc9c6; font-size: 12px; padding: 6px 24px; display: flex; justify-content: space-between; }
header.site { background: var(--cream); border-bottom: 2px solid var(--ink); padding: 20px 24px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
.logo { font-family: var(--font-logo); font-weight: 900; font-size: 36px; letter-spacing: -0.5px; display: inline-block; }
.logo-part-1 { color: var(--ink); }
.logo-part-2 { color: var(--accent); }
.tagline { font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); margin-top: 2px; }
nav.main ul { display: flex; gap: 28px; font-size: 14px; font-weight: 600; flex-wrap: wrap; }
nav.main a:hover { color: var(--accent); }
.header-actions { display: flex; gap: 12px; align-items: center; }
.btn { padding: 10px 18px; border-radius: 4px; font-weight: 700; font-size: 13px; cursor: pointer; border: 1.5px solid var(--ink); display: inline-block; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-outline { background: transparent; color: var(--ink); }

.wrap { max-width: 1140px; margin: 0 auto; padding: 0 24px; }

.hero { padding: 48px 0; border-bottom: 1px solid var(--border); }
.hero-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 44px; align-items: center; }
.eyebrow { display: inline-block; background: var(--accent); color: #fff; font-size: 11px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; padding: 4px 10px; border-radius: 3px; margin-bottom: 16px; }
.hero h1 { font-family: var(--font-serif); font-size: 44px; line-height: 1.1; font-weight: 700; margin: 0 0 18px; }
.hero h1 a { color: var(--ink); }
.hero .dek { font-size: 18px; color: var(--muted); line-height: 1.55; margin: 0 0 18px; }
.byline { font-size: 13px; color: var(--muted); font-weight: 600; }
.hero-img { border-radius: 6px; overflow: hidden; height: 320px; }
.hero-img img { width: 100%; height: 100%; object-fit: cover; }

.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }

.card-img { height: 170px; border-radius: 6px; overflow: hidden; margin-bottom: 14px; }
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.card h3 { font-family: var(--font-serif); font-size: 20px; line-height: 1.25; margin: 0 0 8px; font-weight: 700; }
.card h3 a { color: var(--ink); }
.card p { font-size: 14px; color: var(--muted); line-height: 1.55; margin: 0 0 10px; }
.card .byline { font-size: 12px; }

section.block { padding: 56px 0; border-bottom: 1px solid var(--border); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 32px; flex-wrap: wrap; gap: 8px; }
.section-head h2 { font-family: var(--font-serif); font-size: 28px; margin: 0; font-weight: 700; }
.section-head a { font-size: 13px; font-weight: 700; color: var(--accent); }

section.opinion { background: var(--near-black); color: #e8e3e0; }
section.opinion .section-head h2 { color: #fff; }
section.opinion .section-head a { color: #f0a8a8; }
.topic-badge { display: inline-block; background: var(--accent); color: #fff; font-size: 10px; font-weight: 700; letter-spacing: 0.6px; text-transform: uppercase; padding: 4px 9px; border-radius: 3px; margin-bottom: 16px; }

.opinion-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 24px; }
.op-featured { display: block; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.12); border-radius: 8px; overflow: hidden; transition: border-color 0.15s; }
.op-featured:hover { border-color: rgba(255,255,255,0.3); }
.op-featured-img { height: 220px; overflow: hidden; }
.op-featured-img img { width: 100%; height: 100%; object-fit: cover; }
.op-featured-body { padding: 26px; }
.op-featured-body h3 { font-family: var(--font-serif); color: #fff; font-size: 24px; line-height: 1.3; font-weight: 700; margin: 0 0 12px; }
.op-featured-body p { color: #c9c2bd; font-size: 14px; line-height: 1.6; margin: 0 0 20px; }
.op-list { display: flex; flex-direction: column; justify-content: center; height: 100%; }
.op-row { display: flex; gap: 14px; padding: 20px 4px; border-bottom: 1px solid rgba(255,255,255,0.1); }
.op-row:first-child { padding-top: 4px; }
.op-row:last-child { border-bottom: none; padding-bottom: 4px; }
.op-row-thumb { width: 64px; height: 64px; border-radius: 6px; overflow: hidden; flex-shrink: 0; }
.op-row-thumb img { width: 100%; height: 100%; object-fit: cover; }
.op-row h4 { font-family: var(--font-serif); color: #fff; font-size: 15px; line-height: 1.35; font-weight: 600; margin: 0 0 6px; }
.op-row .topic-badge { font-size: 9px; padding: 3px 7px; margin-bottom: 8px; }
.op-byline { color: #a39a94; font-size: 11px; }

.author { display: flex; align-items: flex-start; gap: 12px; }
.avatar-photo { width: 44px; height: 44px; border-radius: 50%; overflow: hidden; flex-shrink: 0; }
.avatar-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.author-name { font-size: 13px; font-weight: 700; }
.author-name a { color: #fff; }
.author-role { font-size: 12px; color: #b9b2ae; }
.author-bio { font-size: 12px; color: #b9b2ae; line-height: 1.45; margin-top: 2px; max-width: 260px; }

.newsletter { background: var(--accent); color: #fff; padding: 52px 0; text-align: center; }
.newsletter h2 { font-family: var(--font-serif); font-size: 30px; margin: 0 0 10px; }
.newsletter p { margin: 0 0 24px; opacity: 0.92; font-size: 15px; }
.newsletter-form form { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; }
.newsletter-form input { width: 320px; padding: 13px 16px; border-radius: 4px; border: none; font-size: 14px; font-family: var(--font-sans); }
.newsletter-form button { padding: 13px 22px; border-radius: 4px; border: none; background: var(--ink); color: #fff; font-weight: 700; font-size: 14px; cursor: pointer; }

footer.site { background: var(--near-black); color: #b9b2ae; padding: 48px 0 24px; }
.foot-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 32px; margin-bottom: 32px; }
.foot-grid h4 { color: #fff; font-size: 13px; text-transform: uppercase; letter-spacing: 0.8px; margin: 0 0 14px; }
.foot-grid a { display: block; font-size: 14px; margin-bottom: 10px; color: #b9b2ae; }
.foot-logo { font-family: var(--font-serif); font-size: 22px; font-weight: 900; color: #fff; margin-bottom: 10px; }
.foot-bottom { border-top: 1px solid rgba(255,255,255,0.12); padding-top: 20px; font-size: 12px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }

.empty-state { text-align: center; padding: 60px 0; }
.empty-state h1 { font-family: var(--font-serif); font-size: 32px; margin-bottom: 12px; }

@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .grid3 { grid-template-columns: 1fr; }
  .opinion-grid { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  nav.main { display: none; }
}
