@charset "UTF-8";
.lab {
  max-width: 160rem;
  margin: 0 auto;
  padding: 3.2rem 4rem 6rem;
  color: #19354b;
  font-size: 1.4rem;
}

.lab h1 {
  font-size: 3.2rem;
  letter-spacing: -0.08rem;
  margin: 0.6rem 0;
}

.lab h2 {
  font-size: 1.65rem;
  margin: 0;
  font-weight: 650;
}

.lab p {
  margin: 0.6rem 0;
  color: #627587;
}

.lab button {
  font-size: 1.3rem;
}

.lab-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  margin-bottom: 2.4rem;
}

.lab .eyebrow {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.18rem;
  color: #708496;
}

.lab-actions, .sheet-tools {
  display: flex;
  gap: 0.8rem;
  align-items: center;
}

.lab .quiet {
  background: white;
  border: 1px solid #cedbe3;
  color: #25465f;
  padding: 0.9rem 1.4rem;
}

.study-bar {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  margin-bottom: 2.4rem;
  border-bottom: 1px solid #dce5ea;
  padding-bottom: 1.8rem;
}

.study-bar label {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.12rem;
  color: #718798;
}

.study-bar input {
  max-width: 28rem;
  background: transparent;
  border: 0;
  border-bottom: 1px dashed #b2c5d1;
  border-radius: 0;
  padding: 0.5rem 0;
  color: #24445d;
}

.study-bar span {
  margin-left: auto;
  font-size: 1.2rem;
  color: #6d8592;
}

.lab-grid {
  display: grid;
  grid-template-columns: minmax(32rem, 38rem) minmax(0, 1fr);
  gap: 2.4rem;
  align-items: start;
}

.lab-inputs, .lab-results {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.lab-card {
  border: 1px solid #dbe5eb;
  border-radius: 1.2rem;
  background: #fff;
  padding: 2rem;
  box-shadow: 0 0.2rem 0.6rem rgba(16, 63, 121, 0.0117647059);
}

.section-label {
  display: flex;
  gap: 1rem;
  align-items: center;
  margin-bottom: 1.7rem;
  flex-wrap: wrap;
}

.section-label > span:first-child {
  font-size: 1.05rem;
  font-weight: 700;
  background: #eaf3f6;
  color: #2c7c88;
  border-radius: 0.5rem;
  padding: 0.35rem 0.6rem;
}

.section-label small {
  margin-left: auto;
  color: #758894;
}

.lab label {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  font-size: 1.15rem;
  font-weight: 600;
  color: #4e687d;
}

.lab label > span {
  font-size: inherit;
}

.lab input, .lab select {
  width: 100%;
  min-width: 0;
  border: 1px solid #d2dfe7;
  border-radius: 0.6rem;
  background: #fff;
  color: #1c3d54;
  padding: 0.85rem 1rem;
  font: 1.3rem system-ui;
}

.lab select {
  padding-right: 2rem;
}

.lab input:focus, .lab select:focus {
  outline: 2px solid #69bdb7;
  outline-offset: 1px;
}

.field-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.3rem;
}

.lab .field-note {
  font-size: 1.1rem;
  line-height: 1.55;
  color: #728694;
  margin-top: 1rem;
}

.lab details {
  margin-top: 1.6rem;
  border-top: 1px solid #e8eef2;
  padding-top: 1.3rem;
}

.lab summary {
  cursor: pointer;
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #375b72;
}

.lab details .field-pair {
  margin-top: 1rem;
}

.lab details > label {
  margin-top: 1rem;
}

.lab details p {
  font-size: 1.2rem;
}

.lab .text-button {
  padding: 0.3rem 0;
  background: transparent;
  color: #217d83;
  font-size: 1.15rem;
  border-radius: 0;
}

.lab .text-button:hover {
  text-decoration: underline;
}

.lab .text-button:disabled {
  color: #9baeb9;
}

.sheet-card {
  padding-bottom: 1.5rem;
}

.sheet-tools {
  justify-content: space-between;
  margin-bottom: 1.2rem;
}

.data-grid {
  max-height: 44rem;
  overflow: auto;
  border: 1px solid #e0e8ed;
  border-radius: 0.7rem;
}

.data-grid table {
  border-collapse: collapse;
  width: 100%;
  table-layout: fixed;
  font-variant-numeric: tabular-nums;
}

.data-grid th {
  position: sticky;
  top: 0;
  background: #f1f6f8;
  z-index: 1;
  color: #627c8f;
  font-size: 1.05rem;
  font-weight: 600;
  height: 3.4rem;
  border-bottom: 1px solid #dce6ec;
}

.data-grid th:first-child {
  width: 2.6rem;
}

.data-grid th:last-child {
  width: 2.3rem;
}

.data-grid td {
  padding: 0;
  border-bottom: 1px solid #edf1f4;
  border-right: 1px solid #edf1f4;
}

.data-grid td:first-child {
  text-align: center;
  color: #92a4b0;
  font-size: 1rem;
  background: #fafcfd;
}

