/* =============================================================
   Caribbean Social Studies — Post/Article & Page Styles
   assets/css/post.css
   Covers: custom nav, white article theme, mobile optimization
   ============================================================= */

/* ── CUSTOM SITE-WIDE NAV ───────────────────────────────────── */
.css-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 300;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(8, 12, 20, 0.08);
  box-shadow: 0 1px 12px rgba(0,0,0,.06);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  padding: 0 clamp(20px, 4vw, 64px);
  height: 54px;
}

.css-nav-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
}

.css-nav-badge {
  background: #00F060;
  color: #0a1628;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: .04em;
  flex-shrink: 0;
}

.css-nav-name {
  font-size: 11px;
  font-weight: 400;
  color: rgba(8, 12, 20, 0.45);
  line-height: 1.3;
}

.css-nav-logo a {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.css-nav-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(12px, 1.8vw, 26px);
}

.css-nl {
  font-size: 11px;
  color: rgba(8, 12, 20, 0.5);
  text-decoration: none;
  letter-spacing: .05em;
  text-transform: uppercase;
  transition: color .2s;
  white-space: nowrap;
}

.css-nl:hover,
.css-nl-active {
  color: #080C14;
}

.css-nav-mobile-actions {
  display: none;
}

.css-nav-r {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-end;
}

.css-n-si {
  font-size: 11px;
  color: rgba(8, 12, 20, 0.45);
  text-decoration: none;
  letter-spacing: .05em;
  text-transform: uppercase;
  transition: color .2s;
  white-space: nowrap;
}

