/*
Theme Name: Carolina Gayniacs
Theme URI: https://carolinagayniacs.com
Author: Carolina Gayniacs
Author URI: https://carolinagayniacs.com
Description: A warm, community-first WordPress theme for the Carolina Gayniacs network. Supports multisite with network/subsite branding, block editor patterns, and full WCAG 2.1 AA accessibility.
Version: 1.1.0
Requires at least: 6.4
Tested up to: 6.7
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: carolina-gayniacs
Tags: accessibility-ready, block-styles, custom-logo, custom-menu, editor-style, featured-images, one-column, two-columns, wide-blocks
*/

/* ================================================================
   CUSTOM PROPERTIES
   ================================================================ */
:root {
  --pride-red: #E40303;
  --pride-orange: #FF8C00;
  --pride-yellow: #FFED00;
  --pride-green: #008026;
  --pride-blue: #004DFF;
  --pride-purple: #750787;
  --pride-gradient: linear-gradient(90deg,
    var(--pride-red), var(--pride-orange), var(--pride-yellow),
    var(--pride-green), var(--pride-blue), var(--pride-purple));

  --active-color: #CE1126;

  --bg: #faf9f7;
  --white: #ffffff;
  --text: #2d2a26;
  --text-soft: #6e6a63;
  --border: #eae7e2;
  --border-strong: #d6d2cb;
  --surface-hover: #f5f3f0;

  --radius: 10px;
  --radius-sm: 6px;
  --page-pad: 1.5rem;
  --content-width: 1080px;
  --wide-width: 1280px;
  --font: 'Nunito', system-ui, -apple-system, sans-serif;
}

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

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--active-color); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { text-decoration: none; }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ================================================================
   EXTERNAL LINK ICON
   ================================================================ */
a.cg-external::after {
  content: '';
  display: inline-block;
  width: 0.75em;
  height: 0.75em;
  margin-left: 0.25em;
  vertical-align: baseline;
  /* SVG external link icon */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='currentColor' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 8.667V12.667A1.333 1.333 0 0 1 10.667 14H3.333A1.333 1.333 0 0 1 2 12.667V5.333A1.333 1.333 0 0 1 3.333 4H7.333'/%3E%3Cpath d='M10 2H14V6'/%3E%3Cpath d='M6.667 9.333L14 2'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0.55;
}

/* Don't add icon in nav, user dropdown, or buttons */
.header-nav a.cg-external::after,
.mobile-nav-panel a.cg-external::after,
.user-dropdown a.cg-external::after,
.wp-block-button__link.cg-external::after,
.skip-link.cg-external::after {
  display: none;
}

/* ================================================================
   SKIP LINK
   ================================================================ */
.skip-link {
  position: absolute; top: -100%; left: 1rem;
  background: var(--text); color: #fff;
  padding: 0.6rem 1.2rem; border-radius: 0 0 8px 8px;
  font-weight: 700; z-index: 200;
  text-decoration: none; transition: top 0.2s;
}
.skip-link:focus { top: 0; }

/* ================================================================
   PRIDE BAR
   ================================================================ */
.pride-bar {
  height: 10px;
  background: var(--pride-gradient);
}

/* ================================================================
   ALERT BAR
   ================================================================ */
.alert-bar {
  padding: 0.55rem var(--page-pad);
  font-size: 0.88rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.35;
}

.alert-bar a { color: inherit; text-decoration: underline; }

.alert-bar--red {
  background: var(--active-color);
  color: #fff;
}

.alert-bar--yellow {
  background: #FFED00;
  color: #1a1a00;
}

/* ================================================================
   SITE HEADER — scaled up ~120%
   ================================================================ */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 0 var(--page-pad);
  position: sticky;
  top: 0;
  z-index: 100;
}

.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }

