
:root {
  --ink: #111214;
  --ink-muted: #52565e;
  --ink-subtle: #6e737d;
  --paper: #faf9f5;
  --surface: #ffffff;
  --surface-tint: #f3f1ea;
  --border: #e5e2d9;
  --gold: #cfb87c;
  --gold-deep: #8f7430;
  --accent-red: #b42318;
  --accent-blue: #175cd3;
  --accent-green: #067647;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(17, 18, 20, 0.05);
  --shadow-md: 0 8px 28px rgba(17, 18, 20, 0.07);
}

*, *::before, *::after { box-sizing: border-box; }

body.kl-editorial {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}


.kl-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(17, 18, 20, 0.96);
  backdrop-filter: blur(10px);
  border-bottom: 3px solid var(--gold);
  padding: 0.85rem clamp(1.25rem, 4vw, 3rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 2rem;
}

.kl-brand-link {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: #fff;
  line-height: 1.15;
}
.kl-brand-kicker {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--gold);
}
.kl-brand-title {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
}

.kl-nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
}
.kl-nav a {
  color: #e4e2dc;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 550;
  padding: 0.4rem 0.68rem;
  border-radius: 999px;
  white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease;
}
.kl-nav a:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}
.kl-nav a[aria-current="page"] {
  background: var(--gold);
  color: #111;
  font-weight: 700;
}


.kl-wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(2rem, 5vw, 3.75rem) clamp(1.25rem, 4vw, 2.5rem) 4.5rem;
}


.kl-hero {
  max-width: 820px;
  margin-bottom: 2.75rem;
}
.kl-eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-bottom: 0.75rem;
}
.kl-hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 4.4vw, 3.15rem);
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.09;
  color: var(--ink);
}
.kl-hero p.kl-lead {
  margin: 0;
  font-size: clamp(1.05rem, 1.8vw, 1.22rem);
  color: var(--ink-muted);
  max-width: 68ch;
  line-height: 1.55;
}


.kl-stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.1rem;
  margin: 2.25rem 0 3rem;
}
.kl-stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem 1.5rem;
  box-shadow: var(--shadow-sm);
}
.kl-stat-num {
  display: block;
  font-size: clamp(1.9rem, 3vw, 2.45rem);
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.kl-stat-label {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
}
.kl-stat-sub {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.82rem;
  color: var(--ink-subtle);
}


.kl-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  margin-bottom: 1.75rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.kl-toolbar h2 {
  margin: 0;
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.kl-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.kl-pill {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink-muted);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.kl-pill:hover { border-color: var(--ink); color: var(--ink); }
.kl-pill.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}


.kl-gallery-controls {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.1rem;
  border-bottom: 1px solid var(--border);
}
.kl-gallery-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
}
.kl-gallery-title-wrap {
  display: flex;
  align-items: baseline;
  gap: 0.65rem;
}
.kl-gallery-title-wrap h2 {
  margin: 0;
  font-size: 1.45rem;
  font-weight: 740;
  letter-spacing: -0.025em;
}
.kl-gallery-count {
  font-size: 0.82rem;
  font-weight: 650;
  color: var(--ink-subtle);
  font-variant-numeric: tabular-nums;
}
.kl-filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}
.kl-filter-subrow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 1rem;
}
.kl-seg-group {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  background: var(--surface-tint);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 2px;
  gap: 2px;
}
.kl-seg {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink-muted);
  font: inherit;
  font-size: 0.77rem;
  font-weight: 650;
  padding: 0.3rem 0.68rem;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.14s ease, color 0.14s ease, box-shadow 0.14s ease;
}
.kl-seg:hover { color: var(--ink); }
.kl-seg.is-active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(17, 18, 20, 0.09);
}
.kl-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
}
.kl-pill-ct {
  font-size: 0.74rem;
  font-weight: 700;
  opacity: 0.72;
  font-variant-numeric: tabular-nums;
}
.kl-tone-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  display: inline-block;
  flex-shrink: 0;
}
.kl-tone-dot.tone-crimson { background: #b42318; }
.kl-tone-dot.tone-amber { background: #b54708; }
.kl-tone-dot.tone-plum { background: #7e22ce; }
.kl-tone-dot.tone-blue { background: #175cd3; }


.kl-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.35rem;
  align-items: start;
}
@media (max-width: 1020px) {
  .kl-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.kl-empty-state {
  grid-column: 1 / -1;
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  color: var(--ink-muted);
}
.kl-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.kl-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: #d6d1c4;
}


.kl-card-head {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.62rem 0.85rem;
  background: var(--surface-tint);
  border-bottom: 1px solid var(--border);
}
.kl-head-main {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
  flex: 1;
}
.kl-head-top,
.kl-head-sub {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  min-width: 0;
}
.kl-app-stack {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.kl-app-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(17, 18, 20, 0.12);
  box-shadow: 0 1px 2px rgba(17, 18, 20, 0.08);
  background: #fff;
}
.kl-app-icon-stacked {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  margin-left: -10px;
  border: 2px solid var(--surface-tint);
}
.kl-app-icon-fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.82rem;
  color: var(--ink);
  background: var(--gold);
}
.kl-place-line {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  min-width: 0;
  flex: 1;
}
.kl-app-chip-name {
  font-size: 0.85rem;
  font-weight: 750;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.kl-app-more {
  font-size: 0.65rem;
  font-weight: 750;
  color: var(--ink-muted);
  background: #e9e5da;
  padding: 0.05rem 0.32rem;
  border-radius: 999px;
  flex-shrink: 0;
}
.kl-kid-age {
  font-size: 0.65rem;
  font-weight: 780;
  color: #065f46;
  background: #ecfdf3;
  border: 1px solid #a6f4c5;
  padding: 0.06rem 0.36rem;
  border-radius: 5px;
  white-space: nowrap;
  flex-shrink: 0;
}
.kl-app-chip-pub {
  font-size: 0.69rem;
  color: var(--ink-subtle);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}


.kl-card-media {
  appearance: none;
  border: 0;
  padding: 0;
  position: relative;
  width: 100%;
  height: 224px;
  background: #f1efe8;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border);
  cursor: zoom-in;
}
.kl-card-media:focus:not(:focus-visible) {
  outline: none;
}
.kl-card-media.is-landscape {
  padding: 0;
  background: #141518;
}
.kl-card-media.is-portrait {
  padding: 0.55rem;
  background: radial-gradient(circle at center, #f7f5ee 0%, #ebe7dc 100%);
}
.kl-card-media.is-square {
  padding: 1rem;
  background: radial-gradient(circle at center, #f7f5ee 0%, #ebe7dc 100%);
}
.kl-card-media.is-banner {
  padding: 1rem 0.9rem;
  background: radial-gradient(circle at center, #f7f5ee 0%, #ebe7dc 100%);
}
.kl-card-media img.kl-creative-img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 6px;
  box-shadow: 0 4px 14px rgba(17, 18, 20, 0.14);
}
.kl-card-media.is-landscape img.kl-creative-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
  box-shadow: none;
}
.kl-card-media.is-banner img.kl-creative-img {
  width: 100%;
  max-height: 120px;
  object-fit: contain;
  border-radius: 8px;
}
.kl-zoom-hint {
  position: absolute;
  right: 0.55rem;
  bottom: 0.55rem;
  font-size: 0.68rem;
  font-weight: 700;
  color: #fff;
  background: rgba(17, 18, 20, 0.72);
  backdrop-filter: blur(4px);
  padding: 0.18rem 0.48rem;
  border-radius: 999px;
  opacity: 0;
  transition: opacity 0.15s ease;
  pointer-events: none;
}
.kl-card-media:hover .kl-zoom-hint,
.kl-card-media:focus-visible .kl-zoom-hint {
  opacity: 1;
}

.kl-badge {
  font-size: 0.62rem;
  font-weight: 730;
  letter-spacing: 0.02em;
  padding: 0.12rem 0.44rem;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
}
.kl-badge-virt {
  background: #17181c;
  color: var(--gold);
  border: 1px solid rgba(207, 184, 124, 0.45);
}
.kl-badge-prog {
  background: #175cd3;
  color: #fff;
}


.kl-card-body {
  padding: 0.95rem 1.05rem 0.95rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.kl-tax-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  margin-bottom: 0.55rem;
}
.kl-tax-right {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-shrink: 0;
}
.kl-harm-pill {
  display: inline-flex;
  align-items: stretch;
  border-radius: 7px;
  overflow: hidden;
  font-size: 0.72rem;
  font-weight: 740;
  line-height: 1;
  border: 1px solid transparent;
}
.kl-age-gate {
  padding: 0.24rem 0.4rem;
  font-weight: 820;
  letter-spacing: 0.01em;
  color: #fff;
}
.kl-harm-tag {
  padding: 0.24rem 0.48rem;
  white-space: nowrap;
}
.kl-harm-pill.tone-crimson { background: #fef3f2; border-color: #fecdca; color: #912018; }
.kl-harm-pill.tone-crimson .kl-age-gate { background: #b42318; }
.kl-harm-pill.tone-amber { background: #fffaeb; border-color: #fedf89; color: #93370d; }
.kl-harm-pill.tone-amber .kl-age-gate { background: #b54708; }
.kl-harm-pill.tone-plum { background: #faf5ff; border-color: #e9d5ff; color: #6b21a8; }
.kl-harm-pill.tone-plum .kl-age-gate { background: #7e22ce; }
.kl-harm-pill.tone-blue { background: #eff8ff; border-color: #b2ddff; color: #1849a9; }
.kl-harm-pill.tone-blue .kl-age-gate { background: #175cd3; }

.kl-cpm-tag {
  font-size: 0.69rem;
  font-weight: 720;
  color: var(--ink-muted);
  background: var(--surface-tint);
  border: 1px solid var(--border);
  padding: 0.18rem 0.42rem;
  border-radius: 6px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.kl-brand-block {
  margin-bottom: 0.7rem;
}
.kl-card-brand {
  margin: 0;
  font-size: 1.14rem;
  font-weight: 760;
  letter-spacing: -0.02em;
  line-height: 1.22;
  color: var(--ink);
}
.kl-card-sub {
  margin: 0.16rem 0 0;
  font-size: 0.8rem;
  color: var(--ink-muted);
  line-height: 1.3;
}


.kl-spec-grid {
  margin: 0;
  padding: 0.58rem 0.68rem;
  background: #faf9f6;
  border: 1px solid var(--border);
  border-radius: 10px;
  display: grid;
  gap: 0.38rem;
}
.kl-spec-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  align-items: baseline;
  gap: 0.42rem;
}
.kl-spec-row dt {
  font-size: 0.64rem;
  font-weight: 760;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-subtle);
}
.kl-spec-row dd {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.3;
  color: var(--ink);
  font-weight: 560;
  overflow-wrap: anywhere;
}
.kl-spec-row.is-fault dd {
  color: #912018;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.36rem;
}
.kl-fault-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--accent-red);
  flex-shrink: 0;
}
.kl-route-chain {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.18rem;
  font-size: 0.72rem !important;
  color: var(--ink-muted) !important;
}
.kl-route-hop {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 0.04rem 0.28rem;
  font-weight: 620;
  color: var(--ink);
  white-space: nowrap;
}
.kl-route-sep {
  color: var(--ink-subtle);
  font-weight: 700;
}

.kl-action-link {
  font-size: 0.8rem;
  font-weight: 720;
  text-decoration: none;
}
.kl-action-link.is-trace { color: var(--accent-red); }
.kl-action-link.is-story { color: var(--accent-blue); }
.kl-action-link:hover { text-decoration: underline; }


.kl-proof {
  margin-top: 0.65rem;
  padding-top: 0.65rem;
  border-top: 1px solid var(--border);
}
.kl-proof summary {
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 660;
  color: var(--ink-muted);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.kl-proof summary:hover { color: var(--ink); }
.kl-proof summary::-webkit-details-marker { display: none; }
.kl-proof summary::after {
  content: "+";
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--ink-subtle);
}
.kl-proof[open] summary::after { content: "−"; }
.kl-proof-grid {
  margin-top: 0.65rem;
  background: var(--surface-tint);
  border-radius: var(--radius-sm);
  padding: 0.75rem 0.85rem;
  font-size: 0.79rem;
  line-height: 1.48;
  color: var(--ink-muted);
  display: grid;
  gap: 0.42rem;
}
.kl-proof-grid strong { color: var(--ink); }
.kl-proof-grid code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.73rem;
  word-break: break-all;
}


.kl-lightbox[hidden] { display: none; }
.kl-lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.kl-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 18, 20, 0.82);
  backdrop-filter: blur(6px);
}
.kl-lightbox-panel {
  position: relative;
  z-index: 1;
  background: #17181c;
  color: #fff;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  max-width: min(92vw, 880px);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.kl-lightbox-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 1.1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.kl-lightbox-meta {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}
.kl-lightbox-meta strong { font-size: 0.98rem; color: #fff; }
.kl-lightbox-meta span { font-size: 0.8rem; color: #c7c4ba; }
.kl-lightbox-close {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}
.kl-lightbox-close:hover { background: rgba(255, 255, 255, 0.2); }
.kl-lightbox-stage {
  padding: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: auto;
}
.kl-lightbox-stage img {
  max-width: 100%;
  max-height: 72vh;
  width: auto;
  height: auto;
  border-radius: 8px;
}


.kl-callout {
  background: var(--ink);
  color: #f6f4ee;
  border-radius: var(--radius);
  padding: clamp(1.5rem, 3.5vw, 2.25rem);
  margin: 2rem 0 2.75rem;
  border-left: 5px solid var(--gold);
}
.kl-callout h2 {
  margin: 0 0 0.65rem;
  font-size: clamp(1.3rem, 2.5vw, 1.75rem);
  letter-spacing: -0.02em;
  color: #fff;
}
.kl-callout p {
  margin: 0;
  color: #dcd9d0;
  max-width: 72ch;
  font-size: 1.02rem;
}
.kl-callout strong { color: var(--gold); }


.kl-section {
  margin: 3rem 0;
}
.kl-section-head {
  max-width: 740px;
  margin-bottom: 1.5rem;
}
.kl-section-head h2 {
  margin: 0 0 0.45rem;
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  font-weight: 730;
  letter-spacing: -0.025em;
}
.kl-section-head p {
  margin: 0;
  color: var(--ink-muted);
  font-size: 1rem;
}

.kl-two-col {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}
.kl-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1.65rem;
  box-shadow: var(--shadow-sm);
}
.kl-panel h3 {
  margin: 0 0 0.6rem;
  font-size: 1.12rem;
  font-weight: 700;
}


.kl-table-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow-x: auto;
  box-shadow: var(--shadow-sm);
}
.kl-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}
.kl-table th {
  text-align: left;
  font-size: 0.74rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-subtle);
  background: var(--surface-tint);
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
}
.kl-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.kl-table tr:last-child td { border-bottom: 0; }
.kl-num { font-variant-numeric: tabular-nums; font-weight: 650; }
.kl-bar-track {
  width: 140px;
  height: 8px;
  background: var(--surface-tint);
  border-radius: 999px;
  overflow: hidden;
  display: inline-block;
  vertical-align: middle;
  margin-left: 0.5rem;
}
.kl-bar-fill {
  height: 100%;
  background: var(--ink);
  border-radius: 999px;
}
.kl-bar-fill.is-safe { background: var(--accent-green); }
.kl-bar-fill.is-warn { background: var(--accent-red); }


.kl-calc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.kl-field label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-subtle);
  margin-bottom: 0.35rem;
}
.kl-field select {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--paper);
  font: inherit;
  font-size: 0.92rem;
  color: var(--ink);
}
.kl-calc-result {
  background: var(--surface-tint);
  border-radius: var(--radius-sm);
  padding: 1.15rem 1.35rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}
.kl-calc-price {
  font-size: 2.1rem;
  font-weight: 780;
  letter-spacing: -0.03em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}


.kl-footer {
  border-top: 1px solid var(--border);
  padding: 2rem clamp(1.25rem, 4vw, 2.5rem) 3rem;
  color: var(--ink-subtle);
  font-size: 0.86rem;
}
.kl-footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem 2rem;
}
.kl-footer a {
  color: var(--ink-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.kl-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.1rem;
}

@media (max-width: 680px) {
  .kl-header { flex-direction: column; align-items: flex-start; gap: 0.65rem; }
  .kl-card-grid { grid-template-columns: 1fr; }
  .kl-gallery-head .kl-net-search { width: 100%; min-width: 0; }
}


.kl-wrap-wide {
  max-width: 1380px;
}
.kl-hero-wide {
  max-width: none;
  width: 100%;
}
.kl-hero-wide p.kl-lead-wide {
  max-width: none;
  width: 100%;
  font-size: clamp(1.04rem, 1.4vw, 1.16rem);
  line-height: 1.62;
  color: var(--ink-muted);
}
.kl-hero-wide p.kl-lead-wide strong {
  color: var(--ink);
}
.kl-hover-tech {
  margin: 0.45rem 0;
  padding: 0.48rem 0.62rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  font-size: 0.73rem;
  color: #cbd5e1;
  display: grid;
  gap: 0.2rem;
}
.kl-hover-tech-label {
  font-size: 0.65rem;
  font-weight: 780;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--gold);
  margin-bottom: 0.1rem;
}
.kl-hover-tech code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.7rem;
  color: #f8fafc;
}

