/* ── Blog page ── */
.blog-wrap {
  max-width: 1120px; margin: 0 auto;
  padding: calc(var(--nav-offset) + 32px) 24px 0;
}
.blog-crumb { font-size: 13px; color: var(--mid); margin-bottom: 18px; }
.blog-crumb a { color: var(--mid); text-decoration: none; }
.blog-crumb a:hover { color: var(--teal); }
.blog-head { margin-bottom: 28px; }
.blog-head .sec-eye { margin-bottom: 10px; }
.blog-head h1 {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(28px, 3.4vw, 42px);
  font-weight: 800; letter-spacing: -0.03em;
  color: var(--ink); margin-bottom: 10px;
}
.blog-head p { font-size: 15px; color: #3D4F6E; font-weight: 300; max-width: 560px; }

/* Category badge — reused across featured card, list rows, popular list */
.blog-cat {
  display: inline-block; font-family: 'Outfit', sans-serif;
  font-size: 10.5px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.06em; padding: 5px 12px; border-radius: 100px;
  background: var(--teal); color: #fff;
}

/* Topic filter bar — sits above the list, not buried at the bottom */
.blog-topics-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
  margin-bottom: 32px; padding-bottom: 28px;
  border-bottom: 1px solid var(--faint);
}
.blog-topics { display: flex; flex-wrap: wrap; gap: 10px; }
.blog-topic-pill {
  padding: 9px 18px; border: none; border-radius: 100px;
  font-family: 'Outfit', sans-serif; font-size: 13px; font-weight: 700;
  color: #fff; text-decoration: none;
  transition: opacity 0.18s, transform 0.18s;
}
.blog-topic-pill:hover { opacity: 0.85; }
.blog-topic-pill.active { box-shadow: 0 0 0 2px rgba(15,23,42,0.18); }
.blog-search-btn {
  width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0;
  border: 1px solid var(--faint); background: #fff; color: var(--ink);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: border-color 0.18s, color 0.18s;
}
.blog-search-btn:hover { border-color: var(--teal); color: var(--teal); }

/* Mobile: full search bar instead of the icon button */
.blog-search-bar-mobile { display: none; align-items: center; gap: 8px; flex: 1 1 100%; }
.blog-search-bar-mobile input {
  flex: 1; padding: 10px 16px; border: 1px solid var(--faint); border-radius: 100px;
  font-family: 'Plus Jakarta Sans', sans-serif; font-size: 13.5px; outline: none; background: #fff;
}
.blog-search-bar-mobile input:focus { border-color: var(--teal); }
.blog-search-bar-mobile button {
  width: 40px; height: 40px; border-radius: 50%; border: none; flex-shrink: 0;
  background: var(--blue); color: #fff; display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: opacity 0.18s;
}
.blog-search-bar-mobile button:hover { opacity: 0.88; }

