/* Cron tool. Hero, content sections, cards and FAQ come from tool_page.css;
   only the interactive panels are here. */

/* The star field behind the hero is a positioned image, so the panels need
   their own stacking context or it swallows every click. */
.cr {
  position: relative;
  z-index: 1;
  max-width: 1060px;
  margin: 0 auto 56px auto;
  padding: 0 16px;
}

.cr-panel {
  margin-top: 16px;
  padding: 20px;
  border-radius: 16px;
  border: 0.5px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
}

.cr-panel-title {
  margin: 0 0 6px 0;
  color: #fff;
  font-size: 18px;
  font-weight: 600;
}

.cr-panel-title--spaced {
  margin-top: 24px;
}

.cr-hint {
  margin: 0 0 14px 0;
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
  line-height: 22px;
}

.cr-label {
  display: block;
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 500;
}

.cr-input-row,
.cr-line-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.cr-input {
  flex: 1 1 260px;
  min-width: 0;
  padding: 13px 16px;
  border-radius: 12px;
  border: 0.5px solid rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.28);
  color: #fff;
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 18px;
  letter-spacing: 0.5px;
  line-height: 26px;
}

.cr-input:focus {
  outline: none;
  border-color: #8c46ff;
  background: rgba(0, 0, 0, 0.42);
}

.cr.is-invalid .cr-input {
  border-color: rgba(255, 122, 122, 0.6);
}

.cr-select {
  width: 100%;
  padding: 11px 14px;
  border-radius: 10px;
  border: 0.5px solid rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.28);
  color: #fff;
  font-size: 15px;
}

.cr-select:focus {
  outline: none;
  border-color: #8c46ff;
}

.cr-select option {
  background: #1b0b33;
  color: #fff;
}

.cr-error {
  margin: 12px 0 0 0;
  padding: 10px 14px;
  border-radius: 10px;
  border: 0.5px solid rgba(255, 122, 122, 0.45);
  background: rgba(255, 80, 80, 0.12);
  color: #ffc7c7;
  font-size: 14px;
  line-height: 21px;
}

/* The plain-language reading of the expression is the answer most visitors
   came for, so it is the largest thing on the panel. */
.cr-summary {
  margin: 14px 0 0 0;
  color: #fff;
  font-size: 20px;
  font-weight: 500;
  line-height: 30px;
}

.cr-summary:first-letter {
  text-transform: uppercase;
}

.cr-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.cr-field {
  display: flex;
  flex-direction: column;
  gap: 2px;
  align-items: center;
  min-width: 84px;
  padding: 8px 12px;
  border-radius: 10px;
  border: 0.5px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.24);
}

.cr-field-token {
  color: #fff;
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 16px;
}

.cr-field-label {
  color: rgba(255, 255, 255, 0.5);
  font-size: 11.5px;
}

.cr-warnings {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.cr-warning-item {
  margin: 0;
  padding: 10px 14px;
  border-radius: 10px;
  border: 0.5px solid rgba(255, 196, 84, 0.35);
  background: rgba(255, 196, 84, 0.1);
  color: #ffd79a;
  font-size: 13px;
  line-height: 20px;
}

.cr-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}

.cr-columns .cr-panel {
  margin-top: 16px;
}

.cr-runs {
  display: flex;
  flex-direction: column;
  margin-top: 12px;
}

.cr-run {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.09);
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
}

.cr-run:last-child {
  border-bottom: none;
}

.cr-run-clock {
  color: #fff;
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-variant-numeric: tabular-nums;
}

.cr-empty {
  margin: 12px 0 0 0;
  color: rgba(255, 255, 255, 0.5);
  font-size: 14px;
}

.cr-builder {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
}

.cr-build-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  min-width: 0;
}

.cr-build-field span {
  color: rgba(255, 255, 255, 0.7);
  font-size: 12.5px;
}

.cr-build-field input {
  width: 100%;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 10px;
  border: 0.5px solid rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.28);
  color: #fff;
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 15px;
}

.cr-build-field input:focus {
  outline: none;
  border-color: #8c46ff;
}

.cr-line-row {
  margin-top: 10px;
}

.cr-line {
  flex: 1 1 240px;
  min-width: 0;
  padding: 11px 14px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.34);
  color: #d9c7ff;
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px;
  line-height: 22px;
  word-break: break-all;
}

/* Confirmation goes to its own line with a reserved height. Swapping a button's
   label changes its width and shoves its neighbours sideways -- including the
   control the pointer is resting on. */
.cr-status {
  min-height: 20px;
  margin: 12px 0 0 0;
  padding: 0 16px;
  color: #6ee7a8;
  font-size: 13px;
  line-height: 20px;
}

.cr-presets {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
  margin-top: 4px;
}

.cr-preset {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 13px;
  border-radius: 10px;
  border: 0.5px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.24);
  color: #fff;
  text-align: left;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.cr-preset:hover {
  border-color: rgba(140, 70, 255, 0.6);
  background: rgba(110, 0, 255, 0.18);
}

.cr-preset code {
  color: #d9c7ff;
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px;
}

.cr-preset span {
  color: rgba(255, 255, 255, 0.6);
  font-size: 12.5px;
}

@media (max-width: 900px) {
  .cr-columns {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 640px) {
  .cr-input {
    font-size: 16px;
  }

  .cr-summary {
    font-size: 17px;
    line-height: 26px;
  }

  .cr-input-row .tp-btn,
  .cr-line-row .tp-btn {
    width: 100%;
  }
}