.kl-net-controls {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.kl-net-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.65rem 1rem;
}

.kl-net-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.kl-net-group-label {
  font-size: 0.72rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-subtle);
  margin-right: 0.2rem;
}

.kl-pill.is-red-active {
  background: var(--accent-red);
  border-color: var(--accent-red);
  color: #fff;
}

.kl-net-search {
  border: 1px solid var(--border);
  background: var(--paper);
  border-radius: 999px;
  padding: 0.42rem 0.9rem;
  font: inherit;
  font-size: 0.86rem;
  color: var(--ink);
  min-width: 230px;
}
.kl-net-search:focus {
  outline: 2px solid var(--ink);
  outline-offset: 1px;
}

.kl-net-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--ink-muted);
  cursor: pointer;
  user-select: none;
}
.kl-net-toggle input {
  accent-color: var(--accent-red);
  cursor: pointer;
}

.kl-net-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem 1.25rem;
  padding: 0.7rem 1rem;
  background: var(--surface-tint);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  color: var(--ink-muted);
  margin-bottom: 1rem;
}

.kl-legend-items {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.15rem;
}

.kl-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 600;
}

.kl-dot {
  width: 11px;
  height: 11px;
  border-radius: 999px;
  display: inline-block;
  flex-shrink: 0;
}
.kl-dot-red { background: var(--accent-red); box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.22); }
.kl-dot-green { background: var(--accent-green); }
.kl-dot-amber { background: #b54708; }
.kl-dot-slate { background: #fff; border: 2px dashed #6e737d; }

.kl-focus-banner {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 1rem;
  margin-bottom: 1rem;
  background: #fef3f2;
  border: 1px solid #fecdca;
  border-left: 4px solid var(--accent-red);
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  color: #7a271a;
}
.kl-focus-banner.is-visible { display: flex; }


.kl-graph-shell {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow-x: auto;
  overflow-y: hidden;
  position: relative;
}

.kl-graph-canvas {
  position: relative;
  min-width: 1160px;
  background:
    radial-gradient(circle at 1px 1px, rgba(17, 18, 20, 0.045) 1px, transparent 0);
  background-size: 24px 24px;
}

.kl-stage-headers {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border-bottom: 1px solid var(--border);
  background: var(--surface-tint);
}

.kl-stage-head {
  padding: 0.75rem 0.9rem;
  border-right: 1px solid var(--border);
}
.kl-stage-head:last-child { border-right: 0; }
.kl-stage-title {
  display: block;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink);
}
.kl-stage-sub {
  display: block;
  font-size: 0.74rem;
  color: var(--ink-subtle);
  margin-top: 0.1rem;
}

.kl-graph-inner {
  position: relative;
  width: 100%;
}

.kl-graph-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: auto;
  overflow: visible;
}

