/*
Theme Name: EngVarta Blog
Theme URI: https://engvarta.com
Author: EngVarta
Author URI: https://engvarta.com
Description: Lightweight blog theme matching the EngVarta Next.js site design system. Fast, mobile-first, no jQuery.
Version: 1.0.1
Requires at least: 6.0
Requires PHP: 7.4
License: Proprietary
Text Domain: engvarta-blog
*/

/* ─── CSS VARIABLES ─── */
:root {
  --primary: #aa2d32;
  --primary-container: #cb4648;
  --on-primary: #ffffff;
  --primary-fixed: #FFDAD6;
  --surface: #f9f9f9;
  --surface-low: #f3f3f3;
  --surface-lowest: #ffffff;
  --surface-high: #ebebeb;
  --on-surface: #1a1a1a;
  --on-surface-variant: #6b7280;
  --outline-variant: rgba(107, 114, 128, 0.15);
  --secondary: #1e6d01;
  --font-sans: "Inter", system-ui, -apple-system, sans-serif;
  --font-display: "Plus Jakarta Sans", "Inter", system-ui, sans-serif;
  --shadow-ambient: 0 20px 40px rgba(173, 48, 52, 0.06);
  --radius-card: 1rem;
  --radius-btn: 0.75rem;
}

/* ─── RESET ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
html { overflow-x: clip; }
body { font-family: var(--font-sans); color: var(--on-surface); background: var(--surface-lowest); line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: clip; max-width: 100vw; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

/* ─── LAYOUT ─── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 1rem; }
@media (min-width: 640px) { .container { padding: 0 1.5rem; } }
@media (min-width: 1024px) { .container { padding: 0 2rem; } }

/* ─── TYPOGRAPHY ─── */
h1, h2, h3, h4, h5, h6 { font-family: var(--font-display); font-weight: 800; color: var(--on-surface); line-height: 1.2; overflow-wrap: break-word; word-break: break-word; }
h1 { font-size: 2rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.25rem; }
@media (min-width: 640px) {
  h1 { font-size: 2.5rem; }
  h2 { font-size: 1.875rem; }
  h3 { font-size: 1.5rem; }
}
@media (min-width: 1024px) {
  h1 { font-size: 3rem; }
  h2 { font-size: 2.25rem; }
}

/* ─── BUTTONS ─── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 0.25rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-container));
  color: var(--on-primary); font-weight: 700; font-size: 0.875rem;
  padding: 0.625rem 1.25rem; border-radius: var(--radius-btn);
  transition: all 0.2s ease; border: none; cursor: pointer;
}
.btn-primary:hover { filter: brightness(1.08); box-shadow: 0 12px 32px rgba(170, 45, 50, 0.2); }
.btn-primary:active { transform: scale(0.97); }

/* ─── NAVBAR ─── */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.85); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--outline-variant);
}
.nav-wrap { display: flex; align-items: center; justify-content: space-between; height: 4rem; }
.nav-logo img { height: 2.5rem; width: auto; }
@media (min-width: 640px) { .nav-logo img { height: 3rem; } }

/* Desktop nav */
.nav-desktop { display: none; align-items: center; gap: 0.25rem; }
@media (min-width: 1024px) { .nav-desktop { display: flex; } }
.nav-desktop a, .nav-desktop .dropdown-trigger {
  font-size: 0.875rem; font-weight: 500; color: var(--on-surface-variant);
  padding: 0.5rem 0.75rem; border-radius: 0.5rem; transition: color 0.15s;
  background: none; border: none; cursor: pointer; font-family: var(--font-sans);
}
.nav-desktop a:hover, .nav-desktop .dropdown-trigger:hover { color: var(--primary); }
.nav-desktop a.active { color: var(--primary); font-weight: 600; }

/* Dropdown */
.nav-dropdown { position: relative; }
.nav-dropdown .dropdown-menu {
  display: none; position: absolute; top: 100%; left: 0; min-width: 220px;
  background: var(--surface-lowest); border-radius: 0.75rem;
  box-shadow: var(--shadow-ambient); padding: 0.5rem; margin-top: 0.25rem;
}
.nav-dropdown:hover .dropdown-menu { display: block; }
.dropdown-menu a {
  display: block; padding: 0.5rem 0.75rem; border-radius: 0.5rem;
  font-size: 0.875rem; color: var(--on-surface);
}
.dropdown-menu a:hover { background: var(--surface-low); color: var(--primary); }

