/* ════════════════════════════════════════════════════════════
   FREECER® — Blog Listing Page · blog.css (v1)
   Static article grid, dark theme, matches site design tokens
════════════════════════════════════════════════════════════ */

/* ── 0 · Page shell ─────────────────────────────────────── */
.blog-page {
  position: relative;
  background: var(--deep);
  padding-top: clamp(120px, 16vh, 170px);
  padding-bottom: clamp(80px, 10vh, 120px);
}

.blog-container {
  width: min(1240px, 100% - var(--gutter) * 2);
  margin-inline: auto;
}

/* ── 1 · Head — title, subtitle, social icons ──────────── */
.blog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.blog-head-text {
  max-width: 640px;
}

.blog-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.8rem, 3.2vw, 2.6rem);
  line-height: 1.15;
  color: var(--frost);
}

.blog-subtitle {
  margin-top: 14px;
  font-size: .92rem;
  line-height: 1.7;
  color: var(--muted);
}

.blog-subtitle strong {
  color: var(--silver);
  font-weight: 700;
}

.blog-head-social {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.blog-social-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .06);
  border: 1px solid var(--line-soft);
  color: var(--frost);
  transition: background var(--t-fast), transform var(--t-fast), color var(--t-fast);
}

.blog-social-icon svg {
  width: 18px;
  height: 18px;
}

.blog-social-icon:hover {
  background: var(--ice-hi);
  color: #fff;
  transform: translateY(-2px);
}

/* ── 2 · Toolbar — search + category filters ───────────── */
.blog-toolbar {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  padding: 14px 18px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, .04);
  border: 1px solid var(--line-soft);
  margin-bottom: 30px;
}

.blog-search {
  position: relative;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  width: min(220px, 100%);
}

.blog-search-icon {
  position: absolute;
  left: 14px;
  width: 16px;
  height: 16px;
  color: var(--muted);
  pointer-events: none;
}

.blog-search-input {
  width: 100%;
  padding: 10px 16px 10px 40px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, .05);
  color: var(--frost);
  font-size: .86rem;
  font-family: var(--sans);
}

.blog-search-input::placeholder {
  color: var(--muted);
}

.blog-search-input:focus {
  outline: none;
  border-color: var(--ice-hi);
}

.blog-filters {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.blog-filter {
  padding: 9px 18px;
  border-radius: var(--r-pill);
  font-size: .82rem;
  font-weight: 600;
  color: var(--muted);
  background: transparent;
  border: 1px solid transparent;
  white-space: nowrap;
  transition: background var(--t-fast), color var(--t-fast);
}

.blog-filter:hover {
  color: var(--frost);
}

.blog-filter.active {
  color: #fff;
  background: linear-gradient(135deg, var(--ice), var(--ice-hi));
  box-shadow: 0 4px 16px rgba(0, 170, 238, .4);
}

/* ── 3 · Section label ──────────────────────────────────── */
.blog-section-label {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 18px;
}

/* ── 4 · Featured carousel card ─────────────────────────── */
.blog-featured {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: 24px;
  padding: clamp(28px, 4vw, 48px);
  border-radius: var(--r-xl);
  background: linear-gradient(135deg, #cfe9f7 0%, #eaf5fb 100%);
  overflow: hidden;
  margin-bottom: 48px;
}

.blog-featured-copy {
  position: relative;
  z-index: 2;
}

.blog-featured-author {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 16px 6px 6px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, .7);
  font-size: .82rem;
  font-weight: 700;
  color: var(--l-text);
  margin-bottom: 20px;
}

.blog-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: block;
}

.blog-featured-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.4rem, 2.6vw, 2rem);
  line-height: 1.2;
  color: var(--l-text);
  max-width: 20ch;
}

.blog-featured-text {
  margin-top: 16px;
  font-size: .9rem;
  line-height: 1.7;
  color: var(--l-muted);
  max-width: 46ch;
}

.blog-featured-text strong {
  color: var(--l-text);
  font-weight: 700;
}

.blog-featured-more {
  color: var(--ice);
  font-weight: 700;
  text-decoration: underline;
}

.blog-featured-visual {
  position: relative;
  z-index: 1;
  aspect-ratio: 4 / 3;
  border-radius: var(--r-lg);
  overflow: hidden;
}

