
/* V4.7 — Smart Import + Attachments */
.reservation-head-actions{display:flex;gap:.55rem;align-items:center;flex-wrap:wrap;justify-content:flex-end}
.smart-import-modal,.attachment-modal{max-width:760px}
.import-lead{margin:.35rem 0 1.1rem;color:var(--muted,#756a5f);line-height:1.55}
.import-source-grid{display:grid;grid-template-columns:1.35fr .85fr;gap:1rem}
.import-source-field,.attachment-picker{display:flex;flex-direction:column;gap:.45rem;font-weight:650}
.import-source-field textarea{min-height:210px;resize:vertical}
.import-source-field small,.attachment-picker small{font-weight:500;color:var(--muted,#756a5f);line-height:1.4}
.import-status{margin-top:1rem;padding:.8rem .9rem;border:1px solid rgba(107,82,58,.16);border-radius:14px;background:rgba(255,255,255,.55);font-size:.9rem;color:var(--muted,#756a5f)}
.import-status.good{border-color:rgba(59,126,83,.28);background:rgba(227,242,232,.72);color:#315e40}
.import-status.warn{border-color:rgba(185,126,49,.28);background:rgba(250,240,220,.78);color:#7b5725}
.attachment-owner{margin:.25rem 0 1rem;color:var(--muted,#756a5f)}
.attachment-picker{padding:1rem;border:1px dashed rgba(107,82,58,.25);border-radius:16px;background:rgba(255,255,255,.48)}
.attachment-list{display:grid;gap:.65rem;margin-top:1rem;max-height:42vh;overflow:auto}
.attachment-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:.75rem;align-items:center;padding:.8rem .9rem;border:1px solid rgba(107,82,58,.13);border-radius:14px;background:rgba(255,255,255,.62)}
.attachment-row strong{display:block;overflow-wrap:anywhere}
.attachment-row small{display:block;color:var(--muted,#756a5f);margin-top:.18rem}
.attachment-row-actions{display:flex;gap:.4rem}
.attachment-row-actions button,.attachment-chip{border:1px solid rgba(107,82,58,.16);background:rgba(255,255,255,.72);border-radius:999px;padding:.38rem .62rem;font-size:.78rem;cursor:pointer;color:inherit}
.attachment-chip{white-space:nowrap}
.attachment-chip.has-files{background:rgba(224,237,218,.85);border-color:rgba(83,124,75,.28)}
.attachment-storage-note{font-size:.82rem;color:var(--muted,#756a5f);line-height:1.45;margin-top:1rem}
.manager-row .row-actions,.custom-plan-item .row-actions{flex-wrap:wrap}
.import-review-banner{margin:.7rem 0 0;padding:.65rem .8rem;border-radius:12px;background:#f5eadb;color:#694f36;font-size:.84rem}
@media(max-width:700px){
  .import-source-grid{grid-template-columns:1fr}
  .reservation-head-actions{width:100%;justify-content:flex-start}
  .reservation-head-actions .btn{flex:1 1 145px}
  .smart-import-modal,.attachment-modal{width:min(94vw,760px);max-height:90vh;overflow:auto}
  .attachment-row{grid-template-columns:1fr}
  .attachment-row-actions{justify-content:flex-start}
}


/* V4.7.1 — Smart Import reliability */
.modal-backdrop{
  position:fixed;
  inset:0;
  z-index:2600;
  display:none;
  align-items:center;
  justify-content:center;
  padding:20px;
  background:rgba(48,31,22,.54);
  backdrop-filter:blur(8px);
  -webkit-backdrop-filter:blur(8px);
}
.modal-backdrop.open{display:flex!important}
.modal-backdrop .memory-modal{
  position:relative!important;
  inset:auto!important;
  display:block!important;
  width:min(760px,100%);
  max-height:min(90vh,820px);
  overflow:auto;
  border:1px solid rgba(151,101,65,.24);
  border-radius:24px;
  background:#fffaf4;
  color:#35241b;
  padding:24px;
  box-shadow:0 30px 90px rgba(53,31,18,.28);
}
.modal-backdrop .memory-modal h2{color:#35241b;margin:.3rem 0 .6rem}
.modal-backdrop .modal-close{
  position:absolute;
  top:14px;
  right:14px;
  width:38px;
  height:38px;
  border-radius:50%;
  border:1px solid rgba(107,82,58,.18);
  background:#fff;
  color:#533b2c;
  font-size:1.2rem;
  cursor:pointer;
}
.import-source-field textarea,
.import-source-field input,
.attachment-picker input{
  width:100%;
  box-sizing:border-box;
}
.import-source-field textarea{
  border:1px solid #d7b694;
  background:#fffdf9;
  color:#35241b;
  border-radius:14px;
  padding:12px 13px;
  font:inherit;
}
#importReservationBtn{display:inline-flex!important;visibility:visible!important;opacity:1!important}

@media(max-width:700px){
  .modal-backdrop{padding:12px;align-items:flex-end}
  .modal-backdrop .memory-modal{
    width:100%;
    max-height:88vh;
    border-radius:24px 24px 12px 12px;
    padding:20px 18px calc(20px + env(safe-area-inset-bottom));
  }
  .reservation-head-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr;
    gap:10px;
    width:100%;
  }
  .reservation-head-actions .btn{
    display:flex!important;
    width:100%;
    min-height:46px;
    justify-content:center;
    align-items:center;
  }
  #importReservationBtn{
    display:flex!important;
    order:1;
  }
  #addReservationProBtn{order:2}
}
@media(max-width:420px){
  .reservation-head-actions{grid-template-columns:1fr}
}