/* Mobile nav */
/* Hamburger — <label> for CSS checkbox toggle */
.hamburger { display: flex; align-items: center; justify-content: center; width: 2.75rem; height: 2.75rem; cursor: pointer; background: none; border: none; -webkit-tap-highlight-color: transparent; }
@media (min-width: 1024px) { .hamburger { display: none; } }
.hamburger svg { width: 1.5rem; height: 1.5rem; color: var(--on-surface); }
/* hamburger-open/close visibility controlled by <style> in header.php via #mobile-menu-toggle:checked */
.mobile-menu { position: absolute; top: 4rem; left: 0; right: 0; background: var(--surface-lowest); border-bottom: 1px solid var(--outline-variant); padding: 0.5rem 1rem 1rem; box-shadow: 0 8px 24px rgba(0,0,0,0.08); z-index: 50; }
@media (min-width: 1024px) { .mobile-menu { display: none !important; } }
.mobile-menu a { display: block; padding: 0.75rem; font-size: 0.875rem; font-weight: 500; color: var(--on-surface); }
.mobile-menu a:hover { color: var(--primary); }
.mobile-menu details summary { display: flex; align-items: center; justify-content: space-between; padding: 0.75rem; font-size: 0.875rem; font-weight: 500; color: var(--on-surface); cursor: pointer; list-style: none; }
.mobile-menu details summary::-webkit-details-marker { display: none; }
.mobile-menu details[open] summary svg { transform: rotate(180deg); }
.mobile-menu details .sub-menu { padding-left: 1.5rem; }
.mobile-menu details .sub-menu a { font-size: 0.8125rem; padding: 0.5rem 0.75rem; color: var(--on-surface-variant); }

.nav-actions { display: flex; align-items: center; gap: 0.75rem; }

/* ─── FOOTER ─── */
.site-footer { background: var(--on-surface); color: white; }
.footer-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; text-align: center; gap: 1rem; padding: 2rem 0; border-bottom: 1px solid rgba(255,255,255,0.08); }
@media (min-width: 640px) { .footer-top { justify-content: space-between; text-align: left; } }
.footer-brand { display: flex; flex-direction: column; gap: 0.25rem; align-items: center; }
@media (min-width: 640px) { .footer-brand { align-items: flex-start; } }
.footer-brand-name { font-family: var(--font-display); font-size: 1.5rem; font-weight: 800; letter-spacing: -0.02em; }
.footer-tagline { font-size: 0.875rem; color: rgba(255,255,255,0.7); }
.footer-stores { display: flex; gap: 0.5rem; }
.footer-stores img { height: 2.25rem; width: auto; }
.footer-app-badges { display: flex; gap: 0.5rem; align-items: center; }
.footer-app-badges img { height: 36px; width: auto; }
.footer-social-bottom { display: flex; gap: 0.75rem; align-items: center; }
.footer-social-bottom a { color: rgba(255,255,255,0.5); transition: color 0.15s; }
.footer-social-bottom a:hover { color: white; }

.footer-links { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; padding: 2rem 0; }
@media (min-width: 640px) { .footer-links { grid-template-columns: repeat(4, 1fr); gap: 2.5rem; } }
.footer-col h3 { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: rgba(255,255,255,0.4); margin-bottom: 0.75rem; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin: 0; padding: 0; }
.footer-col a { display: block; font-size: 0.875rem; color: rgba(255,255,255,0.7); padding: 0.25rem 0; transition: color 0.15s; }
.footer-col a:hover { color: white; }