.kl-edge-group {
  cursor: pointer;
  transition: opacity 0.16s ease;
}
.kl-edge-group.is-dim { opacity: 0.12; }
.kl-edge-group.is-hot .kl-edge-path { filter: drop-shadow(0 2px 5px rgba(180, 35, 24, 0.35)); }

.kl-edge-hit {
  fill: none;
  stroke: transparent;
  pointer-events: stroke;
}
.kl-edge-path {
  fill: none;
  stroke-linecap: round;
  transition: stroke-opacity 0.15s ease, stroke-width 0.15s ease;
  pointer-events: none;
}
.kl-edge-flow {
  fill: none;
  stroke-linecap: round;
  stroke-dasharray: 6 10;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s ease;
}
.kl-edge-group.is-hot .kl-edge-flow,
.kl-edge-group.is-painpoint-pulse .kl-edge-flow {
  opacity: 0.9;
  animation: klFlowDash 1.1s linear infinite;
}
@keyframes klFlowDash {
  from { stroke-dashoffset: 32; }
  to { stroke-dashoffset: 0; }
}

.kl-edge-pill-bg {
  rx: 9;
  ry: 9;
  stroke-width: 1.25;
}
.kl-edge-pill-text {
  font-size: 10.5px;
  font-weight: 750;
  text-anchor: middle;
  dominant-baseline: central;
  font-variant-numeric: tabular-nums;
  pointer-events: none;
}


.kl-node-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.kl-node {
  position: absolute;
  pointer-events: auto;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 11px;
  padding: 0.55rem 0.65rem;
  box-shadow: 0 2px 7px rgba(17, 18, 20, 0.06);
  cursor: pointer;
  transition: transform 0.14s ease, box-shadow 0.14s ease, opacity 0.16s ease, border-color 0.14s ease;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.25rem;
}
.kl-node:hover,
.kl-node.is-hot {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(17, 18, 20, 0.13);
  z-index: 12;
}
.kl-node.is-dim { opacity: 0.16; }

.kl-node.is-painpoint {
  border: 2.5px solid var(--accent-red);
  background: #fffbfa;
  box-shadow: 0 0 0 4px rgba(180, 35, 24, 0.14), 0 4px 12px rgba(180, 35, 24, 0.15);
}
.kl-node.is-painpoint:hover,
.kl-node.is-painpoint.is-hot {
  box-shadow: 0 0 0 6px rgba(180, 35, 24, 0.24), 0 8px 22px rgba(180, 35, 24, 0.24);
}
.kl-node.is-intact {
  border-color: rgba(6, 118, 71, 0.55);
  border-left: 4px solid var(--accent-green);
}
.kl-node.is-downstream {
  border-color: #d6d2c7;
  border-left: 4px solid #b54708;
}
.kl-node.is-boundary {
  border: 1.5px dashed #8c929d;
  background: #f8f8f6;
}
.kl-node.is-focused {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

.kl-node-top {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
}
.kl-node-icon {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--border);
  background: #141519;
}
.kl-node-thumb {
  width: 34px;
  height: 26px;
  border-radius: 5px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--border);
  background: #141519;
}
.kl-node-titles {
  min-width: 0;
  flex: 1;
}
.kl-node-name {
  font-size: 0.82rem;
  font-weight: 740;
  line-height: 1.2;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.kl-node-sub {
  font-size: 0.7rem;
  color: var(--ink-subtle);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kl-node-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
  margin-top: 0.08rem;
}

.kl-sig-chip {
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.12rem 0.42rem;
  border-radius: 999px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 145px;
}
.kl-sig-red { background: var(--accent-red); color: #fff; }
.kl-sig-green { background: #ecfdf3; color: var(--accent-green); border: 1px solid #abefc6; }
.kl-sig-amber { background: #fffaeb; color: #b54708; border: 1px solid #fedf89; }
.kl-sig-slate { background: #f2f4f7; color: #475467; border: 1px dashed #98a2b3; }

.kl-occ-tag {
  font-size: 0.72rem;
  font-weight: 780;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  background: var(--surface-tint);
  padding: 0.08rem 0.42rem;
  border-radius: 6px;
  flex-shrink: 0;
}
.kl-node.is-painpoint .kl-occ-tag {
  background: #fee4e2;
  color: #912018;
}


.kl-hover-card {
  position: fixed;
  z-index: 90;
  width: 340px;
  max-width: calc(100vw - 24px);
  background: rgba(17, 18, 20, 0.97);
  color: #f6f4ee;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  padding: 0.9rem 1rem;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.34);
  pointer-events: none;
  display: none;
  font-size: 0.83rem;
  line-height: 1.45;
}
.kl-hover-card.is-visible { display: block; }
.kl-hover-card.is-painpoint { border-color: #f97066; border-top: 4px solid #d92d20; }
.kl-hover-kicker {
  font-size: 0.68rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--gold);
}
.kl-hover-title {
  font-size: 0.98rem;
  font-weight: 750;
  color: #fff;
  margin: 0.15rem 0 0.45rem;
}
.kl-hover-blame {
  background: rgba(217, 45, 32, 0.22);
  border: 1px solid rgba(249, 112, 102, 0.55);
  color: #fee4e2;
  border-radius: 8px;
  padding: 0.45rem 0.6rem;
  margin: 0.45rem 0;
  font-size: 0.8rem;
}
.kl-hover-diff {
  display: grid;
  gap: 0.28rem;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  padding: 0.5rem 0.65rem;
  margin: 0.45rem 0;
  font-size: 0.78rem;
}
.kl-hover-diff strong { color: #d0d5dd; }
.kl-hover-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.85rem;
  font-size: 0.77rem;
  color: #d0d5dd;
  margin-top: 0.45rem;
}
.kl-hover-hint {
  margin-top: 0.55rem;
  padding-top: 0.45rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.72rem;
  color: #98a2b3;
}


.kl-ctx-menu {
  position: fixed;
  z-index: 100;
  min-width: 260px;
  max-width: 310px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 18px 40px rgba(17, 18, 20, 0.2);
  padding: 0.4rem;
  display: none;
}
.kl-ctx-menu.is-visible { display: block; }
.kl-ctx-head {
  padding: 0.5rem 0.65rem 0.45rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.3rem;
}
.kl-ctx-head-kicker {
  font-size: 0.66rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-subtle);
}
.kl-ctx-head-title {
  font-size: 0.88rem;
  font-weight: 740;
  color: var(--ink);
  line-height: 1.25;
}
.kl-ctx-item {
  width: 100%;
  appearance: none;
  border: 0;
  background: transparent;
  text-align: left;
  padding: 0.52rem 0.68rem;
  border-radius: 8px;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  text-decoration: none;
}
.kl-ctx-item:hover { background: var(--surface-tint); }
.kl-ctx-item.is-danger { color: var(--accent-red); }
.kl-ctx-item.is-danger:hover { background: #fef3f2; }
.kl-ctx-sep {
  height: 1px;
  background: var(--border);
  margin: 0.3rem 0.25rem;
}


.kl-drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 105;
  background: rgba(17, 18, 20, 0.38);
  display: none;
}
.kl-drawer-backdrop.is-visible { display: block; }

.kl-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 110;
  width: 470px;
  max-width: 100vw;
  background: var(--surface);
  border-left: 1px solid var(--border);
  box-shadow: -12px 0 36px rgba(17, 18, 20, 0.18);
  transform: translateX(100%);
  transition: transform 0.2s ease;
  display: flex;
  flex-direction: column;
}
.kl-drawer.is-open { transform: translateX(0); }
.kl-drawer-head {
  padding: 1.15rem 1.35rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  background: var(--surface-tint);
}
.kl-drawer-body {
  padding: 1.2rem 1.35rem 2rem;
  overflow-y: auto;
  flex: 1;
  display: grid;
  gap: 1rem;
  align-content: start;
}
.kl-drawer-close {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 8px;
  padding: 0.3rem 0.65rem;
  font-weight: 700;
  cursor: pointer;
  color: var(--ink);
}
.kl-drawer-section {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.85rem 1rem;
  font-size: 0.86rem;
}
.kl-drawer-section h4 {
  margin: 0 0 0.45rem;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-subtle);
}
.kl-drawer-section.is-painpoint {
  background: #fef3f2;
  border-color: #fecdca;
  color: #7a271a;
}
.kl-drawer-list {
  margin: 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.35rem;
}
.kl-drawer-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.75rem;
  background: #17181c;
  color: #e4e2dc;
  padding: 0.75rem;
  border-radius: 8px;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-word;
}


.kl-matrix-list {
  display: grid;
  gap: 0.9rem;
}
.kl-chain-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.05rem 1.2rem;
  box-shadow: var(--shadow-sm);
}
.kl-chain-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 0.85rem;
}
.kl-chain-hops {
  display: grid;
  grid-template-columns: repeat(5, minmax(150px, 1fr));
  gap: 0.55rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
}
.kl-hop-box {
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 0.6rem 0.7rem;
  background: var(--paper);
  font-size: 0.78rem;
  cursor: pointer;
}
.kl-hop-box.is-painpoint {
  border: 2px solid var(--accent-red);
  background: #fef3f2;
}
.kl-hop-box.is-intact {
  border-left: 3px solid var(--accent-green);
}
.kl-hop-box.is-boundary {
  border-style: dashed;
}

