.integration-main {
  max-width: 1320px;
  padding-top: 34px;
}

.detail-breadcrumb {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  color: #72797d;
  font-size: 11px;
}

.detail-breadcrumb a { color: #c8cbc9; text-decoration: none; }
.detail-breadcrumb a:hover { color: var(--orange); }
.detail-breadcrumb b { color: var(--orange); }

.detail-hero {
  position: relative;
  min-height: 360px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: clamp(28px, 5vw, 76px);
  align-items: stretch;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: clamp(30px, 5vw, 68px);
  background:
    linear-gradient(110deg, rgba(238, 135, 55, .14), transparent 45%),
    repeating-linear-gradient(90deg, transparent 0, transparent 79px, rgba(255,255,255,.025) 80px),
    #151a1d;
}

.detail-hero::after {
  content: attr(data-platform-code);
  position: absolute;
  direction: ltr;
  left: 34px;
  bottom: -34px;
  color: rgba(255, 255, 255, .025);
  font: 900 clamp(90px, 14vw, 190px)/1 "Segoe UI", sans-serif;
  letter-spacing: -.08em;
  pointer-events: none;
}

.detail-hero-copy { position: relative; z-index: 1; align-self: center; }
.detail-hero h1 {
  max-width: 900px;
  margin: 0 0 20px;
  font-size: clamp(42px, 6vw, 82px);
  line-height: .98;
  letter-spacing: -.055em;
}

.detail-lead {
  max-width: 760px;
  margin: 0;
  color: #b4b5b1;
  font-size: clamp(15px, 1.5vw, 20px);
}

.signal-console {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 230px;
  padding: 28px;
  border: 1px solid #323a3f;
  border-radius: 14px;
  background: rgba(10, 13, 15, .76);
  text-align: center;
}

.signal-orbit {
  position: relative;
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  border: 1px solid #394147;
  border-radius: 50%;
}

.signal-orbit::before, .signal-orbit::after {
  content: "";
  position: absolute;
  inset: 9px;
  border: 1px dashed #394147;
  border-radius: 50%;
}

.signal-orbit::after { inset: 22px; border-style: solid; }
.signal-orbit i { width: 12px; height: 12px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 24px var(--amber); }
.signal-orbit span { position: absolute; inset: 4px; border-top: 2px solid var(--orange); border-radius: 50%; animation: signal-spin 3s linear infinite; }
.signal-console small { color: #747b7f; font-size: 9px; letter-spacing: .12em; }
.signal-console b { margin: 4px 0 10px; font-size: 18px; color: var(--amber); }
.signal-console time { color: #7f8689; font-size: 10px; }
.signal-console button { margin-top: 16px; padding: 7px 12px; border: 1px solid #3a4247; border-radius: 6px; background: transparent; color: #ddd; font: inherit; font-size: 10px; cursor: pointer; }
.signal-console button:hover { border-color: var(--orange); color: var(--orange); }
.signal-console button:disabled { opacity: .45; cursor: wait; }
.detail-hero[data-detail-state="live"] .signal-orbit i { background: var(--green); box-shadow: 0 0 24px var(--green); }
.detail-hero[data-detail-state="live"] .signal-console b { color: var(--green); }
.detail-hero[data-detail-state="ignored"] .signal-orbit i { background: #7c8386; box-shadow: none; }
.detail-hero[data-detail-state="ignored"] .signal-console b { color: #a4aaad; }
.detail-hero[data-detail-state="error"] .signal-orbit i { background: var(--red); box-shadow: 0 0 24px var(--red); }
.detail-hero[data-detail-state="error"] .signal-console b { color: var(--red); }

.detail-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 12px 0 16px;
}

.detail-kpis article {
  min-height: 150px;
  display: flex;
  flex-direction: column;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #161a1d;
}

.detail-kpis span { color: #9da09d; font-size: 11px; }
.detail-kpis b { margin: auto 0 4px; color: var(--orange); font-size: clamp(29px, 3vw, 45px); line-height: 1; direction: ltr; text-align: right; }
.detail-kpis small { color: #686f73; font-size: 9px; }
.detail-kpis article.is-empty b { color: #555d61; }

.detail-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.detail-panel {
  min-height: 330px;
  padding: clamp(24px, 3vw, 38px);
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
}

.detail-panel h2, .live-report-panel h2, .detail-actions h2 { margin: 0; font-size: clamp(27px, 3vw, 42px); line-height: 1.1; }
.detail-panel ul { list-style: none; margin: 28px 0 0; padding: 0; }
.detail-panel li { position: relative; padding: 15px 36px 15px 0; border-bottom: 1px solid var(--line); color: #b8bab6; font-size: 13px; }
.detail-panel li:last-child { border: 0; }
.detail-panel li::before { content: "✓"; position: absolute; right: 0; top: 14px; width: 22px; height: 22px; display: grid; place-items: center; border: 1px solid rgba(85, 194, 139, .38); border-radius: 50%; color: var(--green); font-size: 10px; }
.management-panel { background: linear-gradient(145deg, rgba(238,135,55,.07), transparent 45%), var(--panel); }
.management-panel li::before { content: "←"; border-color: rgba(238,135,55,.42); color: var(--orange); }

.live-report-panel {
  position: relative;
  overflow: hidden;
  padding: clamp(24px, 3.5vw, 46px);
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #111517;
}

.live-report-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 34px; }
.report-freshness { display: grid; grid-template-columns: auto auto; align-items: center; gap: 0 8px; color: var(--green); font-size: 10px; }
.report-freshness i { grid-row: 1 / 3; width: 8px; height: 8px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 5px rgba(85,194,139,.09); }
.report-freshness small { color: #71787b; font-size: 9px; }
.data-rail { height: 46px; display: flex; align-items: flex-end; gap: 5px; margin-bottom: 18px; direction: ltr; border-bottom: 1px solid #2b3236; }
.data-rail i { flex: 1; height: var(--rail-height, 35%); background: linear-gradient(to top, rgba(238,135,55,.12), var(--orange)); opacity: .72; transform-origin: bottom; animation: rail-in .65s ease both; }
.data-rail i:nth-child(1) { --rail-height: 22%; animation-delay: .04s; }
.data-rail i:nth-child(2) { --rail-height: 48%; animation-delay: .08s; }
.data-rail i:nth-child(3) { --rail-height: 35%; animation-delay: .12s; }
.data-rail i:nth-child(4) { --rail-height: 72%; animation-delay: .16s; }
.data-rail i:nth-child(5) { --rail-height: 58%; animation-delay: .2s; }
.data-rail i:nth-child(6) { --rail-height: 92%; animation-delay: .24s; }

.report-rows { border-top: 1px solid var(--line); }
.report-row { min-height: 72px; display: grid; grid-template-columns: 1.25fr .8fr 1fr auto; gap: 18px; align-items: center; border-bottom: 1px solid var(--line); }
.report-row span { color: #d5d6d3; font-size: 13px; }
.report-row b { color: var(--orange); font: 700 22px/1 Consolas, "Segoe UI", sans-serif; direction: ltr; text-align: right; }
.report-row small { color: #697074; font-size: 9px; }
.report-row em { justify-self: end; padding: 5px 8px; border: 1px solid rgba(85,194,139,.3); border-radius: 99px; color: var(--green); font-style: normal; font-size: 9px; }
.report-row.is-empty em { color: var(--amber); border-color: rgba(231,182,84,.3); }
.report-row.is-empty b { color: #656d71; }
.report-note { margin: 20px 0 0; color: #767d80; font-size: 10px; }

.detail-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  align-items: end;
  margin-top: 16px;
  padding: clamp(28px, 4vw, 54px);
  border-radius: 16px;
  background: linear-gradient(135deg, #ee8737, #c96324);
  color: #151719;
}

.detail-actions .eyebrow { color: #52270c; }
.detail-actions p:not(.eyebrow) { max-width: 720px; margin: 13px 0 0; }
.detail-actions>div:last-child { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.detail-actions a { padding: 12px 16px; border: 1px solid rgba(21,23,25,.35); border-radius: 6px; color: #151719; text-decoration: none; font-size: 11px; font-weight: 900; }
.detail-actions .primary-action { border-color: #151719; background: #151719; color: #fff; }
.detail-actions [hidden] { display: none; }

footer a { color: var(--orange); text-decoration: none; }

@keyframes signal-spin { to { transform: rotate(360deg); } }
@keyframes rail-in { from { transform: scaleY(0); opacity: 0; } }

@media (max-width: 900px) {
  .detail-hero { grid-template-columns: 1fr; }
  .signal-console { min-height: 190px; }
  .detail-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .detail-columns { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .integration-main { padding-top: 24px; }
  .detail-hero { padding: 28px 22px; }
  .detail-hero h1 { font-size: 42px; }
  .detail-kpis { grid-template-columns: 1fr; }
  .report-row { grid-template-columns: 1fr auto; gap: 5px 14px; padding: 14px 0; }
  .report-row small { grid-column: 1; }
  .report-row em { grid-column: 2; grid-row: 1 / 3; }
  .live-report-head, .detail-actions { align-items: flex-start; grid-template-columns: 1fr; }
  .live-report-head { flex-direction: column; }
  .detail-actions>div:last-child { justify-content: stretch; flex-direction: column; }
  .detail-actions a { text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  .signal-orbit span, .data-rail i { animation: none; }
}