.footer-made-in-india { text-align: center; margin-top: 0.5rem; padding-top: 1.5rem; font-size: 0.875rem; color: rgba(255,255,255,0.5); font-weight: 500; border-top: 1px solid rgba(255,255,255,0.1); }
.footer-made-in-india p { margin: 0; }
.footer-bottom { display: flex; flex-direction: column; align-items: center; gap: 0.75rem; margin-top: 1rem; padding-bottom: 2rem; }
@media (min-width: 640px) { .footer-bottom { flex-direction: row; justify-content: space-between; } }
.footer-copyright { font-size: 0.75rem; color: rgba(255,255,255,0.25); margin: 0; }
.footer-social-bottom { display: flex; align-items: center; gap: 1rem; }
.footer-social-bottom a { color: rgba(255,255,255,0.3); transition: color 0.15s; }
.footer-social-bottom a:hover { color: white; }
.footer-social-bottom svg { width: 16px; height: 16px; }
.footer-legal { display: flex; align-items: center; gap: 1rem; }
.footer-legal a { font-size: 0.75rem; color: rgba(255,255,255,0.25); transition: color 0.15s; }
.footer-legal a:hover { color: rgba(255,255,255,0.5); }

/* ─── HERO (Blog listing) ─── */
.blog-hero {
  background: linear-gradient(to bottom, var(--primary-fixed), var(--surface));
  padding: 3rem 0 3.5rem; text-align: center;
}
.blog-hero h1 { color: var(--on-surface); }
.blog-hero p { margin-top: 1rem; color: var(--on-surface-variant); font-size: 1rem; max-width: 36rem; margin-left: auto; margin-right: auto; }
@media (min-width: 640px) { .blog-hero { padding: 4rem 0 5rem; } .blog-hero p { font-size: 1.125rem; } }
.trust-strip { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.75rem; margin-top: 1.5rem; }
.trust-strip span { font-size: 0.75rem; font-weight: 600; color: var(--on-surface); background: white; padding: 0.375rem 0.75rem; border-radius: 9999px; box-shadow: 0 1px 3px rgba(0,0,0,0.06); }

/* ─── POST GRID ─── */
.post-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.25rem; padding: 2.5rem 0; }
@media (min-width: 768px) { .post-grid { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; } }
@media (min-width: 1024px) { .post-grid { grid-template-columns: repeat(4, 1fr); gap: 1.5rem; } }

.post-card {
  background: var(--surface-lowest); border-radius: var(--radius-card);
  overflow: hidden; box-shadow: var(--shadow-ambient);
  transition: transform 0.2s, box-shadow 0.2s;
}
.post-card:hover { transform: translateY(-4px); box-shadow: 0 24px 48px rgba(173, 48, 52, 0.1); }
.post-card-image { display: block; aspect-ratio: 16/9; overflow: hidden; }
.post-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.post-card:hover .post-card-image img { transform: scale(1.05); }
.post-card-body { padding: 1.25rem; }
.post-card .cat-pill {
  display: inline-block; font-size: 0.6875rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--primary); background: rgba(170, 45, 50, 0.1);
  padding: 0.2rem 0.5rem; border-radius: 9999px; margin-bottom: 0.5rem;
}
.post-card h2 { font-size: 1.125rem; font-weight: 700; line-height: 1.3; margin-bottom: 0.5rem; }
.post-card h2 a { color: var(--on-surface); }
.post-card h2 a:hover { color: var(--primary); }
.post-card .excerpt { font-size: 0.875rem; color: var(--on-surface-variant); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.post-card .meta { font-size: 0.75rem; color: var(--on-surface-variant); margin-top: 0.75rem; }

/* ─── PAGINATION ─── */
.pagination { display: flex; justify-content: center; gap: 0.5rem; padding: 1rem 0 3rem; }
.pagination a, .pagination .current {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 2.25rem; height: 2.25rem; font-size: 0.875rem; font-weight: 600;
  border-radius: 0.5rem; transition: all 0.15s;
}
.pagination a { color: var(--on-surface-variant); background: var(--surface-lowest); border: 1px solid var(--outline-variant); }
.pagination a:hover { color: var(--primary); border-color: var(--primary); }
.pagination .current { color: var(--on-primary); background: var(--primary); }

/* ─── SINGLE POST ─── */
.single-layout { display: grid; gap: 2rem; padding: 2rem 0 3rem; min-width: 0; max-width: 100%; }
.single-layout article { min-width: 0; overflow-wrap: break-word; word-break: break-word; }
@media (min-width: 1024px) { .single-layout { grid-template-columns: 1fr 320px; gap: 3rem; } }

.post-header { margin-bottom: 2rem; }
.post-header .cat-pill { display: inline-block; font-size: 0.6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--primary); background: rgba(170, 45, 50, 0.1); padding: 0.25rem 0.625rem; border-radius: 9999px; margin-bottom: 0.75rem; }
.post-header h1 { margin-bottom: 0.75rem; }
.post-meta { font-size: 0.875rem; color: var(--on-surface-variant); display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: center; }
.post-meta .sep { color: var(--outline-variant); }

