/* ==========================================================================
   AnyBike — admin-files.css
   Files v8.1 — Deal Files
   ========================================================================== */

.deal-files-wrap{
  display:grid;
  gap:14px;
}

.deal-file-dropzone{
  position:relative;
  min-height:150px;
  padding:24px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  background:#111;
  border:2px dashed rgba(255,255,255,.20);
  border-radius:14px;
  cursor:pointer;
  transition:
    border-color .18s ease,
    background .18s ease,
    transform .18s ease,
    opacity .18s ease;
}

.deal-file-dropzone:hover,
.deal-file-dropzone.drag-active{
  background:rgba(237,28,36,.08);
  border-color:#ed1c24;
}

.deal-file-dropzone.drag-active{
  transform:scale(1.005);
}

.deal-file-dropzone.uploading{
  pointer-events:none;
  opacity:.65;
}

.deal-file-dropzone:focus{
  outline:2px solid #ed1c24;
  outline-offset:3px;
}

.deal-file-dropzone-icon{
  margin-bottom:10px;
  font-size:32px;
  line-height:1;
}

.deal-file-dropzone strong{
  display:block;
  margin-bottom:6px;
  color:#fff;
  font-size:17px;
  font-weight:900;
}

.deal-file-dropzone small{
  max-width:680px;
  color:#999;
  font-size:13px;
  line-height:1.5;
}

.deal-file-input{
  display:none;
}

.deal-file-upload-status{
  display:none;
  padding:11px 13px;
  border-radius:10px;
  background:#151515;
  border:1px solid rgba(255,255,255,.10);
  color:#ddd;
  font-size:13px;
  font-weight:800;
  line-height:1.4;
}

.deal-file-upload-status.show{
  display:block;
}

.deal-file-upload-status.success{
  color:#8cffb1;
  border-color:rgba(51,204,102,.40);
  background:rgba(51,204,102,.08);
}

.deal-file-upload-status.error{
  color:#ff9b9b;
  border-color:rgba(237,28,36,.45);
  background:rgba(237,28,36,.08);
}

.deal-files-list{
  display:grid;
  gap:8px;
}

.deal-file-empty{
  padding:18px;
  text-align:center;
  color:#999;
  background:#111;
  border:1px solid rgba(255,255,255,.08);
  border-radius:12px;
  font-size:13px;
  line-height:1.5;
}

.deal-file-row{
  display:grid;
  grid-template-columns:44px minmax(0,1fr) auto;
  gap:12px;
  align-items:center;
  padding:11px 12px;
  background:#121212;
  border:1px solid rgba(255,255,255,.09);
  border-radius:12px;
  transition:
    border-color .16s ease,
    background .16s ease,
    opacity .16s ease;
}

.deal-file-row:hover{
  border-color:rgba(237,28,36,.40);
  background:#151515;
}

.deal-file-icon{
  width:42px;
  height:42px;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:10px;
  background:#202020;
  border:1px solid rgba(255,255,255,.08);
  font-size:21px;
  line-height:1;
}

.deal-file-info{
  min-width:0;
}

.deal-file-name{
  display:block;
  color:#fff;
  font-size:14px;
  font-weight:900;
  line-height:1.3;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.deal-file-meta{
  display:flex;
  flex-wrap:wrap;
  gap:6px 12px;
  margin-top:5px;
  color:#888;
  font-size:11px;
  font-weight:800;
  line-height:1.35;
}

.deal-file-meta span{
  display:inline-flex;
  align-items:center;
}

.deal-file-actions{
  display:flex;
  flex-wrap:wrap;
  justify-content:flex-end;
  gap:6px;
}

.deal-file-actions button{
  width:auto;
  min-height:34px;
  margin:0;
  padding:7px 10px;
  border-radius:8px;
  background:#202020;
  color:#ddd;
  border:1px solid rgba(255,255,255,.11);
  font-size:12px;
  font-weight:900;
  line-height:1.2;
  cursor:pointer;
}

.deal-file-actions button:hover{
  background:#292929;
  color:#fff;
  border-color:rgba(237,28,36,.45);
}

.deal-file-actions .deal-file-delete{
  color:#ff8589;
}

.deal-file-actions .deal-file-delete:hover{
  background:rgba(237,28,36,.14);
  border-color:rgba(237,28,36,.55);
  color:#fff;
}

.deal-file-preview-modal{
  position:fixed;
  inset:0;
  z-index:1000;
  display:none;
  align-items:center;
  justify-content:center;
  padding:24px;
  background:rgba(0,0,0,.88);
  backdrop-filter:blur(7px);
}

.deal-file-preview-modal.open{
  display:flex;
}

.deal-file-preview-card{
  width:min(1100px,100%);
  max-height:92vh;
  display:flex;
  flex-direction:column;
  overflow:hidden;
  background:#101010;
  border:1px solid rgba(255,255,255,.16);
  border-radius:16px;
  box-shadow:0 30px 100px rgba(0,0,0,.65);
}

.deal-file-preview-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:13px 15px;
  background:#171717;
  border-bottom:1px solid rgba(255,255,255,.10);
}

.deal-file-preview-title{
  min-width:0;
  color:#fff;
  font-size:14px;
  font-weight:900;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.deal-file-preview-close{
  width:38px;
  height:38px;
  flex:0 0 38px;
  margin:0;
  padding:0;
  display:flex;
  align-items:center;
  justify-content:center;
  border-radius:9px;
  background:#242424;
  color:#fff;
  border:1px solid rgba(255,255,255,.10);
  font-size:16px;
  cursor:pointer;
}

.deal-file-preview-close:hover{
  background:#ed1c24;
  border-color:#ed1c24;
}

.deal-file-preview-body{
  min-height:420px;
  height:calc(92vh - 66px);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:auto;
  padding:16px;
  background:#080808;
}

.deal-file-preview-body img{
  display:block;
  max-width:100%;
  max-height:100%;
  object-fit:contain;
  border-radius:8px;
}

.deal-file-preview-body iframe{
  display:block;
  width:100%;
  height:100%;
  min-height:600px;
  border:0;
  background:#fff;
  border-radius:8px;
}

.deal-file-preview-unavailable{
  padding:24px;
  color:#bbb;
  text-align:center;
  line-height:1.6;
}

@media(max-width:760px){
  .deal-file-dropzone{
    min-height:135px;
    padding:20px 14px;
  }

  .deal-file-row{
    grid-template-columns:40px minmax(0,1fr);
  }

  .deal-file-icon{
    width:38px;
    height:38px;
    font-size:19px;
  }

  .deal-file-actions{
    grid-column:1 / -1;
    justify-content:flex-start;
  }

  .deal-file-actions button{
    flex:1 1 auto;
  }

  .deal-file-preview-modal{
    padding:8px;
  }

  .deal-file-preview-card{
    max-height:96vh;
    border-radius:12px;
  }

  .deal-file-preview-body{
    min-height:300px;
    height:calc(96vh - 66px);
    padding:8px;
  }

  .deal-file-preview-body iframe{
    min-height:500px;
  }
}