.ip-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.62fr);
  align-items: center;
  gap: clamp(34px, 7vw, 96px);
  position: relative;
}

.ip-hero-copy {
  min-width: 0;
}

.ip-hero-copy .kicker {
  margin-bottom: 22px;
}

.ip-hero-copy h1 {
  margin-bottom: 24px;
}

.ip-hero-copy .lead {
  margin-bottom: 0;
}

.ip-hero-mark {
  min-width: 0;
  padding: clamp(18px, 3vw, 32px);
  position: relative;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xs);
  background:
    repeating-linear-gradient(8deg, transparent 0 9px, var(--color-grain) 9px 10px),
    var(--color-panel);
  box-shadow: var(--shadow-card);
}

.ip-hero-mark::before {
  position: absolute;
  inset: 10px -9px -9px 10px;
  z-index: -1;
  content: "";
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xs);
  background: var(--color-panel-secondary);
}

.ip-hero-mark svg {
  width: 100%;
  height: auto;
}

.ip-hero-mark > span {
  display: block;
  margin-top: 12px;
  color: var(--color-text-muted);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-align: right;
}

.ip-mark-grid {
  fill: none;
  stroke: var(--color-border-soft);
  stroke-width: 1;
}

.ip-mark-route {
  fill: none;
  stroke: var(--color-accent);
  stroke-width: 5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ip-mark-node {
  stroke: var(--color-panel);
  stroke-width: 5;
}

.ip-mark-node-start {
  fill: var(--color-warning);
}

.ip-mark-node-mid {
  fill: var(--color-accent);
}

.ip-mark-node-end {
  fill: var(--color-success);
}

.lookup-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(260px, 0.65fr);
  align-items: stretch;
  gap: clamp(22px, 4vw, 54px);
}

.lookup-panel {
  min-width: 0;
  padding: clamp(24px, 4vw, 48px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xs);
  background:
    linear-gradient(145deg, var(--color-paper-glow), transparent),
    var(--color-panel);
  box-shadow: var(--shadow-device);
}

.lookup-heading {
  margin-bottom: 18px;
  padding-bottom: 22px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--color-border);
}

.lookup-heading h2 {
  margin-bottom: 0;
  font-size: clamp(28px, 3.5vw, 42px);
}

.lookup-eyebrow,
.lookup-aside-label {
  display: block;
  margin-bottom: 7px;
  color: var(--color-accent-dark);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.11em;
}

.lookup-state {
  max-width: 100%;
  padding: 7px 10px;
  overflow: hidden;
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  background: var(--color-panel);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lookup-state.is-ready {
  color: var(--color-success);
  border-color: var(--color-success);
  background: var(--color-success-soft);
}

.lookup-state.is-error {
  color: var(--color-error);
  border-color: var(--color-error);
  background: var(--color-error-soft);
}

.lookup-message {
  margin-bottom: 20px;
  color: var(--color-text-muted);
  font-size: 0.88rem;
}

.result-grid {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--color-border);
  border-left: 1px solid var(--color-border);
}

.result-cell {
  min-width: 0;
  min-height: 158px;
  margin: 0;
  padding: clamp(20px, 3vw, 30px);
  position: relative;
  border-right: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-paper-soft);
}

.result-cell-primary {
  grid-column: span 2;
  min-height: 184px;
  background:
    linear-gradient(105deg, var(--color-success-soft), transparent 58%),
    var(--color-panel);
}

.result-cell dt {
  margin-bottom: 12px;
  color: var(--color-text-muted);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.result-cell dd {
  max-width: 100%;
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--color-text);
  font-family: var(--font-display);
  font-size: clamp(20px, 2.5vw, 30px);
  font-weight: 700;
  line-height: 1.3;
}

.result-cell-primary dd {
  padding-right: 150px;
  color: var(--color-accent-dark);
  font-family: var(--font-mono);
  font-size: clamp(27px, 4.2vw, 48px);
  letter-spacing: -0.03em;
}

.copy-button {
  min-height: 42px;
  padding: 8px 13px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  position: absolute;
  right: 24px;
  bottom: 27px;
  color: var(--color-white);
  border: 1px solid var(--color-success);
  border-radius: var(--radius-xs);
  background: var(--color-success);
  font-size: 0.78rem;
  font-weight: 750;
}

.copy-button svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.copy-button:focus-visible,
#retry-lookup:focus-visible {
  outline: 3px solid var(--color-warning);
  outline-offset: 3px;
}

.copy-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.copy-feedback {
  min-height: 1.4em;
  margin-top: 12px;
  display: block;
  color: var(--color-success);
  font-size: 0.78rem;
}

.result-note {
  margin-top: 10px;
  display: block;
  color: var(--color-text-muted);
  font-size: 0.75rem;
}

.lookup-actions {
  margin-top: 22px;
  display: flex;
  justify-content: flex-end;
}

.lookup-actions .button svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.lookup-aside {
  min-width: 0;
  padding: clamp(25px, 3vw, 38px);
  position: relative;
  overflow: hidden;
  color: var(--color-panel-secondary);
  border: 1px solid var(--color-accent-dark);
  border-radius: var(--radius-xs);
  background:
    repeating-linear-gradient(90deg, transparent 0 27px, var(--color-text-faint) 27px 28px),
    var(--color-text);
  box-shadow: 7px 7px 0 var(--color-accent-soft);
}