/* Post content */
.entry-content { float: none !important; width: 100% !important; font-size: 1.0625rem; line-height: 1.75; color: var(--on-surface); overflow: hidden; }
.entry-content h2 { font-size: 1.5rem; line-height: 1.4; margin: 2rem 0 0.75rem; font-weight: 600; color: #333; }
.entry-content h3 { font-size: 1.25rem; line-height: 1.4; margin: 1.5rem 0 0.5rem; font-weight: 600; }
.entry-content p { margin-bottom: 1.25rem; font-size: 1.0625rem; line-height: 1.85; }
.entry-content ul, .entry-content ol { margin: 1rem 0 1.25rem; padding-left: 1.5rem; }
.entry-content ul li, .entry-content ol li { margin-bottom: 0.5rem; line-height: 1.75; font-size: 1.0625rem; }
li > ul, li > ol { margin-left: 0; }
.entry-content img { max-width: 100%; height: auto; border-radius: 0.75rem; margin: 1.5rem 0; }
.entry-content iframe { max-width: 100%; height: auto; aspect-ratio: 16/9; border-radius: 0.75rem; margin: 1.5rem 0; }
.entry-content img.size-medium { max-width: 400px; }
.entry-content blockquote { border-left: 4px solid var(--primary); padding: 1rem 1.5rem; margin: 1.5rem 0; background: var(--surface); border-radius: 0 0.5rem 0.5rem 0; color: var(--on-surface-variant); font-style: italic; }
.entry-content a { color: var(--primary); font-weight: 500; box-shadow: none; border-bottom: 1px solid; }
.entry-content a:hover { text-decoration: none; color: #e85b5b; box-shadow: none; }
.entry-content a:focus { color: #e85b5b; box-shadow: none; outline: none; }
.entry-content a img { box-shadow: none; border-bottom: none; }
.entry-content table { border-collapse: collapse; margin: 1.5rem 0; }
.entry-content .table-wrap { display: block !important; overflow-x: auto !important; -webkit-overflow-scrolling: touch; max-width: 100% !important; width: 100% !important; margin: 1.5rem 0; }
.entry-content .table-wrap table { margin: 0; white-space: nowrap; }
.entry-content th, .entry-content td { padding: 0.5rem 0.75rem; border: 1px solid var(--outline-variant); text-align: left; font-size: 0.875rem; }
.entry-content th { background: var(--surface-low); font-weight: 600; }
strong { font-weight: 600; }

/* WP sidebar layout compat */
@media screen and (min-width: 48em) {
  .has-sidebar:not(.error404) #primary { float: left; width: 71%; padding-right: 20px; }
  .has-sidebar #secondary { float: right; padding-top: 0; width: 27%; }
}

/* TOC plugin compat */
#ez-toc-container a { border: none; box-shadow: none; }
div#ez-toc-container nav ul ul li { font-size: 100%; }
div#ez-toc-container ul li { margin-bottom: 5px; margin-top: 5px; }

/* Reading time (hidden, we show our own) */
span.rt-reading-time { display: none !important; }
.reading-time { display: none !important; }

/* Disqus compat */
#disqus_thread { margin-top: 2rem; }

/* Play Store / App Store inline links */
.play-store, .itune { display: inline-block; vertical-align: top; margin-right: 10px; }
.play-store img, .itune img { width: 200px; }
.play-store-header, .itune-header { display: inline-block; vertical-align: top; }
.play-store-header img, .itune-header img { width: 160px; }

/* Video containers */
.video-container { display: block; margin-top: 60px; margin-bottom: 30px; }
.muse-video-entry { padding-top: 100% !important; }
.muse-entry-preview { display: none !important; }

/* FVP plugin compat */
.fvp-share { display: none !important; }

/* Featured image on single */
.post-featured-image { border-radius: var(--radius-card); overflow: hidden; margin-bottom: 2rem; }
.post-featured-image img { width: 100%; height: auto; }

/* Share buttons */
.post-share { display: flex; align-items: center; gap: 0.75rem; padding: 1.5rem 0; border-top: 1px solid var(--outline-variant); margin-top: 2rem; }
.post-share span { font-size: 0.875rem; font-weight: 600; color: var(--on-surface); }
.post-share a { display: inline-flex; align-items: center; justify-content: center; width: 2.25rem; height: 2.25rem; border-radius: 50%; background: var(--surface-low); color: var(--on-surface-variant); transition: all 0.15s; }
.post-share a:hover { background: var(--primary); color: white; }

/* Post tags */
.post-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; padding: 1.25rem 0; border-top: 1px solid var(--outline-variant); margin-top: 1.5rem; }
.post-tags-label { font-size: 0.875rem; font-weight: 600; color: var(--on-surface); }
.post-tags a { display: inline-block; font-size: 0.75rem; font-weight: 500; color: var(--on-surface-variant); background: var(--surface-low); padding: 0.25rem 0.75rem; border-radius: 9999px; border: 1px solid var(--outline-variant); transition: all 0.15s; }
.post-tags a:hover { color: var(--primary); border-color: var(--primary); background: rgba(170, 45, 50, 0.05); }

/* Comments */
.comments-section { margin-top: 2.5rem; padding-top: 2rem; border-top: 1px solid var(--outline-variant); }
.comments-title { font-size: 1.25rem; font-weight: 700; margin-bottom: 1.5rem; }
.comment-list { list-style: none; padding: 0; margin: 0; }
.comment-list li { margin-bottom: 1.25rem; }
.ev-comment .comment-body { display: flex; gap: 0.75rem; }
.comment-author-avatar img { border-radius: 50%; }
.comment-content { flex: 1; }
.comment-meta { display: flex; align-items: baseline; gap: 0.75rem; margin-bottom: 0.375rem; }
.comment-author-name { font-size: 0.875rem; color: var(--on-surface); }
.comment-date { font-size: 0.75rem; color: var(--on-surface-variant); }
.comment-text { font-size: 0.875rem; line-height: 1.6; color: var(--on-surface-variant); }
.comment-text p { margin-bottom: 0.5rem; }
.comment-reply-link { font-size: 0.75rem; color: var(--primary); font-weight: 600; margin-top: 0.25rem; display: inline-block; }
.comment-respond { margin-top: 2rem; }
.comment-respond .comment-reply-title { font-size: 1.125rem; font-weight: 700; margin-bottom: 1rem; }
.comment-form label { display: block; font-size: 0.875rem; font-weight: 600; color: var(--on-surface); margin-bottom: 0.375rem; }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea { width: 100%; padding: 0.625rem 0.75rem; border: 1px solid var(--outline-variant); border-radius: 0.5rem; font-size: 1rem; font-family: inherit; background: var(--surface-lowest); transition: border-color 0.15s; }
.comment-form input:focus, .comment-form textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(170, 45, 50, 0.1); }
.comment-form p { margin-bottom: 1rem; }
.comment-form .form-submit input[type="submit"] {
  background: var(--primary); color: white; border: none; padding: 0.625rem 1.5rem;
  border-radius: 0.5rem; font-size: 0.875rem; font-weight: 600; cursor: pointer; transition: opacity 0.15s;
}
.comment-form .form-submit input[type="submit"]:hover { opacity: 0.9; }
.comments-closed { font-size: 0.875rem; color: var(--on-surface-variant); font-style: italic; }

/* FAQ Plugin (wpb_af_faq) */
ul.qe-faqs-filters-container { display: none; }
.wpb_af_area { list-style: none; padding: 0; margin: 0; }
.wpb_af_area > li { background: var(--surface-lowest); border-radius: 0.75rem; margin-bottom: 0.75rem; overflow: hidden; border: 1px solid var(--outline-variant); }
.wpb_af_area li > a, .wpb_af_area li > a:focus, .wpb_af_area li > a:visited {
  display: flex;
  padding: 1rem 1.25rem; font-weight: 600; font-size: 1rem; color: var(--on-surface) !important;
  cursor: pointer; user-select: none; transition: background 0.15s; text-decoration: none; border: none; box-shadow: none;
}
.wpb_af_area li > a:hover { background: var(--surface-low); }

.wpb_af_faq_content, .faq-answer, .wpb-toggle-content {
  padding: 0 1.25rem 1rem; font-size: 0.9375rem; line-height: 1.6; color: var(--on-surface-variant);
}
.wpb_af_faq { background: var(--surface-lowest); border-radius: 0.75rem; margin-bottom: 0.75rem; overflow: hidden; border: 1px solid var(--outline-variant); }
.wpb_af_faq_title, .wpb-toggle-faq, .faq-question {
  padding: 1rem 1.25rem; font-weight: 600; font-size: 1rem; color: var(--on-surface);
  cursor: pointer; display: flex; 
  user-select: none; transition: background 0.15s;
}
.wpb_af_faq_title:hover { background: var(--surface-low); }


a.itune-header {
  margin-left:10px;
}

/* Related posts */
.related-posts { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--outline-variant); }
.related-posts h3 { font-size: 1.25rem; margin-bottom: 1.25rem; }
.related-grid { display: grid; gap: 1rem; }
@media (min-width: 640px) { .related-grid { grid-template-columns: repeat(3, 1fr); } }

