/* ============================================================
   JAOTECH DIGITAL INSTITUTE
   Blog Page Styles
   ============================================================ */

/* BLOG HERO */
.blog-hero {
  padding: 150px 0 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.blog-hero-glow {
  position: absolute;
  top: -150px; left: 50%;
  transform: translateX(-50%);
  width: 800px; height: 600px;
  background: radial-gradient(ellipse, rgba(26, 26, 255, 0.11) 0%, rgba(102, 0, 204, 0.06) 40%, transparent 70%);
  pointer-events: none;
}

/* CATEGORY FILTERS */
.blog-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 36px;
}
.blog-cat {
  padding: 9px 20px;
  background: var(--white-ghost);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-family: var(--font-heading);
  font-size: 0.80rem;
  font-weight: 600;
  color: var(--white-soft);
  cursor: pointer;
  transition: var(--transition);
  letter-spacing: 0.02em;
}
.blog-cat:hover {
  border-color: var(--border-blue);
  color: var(--white);
}
.blog-cat.active {
  background: var(--blue);
  border-color: var(--blue);
  color: var(--white);
  box-shadow: 0 0 16px var(--blue-glow);
}

/* POST META SHARED */
.post-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.post-date,
.post-read {
  font-size: 0.76rem;
  color: var(--white-soft);
  font-family: var(--font-heading);
  font-weight: 500;
  letter-spacing: 0.04em;
}
.post-cat {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-family: var(--font-heading);
}
.post-cat-ai       { background: var(--blue-glow);               color: var(--blue-light); border: 1px solid var(--border-blue); }
.post-cat-web3     { background: rgba(255, 215, 0, 0.10);        color: var(--gold);       border: 1px solid rgba(255, 215, 0, 0.25); }
.post-cat-skills   { background: rgba(37, 211, 102, 0.10);       color: #25d366;           border: 1px solid rgba(37, 211, 102, 0.25); }
.post-cat-income   { background: var(--red-glow);                 color: var(--red-light);  border: 1px solid rgba(255, 26, 26, 0.25); }
.post-cat-mindset  { background: rgba(102, 0, 204, 0.12);        color: var(--purple-light); border: 1px solid rgba(102, 0, 204, 0.28); }

/* FEATURED POST */
.featured-post-section { background: var(--black-soft); }
.featured-post {
  background: var(--black-card);
  border: 1px solid var(--border-blue);
  border-radius: var(--radius-xl);
  padding: 48px 44px;
  position: relative;
  overflow: hidden;
}
.featured-post::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), var(--purple-light), var(--gold));
}
.featured-post-label {
  font-family: var(--font-display);
  font-size: 0.58rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 24px;
  opacity: 0.9;
}
.featured-post-inner {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 48px;
  align-items: center;
}
.featured-post-title {
  font-size: clamp(1.4rem, 2.8vw, 2rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
  color: var(--white);
}
.featured-post-excerpt {
  font-size: 0.95rem;
  color: var(--white-soft);
  line-height: 1.78;
  margin-bottom: 24px;
}
.featured-post-author {
  display: flex;
  align-items: center;
  gap: 12px;
}
.post-author-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.78rem;
  flex-shrink: 0;
  color: var(--white);
}
.post-author-name {
  display: block;
  font-weight: 700;
  font-size: 0.88rem;
  font-family: var(--font-heading);
  color: var(--white);
}
.post-author-role {
  display: block;
  font-size: 0.75rem;
  color: var(--white-soft);
  margin-top: 2px;
}
.featured-post-visual {
  display: flex;
  align-items: center;
  justify-content: center;
}
.featured-post-img-wrap {
  width: 280px;
  height: 280px;
  border-radius: var(--radius-xl);
  background: radial-gradient(circle, rgba(26, 26, 255, 0.08), transparent);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.featured-post-img {
  width: 200px;
  height: 200px;
  object-fit: contain;
  opacity: 0.9;
}

/* BLOG LAYOUT */
.blog-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 48px;
  align-items: flex-start;
}