.kl-toast {
  position: fixed;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 120;
  background: var(--ink);
  color: #fff;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 600;
  max-width: calc(100vw - 2rem);
  text-align: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  display: none;
}
.kl-toast.is-visible { display: block; }

@media (max-width: 780px) {
  .kl-net-search { width: 100%; min-width: 0; }
  .kl-chain-hops { grid-template-columns: 1fr; }
}




.kl-nav a.kl-nav-support {
  border: 1px solid rgba(207, 184, 124, 0.72);
  background: rgba(207, 184, 124, 0.14);
  color: #f6e7bc;
  font-weight: 700;
}
.kl-nav a.kl-nav-support:hover,
.kl-nav a.kl-nav-support[aria-current="page"] {
  background: var(--gold);
  border-color: var(--gold);
  color: #111214;
}

@media (max-width: 1240px) {
  .kl-nav { gap: 0.25rem; }
  .kl-nav a { font-size: 0.85rem; padding: 0.38rem 0.68rem; }
}

@media (max-width: 680px) {
  .kl-nav a { font-size: 0.82rem; padding: 0.36rem 0.62rem; }
}


.kl-btn-primary,
.kl-btn-secondary,
.kl-btn-gold,
.kl-btn-outline-light,
.kl-btn-danger,
.kl-btn-danger-outline {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border-radius: 999px;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  padding: 0.65rem 1.3rem;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.12s ease;
  line-height: 1.25;
  max-width: 100%;
}
.kl-btn-primary {
  background: var(--ink);
  color: #fff;
  border: 1.5px solid var(--ink);
}
.kl-btn-primary:hover:not(:disabled) { background: #262930; border-color: #262930; }
.kl-btn-primary:disabled { opacity: 0.6; cursor: not-allowed; }

.kl-btn-secondary {
  background: var(--surface);
  color: var(--ink);
  border: 1.5px solid var(--border);
}
.kl-btn-secondary:hover:not(:disabled) { border-color: var(--ink); background: var(--surface-tint); }

.kl-btn-gold {
  background: var(--gold);
  color: #111214;
  border: 1.5px solid var(--gold);
}
.kl-btn-gold:hover { background: #dfc98f; border-color: #dfc98f; }
.kl-btn-lg { padding: 0.82rem 1.6rem; font-size: 1rem; }

.kl-btn-outline-light {
  background: transparent;
  color: #f6f4ee;
  border: 1.5px solid rgba(255, 255, 255, 0.35);
}
.kl-btn-outline-light:hover { border-color: var(--gold); color: var(--gold); }

.kl-btn-danger {
  background: var(--accent-red);
  color: #fff;
  border: 1.5px solid var(--accent-red);
}
.kl-btn-danger:hover:not(:disabled) { background: #912018; border-color: #912018; }
.kl-btn-danger-outline {
  background: #fff;
  color: var(--accent-red);
  border: 1.5px solid #fecdca;
}
.kl-btn-danger-outline:hover { background: #fef3f2; border-color: var(--accent-red); }

.kl-btn-text-danger {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--accent-red);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0.2rem 0.35rem;
}
.kl-btn-text-danger:hover { text-decoration: underline; }

.kl-inline-msg {
  padding: 0.8rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 1.1rem;
}
.kl-inline-msg.is-error {
  background: #fef3f2;
  border: 1px solid #fecdca;
  color: #912018;
}
.kl-inline-msg.is-success {
  background: #ecfdf3;
  border: 1px solid #abefc6;
  color: #067647;
}


.kl-share-bar {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.15rem 1.3rem;
  box-shadow: var(--shadow-sm);
}
.kl-share-bar.is-compact {
  padding: 0.7rem 0.85rem;
  background: var(--surface-tint);
  border-radius: var(--radius-sm);
}
.kl-share-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  margin-bottom: 0.8rem;
}
.kl-share-label {
  font-size: 0.84rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink);
}
.kl-share-privacy {
  font-size: 0.76rem;
  color: var(--ink-subtle);
}
.kl-share-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.kl-share-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.42rem 0.78rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 650;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.14s ease, border-color 0.14s ease, color 0.14s ease;
  line-height: 1.2;
}
.kl-share-btn:hover {
  border-color: var(--ink);
  background: var(--surface);
}
.kl-share-btn.kl-share-native {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}
.kl-share-btn.kl-share-copy.is-copied {
  background: #ecfdf3;
  border-color: #067647;
  color: #067647;
}


.kl-mission-ribbon {
  margin-top: 3rem;
  background: var(--ink);
  color: #f6f4ee;
  border-radius: var(--radius);
  border-left: 5px solid var(--gold);
  padding: 1.35rem 1.55rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
}
.kl-mission-ribbon-copy {
  flex: 1 1 320px;
  min-width: 0;
}
.kl-mission-ribbon-kicker {
  display: block;
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.25rem;
}
.kl-mission-ribbon p {
  margin: 0;
  font-size: 0.96rem;
  color: #dcd9d0;
  line-height: 1.5;
}
.kl-mission-ribbon strong { color: #fff; }


.kl-safe-pill-note {
  background: #ecfdf3;
  color: var(--accent-green);
  border: 1px solid #abefc6;
}
.kl-safe-app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.35rem;
}
.kl-safe-app-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 4px solid var(--accent-green);
  border-radius: var(--radius);
  padding: 1.35rem 1.4rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-width: 0;
}
.kl-safe-app-top {
  display: flex;
  align-items: flex-start;
  gap: 0.95rem;
  min-width: 0;
}
.kl-safe-app-icon-wrap { flex-shrink: 0; }
.kl-safe-app-icon {
  width: 60px;
  height: 60px;
  border-radius: 14px;
  object-fit: cover;
  border: 1px solid rgba(17, 18, 20, 0.12);
  box-shadow: 0 2px 6px rgba(17, 18, 20, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.45rem;
  flex-shrink: 0;
}
.kl-safe-app-meta { min-width: 0; flex: 1; }
.kl-safe-app-name {
  margin: 0 0 0.2rem;
  font-size: 1.15rem;
  font-weight: 740;
  letter-spacing: -0.015em;
  line-height: 1.25;
  color: var(--ink);
  word-break: break-word;
}
.kl-safe-app-sub {
  font-size: 0.82rem;
  color: var(--ink-subtle);
}
.kl-safe-app-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.45rem;
}
.kl-safe-tag {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  background: var(--surface-tint);
  color: var(--ink-muted);
  border: 1px solid var(--border);
}
.kl-safe-seal-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.48rem 0.78rem;
  border-radius: var(--radius-sm);
  background: #ecfdf3;
  border: 1px solid #abefc6;
  color: #067647;
  font-size: 0.8rem;
  font-weight: 750;
}
.kl-safe-metrics {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem 0.9rem;
  padding: 0.85rem 0.95rem;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.kl-safe-metrics dt {
  font-size: 0.68rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-subtle);
}
.kl-safe-metrics dd {
  margin: 0.1rem 0 0;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.kl-safe-zero {
  color: var(--accent-green);
  font-weight: 700;
  font-size: 0.8rem;
}
.kl-safe-app-foot {
  margin-top: auto;
  padding-top: 0.85rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  font-size: 0.84rem;
}
.kl-safe-store-link {
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}
.kl-safe-store-link:hover { text-decoration: underline; }
.kl-safe-alert-link {
  color: var(--accent-blue);
  font-weight: 700;
  text-decoration: none;
}
.kl-safe-alert-link:hover { text-decoration: underline; }

.kl-held-disclosure {
  margin-top: 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
}
.kl-held-list {
  margin: 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.75rem;
}
.kl-held-head {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.75rem;
  align-items: baseline;
  color: var(--ink);
}
.kl-held-count { font-size: 0.78rem; color: var(--ink-subtle); }
.kl-held-reasons {
  margin: 0.3rem 0 0;
  padding-left: 1.15rem;
  color: var(--ink-muted);
  display: grid;
  gap: 0.2rem;
}


.kl-safety-callout {
  display: flex;
  align-items: flex-start;
  gap: 0.95rem;
  background: #fef3f2;
  border: 2px solid var(--accent-red);
  border-left-width: 6px;
  border-radius: var(--radius);
  padding: 1.1rem 1.25rem;
  margin-bottom: 2rem;
  color: #7a271a;
}
.kl-safety-icon {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: var(--accent-red);
  color: #fff;
  font-weight: 900;
  font-size: 1.05rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 0.1rem;
}
.kl-safety-copy strong {
  display: block;
  font-size: 1.02rem;
  color: #7a271a;
  line-height: 1.35;
}
.kl-safety-copy p {
  margin: 0.35rem 0 0;
  font-size: 0.9rem;
  color: #912018;
  line-height: 1.5;
}

.kl-tip-layout,
.kl-alerts-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr);
  gap: 1.5rem;
  align-items: start;
}
.kl-tip-form,
.kl-alerts-panel {
  min-width: 0;
}
.kl-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}
.kl-field { min-width: 0; }
.kl-field input[type="text"],
.kl-field input[type="email"],
.kl-field textarea {
  width: 100%;
  padding: 0.65rem 0.8rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--paper);
  font: inherit;
  font-size: 0.94rem;
  color: var(--ink);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.kl-field textarea { resize: vertical; min-height: 105px; }
.kl-field input:focus,
.kl-field textarea:focus,
.kl-field select:focus {
  outline: 2px solid var(--ink);
  outline-offset: 1px;
  background: var(--surface);
}
.kl-req { color: var(--accent-red); }
.kl-opt {
  text-transform: none;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--ink-subtle);
}
.kl-label-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.25rem 0.75rem;
}
.kl-field-hint {
  font-size: 0.76rem;
  color: var(--ink-subtle);
}