/* Desktop: popup search modal */
.blog-search-modal {
  position: fixed; inset: 0; z-index: 1000;
  display: none; align-items: flex-start; justify-content: center;
  padding-top: 120px;
}
.blog-search-modal.open { display: flex; }
.blog-search-modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(15,23,42,0.5); backdrop-filter: blur(2px);
}
.blog-search-modal-box {
  position: relative; z-index: 1;
  width: min(560px, 90vw); background: #fff;
  border-radius: 16px; box-shadow: 0 24px 60px rgba(0,0,0,0.25);
  animation: blogSearchIn 0.18s ease;
}
@keyframes blogSearchIn { from { opacity: 0; transform: translateY(-8px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
.blog-search-modal-input-wrap { display: flex; align-items: center; gap: 12px; padding: 16px 18px; }
.blog-search-modal-input-wrap i { color: var(--mid); font-size: 16px; }
.blog-search-modal-input-wrap input {
  flex: 1; border: none; outline: none; background: transparent;
  font-family: 'Plus Jakarta Sans', sans-serif; font-size: 16px; color: var(--ink);
}
.blog-search-modal-input-wrap kbd {
  font-family: 'Outfit', sans-serif; font-size: 11px; font-weight: 700; color: var(--mid);
  border: 1px solid var(--faint); border-radius: 6px; padding: 3px 7px; cursor: pointer;
}
.blog-search-modal-hint {
  padding: 10px 18px; border-top: 1px solid var(--faint);
  font-size: 12px; color: var(--mid);
}
.blog-search-modal-hint kbd {
  font-family: 'Outfit', sans-serif; font-weight: 700;
  border: 1px solid var(--faint); border-radius: 5px; padding: 2px 6px; margin: 0 2px;
}
@media (max-width: 700px) {
  .blog-search-btn { display: none; }
  .blog-search-bar-mobile { display: flex; }
}

/* Featured posts — one large card + two stacked, together filling the same width/height envelope.
   Height is set explicitly on the row (not aspect-ratio) so the left card and the
   two-stacked right column are guaranteed equal height, not just approximately matched
   via grid-stretch-into-flex-into-percentage-height (which several browsers get wrong). */
.blog-featured-row {
  display: grid; grid-template-columns: 1.7fr 1fr; gap: 18px;
  height: 420px;
  margin-bottom: 40px;
}
.blog-featured-side { display: flex; flex-direction: column; gap: 18px; height: 100%; }
.blog-featured {
  position: relative; display: block; text-decoration: none;
  border-radius: 20px; overflow: hidden;
  box-shadow: 0 10px 30px rgba(15,23,42,0.1);
}
.blog-featured-main { height: 100%; }
.blog-featured-side .blog-featured { flex: 1 1 0; min-height: 0; }
.blog-featured img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-featured-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(10,14,30,0.85) 0%, rgba(10,14,30,0.3) 55%, transparent 100%);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 24px;
}
.blog-featured-overlay .blog-cat { margin-bottom: 10px; align-self: flex-start; }
.blog-featured-title {
  font-family: 'Outfit', sans-serif; font-weight: 700; color: #fff;
  font-size: clamp(18px, 2.4vw, 27px); line-height: 1.25; letter-spacing: -0.01em;
  max-width: 640px;
}
.blog-featured-side .blog-featured-title { font-size: 15.5px; max-width: none; }
.blog-featured-meta { color: rgba(255,255,255,0.7); font-size: 12.5px; margin-top: 10px; }
.blog-featured-side .blog-featured-meta { font-size: 11.5px; margin-top: 6px; }
@media (max-width: 700px) {
  .blog-featured-row { grid-template-columns: 1fr; height: auto; }
  .blog-featured-main { height: auto; aspect-ratio: 16/10; }
  .blog-featured-side { flex-direction: row; height: auto; }
  .blog-featured-side .blog-featured { aspect-ratio: 4/3; flex: 1 1 0; }
  .blog-featured-overlay .blog-cat { display: none; }
  .blog-topic-pill { padding: 6px 13px; font-size: 11.5px; }
  .blog-topics { gap: 8px; }
}

/* Two-column layout: article list (main) + sidebar */
.blog-layout { display: flex; gap: 44px; align-items: flex-start; margin-bottom: 56px; }
.blog-main { flex: 1 1 620px; min-width: 0; }
.blog-side { flex: 1 1 280px; min-width: 260px; position: sticky; top: calc(var(--nav-offset) + 20px); }
.blog-col-title {
  font-family: 'Outfit', sans-serif; font-size: 17px; font-weight: 700;
  color: var(--ink); margin-bottom: 6px;
}

/* Article list rows — one consistent style for every post, no duplication */
.blog-post-row {
  display: flex; gap: 18px; align-items: center;
  padding: 20px 0; border-top: 1px solid var(--faint);
  text-decoration: none;
}
.blog-post-row:last-child { border-bottom: 1px solid var(--faint); }
.blog-post-thumb { width: 108px; height: 80px; border-radius: 12px; overflow: hidden; flex-shrink: 0; }
.blog-post-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.blog-post-cat { color: var(--teal); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 6px; }
.blog-post-title { font-family: 'Outfit', sans-serif; font-size: 15.5px; font-weight: 700; color: var(--ink); line-height: 1.35; margin-bottom: 6px; }
.blog-post-meta { font-size: 12.5px; color: var(--mid); }

/* Sidebar: Popular posts */
.blog-popular { margin-bottom: 32px; }
.blog-popular-item { display: flex; align-items: flex-start; gap: 12px; padding: 13px 0; border-top: 1px solid var(--faint); text-decoration: none; }
.blog-popular-item:last-child { border-bottom: 1px solid var(--faint); }
.blog-popular-num {
  font-family: 'Outfit', sans-serif; font-size: 20px; font-weight: 800;
  color: rgba(15,23,42,0.15); line-height: 1.2; flex-shrink: 0; width: 18px;
}
.blog-popular-body .blog-cat { background: var(--blue-lt); color: var(--blue); margin-bottom: 6px; font-size: 10px; padding: 4px 10px; }
.blog-popular-title { font-family: 'Outfit', sans-serif; font-size: 13.5px; font-weight: 600; color: var(--ink); line-height: 1.4; }

/* Sidebar: compact newsletter widget (replaces the big full-width banner) */
.blog-nl-card {
  background: var(--paper); border-radius: 16px; padding: 24px 22px;
}
.blog-nl-icon {
  width: 38px; height: 38px; border-radius: 10px;
  background: var(--blue); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; margin-bottom: 14px;
}
.blog-nl-card h3 { font-family: 'Outfit', sans-serif; font-size: 16px; font-weight: 700; color: var(--ink); margin-bottom: 6px; }
.blog-nl-card p { font-size: 13px; color: var(--mid); font-weight: 300; line-height: 1.6; margin-bottom: 16px; }
.blog-nl-card form { display: flex; flex-direction: column; gap: 10px; }
.blog-nl-card input {
  padding: 11px 14px; border: 1px solid var(--faint); border-radius: 10px;
  font-family: 'Plus Jakarta Sans', sans-serif; font-size: 13.5px; outline: none;
  background: #fff;
}
.blog-nl-card input:focus { border-color: var(--teal); }
.blog-nl-card button {
  padding: 11px 16px; background: var(--blue); color: #fff; border: none;
  border-radius: 10px; font-family: 'Outfit', sans-serif; font-weight: 700;
  font-size: 13.5px; cursor: pointer; transition: opacity 0.18s;
}
.blog-nl-card button:hover { opacity: 0.88; }
.blog-nl-note { font-size: 11px; color: var(--mid); margin-top: 10px; }

/* ── Single blog post (article) page ── */
.blog-post-header { margin-bottom: 24px; }
.blog-post-header h1 {
  font-family: 'Outfit', sans-serif;
  font-size: clamp(28px, 4vw, 42px); font-weight: 800;
  letter-spacing: -0.03em; color: var(--ink); line-height: 1.15;
  margin-bottom: 16px; max-width: 780px;
}
.blog-post-excerpt {
  font-size: 17px; color: #3D4F6E; font-weight: 300;
  line-height: 1.7; margin-bottom: 22px; max-width: 720px;
}
.blog-post-byline {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding-bottom: 22px; border-bottom: 1px solid var(--faint);
  font-size: 14px; color: var(--mid);
}
.blog-post-byline .dot { opacity: 0.5; }
.blog-post-byline strong { color: var(--ink); }
.blog-post-cat-link { color: var(--teal); font-weight: 600; text-decoration: none; }
.blog-post-cat-link:hover { text-decoration: underline; }
.blog-post-avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--blue); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Outfit', sans-serif; font-size: 11px; font-weight: 700;
  flex-shrink: 0;
}

