/* ============================================================
   iHacker WHOIS Tool v2.4 — Stylesheet
   Self-contained. No parent site CSS dependencies.
   Dark default, light theme via [data-theme="light"].
   ============================================================ */

/* ---- TOKENS (Dark, default) ---- */
:root {
  --accent: #dd0000;
  --accent-dim: #8b0000;
  --accent-glow: rgba(221, 0, 0, 0.18);

  --bg-0: #080808;
  --bg-1: #0e0e0e;
  --bg-2: #141414;
  --bg-3: #1c1c1c;
  --bg-4: #242424;
  --bg-5: #2e2e2e;

  --bd-1: #262626;
  --bd-2: #363636;
  --bd-accent: rgba(221, 0, 0, 0.35);

  --tx-1: #f0f0f0;
  --tx-2: #a0a0a0;
  --tx-3: #606060;
  --tx-4: #333333;

  --ok:   #16a34a;
  --warn: #d97706;
  --info: #3b82f6;
  --bad:  #dd0000;

  --shadow-panel: 0 0 0 1px rgba(221,0,0,.04), 0 4px 20px rgba(0,0,0,.30);
  --header-bg: rgba(14,14,14,.78);

  --r-sm: 4px;
  --r-md: 8px;
  --r-pill: 20px;

  --f-display: 'Orbitron', 'Trebuchet MS', sans-serif;
  --f-mono: 'JetBrains Mono', 'Menlo', monospace;
  --f-body: 'Inter', system-ui, sans-serif;

  --matrix-opacity: 0.03;
}

/* ---- TOKENS (Light) ---- */
[data-theme="light"] {
  --accent: #cc0000;
  --accent-dim: #990000;
  --accent-glow: rgba(204, 0, 0, 0.10);

  --bg-0: #f5f5f5;
  --bg-1: #ffffff;
  --bg-2: #fafafa;
  --bg-3: #f0f0f0;
  --bg-4: #e8e8e8;
  --bg-5: #dcdcdc;

  --bd-1: #e0e0e0;
  --bd-2: #c8c8c8;
  --bd-accent: rgba(204, 0, 0, 0.30);

  --tx-1: #0a0a0a;
  --tx-2: #4a4a4a;
  --tx-3: #707070;
  --tx-4: #a0a0a0;

  --shadow-panel: 0 0 0 1px rgba(204,0,0,.05), 0 4px 16px rgba(0,0,0,.06);
  --header-bg: rgba(255,255,255,.82);

  --matrix-opacity: 0.012;
}

/* ============================================================
   RESET + GLOBAL
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--f-body);
  background: var(--bg-0);
  color: var(--tx-1);
  line-height: 1.55;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea { font: inherit; color: inherit; }
code { font-family: var(--f-mono); font-size: .92em; background: var(--bg-3); padding: 1px 5px; border-radius: 3px; }
::selection { background: var(--accent); color: #fff; }

/* ============================================================
   BACKGROUND EFFECTS — Matrix rain + scanlines
   ============================================================ */
#matrix-rain {
  position: fixed; inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: var(--matrix-opacity);
}
#scanlines {
  position: fixed; inset: 0;
  z-index: 1;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    transparent 0,
    transparent 2px,
    rgba(255,255,255,.012) 3px,
    transparent 4px
  );
}
[data-theme="light"] #scanlines { display: none; }

/* ============================================================
   HEADER
   ============================================================ */
.ihk-header {
  position: sticky; top: 0;
  z-index: 50;
  height: 52px;
  background: var(--header-bg);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--bd-1);
}
.ihk-header::after {
  content: '';
  position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: .45;
}
.ihk-header-inner {
  max-width: 1200px; margin: 0 auto; height: 100%;
  display: flex; align-items: center; gap: 24px;
  padding: 0 16px;
}
.ihk-logo {
  font-family: var(--f-display);
  font-weight: 900;
  letter-spacing: 2px;
  color: var(--tx-1);
  font-size: 16px;
}
.ihk-logo .logo-bracket { color: var(--accent); margin: 0 1px; }
.ihk-nav {
  display: flex; gap: 18px;
  font-family: var(--f-mono);
  font-size: 13px;
  margin-left: auto;
}
.ihk-nav a {
  color: var(--tx-2);
  padding: 4px 2px;
  border-bottom: 1px solid transparent;
  transition: color .15s, border-color .15s;
}
.ihk-nav a:hover { color: var(--tx-1); }
.ihk-nav a.active { color: var(--accent); border-bottom-color: var(--accent); }
.theme-btn {
  width: 34px; height: 34px;
  border-radius: var(--r-sm);
  border: 1px solid var(--bd-1);
  background: var(--bg-2);
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--tx-1);
  transition: border-color .15s, color .15s, background .15s;
  margin-left: 8px;
}
.theme-btn:hover { border-color: var(--accent); color: var(--accent); }
/* CSS-only icon swap */
.theme-btn .i-sun  { display: none; }
.theme-btn .i-moon { display: inline-flex; }
[data-theme="light"] .theme-btn .i-sun  { display: inline-flex; }
[data-theme="light"] .theme-btn .i-moon { display: none; }

