/* IST Continue Reading - Styles (v1.7.2) - FORCE STYLES */

/* FORCE centered title in gray band - override all theme styles */
.wp-block-post-title,
h1.wp-block-post-title,
.entry-title,
.wp-block-post-title.entry-title {
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  font-size: 2rem !important;
  font-weight: 800 !important;
  margin: 0.5em auto !important;
  text-align: center !important;
  width: 100% !important;
  display: block !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

/* Continue section */
.ist-continue {
  margin: 28px auto !important;
  max-width: 1200px !important;
  background: #f7f9fc !important;
  border: 1px solid #e2e7f0 !important;
  border-radius: 16px !important;
  padding: 22px !important;
}

.ist-continue h2 {
  text-align: center !important;
  margin: 0 0 14px !important;
  font-size: clamp(20px, 3vw, 28px) !important;
  font-weight: 800 !important;
  color: #0f172a !important;
}

.ist-row {
  display: flex !important;
  gap: 16px !important;
  flex-wrap: wrap !important;
  justify-content: center !important;
}

/* Full-card links (entire card is clickable) */
.ist-card {
  display: block !important;
  text-decoration: none !important;
  text-align: center !important;
  cursor: pointer !important;
  flex: 1 1 220px !important;
  max-width: 260px !important;
  min-width: 200px !important;
  padding: 16px !important;
  background: #ffffff !important;
  border: 1px solid #dbe3ee !important;
  border-radius: 12px !important;
  transition: 0.15s ease !important;
  color: inherit !important;
  height: auto !important;
  min-height: 80px !important;
}

.ist-card:hover {
  background: #f0f4fa !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08) !important;
}

.ist-card .title,
.ist-card span.title {
  display: block !important;
  font-weight: 800 !important;
  color: #166bcc !important;
  margin-bottom: 4px !important;
  font-size: 1.05em !important;
  word-break: break-word !important;
  line-height: 1.3 !important;
}

.ist-card:hover .title {
  color: #0d4d94 !important;
}

.ist-card small {
  color: #5f6980 !important;
  font-size: 0.9em !important;
  display: block !important;
  margin-top: 4px !important;
}

/* Empty state (shown when no recents yet) */
.ist-empty {
  display: none !important;
  border: 1px dashed #c6d1e3 !important;
  background: #ffffff !important;
  padding: 18px !important;
  border-radius: 12px !important;
  color: #5f6980 !important;
  text-align: center !important;
  font-style: italic !important;
  width: 100% !important;
}

/* Mobile portrait - FORCE bigger text */
@media (max-width: 600px) and (orientation: portrait) {
  .ist-row {
    gap: 12px !important;
    padding: 0 4px !important;
  }

  .ist-card {
    flex: 1 1 calc(50% - 6px) !important;
    max-width: none !important;
    min-width: auto !important;
    min-height: 70px !important;
    max-height: 110px !important;
    padding: 12px 8px !important;
  }

  /* FORCE bigger text on mobile */
  .ist-card .title,
  .ist-card span.title {
    font-size: 1.15em !important;
    line-height: 1.25 !important;
    margin-bottom: 2px !important;
  }

  .ist-card small {
    font-size: 1.0em !important;
    margin-top: 2px !important;
  }

  .wp-block-post-title,
  h1.wp-block-post-title {
    font-size: 1.8rem !important;
  }
}

/* Mobile landscape */
@media (max-width: 900px) and (orientation: landscape) {
  .ist-card {
    flex: 1 1 200px !important;
    max-width: 220px !important;
    min-height: 75px !important;
  }

  .ist-card .title,
  .ist-card span.title {
    font-size: 1.0em !important;
  }

  .ist-card small {
    font-size: 0.9em !important;
  }
}

/* Tablet and desktop */
@media (min-width: 769px) {
  .ist-card {
    flex: 1 1 220px !important;
    max-width: 260px !important;
    min-height: 90px !important;
  }

  .ist-card .title,
  .ist-card span.title {
    font-size: 1.05em !important;
  }

  .ist-card small {
    font-size: 0.9em !important;
  }
}
