/* Sleep calculator — extends time-calculator.css */

.sc-settings {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin: 0 0 1rem;
  padding: 0.85rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.75);
}

.sc-cycles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
  margin-top: 0.85rem;
}

.sc-cycle {
  padding: 0.9rem 1rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}

.sc-cycle.is-best {
  border-color: #0b3d91;
  box-shadow: 0 0 0 2px rgba(11, 61, 145, 0.12);
  background: linear-gradient(180deg, #f4f8ff, #fff);
}

.sc-cycle__tag {
  margin: 0 0 0.35rem;
  font-size: 0.7rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.sc-cycle.is-best .sc-cycle__tag {
  color: #0b3d91;
}

.sc-cycle strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  letter-spacing: -0.03em;
}

.sc-cycle span {
  display: block;
  margin: 0.15rem 0 0.4rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.sc-cycle p {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--ink);
}

.sc-note {
  margin: 0.9rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

.sc-score {
  margin: 0.2rem 0 0.85rem;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 6vw, 3.4rem);
  letter-spacing: -0.04em;
  line-height: 1;
}

.sc-score span {
  display: block;
  margin-top: 0.25rem;
  font-family: var(--font-sans, inherit);
  font-size: 1rem;
  font-weight: 650;
  letter-spacing: 0;
  color: var(--muted);
}

.sc-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.15rem;
  margin: 0.65rem 0 0.85rem;
  font-weight: 650;
}

.sc-checks label {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  cursor: pointer;
}

.tc-error {
  color: #b42318;
  font-weight: 600;
  margin: 0.75rem 0 0;
}

.tc-steps {
  margin: 0.85rem 0 0;
  padding-left: 1.2rem;
  color: var(--muted);
  line-height: 1.65;
}

.tc-steps li {
  margin-bottom: 0.35rem;
}

.sc-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0.7rem 0 0;
  font-size: 0.95rem;
}

.sc-table th,
.sc-table td {
  text-align: left;
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid var(--line);
}

.sc-table th {
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

@media (max-width: 900px) {
  .sc-settings {
    grid-template-columns: 1fr;
  }

  .sc-cycles {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .tc-page {
    width: min(100%, calc(100% - 1.25rem));
    padding: 0.65rem 0 2.75rem;
    display: flex;
    flex-direction: column;
  }

  .tc-page > .wc-crosslink,
  .tc-hero__lead,
  .tc-hero__actions,
  .tc-strip {
    display: none !important;
  }

  .tc-hero {
    order: 1;
    padding: 0.35rem 0 0.25rem;
  }

  .tc-hero h1 {
    margin: 0 0 0.55rem;
    font-size: clamp(1.7rem, 8.5vw, 2.15rem);
    max-width: none;
  }

  .tc-tool {
    order: 2;
    margin: 0 0 1.5rem;
    padding: 0.85rem 0.8rem 1.1rem;
    border-radius: 18px;
  }

  .tc-tool__head > div:first-child {
    display: none;
  }

  .tc-section:not(.tc-faq):not(#faq) {
    display: none !important;
  }

  .tc-field input,
  .tc-field select {
    min-height: 44px;
    font-size: 16px;
  }

  .tc-actions .btn {
    min-height: 44px;
  }

  .tc-tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .tc-tabs::-webkit-scrollbar {
    display: none;
  }

  .tc-tabs button {
    flex: 0 0 auto;
    white-space: nowrap;
  }
}
