/* ============================================================
   CEEIA 88<sup>th</sup> — Detail Page Styles
   Used by: detail.shtml
   ============================================================ */

/* ----- Article Hero Header ----- */
.detail-hero {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  margin-bottom: 1.5rem;
  /* Default rich gradient — visible when no image is set */
  /*background:
    radial-gradient(ellipse 80% 100% at 85% 0%, rgba(196, 150, 60, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse 60% 80% at 15% 100%, rgba(196, 18, 48, 0.08) 0%, transparent 55%),
    radial-gradient(ellipse 50% 60% at 50% 30%, rgba(43, 124, 211, 0.06) 0%, transparent 55%),
    linear-gradient(160deg, #0a1a33 0%, #0f2340 30%, #1a355a 70%, #0f2340 100%);*/
}
/* Dot-grid texture layer */
.detail-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.04;
  /*background-image: radial-gradient(circle, #fff 1px, transparent 1px);*/
  background-size: 18px 18px;
}
/* Decorative blobs */
.detail-hero::after {
  content: "";
  position: absolute;
  z-index: 1;
  pointer-events: none;
  top: -30%;
  right: -8%;
  width: 18rem;
  height: 18rem;
  border-radius: 50%;
  background: rgba(196, 150, 60, 0.06);
}
.detail-hero__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-size: cover;
  background-position: center;
  /* image set via inline style when available */
}
.detail-hero__bg--has-image {
  z-index: 1;
}
.detail-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  /*background: linear-gradient(
    to top,
    rgba(10, 26, 51, 0.92),
    rgba(15, 35, 64, 0.50),
    rgba(15, 35, 64, 0.20)
  );*/
}
.detail-hero__content {
  position: relative;
  z-index: 3;
  max-width: 100%;
}
@media (min-width: 768px) {
  .detail-hero {
  }
  .detail-hero__content {
  }
}

.detail-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  background: var(--c-red);
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  margin-bottom: 1rem;
  letter-spacing: 0.025em;
}
.detail-hero__title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--c-navy);
  margin-bottom: 0.75rem;
  line-height: 1.25;
}
@media (min-width: 768px) {
  .detail-hero__title {
    font-size: 2rem;
  }
}
@media (min-width: 1024px) {
  .detail-hero__title {
    font-size: 2.375rem;
  }
}

/* ----- Article Meta Row ----- */
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.5rem;
  padding-bottom: 1.25rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--c-border);
}
.detail-meta__item {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.8125rem;
  color: var(--c-text-mid);
}
.detail-meta__item .iconfont {
  color: var(--c-text-light);
  font-size: 15px;
}
.detail-meta__author {
  font-weight: 500;
  color: var(--c-navy);
}
.detail-meta__dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--c-border);
}
.detail-meta__read-time {
  color: var(--c-text-light);
}

/* ----- Featured Image ----- */
.detail-featured-img {
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-md);
}
.detail-featured-img img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.5s var(--ease-out);
}
.detail-featured-img:hover img {
  transform: scale(1.01);
}

/* ----- Article Body ----- */
.detail-body {
  font-size: 0.9375rem;
  color: var(--c-text-mid);
  line-height: 1.8;
}
@media (min-width: 768px) {
  .detail-body {
    font-size: 1rem;
  }
}

.detail-body h2 {
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--c-navy);
  margin: 2.5rem 0 0.75rem;
  line-height: 1.3;
}
.detail-body h2:first-child {
  margin-top: 0;
}
.detail-body h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--c-navy);
  margin: 2rem 0 0.625rem;
  line-height: 1.35;
}
.detail-body p {
  margin-bottom: 1.25rem;
}
.detail-body a {
  color: var(--c-red);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s;
}
.detail-body a:hover {
  color: var(--c-red-hover);
}

/* Blockquote */
.detail-body blockquote {
  position: relative;
  margin: 2rem 0;
  padding: 1.5rem 2rem;
  background: var(--c-bg-gray);
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--c-gold);
  font-style: italic;
  color: var(--c-navy);
}
.detail-body blockquote::before {
  content: "\201C";
  position: absolute;
  top: 0.25rem;
  left: 0.75rem;
  font-size: 3rem;
  color: var(--c-gold);
  font-style: normal;
  line-height: 1;
  opacity: 0.4;
}
.detail-body blockquote p {
  margin-bottom: 0.5rem;
}
.detail-body blockquote p:last-child {
  margin-bottom: 0;
}

/* Lists */
.detail-body ul,
.detail-body ol {
  margin: 1rem 0 1.5rem;
  padding-left: 1.25rem;
}
.detail-body ul {
  list-style: none;
}
.detail-body ul li {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 0.5rem;
}
.detail-body ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-red);
}
.detail-body ol li {
  margin-bottom: 0.5rem;
}

