/* =========================================================
   NetSpace – IMAP Mail Transfer
   Friendly dark UI (layered greys, disciplined layout)
   ========================================================= */

/* ===== Base ===== */
body.dark {
  background: linear-gradient(180deg, #2a2f36 0%, #1c2026 100%);
  color: #eef1f4;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  margin: 0;
}

/* ===== Topbar ===== */
.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 24px;
  background: #2f343c;
  border-bottom: 1px solid #3f4650;
}

.topbar strong {
  font-weight: 600;
}

.topbar .subtitle {
  color: #aab0b6;
  font-size: 12px;
  margin-left: 6px;
}

.topbar nav a {
  margin-left: 16px;
  color: #7aa2d8;
  text-decoration: none;
  font-size: 14px;
}

.topbar nav a:hover {
  text-decoration: underline;
}

/* ===== Workspace ===== */
.workspace {
  max-width: 1100px;
  margin: 32px auto;
  padding: 0 20px;
}

/* ===== Cards layout ===== */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 24px;
  margin-bottom: 10px; /* προαιρετικό separation (ενσωματωμένο) */
}

/* ===== Card ===== */
.card {
  background: linear-gradient(180deg, #343a42 0%, #2b3037 100%);
  border: 1px solid #4a515b;
  border-radius: 10px;
  padding: 22px;
  box-shadow: 0 6px 16px rgba(0,0,0,0.25);
}

.card h3 {
  margin: 0 0 14px 0;
  font-size: 15px;
  font-weight: 600;
  color: #f1f3f5;
}

/* ===== Inputs ===== */
input {
  width: 100%;
  background: linear-gradient(180deg, #1f242a, #1b1f24);
  border: 1px solid #4a515b;
  color: #f5f7fa;
  padding: 11px 12px;
  margin-bottom: 12px;
  border-radius: 6px;
  font-size: 14px;

  /* discipline */
  box-sizing: border-box;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.5);
}

.card input:last-child {
  margin-bottom: 0;
}

input::placeholder {
  color: #aab0b6;
}

input:focus {
  outline: none;
  border-color: #7aa2d8;
  box-shadow:
    inset 0 1px 2px rgba(0,0,0,0.6),
    0 0 0 1px rgba(122,162,216,0.35);
}

/* ===== Controls ===== */
.controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 26px 0;
  flex-wrap: wrap;
  gap: 16px;
}

.toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #d3d7dc;
}

/* ===== Start Button ===== */
.start-btn {
  background: linear-gradient(90deg, #2ea043, #238636);
  border: none;
  color: #ffffff;
  padding: 12px 30px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(0,0,0,0.35);
}

.start-btn:hover {
  filter: brightness(1.08);
}

/* ===== Progress ===== */
.progress-section {
  margin: 18px 0 22px;
}

#progress-text {
  font-size: 13px;
  color: #c1c6cc;
  margin-bottom: 6px;
}

#progress-box {
  background: #1f242a;
  border: 1px solid #4a515b;
  height: 22px;
  border-radius: 6px;
  overflow: hidden;
}

#progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #2ea043, #58c472);
  transition: width 0.3s ease;
}

/* ===== Output Console ===== */
pre {
  background: #20252b;
  border: 1px solid #4a515b;
  border-radius: 10px;
  padding: 16px;
  height: 320px;
  overflow: auto;
  font-size: 12px;
  color: #e0e3e7;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.03);
}
table th, table td {
  padding: 8px 6px;
  font-size: 14px;
}

table th {
  font-weight: 600;
}

select {
  box-sizing: border-box;
}
.abort-btn {
  background:#b93737;
  border:none;
  padding:10px 20px;
  color:#fff;
  border-radius:6px;
  cursor:pointer;
}
.abort-btn:hover {
  background:#a52d2d;
}
/* ---------- Dry run checkbox ---------- */

.toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #cfd3d8;
  font-size: 14px;
  cursor: pointer;
  user-select: none;
}

.toggle input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 4px;
  border: 1px solid #4a515b;
  background: #1f242a;
  position: relative;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.toggle input[type="checkbox"]:checked {
  background: #2f7d32;
  border-color: #2f7d32;
}

.toggle input[type="checkbox"]:checked::after {
  content: "✓";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -55%);
  font-size: 14px;
  line-height: 1;
  color: #fff;
}


.toggle span {
  opacity: 0.85;
}
/* ---------- Topbar ---------- */

.topbar {
  background: linear-gradient(180deg, #2e343b, #2a3036);
  border-bottom: 1px solid #3a4149;
}

.topbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 24px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}

.topbar-title {
  text-align: center;
  color: #f5f7fa;
  font-size: 16px;
}

.topbar-title strong {
  font-weight: 600;
  letter-spacing: 0.4px;
}

.topbar-title .subtitle {
  margin-left: 8px;
  color: #a9b0b7;
  font-size: 13px;
}

.topbar-nav {
  justify-self: end;
  display: flex;
  gap: 18px;
}

.topbar-nav a {
  color: #cfd3d8;
  font-size: 14px;
  text-decoration: none;
}

.topbar-nav a:hover {
  color: #ffffff;
}
/* ---------- Hero title ---------- */

.hero {
  max-width: 1200px;
  margin: 28px auto 34px;
  padding: 0 24px;
  text-align: center;
}

