/* Roberin pH calculator locale compact renewal · full locale release · 2026-06-21 */
body {
  --ph-page: #faf2e8;
  --ph-paper: #fff7e8;
  --ph-paper-soft: #fbf0dc;
  --ph-panel: #fffdf7;
  --ph-input: #fffdf8;
  --ph-ink: #2b2119;
  --ph-muted: #67584a;
  --ph-line: #6b5745;
  --ph-line-soft: rgba(107, 87, 69, 0.28);
  --ph-grid: rgba(107, 87, 69, 0.055);
  --ph-primary-bg: #f2e3d3;
  --ph-primary-ink: #2b2119;
  --ph-unit: #faecd4;
  --ph-green: #e3efd2;
  --ph-blue: #dfeef8;
  --ph-amber: #d2aa55;
  --ph-red: #a94a36;
  --ph-shadow: 4px 4px 0 rgba(72, 55, 40, 0.22);
  --ph-shadow-soft: 2px 2px 0 rgba(72, 55, 40, 0.14);
  --ph-result-accent: #e3efd2;
  --ph-result-ink: #2b2119;
  background:
    linear-gradient(var(--ph-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--ph-grid) 1px, transparent 1px),
    var(--ph-page);
  background-size: 20px 20px, 20px 20px, auto;
}

body .cs-site-content > .cs-container,
body .cs-main-content,
body .cs-content-area,
body .cs-entry__container,
body .cs-entry__content-wrap {
  width: 100%;
  max-width: none;
}

