:root{
  font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  color:#102235;background:#eaf2f8;
  --brand:#075985;--accent:#f59e0b;--panel:#fff;--line:#d8e5ee;
}
*{box-sizing:border-box}
body{margin:0;background:linear-gradient(180deg,#eaf6fc,#f7fbfe);color:#102235}
button,.button,input,select,textarea{font:inherit}
button,.button{border:0;border-radius:10px;background:#075985;color:#fff;padding:10px 14px;font-weight:800;cursor:pointer}
button:hover,.button:hover{filter:brightness(1.05)}
button:disabled{opacity:.55;cursor:not-allowed}
button.secondary,.button.secondary{background:#e4eef5;color:#12354c}
button.danger{background:#b91c1c}
button.light,.button.light{background:#fff;color:#075985}
.top{display:flex;justify-content:space-between;align-items:center;gap:20px;padding:18px 24px;background:linear-gradient(135deg,#064b72,#0c749e);color:#fff}
.top h1{margin:2px 0 4px}.top p{margin:0}.eyebrow{font-weight:900;letter-spacing:.12em;font-size:12px;color:#fde68a}
.top-actions{display:flex;flex-wrap:wrap;gap:8px}
.app{display:grid;grid-template-columns:minmax(270px,340px) minmax(330px,1fr) minmax(300px,390px);gap:14px;padding:14px;align-items:start}
.panel{background:var(--panel);border:1px solid var(--line);border-radius:18px;padding:15px;box-shadow:0 7px 22px #0f3a5512}
.panel-title{display:flex;align-items:center;gap:8px;font-size:17px;font-weight:900;color:#075985;margin-bottom:12px}
.panel-title span{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#075985;color:#fff;font-size:13px}
.spaced{margin-top:20px}
label{display:block;font-weight:750;font-size:13px;margin:10px 0;color:#28475a}
input,select,textarea{width:100%;margin-top:5px;padding:9px 10px;border:1px solid #bfd3df;border-radius:9px;background:#fff;color:#102235}
textarea{resize:vertical}
input[type=color]{padding:3px;height:40px}
input[type=checkbox]{width:auto;margin:0}
input[type=range]{padding:0}
.two{display:grid;grid-template-columns:1fr 1fr;gap:8px}
details{margin:12px 0;border-top:1px solid #e4edf3;padding-top:10px}
summary{cursor:pointer;font-weight:900;color:#075985}
.help{font-size:12px;line-height:1.45;color:#657d8d}
.check-line{display:flex!important;align-items:center;gap:8px}
.slide-buttons{display:grid;grid-template-columns:1fr 1fr;gap:7px}
.slide-buttons button{padding:9px 6px}
.photo-reel-box{margin:16px 0;padding:13px;border:2px solid #c4b5fd;border-radius:15px;background:linear-gradient(145deg,#faf5ff,#eff6ff)}
.photo-reel-head{display:flex;justify-content:space-between;align-items:flex-start;gap:8px;margin-bottom:10px}
.photo-reel-head strong{color:#5b21b6;font-size:16px}.photo-reel-head small{display:block;color:#64748b;margin-top:3px}
.photo-count-badge{background:#5b21b6;color:#fff;border-radius:999px;padding:5px 8px;font-size:10px;font-weight:900;white-space:nowrap}
.photo-picker{border:1px dashed #7c3aed;padding:10px;border-radius:10px;background:#fff;color:#4c1d95}
.webcam-actions,.narration-actions,.transport,.export-grid{display:flex;gap:7px;flex-wrap:wrap}
.webcam-options{display:flex;gap:15px;flex-wrap:wrap}
.webcam-options label{display:flex;align-items:center;gap:6px}
.preview-panel{position:sticky;top:10px}
.phone-wrap{display:grid;place-items:center;background:#07131b;border-radius:18px;padding:10px;min-height:420px}
#preview{max-width:100%;max-height:72vh;width:auto;height:auto;background:#111827;border-radius:12px}
.transport{justify-content:center;margin-top:11px}
#progress{margin:12px 0}
.status-row{display:flex;justify-content:space-between;font-size:12px;font-weight:800;color:#4b6474}
.warning{margin-top:8px;padding:8px 10px;border-radius:8px;background:#fff7ed;color:#9a3412;font-weight:700;font-size:12px}
.status{min-height:34px;margin-top:10px;padding:8px 10px;border-radius:8px;background:#eef7fb;color:#075985;font-weight:700;font-size:12px}
.slide-list{display:flex;flex-direction:column;gap:7px;max-height:240px;overflow:auto;margin-bottom:12px}
.slide-chip{text-align:left;background:#eef4f8;color:#15394e;border:1px solid #d1e0e8}
.slide-chip.active{background:#075985;color:#fff}.slide-chip small{display:block;margin-top:3px;opacity:.85;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.empty{padding:20px;text-align:center;color:#718797;background:#f6fafc;border-radius:10px}
.edit-head{display:flex;justify-content:space-between;align-items:center;gap:8px;margin-bottom:8px}
button.icon{padding:7px 10px;min-width:36px}
.narration-box{border:1px solid #cfdde6;border-radius:12px;padding:10px;margin-top:12px}
.narration-box legend{font-weight:900;color:#075985}
.tts-box{margin-top:12px;padding-top:12px;border-top:1px dashed #cfdde6}
.export-grid{margin-top:8px}.export-grid button{flex:1}
.guide-dialog{max-width:760px;width:min(94vw,760px);border:0;border-radius:18px;padding:0;box-shadow:0 20px 70px #0005}
.guide-dialog::backdrop{background:#00131b99}
.guide-head{display:flex;justify-content:space-between;gap:10px;padding:18px;background:#075985;color:#fff}
.guide-head h2{margin:0}.guide-close{font-size:24px;background:#fff;color:#075985}
.guide-body{padding:20px}.simple-guide h3{color:#075985;margin-bottom:5px}
.guide-actions{padding:0 20px 20px;text-align:right}
@media(max-width:1100px){.app{grid-template-columns:1fr 1fr}.preview-panel{position:static}.editor{grid-column:1/-1}}
@media(max-width:720px){.top{align-items:flex-start;flex-direction:column}.app{grid-template-columns:1fr;padding:8px}.editor{grid-column:auto}.two{grid-template-columns:1fr}.photo-reel-head{flex-direction:column}.phone-wrap{min-height:300px}}


.file-control{
  display:flex;
  align-items:center;
  gap:9px;
  flex-wrap:wrap;
  margin:5px 0 9px;
}
.file-button{
  display:inline-flex;
  align-items:center;
  width:auto;
  margin:0;
  white-space:nowrap;
}
.file-status{
  flex:1;
  min-width:130px;
  padding:8px 10px;
  border:1px solid #cfdde6;
  border-radius:9px;
  background:#f7fafc;
  color:#64748b;
  font-size:12px;
  font-weight:800;
  overflow-wrap:anywhere;
}
.file-status.loaded{
  border-color:#86c7a7;
  background:#eefbf4;
  color:#166534;
}

.auto-tts-option{
  margin:14px 0 8px!important;
  padding:10px 12px;
  border:1px solid #a7c8dc;
  border-radius:10px;
  background:#f0f8fc;
  align-items:flex-start!important;
}
.auto-tts-option small{
  display:block;
  margin-top:3px;
  color:#587385;
  font-weight:650;
  line-height:1.35;
}