.header-inner {
  max-width: var(--content-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0.75rem 0;
  gap: 1.25rem;
}

/* Left-aligned nav variant */
.header-inner.nav-left {
  grid-template-columns: auto 1fr auto;
}

.header-inner.nav-left .header-nav-zone {
  justify-self: start;
  margin-left: 1.5rem;
}

/* Logo zone */
.header-logo-zone {
  display: flex;
  align-items: center;
  justify-self: start;
}

.logo-link {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: inherit;
  flex-shrink: 0;
}

.logo-icon {
  width: 53px; height: 53px;
  border-radius: var(--radius);
  background: var(--pride-gradient);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; overflow: hidden;
}

.logo-icon img { width: 100%; height: 100%; object-fit: contain; }
.logo-icon svg { width: 31px; height: 31px; }

.logo-words { display: flex; flex-direction: column; line-height: 1.15; }
.logo-words .org { font-size: 0.86rem; font-weight: 600; color: var(--text-soft); letter-spacing: 0.02em; }
.logo-words .site { font-size: 1.5rem; font-weight: 800; color: var(--text); letter-spacing: -0.01em; }
.logo-words .site:first-child { font-size: 1.55rem; }

/* Nav zone */
.header-nav-zone { justify-self: center; }

.header-nav {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  list-style: none;
}

.header-nav .nav-link {
  position: relative;
  padding: 0.5rem 0.85rem;
  font-size: 1.05rem; font-weight: 600;
  color: var(--text-soft);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
  white-space: nowrap;
  display: flex; align-items: center; gap: 0.3rem;
}

.header-nav .nav-link:hover,
.header-nav .nav-link:focus-visible { color: var(--text); background: var(--surface-hover); }

.header-nav .current-menu-item > a,
.header-nav .current-menu-ancestor > a,
.header-nav .nav-link.active { color: var(--text); }

.header-nav .current-menu-item > a::after,
.header-nav .nav-link.active::after {
  content: ''; position: absolute;
  bottom: 3px; left: 50%; transform: translateX(-50%);
  width: 22px; height: 3px; border-radius: 3px;
  background: var(--active-color);
}

.header-nav .menu-item-has-children { position: relative; }

.header-nav .menu-item-has-children > a::before {
  content: '';
  display: inline-block;
  width: 0; height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 4.5px solid currentColor;
  margin-left: 5px;
  opacity: 0.45;
  vertical-align: middle;
  order: 1;
}

.header-nav .sub-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%) translateY(-4px);
  min-width: 200px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 8px 28px rgba(0,0,0,0.08), 0 2px 8px rgba(0,0,0,0.04);
  list-style: none;
  padding: 0.4rem;
  opacity: 0; visibility: hidden;
  transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
  z-index: 60;
}

.header-nav .menu-item-has-children.open > .sub-menu {
  opacity: 1; visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.header-nav .sub-menu a {
  display: block;
  padding: 0.5rem 0.85rem;
  font-size: 1rem; font-weight: 500;
  color: var(--text-soft);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: background 0.1s, color 0.1s;
}

.header-nav .sub-menu a:hover,
.header-nav .sub-menu a:focus-visible { background: var(--surface-hover); color: var(--text); }

/* User zone */
.header-user-zone { display: flex; align-items: center; justify-self: end; }

.user-wrap { position: relative; }

.user-btn {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.3rem 0.5rem 0.3rem 0.3rem;
  border: none; background: none; cursor: pointer;
  border-radius: 24px; transition: background 0.15s;
  font-family: var(--font);
}

.user-btn:hover, .user-btn:focus-visible { background: var(--surface-hover); }

.avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--border);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 0.88rem; color: var(--text-soft);
  overflow: hidden;
}

.avatar img { width: 100%; height: 100%; object-fit: cover; }

.user-btn .uname { font-size: 1.05rem; font-weight: 600; color: var(--text); }

.user-btn .chevron {
  width: 14px; height: 14px; color: var(--text-soft); transition: transform 0.2s;
}

.user-wrap.open .user-btn .chevron { transform: rotate(180deg); }

.user-dropdown {
  position: absolute; top: calc(100% + 6px); right: 0;
  min-width: 175px; background: var(--white);
  border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: 0 8px 28px rgba(0,0,0,0.08), 0 2px 8px rgba(0,0,0,0.04);
  list-style: none; padding: 0.4rem;
  opacity: 0; visibility: hidden; transform: translateY(-4px);
  transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
  z-index: 70;
}

.user-wrap.open .user-dropdown { opacity: 1; visibility: visible; transform: translateY(0); }

.user-dropdown .dd-name {
  display: none; padding: 0.45rem 0.75rem 0.3rem;
  font-size: 0.88rem; font-weight: 700; color: var(--text);
}

.user-dropdown .dd-sep { height: 1px; background: var(--border); margin: 0.3rem 0.4rem; }

.user-dropdown a {
  display: block; padding: 0.45rem 0.75rem;
  font-size: 0.95rem; font-weight: 500; color: var(--text-soft);
  text-decoration: none; border-radius: var(--radius-sm);
  transition: background 0.1s, color 0.1s;
}

