/* ==========================================================================
   Kokani Mewaa — content.css
   Typography and components for article + policy pages.
   Loads AFTER styles.css and reuses its mango palette variables
   (--m1 --m2 --m3 --leaf --ink --muted --card --border --shadow --radius).
   The homepage is untouched by this file.
   ========================================================================== */

/* ---------- Page shell ----------
   Content pages use .contentWrap (NOT <section>) so the homepage's
   nth-of-type background alternation never applies here. */

.contentWrap {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 16px 64px;
}

.contentWrap.wide { max-width: 1120px; }

/* Soft paper panel so long text stays readable over the mango gradient */
.paper {
  background: rgba(255, 255, 255, .78);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 34px 38px 40px;
  margin-top: 18px;
  backdrop-filter: blur(6px);
}

/* ---------- Breadcrumb ---------- */
.crumb {
  padding: 18px 0 0;
  font-size: 13px;
  font-weight: 800;
  color: rgba(45, 34, 0, .58);
}
.crumb a { color: rgba(45, 34, 0, .70); }
.crumb a:hover { color: var(--m3); text-decoration: underline; }
.crumb .sep { margin: 0 7px; opacity: .5; }

/* ---------- Article typography ---------- */
.paper h1 {
  margin: 0 0 12px;
  font-size: clamp(26px, 3.4vw, 40px);
  line-height: 1.14;
  letter-spacing: -0.4px;
}

.postMeta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 800;
  color: rgba(45, 34, 0, .60);
  padding-bottom: 20px;
  margin-bottom: 26px;
  border-bottom: 1px dashed rgba(45, 34, 0, .16);
}
.postMeta .dot { opacity: .45; }

.lede {
  font-size: 18px;
  line-height: 1.62;
  color: rgba(45, 34, 0, .80);
  font-weight: 600;
  margin: 0 0 26px;
}

.paper h2 {
  margin: 46px 0 14px;
  font-size: clamp(21px, 2.4vw, 27px);
  line-height: 1.25;
  letter-spacing: -0.2px;
  position: relative;
  padding-left: 16px;
}
.paper h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: .18em;
  bottom: .18em;
  width: 5px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--m2), var(--m3));
}

.paper h3 {
  margin: 30px 0 8px;
  font-size: 18px;
  font-weight: 900;
  color: rgba(45, 34, 0, .92);
}

.paper p {
  margin: 0 0 18px;
  line-height: 1.75;
  color: rgba(45, 34, 0, .84);
}

.paper a {
  color: #b35c00;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: rgba(251, 133, 0, .35);
  text-underline-offset: 3px;
}
.paper a:hover {
  color: var(--m3);
  text-decoration-color: var(--m3);
}

.paper ul, .paper ol {
  margin: 0 0 20px;
  padding-left: 22px;
  line-height: 1.72;
  color: rgba(45, 34, 0, .84);
}
.paper li { margin-bottom: 9px; }
.paper li::marker { color: var(--m3); font-weight: 900; }

.paper strong { font-weight: 900; color: rgba(45, 34, 0, .95); }

.paper blockquote {
  margin: 28px 0;
  padding: 16px 20px;
  border-left: 4px solid var(--leaf);
  background: rgba(42, 157, 143, .07);
  border-radius: 0 14px 14px 0;
  color: rgba(45, 34, 0, .78);
  font-style: italic;
}
.paper blockquote p:last-child { margin-bottom: 0; }

