/* Lịch Việt v1.4.1 — universal, progressively enhanced upload field.
   JS only hides the native input after a functional replacement is installed.
   Existing bespoke upload controls are intentionally preserved. */
.lvup-label-host,
.lvup-zone { min-width:0; max-width:100%; box-sizing:border-box; }
input[type="file"].lvup-native {
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  min-width:1px!important;
  min-height:1px!important;
  padding:0!important;
  margin:0!important;
  border:0!important;
  overflow:hidden!important;
  clip:rect(0,0,0,0)!important;
  clip-path:inset(50%)!important;
  white-space:nowrap!important;
  opacity:0!important;
}
.lvup-zone {
  --lvup-line:var(--outline,var(--edge,#cbded5));
  --lvup-ink:var(--title,var(--text,#184a40));
  --lvup-muted:var(--muted,#708b81);
  --lvup-main:var(--accent,var(--primary,#08745e));
  display:flex!important;
  flex-direction:column;
  gap:9px;
  align-items:stretch;
  position:relative;
  width:100%;
  min-height:112px;
  padding:15px!important;
  margin:7px 0 2px!important;
  border:1.5px dashed var(--lvup-line)!important;
  border-radius:14px!important;
  background:var(--glass,var(--surface,#f5faf7))!important;
  color:var(--lvup-ink)!important;
  text-decoration:none!important;
  cursor:pointer;
  font-family:'Bai Jamjuree',sans-serif!important;
  text-align:left;
  transition:border-color .16s ease, background .16s ease, box-shadow .16s ease;
}
.lvup-zone:hover,.lvup-zone.lvup-dragover {
  border-color:var(--lvup-main)!important;
  background:color-mix(in srgb,var(--lvup-main) 5%,var(--glass,var(--surface,#f5faf7)))!important;
}
.lvup-zone:focus-visible,
input[type="file"].lvup-native:focus-visible + .lvup-zone,
.lvup-label-host:focus-within .lvup-zone {
  outline:2px solid var(--lvup-main)!important;
  outline-offset:2px;
}
.lvup-main { display:flex; flex-wrap:wrap; align-items:center; gap:12px; min-width:0; }
.lvup-mark {
  width:42px;height:42px;flex:0 0 42px;display:grid;place-items:center;
  border:1px solid var(--lvup-line);border-radius:12px;
  background:var(--surface,#fff);color:var(--lvup-main);
}
.lvup-mark svg { display:block; width:20px; height:20px; }
.lvup-copy { display:flex; flex:1 1 170px; flex-direction:column; gap:4px; min-width:0; }
.lvup-title {font-size:13px!important;font-weight:750!important;line-height:1.4;color:var(--lvup-ink)!important;}
.lvup-sub {font-size:11px!important;line-height:1.5;color:var(--lvup-muted)!important;font-weight:500!important;}
.lvup-choose {
  display:inline-flex;align-items:center;justify-content:center;
  min-height:38px; padding:8px 13px;
  border-radius:10px; border:1px solid var(--lvup-line);
  background:var(--surface,#fff); color:var(--lvup-main);
  font-size:12px;font-weight:800;white-space:nowrap;
}
.lvup-meta {font-size:11px!important;line-height:1.5;color:var(--lvup-muted)!important;font-weight:500!important;}
.lvup-selected {
  display:flex;align-items:center;gap:11px;min-width:0;
  padding:10px 0 0;border-top:1px solid var(--lvup-line);
}
.lvup-preview {width:46px;height:46px;flex:0 0 46px;border-radius:9px;overflow:hidden;background:var(--surface,#fff);display:grid;place-items:center;border:1px solid var(--lvup-line);}
.lvup-preview img {display:block;width:100%;height:100%;object-fit:cover;}
.lvup-preview:not(.lvup-image)::before {content:'✓';font-size:17px;font-weight:800;color:var(--lvup-main);}
.lvup-selected-info {display:flex;flex:1 1 auto;flex-direction:column;gap:3px;min-width:0;}
.lvup-filename {font-size:12px;font-weight:750;color:var(--lvup-ink);overflow-wrap:anywhere;line-height:1.4;}
.lvup-filesize {font-size:11px;color:var(--lvup-muted);line-height:1.4;}
.lvup-remove {display:inline-grid;place-items:center;flex:0 0 30px;min-width:30px;min-height:30px;border:1px solid var(--lvup-line);border-radius:9px;color:var(--lvup-muted);background:var(--surface,#fff);font-size:19px;line-height:1;cursor:pointer;user-select:none;}
.lvup-remove:hover,.lvup-remove:focus-visible {color:#b54844;border-color:#c97970;outline-offset:2px;}
.lvup-error {font-size:11px!important;line-height:1.5;color:#ac4239!important;font-weight:650!important;}
.lvup-zone.lvup-invalid {border-color:#bf6258!important;}
.lvup-zone.lvup-has-file .lvup-title {color:var(--lvup-main)!important;}
.lvup-zone [hidden] {display:none!important;}
@media (max-width:600px) {
 .lvup-zone {padding:12px!important;min-height:100px;}
 .lvup-main {gap:9px;}
 .lvup-mark {width:38px;height:38px;flex-basis:38px;}
 .lvup-choose {flex:0 0 auto;}
}
@media (prefers-reduced-motion:reduce) {.lvup-zone {transition:none;}}
/* Avoid inheriting full-width/file form constraints on the custom surface. */
body .lvup-zone *,body .lvup-zone *::before {box-sizing:border-box;}