.hero h1 {
  margin: 0;
  font-size: 28px;
  font-weight: 600;
  letter-spacing: 0.6px;
  color: #f5f7fa;
}

.hero p {
  margin-top: 8px;
  font-size: 14px;
  color: #a9b0b7;
}

/* ---------- Execution Mode ---------- */
.exec-mode {
  margin-top: 14px;
  padding: 12px 16px;
  border: 1px solid #3a4149;
  border-radius: 12px;
  background: linear-gradient(180deg, #2b3138, #262c33);
  max-width: 520px;
}

.exec-mode.wide {
  max-width: 680px;
}

.exec-title {
  font-size: 11px;
  letter-spacing: 0.7px;
  text-transform: uppercase;
  color: #a9b0b7;
  margin-bottom: 8px;
}

.exec-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 18px;
}

.exec-grid .toggle {
  align-items: center;
}


/* ---------- Controls Row (Execution + Actions) ---------- */

.controls-row {
  display: flex;
  align-items: center;   /* κρατά το ύψος σωστό */
  justify-content: space-between;
  gap: 24px;
  margin: 24px 0 18px;
  flex-wrap: wrap;           /* responsive */
}

.controls-left {
  flex: 1 1 auto;
}

.controls-right {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 18px;          /* οπτική ευθυγράμμιση με exec-title */
}

/* Abort button polish */
.abort-btn {
  background: linear-gradient(180deg, #6b2a2a, #5a1e1e);
  border: 1px solid #7a3a3a;
  color: #fff;
  padding: 12px 26px;
  border-radius: 8px;
  font-size: 14px;
  cursor: not-allowed;
  opacity: 0.65;
}

.abort-btn:not([disabled]) {
  cursor: pointer;
  opacity: 1;
}

.abort-btn:not([disabled]):hover {
  filter: brightness(1.08);
}
/* ---------- Disabled toggle visual hint ---------- */
.toggle input:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
/* =========================================================
   NetSpace – IMAP Mail Transfer
   Input polish (icons, labels, show-password)
   ADD THIS AT THE END OF style.css
   ========================================================= */

/* ---------- Field blocks ---------- */
.field {
  margin-bottom: 14px;
}

.field label {
  display: block;
  font-size: 13px;
  color: #cfd3d8;
  margin-bottom: 6px;
  opacity: 0.9;
}

/* ---------- Input with icon ---------- */
.input-wrap {
  position: relative;
}

.input-wrap input {
  padding-left: 40px;
}

/* ---------- Icons (pure CSS) ---------- */
.input-wrap::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 12px;
  width: 16px;
  height: 16px;
  opacity: 0.6;
  transform: translateY(-50%);
  background-size: contain;
  background-repeat: no-repeat;
}

/* User icon */
.input-user::before {
  background-image: url("data:image/svg+xml;utf8,\
<svg xmlns='http://www.w3.org/2000/svg' fill='%23cfd3d8' viewBox='0 0 24 24'>\
<path d='M12 12c2.7 0 4.9-2.2 4.9-4.9S14.7 2.2 12 2.2 7.1 4.4 7.1 7.1 9.3 12 12 12zm0 2.4c-3.3 0-9.8 1.7-9.8 5.1v2.3h19.6v-2.3c0-3.4-6.5-5.1-9.8-5.1z'/>\
</svg>");
}

/* Lock icon */
.input-pass::before {
  background-image: url("data:image/svg+xml;utf8,\
<svg xmlns='http://www.w3.org/2000/svg' fill='%23cfd3d8' viewBox='0 0 24 24'>\
<path d='M17 9h-1V7a4 4 0 10-8 0v2H7a2 2 0 00-2 2v9a2 2 0 002 2h10a2 2 0 002-2v-9a2 2 0 00-2-2zm-6 8.7V15a1 1 0 112 0v2.7a1 1 0 11-2 0zM10 9V7a2 2 0 114 0v2h-4z'/>\
</svg>");
}

/* Server icon */
.input-host::before {
  background-image: url("data:image/svg+xml;utf8,\
<svg xmlns='http://www.w3.org/2000/svg' fill='%23cfd3d8' viewBox='0 0 24 24'>\
<path d='M4 3h16a2 2 0 012 2v4a2 2 0 01-2 2H4a2 2 0 01-2-2V5a2 2 0 012-2zm0 10h16a2 2 0 012 2v4a2 2 0 01-2 2H4a2 2 0 01-2-2v-4a2 2 0 012-2z'/>\
</svg>");
}

/* ---------- Show password ---------- */
.show-pass {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #a9b0b7;
  margin-top: 6px;
  cursor: pointer;
  user-select: none;
}

.show-pass input {
  margin: 0;
  cursor: pointer;
}

/* ---------- Disabled execution options ---------- */
.toggle input:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ---------- Minor spacing harmony ---------- */
.card h3 {
  margin-bottom: 16px;
}
/* Show password inline tweak */
.toggle-inline {
  margin-top: 6px;
  font-size: 13px;
  opacity: 0.85;
}
.toggle-inline {
  align-items: center;
}
/* Show password uses same toggle style */
.show-pass {
  font-size: 12px;
  opacity: 0.85;
  margin-top: 6px;
}
/* Perfect vertical alignment for show password */
.toggle.show-pass span {
  position: relative;
  top: -1px;
}