.user-dropdown a:hover, .user-dropdown a:focus-visible { background: var(--surface-hover); color: var(--text); }
.user-dropdown a.logout { color: #c0392b; font-weight: 600; }
.user-dropdown a.logout:hover, .user-dropdown a.logout:focus-visible { background: #fdf0ef; }

/* Login link (when not authenticated) */
.login-link {
  font-size: 1.05rem; font-weight: 600;
  color: var(--text-soft);
  text-decoration: none;
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
}

.login-link:hover, .login-link:focus-visible {
  color: var(--text);
  background: var(--surface-hover);
}

/* Mobile toggle */
.mobile-toggle {
  display: none; width: 42px; height: 42px;
  align-items: center; justify-content: center;
  border: none; background: none; color: var(--text-soft);
  cursor: pointer; border-radius: var(--radius-sm); flex-shrink: 0;
}

.mobile-toggle svg { width: 24px; height: 24px; }

/* ================================================================
   MOBILE NAV PANEL
   ================================================================ */
.mobile-nav-panel {
  display: none;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 0.5rem var(--page-pad) 0.75rem;
}

/* ================================================================
   CONTENT LAYOUT
   ================================================================ */
.site-content {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 2rem var(--page-pad);
}

.site-content.wide { max-width: var(--wide-width); }
.site-content.full-width { max-width: 100%; padding-left: 0; padding-right: 0; }

.content-wrap {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 2rem;
  align-items: start;
}

.content-wrap.no-sidebar { grid-template-columns: 1fr; }

/* ================================================================
   ENTRIES
   ================================================================ */
.entry {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}
.entry:last-child { margin-bottom: 0; }

.entry-header { margin-bottom: 1rem; }

.entry-title { font-size: 1.5rem; font-weight: 800; line-height: 1.2; margin-bottom: 0.35rem; }
.entry-title a { color: var(--text); text-decoration: none; }
.entry-title a:hover { color: var(--active-color); }

.entry-meta { font-size: 0.82rem; color: var(--text-soft); display: flex; flex-wrap: wrap; gap: 0.75rem; }
.entry-meta a { color: var(--text-soft); }
.entry-meta a:hover { color: var(--active-color); }

.entry-thumbnail { margin-bottom: 1rem; border-radius: var(--radius-sm); overflow: hidden; }
.entry-thumbnail img { width: 100%; height: auto; aspect-ratio: 16/9; object-fit: cover; }

.entry-content { font-size: 1rem; line-height: 1.7; }
.entry-content > *:not(:last-child) { margin-bottom: 1.25rem; }
.entry-content h2 { font-size: 1.4rem; font-weight: 800; }
.entry-content h3 { font-size: 1.2rem; font-weight: 700; }
.entry-content h4 { font-size: 1.05rem; font-weight: 700; }

.entry-content blockquote {
  border-left: 4px solid var(--active-color);
  padding: 0.75rem 1.25rem;
  background: var(--surface-hover);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
}

.entry-content ul, .entry-content ol { padding-left: 1.5rem; }
.entry-content code { background: var(--surface-hover); padding: 0.15em 0.35em; border-radius: 3px; font-size: 0.9em; }
.entry-content pre { background: var(--text); color: #e0e0e0; padding: 1.25rem; border-radius: var(--radius-sm); overflow-x: auto; font-size: 0.88rem; }
.entry-content pre code { background: none; padding: 0; color: inherit; }

.entry-footer { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--border); font-size: 0.82rem; color: var(--text-soft); }
.entry-footer a { color: var(--text-soft); }
.entry-footer a:hover { color: var(--active-color); }

.read-more { display: inline-block; font-weight: 700; font-size: 0.88rem; color: var(--active-color); text-decoration: none; }
.read-more:hover { text-decoration: underline; }

/* ================================================================
   SIDEBAR
   ================================================================ */
.sidebar { position: sticky; top: calc(90px + 1rem); }

.widget {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.25rem; margin-bottom: 1.25rem;
}
.widget:last-child { margin-bottom: 0; }

.widget-title { font-size: 0.95rem; font-weight: 700; margin-bottom: 0.75rem; padding-bottom: 0.5rem; border-bottom: 2px solid var(--border); }

.widget ul { list-style: none; }
.widget ul li { padding: 0.35rem 0; border-bottom: 1px solid var(--border); font-size: 0.88rem; }
.widget ul li:last-child { border-bottom: none; }
.widget ul li a { color: var(--text-soft); text-decoration: none; }
.widget ul li a:hover { color: var(--active-color); }

/* ================================================================
   SEARCH
   ================================================================ */
.search-form { display: flex; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; background: var(--white); }

.search-form .search-field {
  flex: 1; border: none; padding: 0.55rem 0.75rem;
  font-family: var(--font); font-size: 0.9rem; color: var(--text);
  background: transparent; outline: none;
}

.search-form .search-field:focus { box-shadow: inset 0 0 0 2px var(--pride-blue); border-radius: var(--radius-sm) 0 0 var(--radius-sm); }

.search-form .search-submit {
  padding: 0.55rem 1rem; background: var(--text); color: var(--white);
  border: none; font-family: var(--font); font-weight: 700; font-size: 0.85rem;
  cursor: pointer; transition: background 0.15s;
}

.search-form .search-submit:hover { background: var(--active-color); }

.search-results-header { margin-bottom: 1.5rem; }
.search-results-header h1 { font-size: 1.5rem; font-weight: 800; }
.search-results-header p { color: var(--text-soft); font-size: 0.9rem; }

/* ================================================================
   PAGINATION
   ================================================================ */
.pagination { display: flex; justify-content: center; align-items: center; gap: 0.35rem; margin-top: 2rem; font-size: 0.88rem; font-weight: 600; }

.pagination a, .pagination span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 36px; height: 36px; padding: 0 0.5rem;
  border-radius: var(--radius-sm); text-decoration: none; color: var(--text-soft);
  transition: background 0.15s, color 0.15s;
}

.pagination a:hover { background: var(--surface-hover); color: var(--text); }
.pagination .current { background: var(--text); color: var(--white); }

/* ================================================================
   COMMENTS
   ================================================================ */
.comments-area { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; margin-top: 1.5rem; }
.comments-title { font-size: 1.15rem; font-weight: 700; margin-bottom: 1rem; }
.comment-list { list-style: none; }
.comment { padding: 1rem 0; border-bottom: 1px solid var(--border); }
.comment:last-child { border-bottom: none; }
.comment-meta { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; font-size: 0.85rem; }
.comment-author { font-weight: 700; }
.comment-date { color: var(--text-soft); }
.comment-body p { font-size: 0.95rem; }
.comment-respond { margin-top: 1.5rem; }
.comment-form label { display: block; font-weight: 600; font-size: 0.88rem; margin-bottom: 0.25rem; }

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%; padding: 0.55rem 0.75rem; border: 1px solid var(--border);
  border-radius: var(--radius-sm); font-family: var(--font); font-size: 0.9rem;
  color: var(--text); margin-bottom: 0.75rem; outline: none;
}

