/*
Theme Name:  The Morning After (Modern)
Theme URI:   https://github.com/themorningafter-modern
Description: A modern, responsive recreation of the classic WooThemes "The Morning After" blog theme. Built with semantic HTML5, CSS Grid, Flexbox, and zero jQuery dependencies. Fully responsive across all screen sizes.
Version:     1.0.0
Author:      Modernised from WooThemes original
Author URI:  https://woothemes.com
License:     GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: themorningafter-modern
Tags:        blog, one-column, two-columns, right-sidebar, custom-header, custom-menu, featured-images, threaded-comments, translation-ready, responsive-layout
*/

/* ─── CSS Custom Properties ─────────────────────────────── */
:root {
  --bg:           #ebeff2;
  --surface:      #ffffff;
  --border:       #dadada;
  --border-dark:  #999999;
  --text:         #1a1a1a;
  --text-muted:   #666666;
  --text-light:   #818181;
  --accent-blue:  #3a6999;
  --accent-navy:  #224970;
  --accent-red:   #a11b1b;
  --accent-green: #5f9410;
  --accent-link:  #3a6999;
  --feat-bg:      #f2f2f2;
  --about-bg:     #f3f9ff;
  --dot-sep:      linear-gradient(to right, var(--border) 1px, transparent 1px) 0 100% / 6px 1px repeat-x;
  --stripe:       repeating-linear-gradient(90deg, transparent, transparent 3px, rgba(0,0,0,0.04) 3px, rgba(0,0,0,0.04) 4px);
  --max-width:    960px;
  --col-gap:      20px;
  --font-body:    'Source Serif 4', Georgia, serif;
  --font-display: 'Playfair Display', Georgia, serif;
  --font-sans:    Helvetica, Arial, 'Lucida Grande', Verdana, sans-serif;
  --radius:       3px;
  --shadow-sm:    0 1px 3px rgba(0,0,0,0.08);
  --shadow-md:    0 3px 10px rgba(0,0,0,0.10);
  --transition:   0.18s ease;
}

/* ─── Reset ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 13px; }

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  text-align: left;
}

a {
  color: var(--accent-link);
  text-decoration: none;
  transition: color var(--transition), background var(--transition);
}
a:hover { color: #000; }

img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-sans);
  color: #111;
  clear: both;
}

p { margin: 0 0 1.5em; line-height: 1.65; }

strong { font-weight: bold; }
em     { font-style: italic; }

pre {
  background: #eee;
  border: 1px solid #ddd;
  padding: 1.2em;
  margin-bottom: 1.3em;
  overflow-x: auto;
}
code { font: 0.9em monospace; }

blockquote {
  margin: 1.5em 0 1.5em 1.5em;
  color: #666;
  font-style: italic;
}

table { border-collapse: collapse; margin-bottom: 1.4em; width: 100%; }
th, td { padding: 0.3em 0.5em; border-bottom: 1px solid #ddd; text-align: left; }
th { font-weight: bold; background: #f5f5f5; }

hr { border: none; border-top: 1px solid var(--border); margin: 1.5em 0; }

/* ─── Page Wrapper ──────────────────────────────────────── */
.site {
  max-width: var(--max-width);
  margin: 0 auto;
  background: var(--surface);
  padding-bottom: 28px;
}

/* ─── Skip Link ─────────────────────────────────────────── */
.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.skip-link:focus {
  left: 6px;
  top: 6px;
  width: auto;
  height: auto;
  background: #000;
  color: #fff;
  padding: 6px 12px;
  z-index: 9999;
  font-size: 0.85em;
}

/* ─── Site Header ───────────────────────────────────────── */
.site-header {
  padding: 20px var(--col-gap) 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  min-height: 108px;
}

.site-branding { flex: 1 1 auto; }