/* BLOG POSTS GRID */
.blog-posts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.blog-post-card {
  background: var(--black-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}
.blog-post-card:hover {
  border-color: var(--border-blue);
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(26, 26, 255, 0.10);
}
.blog-post-card.hidden { display: none; }

.post-card-img-wrap {
  position: relative;
  height: 160px;
  overflow: hidden;
  background: var(--black);
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border);
}
.post-card-img {
  width: 90px;
  height: 90px;
  object-fit: contain;
  opacity: 0.5;
}
.post-card-cat {
  position: absolute;
  top: 14px;
  left: 14px;
}
.post-card-body {
  padding: 22px 22px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.post-card-title {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 10px;
  color: var(--white);
  flex: 1;
}
.post-card-excerpt {
  font-size: 0.83rem;
  color: var(--white-soft);
  line-height: 1.65;
  margin-bottom: 18px;
}
.post-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  margin-top: auto;
}
.post-author-mini {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.76rem;
  color: var(--white-soft);
  font-family: var(--font-heading);
  font-weight: 500;
}
.post-author-avatar-sm {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.60rem;
  font-weight: 700;
  font-family: var(--font-heading);
  color: var(--white);
  flex-shrink: 0;
}
.post-read-link {
  font-family: var(--font-heading);
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--blue-light);
  transition: var(--transition);
  white-space: nowrap;
}
.post-read-link:hover { color: var(--gold); }

/* SIDEBAR */
.blog-sidebar {
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.sidebar-widget {
  background: var(--black-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 22px;
}
.sidebar-widget-title {
  font-family: var(--font-heading);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--white);
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.sidebar-author {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.sidebar-author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.80rem;
  color: var(--white);
  flex-shrink: 0;
}
.sidebar-author-info strong {
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  font-family: var(--font-heading);
  color: var(--white);
  margin-bottom: 4px;
}
.sidebar-author-info span {
  font-size: 0.78rem;
  color: var(--white-soft);
  line-height: 1.55;
}
.sidebar-cats {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.sidebar-cat {
  display: block;
  width: 100%;
  text-align: left;
  padding: 9px 14px;
  background: var(--white-ghost);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-size: 0.80rem;
  font-weight: 600;
  color: var(--white-soft);
  cursor: pointer;
  transition: var(--transition);
}
.sidebar-cat:hover,
.sidebar-cat.active {
  background: var(--blue-glow);
  border-color: var(--border-blue);
  color: var(--white);
}
.sidebar-enroll {
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.06), rgba(26, 26, 255, 0.06));
  border-color: rgba(255, 215, 0, 0.2);
}
.sidebar-enroll-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 10px;
}
.sidebar-enroll p {
  font-size: 0.83rem;
  color: var(--white-soft);
  line-height: 1.65;
}
.sidebar-community-text {
  font-size: 0.83rem;
  color: var(--white-soft);
  line-height: 1.65;
}

/* LOAD MORE */
.blog-load-more {
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid var(--border);
}
.load-more-note {
  font-size: 0.88rem;
  color: var(--white-soft);
  margin-bottom: 20px;
}