.kl-dropzone {
  position: relative;
  border: 2px dashed #cbc6b8;
  border-radius: var(--radius-sm);
  background: var(--paper);
  padding: 1.25rem 1rem;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.kl-dropzone:hover,
.kl-dropzone.is-dragover {
  border-color: var(--ink);
  background: var(--surface-tint);
}
.kl-dropzone.has-file { border-color: var(--accent-green); background: #f6fef9; }
.kl-dropzone-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}
.kl-dropzone-classifier criteria {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--ink);
  pointer-events: none;
}
.kl-dropzone-classifier criteria strong { display: block; font-size: 0.92rem; }
.kl-dropzone-sub {
  display: block;
  font-size: 0.8rem;
  color: var(--ink-subtle);
  margin-top: 0.15rem;
}
.kl-preview-box {
  margin-top: 0.75rem;
  padding: 0.75rem;
  background: var(--surface-tint);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}
.kl-preview-img {
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #fff;
  flex-shrink: 0;
}
.kl-preview-info {
  flex: 1 1 180px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.3rem;
  font-size: 0.82rem;
  color: var(--ink-muted);
  word-break: break-word;
}

.kl-attest-box {
  background: #fffcf5;
  border: 1.5px solid #f7b267;
  border-radius: var(--radius-sm);
  padding: 0.95rem 1.05rem;
}
.kl-attest-label {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  cursor: pointer;
  font-size: 0.9rem;
  line-height: 1.48;
  color: var(--ink);
}
.kl-attest-label input[type="checkbox"] {
  margin-top: 0.2rem;
  width: 18px;
  height: 18px;
  accent-color: var(--accent-red);
  flex-shrink: 0;
  cursor: pointer;
}

.kl-hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}


.kl-altcha-box {
  background: var(--paper);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.8rem 1rem;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.kl-altcha-box[data-state="solved"] {
  background: #f6fef9;
  border-color: #abefc6;
}
.kl-altcha-box[data-state="error"] {
  background: #fef3f2;
  border-color: #fecdca;
}
.kl-altcha-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.kl-altcha-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  flex: 1 1 220px;
  min-width: 0;
}
.kl-altcha-check {
  width: 19px;
  height: 19px;
  accent-color: var(--accent-green);
  cursor: pointer;
  flex-shrink: 0;
}
.kl-altcha-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.kl-altcha-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.25;
}
.kl-altcha-sub {
  font-size: 0.78rem;
  color: var(--ink-subtle);
  line-height: 1.35;
}
.kl-altcha-box[data-state="solved"] .kl-altcha-sub { color: var(--accent-green); font-weight: 600; }
.kl-altcha-box[data-state="error"] .kl-altcha-sub { color: var(--accent-red); font-weight: 600; }
.kl-altcha-refresh {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink-muted);
  border-radius: 999px;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  cursor: pointer;
}
.kl-altcha-refresh:hover { border-color: var(--ink); color: var(--ink); }

.kl-form-actions {
  margin-top: 1.35rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem 1.15rem;
}
.kl-form-privacy-note {
  font-size: 0.8rem;
  color: var(--ink-subtle);
}

.kl-check-list {
  margin: 0;
  padding-left: 1.15rem;
  display: grid;
  gap: 0.65rem;
  font-size: 0.9rem;
  color: var(--ink-muted);
}
.kl-check-list strong { color: var(--ink); }


.kl-receipt-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 5px solid var(--accent-green);
  border-radius: var(--radius);
  padding: clamp(1.5rem, 3vw, 2.2rem);
  box-shadow: var(--shadow-md);
  margin-bottom: 2rem;
}
.kl-receipt-eyebrow {
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-green);
  margin-bottom: 0.35rem;
}
.kl-receipt-card h2 { margin: 0 0 0.55rem; font-size: 1.65rem; letter-spacing: -0.02em; }
.kl-receipt-lead { margin: 0 0 1.25rem; color: var(--ink-muted); max-width: 65ch; }
.kl-receipt-id-box {
  display: inline-flex;
  flex-direction: column;
  gap: 0.15rem;
  background: var(--surface-tint);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1.15rem;
  margin-bottom: 1rem;
}
.kl-receipt-id-label {
  font-size: 0.7rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-subtle);
}
.kl-receipt-id-val {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--ink);
}
.kl-receipt-badge {
  display: block;
  padding: 0.55rem 0.9rem;
  border-radius: var(--radius-sm);
  background: var(--surface-tint);
  color: var(--ink-muted);
  font-size: 0.85rem;
  font-weight: 650;
  margin-bottom: 1.25rem;
}
.kl-receipt-badge.is-green {
  background: #ecfdf3;
  border: 1px solid #abefc6;
  color: #067647;
}
.kl-receipt-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}


.kl-toggle-group,
.kl-cadence-group {
  border: 0;
  margin: 0;
  padding: 0;
}
.kl-toggle-group legend,
.kl-cadence-group legend {
  font-size: 0.78rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-subtle);
  margin-bottom: 0.55rem;
}
.kl-switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 0.65rem;
  cursor: pointer;
}
.kl-switch-copy {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}
.kl-switch-copy strong { font-size: 0.94rem; color: var(--ink); }
.kl-switch-copy span { font-size: 0.82rem; color: var(--ink-muted); line-height: 1.4; }
.kl-switch {
  position: relative;
  width: 46px;
  height: 26px;
  flex-shrink: 0;
}
.kl-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}
.kl-switch-track {
  position: absolute;
  inset: 0;
  background: #cbc6b8;
  border-radius: 999px;
  transition: background 0.16s ease;
}
.kl-switch-track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.22);
  transition: transform 0.16s ease;
}
.kl-switch input:checked + .kl-switch-track { background: var(--accent-green); }
.kl-switch input:checked + .kl-switch-track::after { transform: translateX(20px); }
.kl-switch input:focus-visible + .kl-switch-track { outline: 2px solid var(--ink); outline-offset: 2px; }

.kl-account-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  border-left: 4px solid var(--gold);
}
.kl-account-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  background: #ecfdf3;
  color: var(--accent-green);
  border: 1px solid #abefc6;
  margin-bottom: 0.25rem;
}
.kl-account-email {
  font-size: 1.15rem;
  font-weight: 750;
  color: var(--ink);
  word-break: break-all;
}
.kl-account-meta { font-size: 0.82rem; color: var(--ink-subtle); }
.kl-account-actions { display: flex; flex-wrap: wrap; gap: 0.55rem; }

.kl-watched-input-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.kl-watched-input-row input { flex: 1 1 200px; min-width: 0; }
.kl-watched-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.65rem;
}
.kl-watched-empty { font-size: 0.82rem; color: var(--ink-subtle); }
.kl-watched-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--ink);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 650;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
}
.kl-watched-remove {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--gold);
  font-size: 1.05rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 0.1rem;
}
.kl-watched-suggest-wrap {
  margin-top: 0.6rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.kl-watched-suggestions { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.kl-suggest-chip {
  appearance: none;
  border: 1px dashed #bdb7a7;
  background: var(--paper);
  color: var(--ink-muted);
  border-radius: 999px;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 650;
  padding: 0.2rem 0.6rem;
  cursor: pointer;
}
.kl-suggest-chip:hover { border-color: var(--ink); color: var(--ink); }

.kl-cadence-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}
.kl-cadence-card {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.85rem 0.95rem;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.kl-cadence-card input { margin-top: 0.2rem; accent-color: var(--ink); flex-shrink: 0; }
.kl-cadence-card strong { display: block; font-size: 0.92rem; color: var(--ink); }
.kl-cadence-card span span { display: block; font-size: 0.8rem; color: var(--ink-muted); line-height: 1.38; margin-top: 0.12rem; }

.kl-sent-panel {
  background: #f6fef9;
  border: 1.5px solid #abefc6;
  border-radius: var(--radius-sm);
  padding: 1.25rem;
}

.kl-tip-receipt-list { display: grid; gap: 0.65rem; }
.kl-tip-receipt-row {
  padding: 0.7rem 0.85rem;
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.kl-tip-receipt-top {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.2rem;
}
.kl-tip-receipt-top code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.8rem;
  font-weight: 750;
  color: var(--ink);
}
.kl-tip-receipt-meta { font-size: 0.8rem; color: var(--ink-muted); }
.kl-tip-receipt-date { font-size: 0.76rem; color: var(--ink-subtle); }
.kl-status-pill {
  font-size: 0.68rem;
  font-weight: 750;
  padding: 0.12rem 0.48rem;
  border-radius: 999px;
}
.kl-status-pill.is-gold { background: #fdf8eb; color: #8f7430; border: 1px solid #e7d5a3; }
.kl-status-pill.is-green { background: #ecfdf3; color: #067647; border: 1px solid #abefc6; }
.kl-status-pill.is-blue { background: #eff8ff; color: #175cd3; border: 1px solid #b2ddff; }
.kl-status-pill.is-muted { background: #f2f4f7; color: #475467; border: 1px solid #d0d5dd; }

.kl-danger-panel { border-color: #fecdca; }
.kl-delete-confirm {
  margin-top: 0.65rem;
  padding: 0.85rem;
  background: #fef3f2;
  border: 1px solid #fecdca;
  border-radius: var(--radius-sm);
}


.kl-support-hero {
  background: var(--ink);
  color: #f6f4ee;
  border-radius: var(--radius);
  border-top: 5px solid var(--gold);
  padding: clamp(1.75rem, 4.5vw, 3rem);
  box-shadow: var(--shadow-md);
}
.kl-support-hero-inner { max-width: 820px; }
.kl-support-kicker {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}
.kl-support-hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 4.3vw, 3.1rem);
  font-weight: 780;
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: #fff;
}
.kl-support-lead {
  margin: 0 0 1.75rem;
  font-size: clamp(1.02rem, 1.7vw, 1.18rem);
  color: #dcd9d0;
  line-height: 1.58;
}
.kl-support-lead strong { color: #fff; }

.kl-support-cta-panel {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(207, 184, 124, 0.35);
  border-radius: 12px;
  padding: 1.25rem 1.35rem;
}
.kl-support-cta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.85rem 1.15rem;
}
.kl-amt-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.kl-amt-pills a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.82rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #f6f4ee;
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  transition: background 0.14s ease, border-color 0.14s ease, color 0.14s ease;
}
.kl-amt-pills a:hover,
.kl-amt-pills a.is-featured {
  border-color: var(--gold);
  background: rgba(207, 184, 124, 0.22);
  color: var(--gold);
}

.kl-memo-box {
  margin-top: 1.1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}
.kl-memo-label {
  font-size: 0.78rem;
  color: #c8c4b8;
  margin-bottom: 0.45rem;
}
.kl-memo-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.65rem;
  background: rgba(0, 0, 0, 0.34);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
}
.kl-memo-row code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.82rem;
  color: #f6e7bc;
  word-break: break-word;
  flex: 1 1 240px;
}
.kl-btn-memo {
  appearance: none;
  border: 1px solid var(--gold);
  background: rgba(207, 184, 124, 0.16);
  color: #f6e7bc;
  border-radius: 999px;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.38rem 0.88rem;
  cursor: pointer;
  flex-shrink: 0;
}
.kl-btn-memo:hover,
.kl-btn-memo.is-copied {
  background: var(--gold);
  color: #111214;
}

.kl-support-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
}
.kl-vision-card {
  position: relative;
  border-top: 3px solid var(--gold);
}
.kl-vision-num {
  display: inline-block;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--gold-deep);
  margin-bottom: 0.35rem;
}
.kl-vision-card p,
.kl-give-option p {
  margin: 0;
  color: var(--ink-muted);
  font-size: 0.93rem;
}
.kl-give-option {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.kl-give-option a { align-self: flex-start; margin-top: auto; }

@media (max-width: 860px) {
  .kl-tip-layout,
  .kl-alerts-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .kl-form-grid,
  .kl-cadence-grid,
  .kl-safe-metrics,
  .kl-safe-app-grid,
  .kl-support-cards {
    grid-template-columns: 1fr;
  }
  .kl-safety-callout {
    padding: 0.95rem 1rem;
  }
}


.kl-card-verdict-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.55rem;
}
.kl-card-verdict-row .kl-coppa-verdict-pill {
  margin-bottom: 0;
}
.kl-issue-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: #175cd3;
  background: #eff8ff;
  border: 1px solid #b2ddff;
  border-radius: 999px;
  padding: 0.22rem 0.6rem;
  text-decoration: none;
  line-height: 1.25;
}
.kl-issue-pill:hover {
  background: #175cd3;
  color: #fff;
  border-color: #175cd3;
}
.kl-card-actions {
  margin-top: auto;
  padding-top: 0.75rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.9rem;
}
.kl-share-toggle {
  margin-left: auto;
  appearance: none;
  border: 1px solid var(--border);
  background: var(--paper);
  color: var(--ink);
  border-radius: 999px;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 700;
  padding: 0.24rem 0.68rem;
  cursor: pointer;
}
.kl-share-toggle:hover {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}
.kl-card-share-slot {
  margin-top: 0.65rem;
  padding-top: 0.65rem;
  border-top: 1px dashed var(--border);
}