@media (max-width: 580px) {
  .ihk-nav { display: none; }
  .ihk-header-inner { gap: 12px; }
  .theme-btn { margin-left: auto; }
}

/* ============================================================
   MAIN
   ============================================================ */
.ihk-main {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 16px 80px;
}

/* ============================================================
   HERO
   ============================================================ */
.hero { text-align: center; padding: 36px 0 24px; }
.hero-tag {
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--tx-3);
  letter-spacing: 2px;
  margin-bottom: 12px;
  text-transform: uppercase;
}
.hero-title {
  font-family: var(--f-display);
  font-weight: 900;
  letter-spacing: 4px;
  font-size: clamp(40px, 7vw, 72px);
  line-height: 1;
  margin: 0 0 14px;
  color: var(--tx-1);
  text-shadow: 0 0 26px var(--accent-glow);
}
.hero-title .dot { color: var(--accent); }
.hero-sub {
  font-size: 14px;
  color: var(--tx-2);
  max-width: 640px;
  margin: 0 auto 28px;
}
@media (max-width: 580px) {
  .hero-title { letter-spacing: 2px; }
  .hero-sub { font-size: 13px; }
  .hero { padding: 20px 0 16px; }
}

/* ============================================================
   SEARCH FORM
   ============================================================ */
.search-form {
  max-width: 820px;
  margin: 0 auto;
}
.search-row {
  display: flex; flex-wrap: wrap;
  gap: 10px;
  align-items: stretch;
  justify-content: center;
}
.search-input-wrap {
  position: relative;
  flex: 1 1 320px;
  min-width: 240px;
}
.search-prompt {
  position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
  font-family: var(--f-mono); color: var(--accent); font-weight: 700;
  pointer-events: none;
  font-size: 16px;
}
#search-input {
  width: 100%;
  height: 52px;
  padding: 0 38px 0 32px;
  font-family: var(--f-mono);
  font-size: 15px;
  background: var(--bg-3);
  color: var(--tx-1);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-sm);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
#search-input::placeholder { color: var(--tx-3); }
#search-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
.input-clear {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  width: 26px; height: 26px;
  border-radius: 50%;
  color: var(--tx-3);
  font-size: 12px;
  display: none;
  align-items: center; justify-content: center;
  transition: color .15s, background .15s;
}
.input-clear:hover { color: var(--tx-1); background: var(--bg-4); }
.search-input-wrap.has-text .input-clear { display: inline-flex; }

.turnstile-wrap {
  flex: 0 0 auto;
  display: flex; align-items: center;
  min-height: 52px;
}

.lookup-btn {
  height: 52px;
  padding: 0 26px;
  background: var(--accent);
  color: #fff;
  font-family: var(--f-display);
  font-weight: 700;
  letter-spacing: 2px;
  font-size: 13px;
  text-transform: uppercase;
  border-radius: var(--r-sm);
  display: inline-flex; align-items: center; gap: 8px;
  transition: background .15s, transform .12s, opacity .15s;
  position: relative;
}
.lookup-btn:hover:not(:disabled) { background: var(--accent-dim); }
.lookup-btn:active:not(:disabled) { transform: translateY(1px); }
.lookup-btn:disabled { opacity: .45; cursor: not-allowed; }
.lookup-btn.loading { pointer-events: none; }
.lookup-btn.loading .btn-arrow { animation: btn-pulse 1s infinite; }
@keyframes btn-pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
.btn-arrow { font-size: 14px; }

@media (max-width: 700px) {
  .turnstile-wrap, .lookup-btn { flex: 1 1 100%; justify-content: center; }
}