.lookup-aside::after {
  width: 110px;
  height: 110px;
  position: absolute;
  right: -48px;
  bottom: -48px;
  content: "";
  border: 15px solid var(--color-accent);
  border-radius: var(--radius-pill);
  opacity: 0.56;
}

.lookup-aside-label {
  color: var(--color-warning);
}

.lookup-aside h2 {
  color: var(--color-panel);
  font-size: clamp(27px, 3vw, 38px);
}

.lookup-aside p {
  position: relative;
  z-index: 1;
  color: var(--color-border);
}

.lookup-aside p:last-of-type {
  margin-bottom: 0;
}

.interpretation-header {
  max-width: 55rem;
  margin-bottom: 42px;
}

.interpretation-header .badge {
  margin-bottom: 18px;
}

.meaning-weave {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(250px, 0.8fr);
  gap: 1px;
  border: 1px solid var(--color-border);
  background: var(--color-border);
  box-shadow: 8px 8px 0 var(--color-panel-secondary);
}

.meaning-band {
  min-width: 0;
  padding: clamp(24px, 4vw, 44px);
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 20px;
  background: var(--color-panel);
}

.meaning-band-wide {
  grid-column: span 2;
}

.meaning-band-accent {
  background:
    linear-gradient(145deg, var(--color-warning-soft), transparent),
    var(--color-panel);
}

.meaning-index {
  padding-top: 6px;
  color: var(--color-accent);
  border-top: 3px solid var(--color-accent);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.meaning-band h3 {
  font-size: clamp(22px, 2.3vw, 29px);
}

.meaning-band p {
  margin-bottom: 0;
  color: var(--color-text-muted);
}

.dns-layout {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.28fr);
  align-items: start;
  gap: clamp(34px, 7vw, 92px);
}

.dns-copy {
  position: sticky;
  top: calc(var(--header-height) + 28px);
}

.dns-copy .badge {
  margin-bottom: 18px;
}

.dns-copy p {
  color: var(--color-text-muted);
}

.dns-steps {
  margin: 0;
  padding: 0;
  counter-reset: dns-step;
  list-style: none;
}

.dns-steps li {
  min-width: 0;
  padding: 28px 28px 28px 80px;
  position: relative;
  border-top: 1px solid var(--color-border);
  counter-increment: dns-step;
}

.dns-steps li:last-child {
  border-bottom: 1px solid var(--color-border);
}

.dns-steps li::before {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  position: absolute;
  top: 28px;
  left: 18px;
  content: counter(dns-step);
  color: var(--color-panel);
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 800;
  box-shadow: 4px 4px 0 var(--color-warning-soft);
}

.dns-steps h3 {
  margin-bottom: 8px;
}

.dns-steps p {
  margin-bottom: 0;
  color: var(--color-text-muted);
}

.privacy-panel {
  padding: clamp(24px, 4vw, 42px);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 24px;
  border: 1px solid var(--color-success);
  border-radius: var(--radius-xs);
  background:
    linear-gradient(110deg, var(--color-success-soft), transparent 65%),
    var(--color-panel);
  box-shadow: 7px 7px 0 var(--color-success-soft);
}

.privacy-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  color: var(--color-success);
  border: 1px solid var(--color-success);
  border-radius: var(--radius-sm);
  background: var(--color-panel);
}

.privacy-icon svg {
  width: 32px;
  height: 32px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.privacy-panel h2 {
  margin-bottom: 8px;
  font-size: clamp(26px, 3vw, 36px);
}

.privacy-panel p {
  max-width: 58rem;
  margin-bottom: 0;
  color: var(--color-text-muted);
}

@media (max-width: 960px) {
  .lookup-layout {
    grid-template-columns: 1fr;
  }

  .lookup-aside {
    min-height: 0;
  }

  .dns-layout {
    grid-template-columns: 1fr;
  }

  .dns-copy {
    position: static;
  }
}

@media (max-width: 768px) {
  .ip-hero {
    grid-template-columns: 1fr;
  }

  .ip-hero-mark {
    width: min(100%, 520px);
  }

  .meaning-weave {
    grid-template-columns: 1fr;
  }

  .meaning-band-wide {
    grid-column: auto;
  }
}

@media (max-width: 560px) {
  .lookup-heading {
    flex-direction: column;
  }

  .result-grid {
    grid-template-columns: 1fr;
  }

  .result-cell-primary {
    grid-column: auto;
  }

  .result-cell-primary dd {
    padding-right: 0;
    padding-bottom: 58px;
  }

  .copy-button {
    right: auto;
    bottom: 22px;
    left: 20px;
  }

  .meaning-band {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .meaning-index {
    width: max-content;
    min-width: 48px;
  }

  .dns-steps li {
    padding: 78px 18px 24px;
  }

  .dns-steps li::before {
    top: 22px;
    left: 18px;
  }

  .privacy-panel {
    grid-template-columns: 1fr;
  }
}