/* =========================================================
   PROJNANA - main stylesheet (mobile-first, responsive)
   ========================================================= */
:root {
  --accent: #e0342b;
  --accent-dark: #b8241c;
  --accent-soft: #fdeceb;
  --ink: #1f2328;
  --muted: #6b7280;
  --border: #e7e8ec;
  --bg-soft: #f7f7fb;
  --radius: 10px;
  --maxw: 1240px;
  --shadow-sm: 0 1px 3px rgba(15,15,20,.06);
  --shadow-md: 0 10px 28px rgba(15,15,20,.08);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Poppins', 'Segoe UI', Roboto, -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--ink);
  background: #fff;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; transition: color .15s; }
img { max-width: 100%; display: block; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
h1, h2, h3, h4 { letter-spacing: -.01em; }

/* ---------- Header ---------- */
.ad-strip { text-align: center; background: #111; padding: 6px 0; }
.ad-strip img { display: inline-block; max-height: 90px; margin: 0 auto; }

.site-header { border-bottom: 1px solid var(--border); position: sticky; top: 0; background: rgba(255,255,255,.96); backdrop-filter: blur(6px); z-index: 100; }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; }
.brand-logo { max-height: 46px; }
.brand-text { font-size: 1.6rem; font-weight: 800; color: var(--accent); letter-spacing: -.02em; }

.nav-toggle { display: none; flex-direction: column; gap: 4px; background: none; border: 0; cursor: pointer; }
.nav-toggle span { width: 24px; height: 2px; background: var(--ink); }

.main-nav { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.main-nav a { font-weight: 600; font-size: .95rem; color: #333; padding: 6px 2px; }
.main-nav a.active, .main-nav a:hover { color: var(--accent); }
.nav-divider { width: 1px; height: 20px; background: var(--border); }

.nav-search-wrap { position: relative; margin-left: auto; }
.nav-search-wrap input {
  width: 520px; padding: 9px 14px; border: 1px solid var(--border); border-radius: 30px; font-size: .88rem;
  background: var(--bg-soft); font-family: inherit; transition: width .2s, background .2s;
}
.nav-search-wrap input:focus { outline: none; width: 280px; background: #fff; border-color: var(--accent); }
#navSearchResults {
  display: none; position: absolute; top: calc(100% + 8px); right: 0; width: 320px; max-width: 90vw;
  background: #fff; border: 1px solid var(--border); border-radius: 10px; box-shadow: var(--shadow-md);
  max-height: 360px; overflow-y: auto; z-index: 200;
}
.nav-search-item { display: flex; gap: 10px; align-items: center; padding: 10px 14px; border-bottom: 1px solid #f2f2f5; }
.nav-search-item:last-child { border-bottom: 0; }
.nav-search-item:hover { background: var(--bg-soft); }
.nav-search-item img { width: 42px; height: 42px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
.nav-search-item small { color: var(--muted); }
.nav-search-empty { padding: 14px; color: var(--muted); font-size: .88rem; text-align: center; }

/* ---------- Filters (language + category rows) ---------- */
.filters-wrap { background: var(--bg-soft); padding: 20px 0; border-bottom: 1px solid var(--border); }
.filter-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.filter-row:last-child { margin-bottom: 0; }
.filter-row-center { justify-content: center; text-align: center; }
.filter-label { font-weight: 700; font-size: .8rem; text-transform: uppercase; color: var(--muted); margin-right: 6px; }
.filter-pill {
  padding: 8px 18px; border-radius: 30px; border: 1px solid var(--border);
  background: #fff; font-size: .88rem; font-weight: 600; cursor: pointer; transition: all .15s;
}
.filter-pill.active, .filter-pill:hover { background: var(--accent); border-color: var(--accent); color: #fff; }

/* Multi-select language pills (checkbox styled as a pill) */
.lang-pill { display: inline-flex; align-items: center; gap: 6px; user-select: none; }
.lang-pill input[type="checkbox"] {
  appearance: none; -webkit-appearance: none; width: 15px; height: 15px; border: 2px solid var(--border);
  border-radius: 4px; margin: 0; cursor: pointer; position: relative; flex-shrink: 0; background: #fff;
}
.lang-pill input[type="checkbox"]:checked { background: var(--accent); border-color: var(--accent); }
.lang-pill input[type="checkbox"]:checked::after {
  content: ''; position: absolute; left: 3px; top: 0px; width: 4px; height: 8px;
  border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.lang-pill:has(input:checked) { background: var(--accent-soft); border-color: var(--accent); }

/* ---------- Live blog search (blogs.php grid filter) ---------- */
.live-search-wrap { position: relative; margin-bottom: 10px; }
.live-search-wrap input {
  width: 100%; padding: 14px 20px; border: 1px solid var(--border); border-radius: 30px; font-size: 1rem;
  font-family: inherit; box-shadow: var(--shadow-sm); transition: border-color .15s;
}
.live-search-wrap input:focus { outline: none; border-color: var(--accent); }
#liveSearchSpinner { position: absolute; right: 20px; top: 50%; transform: translateY(-50%); animation: spin 1s linear infinite; color: var(--accent); }
@keyframes spin { from { transform: translateY(-50%) rotate(0deg); } to { transform: translateY(-50%) rotate(360deg); } }

/* ---------- Category buttons (sidebar, item 12) ---------- */
.category-btn-list { display: flex; flex-wrap: wrap; gap: 8px; }
.category-btn {
  display: inline-block; padding: 7px 14px; border-radius: 20px; border: 1px solid var(--border);
  background: var(--bg-soft); font-size: .85rem; font-weight: 600; transition: all .15s;
}
.category-btn:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.page-banner {
  background: linear-gradient(135deg, rgba(20,20,26,.85), rgba(10,10,14,.85));
  background-color: #1c1c1c;
  background-size: cover;
  background-position: center;
  color: #fff; padding: 70px 0; text-align: center;
}
.page-banner.has-image { background-image: linear-gradient(rgba(10,10,10,.55), rgba(10,10,10,.55)), var(--banner-img); }
.page-banner h1 { font-size: 2.4rem; margin: 0 0 8px; }
.page-banner .crumbs { color: #ccc; font-size: .9rem; }
.page-banner .crumbs a { color: #fff; }

/* ---------- Homepage blog cards (elevated 3D-style card, fixed 370x240 image) ---------- */
.home-blog-grid { display: grid; grid-template-columns: repeat(3, 370px); gap: 48px 34px; justify-content: center; padding: 30px 0 50px; }
.home-blog-grid-2col { grid-template-columns: repeat(2, 1fr); justify-content: stretch; gap: 40px 28px; }
.home-blog-card {
  background: #fff;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(20,20,30,.06), 0 18px 40px rgba(20,20,30,.14);
  transition: transform .25s ease, box-shadow .25s ease;
}
.home-blog-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 4px 10px rgba(20,20,30,.08), 0 30px 55px rgba(20,20,30,.2);
}
.home-blog-thumb { display: block; width: 100%; height: 240px; overflow: hidden; background: #eee; }
.home-blog-thumb img { width: 100%; height: 240px; object-fit: cover; display: block; }
.home-blog-body { padding: 20px 24px 26px; }
.home-blog-date { display: flex; align-items: baseline; gap: 10px; padding-bottom: 14px; border-bottom: 1px solid var(--border); }
.hbd-day { font-size: 2.1rem; font-weight: 800; color: var(--accent); line-height: 1; }
.hbd-month { font-size: .8rem; font-weight: 700; letter-spacing: .03em; color: #333; text-transform: uppercase; }
.home-blog-meta { margin-top: 14px; font-size: .9rem; color: var(--muted); }
.home-blog-meta a { color: var(--accent); font-weight: 700; }
.home-blog-meta .hbm-sep { margin: 0 8px; color: var(--border); }
.home-blog-title { margin: 10px 0 8px; font-size: 1.3rem; font-weight: 800; line-height: 1.35; }
.home-blog-title a { color: var(--ink); }
.home-blog-title a:hover { color: var(--accent); }
.home-blog-excerpt { color: #666; font-size: .95rem; margin: 0 0 14px; line-height: 1.6; }
.home-blog-readmore { display: inline-flex; align-items: center; gap: 6px; font-weight: 800; color: var(--ink); font-size: .95rem; }
.home-blog-readmore:hover { color: var(--accent); }

/* ---------- Blog grid / cards ---------- */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px 28px; padding: 40px 0; }
.blog-grid-2col { grid-template-columns: repeat(2, 1fr); }
.blog-card {
  border-radius: 30px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 6px rgba(20,20,30,.06), 0 18px 40px rgba(20,20,30,.14);
  transition: transform .25s ease, box-shadow .25s ease;
}
.blog-card:hover { box-shadow: 0 4px 10px rgba(20,20,30,.08), 0 30px 55px rgba(20,20,30,.2); transform: translateY(-8px); }
.blog-card .thumb { position: relative; aspect-ratio: 16/10; overflow: hidden; background: #eee; }
.blog-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.blog-card .date-badge {
  position: absolute; top: 12px; right: 12px; background: var(--accent); color: #fff;
  text-align: center; padding: 6px 10px; border-radius: 4px; font-size: .75rem; line-height: 1.2;
}
.blog-card .date-badge strong { display: block; font-size: 1.1rem; }
.blog-card .body { padding: 20px 24px 12px; }
.blog-card h3 { font-size: 1.1rem; margin: 4px 0 8px; }
.blog-card .meta { font-size: .8rem; color: var(--muted); margin-bottom: 8px; }
.blog-card .meta a { color: var(--accent); font-weight: 600; }
.blog-card p { color: #555; font-size: .92rem; margin: 0 0 10px; }
.read-more { color: var(--accent); font-weight: 700; font-size: .85rem; }

.card-footer-row { display: flex; align-items: center; justify-content: space-between; padding: 0 24px 22px; }
.like-btn { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; cursor: pointer; font-weight: 600; color: var(--muted); }
.like-btn.liked, .like-btn:hover { color: var(--accent); }
.like-btn svg { width: 20px; height: 20px; }
.share-icons { display: flex; gap: 8px; }
.share-icons a { width: 30px; height: 30px; border: 1px solid var(--border); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .8rem; }
.share-icons a:hover { background: var(--accent); border-color: var(--accent); color: #fff; }

.featured-badge { display: inline-block; background: #111; color: #fff; font-size: .7rem; padding: 3px 8px; border-radius: 4px; margin-bottom: 8px; }

/* ---------- Blog detail ---------- */
.detail-wrap { display: grid; grid-template-columns: 2fr 1fr; gap: 40px; padding: 40px 0; }
.detail-main img.featured { border-radius: var(--radius); margin-bottom: 24px; }
.detail-main h1 { font-size: 2rem; margin-bottom: 8px; }
.detail-meta { color: var(--muted); font-size: .9rem; margin-bottom: 22px;    padding-left: 15px; }
.detail-meta a { color: var(--accent); font-weight: 600; }
.article-content { font-size: 1.05rem; color: #333; text-align: justify; text-justify: inter-word; padding-left: 15px;
    padding-right: 15px;}
.article-content img { border-radius: 8px; margin: 16px 0; box-shadow: var(--shadow-sm); max-width: 100%; height: auto; }
.article-content iframe { width: 100%; aspect-ratio: 16/9; border: 0; border-radius: 6px; margin: 16px 0; }

/* Per-paragraph alignment chosen in the editor overrides the justify default above */
.article-content .ql-align-left { text-align: left; }
.article-content .ql-align-center { text-align: center; }
.article-content .ql-align-right { text-align: right; }
.article-content .ql-align-justify { text-align: justify; }

/* List/paragraph indent levels (matches Quill's own 3em-per-level increments) */
.article-content .ql-indent-1 { padding-left: 3em; }
.article-content .ql-indent-2 { padding-left: 6em; }
.article-content .ql-indent-3 { padding-left: 9em; }
.article-content .ql-indent-4 { padding-left: 12em; }
.article-content .ql-indent-5 { padding-left: 15em; }
.article-content .ql-indent-6 { padding-left: 18em; }
.article-content .ql-indent-7 { padding-left: 21em; }
.article-content .ql-indent-8 { padding-left: 24em; }

/* Font family choices from the editor's "Sans Serif / Serif / Monospace" dropdown */
.article-content .ql-font-serif { font-family: Georgia, 'Times New Roman', serif; }
.article-content .ql-font-monospace { font-family: 'Monaco', 'Courier New', monospace; }

/* Font size choices from the editor's size dropdown (matches Quill's own defaults) */
.article-content .ql-size-small { font-size: .75em; }
.article-content .ql-size-large { font-size: 1.5em; }
.article-content .ql-size-huge { font-size: 2.5em; }

/* Inline images placed between paragraphs of text (item: embed picture mid-article) */
.article-content p img { display: inline-block; vertical-align: middle; }
.article-content blockquote {
  border-left: 4px solid var(--accent); background: #111; color: #fff; padding: 20px 24px; margin: 24px 0; border-radius: 6px;
}
.tag-list { margin: 30px 0; }
.tag-list a { display: inline-block; background: var(--bg-soft); padding: 6px 14px; border-radius: 4px; margin: 0 6px 6px 0; font-size: .85rem; }

.comments-block { margin-top: 40px; border-top: 1px solid var(--border); padding-top: 30px; }
.comment-item { border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; margin-bottom: 14px; }
.comment-item .c-name { font-weight: 700; }
.comment-item .c-date { color: var(--muted); font-size: .8rem; }
.comment-form input, .comment-form textarea {
  width: 100%; padding: 12px; border: 1px solid var(--border); border-radius: 6px; margin-bottom: 12px; font-family: inherit;
}
.comment-form .row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* ---------- Sidebar ---------- */
.sidebar .widget { border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; margin-bottom: 24px; box-shadow: var(--shadow-sm); }
.sidebar .widget h4 { margin-top: 0; border-left: 4px solid var(--accent); padding-left: 10px; }
.search-box { display: flex; }
.search-box input { flex: 1; padding: 10px; border: 1px solid var(--border); border-radius: 4px 0 0 4px; }
.search-box button { background: var(--accent); color: #fff; border: 0; padding: 0 16px; border-radius: 0 4px 4px 0; cursor: pointer; }
.recent-post { display: flex; gap: 10px; margin-bottom: 14px; }
.recent-post img { width: 60px; height: 60px; object-fit: cover; border-radius: 4px; }
.recent-post .rp-title { font-size: .88rem; font-weight: 600; }
.sidebar-ad img { border-radius: 6px; }

/* ---------- Buttons / forms (shared) ---------- */
.btn { display: inline-block; background: var(--accent); color: #fff; padding: 11px 24px; border-radius: 30px; border: 0; font-weight: 700; cursor: pointer; box-shadow: 0 4px 14px rgba(224,52,43,.25); transition: transform .15s, box-shadow .15s; }
.btn:hover { background: var(--accent-dark); transform: translateY(-1px); box-shadow: 0 6px 18px rgba(224,52,43,.3); }
.btn-outline { background: none; border: 2px solid var(--accent); color: var(--accent); }
.subscribe-form { display: flex; }
.subscribe-form input { flex: 1; padding: 10px; border-radius: 4px 0 0 4px; border: 1px solid #444; background: #222; color: #fff; }
.subscribe-form button { background: var(--accent); color: #fff; border: 0; padding: 0 16px; border-radius: 0 4px 4px 0; cursor: pointer; }
.subscribe-msg { font-size: .82rem; margin-top: 6px; }

.alert { padding: 12px 16px; border-radius: 6px; margin-bottom: 18px; font-size: .92rem; }
.alert-success { background: #e7f8ee; color: #14804a; border: 1px solid #b7ebc9; }
.alert-error { background: #fdeaea; color: #b8241c; border: 1px solid #f6c1bd; }

/* ---------- Simple auth forms (login/change password) ---------- */
.auth-wrap { max-width: 420px; margin: 60px auto; padding: 34px; border: 1px solid var(--border); border-radius: var(--radius); }
.auth-wrap h1 { font-size: 1.5rem; margin-top: 0; text-align: center; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 6px; font-size: .9rem; }
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 11px; border: 1px solid var(--border); border-radius: 6px; font-family: inherit; font-size: .95rem;
}
.captcha-box { display: flex; align-items: center; gap: 10px; background: var(--bg-soft); padding: 10px 14px; border-radius: 6px; margin-bottom: 16px; }
.captcha-box .q { font-weight: 700; font-size: 1.1rem; }

/* ---------- WhatsApp / Call CTAs (item 9) ---------- */
.cta-fab-wrap { position: fixed; right: 22px; bottom: 22px; display: flex; flex-direction: column; gap: 12px; z-index: 300; }
.cta-fab {
  width: 54px; height: 54px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  color: #fff; box-shadow: var(--shadow-md); transition: transform .15s;
}
.cta-fab:hover { transform: scale(1.08); }
.cta-fab-whatsapp { background: #25d366; }
.cta-fab-call { background: var(--accent); }

.footer-cta-row { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.footer-cta-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 9px 16px; border-radius: 20px;
  font-size: .82rem; font-weight: 700; color: #fff !important;
}
.footer-cta-whatsapp { background: #25d366; }
.footer-cta-call { background: var(--accent); }
.footer-cta-btn:hover { opacity: .9; }

.footer-staff-links { margin-top: 6px; }
.footer-staff-links a { display: inline; color: #9a9ba5; margin: 0; }
.footer-staff-links a:hover { color: #fff; }
/* ---------- Footer ---------- */
.site-footer { background: #16171a; color: #cfd2d8; margin-top: 40px; }
.footer-inner { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; padding: 50px 20px; }
.footer-col h3, .footer-col h4 { color: #fff; }
.footer-col a { display: block; color: #cfd2d8; margin-bottom: 8px; }
.footer-col a:hover { color: var(--accent); }
.footer-bottom { text-align: center; padding: 16px; border-top: 1px solid #2a2b30; font-size: .82rem; }

/* ---------- Responsive breakpoints ---------- */
@media (max-width: 992px) {
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .detail-wrap { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .home-blog-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .nav-toggle { display: flex; }
  .main-nav {
    display: none; flex-direction: column; align-items: flex-start; width: 100%;
    position: absolute; top: 100%; left: 0; background: #fff; border-bottom: 1px solid var(--border); padding: 14px 20px;
  }
  .main-nav.open { display: flex; }
  .nav-search-wrap { width: 100%; margin-left: 0; order: 99; }
  .nav-search-wrap input, .nav-search-wrap input:focus { width: 100%; }
  #navSearchResults { width: 100%; }
  .blog-grid { grid-template-columns: 1fr; }
  .home-blog-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; }
  .comment-form .row2 { grid-template-columns: 1fr; }
  .page-banner h1 { font-size: 1.6rem; }
  .cta-fab-wrap { right: 14px; bottom: 14px; gap: 10px; }
  .cta-fab { width: 46px; height: 46px; }
  .filter-row-center { justify-content: flex-start; }
}
