/* ── ILEAcon Design Tokens ───────────────────────────────────────── */
:root {
  --il-purple:       #9e00ff;
  --il-purple-dark:  #7a00cc;
  --il-purple-light: #f3e6ff;
  --il-purple-dim:   rgba(158, 0, 255, 0.08);
  --il-black:        #000000;
  --il-header-bg:    #dddddd;
  --il-footer-bg:    #020202;
  --il-bg:           #f8f8f8;
  --il-white:        #ffffff;
  --il-border:       #e0e0e0;
  --il-text:         #1a1a1a;
  --il-muted:        #666666;
  --il-success:      #2e7d32;
  --il-danger:       #c62828;
  --il-shadow:       0 1px 3px rgba(0,0,0,0.10);
  --il-shadow-card:  0 2px 8px rgba(0,0,0,0.09);
}

/* ── Base ────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 13.5px;
  background: var(--il-bg);
  color: var(--il-text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Header ──────────────────────────────────────────────────────── */
#il-header {
  background: var(--il-header-bg);
  border-top: 6px solid var(--il-black);
  border-bottom: 1px solid #c8c8c8;
  box-shadow: var(--il-shadow);
}
#il-header-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: .7rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.2rem;
}
#il-logo img {
  height: 42px;
  width: auto;
  display: block;
}
#il-header-divider {
  width: 1px;
  height: 38px;
  background: #b0b0b0;
  flex-shrink: 0;
}
#il-header-product {
  display: flex;
  flex-direction: column;
  gap: .1rem;
}
#il-product-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--il-text);
  letter-spacing: .01em;
}
#il-product-name span { color: var(--il-purple); }
#il-powered {
  font-size: .72rem;
  color: var(--il-muted);
  font-variant: small-caps;
  letter-spacing: .06em;
}
#il-powered strong { color: var(--il-purple); font-weight: 700; }

/* ── Page title strip ────────────────────────────────────────────── */
#il-titlestrip {
  background: #000;
  padding: .45rem 0;
}
#il-titlestrip-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  gap: .5rem;
  color: #fff;
  font-size: .78rem;
}
#il-titlestrip-inner .sep { opacity: .6; margin: 0 .3rem; }
#il-titlestrip-inner .current { font-weight: 700; }

/* ── Main ────────────────────────────────────────────────────────── */
#il-main {
  max-width: 1000px;
  margin: 1.5rem auto;
  padding: 0 1.5rem 3rem;
  flex: 1;
}

/* ── Cards ───────────────────────────────────────────────────────── */
.il-card {
  background: var(--il-white);
  border: 1px solid var(--il-border);
  border-radius: 0;
  margin-bottom: 1.2rem;
  box-shadow: var(--il-shadow-card);
}
.il-card-header {
  background: var(--il-black);
  color: #fff;
  padding: .55rem 1.1rem;
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: .84rem;
  font-weight: 700;
  font-variant: small-caps;
  letter-spacing: .04em;
}
.il-card-header.success {
  background: var(--il-success);
}
.il-card-body {
  padding: 1.1rem;
}

/* Step badge */
.il-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
  color: #fff;
  font-size: .72rem;
  font-weight: 700;
  font-variant: normal;
  flex-shrink: 0;
  border: 1.5px solid rgba(255,255,255,.5);
}

/* Header badge (right side) */
.il-hbadge {
  margin-left: auto;
  padding: .15rem .55rem;
  border-radius: 20px;
  font-size: .7rem;
  font-weight: 700;
  font-variant: normal;
  letter-spacing: .02em;
}
.il-hbadge.count   { background: rgba(255,255,255,.2); color: #fff; }
.il-hbadge.running { background: #fff; color: var(--il-purple); }
.il-hbadge.done    { background: #fff; color: var(--il-success); }
.il-hbadge.error   { background: #fff; color: var(--il-danger); }

/* ── Drop Zone ───────────────────────────────────────────────────── */
#drop-zone {
  border: 2px dashed #c0c0c0;
  padding: 1.8rem 1rem;
  text-align: center;
  cursor: pointer;
  background: #fdfdfd;
  transition: border-color .15s, background .15s;
}
#drop-zone:hover    { border-color: var(--il-purple); background: var(--il-purple-dim); }
#drop-zone.dragover { border-color: var(--il-purple); background: var(--il-purple-dim); }
#drop-zone.has-file { border-color: var(--il-success); background: #f0faf2; }
#drop-zone svg { display: block; margin: 0 auto .5rem; }
.dz-hint   { color: var(--il-muted); font-size: .82rem; }
.dz-click  { color: var(--il-purple); font-weight: 700; }
.dz-limits { color: #aaaaaa; font-size: .74rem; margin-top: .25rem; }
#drop-file-name { color: var(--il-success); font-weight: 700; font-size: .9rem; }
#upload-status  { margin-top: .5rem; font-size: .78rem; color: var(--il-muted); }
#upload-status.err { color: var(--il-danger); }

/* ── Table ───────────────────────────────────────────────────────── */
#vs-table-wrap {
  max-height: 360px;
  overflow-y: auto;
  border: 1px solid var(--il-border);
}
#vs-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .82rem;
}
#vs-table thead tr {
  background: var(--il-purple);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 1;
}
#vs-table thead th {
  padding: .45rem .8rem;
  font-weight: 700;
  font-size: .76rem;
  letter-spacing: .05em;
  font-variant: small-caps;
  border: none;
  white-space: nowrap;
}
#vs-table tbody tr {
  border-bottom: 1px solid #efefef;
  transition: background .1s;
}
#vs-table tbody tr:last-child { border-bottom: none; }
#vs-table tbody tr:hover      { background: var(--il-purple-dim); }
#vs-table td { padding: .42rem .8rem; vertical-align: middle; }