.blog-post-hero {
  border-radius: 20px; overflow: hidden;
  margin: 28px 0 20px;
  box-shadow: 0 10px 30px rgba(15,23,42,0.1);
}
.blog-post-hero img { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; }

.blog-share { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 44px; }
.blog-share a, .blog-share button {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px; border-radius: 10px; border: none;
  font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 13.5px;
  color: #fff; text-decoration: none; cursor: pointer;
  transition: opacity 0.18s;
}
.blog-share a:hover, .blog-share button:hover { opacity: 0.88; }
.blog-share .fb { background: #1877F2; }
.blog-share .tw { background: #000; }
.blog-share .wa { background: #25D366; }
.blog-share .li { background: #0A66C2; }
.blog-share .copy { background: #fff; color: var(--ink); border: 1px solid var(--faint); }
.blog-share .copy:hover { border-color: var(--teal); color: var(--teal); opacity: 1; }

.blog-article { max-width: 720px; }
.blog-article h2 {
  font-family: 'Outfit', sans-serif; font-size: 22px; font-weight: 700;
  color: var(--ink); letter-spacing: -0.01em; margin: 32px 0 12px;
}
.blog-article p { font-size: 16px; line-height: 1.8; color: var(--mid); font-weight: 300; margin-bottom: 16px; }
.blog-article ul { margin: 0 0 16px; padding-left: 22px; }
.blog-article li { font-size: 16px; line-height: 1.8; color: var(--mid); font-weight: 300; margin-bottom: 8px; }
.blog-article strong { color: var(--ink); font-weight: 700; }

/* Related posts — 3 cards in a row, shown after the article + share row */
.blog-related { margin-top: 8px; padding-top: 36px; border-top: 1px solid var(--faint); max-width: 720px; }
.blog-related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 18px; }
.blog-related-card {
  display: block; text-decoration: none;
  border-radius: 16px; overflow: hidden;
  background: #fff; border: 1px solid var(--faint);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.blog-related-card:hover { transform: translateY(-3px); box-shadow: 0 10px 26px rgba(15,23,42,0.08); }
.blog-related-card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; display: block; }
.blog-related-body { padding: 14px; }
.blog-related-cat { color: var(--teal); font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }
.blog-related-title { font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 14px; color: var(--ink); line-height: 1.35; margin: 6px 0 4px; }
.blog-related-meta { font-size: 11.5px; color: var(--mid); }

@media (max-width: 700px) {
  .blog-related-grid { grid-template-columns: 1fr; }
  .blog-related-cat { display: none; }
}
@media (max-width: 820px) {
  .blog-layout { flex-direction: column; }
  .blog-side { position: static; width: 100%; }
}