.comment-form input:focus, .comment-form textarea:focus { border-color: var(--pride-blue); box-shadow: 0 0 0 2px rgba(0,77,255,0.15); }

.comment-form .submit {
  background: var(--text); color: var(--white); border: none; padding: 0.6rem 1.5rem;
  border-radius: var(--radius-sm); font-family: var(--font); font-weight: 700;
  font-size: 0.9rem; cursor: pointer; transition: background 0.15s;
}

.comment-form .submit:hover { background: var(--active-color); }

/* ================================================================
   ARCHIVE / CATEGORY HEADERS
   ================================================================ */
.archive-header { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; margin-bottom: 1.5rem; }
.archive-header .archive-label { font-size: 0.78rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-soft); margin-bottom: 0.15rem; }
.archive-header h1 { font-size: 1.5rem; font-weight: 800; }
.archive-header .archive-description { margin-top: 0.5rem; color: var(--text-soft); font-size: 0.92rem; }

/* ================================================================
   404
   ================================================================ */
.error-404 { text-align: center; padding: 4rem 1rem; }
.error-404 h1 { font-size: 4rem; font-weight: 800; color: var(--border-strong); margin-bottom: 0.5rem; }
.error-404 p { font-size: 1.1rem; color: var(--text-soft); margin-bottom: 1.5rem; }