.blog-featured-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-featured-dots {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 3;
}

.blog-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(11, 22, 32, .25);
}

.blog-dot.active {
  background: var(--l-text);
  width: 20px;
  border-radius: 4px;
}

/* ── 5 · Article grid ───────────────────────────────────── */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 56px;
}

.blog-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--r-lg);
  background: rgba(255, 255, 255, .03);
  border: 1px solid var(--line-soft);
  overflow: hidden;
  transition: transform var(--t-fast), border-color var(--t-fast);
}

.blog-card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 170, 238, .35);
}

.blog-card-media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.blog-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-card-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .9);
  color: #ff5a3c;
}

.blog-card-badge svg {
  width: 16px;
  height: 16px;
}

.blog-card-author {
  position: absolute;
  left: 14px;
  bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 14px 5px 5px;
  border-radius: var(--r-pill);
  background: rgba(6, 12, 19, .55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-size: .78rem;
  font-weight: 700;
  color: var(--frost);
}

.blog-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 20px 22px 24px;
}

.blog-card-title {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
  color: var(--frost);
}

.blog-card-excerpt {
  margin-top: 10px;
  font-size: .84rem;
  line-height: 1.6;
  color: var(--muted);
  flex: 1;
}

.blog-card-meta {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line-soft);
}

.blog-card-date,
.blog-card-views {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .74rem;
  font-weight: 600;
  color: var(--muted);
}

.blog-card-date svg,
.blog-card-views svg {
  width: 14px;
  height: 14px;
}

.blog-card-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 18px;
  padding: 12px 20px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  color: var(--frost);
  font-size: .84rem;
  font-weight: 700;
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast);
}

.blog-card-cta:hover {
  background: linear-gradient(135deg, var(--ice), var(--ice-hi));
  border-color: transparent;
  color: #fff;
}

/* ── 6 · Pagination ─────────────────────────────────────── */
.blog-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.blog-page-arrow,
.blog-page-num {
  display: grid;
  place-items: center;
  min-width: 40px;
  height: 40px;
  padding-inline: 6px;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, .03);
  color: var(--muted);
  font-size: .86rem;
  font-weight: 700;
  transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast);
}

.blog-page-arrow svg {
  width: 16px;
  height: 16px;
}

.blog-page-num:hover,
.blog-page-arrow:hover {
  color: var(--frost);
  border-color: var(--line);
}

.blog-page-num.active {
  color: #fff;
  background: linear-gradient(135deg, var(--ice), var(--ice-hi));
  border-color: transparent;
}

.blog-page-arrow.active {
  color: #fff;
  background: linear-gradient(135deg, var(--ice), var(--ice-hi));
  border-color: transparent;
}

.blog-page-dots {
  display: grid;
  place-items: center;
  min-width: 24px;
  height: 40px;
  color: var(--muted);
  font-weight: 700;
}

/* ── 7 · Responsive ─────────────────────────────────────── */
@media (max-width: 1024px) {
  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .blog-featured {
    grid-template-columns: 1fr;
  }

  .blog-featured-visual {
    order: -1;
  }
}

@media (max-width: 700px) {
  .blog-grid {
    grid-template-columns: 1fr;
  }

  .blog-toolbar {
    border-radius: var(--r-lg);
  }

  .blog-search {
    width: 100%;
  }

  .blog-head {
    flex-direction: column;
  }
}