.site-title {
  font-family: var(--font-display);
  font-size: 2.8em;
  font-weight: 900;
  letter-spacing: -0.05em;
  line-height: 1.1;
  margin: 0;
}
.site-title a { color: #000; text-decoration: none; }
.site-title a:hover { color: #fff; background: #000; padding: 0 3px; }

.site-description {
  text-align: right;
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 400;
  text-transform: uppercase;
  color: #666;
  letter-spacing: 0.2em;
  padding: 6px 0 0 18px;
  border-top: 1px solid #ccc;
  margin-top: 6px;
}

/* Header right panel: search + quick links */
.header-panel {
  flex: 0 0 auto;
  width: 380px;
  padding-left: 20px;
  border-left: 1px solid #ddd;
}

.header-panel .search-heading {
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #333;
  margin-bottom: 6px;
}

/* Search form */
.search-form {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
}
.search-form .search-field {
  flex: 1;
  border: 1px solid #ccc;
  border-top-color: #999;
  border-left-color: #999;
  padding: 5px 8px;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.9em;
  color: #333;
  background: #fff;
  outline: none;
  transition: background var(--transition);
}
.search-form .search-field:focus { background: #f7f7f7; }
.search-form .search-submit {
  padding: 5px 14px;
  background: #333;
  color: #fff;
  border: none;
  cursor: pointer;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.85em;
  letter-spacing: 0.05em;
  transition: background var(--transition);
}
.search-form .search-submit:hover { background: #000; }

/* Quick navigation */
.header-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 14px;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.85em;
}
.header-nav a { color: #000; }
.header-nav a:hover { text-decoration: underline; }

/* ─── Primary Navigation ────────────────────────────────── */
.main-navigation {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 0 var(--col-gap);
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  font-family: var(--font-sans);
  font-size: 0.8em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  position: relative;
}

.main-navigation ul {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}

.main-navigation li { position: relative; }

.main-navigation > div > ul > li > a,
.main-navigation > ul > li > a {
  display: block;
  color: #555;
  padding: 8px 12px;
  line-height: 18px;
  text-shadow: 0 1px 0 #fff;
  text-decoration: none;
  transition: background var(--transition);
}
.main-navigation > div > ul > li > a:hover,
.main-navigation > div > ul > li.current-menu-item > a,
.main-navigation > div > ul > li.current-menu-parent > a,
.main-navigation > div > ul > li.current-menu-ancestor > a {
  background: #eee;
  color: #000;
}

/* Drop-down */
.main-navigation ul ul {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  border: 1px solid var(--border);
  min-width: 200px;
  z-index: 999;
  box-shadow: var(--shadow-md);
}
.main-navigation li:hover > ul,
.main-navigation li.focus > ul { display: block; }

.main-navigation ul ul li a {
  display: block;
  padding: 8px 12px;
  color: #555;
  font-size: 0.9em;
  background: #eee;
  border-top: 1px solid #fff;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  transition: background var(--transition);
  white-space: nowrap;
}
.main-navigation ul ul li a:hover { background: #ddd; color: #000; }

/* RSS links */
.nav-rss {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.85em;
}
.nav-rss a { color: #c63f00; }
.nav-rss a:hover { text-decoration: underline; }

/* ─── Top Banner ────────────────────────────────────────── */
.top-banner {
  height: 70px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 var(--col-gap);
  background-color: #f8f9fb;
  background-image: var(--stripe);
  position: relative;
  overflow: hidden;
}

.top-banner .custom-header-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.25;
}

.top-banner .page-title {
  position: relative;
  background: var(--surface);
  color: #000;
  font-family: var(--font-display);
  font-size: 2em;
  font-weight: 700;
  text-transform: lowercase;
  letter-spacing: -0.036em;
  padding: 1px 6px 1px 0;
  margin: 0;
}

/* ─── Layout: Home ──────────────────────────────────────── */
.home-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 var(--col-gap);
  padding: 24px var(--col-gap) 0;
}

/* ─── Latest Post ───────────────────────────────────────── */
.latest-post { margin-bottom: 24px; }

.latest-post-image {
  margin-bottom: 8px;
  overflow: hidden;
}
.latest-post-image img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.latest-post-image img:hover { transform: scale(1.02); }

.latest-post-title {
  font-family: var(--font-display);
  font-size: 1.55em;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.03em;
  margin: 8px 0 6px;
}
.latest-post-title a { color: #000; }
.latest-post-title a:hover { color: #fff; background: #000; }

.latest-post-excerpt {
  font-size: 0.95em;
  line-height: 1.65;
  color: #333;
  margin-bottom: 10px;
}

.latest-post-meta {
  font-size: 0.85em;
  line-height: 1.6;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin-top: 8px;
}
.latest-post-meta a { font-weight: 700; color: var(--accent-link); }
.latest-post-meta a:hover { text-decoration: underline; }

/* ─── Featured Posts ────────────────────────────────────── */
.home-featured {
  background: var(--feat-bg);
  background-image: var(--dot-sep);
  margin-bottom: 18px;
  padding-bottom: 6px;
}

.home-featured-heading {
  background-image: var(--dot-sep);
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-green);
  padding: 10px 12px 12px;
  margin: 0;
}

.featured-item {
  display: flex;
  gap: 12px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}
.featured-item:last-child { border-bottom: none; }

.featured-thumbnail {
  flex: 0 0 65px;
  width: 65px;
  height: 65px;
  object-fit: cover;
  border: 1px solid #999;
}

.featured-title {
  font-family: var(--font-sans);
  font-size: 0.9em;
  font-weight: 700;
  margin-bottom: 4px;
}
.featured-title a { color: var(--accent-navy); }
.featured-title a:hover { color: #000; }

.featured-excerpt { font-size: 0.85em; color: #555; line-height: 1.5; }

/* ─── Asides / Updates ──────────────────────────────────── */
.home-asides { margin-top: 6px; }

ul.arrow { list-style: none; }
ul.arrow li {
  padding: 5px 0 8px 14px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border);
  border-left: 5px solid var(--border);
  font-size: 0.9em;
  line-height: 1.5;
}
ul.arrow li a { color: var(--accent-link); }
ul.arrow li a:hover { color: #000; background: #eee; }

/* ─── Home Right Column ─────────────────────────────────── */
.home-about {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--about-bg);
  padding: 14px 12px 2px;
  margin-bottom: 18px;
}
.home-about p {
  font-size: 0.9em;
  font-family: var(--font-sans);
  line-height: 1.6;
  margin-bottom: 12px;
  color: #444;
}

/* Recent posts on home */
.home-recent-post {
  display: flex;
  gap: 10px;
  padding-bottom: 14px;
  margin-bottom: 10px;
  background-image: var(--dot-sep);
  min-height: 62px;
}
.home-recent-post img {
  flex: 0 0 60px;
  width: 60px;
  height: 60px;
  object-fit: cover;
}
.home-recent-title {
  font-family: var(--font-sans);
  font-size: 0.85em;
  font-weight: 700;
  margin-bottom: 2px;
}
.home-recent-title a { color: #000; }
.home-recent-title a:hover { text-decoration: underline; }
.home-recent-date,
.home-recent-author { color: #666; font-size: 0.8em; }

/* ─── Section headings (mast variants) ─────────────────── */
.mast {
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-red);
  padding-bottom: 6px;
  margin-bottom: 14px;
}
.mast2 {
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-green);
  padding-bottom: 6px;
  margin-bottom: 10px;
}
.mast3 {
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-navy);
  padding-bottom: 6px;
}
.mast4 {
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding-bottom: 6px;
}

/* ─── Sidebar ───────────────────────────────────────────── */
.sidebar { padding-top: 4px; }

.widget {
  margin-bottom: 22px;
}
.widget-title {
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding-bottom: 6px;
  margin-bottom: 10px;
  color: #333;
  border-bottom: 1px solid var(--border);
}
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget ul li {
  padding: 0 0 5px 20px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border);
  font-size: 0.85em;
  position: relative;
}
.widget ul li::before {
  content: '›';
  position: absolute;
  left: 6px;
  color: #999;
}
.widget ol { list-style: none; margin: 0; padding: 0; }
.widget ol li {
  padding: 0 0 5px 10px;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border);
  font-size: 0.85em;
}
.widget a { color: var(--accent-navy); }
.widget a:hover { color: #000; }

/* Category list */
ul.cat li { padding: 0; margin: 0; }
ul.cat li a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-transform: uppercase;
  font-size: 0.75em;
  font-weight: 700;
  font-family: var(--font-sans);
  color: #000;
  border-bottom: 1px solid var(--border);
  border-left: 3px solid var(--border);
  padding: 4px 10px 4px 8px;
  margin-bottom: 2px;
  height: 22px;
  transition: background var(--transition), border-color var(--transition), color var(--transition);
}
ul.cat li a:hover {
  background: #f1f1f1;
  color: var(--accent-link);
  border-left-color: var(--accent-link);
}

/* Recent comments */
ul#recentcomments li {
  padding-left: 20px;
  position: relative;
}
ul#recentcomments li::before {
  content: '💬';
  position: absolute;
  left: 0;
  font-size: 0.7em;
  top: 2px;
}

/* Calendar widget */
#wp-calendar {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 16px;
  font-size: 0.8em;
  font-family: var(--font-sans);
}
#wp-calendar caption {
  text-transform: uppercase;
  font-size: 0.85em;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--accent-navy);
  padding-bottom: 6px;
  text-align: left;
}
#wp-calendar th,
#wp-calendar td {
  padding: 3px 5px;
  text-align: right;
  border-bottom: 1px solid #efefef;
  border-right: 2px solid #fff;
}
#wp-calendar th { background: #dadada; font-weight: 700; color: #000; }
#wp-calendar td#today { background: #f2f2f2; font-weight: 700; }
#wp-calendar td a { font-weight: 700; }