/* ================================================================
   LIVEBLOG PLUGIN (Automattic/liveblog)
   Actual markup (from live site):
     article.liveblog-entry
       aside.liveblog-entry-aside
         a.liveblog-meta-time
           span (relative time)
           span (date)
       div.liveblog-entry-main
         header.liveblog-meta-authors
           div.liveblog-meta-author
             div.liveblog-meta-author-avatar > img
             span.liveblog-meta-author-name
         div.liveblog-entry-content > p
   ================================================================ */

/* Container */
#liveblog-container {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

/* ---- INDIVIDUAL ENTRY ---- */
article.liveblog-entry {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 0;
  border-bottom: 1px solid var(--border);
  transition: background 0.3s ease;
  position: relative;
}

article.liveblog-entry:last-child { border-bottom: none; }

/* New entry flash */
article.liveblog-entry.is-new { animation: cg-entry-flash 2s ease-out; }

@keyframes cg-entry-flash {
  0% { background: rgba(206, 17, 38, 0.06); }
  100% { background: transparent; }
}

/* ---- ASIDE (timestamp column) ---- */
.liveblog-entry-aside {
  padding: 1rem 0 1rem 1rem;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  border-right: 3px solid var(--border);
  transition: border-color 0.2s;
}

article.liveblog-entry:hover .liveblog-entry-aside {
  border-right-color: var(--active-color);
}

.liveblog-entry-aside .liveblog-meta-time {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.1rem;
  text-decoration: none;
  padding: 0.2rem 0.35rem;
  border-radius: var(--radius-sm);
  transition: background 0.15s;
}

.liveblog-entry-aside .liveblog-meta-time:hover {
  background: var(--surface-hover);
}

/* Relative time: "4 minutes ago" */
.liveblog-entry-aside .liveblog-meta-time span:first-child {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-soft);
  line-height: 1.2;
  white-space: nowrap;
}

/* Date: "April 11, 2026" — hide on desktop, show on mobile */
.liveblog-entry-aside .liveblog-meta-time span:last-child {
  display: none;
  font-size: 0.65rem;
  color: var(--text-soft);
  opacity: 0.7;
}

/* ---- MAIN CONTENT AREA ---- */
.liveblog-entry-main {
  padding: 1rem 1.25rem;
  min-width: 0;
}

/* Author header */
.liveblog-meta-authors {
  margin-bottom: 0.45rem;
}

.liveblog-meta-author {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.liveblog-meta-author-avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--border);
  line-height: 0;
}

.liveblog-meta-author-avatar img {
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.liveblog-meta-author-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text);
}

/* Entry content */
.liveblog-entry-content {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text);
}

.liveblog-entry-content p { margin-bottom: 0.5rem; }
.liveblog-entry-content p:last-child { margin-bottom: 0; }

.liveblog-entry-content img {
  max-width: 100%; height: auto;
  border-radius: var(--radius-sm);
  margin: 0.5rem 0;
}

.liveblog-entry-content blockquote {
  border-left: 3px solid var(--active-color);
  padding: 0.5rem 1rem;
  margin: 0.5rem 0;
  background: var(--surface-hover);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
}

.liveblog-entry-content a {
  color: var(--active-color);
  font-weight: 600;
}

/* ---- ENTRY ACTIONS (edit/delete for logged-in editors) ---- */
.liveblog-entry-actions {
  display: flex;
  gap: 0.4rem;
  margin-top: 0.65rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border);
  list-style: none;
}

.liveblog-entry-actions li { display: inline-flex; }

.liveblog-entry-actions button {
  font-family: var(--font);
  font-size: 0.78rem; font-weight: 600;
  padding: 0.3rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--white);
  color: var(--text-soft);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.liveblog-entry-actions button:hover {
  background: var(--surface-hover);
  color: var(--text);
  border-color: var(--border-strong);
}

.liveblog-entry-actions .liveblog-entry-delete:hover {
  color: #c0392b;
  border-color: #c0392b;
  background: #fdf0ef;
}

/* ---- KEY EVENTS ---- */
article.liveblog-entry.type-key .liveblog-entry-aside {
  border-right-color: var(--active-color);
  border-right-width: 4px;
}

article.liveblog-entry.type-key {
  background: rgba(206, 17, 38, 0.025);
}

/* /highlight command */
article.liveblog-entry.type-highlight .liveblog-entry-aside {
  border-right-color: var(--pride-yellow);
  border-right-width: 4px;
}

article.liveblog-entry.type-highlight {
  background: rgba(255, 237, 0, 0.06);
}