.data-grid td input {
  width: 100%;
  font-size: 1.15rem;
  border: 0;
  border-radius: 0;
  padding: 0.65rem 0.45rem;
  height: 3.4rem;
  text-align: right;
}

.data-grid td input::placeholder {
  color: #abb8c1;
}

.data-grid tr.selected-row td {
  background: #e7f6f3;
}

.data-grid tr.selected-row input {
  background: #effaf8;
}

.data-grid td button {
  width: 100%;
  padding: 0;
  background: transparent;
  color: #93a5b2;
  font-size: 1.5rem;
}

.lab .add-row {
  width: 100%;
  background: #f3f8fa;
  color: #4a7186;
  margin-top: 1rem;
  font-size: 1.15rem;
  padding: 0.8rem;
}

.analysis-controls .method-pill {
  margin-left: auto;
  font-size: 1rem;
  background: #f3f7fa;
  color: #54768e;
  padding: 0.4rem 0.8rem;
  border-radius: 2rem;
}

.fit-fields {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 1.4rem;
}

.analyze-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  margin-top: 1.8rem;
}

.analyze-row p {
  font-size: 1.15rem;
  max-width: 39rem;
}

.analyze-row button {
  white-space: nowrap;
  background: #107e7b;
  padding: 1.1rem 2rem;
}

.analyze-row button span {
  margin-left: 1rem;
}

#manual-range {
  margin-top: 1rem;
}

#analysis-status {
  font-size: 1.15rem;
  margin-top: 1.2rem;
  color: #647e8e;
}

#analysis-status.error {
  color: #a34326;
}

#analysis-status.success {
  color: #18786b;
}

.result-metrics {
  display: grid;
  grid-template-columns: 1.15fr 1fr 1.1fr;
  gap: 1.2rem;
}

.result-metrics article {
  border: 1px solid #d9e6ea;
  border-radius: 1rem;
  padding: 1.8rem;
  background: white;
}

.result-metrics article:first-child {
  background: #e9f6f3;
  border-color: #c9e7e0;
}

.result-metrics p {
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.08rem;
  color: #65818b;
  margin: 0 0 0.7rem;
}

.result-metrics strong {
  display: block;
  font-size: 2.4rem;
  line-height: 1.4;
  letter-spacing: -0.05rem;
  color: #117f7a;
}

.result-metrics article:last-child strong {
  font-size: 1.8rem;
  padding: 0.4rem 0;
}

.result-metrics small {
  font-size: 1rem;
  color: #78929d;
}

