/* ==========================================================================
   Pollab design kit - blog.css
   Blog chrome and content: minimal blog navbar (language pill + 3-dot
   menu), listing cards, article pages, taxonomy/archive pages.
   Requires base.css.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Blog
   -------------------------------------------------------------------------- */

/* Blog header: logo + wordmark, no nav links */
.navbar-blog .navbar-inner {
  gap: 16px;
}

.blog-mark {
  font-family: "Lora", ui-serif, Georgia, serif;
  font-size: 1.15rem;
  color: var(--ink);
  line-height: 1;
  padding-left: 16px;
  border-left: 1px solid var(--line);
}

.navbar-blog .nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Blog navbar chrome: language picker + 3-dot overflow menu (both sizes). */
.nav-lang,
.nav-menu {
  position: relative;
}

.nav-lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--btn-line);
  background: transparent;
  color: var(--ink);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  transition: border-color var(--fast) var(--ease), color var(--fast) var(--ease);
}

.nav-lang-toggle:hover,
.nav-lang.open .nav-lang-toggle {
  border-color: var(--gold);
  color: var(--gold-text);
}

.nav-lang-chev {
  width: 15px;
  height: 15px;
  transition: transform var(--fast) var(--ease);
}

.nav-lang.open .nav-lang-chev {
  transform: rotate(180deg);
}

.nav-menu-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background-color var(--fast) var(--ease);
}

.nav-menu-btn:hover,
.nav-menu.open .nav-menu-btn {
  background-color: var(--surface-alt);
}

.nav-menu-btn .icon {
  width: 20px;
  height: 20px;
}

.nav-lang-list,
.nav-menu-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 172px;
  background-color: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-1);
  padding: 8px;
  display: grid;
  gap: 2px;
  z-index: 60;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition:
    opacity var(--fast) var(--ease),
    visibility var(--fast) var(--ease),
    transform var(--fast) var(--ease);
}

.nav-lang.open .nav-lang-list,
.nav-menu.open .nav-menu-panel {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.nav-lang-list button,
.nav-menu-panel a {
  display: block;
  width: 100%;
  text-align: left;
  padding: 9px 13px;
  border-radius: 9px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-2);
  background: transparent;
  border: 0;
  cursor: pointer;
  font-family: inherit;
}

.nav-lang-list button:hover,
.nav-menu-panel a:hover {
  background-color: var(--surface-alt);
  color: var(--ink);
}

.nav-lang-opt.is-active {
  color: var(--gold-text);
  font-weight: 600;
}

/* On phones tighten the whole blog header so the brand never compresses. */
@media (max-width: 600px) {
  .navbar-blog .navbar-inner {
    gap: 8px;
  }

  .navbar-blog .nav-actions {
    gap: 6px;
  }

  /* Keep the logo at its natural size - never squeezed by the controls. */
  .navbar-blog .navbar-inner > a:first-child {
    flex: none;
  }

  .navbar-blog .nav-logo-img {
    height: 26px;
    flex: none;
  }

  .blog-mark {
    padding-left: 9px;
    font-size: 0.98rem;
  }

  .nav-lang-toggle {
    padding: 6px 10px;
    font-size: 0.82rem;
    gap: 4px;
  }

  .nav-lang-chev {
    width: 13px;
    height: 13px;
  }

  .nav-menu-btn {
    width: 34px;
    height: 34px;
  }

  .nav-menu-btn .icon {
    width: 18px;
    height: 18px;
  }
}

/* Listing: featured post */
.post-feature {
  display: grid;
  gap: 0;
  overflow: hidden;
  text-align: left;
}

@media (min-width: 1024px) {
  .post-feature {
    grid-template-columns: 7fr 5fr;
    align-items: stretch;
  }
}

.post-feature .pf-img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 280px;
  object-fit: cover;
}

.post-feature .pf-body {
  padding: clamp(24px, 3.5vw, 44px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.post-feature h2 {
  font-size: clamp(1.5rem, 2.6vw, 2.1rem);
  margin: 10px 0 12px;
}

.post-feature h2 a:hover {
  color: var(--gold-text);
}

/* Listing: card grid */
.post-grid {
  display: grid;
  gap: 24px;
  margin-top: 28px;
}

@media (min-width: 640px) {
  .post-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1024px) {
  .post-grid {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

.post-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  text-align: left;
  transition: border-color var(--fast) var(--ease);
}

.post-card:hover {
  border-color: var(--gold);
}

.post-card .pc-img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

.post-card .pc-body {
  padding: 20px 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.post-card h3 {
  font-size: 1.15rem;
  margin: 0;
  line-height: 1.35;
}

.post-card h3 a:hover {
  color: var(--gold-text);
}

.post-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--ink-2);
}

/* .post-cat (category chip) is shared with pulse and lives in base.css */

.post-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--ink-3);
  margin-top: auto;
}

/* Article page */
.post-head {
  padding-block: clamp(44px, 6vw, 72px) 28px;
  text-align: center;
}

/* Blog listing + article pages: tighten the gap under the sticky navbar so
   the eyebrow / category text sits closer to the top on all screens. */
.page-blog .page-hero {
  padding-top: clamp(24px, 3.5vw, 40px);
}

.page-blog .post-head {
  padding-top: clamp(20px, 3vw, 34px);
}

/* Archive page: browse-by-category / tag blocks + chronological list. */
.archive-block {
  padding-bottom: clamp(28px, 4vw, 44px);
}

.archive-h {
  font-size: 1.15rem;
  margin-bottom: 16px;
}

.archive-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.archive-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 15px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--ink);
  transition: border-color var(--fast) var(--ease), color var(--fast) var(--ease);
}

.archive-chip span {
  font-size: 0.72rem;
  color: var(--ink-3);
}