/* Key Events sidebar widget / shortcode */
.liveblog-key-events {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.liveblog-key-events h2,
.liveblog-key-events h3 {
  padding: 0.85rem 1.1rem;
  font-size: 0.92rem; font-weight: 700;
  margin: 0;
  background: var(--surface-hover);
  border-bottom: 1px solid var(--border);
}

.liveblog-key-events div,
.liveblog-key-events li { border-bottom: 1px solid var(--border); }

.liveblog-key-events div:last-child,
.liveblog-key-events li:last-child { border-bottom: none; }

.liveblog-key-events a {
  display: block;
  padding: 0.65rem 1.1rem;
  font-size: 0.88rem; font-weight: 600;
  color: var(--text);
  text-decoration: none;
  transition: background 0.1s, padding-left 0.15s;
  position: relative;
}

.liveblog-key-events a:hover {
  background: var(--surface-hover);
  padding-left: 1.35rem;
}

.liveblog-key-events a::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px; background: transparent;
  transition: background 0.15s;
}

.liveblog-key-events a:hover::before { background: var(--active-color); }

/* Hashtags */
.liveblog-hash { color: var(--active-color); font-weight: 700; }

/* Emoji */
.liveblog-emoji { width: 1.2em; height: 1.2em; vertical-align: -0.15em; margin: 0 0.1em; }

/* ---- EDITOR FORM ---- */
.liveblog-form {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface-hover);
}

.liveblog-form textarea,
.liveblog-form .liveblog-input {
  width: 100%; min-height: 80px;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font); font-size: 0.92rem;
  color: var(--text); background: var(--white);
  outline: none; resize: vertical;
  transition: border-color 0.15s;
}

.liveblog-form textarea:focus,
.liveblog-form .liveblog-input:focus {
  border-color: var(--pride-blue);
  box-shadow: 0 0 0 2px rgba(0, 77, 255, 0.12);
}

.liveblog-form .liveblog-submit,
.liveblog-form button[type="submit"],
.liveblog-form input[type="submit"] {
  margin-top: 0.5rem;
  padding: 0.55rem 1.25rem;
  background: var(--active-color); color: var(--white);
  border: none; border-radius: var(--radius-sm);
  font-family: var(--font); font-weight: 700; font-size: 0.88rem;
  cursor: pointer; transition: background 0.15s;
}

.liveblog-form .liveblog-submit:hover,
.liveblog-form button[type="submit"]:hover,
.liveblog-form input[type="submit"]:hover {
  background: var(--text);
}

/* Load more */
.liveblog-between,
.liveblog-load-more {
  text-align: center;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
}

.liveblog-between a,
.liveblog-load-more a,
.liveblog-between button,
.liveblog-load-more button {
  display: inline-block;
  padding: 0.45rem 1.25rem;
  font-family: var(--font); font-size: 0.85rem; font-weight: 700;
  color: var(--text-soft);
  background: var(--surface-hover);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  text-decoration: none; cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.liveblog-between a:hover,
.liveblog-load-more a:hover,
.liveblog-between button:hover,
.liveblog-load-more button:hover {
  background: var(--white);
  color: var(--text);
  border-color: var(--border-strong);
}

/* Archived notice */
.liveblog-archived {
  padding: 0.75rem 1.25rem;
  background: var(--surface-hover);
  font-size: 0.85rem; font-weight: 600;
  color: var(--text-soft);
  text-align: center;
  border-bottom: 1px solid var(--border);
}

/* ---- LIVEBLOG MOBILE ---- */
@media (max-width: 600px) {
  article.liveblog-entry {
    grid-template-columns: 1fr;
  }

  .liveblog-entry-aside {
    border-right: none;
    border-bottom: 1px solid var(--border);
    padding: 0.65rem 1rem;
    justify-content: flex-start;
    background: var(--surface-hover);
  }

  article.liveblog-entry:hover .liveblog-entry-aside {
    border-right-color: transparent;
    border-bottom-color: var(--active-color);
  }

  .liveblog-entry-aside .liveblog-meta-time {
    flex-direction: row;
    gap: 0.5rem;
  }

  .liveblog-entry-aside .liveblog-meta-time span:last-child {
    display: inline;
  }

  .liveblog-entry-main { padding: 0.85rem 1rem; }
}

/* ================================================================
   FOOTER
   ================================================================ */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--white);
  padding: 1.25rem var(--page-pad);
  text-align: center;
  color: var(--text-soft);
  font-size: 0.8rem;
}

