/*
Theme Name:   Remove & Replace Child
Theme URI:    https://removeandreplace.com/
Description:  Child theme for Astra powering RemoveandReplace.com — a custom, fast, ad-friendly design for DIY appliance repair guides. Keeps Ezoic ad zones intact and all content editable from the WordPress dashboard.
Author:       Remove & Replace
Author URI:   https://removeandreplace.com/
Template:     astra
Version:      1.0.0
Text Domain:  rr-child
*/

/* =========================================================================
   DESIGN TOKENS
   ========================================================================= */
:root {
  --bg: #fafaf7;
  --bg-warm: #f4f0e6;
  --ink: #14181f;
  --ink-2: #3a414d;
  --ink-3: #6b7280;
  --ink-4: #9ca3af;
  --line: #e5e2d8;
  --line-2: #eae6da;
  --brand: #18406f;
  --brand-2: #102d52;
  --brand-soft: #e9f0f9;
  --accent: #4a8fd4;
  --accent-soft: #e6f0fb;
  --amber: #f5b042;
  --amber-2: #c27d0e;
  --card: #ffffff;
  --shadow-sm: 0 1px 2px rgba(20,24,31,0.04), 0 1px 3px rgba(20,24,31,0.06);
  --shadow-md: 0 4px 12px rgba(20,24,31,0.06), 0 2px 4px rgba(20,24,31,0.04);
  --shadow-lg: 0 20px 40px rgba(20,24,31,0.08), 0 8px 16px rgba(20,24,31,0.04);
  --radius: 14px;
  --wrap: 1280px;
}

/* =========================================================================
   RESET / BASE — scoped so Astra admin bar etc. are untouched
   ========================================================================= */
.rr * { box-sizing: border-box; }
body.rr-theme {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "ss01", "cv11";
  margin: 0;
}
.rr .serif { font-family: 'Instrument Serif', Georgia, serif; font-weight: 400; font-style: italic; }
.rr a { color: inherit; text-decoration: none; }
.rr button { font-family: inherit; cursor: pointer; border: none; background: none; }
.rr img { max-width: 100%; height: auto; }

/* Hide Astra's default header/footer/containers; we render our own */
.ast-above-header-wrap,
.site-header,
.ast-main-header-wrap,
#masthead,
.site-footer,
#colophon,
.ast-mobile-header-wrap { display: none !important; }
#page .site-content { padding: 0 !important; }
.ast-container, .site-content > .ast-container { max-width: none; padding: 0; margin: 0; }
#secondary, .widget-area { display: none !important; }
#primary, .ast-container .content-area, .ast-container #primary { width: 100% !important; max-width: 100% !important; float: none !important; margin: 0 !important; }
.ast-container .ast-row { display: block !important; }

/* =========================================================================
   TOP BAR
   ========================================================================= */
.rr-topbar { background: var(--ink); color: #e5e7eb; font-size: 12.5px; padding: 8px 0; }
.rr-topbar-inner { max-width: var(--wrap); margin: 0 auto; padding: 0 32px; display: flex; justify-content: space-between; align-items: center; }
.rr-topbar-inner span { opacity: 0.75; }
.rr-topbar-inner .live { display: inline-flex; align-items: center; gap: 6px; }
.rr-topbar-inner .live::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 3px rgba(34,197,94,0.25); }

/* =========================================================================
   HEADER
   ========================================================================= */
.rr-header { border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 100; backdrop-filter: blur(8px); background: rgba(250, 250, 247, 0.92); }
body.admin-bar .rr-header { top: 32px; }
.rr-header-inner { max-width: var(--wrap); margin: 0 auto; padding: 16px 32px; display: grid; grid-template-columns: auto 1fr auto; gap: 40px; align-items: center; }
.rr-logo { display: flex; align-items: center; gap: 12px; }
.rr-logo-text { display: flex; flex-direction: column; line-height: 1; }
.rr-logo-text .name { font-family: 'Inter', system-ui, -apple-system, sans-serif !important; font-size: 19px; font-weight: 800 !important; letter-spacing: -0.02em; color: var(--ink); }
.rr-logo-text .name .amp { color: var(--accent); }
.rr-logo-text .tag { font-size: 9px; letter-spacing: 0.18em; color: var(--ink-4); margin-top: 3px; font-weight: 600; text-transform: uppercase; }
.rr-nav { display: flex; gap: 28px; font-size: 14.5px; font-weight: 500; justify-content: center; list-style: none; margin: 0; padding: 0; }
.rr-nav li { list-style: none; }
.rr-nav a { color: var(--ink-2); transition: color 0.15s; }
.rr-nav a:hover { color: var(--ink); }
.rr-nav .current-menu-item > a { color: var(--ink); }
.rr-header-actions { display: flex; align-items: center; gap: 12px; }
.rr-header-actions .icon-btn { width: 38px; height: 38px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--ink-2); transition: background 0.15s; }
.rr-header-actions .icon-btn:hover { background: var(--bg-warm); }
.btn-ask { background: var(--ink); color: #fff !important; padding: 9px 18px; border-radius: 100px; font-size: 13.5px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; transition: transform 0.15s, background 0.15s; }
.btn-ask:hover { background: var(--ink-2); transform: translateY(-1px); }

/* =========================================================================
   HERO (front page)
   ========================================================================= */
.hero { padding: 80px 32px 60px; max-width: 1100px; margin: 0 auto; text-align: center; position: relative; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 100px; background: var(--brand-soft); color: var(--brand); font-size: 12.5px; font-weight: 600; margin-bottom: 28px; border: 1px solid rgba(44, 85, 196, 0.15); }
.hero-badge .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--brand); }
.hero h1 { font-size: 76px; font-weight: 800; letter-spacing: -0.04em; line-height: 0.98; margin: 0 0 20px; color: var(--ink); }
.hero h1 .serif { color: var(--accent); font-weight: 400; }
.hero-sub { font-size: 19px; color: var(--ink-3); margin: 0 auto 36px; max-width: 580px; line-height: 1.5; }
.hero::before, .hero::after { content: ''; position: absolute; border-radius: 50%; pointer-events: none; filter: blur(60px); }
.hero::before { width: 300px; height: 300px; background: radial-gradient(circle, rgba(44,85,196,0.12), transparent); top: 20px; left: 10%; }
.hero::after { width: 260px; height: 260px; background: radial-gradient(circle, rgba(245,176,66,0.1), transparent); top: 100px; right: 8%; }