.as-scorecards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  margin-bottom: 1.35rem;
}
.as-store-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem 1.35rem;
  box-shadow: var(--shadow-sm);
}
.as-sc-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.75rem;
}
.as-sc-kicker {
  display: block;
  font-size: 0.71rem;
  font-weight: 760;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--gold-deep);
}
.as-sc-title {
  margin: 0.15rem 0 0;
  font-size: 1.32rem;
  font-weight: 760;
  letter-spacing: -0.02em;
}
.as-sc-score-box {
  text-align: right;
  flex-shrink: 0;
}
.as-sc-score {
  display: block;
  font-size: 1.85rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.as-sc-score small {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-subtle);
  margin-left: 2px;
}
.as-sc-score-cap {
  display: block;
  margin-top: 0.22rem;
  font-size: 0.72rem;
  color: var(--ink-subtle);
}
.as-bar-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: var(--ink-muted);
  margin-bottom: 0.38rem;
}
.as-health-bar {
  height: 13px;
  border-radius: 999px;
  overflow: hidden;
  display: flex;
  background: #e6e3da;
  border: 1px solid rgba(17, 18, 20, 0.08);
  margin-bottom: 0.9rem;
}
.as-bar-seg {
  height: 100%;
  transition: width 0.25s ease;
}
.as-sc-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.6rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--border);
}
.as-kpi-val {
  display: block;
  font-size: 1.15rem;
  font-weight: 780;
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
  color: var(--ink);
}
.as-kpi-val.is-green { color: var(--accent-green); }
.as-kpi-val.is-red { color: var(--accent-red); }
.as-kpi-val.is-amber { color: #b54708; }
.as-kpi-lbl {
  display: block;
  font-size: 0.72rem;
  color: var(--ink-subtle);
  margin-top: 0.1rem;
}


.as-controls {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.95rem 1.15rem;
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.as-controls-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.85rem;
}
.as-ctrl-group {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.as-controls-row .kl-net-search {
  margin-left: auto;
  min-width: 175px;
  max-width: 215px;
  padding: 0.36rem 0.78rem;
  font-size: 0.82rem;
}
.as-legend-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  padding-top: 0.65rem;
  border-top: 1px solid var(--border);
}
.as-swatch {
  width: 11px;
  height: 11px;
  border-radius: 3px;
  border: 1.5px solid transparent;
  display: inline-block;
  flex-shrink: 0;
}


.as-stage-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
}
.as-stage-grid.is-single {
  grid-template-columns: 1fr;
}
.as-store-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.9rem 0.95rem 0.95rem;
  box-shadow: var(--shadow-sm);
  min-width: 0;
}
.as-panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}
.as-panel-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 760;
  letter-spacing: -0.015em;
}
.as-panel-sub {
  display: block;
  font-size: 0.76rem;
  color: var(--ink-subtle);
}
.as-panel-count {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--ink-muted);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.as-treemap {
  position: relative;
  width: 100%;
  height: 620px;
  background: #f5f3ec;
  border-radius: 10px;
  overflow: hidden;
}
.as-empty {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-subtle);
  font-size: 0.92rem;
}


.as-tile {
  position: absolute;
  appearance: none;
  border: 1px solid transparent;
  padding: 0;
  margin: 0;
  overflow: hidden;
  text-align: left;
  font: inherit;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  transition: transform 0.1s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}