/* ================================================================
   FOCUS
   ================================================================ */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--pride-blue); outline-offset: 2px;
}

/* ================================================================
   BLOCK EDITOR ALIGNMENTS
   ================================================================ */
.alignwide { max-width: var(--wide-width); margin-left: auto; margin-right: auto; }
.alignfull { width: 100vw; max-width: 100vw; margin-left: calc(-50vw + 50%); }
.wp-block-image.alignfull img, .wp-block-cover.alignfull { border-radius: 0; }

.wp-block-button__link { background: var(--text); color: var(--white); border-radius: var(--radius-sm); padding: 0.65rem 1.5rem; font-family: var(--font); font-weight: 700; transition: background 0.15s; }
.wp-block-button__link:hover { background: var(--active-color); color: var(--white); }

.wp-block-quote { border-left: 4px solid var(--active-color); padding: 0.75rem 1.25rem; background: var(--surface-hover); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.wp-block-separator { border: none; border-top: 2px solid var(--border); }

.wp-block-table table { border-collapse: collapse; width: 100%; }
.wp-block-table td, .wp-block-table th { border: 1px solid var(--border); padding: 0.55rem 0.75rem; text-align: left; }
.wp-block-table th { background: var(--surface-hover); font-weight: 700; }

/* ================================================================
   RESPONSIVE: TABLET (<=900px)
   ================================================================ */
@media (max-width: 900px) {
  .header-inner,
  .header-inner.nav-left { grid-template-columns: 1fr 1fr; }
  .header-nav-zone { display: none; }
  .mobile-toggle { display: flex; }
  .header-logo-zone { gap: 0.4rem; }
  .header-inner.nav-left .header-nav-zone { margin-left: 0; }

  .mobile-nav-panel.open { display: block; }

  .mnav-item { border-bottom: 1px solid var(--border); }
  .mnav-item:last-child { border-bottom: none; }
  .mnav-row { display: flex; align-items: center; }

  .mnav-row .mnav-link {
    flex: 1; display: block; padding: 0.6rem 0.5rem;
    font-size: 0.95rem; font-weight: 600; color: var(--text-soft);
    text-decoration: none; border-radius: var(--radius-sm);
    transition: background 0.1s, color 0.1s;
  }

  .mnav-row .mnav-link:hover, .mnav-row .mnav-link:focus-visible { background: var(--surface-hover); color: var(--text); }

  .mnav-row .mnav-link.active { color: var(--text); position: relative; padding-left: 1rem; }
  .mnav-row .mnav-link.active::before {
    content: ''; position: absolute; left: 0; top: 0.45rem; bottom: 0.45rem;
    width: 3px; border-radius: 3px; background: var(--active-color);
  }

  .mnav-expand {
    width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
    background: none; border: none; color: var(--text-soft); cursor: pointer;
    border-radius: var(--radius-sm); flex-shrink: 0; transition: background 0.1s, color 0.1s;
  }

  .mnav-expand:hover, .mnav-expand:focus-visible { background: var(--surface-hover); color: var(--text); }
  .mnav-expand svg { width: 14px; height: 14px; transition: transform 0.2s; }
  .mnav-item.expanded .mnav-expand svg { transform: rotate(180deg); }

  .msub { display: none; padding-left: 1rem; padding-bottom: 0.35rem; }
  .mnav-item.expanded .msub { display: block; }

  .msub a {
    display: block; padding: 0.4rem 0.5rem; font-size: 0.88rem; font-weight: 500;
    color: var(--text-soft); text-decoration: none; border-radius: var(--radius-sm); transition: background 0.1s;
  }
  .msub a:hover { background: var(--surface-hover); }

  .content-wrap { grid-template-columns: 1fr; }
  .sidebar { position: static; }
}

/* ================================================================
   RESPONSIVE: MOBILE (<=550px)
   ================================================================ */
@media (max-width: 550px) {
  :root { --page-pad: 1rem; }
  .logo-icon { width: 44px; height: 44px; }
  .logo-icon svg { width: 26px; height: 26px; }
  .logo-words .site { font-size: 1.25rem; }
  .logo-words .site:first-child { font-size: 1.3rem; }
  .logo-words .org { font-size: 0.78rem; }
  .user-btn .uname { display: none; }
  .user-dropdown .dd-name { display: block; }
  .entry-title { font-size: 1.25rem; }
}
