/*
Theme Name: KingBygone
Theme URI: https://kingbygone.com
Author: King Bygone
Author URI: https://kingbygone.com
Description: A modern entertainment and celebrity news theme for KingBygone.com
Version: 1.3.7
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: kingbygone
Tags: news, entertainment, magazine, custom-logo, featured-images, threaded-comments, full-width-template
*/

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --orange: #FF6B2B;
  --orange-dark: #e05a20;
  --bg: #F5F5F5;
  --white: #ffffff;
  --dark: #1A1A1A;
  --mid: #555;
  --light: #888;
  --border: #E8E8E8;
}
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; background: var(--bg); color: var(--dark); }

/* ── HEADER ── */
header { background: var(--white); border-bottom: 3px solid var(--orange); position: sticky; top: 0; z-index: 200; box-shadow: 0 2px 10px rgba(0,0,0,.07); }
.header-inner { max-width: 1200px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; gap: 28px; height: 64px; }

/* Logo — text fallback AND custom logo image */
.logo,
a.custom-logo-link { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.logo-icon { width: 38px; height: 38px; background: var(--orange); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 900; font-size: 18px; flex-shrink: 0; }
.logo-text { font-size: 20px; font-weight: 900; color: var(--dark); letter-spacing: -0.5px; }
.logo-text span { color: var(--orange); }
a.custom-logo-link img,
.logo-custom-img { height: 40px; width: auto; display: block; }

/* Nav — must target ul/li/a because wp_nav_menu outputs nav > ul > li > a */
header nav { flex: 1; min-width: 0; }
header nav ul { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; flex-wrap: nowrap; }
header nav ul li { list-style: none; }
header nav ul li a { font-size: 12px; font-weight: 700; color: var(--dark); text-decoration: none; padding: 6px 13px; text-transform: uppercase; letter-spacing: .06em; border-radius: 4px; transition: color .15s; white-space: nowrap; display: block; }
header nav ul li a:hover,
header nav ul .current-menu-item > a,
header nav ul .current-menu-ancestor > a { color: var(--orange); }

/* Header right */
.header-right { display: flex; align-items: center; gap: 14px; margin-left: auto; flex-shrink: 0; }
.header-icons { display: flex; align-items: center; gap: 14px; }
.header-icons a,
.header-icons button { background: none; border: none; color: var(--mid); cursor: pointer; display: flex; align-items: center; padding: 0; transition: color .15s; text-decoration: none; }
.header-icons a:hover,
.header-icons button:hover { color: var(--orange); }
.header-icons svg { width: 19px; height: 19px; }
.header-subscribe { background: var(--orange); color: #fff; border: none; padding: 7px 18px; border-radius: 20px; font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; cursor: pointer; white-space: nowrap; text-decoration: none; transition: background .15s; display: inline-block; }
.header-subscribe:hover { background: var(--orange-dark); }
.nav-menu-toggle { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-menu-toggle span { display: block; width: 22px; height: 2px; background: var(--dark); margin: 5px 0; border-radius: 2px; transition: transform .2s, opacity .2s; }

/* ── LAYOUT ── */
.main-wrap { max-width: 1200px; margin: 30px auto; padding: 0 24px; display: grid; grid-template-columns: 1fr 300px; gap: 30px; align-items: start; }

/* ── HERO CARD ── */
.hero-card { position: relative; border-radius: 10px; overflow: visible; }
.hero-img { width: 100%; height: 400px; object-fit: cover; display: block; border-radius: 10px; }
.hero-img-placeholder { width: 100%; height: 400px; border-radius: 10px; background: linear-gradient(135deg, #1a0a2e 0%, #2d1b4e 40%, #1a2a3e 100%); display: block; }
.hero-body { position: relative; z-index: 1; background: var(--white); margin: 0 16px; margin-top: -36px; border-radius: 10px; padding: 28px 26px 28px; box-shadow: 0 4px 20px rgba(0,0,0,.10); }
.badge { display: inline-block; background: var(--orange); color: #fff; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; padding: 4px 12px; border-radius: 20px; margin-bottom: 14px; text-decoration: none; }
.hero-body h1 { color: var(--dark); font-size: 26px; font-weight: 800; line-height: 1.28; margin-bottom: 12px; }
.hero-body h1 a { color: inherit; text-decoration: none; }
.hero-body h1 a:hover { color: var(--orange); }
.hero-meta { display: flex; align-items: center; gap: 12px; color: var(--light); font-size: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.hero-meta .author { color: var(--orange); font-weight: 600; text-decoration: none; }
.hero-excerpt { color: var(--mid); font-size: 14px; line-height: 1.7; margin-bottom: 18px; }
.hero-actions { display: flex; align-items: center; justify-content: flex-end; }
.share-icons { display: flex; gap: 10px; }
.share-icons a { color: var(--mid); font-size: 13px; text-decoration: none; width: 30px; height: 30px; border: 1px solid var(--border); border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: all .15s; }
.share-icons a:hover { background: var(--orange); border-color: var(--orange); color: #fff; }

/* ── SIDEBAR ── */
.sidebar { display: flex; flex-direction: column; gap: 24px; position: sticky; top: 80px; align-self: start; }
.sidebar-widget { background: var(--white); border-radius: 10px; padding: 20px; box-shadow: 0 1px 4px rgba(0,0,0,.06); }
.widget-title { font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--dark); padding-bottom: 12px; border-bottom: 2px solid var(--orange); margin-bottom: 16px; }
.popular-item { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--border); }
.popular-item:last-child { border-bottom: none; padding-bottom: 0; }
.popular-thumb { width: 70px; height: 70px; border-radius: 6px; flex-shrink: 0; object-fit: cover; background: linear-gradient(135deg, #ddd, #ccc); display: block; }
.popular-text .badge { font-size: 9px; padding: 2px 8px; margin-bottom: 5px; display: inline-block; }
.popular-text h4 { font-size: 13px; font-weight: 700; line-height: 1.35; color: var(--dark); margin-bottom: 4px; }
.popular-text h4 a { color: inherit; text-decoration: none; }
.popular-text h4 a:hover { color: var(--orange); }
.popular-text .date { color: var(--light); font-size: 11px; }

/* ── POST GRID ── */
.section { max-width: 1200px; margin: 0 auto 36px; padding: 0 24px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.section-title { font-size: 14px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; display: flex; align-items: center; gap: 10px; }
.section-title::before { content: ''; display: block; width: 4px; height: 20px; background: var(--orange); border-radius: 2px; }
.see-all { color: var(--orange); font-size: 12px; font-weight: 700; text-decoration: none; text-transform: uppercase; letter-spacing: .06em; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }

/* ── POST CARD ── */
.post-card { position: relative; border-radius: 10px; overflow: visible; transition: transform .2s; }
.post-card:hover { transform: translateY(-3px); }
.post-card:hover .content { box-shadow: 0 8px 24px rgba(0,0,0,.13); }
.post-card .img-wrap { position: relative; overflow: hidden; border-radius: 10px; }
.post-card .img-wrap img { width: 100%; height: 220px; object-fit: cover; display: block; }
.post-card .img-wrap .img-placeholder { width: 100%; height: 220px; background: linear-gradient(135deg, #1a0a2e, #2d1b4e); display: block; }
.post-card .img-wrap .badge { position: absolute; top: 14px; left: 14px; margin: 0; }
.post-card .content { position: relative; z-index: 1; background: var(--white); margin: 0 10px; margin-top: -26px; border-radius: 10px; padding: 20px 18px 18px; box-shadow: 0 4px 16px rgba(0,0,0,.09); }
.post-card .meta { display: flex; align-items: center; gap: 10px; color: var(--light); font-size: 11px; margin-bottom: 8px; flex-wrap: wrap; }
.post-card .meta .dot { width: 3px; height: 3px; background: var(--light); border-radius: 50%; flex-shrink: 0; }
.post-card h3 { font-size: 17px; font-weight: 800; line-height: 1.3; margin-bottom: 8px; color: var(--dark); }
.post-card h3 a { color: inherit; text-decoration: none; }
.post-card h3 a:hover { color: var(--orange); }
.post-card p { color: var(--mid); font-size: 13px; line-height: 1.6; margin-bottom: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.post-card .card-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 12px; border-top: 1px solid var(--border); }
.post-card .card-footer .read-link { color: var(--orange); font-size: 12px; font-weight: 700; text-decoration: none; text-transform: uppercase; letter-spacing: .05em; }
.post-card .card-footer .share { display: flex; gap: 8px; }
.post-card .card-footer .share a { color: var(--light); font-size: 12px; text-decoration: none; transition: color .15s; }
.post-card .card-footer .share a:hover { color: var(--orange); }

/* ── PAGINATION ── */
.pagination { display: flex; gap: 8px; align-items: center; margin: 28px 0 10px; flex-wrap: wrap; }
.pagination a,
.pagination span { width: 38px; height: 38px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; text-decoration: none; background: var(--white); color: var(--dark); box-shadow: 0 1px 4px rgba(0,0,0,.08); transition: all .15s; }
.pagination .current,
.pagination a:hover { background: var(--orange); color: #fff; }
.pagination .dots { background: transparent; box-shadow: none; }

/* ── LOAD MORE ── */
.load-more-wrap { text-align: center; margin: 32px 0 10px; }
.load-more-btn { cursor: pointer; }
.load-more-btn:disabled { opacity: .6; cursor: wait; }

/* ── READING PROGRESS BAR ── */
#reading-progress { position: fixed; top: 0; left: 0; width: 0%; height: 3px; background: var(--orange); z-index: 9999; transition: width .1s linear; }

/* ── BREADCRUMB ── */
.breadcrumb { font-size: 12px; color: var(--light); margin-bottom: 20px; display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.breadcrumb a { color: var(--light); text-decoration: none; transition: color .15s; }
.breadcrumb a:hover { color: var(--orange); }
.breadcrumb .bc-sep { color: var(--border); }
.breadcrumb span:last-child { color: var(--dark); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }

/* ── CATEGORY BADGE COLORS ── */
.badge-celebrity    { background: #8B5CF6; }
.badge-gist         { background: #10B981; }
.badge-gossip       { background: #10B981; }
.badge-fashion      { background: #EC4899; }
.badge-movies-tv    { background: #3B82F6; }
.badge-movies       { background: #3B82F6; }
.badge-culture      { background: #F59E0B; }
.badge-entertainment { background: #EF4444; }
.badge-lyrics       { background: #6366F1; }
.badge-featured     { background: var(--orange); }

/* ── NEWSLETTER ── */
.newsletter-wrap { position: relative; margin-top: 50px; }
.scallop { display: block; width: 100%; height: 40px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 40'%3E%3Cpath d='M0 40 Q30 0 60 20 Q90 40 120 20 Q150 0 180 20 Q210 40 240 20 Q270 0 300 20 Q330 40 360 20 Q390 0 420 20 Q450 40 480 20 Q510 0 540 20 Q570 40 600 20 Q630 0 660 20 Q690 40 720 20 Q750 0 780 20 Q810 40 840 20 Q870 0 900 20 Q930 40 960 20 Q990 0 1020 20 Q1050 40 1080 20 Q1110 0 1140 20 Q1170 40 1200 20 L1200 0 L0 0Z' fill='%23F5F5F5'/%3E%3C/svg%3E") no-repeat center/cover; }
.newsletter { background: var(--white); padding: 50px 24px; text-align: center; }
.newsletter .icon { width: 60px; height: 60px; background: var(--orange); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 18px; }
.newsletter .icon svg { width: 26px; height: 26px; fill: #fff; }
.newsletter h2 { font-size: 26px; font-weight: 800; margin-bottom: 8px; }
.newsletter p { color: var(--mid); margin-bottom: 28px; font-size: 14px; }
.newsletter form { display: flex; flex-direction: column; gap: 12px; max-width: 420px; margin: 0 auto 20px; }
.newsletter input { padding: 13px 18px; border: 1px solid var(--border); border-radius: 6px; font-size: 14px; color: var(--dark); background: var(--bg); }
.newsletter input:focus { outline: none; border-color: var(--orange); }
.newsletter button { background: var(--orange); color: #fff; border: none; padding: 13px; border-radius: 6px; font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; cursor: pointer; transition: background .15s; }
.newsletter button:hover { background: var(--orange-dark); }
.newsletter .spam { color: var(--light); font-size: 12px; }
.social-icons { display: flex; gap: 16px; justify-content: center; margin-top: 30px; flex-wrap: wrap; }
.social-icons a { color: var(--mid); text-decoration: none; font-size: 13px; font-weight: 600; width: 38px; height: 38px; border: 1px solid var(--border); border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: all .15s; }
.social-icons a:hover { background: var(--orange); border-color: var(--orange); color: #fff; }

/* ── FOOTER ── */
footer { background: var(--white); border-top: 1px solid var(--border); padding: 16px 24px 20px; text-align: center; color: var(--light); font-size: 12px; }
.footer-nav { display: flex; justify-content: center; margin-bottom: 10px; }
.footer-nav-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 4px; }
.footer-nav-links li a { font-size: 12px; font-weight: 600; color: var(--mid); text-decoration: none; padding: 4px 10px; border-radius: 4px; text-transform: uppercase; letter-spacing: .04em; transition: color .15s; }
.footer-nav-links li a:hover,
.footer-nav-links .current-menu-item > a { color: var(--orange); }
.footer-copy a { color: var(--mid); text-decoration: none; }
.footer-copy a:hover { color: var(--orange); }

/* ── SINGLE POST ── */
.single-wrap { max-width: 1200px; margin: 30px auto; padding: 0 24px; display: grid; grid-template-columns: 1fr 300px; gap: 30px; align-items: start; }
.single-content { background: var(--white); border-radius: 10px; overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,.07); }
.single-hero { position: relative; }
.single-hero img { width: 100%; height: 420px; object-fit: cover; display: block; }
.single-hero .img-placeholder { width: 100%; height: 420px; background: linear-gradient(135deg, #2d1b4e, #1a0a2e, #1a2a3e); display: block; }
.single-hero .badge { position: absolute; top: 20px; left: 24px; }
.single-body { padding: 30px; }
.single-body h1 { font-family: 'Playfair Display', Georgia, serif; font-size: 32px; font-weight: 900; line-height: 1.2; margin-bottom: 14px; }
.breadcrumb { display: none; }
.single-meta { display: flex; align-items: center; gap: 16px; color: var(--light); font-size: 13px; padding-bottom: 20px; border-bottom: 1px solid var(--border); margin-bottom: 24px; flex-wrap: nowrap; overflow: hidden; }
.single-meta .author-name { color: var(--orange); font-weight: 700; text-decoration: none; }
.single-body .entry-content p { color: var(--mid); font-size: 15px; line-height: 1.8; margin-bottom: 18px; }
.single-body .entry-content h2 { font-size: 22px; font-weight: 800; margin: 28px 0 14px; }
.single-body .entry-content h3 { font-size: 18px; font-weight: 700; margin: 22px 0 12px; }
.single-body .entry-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 16px 0; }
/* Blockquote — Option 2: Dark card */
.single-body .entry-content blockquote,
.single-body .entry-content .wp-block-quote {
  background: #12001f !important;
  border: none !important;
  border-left: none !important;
  border-radius: 12px;
  padding: 58px 28px 26px !important;
  margin: 28px 0;
  position: relative;
  /* isolation creates a proper stacking context — fixes iOS Safari pseudo-element rendering */
  isolation: isolate;
  font-style: normal;
  color: #fff !important;
}
/* Orange gradient top bar */
.single-body .entry-content blockquote::before,
.single-body .entry-content .wp-block-quote::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--orange), #ff9900);
  border-radius: 12px 12px 0 0;
  z-index: 1;
}
/* Orange quote-mark icon badge */
.single-body .entry-content blockquote::after,
.single-body .entry-content .wp-block-quote::after {
  content: '\201C';
  position: absolute;
  top: 14px; left: 22px;
  width: 36px; height: 36px;
  background: var(--orange);
  border-radius: 8px;
  color: #fff;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 26px; font-weight: 900;
  line-height: 36px; text-align: center;
  z-index: 1;
}
.single-body .entry-content blockquote p,
.single-body .entry-content .wp-block-quote p {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 17px; font-weight: 700; font-style: italic;
  line-height: 1.65; color: #fff !important;
  margin-bottom: 14px;
}
.single-body .entry-content blockquote cite,
.single-body .entry-content .wp-block-quote cite {
  font-size: 11px; font-weight: 800; font-style: normal;
  color: var(--orange) !important; text-transform: uppercase; letter-spacing: .1em;
  display: block;
}
.single-body .entry-content blockquote cite span,
.single-body .entry-content .wp-block-quote cite span { color: rgba(255,255,255,.4); font-weight: 600; text-transform: none; letter-spacing: 0; }
.single-body .entry-content ul, .single-body .entry-content ol { padding-left: 24px; color: var(--mid); font-size: 15px; line-height: 1.8; margin-bottom: 18px; }
.single-body .entry-content a { color: var(--orange); }

/* Author box */
.author-box { background: var(--bg); border-radius: 10px; padding: 24px; display: flex; gap: 18px; align-items: flex-start; margin: 0 30px 30px; border: 1px dashed var(--border); }
.author-avatar { width: 72px; height: 72px; border-radius: 50%; background: linear-gradient(135deg, var(--orange), #ff9900); flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 24px; font-weight: 900; overflow: hidden; }
.author-avatar img { width: 72px; height: 72px; object-fit: cover; }
.author-info h4 { font-size: 16px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 5px; }
.author-info p { color: var(--mid); font-size: 13px; line-height: 1.6; margin-bottom: 10px; }
.author-socials { display: flex; gap: 8px; }
.author-socials a { width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; color: var(--mid); font-size: 12px; text-decoration: none; transition: all .15s; }
.author-socials a:hover { background: var(--orange); border-color: var(--orange); color: #fff; }

/* Related posts */
.related { padding: 0 30px 30px; }
.related-title { font-size: 14px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; display: flex; align-items: center; gap: 8px; margin-bottom: 18px; border-left: 4px solid var(--orange); padding-left: 10px; }
.related-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.related-card { display: flex; gap: 0; background: var(--bg); border-radius: 8px; overflow: hidden; text-decoration: none; transition: transform .15s; }
.related-card:hover { transform: translateY(-2px); }
.related-card .thumb { width: 100px; height: 90px; flex-shrink: 0; object-fit: cover; background: linear-gradient(135deg, #2d1b4e, #1a0a2e); display: block; }
.related-card .info { padding: 12px; }
.related-card .badge { font-size: 9px; padding: 2px 9px; margin-bottom: 6px; display: inline-block; }
.related-card h4 { font-size: 13px; font-weight: 700; line-height: 1.3; margin-bottom: 5px; color: var(--dark); }
.related-card .date { color: var(--light); font-size: 11px; }

/* ── ARCHIVE / INDEX ── */
.archive-wrap { max-width: 1200px; margin: 30px auto; padding: 0 24px; display: grid; grid-template-columns: 1fr 300px; gap: 30px; align-items: start; }
.archive-main {}
.archive-header { margin-bottom: 28px; }
.archive-header h1 { font-size: 24px; font-weight: 900; display: flex; align-items: center; gap: 10px; }
.archive-header h1::before { content: ''; display: block; width: 4px; height: 28px; background: var(--orange); border-radius: 2px; }
.archive-header p { color: var(--light); font-size: 13px; margin-top: 6px; }

/* ── 404 PAGE ── */
.not-found-wrap { max-width: 600px; margin: 80px auto; padding: 0 24px; text-align: center; }
.not-found-wrap .code { font-size: 120px; font-weight: 900; color: var(--orange); line-height: 1; }
.not-found-wrap h2 { font-size: 28px; font-weight: 800; margin-bottom: 12px; }
.not-found-wrap p { color: var(--mid); margin-bottom: 28px; }
.btn-primary { display: inline-block; background: var(--orange); color: #fff; padding: 12px 28px; border-radius: 6px; font-weight: 700; text-decoration: none; font-size: 14px; text-transform: uppercase; letter-spacing: .05em; transition: background .15s; }
.btn-primary:hover { background: var(--orange-dark); }


/* ── MOBILE BOTTOM TAB BAR (hidden on desktop) ── */
.mobile-tabbar { display: none; }
.mobile-cat-overlay { display: none; }

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  .main-wrap,
  .single-wrap,
  .archive-wrap { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .nav-menu-toggle { display: block; }
  .header-subscribe { display: none; }
  /* Keep header sticky on mobile — it IS a containing block for absolute children */
  header nav { display: none; position: absolute; top: 64px; left: 0; right: 0; background: var(--white); border-bottom: 3px solid var(--orange); box-shadow: 0 6px 16px rgba(0,0,0,.1); z-index: 199; }
  header nav.open { display: block; }
  header nav ul { flex-direction: column; gap: 0; padding: 12px 24px 20px; }
  header nav ul li a { padding: 11px 0; border-bottom: 1px solid var(--border); border-radius: 0; font-size: 13px; display: block; }
  header nav ul li:last-child > a { border-bottom: none; }
}
@media (max-width: 600px) {
  .grid-3,
  .grid-2 { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr; }
  .single-hero img, .single-hero .img-placeholder { height: 240px; }
  .single-body { padding: 20px; }
  .author-box { flex-direction: column; margin: 0 16px 24px; }
  .related { padding: 0 16px 24px; }

  /* Hero card: normal stacked layout on mobile (no text-over-image overlap) */
  .hero-card { overflow: hidden; }
  .hero-img, .hero-img-placeholder { height: 220px; border-radius: 0; }
  .hero-body { margin: 0; margin-top: 0; border-radius: 0; box-shadow: none; padding: 16px 14px; }
  .hero-body h1 { font-size: 18px; }

  /* Single post meta: compact single line */
  .single-meta { gap: 7px; font-size: 11px; }
  .single-meta .share-icons a { width: 26px; height: 26px; font-size: 11px; }

  /* Blockquote on mobile: normal font, no italic */
  .single-body .entry-content blockquote p,
  .single-body .entry-content .wp-block-quote p {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-style: normal;
    font-weight: 600;
    font-size: 15px;
  }
}

/* ── MOBILE BOTTOM TAB BAR (phones ≤ 640px) ── */
@media (max-width: 640px) {
  /* Push page content above the fixed tab bar */
  body { padding-bottom: 68px; }

  /* Hide hamburger — tab bar replaces it on phones */
  .nav-menu-toggle { display: none; }

  /* Tab bar */
  .mobile-tabbar {
    display: flex;
    position: fixed;
    bottom: 0; left: 0; right: 0;
    height: 60px;
    background: var(--white);
    border-top: 1px solid var(--border);
    box-shadow: 0 -3px 16px rgba(0,0,0,.09);
    z-index: 300;
    /* respect iPhone home-indicator safe area */
    padding-bottom: env(safe-area-inset-bottom, 0px);
  }
  .mobile-tab {
    flex: 1;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 3px;
    text-decoration: none;
    background: none; border: none; cursor: pointer;
    position: relative; padding: 8px 2px 6px;
    -webkit-tap-highlight-color: transparent;
  }
  .mobile-tab svg { width: 21px; height: 21px; color: #bbb; transition: color .15s; }
  .mobile-tab--news svg { width: 24px; height: 24px; }
  .mobile-tab span { font-size: 9px; font-weight: 700; color: #bbb; transition: color .15s; }
  .mobile-tab.is-active svg,
  .mobile-tab.is-active span { color: var(--orange); }
  .mobile-tab.is-active::after {
    content: '';
    position: absolute; top: 5px; left: 50%; transform: translateX(-50%);
    width: 18px; height: 2px;
    background: var(--orange); border-radius: 2px;
  }

  /* Category sheet overlay */
  .mobile-cat-overlay {
    position: fixed; inset: 0;
    display: flex; flex-direction: column; justify-content: flex-end;
    background: rgba(18,0,31,.78);
    backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
    z-index: 400;
    opacity: 0; pointer-events: none;
    transition: opacity .2s;
  }
  .mobile-cat-overlay.open { opacity: 1; pointer-events: auto; }

  .mobile-cat-sheet {
    background: var(--white);
    border-radius: 22px 22px 0 0;
    padding: 14px 14px 80px; width: 100%;
    transform: translateY(100%);
    transition: transform .26s cubic-bezier(.4,0,.2,1);
  }
  .mobile-cat-overlay.open .mobile-cat-sheet { transform: translateY(0); }

  .mobile-cat-handle {
    width: 40px; height: 4px;
    background: var(--border); border-radius: 2px;
    margin: 0 auto 16px;
  }
  .mobile-cat-title {
    font-size: 11px; font-weight: 800;
    color: var(--light); text-transform: uppercase;
    letter-spacing: .1em; margin-bottom: 14px;
  }
  .mobile-cat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  .mobile-cat-item {
    border-radius: 12px; padding: 12px 10px;
    display: flex; align-items: center; gap: 10px;
    text-decoration: none;
    transition: filter .12s;
  }
  .mobile-cat-item:active { filter: brightness(.94); }
  .mobile-cat-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
  .mobile-cat-item span:last-child {
    font-size: 12px; font-weight: 700; color: var(--dark);
  }
  .mobile-cat-item.is-active span:last-child { color: var(--orange); }
}