/* SEARCH */
.search-wrap { max-width: 720px; margin: 0 auto; position: relative; }
.search { background: #fff; border-radius: 100px; padding: 8px 8px 8px 24px; display: flex; align-items: center; gap: 12px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); transition: box-shadow 0.2s, border-color 0.2s; }
.search:focus-within { border-color: var(--brand); box-shadow: 0 0 0 4px rgba(44,85,196,0.12), var(--shadow-lg); }
.search svg.search-icon { color: var(--ink-3); flex-shrink: 0; }
.search input { flex: 1; border: none; outline: none; font-family: inherit; font-size: 16px; padding: 10px 4px; background: transparent; color: var(--ink); }
.search input::placeholder { color: var(--ink-4); }
.search-btn { background: var(--brand); color: #fff; padding: 12px 22px; border-radius: 100px; font-size: 14.5px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; transition: background 0.15s, transform 0.15s; }
.search-btn:hover { background: var(--brand-2); transform: translateY(-1px); }
.search-hints { margin-top: 20px; display: flex; justify-content: center; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13.5px; color: var(--ink-3); }
.search-hints .label { color: var(--ink-4); font-size: 12px; font-weight: 500; margin-right: 4px; }
.hint-chip { padding: 5px 12px; border-radius: 100px; background: #fff; border: 1px solid var(--line); font-size: 12.5px; color: var(--ink-2); font-weight: 500; transition: all 0.15s; cursor: pointer; }
.hint-chip:hover { border-color: var(--brand); color: var(--brand); background: var(--brand-soft); }

/* STATS */
.stats { max-width: 1100px; margin: 40px auto 0; padding: 0 32px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; background: var(--line); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.stat { background: #fff; padding: 22px 20px; text-align: center; }
.stat .num { font-size: 28px; font-weight: 800; letter-spacing: -0.03em; color: var(--ink); line-height: 1; }
.stat .num .serif { color: var(--accent); }
.stat .lbl { font-size: 12px; color: var(--ink-3); font-weight: 500; margin-top: 6px; letter-spacing: 0.02em; }

/* =========================================================================
   SECTIONS
   ========================================================================= */
section.slab { max-width: var(--wrap); margin: 0 auto; padding: 80px 32px 20px; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 36px; gap: 30px; }
.section-head h2 { font-size: 42px; font-weight: 800; letter-spacing: -0.03em; margin: 0; line-height: 1; }
.section-head h2 .serif { color: var(--accent); }
.section-head p { color: var(--ink-3); font-size: 15px; margin: 10px 0 0; max-width: 420px; }
.section-head .view-all { color: var(--ink); font-size: 14px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; padding: 10px 16px; border-radius: 100px; border: 1px solid var(--line); background: #fff; transition: all 0.15s; flex-shrink: 0; }
.section-head .view-all:hover { border-color: var(--ink); transform: translateX(2px); }

/* CATEGORY GRID */
.cats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.cat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 0 0 18px; text-align: left; transition: all 0.2s; cursor: pointer; position: relative; overflow: hidden; display: block; }
.cat::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--brand); transform: scaleX(0); transform-origin: left; transition: transform 0.3s; }
.cat:hover { border-color: var(--ink); transform: translateY(-3px); box-shadow: var(--shadow-md); }
.cat:hover::before { transform: scaleX(1); }
.cat-photo { width: 100%; height: 88px; display: flex; align-items: center; justify-content: center; }
.cat.featured .cat-photo { height: 130px; }
.cat-body { padding: 14px 16px 0; }
.cat .cat-icon { width: 40px; height: 40px; display: flex; align-items: center; justify-content: center; background: var(--bg-warm); border-radius: 10px; margin-bottom: 12px; color: var(--ink-2); position: relative; z-index: 1; margin-top: -34px; border: 3px solid #fff; margin-left: 16px; }
.cat .cat-name { font-size: 14.5px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 3px; }
.cat .cat-meta { font-size: 12px; color: var(--ink-4); font-weight: 500; }
.cat.featured { grid-column: span 2; background: var(--ink); color: #fff; border-color: var(--ink); padding: 0 0 22px; display: flex; flex-direction: column; justify-content: flex-start; min-height: 160px; }
.cat.featured .cat-body { padding: 0 22px; }
.cat.featured .cat-icon { background: rgba(245,176,66,0.18); color: var(--amber); width: 48px; height: 48px; margin-top: -30px; border: 3px solid var(--ink); margin-left: 22px; }
.cat.featured .cat-name { font-size: 22px; margin-top: 14px; }
.cat.featured .cat-meta { color: rgba(255,255,255,0.55); font-size: 13px; }
.cat.featured::before { display: none; }
.cat.featured:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.cat .badge-top { font-size: 10px; letter-spacing: 0.12em; color: var(--amber); font-weight: 700; text-transform: uppercase; margin-bottom: 6px; }
.cat .cat-photo svg { transition: transform 0.35s ease; }
.cat:hover .cat-photo svg { transform: scale(1.08); }
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

/* FEATURE GRID (latest + ask) */
.feature-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 24px; margin-top: 80px; }
.guides { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.guide-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; display: flex; gap: 14px; cursor: pointer; transition: all 0.15s; }
.guide-card:hover { border-color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.guide-thumb { width: 72px; height: 72px; border-radius: 10px; background: var(--bg-warm); flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: var(--ink-3); font-size: 24px; background-image: repeating-linear-gradient(45deg, transparent 0 6px, rgba(20,24,31,0.04) 6px 7px); overflow: hidden; }
.guide-thumb img { width: 100%; height: 100%; object-fit: cover; }
.guide-card .guide-meta { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--brand); font-weight: 700; }
.guide-card h3 { font-size: 15px; font-weight: 700; letter-spacing: -0.01em; margin: 4px 0 6px; line-height: 1.25; }
.guide-card .guide-sub { font-size: 12px; color: var(--ink-4); display: flex; gap: 8px; align-items: center; }
.guide-card .guide-sub .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--ink-4); }

/* ASK PANEL */
.ask-panel { background: var(--ink); color: #fff; border-radius: var(--radius); padding: 32px 28px; position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; }
.ask-panel::before { content: ''; position: absolute; top: -60px; right: -60px; width: 200px; height: 200px; background: radial-gradient(circle, rgba(245,176,66,0.25), transparent 70%); }
.ask-tools { width: 56px; height: 56px; background: rgba(245,176,66,0.15); border-radius: 14px; display: flex; align-items: center; justify-content: center; margin-bottom: 20px; color: var(--amber); position: relative; }
.ask-panel h3 { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.05; margin: 0 0 12px; position: relative; }
.ask-panel h3 .serif { color: var(--amber); font-weight: 400; }
.ask-panel p { font-size: 14px; color: rgba(255,255,255,0.65); line-height: 1.55; margin: 0 0 24px; position: relative; }
.ask-panel .ask-btn { background: var(--amber); color: var(--ink); padding: 14px 22px; border-radius: 100px; font-weight: 700; font-size: 14.5px; display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; transition: transform 0.15s; position: relative; }
.ask-panel .ask-btn:hover { transform: translateX(2px); }
.ask-panel .meta { margin-top: 18px; font-size: 12px; color: rgba(255,255,255,0.5); display: flex; gap: 14px; position: relative; }
.ask-panel .meta span::before { content: '✓'; color: var(--amber); margin-right: 6px; }

/* WIDE / RECENT */
.wide-section { background: var(--bg-warm); padding: 80px 0; margin-top: 80px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.wide-inner { max-width: var(--wrap); margin: 0 auto; padding: 0 32px; }
.recent-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.recent-card { background: #fff; border-radius: var(--radius); overflow: hidden; cursor: pointer; transition: all 0.2s; border: 1px solid var(--line); }
.recent-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.recent-hero { aspect-ratio: 16/10; background: var(--bg-warm); position: relative; display: flex; align-items: center; justify-content: center; color: var(--ink-4); background-image: radial-gradient(circle at 30% 40%, rgba(44,85,196,0.08), transparent 50%), radial-gradient(circle at 70% 60%, rgba(245,176,66,0.08), transparent 50%); overflow: hidden; }
.recent-hero img { width: 100%; height: 100%; object-fit: cover; }
.recent-hero .ph-icon { font-size: 60px; opacity: 0.3; }
.recent-hero .rec-tag { position: absolute; top: 14px; left: 14px; padding: 5px 11px; background: #fff; border-radius: 100px; font-size: 11px; letter-spacing: 0.1em; color: var(--brand); font-weight: 700; text-transform: uppercase; z-index: 2; }
.recent-body { padding: 20px 22px 22px; }
.recent-body h3 { font-size: 18px; font-weight: 700; letter-spacing: -0.015em; margin: 0 0 8px; line-height: 1.25; }
.recent-body p { font-size: 13.5px; color: var(--ink-3); margin: 0 0 16px; line-height: 1.5; }
.recent-body .meta { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--ink-4); }
.recent-body .read { color: var(--ink); font-weight: 600; display: inline-flex; align-items: center; gap: 4px; }

/* BRANDS */
.brands { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.brand-chip { padding: 11px 22px; background: #fff; border: 1px solid var(--line); border-radius: 100px; font-size: 14px; font-weight: 600; color: var(--ink-2); cursor: pointer; transition: all 0.15s; }
.brand-chip:hover { border-color: var(--ink); color: var(--ink); transform: translateY(-2px); }

/* TRUST */
.trust { max-width: var(--wrap); margin: 80px auto 0; padding: 0 32px; display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center; }
.trust-copy h2 { font-size: 48px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.02; margin: 0 0 18px; }
.trust-copy h2 .serif { color: var(--accent); }
.trust-copy p { font-size: 16px; color: var(--ink-3); line-height: 1.55; margin: 0 0 24px; }
.trust-points { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 24px; }
.trust-pt { display: flex; gap: 12px; align-items: flex-start; }
.trust-pt .pt-icon { width: 32px; height: 32px; background: var(--brand-soft); color: var(--brand); border-radius: 8px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.trust-pt strong { font-size: 14px; font-weight: 700; display: block; margin-bottom: 2px; }
.trust-pt span { font-size: 13px; color: var(--ink-3); line-height: 1.4; }
.tech-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow-md); position: relative; }
.tech-avatar { width: 56px; height: 56px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand-2)); display: flex; align-items: center; justify-content: center; font-size: 22px; color: #fff; font-weight: 700; margin-bottom: 16px; }
.tech-quote { font-size: 18px; line-height: 1.4; letter-spacing: -0.01em; font-weight: 500; margin: 0 0 16px; }
.tech-name { font-size: 13px; color: var(--ink-3); font-weight: 600; }
.tech-name b { color: var(--ink); display: block; font-weight: 700; font-size: 14px; }

/* =========================================================================
   ARTICLE (single)
   ========================================================================= */
body.single .rr a { color: var(--brand); }
.crumb { max-width: var(--wrap); margin: 0 auto; padding: 20px 32px 0; font-size: 13px; color: var(--ink-3); }
.crumb a { color: var(--ink-3); }
.crumb a:hover { color: var(--ink); }
.crumb .sep { margin: 0 8px; opacity: 0.5; }
.crumb .current { color: var(--ink); font-weight: 600; }

.article-head { max-width: 820px; margin: 0 auto; padding: 32px 32px 40px; }
.article-head .cat-tag { display: inline-block; padding: 6px 14px; background: var(--brand-soft); color: var(--brand); border-radius: 100px; font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 20px; }
.article-head h1 { font-size: 56px; font-weight: 800; letter-spacing: -0.035em; line-height: 1.02; margin: 0 0 20px; }
.article-head h1 .serif { color: var(--accent); font-weight: 400; }
.article-head .dek { font-size: 20px; color: var(--ink-3); line-height: 1.45; margin: 0 0 28px; }
.byline { display: flex; align-items: center; gap: 14px; padding: 16px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.byline .av { width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 15px; overflow: hidden; }
.byline .av img { width: 100%; height: 100%; object-fit: cover; }
.byline .meta { flex: 1; font-size: 13px; color: var(--ink-3); }
.byline .meta b { color: var(--ink); display: block; font-size: 14px; font-weight: 700; }
.byline .actions { display: flex; gap: 8px; }
.byline .actions button { width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 50%; color: var(--ink-3); display: flex; align-items: center; justify-content: center; background: #fff; }
.byline .actions button:hover { border-color: var(--ink); color: var(--ink); }
.byline .actions button#rr-bookmark.active { background: var(--brand-soft); border-color: var(--brand); color: var(--brand); }
.rr-toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(20px); background: var(--ink); color: #fff; font-size: 13.5px; font-weight: 600; padding: 11px 20px; border-radius: 100px; box-shadow: var(--shadow-lg); opacity: 0; pointer-events: none; transition: opacity 0.2s, transform 0.2s; z-index: 999; }
.rr-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.search-pop-wrap { position: relative; }
.search-pop { position: absolute; top: calc(100% + 10px); right: 0; background: #fff; border: 1px solid var(--line); border-radius: 100px; box-shadow: var(--shadow-lg); padding: 6px 6px 6px 18px; display: flex; align-items: center; gap: 8px; width: 300px; max-width: calc(100vw - 32px); opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity 0.18s, transform 0.18s, visibility 0.18s; z-index: 120; }
.search-pop.open { opacity: 1; visibility: visible; transform: translateY(0); }
.search-pop input { flex: 1; border: none; outline: none; font-size: 14px; font-family: inherit; color: var(--ink); background: transparent; }
.search-pop button { width: 34px; height: 34px; border-radius: 50%; background: var(--ink); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.search-pop button:hover { background: var(--ink-2); }
.search-float { position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg); max-height: 0; overflow: hidden; opacity: 0; transition: max-height 0.25s ease, opacity 0.2s; z-index: 90; }
.search-float.open { max-height: 90px; opacity: 1; }
.search-float form { max-width: var(--wrap); margin: 0 auto; padding: 18px 32px; display: flex; align-items: center; gap: 12px; }
.search-float svg.s-icon { color: var(--ink-4); flex-shrink: 0; }
.search-float input { flex: 1; border: none; outline: none; font-size: 16px; font-family: inherit; color: var(--ink); background: transparent; }
.search-float button { width: 40px; height: 40px; border-radius: 50%; background: var(--ink); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.search-float button:hover { background: var(--ink-2); }

/* =========================================================================
   CATEGORY ARCHIVE
   ========================================================================= */
.cat-hero { max-width: var(--wrap); margin: 0 auto; padding: 56px 32px 40px; text-align: center; border-bottom: 1px solid var(--line); }
.cat-hero-icon { width: 64px; height: 64px; border-radius: 16px; background: var(--bg-warm); color: var(--brand); display: flex; align-items: center; justify-content: center; margin: 0 auto 20px; }
.cat-hero h1 { font-size: 42px; letter-spacing: -0.02em; margin: 0 0 14px; }
.cat-hero h1 .serif { color: var(--brand); font-weight: 400; }
.cat-hero-sub { font-size: 17px; color: var(--ink-3); max-width: 620px; margin: 0 auto 16px; line-height: 1.5; }
.cat-hero-meta { display: inline-block; font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; font-weight: 700; color: var(--ink-4); background: var(--bg-warm); padding: 7px 16px; border-radius: 100px; }
.cat-ask-panel { max-width: var(--wrap); margin: 56px auto 0; background: var(--ink); color: #fff; border-radius: var(--radius); padding: 32px; display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.cat-ask-panel .ask-tools { width: 52px; height: 52px; border-radius: 14px; background: rgba(245,176,66,0.16); color: var(--amber); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.cat-ask-panel h3 { font-size: 21px; margin: 0 0 6px; }
.cat-ask-panel h3 .serif { color: var(--amber); font-weight: 400; }
.cat-ask-panel p { color: rgba(255,255,255,0.65); font-size: 14.5px; margin: 0; }
.cat-ask-panel .ask-btn { margin-left: auto; background: #fff; color: var(--ink); padding: 13px 22px; border-radius: 100px; font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; transition: background 0.15s; }
.cat-ask-panel .ask-btn:hover { background: var(--bg-warm); }
@media (max-width: 700px) {
  .cat-hero { padding: 40px 20px 32px; }
  .cat-hero h1 { font-size: 30px; }
  .cat-ask-panel { padding: 24px 20px; }
  .cat-ask-panel .ask-btn { margin-left: 0; width: 100%; justify-content: center; }
}
@media (max-width: 600px) {
  .byline { flex-wrap: wrap; }
  .byline .actions { order: 3; width: 100%; justify-content: flex-start; margin-top: 4px; }
  .read-time { display: block; margin-top: 2px; }
}

.hero-img { max-width: 1080px; margin: 0 auto 48px; padding: 0 32px; }
.hero-img .ph { aspect-ratio: 21/9; background: var(--bg-warm); border-radius: var(--radius); background-image: radial-gradient(circle at 30% 40%, rgba(44,85,196,0.08), transparent 55%), radial-gradient(circle at 70% 60%, rgba(245,176,66,0.09), transparent 55%); display: flex; align-items: center; justify-content: center; color: var(--ink-4); overflow: hidden; }
.hero-img img { width: 100%; border-radius: var(--radius); display: block; }

.body-grid { max-width: 1180px; margin: 0 auto; padding: 0 32px; display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 60px; align-items: flex-start; }
.rr article.post-body { max-width: 720px; justify-self: center; width: 100%; }
.rr article.post-body a { color: var(--brand); font-weight: 700; text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 2px; }
.rr article.post-body a:hover { color: var(--accent); }
.rr article.post-body p { font-size: 17px; line-height: 1.7; color: var(--ink-2); margin: 0 0 20px; }
.rr article.post-body > p:first-of-type, .rr article.post-body p.lead { font-size: 20px; color: var(--ink); font-weight: 500; margin-bottom: 28px; }
.rr article.post-body h2 { font-size: 32px; font-weight: 800; letter-spacing: -0.025em; margin: 48px 0 16px; line-height: 1.1; }
.rr article.post-body h2 .serif { color: var(--accent); font-weight: 400; }
.rr article.post-body h3 { font-size: 22px; font-weight: 700; letter-spacing: -0.015em; margin: 32px 0 12px; }
.rr article.post-body ul, .rr article.post-body ol { padding-left: 22px; margin: 0 0 20px; }
.rr article.post-body li { font-size: 17px; line-height: 1.65; color: var(--ink-2); margin-bottom: 8px; }
.rr article.post-body blockquote { border-left: 3px solid var(--brand); padding: 4px 0 4px 20px; margin: 28px 0; font-family: 'Instrument Serif', Georgia, serif; font-size: 22px; line-height: 1.4; color: var(--ink); font-style: italic; }
.rr article.post-body img { border-radius: var(--radius); margin: 32px 0; }
.rr article.post-body .wp-caption-text, .rr article.post-body figcaption { font-size: 13px; color: var(--ink-3); text-align: center; margin: -20px 0 28px; font-style: italic; }

/* STEP CARDS (re-usable block / shortcode) */
.step { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 26px; margin: 24px 0; position: relative; }
.step::before { content: ''; position: absolute; left: 0; top: 24px; bottom: 24px; width: 3px; background: var(--brand); border-radius: 3px; }
.step .step-num { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--brand); font-weight: 700; margin-bottom: 6px; }
.step h3 { margin: 0 0 10px !important; font-size: 22px; }
.step p:last-child { margin-bottom: 0; }
.step .difficulty { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--ink-3); font-weight: 600; margin-top: 10px; }
.step .difficulty .dots { display: inline-flex; gap: 3px; }
.step .difficulty .dots span { width: 6px; height: 6px; border-radius: 50%; background: var(--line); }
.step .difficulty .dots span.on { background: var(--amber); }

/* INLINE ASK CTA */
.inline-ask { background: var(--ink); color: #fff; border-radius: var(--radius); padding: 28px; display: flex; gap: 22px; align-items: center; margin: 40px 0; position: relative; overflow: hidden; }
.inline-ask::before { content: ''; position: absolute; top: -40px; right: -40px; width: 160px; height: 160px; background: radial-gradient(circle, rgba(245,176,66,0.2), transparent 70%); }
.inline-ask .icon { width: 52px; height: 52px; background: rgba(245,176,66,0.15); border-radius: 12px; display: flex; align-items: center; justify-content: center; color: var(--amber); flex-shrink: 0; position: relative; }
.inline-ask h4 { font-size: 20px; margin: 0 0 4px; font-weight: 800; letter-spacing: -0.02em; position: relative; color: #fff !important; }
.inline-ask h4 .serif { color: var(--amber); font-weight: 400; }
.inline-ask p { font-size: 13.5px; color: rgba(255,255,255,0.65); margin: 0; position: relative; }
.inline-ask .btn { background: var(--amber); color: var(--ink) !important; padding: 12px 20px; border-radius: 100px; font-weight: 700; font-size: 13.5px; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; position: relative; margin-left: auto; transition: transform 0.15s; }
.inline-ask .btn:hover { transform: translateX(2px); }

/* EZOIC AD ZONES */
.ad-zone { background: var(--bg-warm); border: 1px dashed var(--line); border-radius: 12px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: var(--ink-4); gap: 6px; background-image: repeating-linear-gradient(45deg, transparent 0 10px, rgba(20,24,31,0.018) 10px 11px); }
.ad-zone .ad-label { font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; font-weight: 700; color: var(--ink-4); }
.ad-zone .ad-dim { font-size: 11px; color: var(--ink-4); opacity: 0.7; }
.ad-leader { max-width: 760px; margin: 0 auto 40px; padding: 0 32px; }
.ad-leader .ad-zone { min-height: 110px; }
.ad-incontent { margin: 36px 0; min-height: 250px; }
.ad-sidebar { min-height: 600px; }
/* When Ezoic injects a real ad, the placeholder div needs no styling */
.ezoic-ad { margin: 36px auto; text-align: center; }

/* SIDEBAR */
.rr aside.post-sidebar { position: sticky; top: 80px; }
body.admin-bar .rr aside.post-sidebar { top: 112px; }
.side-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-bottom: 16px; }
.side-card h4 { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-4); margin: 0 0 14px; font-weight: 700; }
.toc { list-style: none; padding: 0; margin: 0; }
.toc li { margin-bottom: 2px; list-style: none; }
.toc a { display: flex; gap: 10px; font-size: 13.5px; color: var(--ink-2); padding: 6px 0 6px 10px; line-height: 1.35; border-left: 2px solid transparent; margin-left: -12px; }
.toc a:hover { color: var(--ink); }
.toc a.active { color: var(--brand); border-left-color: var(--brand); font-weight: 600; }
.toc a .n { color: var(--ink-4); font-weight: 600; min-width: 16px; }
.toc a.active .n { color: var(--brand); }
.side-ask { background: var(--ink); color: #fff; border-radius: var(--radius); padding: 22px; position: relative; overflow: hidden; }
.side-ask::before { content: ''; position: absolute; top: -30px; right: -30px; width: 120px; height: 120px; background: radial-gradient(circle, rgba(245,176,66,0.22), transparent 70%); }
.side-ask .ic { width: 40px; height: 40px; background: rgba(245,176,66,0.18); border-radius: 10px; display: flex; align-items: center; justify-content: center; color: var(--amber); margin-bottom: 12px; position: relative; }
.side-ask h5 { font-size: 18px; margin: 0 0 6px; font-weight: 800; letter-spacing: -0.015em; position: relative; color: #fff !important; }
.side-ask h5 .serif { color: var(--amber); font-weight: 400; }
.side-ask p { font-size: 12.5px; margin: 0 0 14px; color: rgba(255,255,255,0.65); line-height: 1.5; position: relative; }
.side-ask .btn { display: inline-flex; align-items: center; gap: 6px; background: var(--amber); color: var(--ink) !important; padding: 10px 16px; border-radius: 100px; font-weight: 700; font-size: 13px; position: relative; }

/* RELATED */
.related { background: var(--bg-warm); border-top: 1px solid var(--line); padding: 72px 0; margin-top: 80px; }
.related-inner { max-width: var(--wrap); margin: 0 auto; padding: 0 32px; }
.related h2 { font-size: 36px; font-weight: 800; letter-spacing: -0.025em; margin: 0 0 8px; }
.related h2 .serif { color: var(--accent); font-weight: 400; }
.related p.sub { color: var(--ink-3); margin: 0 0 32px; font-size: 15px; }
.rel-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.rel-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; color: inherit; transition: all 0.2s; }
.rel-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.rel-card .thumb { aspect-ratio: 16/10; background: var(--bg-warm); background-image: radial-gradient(circle at 30% 40%, rgba(44,85,196,0.08), transparent 55%), radial-gradient(circle at 70% 60%, rgba(245,176,66,0.08), transparent 55%); position: relative; overflow: hidden; }
.rel-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.rel-card .thumb .tag { position: absolute; top: 14px; left: 14px; background: #fff; padding: 5px 11px; border-radius: 100px; font-size: 11px; font-weight: 700; color: var(--brand); letter-spacing: 0.08em; text-transform: uppercase; z-index: 2; }
.rel-card .bdy { padding: 18px 20px 20px; }
.rel-card h3 { font-size: 16px; font-weight: 700; letter-spacing: -0.01em; margin: 0 0 6px; line-height: 1.3; }
.rel-card .rmeta { font-size: 12px; color: var(--ink-4); }

/* =========================================================================
   FOOTER
   ========================================================================= */
.rr-footer { background: var(--ink); color: rgba(255,255,255,0.7); padding: 60px 32px 32px; margin-top: 100px; }
body.single .rr-footer { margin-top: 0; }
.footer-inner { max-width: var(--wrap); margin: 0 auto; display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 50px; padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,0.1); }
.footer-brand .rr-logo { margin-bottom: 14px; }
.footer-brand .rr-logo-text .name { color: #fff; }
.footer-brand .rr-logo-text .tag { color: rgba(255,255,255,0.5); }
.footer-brand p { font-size: 13.5px; line-height: 1.5; margin: 0 0 20px; max-width: 320px; }
.rr-footer h4 { color: #fff; font-size: 13px; font-weight: 700; margin: 0 0 16px; letter-spacing: 0.04em; text-transform: uppercase; }
.rr-footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.rr-footer ul li { list-style: none; }
.rr-footer ul a { font-size: 14px; transition: color 0.15s; color: rgba(255,255,255,0.75) !important; }
.rr-footer ul a:hover { color: #fff !important; }
.footer-bottom { max-width: var(--wrap); margin: 0 auto; padding-top: 28px; display: flex; justify-content: space-between; font-size: 12.5px; color: rgba(255,255,255,0.4); }
.footer-bottom a { margin-left: 20px; color: rgba(255,255,255,0.55) !important; }
.footer-bottom a:hover { color: #fff !important; }
.social { display: flex; gap: 10px; margin-top: 18px; }
.social a { width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,0.08); display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,0.65); transition: background 0.15s, color 0.15s; }
.social a:hover { background: var(--accent); color: #fff; }
.footer-legal { max-width: var(--wrap); margin: 18px auto 0; font-size: 11.5px; color: rgba(255,255,255,0.3); line-height: 1.5; }

/* =========================================================================
   MOBILE MENU (drawer)
   ========================================================================= */
.menu-toggle { display: none; width: 40px; height: 40px; border-radius: 10px; flex-direction: column; align-items: center; justify-content: center; gap: 4px; background: none; transition: background 0.15s; }
.menu-toggle:hover { background: var(--bg-warm); }
.menu-toggle span { width: 20px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform 0.25s, opacity 0.2s; }
.menu-toggle.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.menu-toggle.open span:nth-child(2) { opacity: 0; }
.menu-toggle.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.m-backdrop { position: fixed; inset: 0; background: rgba(20,24,31,0.45); backdrop-filter: blur(2px); opacity: 0; transition: opacity 0.25s; z-index: 9998; }
.m-backdrop.open { opacity: 1; }
.m-drawer { position: fixed; top: 0; right: 0; height: 100%; width: 84%; max-width: 340px; background: var(--bg); z-index: 9999; transform: translateX(100%); transition: transform 0.28s cubic-bezier(0.4,0,0.2,1); display: flex; flex-direction: column; padding: 18px 18px 22px; box-shadow: -20px 0 50px rgba(20,24,31,0.18); }
.m-drawer.open { transform: translateX(0); }
.m-drawer-head { display: flex; justify-content: space-between; align-items: center; }
.m-drawer-title { font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-4); font-weight: 700; }
.m-close { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; color: var(--ink-2); background: none; transition: background 0.15s; }
.m-close:hover { background: var(--bg-warm); }
.m-nav, .m-nav ul { display: flex; flex-direction: column; list-style: none; margin: 0; padding: 0; }
.m-nav { margin-top: 14px; }
.m-nav a { font-size: 19px; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); padding: 16px 4px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; transition: color 0.15s; }
.m-nav a::after { content: '\2192'; color: var(--ink-4); font-size: 15px; }
.m-nav a:hover { color: var(--brand); }
.m-ask-btn { margin-top: auto; background: var(--ink); color: #fff; text-align: center; padding: 15px; border-radius: 100px; font-weight: 700; font-size: 15px; transition: background 0.15s; }
.m-ask-btn:hover { background: var(--ink-2); }
body.menu-open { overflow: hidden; }

/* =========================================================================
   RESPONSIVE
   ========================================================================= */
@media (max-width: 960px) {
  .menu-toggle { display: flex; }
  .hero h1 { font-size: 48px; }
  .cats { grid-template-columns: repeat(3, 1fr); }
  .cat.featured { grid-column: span 3; }
  .feature-grid { grid-template-columns: 1fr; }
  .guides { grid-template-columns: 1fr; }
  .recent-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .trust { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .rr-nav { display: none; }
  .section-head { flex-direction: column; align-items: flex-start; }
  .section-head h2 { font-size: 32px; }
  .body-grid { grid-template-columns: 1fr; }
  .rr aside.post-sidebar { position: static; }
  .article-head h1 { font-size: 36px; }
  .rel-grid { grid-template-columns: 1fr; }
  .inline-ask { flex-direction: column; align-items: flex-start; }
  .inline-ask .btn { margin-left: 0; }
}

/* ---- Phones ---- */
@media (max-width: 600px) {
  /* Top bar: stack the two lines, center them */
  .rr-topbar { font-size: 11.5px; }
  .rr-topbar-inner { flex-direction: column; gap: 3px; text-align: center; padding: 0 16px; }
  .rr-topbar-inner .live { justify-content: center; }

  /* Header: tighter gutters */
  .rr-header-inner { padding: 12px 16px; gap: 14px; }
  .rr-logo-text .name { font-size: 17px; }
  .btn-ask { display: none; }

  /* Hero */
  .hero { padding: 40px 18px 36px; }
  .hero h1 { font-size: 38px; }
  .hero-sub { font-size: 16px; margin-bottom: 28px; }
  .hero-badge { margin-bottom: 22px; }

  /* Search: stack input over full-width button */
  .search { flex-direction: column; align-items: stretch; padding: 12px; border-radius: 18px; gap: 8px; }
  .search input { text-align: center; padding: 8px 4px; }
  .search-btn { justify-content: center; padding: 13px; }
  .search-hints { margin-top: 16px; }

  /* Stats: 2-up, lighter gutters */
  .stats { margin: 28px 16px 0; padding: 0; grid-template-columns: repeat(2, 1fr); }

  /* Sections */
  section.slab { padding: 48px 16px 20px; }
  .section-head h2 { font-size: 27px; }

  /* Categories: 2-up */
  .cats { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .cat.featured { grid-column: span 2; min-height: 0; }

  .feature-grid { margin-top: 56px; }
  .wide-section { padding: 56px 0; margin-top: 56px; }
  .wide-inner { padding: 0 16px; }

  .trust { margin-top: 56px; padding: 0 16px; gap: 28px; }
  .trust-copy h2 { font-size: 34px; }
  .trust-points { grid-template-columns: 1fr; }

  /* Footer: 2-up links, stacked legal row, safe gutters */
  .rr-footer { padding: 48px 16px 24px; margin-top: 64px; }
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 28px 20px; }
  .footer-brand { grid-column: span 2; }
  .footer-bottom { flex-direction: column; gap: 12px; align-items: flex-start; }
  .footer-bottom a { margin-left: 0; margin-right: 16px; }
}
