/* ==========================================================================
   Live exposure check — the homepage console.

   The console sits on the hero's dark field, so everything here is authored
   for that surface: a translucent frame, white copy, azure accents. Tokens
   come from the theme (theme.css); the frame falls back to literal values so
   the shortcode still looks right if it is dropped into another theme.
   ========================================================================== */

.sh-ec {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-2xl, 1rem);
  background: linear-gradient(180deg, rgb(255 255 255 / 0.05), rgb(255 255 255 / 0.02));
  border: 1px solid rgb(255 255 255 / 0.12);
  box-shadow:
    0 0 0 1px rgb(0 156 255 / 0.08),
    0 24px 60px -24px rgb(0 156 255 / 0.28),
    inset 0 1px 0 rgb(255 255 255 / 0.08);
  backdrop-filter: blur(8px);
}

.sh-ec__head {
  border-bottom: 1px solid rgb(255 255 255 / 0.1);
  padding: 0.875rem 1.25rem;
}

.sh-ec__label {
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: rgb(255 255 255 / 0.6);
}

.sh-ec__body { padding: 1.25rem; }

@media (min-width: 640px) {
  .sh-ec__head { padding: 0.875rem 1.5rem; }
  .sh-ec__body { padding: 1.5rem; }
}

/* ── The address row ─────────────────────────────────────────────────────── */

.sh-ec__form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .sh-ec__form { flex-direction: row; }
}

.sh-ec__input {
  min-width: 0;
  flex: 1;
  border-radius: var(--r-xl, 0.75rem);
  border: 1px solid rgb(255 255 255 / 0.15);
  background: rgb(4 7 15 / 0.55);
  padding: 0.875rem 1rem;
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 1rem;
  color: #fff;
  outline: none;
  transition: border-color 150ms, background-color 150ms;
}

.sh-ec__input::placeholder { color: rgb(255 255 255 / 0.45); }

.sh-ec__input:focus {
  border-color: rgb(0 156 255 / 0.7);
  background: rgb(4 7 15 / 0.75);
}

.sh-ec__input:read-only { color: rgb(255 255 255 / 0.7); }

.sh-ec__input--code { letter-spacing: 0.3em; }

/* Honeypot: present for bots, unreachable for everyone else. */
.sh-ec__hp {
  position: absolute;
  left: -9999px;
  width: 0;
  height: 0;
  opacity: 0;
}

.sh-ec__submit:disabled { opacity: 0.6; cursor: default; }

.sh-ec__note {
  margin-top: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: rgb(255 255 255 / 0.6);
}

.sh-ec__note svg { flex: none; }

.sh-ec__challenge { margin-top: 0.75rem; }

.sh-ec__challenge-error {
  margin-top: 0.5rem;
  font-size: 0.75rem;
  color: var(--risk-high, #dc2626);
}

/* ── Panels shared by the code step and the result states ───────────────── */

.sh-ec__panel {
  margin-top: 1.25rem;
  border-radius: var(--r-xl, 0.75rem);
  padding: 1.25rem;
  background-image: linear-gradient(180deg, rgb(255 255 255 / 0.06), rgb(255 255 255 / 0.015));
  border: 1px solid rgb(255 255 255 / 0.1);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.05), 0 18px 40px -26px rgb(0 0 0 / 0.8);
}

.sh-ec__otp-intro {
  font-size: 0.875rem;
  line-height: 1.6;
  color: rgb(255 255 255 / 0.8);
}

.sh-ec__otp-email {
  font-family: var(--font-mono, ui-monospace, monospace);
  color: #fff;
}

.sh-ec__otp-row {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .sh-ec__otp-row { flex-direction: row; }
}

.sh-ec__otp-actions {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  font-size: 0.875rem;
}