.as-tile:hover,
.as-tile:focus-visible {
  z-index: 15;
  box-shadow: 0 0 0 2px #111214, 0 8px 20px rgba(17, 18, 20, 0.22);
  outline: none;
}
.as-tile.has-bad-ad {
  border-width: 1.5px;
  box-shadow: inset 0 0 0 1px rgba(180, 35, 24, 0.35);
}
.as-tile.is-lg {
  padding: 6px 7px;
  gap: 3px;
}
.as-tile.is-md {
  padding: 4px 5px;
  gap: 2px;
}
.as-tile.is-sm {
  align-items: center;
  justify-content: center;
}
.as-tile-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 4px;
  width: 100%;
}
.as-tile-ico {
  border-radius: 7px;
  object-fit: cover;
  flex-shrink: 0;
  background: #fff;
  box-shadow: 0 1px 3px rgba(17, 18, 20, 0.18);
  display: block;
}
.as-tile-ico.is-lg { width: 30px; height: 30px; border-radius: 7px; }
.as-tile-ico.is-md { width: 19px; height: 19px; border-radius: 5px; }
.as-tile-ico.is-sm { width: 20px; height: 20px; border-radius: 5px; }
.as-tile-mono {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.72rem;
  color: #111214;
  background: rgba(255, 255, 255, 0.78);
}
.as-tile-score {
  color: #fff;
  font-size: 0.66rem;
  font-weight: 800;
  line-height: 1;
  padding: 3px 5px;
  border-radius: 5px;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.as-tile-score.is-compact {
  font-size: 0.61rem;
  padding: 2px 4px;
}
.as-tile-name {
  font-size: 0.76rem;
  font-weight: 760;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
}
.as-tile-name.is-clamp2 {
  font-size: 0.68rem;
  font-weight: 730;
  white-space: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.16;
  margin-top: 2px;
}
.as-tile.is-md .as-tile-name { font-size: 0.68rem; font-weight: 720; }
.as-tile-md-row {
  display: flex;
  align-items: center;
  gap: 4px;
  width: 100%;
  min-width: 0;
}
.as-tile-meta {
  font-size: 0.66rem;
  font-weight: 600;
  opacity: 0.82;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
  font-variant-numeric: tabular-nums;
}
.as-tile-sm-abbr {
  font-size: 0.62rem;
  font-weight: 750;
  opacity: 0.75;
}


.as-hover-card {
  position: fixed;
  z-index: 120;
  width: 315px;
  background: #141518;
  color: #f6f4ee;
  border: 1px solid rgba(207, 184, 124, 0.45);
  border-radius: 13px;
  padding: 0.85rem 0.95rem;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.36);
  pointer-events: none;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.1s ease, transform 0.1s ease;
}
.as-hover-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.as-hc-head {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.65rem;
}
.as-hc-ico {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  object-fit: cover;
  flex-shrink: 0;
  background: #fff;
}
.as-hc-title-wrap { min-width: 0; flex: 1; }
.as-hc-title {
  font-size: 0.9rem;
  font-weight: 760;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.as-hc-sub {
  font-size: 0.72rem;
  color: #b7b4aa;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.as-hc-pill {
  color: #fff;
  font-size: 0.85rem;
  font-weight: 820;
  padding: 0.25rem 0.48rem;
  border-radius: 8px;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.as-hc-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
  padding: 0.5rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 0.55rem;
}
.as-hc-metrics span {
  display: block;
  font-size: 0.64rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #a6a399;
}
.as-hc-metrics strong {
  display: block;
  font-size: 0.8rem;
  color: #fff;
  font-variant-numeric: tabular-nums;
}
.as-hc-alert { font-size: 0.77rem; color: #fda29b; font-weight: 650; }
.as-hc-flag { font-size: 0.77rem; color: #fedf89; font-weight: 620; }
.as-hc-safe { font-size: 0.77rem; color: #6ce9a6; font-weight: 650; }
.as-hc-note { font-size: 0.76rem; color: #c7c4ba; }
.as-hc-hint {
  margin-top: 0.45rem;
  font-size: 0.68rem;
  color: var(--gold);
  font-weight: 650;
}


.as-dr-head-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.as-dr-ico {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--border);
  background: #fff;
}
.as-dr-store {
  font-size: 0.7rem;
  font-weight: 760;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gold-deep);
}
.as-dr-title {
  margin: 0.1rem 0 0;
  font-size: 1.16rem;
  font-weight: 760;
  line-height: 1.2;
}
.as-dr-dev {
  font-size: 0.8rem;
  color: var(--ink-subtle);
  margin-top: 0.1rem;
}
.as-dr-status-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.62rem 0.82rem;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 0.84rem;
  margin-bottom: 1rem;
}
.as-dr-score-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin-bottom: 1.15rem;
}
.as-dr-score-tile {
  background: var(--surface-tint);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.65rem 0.72rem;
  text-align: center;
}
.as-dr-score-tile span {
  display: block;
  font-size: 0.68rem;
  font-weight: 740;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-subtle);
}
.as-dr-score-tile strong {
  display: block;
  font-size: 1.55rem;
  font-weight: 820;
  line-height: 1.15;
  margin: 0.15rem 0;
  font-variant-numeric: tabular-nums;
}
.as-dr-score-tile small {
  display: block;
  font-size: 0.71rem;
  color: var(--ink-muted);
}
.as-dr-section {
  margin-bottom: 1.1rem;
}
.as-dr-section h4 {
  margin: 0 0 0.5rem;
  font-size: 0.74rem;
  font-weight: 780;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-subtle);
}
.as-dr-kv {
  margin: 0;
  display: grid;
  gap: 0.45rem;
  background: #faf9f6;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
}
.as-dr-kv div {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.84rem;
}
.as-dr-kv dt { color: var(--ink-subtle); font-weight: 600; flex-shrink: 0; }
.as-dr-kv dd { margin: 0; text-align: right; color: var(--ink); font-weight: 620; word-break: break-word; }
.as-dr-kv code { font-size: 0.76rem; }
.as-dr-card-list { display: grid; gap: 0.55rem; }
.as-dr-bad-item {
  background: #fef3f2;
  border: 1px solid #fecdca;
  border-radius: 10px;
  padding: 0.65rem 0.8rem;
  font-size: 0.86rem;
}
.as-dr-tag {
  font-size: 0.74rem;
  font-weight: 680;
  color: #912018;
  margin-left: 0.3rem;
}
.as-dr-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 0.35rem;
}
.as-dr-links a {
  font-size: 0.79rem;
  font-weight: 720;
  color: #b42318;
  text-decoration: none;
}
.as-dr-links a:hover { text-decoration: underline; }
.as-dr-list {
  margin: 0;
  padding-left: 1.15rem;
  display: grid;
  gap: 0.35rem;
  font-size: 0.86rem;
  color: var(--ink);
}
.as-dr-safe-box {
  background: #ecfdf3;
  border: 1px solid #a6f4c5;
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  font-size: 0.86rem;
  color: #054f31;
}
.as-dr-safe-box a { font-weight: 720; color: #067647; }


.as-dir-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-bottom: 0.9rem;
}
.as-select {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink);
  border-radius: 8px;
  padding: 0.42rem 0.75rem;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
}
.as-dir-row {
  cursor: pointer;
  transition: background 0.12s ease;
}
.as-dir-row:hover { background: #faf8f2; }
.as-dir-app {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}
.as-dir-ico {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(17, 18, 20, 0.1);
  background: #fff;
}
.as-dir-app strong { display: block; font-size: 0.88rem; line-height: 1.2; }
.as-dir-app span { display: block; font-size: 0.74rem; color: var(--ink-subtle); }
.as-store-tag {
  font-size: 0.74rem;
  font-weight: 700;
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  white-space: nowrap;
}
.as-store-tag.is-android { background: #ecfdf3; color: #065f46; border: 1px solid #a6f4c5; }
.as-store-tag.is-ios { background: #eff8ff; color: #1849a9; border: 1px solid #b2ddff; }
.as-dir-chip {
  display: inline-block;
  min-width: 34px;
  text-align: center;
  font-size: 0.78rem;
  font-weight: 780;
  padding: 0.16rem 0.45rem;
  border-radius: 7px;
  border: 1px solid transparent;
  font-variant-numeric: tabular-nums;
}
.as-dir-chip.is-grey {
  background: #f0eee7;
  color: var(--ink-subtle);
  border-color: var(--border);
}
.as-dir-more-wrap {
  margin-top: 1rem;
  text-align: center;
}

@media (max-width: 980px) {
  .as-scorecards,
  .as-stage-grid { grid-template-columns: 1fr; }
  .as-controls-row .kl-net-search { margin-left: 0; width: 100%; }
}
@media (max-width: 680px) {
  .as-sc-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}



@property --kl-aurora-angle {
  syntax: "<angle>";
  initial-value: 0deg;
  inherits: false;
}

@keyframes kl-aurora-spin {
  to { --kl-aurora-angle: 360deg; }
}

@keyframes kl-shimmer-sweep {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

body.kl-edit-active {
  padding-bottom: 92px;
}

.kl-ed-deleted {
  display: none !important;
}

.kl-ed-deleting {
  opacity: 0 !important;
  transform: scale(0.985) !important;
  transition: opacity 0.17s ease, transform 0.17s ease !important;
}


.kl-ed-fab {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 900;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.48rem 0.92rem;
  border-radius: 999px;
  border: 1px solid rgba(17, 18, 20, 0.14);
  background: rgba(255, 255, 255, 0.84);
  backdrop-filter: blur(18px) saturate(180%);
  -webkit-backdrop-filter: blur(18px) saturate(180%);
  color: var(--ink);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  box-shadow: 0 6px 22px rgba(17, 18, 20, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  cursor: pointer;
  opacity: 0.82;
  transition: opacity 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}
.kl-ed-fab[hidden] { display: none !important; }
.kl-ed-fab:hover {
  opacity: 1;
  transform: translateY(-1px);
  border-color: rgba(147, 51, 234, 0.36);
  box-shadow: 0 10px 28px rgba(147, 51, 234, 0.18), 0 4px 12px rgba(17, 18, 20, 0.1);
}
.kl-ed-fab-spark,
.kl-ed-aurora-dot {
  background: linear-gradient(135deg, #ec4899, #8b5cf6, #3b82f6, #10b981);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 0.96rem;
  line-height: 1;
}


.kl-ed-section-box {
  position: relative;
  border-radius: 14px;
  outline: 1.5px dashed rgba(17, 18, 20, 0.16);
  outline-offset: 6px;
  transition: outline-color 0.16s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.kl-ed-section-box:hover,
.kl-ed-section-box.kl-ed-editing,
.kl-ed-section-box.kl-ed-previewing {
  outline: 1.5px solid rgba(139, 92, 246, 0.55);
  box-shadow: 0 0 0 5px rgba(139, 92, 246, 0.08);
}


.kl-ed-section-box.kl-ed-shimmering {
  outline: 2px solid transparent;
  box-shadow:
    0 0 0 3px rgba(192, 132, 252, 0.42),
    0 0 28px rgba(96, 165, 250, 0.34),
    0 0 48px rgba(244, 114, 182, 0.22);
  background-image: linear-gradient(
    110deg,
    rgba(255, 255, 255, 0) 20%,
    rgba(192, 132, 252, 0.16) 40%,
    rgba(96, 165, 250, 0.18) 52%,
    rgba(244, 114, 182, 0.14) 64%,
    rgba(255, 255, 255, 0) 82%
  );
  background-size: 220% 100%;
  animation: kl-shimmer-sweep 1.25s linear infinite;
}


.kl-ed-sec-bar {
  position: absolute;
  top: -24px;
  right: 8px;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.24rem 0.34rem 0.24rem 0.65rem;
  border-radius: 999px;
  background: rgba(18, 20, 26, 0.88);
  backdrop-filter: blur(14px) saturate(170%);
  -webkit-backdrop-filter: blur(14px) saturate(170%);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.24);
  opacity: 0.82;
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.kl-ed-section-box:hover > .kl-ed-sec-bar,
.kl-ed-section-box.kl-ed-editing > .kl-ed-sec-bar,
.kl-ed-section-box.kl-ed-previewing > .kl-ed-sec-bar {
  opacity: 1;
  transform: translateY(-1px);
}
.kl-ed-sec-name {
  font-size: 0.7rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.78);
  max-width: 170px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.kl-ed-sec-btns {
  display: inline-flex;
  align-items: center;
  gap: 0.22rem;
}
.kl-ed-pill-btn {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.1);
  color: #f8fafc;
  border-radius: 999px;
  padding: 0.22rem 0.6rem;
  font: inherit;
  font-size: 0.73rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.14s ease, border-color 0.14s ease, transform 0.12s ease;
}
.kl-ed-pill-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.22);
}
.kl-ed-pill-btn:disabled {
  opacity: 0.34;
  cursor: not-allowed;
}
.kl-ed-pill-btn.is-move {
  padding: 0.22rem 0.48rem;
  font-size: 0.8rem;
  line-height: 1.05;
}
.kl-ed-section-box.kl-ed-moved {
  outline: 2px solid rgba(59, 130, 246, 0.78);
  box-shadow: 0 0 0 6px rgba(59, 130, 246, 0.16);
}
.kl-ed-pill-btn.is-concise {
  background: linear-gradient(135deg, rgba(236, 72, 153, 0.86), rgba(139, 92, 246, 0.92), rgba(59, 130, 246, 0.88));
  border-color: rgba(255, 255, 255, 0.3);
  color: #fff;
}
.kl-ed-pill-btn.is-concise:hover {
  filter: brightness(1.08);
}
.kl-ed-pill-btn.is-delete:hover {
  background: #dc2626;
  border-color: #ef4444;
  color: #fff;
}


.kl-ed-review-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem 0.9rem;
  padding: 0.55rem 0.85rem;
  margin-bottom: 0.65rem;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(250, 245, 255, 0.96), rgba(239, 246, 255, 0.96));
  border: 1px solid rgba(139, 92, 246, 0.34);
  box-shadow: 0 8px 22px rgba(139, 92, 246, 0.12);
}
.kl-ed-review-meta {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
  color: var(--ink);
}
.kl-ed-word-delta {
  font-size: 0.76rem;
  font-weight: 700;
  color: #6d28d9;
  background: rgba(139, 92, 246, 0.12);
  padding: 0.14rem 0.5rem;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}
.kl-ed-review-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.32rem;
}
.kl-ed-rv-btn {
  appearance: none;
  border: 1px solid rgba(17, 18, 20, 0.14);
  background: #fff;
  color: var(--ink);
  border-radius: 999px;
  padding: 0.28rem 0.68rem;
  font: inherit;
  font-size: 0.77rem;
  font-weight: 700;
  cursor: pointer;
}
.kl-ed-rv-btn:hover { background: #f3f4f6; }
.kl-ed-rv-btn.is-current {
  border-color: #8b5cf6;
  color: #6d28d9;
  background: #f5f3ff;
}
.kl-ed-rv-btn.is-apply {
  background: linear-gradient(135deg, #111827, #312e81);
  border-color: transparent;
  color: #fff;
}
.kl-ed-rv-btn.is-apply:hover { filter: brightness(1.12); }
.kl-ed-preview-highlight {
  background: rgba(139, 92, 246, 0.08);
  border-radius: 8px;
  padding: 0.35rem 0.5rem;
  transition: background 0.2s ease;
}


.kl-ed-editor-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.42rem 0.7rem;
  margin-bottom: 0.5rem;
  border-radius: 10px;
  background: rgba(18, 20, 26, 0.92);
  color: #fff;
  font-size: 0.78rem;
}
.kl-ed-editor-badge {
  font-weight: 700;
  color: #e9d5ff;
}
.kl-ed-editor-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.28rem;
}
.kl-ed-mini-btn {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-radius: 7px;
  padding: 0.22rem 0.55rem;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 650;
  cursor: pointer;
}
.kl-ed-mini-btn:hover { background: rgba(255, 255, 255, 0.2); }
.kl-ed-mini-btn.is-aurora {
  background: linear-gradient(135deg, #ec4899, #8b5cf6, #3b82f6);
  border-color: transparent;
}
.kl-ed-mini-btn.is-done {
  background: #10b981;
  border-color: transparent;
  color: #052e16;
  font-weight: 800;
}
.kl-ed-tiptap-host .ProseMirror {
  outline: 2px solid #8b5cf6;
  outline-offset: 4px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--ink);
  padding: 0.45rem 0.65rem;
  min-height: 2.2em;
}
.kl-ed-tiptap-host .ProseMirror p:first-child { margin-top: 0; }
.kl-ed-tiptap-host .ProseMirror p:last-child { margin-bottom: 0; }

.kl-ed-bubble {
  display: inline-flex;
  align-items: center;
  gap: 0.18rem;
  padding: 0.24rem 0.34rem;
  border-radius: 999px;
  background: rgba(17, 19, 24, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.32);
  z-index: 980;
}
.kl-ed-bubble button {
  appearance: none;
  border: 0;
  background: transparent;
  color: #f8fafc;
  border-radius: 999px;
  padding: 0.24rem 0.56rem;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
}
.kl-ed-bubble button:hover { background: rgba(255, 255, 255, 0.15); }
.kl-ed-bubble button.is-aurora {
  background: linear-gradient(135deg, #ec4899, #8b5cf6, #3b82f6);
  color: #fff;
}
.kl-ed-bubble-sep {
  width: 1px;
  height: 16px;
  background: rgba(255, 255, 255, 0.2);
  margin: 0 0.14rem;
}


.kl-ed-dock {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  z-index: 950;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 0.68rem 0.5rem 0.95rem;
  border-radius: 999px;
  background: rgba(17, 19, 25, 0.88);
  backdrop-filter: blur(22px) saturate(185%);
  -webkit-backdrop-filter: blur(22px) saturate(185%);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  color: #f8fafc;
  max-width: calc(100vw - 24px);
}
.kl-ed-dock[hidden] { display: none; }
.kl-ed-dock-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  font-size: 0.83rem;
}
.kl-ed-change-pill {
  font-size: 0.7rem;
  font-weight: 750;
  padding: 0.14rem 0.5rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
}
.kl-ed-change-pill.is-dirty {
  background: rgba(251, 191, 36, 0.22);
  color: #fde68a;
}
.kl-ed-dock-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.34rem;
}
.kl-ed-dock-btn {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.1);
  color: #f8fafc;
  border-radius: 999px;
  padding: 0.36rem 0.78rem;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}
