/* AInsight Featured Media v1.7.1 */
:root{
  --featured-ratio:16 / 9;
  --featured-navy:#0d3158;
  --featured-gold:#f0aa2a;
  --featured-green:#16835f;
  --featured-red:#c8333d;
}

.featured-upload-manager{
  margin:1rem 0;
  padding:1rem;
  border:1px solid #d7e1eb;
  border-radius:14px;
  background:#f8fafc;
}

.featured-upload-head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:1rem;
  margin-bottom:.8rem;
}

.featured-upload-head strong,
.featured-upload-head small{display:block}

.featured-upload-head small{
  color:#64748b;
  margin-top:.2rem;
}

.featured-size-badge{
  flex:0 0 auto;
  padding:.3rem .65rem;
  border-radius:999px;
  background:#fff3d6;
  color:#805507;
  font-size:.76rem;
  font-weight:900;
  direction:ltr;
}

.featured-dropzone{
  min-height:180px;
  padding:1rem;
  border:2px dashed #9db4d2;
  border-radius:13px;
  display:grid;
  place-items:center;
  align-content:center;
  gap:.35rem;
  text-align:center;
  cursor:pointer;
  background:#fff;
  transition:.2s ease;
  outline:none;
}

.featured-dropzone:hover,
.featured-dropzone:focus,
.featured-dropzone.is-dragging{
  border-color:var(--featured-gold);
  background:#fffaf0;
}

.featured-dropzone.has-file{
  border-color:#16835f;
  background:#effbf5;
}

.featured-dropzone.is-uploading{
  border-color:#2563a0;
  background:#eef6ff;
  cursor:progress;
}

.featured-dropzone.is-uploaded{
  border-color:#16835f;
  background:#eaf9f2;
}

.featured-dropzone.has-error{
  border-color:var(--featured-red);
  background:#fff2f2;
}

.featured-file-input{
  display:none!important;
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  opacity:0!important;
  overflow:hidden!important;
  pointer-events:none!important;
}

.featured-drop-icon{font-size:2.2rem}
.featured-dropzone small{color:#64748b}

.featured-error{
  color:#a02222;
  font-weight:800;
  font-size:.82rem;
}

.featured-preview{
  display:grid;
  grid-template-columns:minmax(180px,280px) 1fr;
  gap:1rem;
  align-items:center;
  margin-top:1rem;
  padding:.8rem;
  border:1px solid #d7e1eb;
  border-radius:12px;
  background:#fff;
}

.featured-preview[hidden]{display:none}

.featured-preview img{
  width:100%;
  aspect-ratio:var(--featured-ratio);
  object-fit:cover;
  border-radius:10px;
  background:#eaf0f7;
}

.featured-preview-info strong,
.featured-preview-info small{
  display:block;
  margin-bottom:.45rem;
}

.featured-preview-info small{
  color:#64748b;
  direction:ltr;
  text-align:right;
}

.featured-actions{
  display:flex;
  flex-wrap:wrap;
  gap:.55rem;
  margin-top:.75rem;
}

.featured-status{
  min-height:1.6rem;
  margin-top:.5rem;
  font-size:.82rem;
  font-weight:800;
}

.featured-status.is-ready{color:#805507}
.featured-status.is-uploading{color:#1d5f94}
.featured-status.is-success{color:#12694d}
.featured-status.is-error{color:#a02222}

.featured-progress{
  height:8px;
  overflow:hidden;
  margin-top:.6rem;
  border-radius:999px;
  background:#e7edf4;
}

.featured-progress[hidden]{display:none}

.featured-progress span{
  display:block;
  width:0;
  height:100%;
  border-radius:inherit;
  background:linear-gradient(90deg,#0d3158,#f0aa2a);
  transition:width .25s ease;
}

.featured-remove-existing{
  display:flex;
  gap:.55rem;
  align-items:center;
  margin-top:.9rem;
  font-size:.85rem;
}

.featured-upload-note{
  margin-top:.75rem;
  color:#64748b;
  font-size:.78rem;
  line-height:1.8;
}

:is(
  .post-card,.article-card,.blog-card,.news-card,.featured-card,
  .post-thumbnail,.post-cover,.article-cover,.post-image,
  .featured-image,.entry-thumbnail,.card-img-wrap
){
  overflow:hidden;
}

:is(
  .post-card,.article-card,.blog-card,.news-card,.featured-card,
  .post-thumbnail,.post-cover,.article-cover,.post-image,
  .featured-image,.entry-thumbnail,.card-img-wrap
) > img,
img.card-img-top,
img.post-thumbnail,
img.featured-image,
img[data-featured-image]{
  display:block;
  width:100%;
  aspect-ratio:var(--featured-ratio);
  height:auto;
  object-fit:cover;
  object-position:center;
  background:#eaf0f7;
}

:is(.post-content,.article-content,.entry-content,.content-body,.single-post-content) img{
  display:block;
  max-width:100%;
  height:auto;
  margin-inline:auto;
}

:is(.post-hero,.article-hero,.hero-post,.featured-hero) img{
  display:block;
  width:100%;
  aspect-ratio:var(--featured-ratio);
  object-fit:cover;
  object-position:center;
}

@media(max-width:767px){
  .featured-upload-head{align-items:flex-start}
  .featured-preview{grid-template-columns:1fr}
  .featured-actions .btn{width:100%}
}