.css-n-si:hover { color: #080C14; }

.css-n-sub {
  background: #FF0090;
  color: #fff;
  border: none;
  padding: 6px 18px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: .03em;
  transition: transform .22s cubic-bezier(.16,1,.3,1);
  font-family: inherit;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

.css-n-sub:hover { transform: scale(1.05); color: #fff; }

/* Hamburger button */
.css-nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  width: 36px;
  height: 36px;
  border-radius: 4px;
  flex-shrink: 0;
}

.css-nav-burger span {
  display: block;
  height: 1.5px;
  background: #080C14;
  border-radius: 2px;
  transition: all .28s cubic-bezier(.16,1,.3,1);
  transform-origin: center;
}

/* Burger → X animation */
.css-nav-burger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.css-nav-burger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.css-nav-burger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ── PREVENT HORIZONTAL SCROLL ──────────────────────────── */
html, body { overflow-x: hidden; max-width: 100%; }

/* ── GHOST DEFAULT NAV HIDE (replaced by css-nav) ─────────── */
.gh-navigation { display: none !important; }

/* ── ARTICLE PAGE — WHITE THEME ────────────────────────────── */
body.post-template,
body.page-template {
  background: #fff;
  color: #1a1a2e;
}

/* Offset fixed nav */
body.post-template .gh-viewport,
body.page-template .gh-viewport {
  padding-top: 54px;
}

body.post-template .gh-main,
body.page-template .gh-main {
  background: #fff;
}

body.post-template .gh-article,
body.page-template .gh-article {
  background: #fff;
}

/* Article header */
body.post-template .gh-article-header,
body.page-template .gh-article-header {
  color: #080C14;
}

body.post-template .gh-article-title,
body.page-template .gh-article-title {
  color: #080C14;
}

body.post-template .gh-article-excerpt,
body.page-template .gh-article-excerpt {
  color: rgba(8, 12, 20, 0.6);
}

body.post-template .gh-article-meta,
body.post-template .gh-article-authors,
body.page-template .gh-article-meta {
  color: rgba(8, 12, 20, 0.48);
}

/* Author — name only, no avatar or date */
body.post-template .gh-article-author-image,
body.page-template .gh-article-author-image {
  display: none;
}

body.post-template .gh-article-meta-content,
body.page-template .gh-article-meta-content {
  display: none;
}

body.post-template .gh-article-author-name,
body.page-template .gh-article-author-name {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
  color: rgba(8, 12, 20, 0.55);
}

body.post-template .bull,
body.page-template .bull {
  color: rgba(8, 12, 20, 0.3);
}

/* Body copy */
body.post-template .gh-content,
body.page-template .gh-content {
  color: #2a2a3e;
}

body.post-template .gh-content p,
body.page-template .gh-content p {
  color: rgba(8, 12, 20, 0.78);
  line-height: 1.85;
}

body.post-template .gh-content h1,
body.post-template .gh-content h2,
body.post-template .gh-content h3,
body.post-template .gh-content h4,
body.post-template .gh-content h5,
body.post-template .gh-content h6,
body.page-template .gh-content h1,
body.page-template .gh-content h2,
body.page-template .gh-content h3 {
  color: #080C14;
}

body.post-template .gh-content a,
body.page-template .gh-content a {
  color: #FF0090;
}

body.post-template .gh-content a:hover,
body.page-template .gh-content a:hover {
  color: #cc007a;
}

body.post-template .gh-content blockquote,
body.page-template .gh-content blockquote {
  border-left-color: #FF0090;
  color: rgba(8, 12, 20, 0.65);
}

body.post-template .gh-content hr,
body.page-template .gh-content hr {
  border-color: rgba(8, 12, 20, 0.1);
}

/* Tags */
body.post-template .gh-tags a,
body.page-template .gh-tags a {
  background: rgba(8, 12, 20, 0.06);
  color: rgba(8, 12, 20, 0.55);
  border: 1px solid rgba(8, 12, 20, 0.1);
}

/* Read more section */
body.post-template .gh-container,
body.page-template .gh-container {
  background: #fff;
}

body.post-template .gh-container-title,
body.page-template .gh-container-title {
  color: #080C14;
}

body.post-template .gh-feed .gh-card-title,
body.post-template .gh-feed .gh-card-excerpt,
body.post-template .gh-feed .gh-card-meta,
body.page-template .gh-feed .gh-card-title,
body.page-template .gh-feed .gh-card-excerpt,
body.page-template .gh-feed .gh-card-meta {
  color: #080C14;
}

body.post-template .gh-feed .gh-card-excerpt,
body.page-template .gh-feed .gh-card-excerpt {
  color: rgba(8, 12, 20, 0.6);
}

body.post-template .gh-feed .gh-card-meta,
body.page-template .gh-feed .gh-card-meta {
  color: rgba(8, 12, 20, 0.45);
}

/* Post nav prev/next */
body.post-template .gh-navigation-previous,
body.post-template .gh-navigation-next {
  background: #f5f5f8;
  color: #080C14;
}

body.post-template .gh-navigation-title {
  color: #080C14;
}

/* Footer — dark navy background, white text */
body.post-template .gh-footer,
body.post-template footer.gh-footer,
body.page-template .gh-footer {
  background: #0e0c22;
  border-top: none;
  color: rgba(255, 255, 255, 0.6);
}

body.post-template .gh-footer a,
body.page-template .gh-footer a {
  color: rgba(255, 255, 255, 0.6);
}

body.post-template .gh-footer a:hover,
body.page-template .gh-footer a:hover {
  color: #fff;
}

body.post-template .gh-footer p,
body.post-template .gh-footer span,
body.post-template .gh-footer div,
body.page-template .gh-footer p,
body.page-template .gh-footer span,
body.page-template .gh-footer div {
  color: rgba(255, 255, 255, 0.6);
}

/* Accent variable */
body.post-template,
body.page-template {
  --ghost-accent-color: #FF0090;
}

/* ── MOBILE NAV (≤ 900px) ───────────────────────────────────── */
@media (max-width: 900px) {
  .css-nav {
    grid-template-columns: 1fr auto;
  }

  .css-nav-links {
    display: none;
    position: fixed;
    top: 54px; left: 0; right: 0; bottom: 0;
    background: rgba(255, 255, 255, 0.99);
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    padding: 24px clamp(20px, 5vw, 48px) 40px;
    gap: 0;
    overflow-y: auto;
    z-index: 299;
    border-top: 1px solid rgba(8, 12, 20, 0.08);
  }

  .css-nav-links.open {
    display: flex;
  }

  .css-nl {
    font-size: 15px;
    padding: 14px 0;
    border-bottom: 1px solid rgba(8, 12, 20, 0.07);
    width: 100%;
    color: #080C14;
    letter-spacing: .03em;
  }

  .css-nl:last-of-type {
    border-bottom: none;
  }

  .css-nav-mobile-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 24px;
    width: 100%;
    padding-top: 20px;
    border-top: 1px solid rgba(8, 12, 20, 0.08);
  }

  .css-nav-sub-mobile {
    display: inline-block;
    background: #FF0090;
    color: #fff !important;
    padding: 12px 24px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    text-align: center;
    text-transform: none;
    letter-spacing: .02em;
    border-bottom: none !important;
  }

  .css-nav-burger { display: flex; }
  .css-n-si { display: none; }
  .css-n-sub { display: none; }
}

@media (max-width: 600px) {
  .css-nav {
    padding: 0 16px;
    height: 52px;
  }

  body.post-template .gh-viewport,
  body.page-template .gh-viewport {
    padding-top: 52px;
  }

  .css-nav-links {
    top: 52px;
  }
}

/* ── MOBILE: ARTICLE CONTENT ────────────────────────────────── */
@media (max-width: 600px) {
  body.post-template .gh-article-header,
  body.page-template .gh-article-header {
    padding-left: 20px;
    padding-right: 20px;
  }

  body.post-template .gh-article-title,
  body.page-template .gh-article-title {
    font-size: clamp(26px, 7vw, 42px) !important;
  }

  body.post-template .gh-content.gh-canvas,
  body.page-template .gh-content.gh-canvas {
    padding-left: 20px;
    padding-right: 20px;
  }

  body.post-template .gh-content p,
  body.page-template .gh-content p {
    font-size: 16px;
  }
}

/* ── FOOTER LOGO — preserve aspect ratio ─────────────────── */
body.post-template .gh-footer-logo img,
body.page-template .gh-footer-logo img {
  max-height: 40px;
  width: auto;
  object-fit: contain;
}

/* ── FOOTER SIGNUP BUTTON ─────────────────────────────────── */
body.post-template .gh-footer .gh-button,
body.page-template .gh-footer .gh-button {
  background-color: #FF0090 !important;
  color: #fff !important;
  border-radius: 100px !important;
}
