/* ═══════════════════════════════════════════════════════════════════════════
   PIXEL ADDIS SOLUTIONS — BLOG PAGE STYLESHEET
   Oracle-style horizontal cards + About Page Hero Style
   ═══════════════════════════════════════════════════════════════════════════ */

/* ═══════════ BLOG PAGE CONTAINER ═══════════ */
.blog-page-main {
  width: 100%;
  overflow-x: hidden;
  background: #ffffff;
}

.blog-page-container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 44px);
}

/* ═══════════ HERO BANNER (MATCHING ABOUT PAGE) ═══════════ */
.blog-hero-section {
  position: relative;
  min-height: 440px;
  padding: clamp(120px, 16vh, 180px) 0 clamp(56px, 7vh, 80px);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background-color: #07132e;
}

.blog-hero-bg-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.blog-hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  transform: scale(1.06);
  filter: brightness(0.95) contrast(1.05);
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.blog-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: 
    radial-gradient(ellipse at 50% 40%, rgba(7, 19, 46, 0.3) 0%, rgba(7, 19, 46, 0.6) 70%, rgba(7, 19, 46, 0.85) 100%),
    linear-gradient(180deg, rgba(7, 19, 46, 0.35) 0%, rgba(7, 19, 46, 0.15) 40%, rgba(7, 19, 46, 0.7) 85%, #07132e 100%);
  pointer-events: none;
}

.blog-hero-glow-blob {
  position: absolute;
  top: 20%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(circle, rgba(58, 106, 199, 0.35) 0%, rgba(25, 73, 179, 0.1) 60%, transparent 80%);
  filter: blur(60px);
  z-index: 2;
  pointer-events: none;
}

.blog-hero-content {
  position: relative;
  z-index: 3;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  color: #ffffff;
}

.blog-hero-title {
  font-family: var(--heading);
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
  color: #ffffff;
}

.blog-hero-title span {
  color: var(--blue-400, #6ea8fe);
}

.blog-hero-sub {
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.75);
  max-width: 640px;
  margin: 0 auto;
}

/* ═══════════ BLOG CONTENT SECTION ═══════════ */
.blog-content-section {
  padding: clamp(56px, 7vh, 88px) 0;
  background: #f8f9fb;
}

/* ─── Section Heading ─── */
.blog-section-heading {
  margin-bottom: 36px;
}

.blog-section-heading h3 {
  font-family: var(--heading);
  font-size: clamp(1.2rem, 1.8vw, 1.5rem);
  font-weight: 700;
  color: var(--gray-900, #0f172a);
  position: relative;
  padding-bottom: 14px;
}

.blog-section-heading h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 36px;
  height: 3px;
  border-radius: 2px;
  background: var(--blue-600, #1949b3);
}

/* ═══════════ ORACLE-STYLE HORIZONTAL BLOG CARDS ═══════════ */
.blog-posts-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 48px;
}

.blog-hcard {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  background: #ffffff;
  border-radius: 14px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.04), 0 6px 24px rgba(15, 23, 42, 0.04);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.blog-hcard:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 44px rgba(15, 23, 42, 0.1), 0 4px 14px rgba(15, 23, 42, 0.05);
}

/* ─── Image Side ─── */
.blog-hcard-img {
  position: relative;
  overflow: hidden;
  min-height: 200px;
  max-height: 240px;
  background: #eef1f5;
}

.blog-hcard-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.blog-hcard:hover .blog-hcard-img img {
  transform: scale(1.04);
}

/* Overlay caption at bottom of image (Oracle-style) */
.blog-hcard-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px 24px;
  background: linear-gradient(0deg, rgba(7, 19, 46, 0.88) 0%, rgba(7, 19, 46, 0.5) 60%, transparent 100%);
  color: #ffffff;
}

.blog-hcard-overlay-title {
  font-family: var(--heading);
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 4px;
}

.blog-hcard-overlay-sub {
  font-size: 0.76rem;
  opacity: 0.7;
  line-height: 1.4;
}