body .cs-breadcrumbs,
body .cs-entry__header,
body .ph-calculator-container,
body .entry-content > article {
  width: min(900px, calc(100vw - 32px));
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

body .cs-entry__header {
  margin-top: 18px;
  margin-bottom: 14px;
  text-align: left;
}

body .cs-entry__title {
  color: var(--ph-ink);
  font-size: clamp(30px, 3.2vw, 42px);
  line-height: 1.12;
  font-weight: 950;
  letter-spacing: -0.055em;
  word-break: keep-all;
}

.ph-calculator-container,
.ph-calculator-container *,
.ph-calculator-container *::before,
.ph-calculator-container *::after {
  box-sizing: border-box;
}

.ph-calculator-container {
  position: relative;
  isolation: isolate;
  display: block;
  margin-top: 0;
  margin-bottom: 24px;
  overflow: hidden;
  color: var(--ph-ink);
  background:
    linear-gradient(rgba(107, 87, 69, 0.052) 1px, transparent 1px),
    linear-gradient(90deg, rgba(107, 87, 69, 0.044) 1px, transparent 1px),
    var(--ph-paper);
  background-size: 20px 20px, 20px 20px, auto;
  border: 2px solid var(--ph-line);
  border-radius: 0;
  box-shadow: var(--ph-shadow);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
  line-height: 1.45;
  text-align: left;
}

.ph-calculator-container[data-ph-tone="acid-strong"] { --ph-result-accent: #f3d6ca; --ph-result-ink: #2b2119; }
.ph-calculator-container[data-ph-tone="acid-weak"] { --ph-result-accent: #f5e0c5; --ph-result-ink: #2b2119; }
.ph-calculator-container[data-ph-tone="neutral"] { --ph-result-accent: #e3efd2; --ph-result-ink: #2b2119; }
.ph-calculator-container[data-ph-tone="base-weak"] { --ph-result-accent: #dfeef8; --ph-result-ink: #2b2119; }
.ph-calculator-container[data-ph-tone="base-strong"] { --ph-result-accent: #e5def1; --ph-result-ink: #2b2119; }

.ph-calculator-container br,
.ph-calculator-container p:empty {
  display: none !important;
  margin: 0 !important;
  padding: 0 !important;
  min-height: 0 !important;
}

.ph-calculator-container :where(h2, h3, p, span, strong, em, small, label) {
  color: inherit;
  word-break: keep-all;
}

.ph-calculator-container :where(button, input) {
  font: inherit !important;
  letter-spacing: 0 !important;
  border-radius: 0 !important;
}

.ph-lab-title {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(128px, auto);
  gap: 12px;
  align-items: center;
  min-width: 0;
  padding: 13px 14px 12px;
  background:
    linear-gradient(135deg, rgba(255, 253, 247, 0.95), rgba(250, 236, 212, 0.74)),
    var(--ph-paper);
}

.ph-lab-title-copy {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.ph-lab-kicker {
  width: fit-content;
  margin: 0;
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  font-size: 12px;
  line-height: 1.1;
  font-weight: 950;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.ph-lab-title h2 {
  margin: 0;
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  font-size: clamp(23px, 2.4vw, 31px);
  line-height: 1.12;
  font-weight: 950;
  letter-spacing: -0.045em;
}

.ph-lab-title-copy p:last-child {
  max-width: 650px;
  margin: 0;
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  font-size: 14px;
  line-height: 1.45;
  font-weight: 760;
}

.ph-lab-title-meter {
  display: grid;
  place-items: center;
  gap: 2px;
  min-width: 128px;
  padding: 8px 10px;
  color: var(--ph-ink);
  background: var(--ph-panel);
  border: 1px solid var(--ph-line);
  box-shadow: var(--ph-shadow-soft);
  text-align: center;
}

.ph-lab-title-meter strong {
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  font-size: 25px;
  line-height: 1;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
}

.ph-lab-title-meter span,
.ph-lab-title-meter small {
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  font-size: 11px;
  line-height: 1.15;
  font-weight: 900;
}

.ph-lab-body {
  display: grid;
  grid-template-columns: minmax(300px, 0.92fr) minmax(0, 1.08fr);
  gap: 10px;
  align-items: stretch;
  min-width: 0;
  padding: 12px;
  border-top: 2px solid var(--ph-line);
}

.ph-lab-panel {
  display: grid;
  align-content: start;
  gap: 10px;
  min-width: 0;
  min-height: 100%;
  padding: 11px;
  color: var(--ph-ink);
  background: var(--ph-panel);
  border: 2px solid var(--ph-line);
  border-radius: 0;
  box-shadow: var(--ph-shadow-soft);
}

.ph-lab-panel-head {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--ph-line);
}

.ph-lab-panel-head h3 {
  margin: 0;
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  font-size: 16px;
  line-height: 1.18;
  font-weight: 950;
  letter-spacing: -0.025em;
}

.ph-lab-panel-head p {
  margin: 0;
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  font-size: 12.5px;
  line-height: 1.32;
  font-weight: 760;
}

.ph-lab-field-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  min-width: 0;
}

.ph-lab-field {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.ph-lab-label,
.ph-lab-slider-head span {
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  font-size: 12.5px;
  line-height: 1.1;
  font-weight: 930;
}

.ph-lab-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  min-width: 0;
  border: 1px solid var(--ph-line);
  background: var(--ph-input);
  box-shadow: inset 0 0 0 1px rgba(107, 87, 69, 0.08);
}

.ph-lab-input-row:has(.ph-lab-input:focus-visible) {
  outline: 2px solid var(--ph-amber);
  outline-offset: 2px;
}

.ph-lab-input {
  width: 100% !important;
  min-width: 0 !important;
  min-height: 40px !important;
  margin: 0 !important;
  padding: 8px 10px !important;
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  background: transparent !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  font-size: 17px !important;
  line-height: 1.1 !important;
  font-weight: 950 !important;
  font-variation-settings: "wght" 950;
  font-variant-numeric: tabular-nums;
}

.ph-lab-input::placeholder {
  color: #9f9284 !important;
  -webkit-text-fill-color: #9f9284 !important;
  font-weight: 720 !important;
}

.ph-lab-unit-chip {
  display: grid;
  place-items: center;
  min-width: 42px;
  padding: 0 10px;
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  background: var(--ph-unit);
  border-left: 1px solid var(--ph-line);
  font-size: 12px;
  line-height: 1;
  font-weight: 900;
}

.ph-lab-hint {
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  font-size: 11.5px;
  line-height: 1.28;
  font-weight: 760;
}

.ph-lab-slider-block {
  display: grid;
  gap: 7px;
  min-width: 0;
  padding: 9px;
  background: var(--ph-paper-soft);
  border: 1px solid var(--ph-line);
}

.ph-lab-slider-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.ph-lab-slider-head strong {
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  font-size: 12px;
  line-height: 1;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
}

.ph-lab-slider {
  width: 100%;
  height: 22px;
  margin: 0;
  accent-color: var(--ph-line);
  background: transparent;
  cursor: pointer;
  font-weight: 950 !important;
}

.ph-lab-slider::-webkit-slider-runnable-track {
  height: 8px;
  border: 1px solid var(--ph-line);
  background: linear-gradient(90deg, #eeb5a6 0%, #f2dfaa 40%, #e3efd2 50%, #b8d9e6 72%, #cec4e6 100%);
}

.ph-lab-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  margin-top: -6px;
  border: 2px solid var(--ph-line);
  border-radius: 0;
  background: var(--ph-primary-bg);
  box-shadow: 2px 2px 0 rgba(72, 55, 40, 0.24);
}

.ph-lab-slider::-moz-range-track {
  height: 8px;
  border: 1px solid var(--ph-line);
  background: linear-gradient(90deg, #eeb5a6 0%, #f2dfaa 40%, #e3efd2 50%, #b8d9e6 72%, #cec4e6 100%);
}

.ph-lab-slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: 2px solid var(--ph-line);
  border-radius: 0;
  background: var(--ph-primary-bg);
  box-shadow: 2px 2px 0 rgba(72, 55, 40, 0.24);
}

.ph-lab-scale-labels,
.ph-lab-scale-notes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  color: var(--ph-muted);
  font-size: 11px;
  line-height: 1.12;
  font-weight: 850;
}

.ph-lab-scale-labels span:nth-child(2) {
  text-align: center;
}

.ph-lab-scale-labels span:nth-child(3) {
  text-align: right;
}

.ph-lab-samples {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  min-width: 0;
}

.ph-lab-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  min-width: 0;
}

.ph-lab-chip,
.ph-lab-button,
.ph-lab-copy {
  display: inline-grid !important;
  place-items: center !important;
  min-width: 0 !important;
  min-height: 40px !important;
  margin: 0 !important;
  padding: 8px 9px !important;
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  background: var(--ph-panel) !important;
  border: 1px solid var(--ph-line) !important;
  border-radius: 0 !important;
  box-shadow: var(--ph-shadow-soft) !important;
  font-size: 13px !important;
  line-height: 1.1 !important;
  font-weight: 900 !important;
  text-align: center !important;
  text-decoration: none !important;
  cursor: pointer;
  transition: transform 120ms ease, box-shadow 120ms ease, background-color 120ms ease;
}

.ph-lab-button--primary,
.ph-lab-chip:hover,
.ph-lab-button:hover,
.ph-lab-copy:hover {
  background: var(--ph-primary-bg) !important;
  color: var(--ph-primary-ink) !important;
  -webkit-text-fill-color: var(--ph-primary-ink) !important;
}

.ph-lab-chip:active,
.ph-lab-button:active,
.ph-lab-copy:active {
  transform: translate(1px, 1px);
  box-shadow: 1px 1px 0 rgba(72, 55, 40, 0.16) !important;
}

.ph-lab-chip:focus-visible,
.ph-lab-button:focus-visible,
.ph-lab-copy:focus-visible,
.ph-lab-slider:focus-visible,
.ph-lab-input:focus-visible {
  outline: 2px solid var(--ph-amber) !important;
  outline-offset: 2px !important;
}

.ph-lab-compat-action {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  padding: 0 !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.ph-lab-result-hero {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 13px;
  color: var(--ph-result-ink);
  background: var(--ph-result-accent);
  border: 1px solid var(--ph-line);
  box-shadow: var(--ph-shadow-soft);
  text-align: center;
}

.ph-lab-result-hero span {
  color: inherit !important;
  -webkit-text-fill-color: currentColor !important;
  font-size: 12px;
  line-height: 1;
  font-weight: 900;
}

.ph-lab-result-hero strong {
  color: inherit !important;
  -webkit-text-fill-color: currentColor !important;
  font-size: clamp(38px, 5vw, 58px);
  line-height: 0.95;
  font-weight: 950;
  letter-spacing: -0.055em;
  font-variant-numeric: tabular-nums;
}

.ph-lab-result-hero em {
  justify-self: center;
  min-width: 92px;
  padding: 5px 9px;
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  background: rgba(255, 253, 247, 0.72);
  border: 1px solid var(--ph-line);
  font-size: 12px;
  line-height: 1;
  font-style: normal;
  font-weight: 950;
}

.ph-lab-classification-desc {
  margin: 0;
  min-height: 42px;
  padding: 8px 9px;
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  background: var(--ph-paper-soft);
  border: 1px solid var(--ph-line);
  font-size: 12.5px;
  line-height: 1.35;
  font-weight: 780;
}

.ph-lab-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  min-width: 0;
}

.ph-lab-metric {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 8px;
  color: var(--ph-ink);
  background: var(--ph-paper-soft);
  border: 1px solid var(--ph-line);
}

.ph-lab-metric span {
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  font-size: 11px;
  line-height: 1;
  font-weight: 900;
}

.ph-lab-metric strong {
  min-width: 0;
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  font-size: clamp(14px, 1.4vw, 18px);
  line-height: 1.05;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ph-lab-copy {
  min-height: 34px !important;
  padding: 6px 8px !important;
  font-size: 12px !important;
}

.ph-lab-formula {
  margin: 0;
  padding: 8px 9px;
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  background: var(--ph-paper-soft);
  border: 1px dashed var(--ph-line);
  font-size: 12px;
  line-height: 1.3;
  font-weight: 820;
}

.ph-lab-status {
  min-height: 19px;
  margin: 0;
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  font-size: 12px;
  line-height: 1.3;
  font-weight: 850;
}

.ph-lab-status[data-state="ok"] {
  color: #355733 !important;
  -webkit-text-fill-color: #355733 !important;
}

.ph-lab-status[data-state="error"] {
  color: var(--ph-red) !important;
  -webkit-text-fill-color: var(--ph-red) !important;
}

.ph-lab-scale {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 0 12px 12px;
}

.ph-lab-scale-track {
  position: relative;
  height: 16px;
  border: 1px solid var(--ph-line);
  background: linear-gradient(90deg, #de8e78 0%, #f0c985 35%, #e3efd2 50%, #8dc5d8 72%, #b8a9dd 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 253, 247, 0.52);
}

.ph-lab-scale-marker {
  position: absolute;
  top: -5px;
  width: 10px;
  height: 26px;
  transform: translateX(-50%);
  background: var(--ph-primary-bg);
  border: 2px solid var(--ph-line);
  box-shadow: 2px 2px 0 rgba(72, 55, 40, 0.24);
}

.ph-lab-scale-notes {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 5px;
}

.ph-lab-scale-notes span {
  min-width: 0;
  padding: 6px 5px;
  color: var(--ph-muted) !important;
  -webkit-text-fill-color: var(--ph-muted) !important;
  background: var(--ph-panel);
  border: 1px solid var(--ph-line-soft);
  font-size: 11px;
  line-height: 1.15;
  font-weight: 850;
  text-align: center;
}

.ph-lab-scale-notes strong {
  display: block;
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  font-size: 11px;
  line-height: 1;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
}

body:is([data-scheme="dark"], [data-scheme="inverse"]) {
  --ph-page: #201811;
  --ph-paper: #2b2119;
  --ph-paper-soft: #241c15;
  --ph-panel: #33271d;
  --ph-input: #241c15;
  --ph-ink: #f7ebd8;
  --ph-muted: #f0dfc5;
  --ph-line: #a98b6b;
  --ph-line-soft: rgba(169, 139, 107, 0.48);
  --ph-grid: rgba(229, 196, 139, 0.06);
  --ph-primary-bg: #ead6b8;
  --ph-primary-ink: #21170f;
  --ph-unit: #3b2d21;
  --ph-shadow: 4px 4px 0 rgba(0, 0, 0, 0.34);
  --ph-shadow-soft: 2px 2px 0 rgba(0, 0, 0, 0.24);
  color-scheme: dark;
}

body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-calculator-container[data-ph-tone="acid-strong"] { --ph-result-accent: #5a3028; --ph-result-ink: #f7ebd8; }
body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-calculator-container[data-ph-tone="acid-weak"] { --ph-result-accent: #5a461e; --ph-result-ink: #f7ebd8; }
body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-calculator-container[data-ph-tone="neutral"] { --ph-result-accent: #344a32; --ph-result-ink: #f7ebd8; }
body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-calculator-container[data-ph-tone="base-weak"] { --ph-result-accent: #233c43; --ph-result-ink: #f7ebd8; }
body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-calculator-container[data-ph-tone="base-strong"] { --ph-result-accent: #40385d; --ph-result-ink: #f7ebd8; }

body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-lab-title {
  background:
    linear-gradient(135deg, rgba(51, 39, 29, 0.98), rgba(43, 33, 25, 0.92)),
    var(--ph-paper);
}

body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-lab-input::placeholder {
  color: #b9a894 !important;
  -webkit-text-fill-color: #b9a894 !important;
}

body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-lab-result-hero em {
  color: var(--ph-ink) !important;
  -webkit-text-fill-color: var(--ph-ink) !important;
  background: rgba(36, 28, 21, 0.72);
}

body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-lab-status[data-state="ok"] {
  color: #d8efc8 !important;
  -webkit-text-fill-color: #d8efc8 !important;
}

body:is([data-scheme="dark"], [data-scheme="inverse"]) .ph-lab-status[data-state="error"] {
  color: #f0b4a2 !important;
  -webkit-text-fill-color: #f0b4a2 !important;
}

body[data-scheme="auto"] .ph-calculator-container {
  color: var(--ph-ink);
}

@media (prefers-color-scheme: dark) {
  body[data-scheme="auto"] {
    --ph-page: #201811;
    --ph-paper: #2b2119;
    --ph-paper-soft: #241c15;
    --ph-panel: #33271d;
    --ph-input: #241c15;
    --ph-ink: #f7ebd8;
    --ph-muted: #f0dfc5;
    --ph-line: #a98b6b;
    --ph-line-soft: rgba(169, 139, 107, 0.48);
    --ph-grid: rgba(229, 196, 139, 0.06);
    --ph-primary-bg: #ead6b8;
    --ph-primary-ink: #21170f;
    --ph-unit: #3b2d21;
    --ph-shadow: 4px 4px 0 rgba(0, 0, 0, 0.34);
    --ph-shadow-soft: 2px 2px 0 rgba(0, 0, 0, 0.24);
    color-scheme: dark;
  }

  body[data-scheme="auto"] .ph-calculator-container[data-ph-tone="acid-strong"] { --ph-result-accent: #5a3028; --ph-result-ink: #f7ebd8; }
  body[data-scheme="auto"] .ph-calculator-container[data-ph-tone="acid-weak"] { --ph-result-accent: #5a461e; --ph-result-ink: #f7ebd8; }
  body[data-scheme="auto"] .ph-calculator-container[data-ph-tone="neutral"] { --ph-result-accent: #344a32; --ph-result-ink: #f7ebd8; }
  body[data-scheme="auto"] .ph-calculator-container[data-ph-tone="base-weak"] { --ph-result-accent: #233c43; --ph-result-ink: #f7ebd8; }
  body[data-scheme="auto"] .ph-calculator-container[data-ph-tone="base-strong"] { --ph-result-accent: #40385d; --ph-result-ink: #f7ebd8; }

  body[data-scheme="auto"] .ph-lab-title {
    background:
      linear-gradient(135deg, rgba(51, 39, 29, 0.98), rgba(43, 33, 25, 0.92)),
      var(--ph-paper);
  }

  body[data-scheme="auto"] .ph-lab-input::placeholder {
    color: #b9a894 !important;
    -webkit-text-fill-color: #b9a894 !important;
  }

  body[data-scheme="auto"] .ph-lab-result-hero em {
    color: var(--ph-ink) !important;
    -webkit-text-fill-color: var(--ph-ink) !important;
    background: rgba(36, 28, 21, 0.72);
  }
}

@media (max-width: 860px) {
  body .cs-breadcrumbs,
  body .cs-entry__header,
  body .ph-calculator-container,
  body .entry-content > article {
    width: min(100% - 24px, 900px);
  }

  .ph-lab-title,
  .ph-lab-body {
    grid-template-columns: 1fr;
  }

  .ph-lab-title-meter {
    justify-items: start;
    text-align: left;
  }

  .ph-lab-metric-grid {
    grid-template-columns: 1fr;
  }

  .ph-lab-scale-notes {
    grid-template-columns: repeat(5, minmax(88px, 1fr));
    overflow-x: auto;
    scrollbar-width: thin;
  }
}

@media (max-width: 520px) {
  body .cs-breadcrumbs,
  body .cs-entry__header,
  body .ph-calculator-container,
  body .entry-content > article {
    width: min(100% - 16px, 900px);
  }

  .ph-calculator-container {
    box-shadow: 3px 3px 0 rgba(72, 55, 40, 0.18);
  }

  .ph-lab-title {
    gap: 9px;
    padding: 11px;
  }

  .ph-lab-title h2 {
    font-size: 24px;
  }

  .ph-lab-title-copy p:last-child {
    font-size: 13px;
  }

  .ph-lab-body {
    gap: 9px;
    padding: 10px;
  }

  .ph-lab-panel {
    gap: 9px;
    padding: 10px;
  }

  .ph-lab-samples {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ph-lab-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ph-lab-chip,
  .ph-lab-button {
    min-height: 38px !important;
    padding: 7px 7px !important;
    font-size: 12.5px !important;
  }

  .ph-lab-result-hero {
    padding: 11px;
  }

  .ph-lab-result-hero strong {
    font-size: 42px;
  }

  .ph-lab-scale {
    padding: 0 10px 10px;
  }

  .ph-lab-scale-notes {
    grid-template-columns: 1fr;
    overflow-x: visible;
  }

  .ph-lab-scale-notes span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    text-align: left;
  }
}

@media (max-width: 370px) {
  body .cs-breadcrumbs,
  body .cs-entry__header,
  body .ph-calculator-container,
  body .entry-content > article {
    width: min(100% - 12px, 900px);
  }

  .ph-lab-samples {
    grid-template-columns: 1fr;
  }

  .ph-lab-input {
    font-size: 16px !important;
  }
}
