* { box-sizing: border-box; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #0b141a;
  color: #e9edef;
  margin: 0;
  padding: 0;
}
#app { max-width: 720px; margin: 0 auto; padding: 24px; }
header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; }
h1 { font-size: 20px; margin: 0; }
.badge { padding: 4px 12px; border-radius: 12px; font-size: 12px; font-weight: 600; }
.badge.disconnected { background: #3b1f1f; color: #ff8080; }
.badge.qr { background: #3b361f; color: #ffe680; }
.badge.ready { background: #1f3b28; color: #25d366; }

.screen.hidden { display: none; }

#screen-connect { text-align: center; padding: 60px 0; }
#qr-box { margin-top: 24px; min-height: 260px; display: flex; align-items: center; justify-content: center; }
#qr-box img { width: 260px; height: 260px; background: #fff; padding: 12px; border-radius: 8px; }

.card {
  background: #202c33;
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 16px;
}
.card h2 { margin-top: 0; font-size: 16px; }
label { display: block; font-size: 13px; margin: 12px 0 4px; color: #8696a0; }
input[type="text"], input[type="file"], textarea {
  width: 100%;
  padding: 10px;
  background: #2a3942;
  border: 1px solid #3b4a54;
  border-radius: 6px;
  color: #e9edef;
  font-size: 14px;
}
button {
  background: #00a884;
  color: #fff;
  border: none;
  padding: 10px 18px;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
  margin: 12px 8px 0 0;
}
button:hover { background: #06cf9c; }
button.danger { background: #a83232; }
button.danger:hover { background: #cf3d3d; }
button:disabled { opacity: 0.4; cursor: not-allowed; }

.progress-bar { background: #2a3942; border-radius: 6px; height: 10px; overflow: hidden; margin-top: 8px; }
.progress-fill { background: #00a884; height: 100%; width: 0%; transition: width 0.3s; }
#gen-progress-text { margin-top: 8px; font-size: 13px; color: #8696a0; }

.stats { display: flex; gap: 24px; margin-top: 16px; }
.stats div { text-align: center; }
.stats span { display: block; font-size: 24px; font-weight: 700; }
.stats label { font-size: 12px; }

table { width: 100%; border-collapse: collapse; margin-top: 12px; font-size: 13px; }
th, td { text-align: left; padding: 6px 8px; border-bottom: 1px solid #2a3942; }
td.result-sent { color: #25d366; }
td.result-failed { color: #ff8080; }
