/* Work hours calculator — extends time-calculator.css */

.whc-settings {
  display: grid;
  grid-template-columns: repeat(4, 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);
}

.whc-settings .tc-field--wide {
  grid-column: span 2;
}

.whc-day {
  display: grid;
  grid-template-columns: 7.5rem repeat(4, minmax(0, 1fr)) 4.5rem;
  gap: 0.5rem;
  align-items: end;
  padding: 0.55rem 0;
  border-bottom: 1px dashed var(--line);
}

.whc-day:last-child {
  border-bottom: 0;
}

.whc-day__label {
  font-weight: 750;
  font-size: 0.92rem;
  padding-bottom: 0.65rem;
  color: var(--ink);
}

.whc-day__total {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  padding-bottom: 0.55rem;
  text-align: right;
  color: var(--brand, #0b3d91);
}

.whc-days-wrap {
  max-height: 420px;
  overflow: auto;
  margin: 0.5rem 0 0.75rem;
  padding-right: 0.25rem;
}

.whc-add-row {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr)) auto;
  gap: 0.5rem;
  align-items: end;
  margin-bottom: 0.55rem;
}

.whc-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.35rem 0 0.75rem;
}

.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;
}

.tc-error {
  color: #b42318;
  font-weight: 600;
  margin: 0.75rem 0 0;
}

@media (max-width: 900px) {
  .whc-settings {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .whc-day {
    grid-template-columns: 1fr 1fr;
  }

  .whc-day__label {
    grid-column: 1 / -1;
    padding-bottom: 0;
  }

  .whc-day__total {
    grid-column: 1 / -1;
    text-align: left;
  }

  .whc-add-row {
    grid-template-columns: 1fr 1fr;
  }
}

/* Mobile: title → calculator immediately */
@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,
  .whc-toolbar .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;
  }
}

@media print {
  .site-header,
  .ambient,
  .wc-crosslink,
  .tc-hero__actions,
  .tc-tool__toggles,
  .tc-tabs,
  .whc-toolbar,
  .site-footer,
  .toast {
    display: none !important;
  }

  .tc-tool {
    box-shadow: none;
    border: 0;
  }
}
