.cdr-page {
  font-family: 'Courier New', Courier, monospace;
  background: #ffffff;
  color: #2a2a26;
  padding: 0;
  margin: 0;
  max-width: 1000px;
  box-sizing: border-box;
}
.cdr-page * { box-sizing: border-box; }

.cdr-breadcrumb { font-size: 12px; margin-bottom: 20px; color: #1a1a17; }
.cdr-breadcrumb a { color: #1a4fd6; text-decoration: none; }
.cdr-breadcrumb a:hover { text-decoration: underline; }
.cdr-breadcrumb span { color: #1a1a17; }

.cdr-subtitle {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 16px;
  color: #444;
  margin: 0 0 24px 0;
}

.cdr-panel { border: 1px solid #2a2a26; background: #ffffff; margin-bottom: 32px; }

.cdr-body { display: flex; flex-wrap: wrap; gap: 24px; padding: 24px; }
.cdr-inputs { flex: 1 1 360px; min-width: 0; }
.cdr-row { display: flex; gap: 16px; margin-bottom: 12px; }
.cdr-field { flex: 1; min-width: 0; }
.cdr-field label {
  display: block;
  font-size: 11px;
  letter-spacing: 0.05em;
  margin-bottom: 5px;
  color: #555;
}

.cdr-select-wrap { position: relative; }
.cdr-page .cdr-select-wrap select {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  display: block !important;
  box-sizing: border-box !important;
  width: 100% !important;
  height: 32px !important;
  min-height: 0 !important;
  max-height: none !important;
  margin: 0 !important;
  padding: 0 28px 0 8px !important;
  border: 1px solid #999 !important;
  border-radius: 0 !important;
  background: #fff !important;
  font-family: inherit !important;
  font-size: 13px !important;
  line-height: 30px !important;
  color: #2a2a26 !important;
  vertical-align: middle !important;
  cursor: pointer;
}
.cdr-page .cdr-select-wrap select:focus { outline: 1px solid #2a2a26 !important; }
.cdr-select-arrow {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 11px;
  color: #555;
}

.cdr-input-group {
  display: flex;
  align-items: stretch;
  border: 1px solid #999;
  background: #fff;
  height: 32px;
  overflow: hidden;
}
.cdr-input-group.cdr-readonly { background: #f7f7f7; }
.cdr-page .cdr-input-group input {
  appearance: none !important;
  -webkit-appearance: none !important;
  box-sizing: border-box !important;
  flex: 1 1 auto !important;
  min-width: 0 !important;
  width: 100% !important;
  height: 30px !important;
  min-height: 0 !important;
  max-height: none !important;
  margin: 0 !important;
  padding: 0 8px !important;
  border: none !important;
  border-radius: 0 !important;
  outline: none !important;
  box-shadow: none !important;
  font-family: inherit !important;
  font-size: 13px !important;
  line-height: 30px !important;
  color: #2a2a26 !important;
  background: transparent !important;
  vertical-align: middle !important;
}
.cdr-page .cdr-input-group input[readonly] { color: #555 !important; }
.cdr-page .cdr-input-group input.cdr-bad { color: #c0392b !important; }
.cdr-input-group:focus-within { outline: 1px solid #2a2a26; }

.cdr-binary {
  border: 1px solid #ddd;
  background: #fafafa;
  padding: 12px;
  margin-top: 4px;
}
.cdr-binary-head {
  font-size: 10px;
  letter-spacing: 0.06em;
  color: #555;
  margin-bottom: 8px;
}
.cdr-binary-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 5px;
}
.cdr-binary-label {
  font-size: 10px;
  color: #999;
  width: 58px;
  flex: 0 0 auto;
}
.cdr-binary-bits {
  font-size: 11px;
  letter-spacing: 0.5px;
  white-space: nowrap;
  overflow-x: auto;
}
.cdr-binary-bits .net { color: #1a4fd6; }
.cdr-binary-bits .host { color: #b8860b; }
.cdr-binary-bits .dot { color: #bbb; }
.cdr-binary-legend {
  font-size: 10px;
  color: #777;
  margin-top: 8px;
}
.cdr-swatch {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 4px;
  margin-left: 8px;
  vertical-align: middle;
}
.cdr-binary-legend .cdr-swatch:first-child { margin-left: 0; }
.cdr-swatch-net { background: #1a4fd6; }
.cdr-swatch-host { background: #b8860b; }

.cdr-result { flex: 1 1 300px; border: 1px solid #999; padding: 16px 20px; background: #fff; }
.cdr-result-head {
  font-size: 11px;
  letter-spacing: 0.05em;
  color: #555;
  border-bottom: 1px solid #ccc;
  padding-bottom: 8px;
  margin-bottom: 8px;
}
.cdr-result-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #eee;
  font-size: 12px;
  color: #555;
}
.cdr-result-row strong { font-size: 15px; color: #1a1a17; text-align: right; }
.cdr-btns { margin-top: 16px; display: flex; gap: 8px; }
.cdr-btns button {
  font-family: inherit;
  font-size: 13px;
  padding: 8px 14px;
  border: 1px solid #2a2a26;
  background: #ffffff;
  color: #2a2a26;
  cursor: pointer;
}
.cdr-btns button:hover { background: #f2f2f2; }
.cdr-btns button:disabled { opacity: 0.5; cursor: default; }

.cdr-note {
  border-top: 1px solid #999;
  border-left: 3px solid #c9a227;
  background: #fbf8ee;
  padding: 12px 16px;
  font-size: 12px;
  color: #1a1a17;
}
.cdr-note.cdr-error {
  border-left-color: #c0392b;
  background: #fdf0ee;
  color: #8a2418;
}

@media (max-width: 520px) {
  .cdr-row { flex-direction: column; gap: 12px; }
  .cdr-body { padding: 16px; }
}