/* ── 8 · Accessibility utility ──────────────────────────── */
/* Visually hidden but still announced by screen readers. */
.screen-reader-text {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── 9 · Thumbnail placeholder ──────────────────────────── */
/* Shown when a post has no featured image, so every card in the grid keeps
   the same proportions and the layout stays even. */
.blog-thumb-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 3 / 2;
  background:
    radial-gradient(600px 300px at 70% 0%, rgba(0, 170, 238, .14), transparent 60%),
    linear-gradient(160deg, #0a141d 0%, #060d14 100%);
}
.blog-thumb-placeholder span {
  font-family: var(--serif);
  font-size: .82rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: rgba(184, 199, 209, .35);
}

/* ── 10 · Empty state ───────────────────────────────────── */
.blog-empty {
  padding: clamp(50px, 8vw, 90px) 0;
  text-align: center;
}
.blog-empty h2 {
  font-family: var(--serif);
  color: var(--frost);
  margin-bottom: 12px;
}
.blog-empty p {
  color: var(--muted);
  max-width: 46ch;
  margin: 0 auto 26px;
}

/* Category filters are links now, not buttons — keep them on one baseline. */
.blog-filter { display: inline-block; text-decoration: none; }

/* Titles are links; inherit colour so the card styling still governs. */
.blog-card-title a,
.blog-featured-title a { color: inherit; }
.blog-card-title a:hover,
.blog-featured-title a:hover { color: var(--ice-hi); }

/* ── 11 · Single post ───────────────────────────────────── */
.single-post {
  background: var(--deep);
  padding-top: clamp(120px, 16vh, 170px);
  padding-bottom: clamp(60px, 8vh, 100px);
}
.single-head,
.single-body,
.single-tags,
.single-nav,
.single-comments,
.single-pagelinks {
  width: min(760px, 100% - var(--gutter) * 2);
  margin-inline: auto;
}
.single-breadcrumb {
  display: flex;
  gap: 10px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 20px;
}
.single-breadcrumb a { color: var(--ice-hi); }
.single-title {
  font-family: var(--serif);
  font-size: clamp(2rem, 4.6vw, 3.4rem);
  line-height: 1.08;
  color: var(--frost);
  margin-bottom: 22px;
}
.single-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-size: .9rem;
  color: var(--muted);
}
.single-meta-author { display: inline-flex; align-items: center; gap: 10px; }
.single-meta-author img { border-radius: 50%; }
.single-meta-sep { opacity: .5; }

.single-hero {
  width: min(1100px, 100% - var(--gutter) * 2);
  margin: clamp(30px, 5vw, 52px) auto;
  border-radius: var(--r-xl);
  overflow: hidden;
}
.single-hero img { width: 100%; height: auto; }
.single-hero figcaption {
  padding: 12px 4px 0;
  font-size: .82rem;
  color: var(--muted);
  text-align: center;
}

/* Long-form body copy. Element selectors are scoped under .single-body so they
   never touch Elementor-built content elsewhere on the site. */
.single-body { font-size: 1.06rem; line-height: 1.85; color: var(--silver); }
.single-body > * + * { margin-top: 1.3em; }
.single-body h2,
.single-body h3,
.single-body h4 {
  font-family: var(--serif);
  color: var(--frost);
  margin-top: 1.8em;
  line-height: 1.2;
}
.single-body h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); }
.single-body h3 { font-size: clamp(1.25rem, 2.4vw, 1.6rem); }
.single-body a { color: var(--ice-hi); text-decoration: underline; text-underline-offset: 3px; }
.single-body img { border-radius: var(--r-md); height: auto; }
.single-body ul,
.single-body ol { padding-left: 1.4em; }
.single-body ul li { list-style: disc; }
.single-body ol li { list-style: decimal; }
.single-body li + li { margin-top: .5em; }
.single-body blockquote {
  border-left: 2px solid var(--ice-hi);
  padding-left: 22px;
  font-family: var(--serif);
  font-size: 1.2rem;
  color: var(--frost);
}
.single-body code {
  background: rgba(255, 255, 255, .06);
  padding: 2px 6px;
  border-radius: 5px;
  font-size: .92em;
}
.single-body pre {
  background: rgba(255, 255, 255, .05);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  padding: 18px;
  overflow-x: auto;
}
.single-body pre code { background: none; padding: 0; }
.single-body figure { margin-block: 1.6em; }
.single-body figcaption { font-size: .84rem; color: var(--muted); text-align: center; padding-top: 8px; }
.single-body table { width: 100%; border-collapse: collapse; display: block; overflow-x: auto; }
.single-body th,
.single-body td { border: 1px solid var(--line-soft); padding: 10px 12px; text-align: left; }

.single-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 44px; }
.single-tag {
  padding: 7px 15px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-soft);
  font-size: .8rem;
  color: var(--muted);
  transition: color var(--t-fast), border-color var(--t-fast);
}
.single-tag:hover { color: var(--ice-hi); border-color: rgba(0, 170, 238, .4); }