.sh-ec__link {
  color: var(--brand, #009cff);
  text-underline-offset: 2px;
  cursor: pointer;
  background: none;
  border: 0;
  padding: 0;
  font-size: inherit;
}

.sh-ec__link:hover:not(:disabled) { text-decoration: underline; }

.sh-ec__link:disabled {
  cursor: default;
  color: rgb(255 255 255 / 0.55);
  text-decoration: none;
}

.sh-ec__link--muted { color: rgb(255 255 255 / 0.7); }
.sh-ec__link--muted:hover:not(:disabled) { color: #fff; }
.sh-ec__link--muted:disabled { opacity: 0.5; }

/* ── Messages ────────────────────────────────────────────────────────────── */

.sh-ec__msg {
  margin-top: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: rgb(255 255 255 / 0.85);
}

.sh-ec__copy {
  margin-top: 0.375rem;
  font-size: 0.875rem;
  line-height: 1.6;
  color: rgb(255 255 255 / 0.75);
}

.sh-ec__fineprint {
  margin-top: 0.75rem;
  font-size: 0.75rem;
  color: rgb(255 255 255 / 0.6);
}

.sh-ec__busy {
  margin-top: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 0.75rem;
  color: rgb(255 255 255 / 0.75);
}

.sh-ec__ico-risk { flex: none; color: var(--risk-high, #dc2626); }
.sh-ec__ico-brand { flex: none; color: var(--brand, #009cff); }

.sh-ec-spin {
  flex: none;
  color: var(--brand, #009cff);
  animation: sh-ec-spin 1s linear infinite;
}

@keyframes sh-ec-spin {
  to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .sh-ec-spin { animation-duration: 3s; }
}

/* ── Results ─────────────────────────────────────────────────────────────── */

.sh-ec__result { margin-top: 1.25rem; }

.sh-ec__result-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: #fff;
}

.sh-ec__actions {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.sh-ec__actions .btn:disabled { opacity: 0.6; cursor: default; }

.sh-ec__table-wrap {
  margin-top: 0.75rem;
  overflow: hidden;
  border-radius: var(--r-xl, 0.75rem);
  border: 1px solid rgb(255 255 255 / 0.1);
  background: rgb(4 7 15 / 0.5);
}

.sh-ec__table-scroll { overflow-x: auto; }

.sh-ec__table {
  width: 100%;
  text-align: left;
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 0.75rem;
  white-space: nowrap;
}

.sh-ec__table th {
  padding: 0.625rem 1rem;
  font-size: 0.625rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgb(255 255 255 / 0.55);
  border-bottom: 1px solid rgb(255 255 255 / 0.1);
}

.sh-ec__table td {
  padding: 0.625rem 1rem;
  border-top: 1px solid rgb(255 255 255 / 0.06);
}

.sh-ec__table tbody tr:first-child td { border-top: 0; }

.sh-ec__masked { user-select: none; color: rgb(255 255 255 / 0.35); }
.sh-ec__user { color: rgb(255 255 255 / 0.85); }
.sh-ec__cell { color: rgb(255 255 255 / 0.75); white-space: normal; word-break: break-all; }

.sh-ec__pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.5rem 1rem;
  border-top: 1px solid rgb(255 255 255 / 0.1);
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 0.6875rem;
  color: rgb(255 255 255 / 0.6);
}

.sh-ec__pager-btns { display: flex; gap: 0.25rem; }

.sh-ec__pager-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: var(--r-lg, 0.5rem);
  border: 1px solid rgb(255 255 255 / 0.1);
  color: rgb(255 255 255 / 0.7);
  cursor: pointer;
  transition: background-color 150ms, color 150ms;
}

.sh-ec__pager-btn:hover:not(:disabled) {
  background: rgb(255 255 255 / 0.06);
  color: #fff;
}

.sh-ec__pager-btn:disabled { pointer-events: none; opacity: 0.3; }

.sh-ec__raw {
  margin-top: 0.75rem;
  padding: 0.75rem;
  overflow-x: auto;
  border-radius: var(--r-xl, 0.75rem);
  border: 1px solid rgb(255 255 255 / 0.1);
  background: rgb(4 7 15 / 0.5);
}

.sh-ec__raw ul {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.sh-ec__raw li {
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 0.75rem;
  color: rgb(255 255 255 / 0.75);
  word-break: break-all;
}