.kl-ed-dock-btn:hover:not(:disabled) { background: rgba(255, 255, 255, 0.2); }
.kl-ed-dock-btn:disabled { opacity: 0.42; cursor: not-allowed; }
.kl-ed-dock-btn.is-primary {
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  border-color: rgba(255, 255, 255, 0.24);
  color: #fff;
}
.kl-ed-dock-btn.is-primary.is-pulsing {
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.36);
}
.kl-ed-dock-btn.is-done {
  background: rgba(255, 255, 255, 0.92);
  color: #111827;
  border-color: transparent;
}


.kl-ed-restore-wrap { position: relative; }
.kl-ed-deleted-menu {
  position: absolute;
  bottom: calc(100% + 12px);
  right: 0;
  min-width: 260px;
  max-width: 340px;
  background: rgba(22, 24, 31, 0.96);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;
  padding: 0.6rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.4);
  color: #f8fafc;
}
.kl-ed-deleted-menu[hidden] { display: none; }
.kl-ed-del-head {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #94a3b8;
  padding: 0.25rem 0.4rem 0.45rem;
}
.kl-ed-del-empty {
  font-size: 0.82rem;
  color: #cbd5e1;
  padding: 0.5rem 0.45rem;
}
.kl-ed-del-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.42rem 0.45rem;
  border-radius: 8px;
  font-size: 0.82rem;
}
.kl-ed-del-row:hover { background: rgba(255, 255, 255, 0.08); }
.kl-ed-del-row button {
  appearance: none;
  border: 1px solid rgba(52, 211, 153, 0.45);
  background: rgba(16, 185, 129, 0.18);
  color: #6ee7b7;
  border-radius: 999px;
  padding: 0.2rem 0.62rem;
  font: inherit;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
}


.kl-ed-modal {
  position: fixed;
  inset: 0;
  z-index: 990;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.kl-ed-modal[hidden] { display: none; }
.kl-ed-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.46);
  backdrop-filter: blur(8px);
}
.kl-ed-modal-sheet {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 400px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(22px) saturate(180%);
  border: 1px solid rgba(17, 18, 20, 0.12);
  border-radius: 20px;
  padding: 1.6rem;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
  text-align: center;
}
.kl-ed-modal-icon {
  font-size: 1.8rem;
  line-height: 1;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, #ec4899, #8b5cf6, #3b82f6, #10b981);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.kl-ed-modal-sheet h2 {
  margin: 0 0 0.4rem;
  font-size: 1.24rem;
  font-weight: 780;
  letter-spacing: -0.02em;
}
.kl-ed-modal-sheet p {
  margin: 0 0 1.1rem;
  font-size: 0.87rem;
  color: var(--ink-muted);
  line-height: 1.48;
}
.kl-ed-pass-input {
  width: 100%;
  padding: 0.68rem 0.9rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #fff;
  font: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  margin-bottom: 0.7rem;
}
.kl-ed-pass-input:focus {
  outline: 2px solid #8b5cf6;
  outline-offset: 1px;
}
.kl-ed-auth-err {
  font-size: 0.82rem;
  font-weight: 650;
  color: var(--accent-red);
  margin-bottom: 0.75rem;
}
.kl-ed-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.55rem;
  margin-top: 0.4rem;
}
.kl-ed-modal-cancel,
.kl-ed-modal-submit {
  appearance: none;
  border-radius: 999px;
  padding: 0.55rem 1.05rem;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 700;
  cursor: pointer;
}
.kl-ed-modal-cancel {
  border: 1px solid var(--border);
  background: #fff;
  color: var(--ink-muted);
}
.kl-ed-modal-submit {
  border: 0;
  background: linear-gradient(135deg, #111827, #4f46e5);
  color: #fff;
}


.kl-ed-toast {
  position: fixed;
  top: 72px;
  left: 50%;
  transform: translate(-50%, -14px);
  z-index: 995;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.58rem 1rem;
  border-radius: 999px;
  background: rgba(17, 19, 25, 0.92);
  backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #f8fafc;
  font-size: 0.84rem;
  font-weight: 620;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.kl-ed-toast.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0);
}
.kl-ed-toast-btn {
  appearance: none;
  border: 0;
  background: rgba(255, 255, 255, 0.18);
  color: #fde68a;
  border-radius: 999px;
  padding: 0.2rem 0.65rem;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 750;
  cursor: pointer;
}
.kl-ed-toast-btn:hover { background: rgba(255, 255, 255, 0.28); }

@media (max-width: 680px) {
  .kl-ed-dock {
    border-radius: 18px;
    padding: 0.55rem 0.7rem;
    justify-content: center;
  }
  .kl-ed-sec-name { display: none; }
}