/* Quick tags */
.quick-tags {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 6px;
  justify-content: center;
  margin-top: 14px;
  font-family: var(--f-mono);
  font-size: 12px;
}
.quick-label { color: var(--tx-3); margin-right: 4px; }
.quick-tag {
  padding: 4px 10px;
  background: var(--bg-3);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-pill);
  color: var(--tx-2);
  font-size: 12px;
  font-family: var(--f-mono);
  transition: border-color .15s, color .15s, background .15s;
}
.quick-tag:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--bg-2);
}

/* ============================================================
   RESULT REGION + HEADER STRIP
   ============================================================ */
.result-region {
  margin-top: 40px;
}
.result-header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
  padding: 18px 20px;
  background: var(--bg-2);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-md);
  margin-bottom: 14px;
  position: relative; overflow: hidden;
}
.result-header::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
}
.rh-domain {
  font-family: var(--f-display);
  font-weight: 700;
  font-size: clamp(20px, 3.2vw, 28px);
  letter-spacing: 2px;
  word-break: break-all;
  color: var(--tx-1);
}
.rh-meta {
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--tx-2);
  margin-top: 4px;
}
.rh-right { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.rh-badge {
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  padding: 5px 12px;
  border-radius: var(--r-pill);
  border: 1px solid var(--bd-2);
  background: var(--bg-3);
  text-transform: uppercase;
  color: var(--tx-2);
}
.rh-badge.ok      { color: var(--ok);   border-color: var(--ok);   background: rgba(22,163,74,.10); }
.rh-badge.warn    { color: var(--warn); border-color: var(--warn); background: rgba(217,119,6,.10); }
.rh-badge.bad     { color: var(--bad);  border-color: var(--bad);  background: rgba(221,0,0,.10); }
.rh-badge.info    { color: var(--info); border-color: var(--info); background: rgba(59,130,246,.10); }
.rh-countdown {
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--tx-2);
}

/* ============================================================
   TAB BAR
   ============================================================ */
.tab-bar {
  display: flex; flex-wrap: wrap;
  gap: 0;
  background: var(--bg-2);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-md);
  padding: 4px;
  margin-bottom: 14px;
  overflow-x: auto;
}
.tab {
  position: relative;
  padding: 10px 16px;
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--tx-2);
  border-radius: var(--r-sm);
  white-space: nowrap;
  transition: color .15s, background .15s;
  display: inline-flex; align-items: center; gap: 6px;
}
.tab:hover { color: var(--tx-1); background: var(--bg-3); }
.tab.active {
  color: var(--accent);
  background: var(--bg-3);
}
.tab.active::after {
  content: '';
  position: absolute; left: 14px; right: 14px; bottom: 4px;
  height: 2px;
  background: var(--accent);
  border-radius: 1px;
}
.tab[hidden] { display: none !important; }
.tab-count {
  font-size: 10px;
  color: var(--tx-3);
  background: var(--bg-4);
  padding: 1px 6px;
  border-radius: var(--r-pill);
  min-width: 18px;
  text-align: center;
}
.tab.active .tab-count { color: var(--accent); background: var(--bg-2); }
.tab-count:empty { display: none; }

/* ============================================================
   PANELS
   ============================================================ */
.panels { display: block; }
.panel {
  position: relative;
  background: var(--bg-2);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-md);
  margin-bottom: 14px;
  box-shadow: var(--shadow-panel);
  overflow: hidden;
}
.panel::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent 70%);
}
.panel[hidden] { display: none !important; }
.panel-head {
  display: flex; align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--bd-1);
  background: var(--bg-1);
}
.panel-dots { display: inline-flex; gap: 5px; margin-right: 4px; }
.panel-dots i {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--bd-2);
  display: inline-block;
}
.panel-dots i:nth-child(1) { background: #ed6a5e; }
.panel-dots i:nth-child(2) { background: #f4be4f; }
.panel-dots i:nth-child(3) { background: #62c454; }
.panel-title {
  font-family: var(--f-mono);
  font-size: 12px;
  color: var(--tx-2);
}
.panel-tag {
  font-family: var(--f-mono);
  font-size: 11px;
  margin-left: auto;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  border: 1px solid var(--bd-1);
  color: var(--tx-2);
  background: var(--bg-3);
}
.panel-tag.ok  { color: var(--ok);  border-color: var(--ok);  background: rgba(22,163,74,.10); }
.panel-tag.bad { color: var(--bad); border-color: var(--bad); background: rgba(221,0,0,.10); }
.panel-body { padding: 18px 20px; }

/* Skeleton shimmer */
.skeleton { display: block; }
.sk-line {
  height: 14px;
  margin-bottom: 10px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--bg-3) 0%, var(--bg-4) 50%, var(--bg-3) 100%);
  background-size: 200% 100%;
  animation: sk 1.4s infinite;
}
.sk-line.short { width: 60%; }
@keyframes sk {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.copy-btn {
  margin-left: auto;
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--tx-2);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-sm);
  padding: 4px 10px;
  transition: color .15s, border-color .15s;
}
.copy-btn:hover { color: var(--accent); border-color: var(--accent); }