/* ---------- Callouts ---------- */
.note, .tip {
  border-radius: var(--radius);
  padding: 18px 22px;
  margin: 28px 0;
  border: 1px solid var(--border);
  box-shadow: 0 10px 30px rgba(45, 34, 0, .06);
}
.note {
  background: linear-gradient(135deg, rgba(255, 209, 102, .30), rgba(255, 183, 3, .16));
  border-color: rgba(251, 133, 0, .22);
}
.tip {
  background: linear-gradient(135deg, rgba(42, 157, 143, .14), rgba(42, 157, 143, .06));
  border-color: rgba(42, 157, 143, .22);
}
.note p:last-child, .tip p:last-child { margin-bottom: 0; }
.note strong { color: #a35400; }
.tip strong { color: #1d6f66; }

/* ---------- Tables ---------- */
.table-scroll {
  overflow-x: auto;
  margin: 28px 0;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  -webkit-overflow-scrolling: touch;
}
.paper table {
  width: 100%;
  min-width: 480px;
  border-collapse: collapse;
  background: rgba(255, 255, 255, .90);
  font-size: 14.5px;
}
.paper thead th {
  background: linear-gradient(135deg, var(--m2), var(--m3));
  color: #fff;
  font-weight: 900;
  text-align: left;
  padding: 13px 16px;
  font-size: 13px;
  letter-spacing: .2px;
  white-space: nowrap;
}
.paper tbody td {
  padding: 13px 16px;
  border-bottom: 1px solid rgba(45, 34, 0, .08);
  vertical-align: top;
  line-height: 1.55;
  color: rgba(45, 34, 0, .82);
}
.paper tbody tr:nth-child(even) td { background: rgba(255, 247, 204, .40); }
.paper tbody tr:last-child td { border-bottom: none; }

/* ---------- FAQ (extends the theme's details styling) ---------- */
.paper .faq { display: grid; gap: 12px; margin: 26px 0 10px; }
.paper .faq details {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .70);
  box-shadow: 0 10px 30px rgba(45, 34, 0, .06);
  padding: 0;
}
.paper .faq summary {
  cursor: pointer;
  font-weight: 900;
  padding: 15px 48px 15px 18px;
  position: relative;
  list-style: none;
  line-height: 1.45;
}
.paper .faq summary::-webkit-details-marker { display: none; }
.paper .faq summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255, 183, 3, .55), rgba(251, 133, 0, .40));
  font-size: 17px;
  font-weight: 700;
}
.paper .faq details[open] summary::after { content: "\2212"; }
.paper .faq details > div { padding: 0 18px 16px; }
.paper .faq details > div p { margin: 0 0 12px; color: rgba(45, 34, 0, .76); }
.paper .faq details > div p:last-child { margin-bottom: 0; }

/* ---------- Related posts ---------- */
.related {
  margin: 46px 0 0;
  padding: 20px 22px;
  border-radius: var(--radius);
  background: rgba(255, 247, 204, .55);
  border: 1px solid var(--border);
}
.related h3 { margin: 0 0 12px; font-size: 15px; text-transform: uppercase; letter-spacing: .08em; }
.related ul { margin: 0; padding-left: 20px; }
.related li { margin-bottom: 8px; }

/* ---------- In-content CTA ---------- */
.ctaBox {
  margin: 46px 0 4px;
  padding: 28px 26px;
  border-radius: var(--radius);
  text-align: center;
  border: 1px solid rgba(251, 133, 0, .22);
  background:
    radial-gradient(600px 320px at 20% 20%, rgba(255, 255, 255, .85), transparent 60%),
    linear-gradient(135deg, rgba(255, 224, 102, .70), rgba(255, 183, 3, .45), rgba(42, 157, 143, .12));
  box-shadow: var(--shadow);
}
.ctaBox h3 { margin: 0 0 8px; font-size: 21px; }
.ctaBox p { margin: 0 auto 18px; max-width: 52ch; color: rgba(45, 34, 0, .78); }
.ctaBox .ctaRow { justify-content: center; }

/* ---------- Guide index cards ---------- */
.guideGrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
  margin: 28px 0 14px;
}
.guideCard {
  display: flex;
  flex-direction: column;
  padding: 22px 22px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, .82);
  box-shadow: var(--shadow);
  transition: transform .12s ease, box-shadow .2s ease;
}
.guideCard:hover {
  transform: translateY(-3px);
  box-shadow: 0 24px 65px rgba(45, 34, 0, .16);
}
.guideCard .tag { margin-bottom: 10px; }
.guideCard h3 { margin: 0 0 10px; font-size: 17px; line-height: 1.38; }
.guideCard h3 a { text-decoration: none; color: var(--ink); }
.guideCard h3 a:hover { color: var(--m3); }
.guideCard p {
  margin: 0 0 16px;
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--muted);
}
.guideCard .readMore {
  margin-top: auto;
  font-weight: 900;
  font-size: 13.5px;
  color: #b35c00;
  text-decoration: none;
}
.guideCard .readMore:hover { text-decoration: underline; }