/* Tag cloud */
.widget .tagcloud a {
  display: inline-block;
  margin: 2px;
  padding: 2px 6px;
  background: #f0f0f0;
  border: 1px solid var(--border);
  font-size: 0.8em !important;
  color: var(--accent-navy);
  border-radius: var(--radius);
}
.widget .tagcloud a:hover { background: #000; color: #fff; border-color: #000; }

/* Search widget */
.widget_search label { display: none; }
.widget_search .search-field { width: 100%; }

/* ─── Archive / Blog listing ────────────────────────────── */
.archive-content {
  display: grid;
  grid-template-columns: 190px 1fr 200px;
  gap: 0 var(--col-gap);
  padding: 24px var(--col-gap) 0;
}

.archive-info {}

.archive-meta { margin-top: 16px; border-top: 1px solid var(--border); }

h2.archive-name {
  font-family: var(--font-display);
  letter-spacing: -0.04em;
  font-size: 1.8em;
  margin-bottom: 4px;
  font-weight: 700;
}

.archive-feed,
.archive-number,
.archive-email {
  padding: 6px 0 6px 22px;
  border-bottom: 1px solid var(--border);
  font-size: 0.85em;
  color: #666;
  position: relative;
}
.archive-feed a { color: #666; }

.archive-post-block {
  padding: 10px 0 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 18px;
}

.archive-title {
  line-height: 1.2;
  padding-bottom: 4px;
  font-size: 1em;
}
.archive-title a {
  font-family: var(--font-display);
  font-size: 1.15em;
  color: #000;
  letter-spacing: -0.03em;
  font-weight: 700;
}
.archive-title a:hover { color: #fff; background: #000; }

.archive-post-meta {
  color: #666;
  padding: 2px 0 6px;
  font-family: var(--font-sans);
  font-size: 0.75em;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.archive-post-meta a { color: var(--accent-link); }
.archive-post-meta a:hover { color: #000; text-decoration: underline; }
.archive-post-meta .dot { color: #ccc; margin: 0 4px; }

.archive-excerpt {
  font-size: 0.9em;
  line-height: 1.65;
  color: #444;
  margin-bottom: 12px;
}

/* ─── Single Post ───────────────────────────────────────── */
.post-content-wrap {
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: 0 var(--col-gap);
  padding: 24px var(--col-gap) 0;
}

.post-main {}

h2.post-category {
  font-family: var(--font-sans);
  font-size: 0.72em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #999;
  border-bottom: 1px solid var(--border);
  padding-bottom: 5px;
  margin-bottom: 12px;
}

.entry-title {
  font-family: var(--font-display);
  font-size: 2.2em;
  letter-spacing: -0.04em;
  line-height: 1.15;
  margin-bottom: 10px;
  font-weight: 700;
}

.post-meta {
  color: #666;
  padding: 4px 0 6px;
  font-family: var(--font-sans);
  font-size: 0.75em;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  border-bottom: 1px solid var(--border);
  margin-bottom: 6px;
}
.post-meta a { color: var(--accent-link); }
.post-meta a:hover { color: #000; text-decoration: underline; }
.post-meta .dot { color: #ccc; margin: 0 4px; }

.post-hero {
  width: 100%;
  max-height: 340px;
  object-fit: cover;
  margin-bottom: 18px;
}

.entry-content { margin-top: 14px; }
.entry-content p { margin-bottom: 16px; line-height: 1.75; }
.entry-content a { border-bottom: 1px solid #eee; color: var(--accent-link); }
.entry-content a:hover { color: #000; border-bottom-color: #000; }

.entry-content blockquote {
  float: right;
  width: 240px;
  color: #000;
  margin: 0 0 16px 24px;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.25em;
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.4;
  border: none;
}
.entry-content blockquote p { text-align: right; margin-bottom: 0; }

.entry-content ul,
.entry-content ol {
  margin: 0 0 1.5em 1.5em;
  padding: 0;
}
.entry-content ul { list-style: disc; }
.entry-content ol { list-style: decimal; }
.entry-content li { margin-bottom: 0.4em; }

/* Filed under */
.filed-under {
  background: #111;
  color: #eee;
  padding: 1px 6px;
  text-transform: uppercase;
  font-family: var(--font-sans);
  font-size: 0.75em;
  font-weight: 700;
  display: inline-block;
  margin-right: 4px;
}

/* Post navigation */
.post-navigation {
  font-family: var(--font-sans);
  font-size: 0.75em;
  font-weight: 700;
  text-transform: uppercase;
  color: #818181;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
  margin-top: 10px;
  display: flex;
  justify-content: space-between;
}
.post-navigation a { color: var(--accent-link); }
.post-navigation a:hover { text-decoration: underline; }

/* ─── Comments ──────────────────────────────────────────── */
#comments { margin-top: 40px; }

h2.comments-title {
  font-family: var(--font-sans);
  font-size: 0.85em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #000;
  border-bottom: 1px solid var(--border);
  border-top: 3px solid #999;
  padding: 8px 0 6px;
  margin-bottom: 16px;
  background: var(--stripe);
}

ol.comment-list { list-style: none; padding: 0; }

.comment {
  border-right: 3px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-bottom: 18px;
  padding: 0 14px 0 0;
  overflow: hidden;
}
.comment.even  { border-right-color: var(--border-dark); }
.comment.bypostauthor { border-right-color: #000; border-bottom-color: #000; }

.comment-number {
  width: 36px;
  float: left;
  font-size: 2.6em;
  font-weight: 900;
  font-family: var(--font-display);
  color: #ccc;
  line-height: 1;
}

.comment-body { overflow: hidden; }

.comment-author cite {
  font-style: normal;
  display: block;
  color: #818181;
  text-transform: uppercase;
  font-family: var(--font-sans);
  font-size: 0.75em;
  letter-spacing: 0.04em;
  margin-bottom: 6px;
}
.comment-author cite a { color: var(--accent-link); font-weight: 700; }
.comment-author cite a:hover { color: #000; text-decoration: underline; }

.comment-content p { font-size: 0.9em; line-height: 1.65; margin-bottom: 12px; }

.reply a {
  color: #fff;
  background: var(--accent-link);
  font-family: var(--font-sans);
  font-size: 0.75em;
  text-transform: uppercase;
  padding: 2px 6px;
  font-weight: 700;
  display: inline-block;
  margin-bottom: 20px;
}
.reply a:hover { background: #000; }

/* Threaded comment children */
.children {
  list-style: none;
  margin: 0 0 0 2em;
  padding: 0;
}
.children .comment {
  border-right: 0;
  border-bottom: 0;
  border-top: 1px dashed #bbb;
  padding-top: 14px;
  margin: 0;
}

/* ─── Comment form ──────────────────────────────────────── */
#respond { margin-top: 30px; }

h3#reply-title {
  font-family: var(--font-sans);
  font-size: 0.75em;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #000;
  border-bottom: 1px solid var(--border);
  padding-bottom: 5px;
  margin-bottom: 20px;
  display: block;
  float: left;
  width: 100%;
}

#respond small { display: block; margin-top: 4px; font-size: 0.9em; }
#respond #cancel-comment-reply-link {
  display: inline-block;
  padding: 3px 6px;
  margin: 5px 0;
  font-size: 0.9em;
  color: #fff;
  background: var(--accent-link);
}
#respond #cancel-comment-reply-link:hover { background: #000; }

#commentform { clear: both; }
#commentform p { margin-bottom: 14px; }
#commentform label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.8em;
  font-weight: 700;
  margin-bottom: 4px;
  color: #333;
}
#commentform input[type="text"],
#commentform input[type="email"],
#commentform input[type="url"],
#commentform textarea {
  width: 100%;
  max-width: 400px;
  border: 1px solid #dadada;
  border-top-color: #999;
  border-left-color: #999;
  padding: 5px 8px;
  font-family: var(--font-body);
  font-size: 0.9em;
  background: #fff;
  outline: none;
  transition: background var(--transition);
}
#commentform input:focus,
#commentform textarea:focus { background: #f7f7f7; }
#commentform textarea { height: 160px; max-width: 100%; width: 100%; }

#commentform input#submit {
  background: var(--accent-link);
  color: #fff;
  border: none;
  padding: 7px 20px;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.85em;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: background var(--transition);
}
#commentform input#submit:hover { background: #000; }

/* ─── Pager navigation ──────────────────────────────────── */
.page-navigation {
  font-family: var(--font-sans);
  font-size: 0.75em;
  font-weight: 700;
  text-transform: uppercase;
  color: #818181;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
  margin-top: 10px;
}
.page-navigation a { color: var(--accent-link); }
.page-navigation a:hover { text-decoration: underline; }

/* ─── Info boxes ─────────────────────────────────────────── */
p.alert, p.download, p.info, p.note, p.tick {
  margin: 12px 0 20px;
  padding: 10px 12px 10px 48px;
  position: relative;
  font-size: 0.9em;
  line-height: 1.5;
}
p.alert::before, p.download::before, p.info::before, p.note::before, p.tick::before {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.3em;
}
p.alert  { background: #ffd9c8; border-top: 1px solid #f0baa2; border-bottom: 1px solid #f0baa2; }
p.alert::before  { content: '⚠'; color: #c63f00; }
p.download, p.tick { background: #edfcd5; border-top: 1px solid #d4ebaf; border-bottom: 1px solid #d4ebaf; }
p.download::before { content: '↓'; color: var(--accent-green); }
p.tick::before  { content: '✓'; color: var(--accent-green); }
p.info  { background: #eee; border-top: 1px solid #ccc; border-bottom: 1px solid #ccc; }
p.info::before  { content: 'ℹ'; color: #555; }
p.note  { background: #fef6d2; border-top: 1px solid #efe3ae; border-bottom: 1px solid #efe3ae; }
p.note::before  { content: '✎'; color: #888; }

/* ─── Gallery ────────────────────────────────────────────── */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; margin-bottom: 16px; }
.gallery-item { margin: 0; }
.gallery-icon { background: var(--stripe); padding: 6px; }
.gallery-icon img { border: 5px solid #bbb; width: 100%; }
.gallery-caption { font-size: 0.75em; text-align: center; text-transform: uppercase; letter-spacing: 0.08em; padding: 4px 0; color: #555; }

/* ─── WordPress image classes ───────────────────────────── */
.aligncenter, div.aligncenter { display: block; margin: 14px auto; }
.alignleft  { float: left; margin: 0 14px 10px 0; }
.alignright { float: right; margin: 0 0 10px 14px; }

.wp-caption {
  border: 1px solid #ddd;
  background: #f3f3f3;
  padding: 4px;
  border-radius: var(--radius);
  text-align: center;
  max-width: 100%;
}
.wp-caption img { margin: 0; }
.wp-caption-text { font-size: 0.85em; padding: 4px 5px; color: #555; margin: 0; }

/* ─── Site Footer ───────────────────────────────────────── */
.site-footer {
  padding: 14px var(--col-gap) 0;
  border-top: 4px dotted var(--border);
  color: #666;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  font-family: var(--font-sans);
  font-size: 0.85em;
  margin-top: 28px;
}
.site-footer p { margin: 0; }
.site-footer a { color: #666; }
.site-footer a:hover { text-decoration: underline; }
.site-footer #credit { text-align: right; }

/* ─── 404 / No results ──────────────────────────────────── */
.not-found-content,
.no-results-content {
  padding: 40px var(--col-gap);
  text-align: center;
  color: #666;
}
.not-found-content h1,
.no-results-content h2 {
  font-family: var(--font-display);
  font-size: 3em;
  color: #ccc;
  margin-bottom: 12px;
}

/* ─── Search results page ───────────────────────────────── */
.search-results-content {
  padding: 24px var(--col-gap) 0;
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: 0 var(--col-gap);
}

/* ─── Full-width template ───────────────────────────────── */
.full-width-content {
  padding: 24px var(--col-gap) 0;
}

/* ─── Misc helpers ──────────────────────────────────────── */
.clear { clear: both; }
.fl    { float: left; }
.fr    { float: right; }
.screen-reader-text {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ─── Responsive ────────────────────────────────────────── */
@media (max-width: 900px) {
  .home-content    { grid-template-columns: 1fr; }
  .archive-content { grid-template-columns: 160px 1fr; }
  .archive-content .sidebar { display: none; }
  .post-content-wrap { grid-template-columns: 1fr; }
  .post-content-wrap .sidebar { display: none; }
  .search-results-content { grid-template-columns: 1fr; }
  .search-results-content .sidebar { display: none; }
  .header-panel { width: auto; flex: 1 1 auto; }
  .site-header { flex-wrap: wrap; }
}

@media (max-width: 680px) {
  .site-header { flex-direction: column; gap: 14px; padding-bottom: 10px; }
  .header-panel { width: 100%; border-left: none; border-top: 1px solid #ddd; padding-left: 0; padding-top: 12px; }
  .main-navigation { flex-direction: column; }
  .nav-rss { padding: 6px 0; border-top: 1px solid var(--border); }
  .archive-content { grid-template-columns: 1fr; }
  .archive-content .archive-info { display: none; }
  .entry-content blockquote { float: none; width: auto; margin: 0 0 16px; }
  .site-title { font-size: 2.2em; }
}

@media (max-width: 480px) {
  .site { padding-bottom: 16px; }
  .home-content,
  .archive-content,
  .post-content-wrap,
  .full-width-content { padding: 14px 12px 0; }
  .site-header      { padding: 14px 12px 0; }
  .main-navigation  { padding: 0 12px; }
  .top-banner       { padding: 0 12px; }
  .site-footer      { padding: 14px 12px 0; flex-direction: column; gap: 8px; }
  .site-footer #credit { text-align: left; }
  #commentform input[type="text"],
  #commentform input[type="email"],
  #commentform input[type="url"] { max-width: 100%; }
}