/* NEWSLETTER */
.newsletter-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.newsletter-content p {
  font-size: 0.98rem;
  color: var(--white-soft);
  line-height: 1.80;
  margin-top: 0;
}
.newsletter-options {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.newsletter-option {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--black-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: var(--transition);
  color: var(--white);
}
.newsletter-option:hover {
  border-color: var(--border-blue);
  transform: translateX(4px);
}
.nl-option-abbr {
  width: 42px;
  height: 42px;
  border-radius: var(--radius);
  background: var(--blue-glow);
  border: 1px solid var(--border-blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--blue-light);
  flex-shrink: 0;
  letter-spacing: 0.06em;
}
.newsletter-option strong {
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  font-family: var(--font-heading);
  margin-bottom: 2px;
}
.newsletter-option span {
  font-size: 0.76rem;
  color: var(--white-soft);
}

/* CTA banner glow */
.cta-banner-glow {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 800px; height: 400px;
  background: radial-gradient(ellipse, rgba(26, 26, 255, 0.18), rgba(102, 0, 204, 0.08), transparent 70%);
  pointer-events: none;
}

/* RESPONSIVE */
@media (max-width: 1100px) {
  .blog-layout          { grid-template-columns: 1fr; }
  .blog-sidebar         { position: static; display: grid; grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 1024px) {
  .featured-post-inner  { grid-template-columns: 1fr; gap: 32px; }
  .featured-post-visual { display: none; }
  .newsletter-wrap      { grid-template-columns: 1fr; gap: 48px; }
}
@media (max-width: 768px) {
  .blog-posts           { grid-template-columns: 1fr; }
  .blog-sidebar         { grid-template-columns: 1fr; }
  .featured-post        { padding: 30px 24px; }
  .blog-categories      { gap: 8px; }
  .blog-cat             { font-size: 0.74rem; padding: 7px 14px; }
}
@media (max-width: 480px) {
  .newsletter-options   { gap: 10px; }
  .newsletter-option    { padding: 12px 14px; gap: 12px; }
}

/* ── BLOG LIVE BADGE ── */
.blog-hero-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin: 20px 0 0;
  flex-wrap: wrap;
}
.blog-live-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(37, 211, 102, 0.08);
  border: 1px solid rgba(37, 211, 102, 0.25);
  border-radius: 100px;
  font-family: var(--font-heading);
  font-size: 0.76rem;
  font-weight: 700;
  color: #25d366;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #25d366;
  box-shadow: 0 0 8px rgba(37, 211, 102, 0.7);
  animation: livePulse 1.8s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.5; transform: scale(0.7); }
}
.blog-post-count {
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--white-soft);
  letter-spacing: 0.06em;
}

/* ── LOADING STATE ── */
.blog-loading-state {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 0;
}
.blog-loading-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}
.blog-loading-ring {
  width: 44px;
  height: 44px;
  border: 3px solid var(--border);
  border-top-color: var(--blue-light);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
.blog-loading-inner p {
  font-size: 0.88rem;
  color: var(--white-soft);
  font-family: var(--font-heading);
}

/* ── ERROR STATE ── */
.blog-error-state {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 0;
}
.blog-error-inner {
  text-align: center;
  max-width: 480px;
}
.blog-error-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--red-glow);
  border: 1px solid rgba(255, 26, 26, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--red-light);
  margin: 0 auto 20px;
}
.blog-error-inner h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 12px;
}
.blog-error-inner p {
  font-size: 0.90rem;
  color: var(--white-soft);
  line-height: 1.72;
}

/* ── HOW PUBLISHING WORKS ── */
.blog-how-steps {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}
.blog-how-step {
  flex: 1;
  min-width: 160px;
  max-width: 210px;
  text-align: center;
  padding: 30px 20px;
  background: var(--black-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}
.blog-how-step:hover {
  border-color: var(--border-blue);
  transform: translateY(-4px);
}
.blog-how-num {
  font-family: var(--font-display);
  font-size: 0.60rem;
  color: var(--blue-light);
  letter-spacing: 0.2em;
  margin-bottom: 12px;
}
.blog-how-step h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.blog-how-step p {
  font-size: 0.80rem;
  color: var(--white-soft);
  line-height: 1.62;
}
.blog-how-arrow {
  font-size: 1.2rem;
  color: var(--border-blue);
  flex-shrink: 0;
  font-family: var(--font-heading);
}

/* ── CTA BANNER GLOW ── */
.cta-banner-glow {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 800px; height: 400px;
  background: radial-gradient(ellipse, rgba(26,26,255,0.18), rgba(102,0,204,0.08), transparent 70%);
  pointer-events: none;
}

@media (max-width: 768px) {
  .blog-how-steps  { flex-direction: column; align-items: stretch; }
  .blog-how-step   { max-width: 100%; }
  .blog-how-arrow  { transform: rotate(90deg); text-align: center; }
}