/* ─── SIDEBAR ─── */
.blog-sidebar { position: sticky; top: 5rem; align-self: start; min-width: 0; max-width: 100%; }
.sidebar-widget { background: var(--surface-lowest); border-radius: var(--radius-card); padding: 1.25rem; margin-bottom: 1.25rem; box-shadow: var(--shadow-ambient); }
.sidebar-widget h4 { font-family: var(--font-display); font-size: 0.875rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; color: var(--on-surface); margin-bottom: 1rem; padding-bottom: 0.5rem; border-bottom: 2px solid var(--primary); }

/* Search widget */
.search-form { display: flex; gap: 0.5rem; }
.search-form input[type="search"] {
  flex: 1; font-size: 1rem; padding: 0.625rem 0.75rem; border: 1px solid var(--outline-variant);
  border-radius: var(--radius-btn); outline: none; font-family: var(--font-sans);
  transition: border-color 0.15s;
}
.search-form input[type="search"]:focus { border-color: var(--primary); }
.search-form button { padding: 0.625rem 1rem; background: var(--primary); color: white; border: none; border-radius: var(--radius-btn); cursor: pointer; font-weight: 600; font-size: 0.875rem; }

/* Recent posts widget */
.recent-post-item { display: flex; gap: 0.75rem; padding: 0.5rem 0; border-bottom: 1px solid var(--outline-variant); }
.recent-post-item:last-child { border-bottom: none; }
.recent-post-thumb { width: 3.5rem; height: 3.5rem; border-radius: 0.5rem; overflow: hidden; flex-shrink: 0; }
.recent-post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.recent-post-info { flex: 1; min-width: 0; }
.recent-post-info a { font-size: 0.8125rem; font-weight: 600; color: var(--on-surface); line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.recent-post-info a:hover { color: var(--primary); text-decoration: underline; }
/* Sidebar links hover underline */
.blog-sidebar a:hover { text-decoration: underline; }
.recent-post-info .date { font-size: 0.6875rem; color: var(--on-surface-variant); margin-top: 0.2rem; }

/* Recent comments widget */
.recent-comment-item { padding: 0.5rem 0; border-bottom: 1px solid var(--outline-variant); font-size: 0.8125rem; }
.recent-comment-item:last-child { border-bottom: none; }
.recent-comment-item .commenter { font-weight: 600; color: var(--on-surface); }
.recent-comment-item .comment-excerpt { color: var(--on-surface-variant); }
.recent-comment-item .on-post a { color: var(--primary); font-weight: 500; }

/* Tags cloud */
.tag-cloud { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tag-cloud a {
  font-size: 0.75rem; font-weight: 600; color: var(--on-surface-variant);
  background: var(--surface-low); padding: 0.3rem 0.75rem; border-radius: 9999px;
  transition: all 0.15s;
}
.tag-cloud a:hover { color: var(--primary); background: rgba(170, 45, 50, 0.1); }

/* ─── DOWNLOAD MODAL ─── */
.ev-modal { display: none; position: fixed; inset: 0; z-index: 100; align-items: flex-end; justify-content: center; }
.ev-modal.is-open { display: flex; }

/* Hide Zendesk/third-party chat widgets when any modal is open */
body:has(.ev-modal.is-open) iframe[title*="chat" i],
body:has(.ev-modal.is-open) iframe[title*="messaging" i],
body:has(.ev-modal.is-open) #launcher,
body:has(.ev-modal.is-open) [data-testid="launcher"],
body:has(.ev-modal.is-open) .zEWidget-launcher,
body:has(.ev-modal.is-open) div[class*="zEWidget"] {
  display: none !important;
}
@media (min-width: 640px) { .ev-modal { align-items: center; padding: 1rem; } }
.modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.6); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.modal-content {
  position: relative; background: linear-gradient(to bottom, #fafafa, rgba(var(--primary-fixed-rgb, 251,218,218), 0.6));
  border-radius: 1.5rem 1.5rem 0 0; width: 100%; max-width: 28rem; max-height: 90vh; overflow-y: auto;
  animation: slideUp 0.3s ease-out;
}
@media (min-width: 640px) { .modal-content { border-radius: 1rem; animation: fadeIn 0.2s ease-out; } }
.modal-close {
  position: absolute; top: 1rem; right: 1rem; z-index: 10;
  width: 2rem; height: 2rem; display: flex; align-items: center; justify-content: center;
  border-radius: 50%; background: rgba(0,0,0,0.08); color: var(--on-surface-variant);
  cursor: pointer; border: none; -webkit-tap-highlight-color: transparent;
}
.modal-body { padding: 2rem 1.5rem 1.5rem; text-align: center; }
@media (min-width: 640px) { .modal-body { padding: 2.5rem 1.2rem 2.5rem;  } }
.modal-logo { display: inline-block; background: white; border-radius: 0.5rem; padding: 0.5rem; margin-bottom: 1.5rem; box-shadow: 0 1px 3px rgba(0,0,0,0.06); }
.modal-logo img { height: 3.5rem; width: auto; }
.modal-steps { margin-top: 1.5rem; text-align: left; max-width: 20rem; margin-left: auto; margin-right: auto; }
.modal-step { display: flex; align-items: flex-start; gap: 0.75rem; margin-bottom: 1rem; }
.modal-step-num { flex-shrink: 0; width: 1.75rem; height: 1.75rem; border-radius: 50%; background: linear-gradient(135deg, var(--primary), var(--primary-container)); color: white; font-size: 0.75rem; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.modal-step-title { font-weight: 600; font-size: 0.875rem; color: var(--on-surface); }
.modal-step-sub { font-size: 0.75rem; color: var(--on-surface-variant); }
.modal-stores { margin-top: 1.5rem; display: flex; justify-content: center; gap: 0.75rem; }
.modal-stores img { height: 2.75rem; width: auto; transition: transform 0.15s; }
.modal-stores a:hover img { transform: scale(1.05); }
.modal-trust { margin-top: 1.5rem; padding-top: 1rem; }
.modal-trust-avatars { display: flex; align-items: center; }
.modal-trust-avatars img { width: 2rem; height: 2rem; border-radius: 50%; border: 2px solid white; object-fit: cover; margin-left: -0.5rem; }
.modal-trust-avatars img:first-child { margin-left: 0; }
.modal-trust-text { font-size: 0.9375rem; font-weight: 700; color: var(--on-surface); margin-top: 0.25rem; }
.modal-trust-text .highlight { color: var(--primary); }
.modal-pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.375rem; margin-top: 0.625rem; }
.modal-pills span { font-size: 0.75rem; font-weight: 600; color: var(--on-surface); background: white; padding: 0.3rem 0.75rem; border-radius: 9999px; border: 1px solid var(--outline-variant); }

/* ─── 404 ─── */
.page-404 { text-align: center; padding: 5rem 0; }
.page-404 h1 { font-size: 4rem; color: var(--primary); }
.page-404 p { margin-top: 1rem; color: var(--on-surface-variant); font-size: 1.125rem; }
.page-404 a { display: inline-block; margin-top: 1.5rem; color: var(--primary); font-weight: 600; }

/* ─── ANIMATIONS ─── */
@keyframes slideUp { from { opacity: 0; transform: translateY(100%); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }

/* ─── UTILITIES ─── */
.text-primary { color: var(--primary); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