/* Type badges */
.type-badge {
  display: inline-block;
  padding: .1rem .4rem;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  border-radius: 2px;
}
.type-lb   { background: #e8e0ff; color: #5500bb; }
.type-cs   { background: #e0f0ff; color: #005599; }
.type-vpn  { background: #ffe8f8; color: #990066; }
.type-auth { background: #fff0e0; color: #994400; }
.type-gslb { background: #e0ffe8; color: #006622; }
.type-cr   { background: #fff5e0; color: #886600; }
.type-other{ background: #eeeeee; color: #555555; }

/* State */
.state-enabled  { color: var(--il-success); font-weight: 700; }
.state-disabled { color: var(--il-danger);  font-weight: 700; }

/* Checkboxes */
#vs-table input[type=checkbox] { accent-color: var(--il-purple); width: 14px; height: 14px; cursor: pointer; }

/* ── Toolbar ─────────────────────────────────────────────────────── */
.il-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .6rem;
  margin-top: .85rem;
}
.il-toolbar-sep { width: 1px; height: 1.4rem; background: var(--il-border); }

/* ── Buttons ─────────────────────────────────────────────────────── */
.il-btn {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  border: none;
  border-radius: 0;
  cursor: pointer;
  font-family: Arial, sans-serif;
  font-size: .82rem;
  font-weight: 700;
  padding: .4rem .9rem;
  transition: background .15s, color .15s;
  text-decoration: none;
  line-height: 1.4;
  letter-spacing: .01em;
}
.il-btn:disabled { opacity: .4; cursor: not-allowed; }
.il-btn-primary {
  background: var(--il-purple);
  color: #fff;
}
.il-btn-primary:hover:not(:disabled) { background: var(--il-purple-dark); color: #fff; }
.il-btn-outline {
  background: transparent;
  color: var(--il-purple);
  border: 1px solid var(--il-purple);
}
.il-btn-outline:hover:not(:disabled) { background: var(--il-purple-light); }
.il-btn-success  { background: var(--il-success); color: #fff; }
.il-btn-success:hover { background: #1b5e20; color: #fff; }
.il-btn-lg { padding: .5rem 1.4rem; font-size: .9rem; }

/* ── Form controls ───────────────────────────────────────────────── */
.il-check { accent-color: var(--il-purple); }
.il-label { font-size: .82rem; }
.il-input {
  border: 1px solid #c8c8c8;
  border-radius: 0;
  padding: .32rem .55rem;
  font-size: .82rem;
  width: 5rem;
  font-family: Arial, sans-serif;
}
.il-input:focus { outline: 2px solid var(--il-purple); outline-offset: 0; }

/* ── Log box ─────────────────────────────────────────────────────── */
#log-box {
  font-family: "Consolas", "Courier New", monospace;
  font-size: .78rem;
  line-height: 1.6;
  max-height: 280px;
  overflow-y: auto;
  background: #110822;
  color: #ccc0dd;
  padding: .75rem 1rem;
  white-space: pre-wrap;
  word-break: break-all;
  border: 1px solid #2a1048;
}
#log-box .log-found { color: #c084fc; }
#log-box .log-label { color: #8866aa; }
#log-box .log-error { color: #f87171; }
#log-box .log-ok    { color: #4ade80; }

/* ── Download card body ──────────────────────────────────────────── */
#download-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.dl-check-circle {
  width: 2.8rem;
  height: 2.8rem;
  background: var(--il-success);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ── Footer ──────────────────────────────────────────────────────── */
#il-footer {
  background: var(--il-footer-bg);
  color: #888;
  text-align: center;
  font-size: .73rem;
  padding: .75rem 1rem;
  margin-top: auto;
}
#il-footer a { color: var(--il-purple); text-decoration: none; }
#il-footer a:hover { text-decoration: underline; }

/* ── Scrollbar ───────────────────────────────────────────────────── */
#vs-table-wrap::-webkit-scrollbar { width: 6px; }
#vs-table-wrap::-webkit-scrollbar-track { background: #f8f8f8; }
#vs-table-wrap::-webkit-scrollbar-thumb { background: #c8c8c8; }
#log-box::-webkit-scrollbar { width: 6px; }
#log-box::-webkit-scrollbar-track { background: #110822; }
#log-box::-webkit-scrollbar-thumb { background: #3d1a66; }