/* Inline highlight */
.detail-body strong {
  color: var(--c-navy);
  font-weight: 600;
}

/* ----- Info Alert (inline callout) ----- */
.detail-callout {
  background: var(--c-bg-gray);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin: 2rem 0;
}
.detail-callout__icon {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--radius-md);
  background: var(--c-blue-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--c-blue);
}
.detail-callout__text {
  font-size: 0.875rem;
  color: var(--c-text-mid);
  line-height: 1.6;
}
.detail-callout__text strong {
  color: var(--c-navy);
}

/* ----- Tags ----- */
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--c-border);
}
.detail-tags__label {
  display: flex;
  align-items: center;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--c-text-light);
  margin-right: 0.25rem;
}
.detail-tag {
  display: inline-block;
  padding: 0.3125rem 0.875rem;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 9999px;
  background: var(--c-bg-gray);
  color: var(--c-text-mid);
  transition: all 0.2s;
  cursor: pointer;
}
.detail-tag:hover {
  background: var(--c-navy);
  color: #fff;
}

/* ----- Share Section ----- */
.detail-share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 2rem;
  padding: 1.25rem 1.5rem;
  background: var(--c-bg-gray);
  border-radius: var(--radius-xl);
}
.detail-share__label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--c-navy);
  margin-right: 0.5rem;
}
.detail-share__btn {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s var(--ease-out);
  color: var(--c-text-mid);
  background: #fff;
  border: 1px solid var(--c-border);
}
.detail-share__btn:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.detail-share__btn--facebook:hover { background: #1877f2; border-color: #1877f2; }
.detail-share__btn--twitter:hover  { background: #1da1f2; border-color: #1da1f2; }
.detail-share__btn--linkedin:hover { background: #0a66c2; border-color: #0a66c2; }
.detail-share__btn--link:hover     { background: var(--c-navy); border-color: var(--c-navy); }

/* ----- Prev / Next Navigation ----- */
.detail-nav {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin-top: 2.5rem;
}
@media (min-width: 640px) {
  .detail-nav {
    grid-template-columns: 1fr 1fr;
  }
}
.detail-nav__card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--c-border);
  transition: all 0.25s var(--ease-out);
  cursor: pointer;
}
.detail-nav__card:hover {
  box-shadow: var(--shadow-md);
  border-color: rgba(196, 18, 48, 0.2);
}
.detail-nav__card--next {
  text-align: right;
  flex-direction: row-reverse;
}
.detail-nav__arrow {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--c-bg-gray);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--c-text-mid);
  transition: all 0.2s;
}
.detail-nav__card:hover .detail-nav__arrow {
  background: var(--c-red);
  color: #fff;
}
.detail-nav__info {
  flex: 1;
  min-width: 0;
}
.detail-nav__label {
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--c-text-light);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.25rem;
}
.detail-nav__title {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--c-navy);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s;
}
.detail-nav__card:hover .detail-nav__title {
  color: var(--c-red);
}

/* ----- Related Articles (Sidebar Card) ----- */
.related-card {
  background: #fff;
  border-radius: var(--radius-xl);
  border: 1px solid var(--c-border);
  overflow: hidden;
  margin-top: 1rem;
}
.related-card__header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--c-border);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.related-card__header-icon {
  width: 2rem;
  height: 2rem;
  border-radius: var(--radius-md);
  background: var(--c-red-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--c-red);
}
.related-card__header-title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--c-navy);
}
.related-card__item {
  display: block;
  padding: 0.875rem 1.25rem;
  border-bottom: 1px solid var(--c-border);
  transition: background 0.2s;
  cursor: pointer;
}
.related-card__item:last-child {
  border-bottom: none;
}
.related-card__item:hover {
  background: var(--c-bg-gray);
}
.related-card__item-date {
  font-size: 0.6875rem;
  color: var(--c-red);
  font-weight: 500;
  margin-bottom: 0.125rem;
}
.related-card__item-title {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--c-navy);
  line-height: 1.45;
  transition: color 0.2s;
}
.related-card__item:hover .related-card__item-title {
  color: var(--c-blue);
}

/* ---- Back to list button ---- */
.sidebar-back-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-lg);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--c-text-mid);
  cursor: pointer;
  transition: all 0.2s var(--ease-out);
  margin-bottom: 0.5rem;
}
.sidebar-back-link:hover {
  background: var(--c-bg-gray);
  color: var(--c-navy);
}

/* ---- Sticky Sidebar ---- */
.sidebar-desktop__inner {
  position: sticky;
  top: 5rem;
}