.archive-chip:hover {
  border-color: var(--gold);
  color: var(--gold-text);
}

.archive-chip:hover span {
  color: var(--gold-text);
}

.archive-year {
  font-family: "Lora", ui-serif, Georgia, serif;
  font-size: 1.35rem;
  color: var(--gold-text);
  margin-bottom: 4px;
}

.archive-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.archive-item {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding: 15px 0;
  border-top: 1px solid var(--line-soft);
}

.archive-item:last-child {
  border-bottom: 1px solid var(--line-soft);
}

.archive-date {
  flex: none;
  width: 58px;
  font-size: 0.8rem;
  color: var(--ink-3);
}

.archive-title {
  flex: 1;
  min-width: 0;
}

.archive-title a {
  font-weight: 500;
  color: var(--ink);
}

.archive-title a:hover {
  color: var(--gold-text);
}

.archive-item-cat {
  flex: none;
  margin-left: auto;
}

@media (max-width: 560px) {
  .archive-item {
    flex-wrap: wrap;
    gap: 4px 12px;
  }

  .archive-item-cat {
    order: 3;
    margin-left: 74px;
  }
}

.post-head h1 {
  font-size: clamp(1.9rem, 4.2vw, 3rem);
  max-width: 24ch;
  margin-inline: auto;
}

.post-head .post-meta {
  justify-content: center;
  margin-top: 14px;
}

.post-hero-img {
  width: 100%;
  aspect-ratio: 21 / 9;
  object-fit: cover;
  border-radius: 18px;
  border: 1px solid var(--line-soft);
  box-shadow: var(--shadow-1);
  display: block;
}

/* Category badge overlaid on the article hero image (bottom-left). */
.post-hero {
  position: relative;
  margin: 0;
}

.post-hero-cat {
  position: absolute;
  left: clamp(14px, 2vw, 22px);
  bottom: clamp(14px, 2vw, 22px);
  display: inline-flex;
  align-items: center;
  background-color: var(--navy);
  color: var(--band-gold);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 8px 15px;
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(10, 37, 64, 0.28);
}

[data-theme="dark"] .post-hero-cat {
  background-color: var(--gold);
  color: #0a1220;
}

a.post-hero-cat {
  transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}

a.post-hero-cat:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(10, 37, 64, 0.34);
}

.post-prose {
  padding-block: clamp(36px, 5vw, 56px) clamp(56px, 7vw, 84px);
}

.post-prose p {
  font-size: 1.02rem;
  line-height: 1.85;
  color: var(--ink-2);
  margin-bottom: 1.3em;
}

.post-prose .lede {
  font-size: 1.15rem;
  color: var(--ink);
}

.post-prose h2 {
  font-size: 1.55rem;
  margin: 2em 0 0.7em;
}

.post-prose img {
  border-radius: 14px;
  border: 1px solid var(--line-soft);
  margin: 1.6em 0;
}

.post-prose figcaption {
  font-size: 0.8rem;
  color: var(--ink-3);
  margin-top: -1em;
  margin-bottom: 1.6em;
}

.post-prose strong {
  color: var(--ink);
}

.post-prose a {
  color: var(--gold-text);
  font-weight: 500;
}

/* Author card */
.author-card {
  display: flex;
  align-items: center;
  gap: 16px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 20px 4px;
  margin: 2.4em 0 1.6em;
}

.author-card .av {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background-color: var(--navy);
  color: #f5f2e9;
  font-family: "Lora", ui-serif, Georgia, serif;
  font-size: 1.15rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

[data-theme="dark"] .author-card .av {
  background-color: var(--gold);
  color: #0a1220;
}

.author-card .an {
  font-weight: 600;
  color: var(--ink);
}

.author-card .ar {
  font-size: 0.85rem;
  color: var(--ink-3);
}

/* Tags */
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 14px;
}

a.tag {
  transition: border-color var(--fast) var(--ease), color var(--fast) var(--ease);
}

a.tag:hover {
  border-color: var(--gold);
  color: var(--gold-text);
}

/* --------------------------------------------------------------------------
   2. Blog share + language extras (F38)
   Blog-specific placement for the shared primitives in base.css.
   -------------------------------------------------------------------------- */

/* Linked tag chips (inert spans before F38) */
a.tag {
  transition: border-color var(--fast) var(--ease), color var(--fast) var(--ease);
}

a.tag:hover {
  border-color: var(--gold-line);
  color: var(--gold-text);
}

.post-meta .share-wrap {
  margin-left: 6px;
}

/* --------------------------------------------------------------------------
   3. Listing pagination + blog search (F46 P08)
   Numbered pill pagination under listing grids, and the compact
   search form on the listing + archive pages.
   -------------------------------------------------------------------------- */

.pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
}

.page-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding-inline: 12px;
  border: 1px solid var(--btn-line);
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ink-2);
  transition: border-color var(--fast) var(--ease), color var(--fast) var(--ease);
}

.page-pill:hover {
  border-color: var(--gold-line);
  color: var(--gold-text);
}

.page-pill.active {
  border-color: var(--gold-line);
  background-color: var(--gold-tint);
  color: var(--gold-text);
}

.page-pill.disabled {
  opacity: 0.45;
  pointer-events: none;
}

.blog-search {
  display: flex;
  justify-content: center;
  gap: 10px;
  max-width: 440px;
  margin: 26px auto 0;
}

.blog-search .form-input {
  flex: 1;
  height: 42px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background-color: var(--surface);
  font: inherit;
  font-size: 0.9rem;
  color: var(--ink);
}

.blog-search .form-input:focus {
  outline: none;
  border-color: var(--gold-line);
}

.blog-search .btn {
  margin-top: 0;
  padding-block: 0;
  height: 42px;
  display: inline-flex;
  align-items: center;
}