/* ============================================================
   TWO-COLUMN GRID FOR FIELDS
   ============================================================ */
.kv-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 24px;
}
@media (max-width: 800px) { .kv-grid { grid-template-columns: 1fr; } }
.kv {
  display: flex; flex-direction: column;
  padding: 8px 0;
  border-bottom: 1px dashed var(--bd-1);
}
.kv:last-child { border-bottom: 0; }
.kv-label {
  font-family: var(--f-mono);
  font-size: 11px;
  color: var(--tx-3);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 3px;
}
.kv-value {
  font-family: var(--f-mono);
  font-size: 13px;
  color: var(--tx-1);
  word-break: break-word;
}
.kv-value.muted { color: var(--tx-3); }
.kv-value a { color: var(--accent); border-bottom: 1px dotted var(--accent); }
.kv-value a:hover { color: var(--accent-dim); }

/* Date cards — 3 column */
.date-grid {
  display: grid; gap: 10px;
  grid-template-columns: repeat(3, 1fr);
  margin-bottom: 16px;
}
@media (max-width: 560px) { .date-grid { grid-template-columns: repeat(2, 1fr); } }
.date-card {
  padding: 12px 14px;
  border: 1px solid var(--bd-1);
  border-radius: var(--r-sm);
  background: var(--bg-1);
}
.date-card .dc-label {
  font-family: var(--f-mono);
  font-size: 10px; letter-spacing: 1.5px;
  color: var(--tx-3);
  text-transform: uppercase;
  margin-bottom: 4px;
}
.date-card .dc-value {
  font-family: var(--f-mono);
  font-size: 14px;
  font-weight: 500;
}
.date-card.created .dc-value { color: var(--info); }
.date-card.updated .dc-value { color: var(--tx-2); }
.date-card.expires .dc-value { color: var(--ok); }
.date-card.expires.warn .dc-value { color: var(--warn); }
.date-card.expires.bad  .dc-value { color: var(--bad); }
.date-card .dc-sub {
  font-size: 11px; color: var(--tx-3); font-family: var(--f-mono);
  margin-top: 3px;
}

/* Status flags row */
.status-flags { display: flex; flex-wrap: wrap; gap: 6px; }
.flag-chip {
  font-family: var(--f-mono);
  font-size: 11px;
  padding: 3px 9px;
  border-radius: var(--r-pill);
  border: 1px solid var(--bd-2);
  color: var(--tx-2);
  background: var(--bg-3);
}

/* Privacy pill */
.privacy-pill {
  display: inline-block;
  font-family: var(--f-mono);
  font-size: 11px;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  border: 1px solid var(--warn);
  color: var(--warn);
  background: rgba(217,119,6,.10);
  margin-left: 8px;
}

/* Section sub-titles inside panels */
.sub-title {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 1.5px;
  color: var(--accent);
  text-transform: uppercase;
  margin: 18px 0 8px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--bd-1);
}

/* ============================================================
   DNS TABLE
   ============================================================ */
.dns-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--f-mono);
  font-size: 13px;
}
.dns-table th, .dns-table td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--bd-1);
  vertical-align: top;
}
.dns-table th {
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--tx-3);
  background: var(--bg-1);
  font-weight: 500;
}
.dns-table tr:hover td { background: var(--bg-3); }
.dns-table .dns-host { color: var(--tx-1); word-break: break-all; }
.dns-table .dns-val  { color: var(--tx-2); word-break: break-all; }
.dns-table .dns-ttl  { color: var(--tx-3); font-size: 12px; white-space: nowrap; }