/* ─── Text Side ─── */
.blog-hcard-body {
  padding: 24px 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.blog-hcard-category {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--blue-600, #1949b3);
  margin-bottom: 14px;
}

.blog-hcard-body h2 {
  font-family: var(--heading);
  font-size: clamp(1rem, 1.4vw, 1.25rem);
  font-weight: 700;
  color: var(--gray-900, #0f172a);
  line-height: 1.35;
  margin-bottom: 8px;
}

.blog-hcard-body p {
  font-size: 0.84rem;
  line-height: 1.6;
  color: var(--gray-500, #64748b);
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.blog-hcard-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--gray-400, #94a3b8);
  margin-top: auto;
}

.blog-hcard-meta .blog-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--gray-300, #cbd5e1);
}

.blog-hcard-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 18px;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--gray-900, #0f172a);
  transition: color 0.2s;
}

.blog-hcard:hover .blog-hcard-cta {
  color: var(--blue-600, #1949b3);
}

.blog-hcard-cta svg {
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

.blog-hcard:hover .blog-hcard-cta svg {
  transform: translateX(4px);
}

/* ─── Alternating layout (even cards: image on right) ─── */
.blog-hcard:nth-child(even) {
  direction: rtl;
}

.blog-hcard:nth-child(even) > * {
  direction: ltr;
}

/* ─── Coming Soon Banner ─── */
.blog-coming-soon {
  text-align: center;
  padding: 56px 40px;
  background: 
    linear-gradient(135deg, rgba(7, 19, 46, 0.88) 0%, rgba(15, 33, 72, 0.85) 50%, rgba(20, 45, 94, 0.88) 100%),
    url('../assets/img/topo-pattern-dark.jpg') center / cover no-repeat;
  border-radius: 14px;
  box-shadow: 0 4px 20px rgba(7, 19, 46, 0.2);
  color: #ffffff;
  position: relative;
  overflow: hidden;
}

.blog-coming-soon-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 20px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.blog-coming-soon-icon svg {
  width: 26px;
  height: 26px;
  stroke: rgba(255, 255, 255, 0.85);
}

.blog-coming-soon h3 {
  font-family: var(--heading);
  font-size: 1.2rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.blog-coming-soon p {
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.6;
  max-width: 500px;
  margin: 0 auto 24px;
}

.blog-subscribe-form {
  display: flex;
  gap: 10px;
  max-width: 420px;
  margin: 0 auto;
}

.blog-subscribe-form input {
  flex: 1;
  padding: 12px 18px;
  border: 1px solid var(--gray-200, #e2e8f0);
  border-radius: 8px;
  font-size: 0.88rem;
  color: var(--gray-700, #334155);
  background: #fafbfc;
  outline: none;
  transition: border-color 0.2s;
}

.blog-subscribe-form input:focus {
  border-color: var(--blue-600, #1949b3);
}

.blog-subscribe-form button {
  padding: 12px 24px;
  background: var(--blue-600, #1949b3);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.blog-subscribe-form button:hover {
  background: var(--blue-700, #153d8a);
}

/* ═══════════ RESPONSIVE ═══════════ */
@media (max-width: 900px) {
  .blog-hcard {
    grid-template-columns: 1fr;
  }
  .blog-hcard:nth-child(even) {
    direction: ltr;
  }
  .blog-hcard-img {
    min-height: 180px;
    max-height: 200px;
  }
  .blog-hcard-body {
    padding: 20px 24px;
  }
}

@media (max-width: 600px) {
  .blog-hero-section {
    min-height: 320px;
    padding: 100px 0 40px;
  }
  .blog-hero-section h1 {
    font-size: 1.6rem;
  }
  .blog-hero-section p {
    font-size: 0.88rem;
  }
  .blog-hcard-img {
    min-height: 160px;
    max-height: 180px;
  }
  .blog-hcard-body {
    padding: 20px 18px;
  }
  .blog-hcard h2 {
    font-size: 1.1rem;
  }
  .blog-hcard p {
    font-size: 0.85rem;
  }
  .blog-hcard-category {
    font-size: 0.62rem;
  }
  .blog-hcard-cta {
    font-size: 0.78rem;
  }
  .blog-coming-soon {
    padding: 36px 20px;
  }
  .blog-coming-soon h3 {
    font-size: 1.05rem;
  }
  .blog-coming-soon p {
    font-size: 0.84rem;
  }
  .blog-subscribe-form {
    flex-direction: column;
  }
  .blog-subscribe-form input,
  .blog-subscribe-form button {
    width: 100%;
  }
}

@media (max-width: 400px) {
  .blog-hero-section {
    min-height: 280px;
    padding: 90px 0 32px;
  }
  .blog-hero-section h1 {
    font-size: 1.35rem;
  }
  .blog-hcard-body {
    padding: 18px 16px;
  }
  .blog-hcard h2 {
    font-size: 1rem;
  }
}

/* ═══════════ SEARCH BAR (in hero) ═══════════ */
.blog-search-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 460px;
  margin: 28px auto 0;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 10px;
  padding: 10px 18px;
  backdrop-filter: blur(8px);
  transition: border-color 0.2s, background 0.2s;
}
.blog-search-bar:focus-within {
  border-color: var(--blue-400, #6ea8fe);
  background: rgba(255,255,255,0.15);
}
.blog-search-bar svg {
  flex-shrink: 0;
  stroke: rgba(255,255,255,0.5);
}
.blog-search-bar input {
  flex: 1;
  background: none;
  border: none;
  outline: none;
  font-size: 0.92rem;
  color: #ffffff;
}
.blog-search-bar input::placeholder {
  color: rgba(255,255,255,0.45);
}

/* ═══════════ CATEGORY & TAG FILTERS ═══════════ */
.blog-filters {
  margin-bottom: 28px;
}
.blog-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}
.blog-filter-btn {
  padding: 7px 18px;
  border: 1px solid var(--gray-200, #e2e8f0);
  border-radius: 8px;
  background: #fff;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--gray-600, #475569);
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}
.blog-filter-btn:hover {
  border-color: var(--blue-300, #93b8f5);
  color: var(--blue-600, #1949b3);
}
.blog-filter-btn.active {
  background: var(--blue-600, #1949b3);
  border-color: var(--blue-600, #1949b3);
  color: #fff;
}

.blog-filter-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.blog-tag-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border: 1px solid var(--gray-200, #e2e8f0);
  border-radius: 20px;
  background: #fff;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--gray-500, #64748b);
  cursor: pointer;
  transition: all 0.2s;
}
.blog-tag-btn:hover {
  border-color: var(--gray-300, #cbd5e1);
  color: var(--gray-700, #334155);
}
.blog-tag-btn.active {
  background: var(--gray-900, #0f172a);
  border-color: var(--gray-900, #0f172a);
  color: #fff;
}
.blog-tag-btn.active .blog-tag-dot {
  background: #fff !important;
}
.blog-tag-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ═══════════ LOADING STATE ═══════════ */
.blog-loading,
.blog-article-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 20px;
  gap: 16px;
  color: var(--gray-400, #94a3b8);
  font-size: 0.9rem;
}
.blog-loading-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid var(--gray-200, #e2e8f0);
  border-top-color: var(--blue-600, #1949b3);
  border-radius: 50%;
  animation: blogSpin 0.7s linear infinite;
}
@keyframes blogSpin {
  to { transform: rotate(360deg); }
}

/* ═══════════ EMPTY STATE ═══════════ */
.blog-empty {
  text-align: center;
  padding: 56px 20px;
  color: var(--gray-400, #94a3b8);
}
.blog-empty svg {
  margin-bottom: 12px;
  stroke: var(--gray-300, #cbd5e1);
}
.blog-empty p {
  font-size: 0.92rem;
}

/* ═══════════ ERROR STATE ═══════════ */
.blog-error {
  text-align: center;
  padding: 48px 20px;
  color: var(--gray-500, #64748b);
  font-size: 0.92rem;
}

/* ═══════════ PAGINATION ═══════════ */
.blog-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 36px 0 48px;
}
.blog-page-btn {
  min-width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--gray-200, #e2e8f0);
  border-radius: 8px;
  background: #fff;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--gray-600, #475569);
  cursor: pointer;
  transition: all 0.2s;
}
.blog-page-btn:hover:not(:disabled) {
  border-color: var(--blue-300, #93b8f5);
  color: var(--blue-600, #1949b3);
}
.blog-page-btn.active {
  background: var(--blue-600, #1949b3);
  border-color: var(--blue-600, #1949b3);
  color: #fff;
}
.blog-page-btn:disabled {
  opacity: 0.35;
  cursor: default;
}
.blog-page-dots {
  padding: 0 4px;
  color: var(--gray-400, #94a3b8);
  font-size: 0.85rem;
}

/* ═══════════ CATEGORY DOT IN FILTER BUTTONS ═══════════ */
.blog-cat-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
}
.blog-filter-btn.active .blog-cat-dot {
  background: #fff !important;
}

/* ═══════════ BADGES (Featured / Pinned) ═══════════ */
.blog-hcard-badges {
  position: absolute;
  top: 12px;
  left: 12px;
  display: flex;
  gap: 6px;
  z-index: 2;
}
.blog-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  backdrop-filter: blur(8px);
}
.blog-badge-pinned {
  background: rgba(255,255,255,0.9);
  color: var(--gray-800, #1e293b);
}
.blog-badge-featured {
  background: rgba(245,158,11,0.9);
  color: #fff;
}

/* ═══════════ STATS ROW (views + likes on cards) ═══════════ */
.blog-hcard-stats {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 10px;
}
.blog-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  color: var(--gray-400, #94a3b8);
}
.blog-stat svg {
  stroke: var(--gray-400, #94a3b8);
}

/* ═══════════ RESPONSIVE — FILTERS ═══════════ */
@media (max-width: 600px) {
  .blog-filter-row {
    gap: 6px;
  }
  .blog-filter-btn {
    padding: 6px 12px;
    font-size: 0.72rem;
  }
  .blog-tag-btn {
    padding: 4px 10px;
    font-size: 0.68rem;
  }
  .blog-search-bar {
    margin-top: 20px;
    padding: 8px 14px;
  }
  .blog-search-bar input {
    font-size: 0.85rem;
  }
}