/* ---------- Site footer (shared across all pages) ---------- */
.siteFooter {
  border-top: 1px solid rgba(45, 34, 0, .12);
  background: rgba(255, 255, 255, .55);
  backdrop-filter: blur(6px);
  padding: 40px 0 24px;
  margin-top: 10px;
}
.footerCols {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 28px;
}
.footerCols h4 {
  margin: 0 0 14px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .1em;
  font-weight: 1000;
  color: rgba(45, 34, 0, .60);
}
.footerCols ul { list-style: none; margin: 0; padding: 0; }
.footerCols li { margin-bottom: 9px; }
.footerCols a {
  font-weight: 800;
  font-size: 14px;
  color: rgba(45, 34, 0, .78);
}
.footerCols a:hover { color: var(--m3); text-decoration: underline; }
.footerBrand img { width: 96px; height: auto; margin-bottom: 10px; }
.footerBrand p {
  margin: 0 0 10px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
  font-weight: 600;
  max-width: 34ch;
}
.footerBase {
  margin-top: 30px;
  padding-top: 18px;
  border-top: 1px solid rgba(45, 34, 0, .10);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 13px;
  font-weight: 800;
  color: rgba(45, 34, 0, .62);
}

/* ---------- Page header tweaks for content pages ---------- */
.pageHeadBand {
  padding: 26px 0 6px;
  background:
    radial-gradient(700px 300px at 20% 0%, rgba(255, 255, 255, .70), transparent 60%),
    linear-gradient(180deg, rgba(255, 224, 102, .45), rgba(255, 224, 102, 0));
}

/* ---------- Responsive ---------- */
@media (max-width: 940px) {
  .footerCols { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  .paper { padding: 24px 20px 28px; border-radius: 16px; }
  .paper h2 { padding-left: 13px; }
  .lede { font-size: 16.5px; }
  .paper p, .paper li { font-size: 15.5px; }
  .footerCols { grid-template-columns: 1fr; gap: 22px; }
  .guideGrid { grid-template-columns: 1fr; }
}

@media print {
  header, .siteFooter, .ctaBox, .related, .floatingWA, .crumb { display: none !important; }
  body { background: #fff; }
  .paper { box-shadow: none; border: none; background: #fff; padding: 0; }
}

/* ---------- Active nav state (shared across all pages) ---------- */
.navlinks a[aria-current="page"] {
  background: rgba(251, 133, 0, .14);
  box-shadow: inset 0 -2px 0 var(--m3);
}
.menuPanelInner a[aria-current="page"] {
  background: rgba(251, 133, 0, .16);
  box-shadow: inset 0 0 0 1px rgba(251, 133, 0, .30);
}

/* ---------- Article hero image ---------- */
.postHero {
  margin: 0 0 26px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  background: rgba(255, 255, 255, .55);
  position: relative;
}
.postHero img {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: center;
  display: block;
}
.postHero figcaption {
  padding: 10px 16px 12px;
  font-size: 12.5px;
  font-weight: 800;
  line-height: 1.5;
  color: rgba(45, 34, 0, .62);
  background: rgba(255, 247, 204, .55);
  border-top: 1px solid var(--border);
}

/* ---------- Guide card thumbnails ---------- */
.guideCard { padding: 0; overflow: hidden; }
.guideCard .guideThumb {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, .55);
}
.guideCard .guideThumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform .3s ease;
}
.guideCard:hover .guideThumb img { transform: scale(1.04); }
.guideCard .guideBody {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  padding: 18px 20px 20px;
}
.guideCard .guideBody > .tag { margin-bottom: 10px; }

@media (max-width: 760px) {
  .postHero img { aspect-ratio: 4 / 3; }
}

@media print {
  .postHero { display: none !important; }
}

/* ---------- Build-time reminder: EMAIL is still blank in build.py ---------- */
.needsEmail {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 8px;
  background: rgba(251, 133, 0, .18);
  border: 1px dashed var(--m3);
  color: #a35400;
  font-size: 13px;
}

/* ---------- Logo sizing ----------
   logo-400.png is the artwork cropped free of the transparent padding that made
   the original render tiny, so the same markup now shows a much larger mark.
   These override the .logo rule in styles.css, which stays untouched. */
header .brand img.logo {
  width: 168px;
  height: 87px;
  border-radius: 0;
}
.footerBrand img { width: 190px; height: auto; }

@media (max-width: 940px) {
  header .brand img.logo { width: 150px; height: 78px; }
}

@media (max-width: 760px) {
  header .brand img.logo { width: 138px; height: 71px; }
  .footerBrand img { width: 170px; }
}