.dtype {
  display: inline-block;
  font-family: var(--f-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 3px 8px;
  border-radius: var(--r-sm);
  border: 1px solid var(--c, var(--bd-2));
  color: var(--c, var(--tx-2));
  background: color-mix(in srgb, var(--c, var(--tx-2)) 8%, transparent);
}
.dtype-A     { --c: #3b82f6; }
.dtype-AAAA  { --c: #06b6d4; }
.dtype-MX    { --c: #a855f7; }
.dtype-NS    { --c: #dd0000; }
.dtype-TXT   { --c: #d97706; }
.dtype-CNAME { --c: #16a34a; }
.dtype-SOA   { --c: #14b8a6; }
.dtype-CAA   { --c: #f59e0b; }
.dtype-SRV   { --c: #ec4899; }
.dtype-SPF   { --c: #84cc16; }
.dtype-DMARC { --c: #ef4444; }

@media (max-width: 700px) {
  .dns-table th:nth-child(2), .dns-table td:nth-child(2) { display: none; }
}

/* ============================================================
   BLACKLIST GRID
   ============================================================ */
.bl-summary-card {
  padding: 16px 18px;
  background: var(--bg-1);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-sm);
  margin-bottom: 16px;
  display: flex; align-items: center; gap: 14px;
}
.bl-num {
  font-family: var(--f-display);
  font-size: 32px;
  font-weight: 700;
  color: var(--ok);
}
.bl-num.bad { color: var(--bad); }
.bl-text {
  font-family: var(--f-mono);
  font-size: 13px;
  color: var(--tx-2);
}
.bl-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
}
.bl-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--bd-1);
  border-radius: var(--r-sm);
  background: var(--bg-1);
  font-family: var(--f-mono);
  font-size: 12px;
}
.bl-item.listed { border-color: var(--bad); background: rgba(221,0,0,.06); }
.bl-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--ok);
  flex-shrink: 0;
  box-shadow: 0 0 8px currentColor;
  color: var(--ok);
}
.bl-item.listed .bl-dot { background: var(--bad); color: var(--bad); }
.bl-label { flex: 1; color: var(--tx-1); }
.bl-code  { color: var(--tx-3); font-size: 11px; }

/* ============================================================
   SSL DETAILS
   ============================================================ */
.ssl-day-card {
  text-align: center;
  padding: 18px;
  border: 1px solid var(--bd-1);
  border-radius: var(--r-md);
  background: var(--bg-1);
  margin-bottom: 16px;
}
.ssl-day-num {
  font-family: var(--f-display);
  font-size: 44px;
  font-weight: 700;
  color: var(--ok);
  line-height: 1;
}
.ssl-day-num.warn { color: var(--warn); }
.ssl-day-num.bad  { color: var(--bad); }
.ssl-day-label {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--tx-3);
  margin-top: 6px;
}
.san-list {
  display: flex; flex-wrap: wrap; gap: 4px;
  font-family: var(--f-mono);
  font-size: 12px;
}
.san-chip {
  padding: 3px 9px;
  border-radius: var(--r-pill);
  background: var(--bg-3);
  border: 1px solid var(--bd-1);
  color: var(--tx-2);
}

/* ============================================================
   RAW OUTPUT
   ============================================================ */
.raw-output {
  font-family: var(--f-mono);
  font-size: 12px;
  background: var(--bg-1);
  color: var(--tx-2);
  padding: 16px;
  border-radius: var(--r-sm);
  border: 1px solid var(--bd-1);
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 540px;
  overflow-y: auto;
  margin: 0;
  line-height: 1.55;
}

/* ============================================================
   INFO MESSAGES (unhosted, errors)
   ============================================================ */
.info-msg {
  padding: 16px 18px;
  background: var(--bg-1);
  border: 1px dashed var(--bd-2);
  border-radius: var(--r-sm);
  font-family: var(--f-mono);
  font-size: 13px;
  color: var(--tx-2);
  text-align: center;
}
.info-msg.warn { border-color: var(--warn); color: var(--warn); }
.info-msg.bad  { border-color: var(--bad);  color: var(--bad); }

/* ============================================================
   HISTORY
   ============================================================ */
.history-section, .seo-cards, .faq-section {
  margin-top: 56px;
}
.section-head {
  display: flex; align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap; gap: 8px;
}
.section-title {
  font-family: var(--f-mono);
  font-size: 14px;
  font-weight: 500;
  color: var(--accent);
  margin: 0;
  letter-spacing: 1.5px;
}
.section-badge {
  font-family: var(--f-mono);
  font-size: 10px; letter-spacing: 2px;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  border: 1px solid var(--bd-1);
  color: var(--tx-3);
  background: var(--bg-3);
}
.history-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
}
.history-item {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px;
  background: var(--bg-2);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-sm);
  font-family: var(--f-mono);
  font-size: 12px;
  transition: border-color .15s, background .15s, transform .15s;
}
.history-item:hover {
  border-color: var(--accent);
  background: var(--bg-3);
  transform: translateY(-1px);
}
.hi-icon { color: var(--accent); }
.hi-domain { color: var(--tx-1); flex: 1; word-break: break-all; }
.hi-ago { color: var(--tx-3); font-size: 11px; }
.hi-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--ok); }
.hi-dot.err { background: var(--bad); }
.history-empty {
  grid-column: 1 / -1;
  padding: 30px;
  text-align: center;
  color: var(--tx-3);
  font-family: var(--f-mono);
  font-size: 13px;
  border: 1px dashed var(--bd-1);
  border-radius: var(--r-sm);
}

/* ============================================================
   SEO CARDS
   ============================================================ */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
}
.seo-card {
  padding: 22px;
  background: var(--bg-2);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-md);
  position: relative;
  overflow: hidden;
}
.seo-card::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
}
.seo-card-num {
  font-family: var(--f-display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 3px;
  color: var(--accent);
  margin-bottom: 10px;
}
.seo-card h3 {
  font-family: var(--f-display);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 1.5px;
  margin: 0 0 8px;
  color: var(--tx-1);
}
.seo-card p {
  font-size: 13px;
  color: var(--tx-2);
  margin: 0;
  line-height: 1.6;
}
.seo-card code { background: var(--bg-3); color: var(--accent); }

/* ============================================================
   FAQ
   ============================================================ */
.faq-list { display: flex; flex-direction: column; gap: 8px; }
.faq-item {
  background: var(--bg-2);
  border: 1px solid var(--bd-1);
  border-radius: var(--r-md);
  padding: 14px 18px;
  transition: border-color .15s;
}
.faq-item[open] { border-color: var(--accent); }
.faq-item summary {
  cursor: pointer;
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 1px;
  color: var(--tx-1);
  list-style: none;
  display: flex; justify-content: space-between; align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-arrow {
  color: var(--accent);
  transition: transform .2s;
  font-family: var(--f-mono);
  font-size: 14px;
}
.faq-item[open] .faq-arrow { transform: rotate(180deg); }
.faq-item p {
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--tx-2);
  line-height: 1.65;
}
.faq-item code { background: var(--bg-3); color: var(--accent); }

/* ============================================================
   FOOTER
   ============================================================ */
.ihk-footer {
  position: relative; z-index: 2;
  border-top: 1px solid var(--bd-1);
  background: var(--bg-1);
  margin-top: 60px;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 22px 16px;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 14px;
  font-family: var(--f-mono);
  font-size: 12px;
}
.footer-left { display: flex; gap: 14px; align-items: center; color: var(--tx-3); }
.footer-logo { color: var(--accent); font-weight: 700; }
.footer-version { color: var(--tx-3); }
.footer-right { display: flex; gap: 16px; }
.footer-right a { color: var(--tx-2); transition: color .15s; }
.footer-right a:hover { color: var(--accent); }

/* ============================================================
   TOAST
   ============================================================ */
.toast-stack {
  position: fixed; right: 16px; bottom: 16px;
  z-index: 100;
  display: flex; flex-direction: column; gap: 8px;
  pointer-events: none;
}
.toast {
  pointer-events: auto;
  background: var(--bg-2);
  color: var(--tx-1);
  border: 1px solid var(--bd-1);
  border-left: 3px solid var(--accent);
  border-radius: var(--r-sm);
  padding: 10px 16px;
  font-family: var(--f-mono);
  font-size: 13px;
  box-shadow: 0 8px 24px rgba(0,0,0,.30);
  animation: toast-in .25s ease-out;
  max-width: 360px;
}
.toast.ok  { border-left-color: var(--ok); }
.toast.warn{ border-left-color: var(--warn); }
.toast.bad { border-left-color: var(--bad); }
.toast.fade-out { animation: toast-out .25s ease-in forwards; }
@keyframes toast-in {
  from { transform: translateX(20px); opacity: 0; }
  to   { transform: translateX(0);     opacity: 1; }
}
@keyframes toast-out {
  to { transform: translateX(20px); opacity: 0; }
}

/* ============================================================
   UTILITIES
   ============================================================ */
.mono { font-family: var(--f-mono); }
.muted { color: var(--tx-3); }
.small { font-size: 11px; }
[hidden] { display: none !important; }

/* Scrollbar styling */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-1); }
::-webkit-scrollbar-thumb { background: var(--bg-4); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-dim); }
