/* SH 4 - Upload Hardening + Cover WebP */

.book-form-grid-v4{
  display:grid;
  grid-template-columns:minmax(0,1fr) 360px;
  gap:22px;
  align-items:start;
  margin-bottom:22px;
}

.cover-preview-v4{
  width:100%;
  aspect-ratio:3/4;
  border-radius:22px;
  overflow:hidden;
  background:linear-gradient(145deg,#eff6ff,#fff);
  border:1px solid var(--line,#e2e8f0);
  box-shadow:0 18px 44px rgba(15,23,42,.09);
  margin-bottom:18px;
}

.cover-preview-v4 img{
  width:100%;
  height:100%;
  object-fit:cover;
}

.file-list-v4{
  display:flex;
  flex-direction:column;
  gap:12px;
  margin-top:18px;
}

.file-item-v4{
  display:flex;
  align-items:center;
  gap:14px;
  padding:14px;
  border:1px solid var(--line,#e2e8f0);
  border-radius:18px;
  background:rgba(248,250,252,.55);
}

.file-item-v4 > div{
  flex:1;
  min-width:0;
}

.file-item-v4 strong,
.file-item-v4 small{
  display:block;
}

.file-item-v4 small{
  color:var(--muted,#64748b);
  margin-top:4px;
}

.file-type-v4{
  width:52px;
  height:52px;
  border-radius:16px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:13px;
  font-weight:900;
  flex:0 0 auto;
}

.file-type-v4.pdf{
  background:#fef2f2;
  color:#dc2626;
  border:1px solid #fecaca;
}

.file-type-v4.epub{
  background:#ecfdf5;
  color:#047857;
  border:1px solid #bbf7d0;
}

html[data-theme="dark"] .file-item-v4{
  background:#0b1220!important;
  border-color:var(--line,#243449)!important;
}

html[data-theme="dark"] .cover-preview-v4{
  background:#0b1220!important;
  border-color:var(--line,#243449)!important;
}

@media(max-width:920px){
  .book-form-grid-v4{
    grid-template-columns:1fr;
  }
}

@media(max-width:760px){
  .file-item-v4{
    align-items:flex-start;
    flex-direction:column;
  }
}
