    :root {
      --bg: #f5f7fb;
      --card: #ffffff;
      --text: #142033;
      --muted: #5a6b86;
      --line: #d8e0ee;
      --accent: #0f766e;
      --accent-2: #0b5f59;
      --danger: #b42318;
      --shadow: 0 8px 22px rgba(20, 32, 51, 0.08);
      --radius: 14px;
    }

    * {
      box-sizing: border-box;
    }

    html {
      -webkit-text-size-adjust: 100%;
      text-size-adjust: 100%;
    }

    body {
      margin: 0;
      font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
      background: linear-gradient(180deg, #edf2fa 0%, #f9fbff 45%, #f4f8fc 100%);
      color: var(--text);
      line-height: 1.4;
    }

    .container {
      width: min(100%, 980px);
      margin: 0 auto;
      padding: clamp(12px, 2.8vw, 24px);
    }

    .app {
      background: var(--card);
      border: 1px solid var(--line);
      border-radius: var(--radius);
      box-shadow: var(--shadow);
      overflow: hidden;
    }

    .header {
      padding: clamp(14px, 2.8vw, 22px) clamp(14px, 2.8vw, 20px) clamp(12px, 2.2vw, 18px);
      border-bottom: 1px solid var(--line);
      background: linear-gradient(120deg, #f9fcff 0%, #f3f8ff 100%);
    }

    h1 {
      margin: 0;
      font-size: clamp(1.5rem, 4.8vw, 2rem);
      letter-spacing: 0.2px;
    }

.sub {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: clamp(0.92rem, 1.8vw, 1rem);
}

.seo-intro {
  margin: 10px 0 0;
  max-width: 76ch;
  color: #314763;
  font-size: clamp(0.9rem, 1.7vw, 1rem);
}

.ad-slot {
  margin: 12px 0;
  min-height: clamp(110px, 16vw, 140px);
      border: 1px dashed #b9c7df;
      border-radius: 10px;
      background: #f6f9ff;
      display: flex;
      align-items: center;
      justify-content: center;
      color: #60708f;
      font-size: 0.9rem;
      text-align: center;
  padding: 8px;
  overflow: hidden;
  contain: layout paint;
}

.ad-unit {
  display: block;
  width: 100%;
  min-height: 90px;
}

    .content {
      padding: clamp(12px, 2.5vw, 20px);
      display: grid;
      gap: clamp(10px, 2.4vw, 16px);
    }

    .rate-wrap {
      display: grid;
      gap: 8px;
      max-width: 360px;
    }

    label {
      font-size: 0.9rem;
      color: var(--muted);
      font-weight: 600;
      display: inline-block;
      margin-bottom: 2px;
    }

    input,
    button {
      font: inherit;
    }

    input[type="time"],
    input[type="number"] {
      width: 100%;
      min-height: 48px;
      border: 1px solid var(--line);
      border-radius: 10px;
      padding: 10px 12px;
      background: #fff;
      color: var(--text);
      font-size: 1rem;
    }

    input:focus,
    button:focus {
      outline: 3px solid rgba(15, 118, 110, 0.22);
      outline-offset: 1px;
    }

.days {
  display: grid;
  gap: 12px;
  min-height: 860px;
}

    .day {
      border: 1px solid var(--line);
      border-radius: 12px;
      padding: clamp(10px, 2vw, 14px);
      background: #fff;
      display: grid;
      gap: 10px;
    }

    .day-head {
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 8px;
      flex-wrap: wrap;
    }

    .day-name {
      font-weight: 700;
      font-size: 1rem;
    }

    .day-total {
      color: var(--accent-2);
      font-weight: 700;
      font-size: 0.95rem;
    }

    .day-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 10px;
    }

    .day-grid .wide {
      grid-column: 1 / -1;
    }

    .results {
      border: 1px solid var(--line);
      border-radius: 12px;
      background: #fcfdff;
      padding: clamp(10px, 2vw, 14px);
      display: grid;
      gap: 6px;
    }

    .result-row {
      display: flex;
      justify-content: space-between;
      align-items: baseline;
      gap: 12px;
      flex-wrap: wrap;
    }

    .result-label {
      color: var(--muted);
      font-size: 0.95rem;
    }

    .result-value {
      font-size: 1.05rem;
      font-weight: 700;
    }

    .overtime {
      color: var(--danger);
      font-weight: 700;
      min-height: 1.2em;
    }

    .actions {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 10px;
    }

    .btn {
      min-height: 48px;
      border: 0;
      border-radius: 10px;
      background: var(--accent);
      color: #fff;
      font-weight: 700;
      cursor: pointer;
    }

    .btn:hover {
      background: #0c655f;
    }

    .btn.secondary {
      background: #e8eef8;
      color: #1f2f47;
      border: 1px solid #ccd8ea;
    }

.faq {
      margin-top: 14px;
      background: #fff;
      border: 1px solid var(--line);
      border-radius: var(--radius);
      box-shadow: var(--shadow);
      padding: clamp(12px, 2.4vw, 18px);
}

.faq,
.foot {
  content-visibility: auto;
  contain-intrinsic-size: 1px 500px;
}

    .faq h2 {
      margin: 0 0 10px;
      font-size: 1.25rem;
    }

    details {
      border-top: 1px solid var(--line);
      padding: 10px 0;
    }

    details:first-of-type {
      border-top: 0;
      padding-top: 0;
    }

    summary {
      cursor: pointer;
      font-weight: 600;
    }

    .foot {
      text-align: center;
      color: var(--muted);
      font-size: 0.84rem;
      margin: 14px 0 10px;
    }

@media (max-width: 420px) {
      .day-grid {
        grid-template-columns: 1fr;
      }

      .actions {
        grid-template-columns: 1fr;
      }

      .result-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
      }
}

@media (min-width: 700px) {
  .days {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    min-height: 460px;
  }
}

    @media (min-width: 760px) {
      .container {
        padding: 24px;
      }

      .content {
        padding: 18px;
      }

      .day-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
      }

      .day-grid .wide {
        grid-column: auto;
      }

      .actions {
        grid-template-columns: auto auto;
        justify-content: start;
      }

      .btn {
        min-width: 160px;
      }
    }

    @media (min-width: 1024px) {
      .container {
        width: min(100%, 1080px);
      }

      .content {
        gap: 18px;
      }
    }

    @media print {
      body {
        background: #fff;
      }

      .container {
        width: 100%;
        max-width: 100%;
        padding: 0;
      }

      .app,
      .faq {
        box-shadow: none;
      }

      .actions,
      .ad-slot {
        display: none;
      }
    }
