/*
Theme Name: BD345 Bengali Guide pNVgSpCm
Theme URI: https://bd345.uno/
Author: BD345 বাংলা গাইড
Description: Bright mobile-first editorial theme for the independent BD345 Bengali guide.
Version: 1.0.1
Text Domain: bd345-guide
*/

:root {
  --page: #f3f7f6;
  --surface: #ffffff;
  --soft: #e7f3ef;
  --ink: #142b2a;
  --muted: #637572;
  --deep: #123c3a;
  --accent: #167d72;
  --violet: #6d5bd0;
  --gold: #f0b84a;
  --border: #d3e3df;
  --info: #e8f4fa;
  --focus: #5a46c8;
  --shadow: 0 14px 34px rgba(20,70,65,.10);
  --radius: 18px;
  --wrap: 1140px;
  --measure: 780px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: "Noto Sans Bengali", "Hind Siliguri", "Nirmala UI", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.72;
  overflow-wrap: anywhere;
}
body.menu-open { overflow: hidden; }
a { color: #0f695f; text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--violet); }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
img { display: block; max-width: 100%; height: auto; }
.trp-floating-switcher { display: none !important; }

.skip-link { position: fixed; left: 12px; top: -100px; z-index: 9999; padding: 12px 16px; background: #fff; color: #111; border-radius: 8px; }
.skip-link:focus { top: 12px; }
.site-header { position: relative; z-index: 20; background: rgba(255,255,255,.97); border-bottom: 1px solid var(--border); }
.header-inner { max-width: var(--wrap); min-height: 68px; margin: auto; padding: 8px 24px; display: flex; align-items: center; gap: 22px; }
.brand { flex: 0 0 auto; line-height: 0; }
.custom-logo { width: auto; height: 48px; max-width: 260px; object-fit: contain; }
.brand-fallback { color: var(--deep); font-size: 22px; font-weight: 800; text-decoration: none; line-height: 1.2; }
.menu-toggle { display: none; margin-left: auto; min-width: 48px; min-height: 48px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); color: var(--deep); font: inherit; font-weight: 800; cursor: pointer; }
.primary-nav { margin-left: auto; min-width: 0; }
.primary-nav ul { display: flex; align-items: center; justify-content: flex-end; gap: 3px; margin: 0; padding: 0; list-style: none; }
.primary-nav a { display: flex; align-items: center; min-height: 44px; padding: 7px 10px; border-radius: 10px; color: var(--deep); font-size: 14px; font-weight: 750; text-decoration: none; white-space: nowrap; }
.primary-nav a:hover, .primary-nav .current-menu-item a { background: var(--soft); color: #0b5a52; }

.site-main { min-height: 55vh; }
.article-shell { max-width: var(--wrap); margin: 0 auto; padding: 56px 24px 80px; }
.article { max-width: var(--measure); margin: 0 auto; }
.article h1 { margin: 0 0 22px; color: var(--deep); font-size: clamp(38px, 5.5vw, 66px); line-height: 1.08; letter-spacing: -.035em; }
.article h2 { scroll-margin-top: 22px; margin: 70px 0 18px; color: var(--deep); font-size: clamp(28px, 3.6vw, 42px); line-height: 1.18; letter-spacing: -.02em; }
.article h2::before { content: ""; display: block; width: 54px; height: 6px; margin-bottom: 15px; border-radius: 9px; background: linear-gradient(90deg, var(--accent), var(--gold)); }
.article h3 { margin: 38px 0 13px; color: #155e57; font-size: 24px; line-height: 1.3; }
.article p { margin: 0 0 22px; }
.article > p:first-of-type { font-size: 20px; line-height: 1.66; color: #264a47; }
.article strong { color: #0e4b46; }
.article code { padding: .12em .34em; border-radius: 5px; background: var(--soft); color: #3c357a; font-family: ui-monospace, monospace; font-size: .88em; }
.article ul, .article ol { margin: 18px 0 28px; padding-inline-start: 28px; }
.article li { margin: 9px 0; padding-inline-start: 5px; }
.article blockquote { margin: 30px 0; padding: 20px 24px; border-inline-start: 5px solid var(--violet); border-radius: 0 var(--radius) var(--radius) 0; background: #f0eefc; }
.article table { width: 100%; border-collapse: collapse; margin: 26px 0 34px; background: #fff; box-shadow: var(--shadow); }
.article th, .article td { padding: 14px 16px; border: 1px solid var(--border); text-align: start; vertical-align: top; }
.article th { background: var(--deep); color: #fff; }
.table-scroll { max-width: 100%; overflow-x: auto; border-radius: var(--radius); box-shadow: var(--shadow); }
.table-scroll table { min-width: 660px; margin: 0; box-shadow: none; }

.home-article { max-width: none; }
.home-article > *:not(.editorial-figure):not(.hero-actions) { max-width: var(--measure); margin-left: auto; margin-right: auto; }
.home-article h1 { max-width: 940px; padding-top: 20px; text-align: center; }
.home-article > p:first-of-type, .home-article > p:nth-of-type(2) { max-width: 860px; text-align: center; }
.hero-actions { display: flex; justify-content: center; gap: 12px; max-width: 860px; margin: 26px auto 34px; }
.button-link { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 10px 18px; border-radius: 14px; background: var(--accent); color: #fff; font-weight: 800; text-decoration: none; box-shadow: var(--shadow); }
.button-link.secondary { background: var(--violet); }
.button-link:hover { color: #fff; filter: brightness(.94); }
.editorial-figure { width: min(100%, 1020px); margin: 35px auto 56px; overflow: hidden; border-radius: 24px; background: var(--deep); box-shadow: var(--shadow); }
.editorial-figure img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.editorial-figure.hero-image img { aspect-ratio: 16 / 9; }
.editorial-figure figcaption { padding: 12px 18px 14px; color: #d9ebe8; font-size: 14px; }
.home-article h2:nth-of-type(3n+1) { padding: 34px 38px 0; max-width: 860px; border-radius: var(--radius) var(--radius) 0 0; background: var(--soft); }

.faq-list { max-width: var(--measure); margin: 38px auto 0; }
.faq-list h2 { margin-top: 0; }
.faq-item { margin: 12px 0; border: 1px solid var(--border); border-radius: 15px; background: #fff; box-shadow: 0 8px 22px rgba(20,70,65,.06); }
.faq-item summary { min-height: 54px; padding: 15px 48px 15px 18px; cursor: pointer; color: var(--deep); font-weight: 800; list-style-position: outside; }
.faq-answer { padding: 0 18px 18px; }
.faq-answer p:last-child { margin-bottom: 0; }

.breadcrumb { max-width: var(--wrap); margin: 0 auto; padding: 20px 24px 0; color: var(--muted); font-size: 14px; }
.breadcrumb a { color: var(--muted); }
.site-footer { background: var(--deep); color: #d9ebe8; }
.footer-inner { max-width: var(--wrap); margin: auto; padding: 46px 24px; display: grid; grid-template-columns: 1.25fr 1fr; gap: 38px; }
.site-footer h2 { margin: 0 0 12px; color: #fff; font-size: 24px; }
.site-footer p { margin: 0 0 12px; }
.site-footer a { color: #fff; }
.trust-links { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 7px 18px; margin: 0; padding: 0; list-style: none; }

@media (max-width: 1040px) {
  .header-inner { min-height: 58px; padding: 5px 16px; }
  .custom-logo { height: 44px; max-width: 230px; }
  .menu-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .primary-nav { position: fixed; inset: 58px 0 0; display: none; padding: 20px 16px 40px; overflow-y: auto; background: #f7fbfa; }
  .primary-nav.is-open { display: block; }
  .primary-nav ul { display: block; }
  .primary-nav li + li { margin-top: 7px; }
  .primary-nav a { min-height: 50px; padding: 12px 15px; background: #fff; border: 1px solid var(--border); font-size: 16px; white-space: normal; }
}

@media (max-width: 600px) {
  body { font-size: 16px; }
  .article-shell { padding: 38px 16px 58px; }
  .article h1 { font-size: clamp(34px, 10.5vw, 42px); }
  .article h2 { margin-top: 48px; font-size: 29px; }
  .article h3 { font-size: 22px; }
  .article > p:first-of-type { font-size: 18px; }
  .home-article h1 { text-align: start; }
  .home-article > p:first-of-type, .home-article > p:nth-of-type(2) { text-align: start; }
  .hero-actions { display: grid; }
  .button-link { width: 100%; }
  .editorial-figure { margin: 28px auto 42px; border-radius: 14px; }
  .editorial-figure img, .editorial-figure.hero-image img { aspect-ratio: 4 / 3; }
  .home-article h2:nth-of-type(3n+1) { padding: 24px 20px 0; }
  .footer-inner { grid-template-columns: 1fr; padding: 38px 16px; }
  .trust-links { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