.single-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 52px;
}
.single-nav-link {
  padding: 20px 22px;
  border-radius: var(--r-lg);
  border: 1px solid var(--line-soft);
  background: rgba(255, 255, 255, .03);
  transition: border-color var(--t-fast), background var(--t-fast);
}
.single-nav-link:hover { border-color: rgba(0, 170, 238, .4); background: rgba(0, 170, 238, .06); }
.single-nav-link.next { text-align: right; grid-column: 2; }
.single-nav-label {
  display: block;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ice-hi);
  margin-bottom: 6px;
}
.single-nav-title { color: var(--frost); font-family: var(--serif); font-size: 1.05rem; line-height: 1.3; }

/* ── 12 · Comments ──────────────────────────────────────── */
.single-comments { margin-top: 60px; padding-top: 40px; border-top: 1px solid var(--line-soft); }
.single-comments-title { font-family: var(--serif); color: var(--frost); font-size: 1.5rem; margin-bottom: 24px; }
.comment-list { padding: 0; }
.comment-list li { list-style: none; }
.comment-list .children { padding-left: clamp(16px, 4vw, 40px); }
.comment-body {
  padding: 20px 0;
  border-bottom: 1px solid var(--line-soft);
}
.comment-author { display: flex; align-items: center; gap: 10px; color: var(--frost); }
.comment-author img { border-radius: 50%; }
.comment-meta { font-size: .8rem; color: var(--muted); margin-bottom: 10px; }
.comment-meta a { color: var(--muted); }
.comment-content { color: var(--silver); }
.comment-content a { color: var(--ice-hi); }
.reply { margin-top: 8px; }
.reply a { font-size: .8rem; color: var(--ice-hi); font-weight: 700; }
.comments-closed { color: var(--muted); font-style: italic; }

.comment-form { margin-top: 30px; }
.comment-form p { margin-bottom: 16px; }
.comment-form label {
  display: block;
  margin-bottom: 7px;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--silver);
}
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  padding: 13px 15px;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: rgba(3, 5, 8, .55);
  color: var(--frost);
  font-family: var(--sans);
  font-size: .95rem;
}
.comment-form textarea { resize: vertical; min-height: 130px; }
.comment-form input:focus,
.comment-form textarea:focus {
  outline: none;
  border-color: var(--ice-hi);
  box-shadow: 0 0 0 3px rgba(0, 170, 238, .16);
}
.comment-form .submit {
  padding: 15px 32px;
  border-radius: var(--r-pill);
  background: linear-gradient(135deg, var(--ice), var(--ice-hi));
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  border: none;
}
.comment-notes, .comment-form-cookies-consent label {
  font-size: .84rem;
  color: var(--muted);
  text-transform: none;
  letter-spacing: 0;
  font-weight: 400;
}
.comment-form-cookies-consent { display: flex; align-items: center; gap: 8px; }
.comment-form-cookies-consent input { width: auto; }

/* ── 13 · 404 ───────────────────────────────────────────── */
.error-404 {
  background: var(--deep);
  min-height: 78vh;
  display: flex;
  align-items: center;
  padding: clamp(140px, 18vh, 200px) 0 clamp(70px, 10vh, 110px);
}
.error-404-inner { text-align: center; }
.error-404-code {
  font-family: var(--serif);
  font-size: clamp(6rem, 22vw, 15rem);
  line-height: .9;
  margin: 18px 0 4px;
  background: linear-gradient(180deg, rgba(0, 170, 238, .85), rgba(0, 170, 238, .06));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.error-404-title {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 4vw, 3rem);
  color: var(--frost);
  margin-bottom: 14px;
}
.error-404-text { color: var(--muted); max-width: 52ch; margin: 0 auto 32px; }
.error-404-search {
  display: flex;
  gap: 10px;
  max-width: 460px;
  margin: 0 auto 28px;
  flex-wrap: wrap;
}
.error-404-search input {
  flex: 1 1 220px;
  padding: 14px 18px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .05);
  color: var(--frost);
  font-family: var(--sans);
}
.error-404-search input:focus {
  outline: none;
  border-color: var(--ice-hi);
  box-shadow: 0 0 0 3px rgba(0, 170, 238, .16);
}
.error-404-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

@media (max-width: 700px) {
  .single-nav { grid-template-columns: 1fr; }
  .single-nav-link.next { grid-column: 1; text-align: left; }
}