.plot-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.plot-title p {
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.legend-dot {
  display: inline-block;
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: #103f79;
}

.legend-line {
  display: inline-block;
  width: 1.6rem;
  height: 0.2rem;
  background: #10978a;
  margin-left: 0.7rem;
}

.legend-band {
  display: inline-block;
  width: 1.4rem;
  height: 0.7rem;
  background: #c7e9e3;
  margin-left: 0.7rem;
}

.chart {
  position: relative;
  min-height: 25rem;
  margin-top: 1rem;
}

.chart svg {
  display: block;
  width: 100%;
  height: auto;
}

.chart-empty {
  min-height: 25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 0.6rem;
  color: #76909e;
  font-size: 1.4rem;
  background: linear-gradient(rgba(255, 255, 255, 0) 95%, #eaf0f4 95%);
  background-size: 100% 5rem;
}

.chart-empty small {
  font-size: 1.1rem;
  color: #a0b0ba;
}

.derivative-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.small.chart, .small .chart-empty {
  min-height: 19rem;
}

.chart-tooltip {
  position: absolute;
  left: 1rem;
  bottom: 0.5rem;
  background: rgba(22, 62, 84, 0.9215686275);
  color: white;
  border-radius: 0.5rem;
  padding: 0.45rem 0.8rem;
  font-size: 1.1rem;
  pointer-events: none;
}

.interpretation ul {
  padding-left: 1.8rem;
  font-size: 1.15rem;
  color: #60798b;
  line-height: 1.7;
}

.interpretation .section-label button {
  margin-left: auto;
}

.interpretation > p {
  font-size: 1.2rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.lab [hidden] {
  display: none !important;
}

.marca nav {
  display: flex;
  gap: 2.4rem;
}

.marca nav a {
  font-size: 1.3rem;
  line-height: 1.4;
  color: #31566d;
}

.plot-tools {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  margin: 0.7rem 0;
}

.plot-tools label {
  flex-direction: row;
  align-items: center;
  font-weight: 400;
}

.plot-tools input {
  width: auto;
}

.plot-tools button {
  margin-left: auto;
}

@media (min-width: 1500px) {
  .chart {
    min-height: 30rem;
  }
}
@media (max-width: 1100px) {
  .lab {
    padding: 2.4rem 2rem;
  }
  .lab-grid {
    grid-template-columns: 31rem minmax(0, 1fr);
    gap: 1.5rem;
  }
  .fit-fields {
    grid-template-columns: 1fr 1fr;
  }
  .fit-fields > label:first-child {
    grid-column: 1/-1;
  }
  .result-metrics {
    grid-template-columns: 1fr;
  }
  .result-metrics article {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 1rem 1.4rem;
  }
  .result-metrics strong {
    grid-column: 2;
    grid-row: 1/3;
    text-align: right;
    font-size: 2rem;
  }
  .result-metrics article:last-child strong {
    font-size: 1.5rem;
  }
  .derivative-grid {
    grid-template-columns: 1fr;
  }
  .analyze-row {
    align-items: stretch;
    flex-direction: column;
    gap: 0.8rem;
  }
  .lab-card {
    padding: 1.6rem;
  }
}
@media (max-width: 740px) {
  .lab {
    padding: 2rem 1.4rem 4rem;
  }
  .lab-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 1.2rem;
  }
  .lab h1 {
    font-size: 2.7rem;
  }
  .lab-grid {
    grid-template-columns: 1fr;
  }
  .lab-actions {
    width: 100%;
  }
  .lab-actions button {
    flex: 1;
  }
  .study-bar {
    gap: 0.8rem;
    flex-wrap: wrap;
  }
  .study-bar input {
    flex: 1;
  }
  .study-bar span {
    width: 100%;
    margin: 0;
  }
  .lab-inputs {
    gap: 1.4rem;
  }
  .data-grid {
    max-height: 30rem;
  }
  .lab-results {
    gap: 1.4rem;
  }
  .result-metrics {
    grid-template-columns: 1fr;
  }
  .marca {
    padding: 1rem 1.6rem;
    gap: 1rem;
    flex-wrap: wrap;
  }
  .marca img {
    width: 20rem;
  }
  .marca nav {
    gap: 1.4rem;
  }
  .marca nav a {
    font-size: 1.15rem;
  }
  .derivative-grid {
    gap: 1.4rem;
  }
  .chart, .chart-empty {
    min-height: 18rem;
  }
}
/* Selector de saltos: escala tipográfica consistente con la pantalla. */
.candidate-heading {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.3rem;
  flex-wrap: wrap;
  color: #567185;
  font-size: 1.15rem;
}

.candidate-heading button {
  flex-shrink: 0;
}

.candidate-panel {
  border-top: 1px solid #e2ebef;
  margin-top: 1rem;
  padding-top: 1rem;
}

.candidate-panel h3 {
  font-size: 1.3rem;
  margin: 0 0 0.9rem;
  color: #103f79;
}

.candidate-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
  gap: 0.8rem;
}

.lab .candidate-option {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  text-align: left;
  border: 1px solid #cbdde5;
  border-radius: 10px;
  padding: 1.2rem;
  background: #f7fafb;
  color: #103f79;
  cursor: pointer;
  min-width: 0;
  white-space: normal;
}

.lab .candidate-option strong {
  font-size: 1.35rem;
}

.lab .candidate-option span {
  font-size: 1.1rem;
  color: #567185;
  font-weight: 400;
}

.lab .candidate-option[aria-pressed=true] {
  background: #e7f6f1;
  border: 2px solid #0d918a;
  padding: calc(1.2rem - 1px);
}

.lab .candidate-option:focus-visible {
  outline: 3px solid #103f79;
  outline-offset: 3px;
}

.candidate-panel ul {
  font-size: 1.1rem;
  color: #567185;
  padding-left: 1.8rem;
  line-height: 1.55;
  margin-bottom: 0;
}

.cond-options {
  margin-top: 1.3rem;
}

.cond-check {
  flex-direction: row !important;
  align-items: center;
}

.cond-check input {
  width: auto !important;
}

.measurement-column {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1.3rem;
}

.lab .fit-quality {
  margin: 0;
  padding: 1.2rem 1.5rem;
  border: 1px solid #e4d1a6;
  border-radius: 0.7rem;
  background: #fff9ed;
  color: #755822;
  font-size: 1.2rem;
  line-height: 1.6;
}

.derivative-toolbar {
  padding: 1.2rem 0;
}

.derivative-toolbar select {
  max-width: 40rem;
}

.analysis-controls .fit-fields {
  margin-top: 1.4rem;
}

.standard-preview {
  display: block;
  color: #167b76;
  background: #edf8f5;
  border-radius: 0.5rem;
  padding: 0.7rem;
  font-size: 1.1rem;
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.cond-line-results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.cond-line-results article {
  padding: 1.4rem;
  border: 1px solid #d7e5eb;
  border-radius: 10px;
}

.cond-line-results h3 {
  margin: 0 0 1rem;
  font-size: 1.4rem;
  color: #103f79;
}

.cond-line-results p {
  font-size: 1.2rem;
  overflow-wrap: anywhere;
}

.data-grid tr.secondary-row input {
  background: #eef3fc;
}

.data-grid tr.downweighted-row td:first-child {
  background: #fff0d2;
  color: #8e570d;
  font-weight: bold;
}