.pfcr-app,
.pfcr-app * { box-sizing: border-box; }

.pfcr-app {
  --pfcr-bg: #f4f8f7;
  --pfcr-surface: #ffffff;
  --pfcr-surface-2: #eef6f3;
  --pfcr-surface-3: #e8f0ee;
  --pfcr-text: #142322;
  --pfcr-text-2: #3d5451;
  --pfcr-muted: #667b77;
  --pfcr-border: #cadbd6;
  --pfcr-accent: #0d6d61;
  --pfcr-accent-2: #0b4f48;
  --pfcr-focus: #f2c94c;
  --pfcr-success: #147a52;
  --pfcr-warning: #9b5b0d;
  --pfcr-error: #a33a3a;
  --pfcr-neutral: #45666c;
  --pfcr-selected-bg: #dff2ec;
  --pfcr-selected-text: #0c3f38;
  --pfcr-shadow: 0 30px 80px rgba(21, 51, 47, .18);
  margin: 40px auto;
  width: min(1180px, 100%);
  color: var(--pfcr-text) !important;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.pfcr-shell {
  background: var(--pfcr-bg);
  border: 1px solid var(--pfcr-border);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--pfcr-shadow);
}

.pfcr-hero {
  position: relative;
  min-height: 470px;
  isolation: isolate;
  overflow: hidden;
  background: #173c37;
}

.pfcr-hero__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
  z-index: -3;
}

.pfcr-hero__scrim {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(7, 30, 28, .94) 0%, rgba(7, 30, 28, .83) 36%, rgba(7, 30, 28, .42) 63%, rgba(7, 30, 28, .12) 100%),
    linear-gradient(180deg, rgba(0,0,0,.08), rgba(0,0,0,.18));
}

.pfcr-hero__content {
  width: min(690px, 65%);
  padding: 52px 54px 48px;
  color: #fff !important;
  text-shadow: 0 2px 18px rgba(0,0,0,.28);
}

.pfcr-badges, .pfcr-chips { display: flex; flex-wrap: wrap; gap: 10px; }
.pfcr-badges span,
.pfcr-chips span {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 7px 11px;
  border-radius: 999px;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.26);
  color: #ffffff !important;
  font-size: 13px;
  font-weight: 700;
  backdrop-filter: blur(8px);
}
.pfcr-eyebrow { margin: 24px 0 8px; color: #d8f1ea !important; font-size: 13px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.pfcr-hero h2 { margin: 0 !important; color: #fff !important; font-size: 64px !important; font-size: clamp(44px, 6vw, 76px) !important; line-height: .96 !important; letter-spacing: -.045em; font-weight: 900 !important; max-width: 720px; }
.pfcr-hero__lede { margin: 20px 0 20px; max-width: 650px; color: #edf7f4 !important; font-size: 18px; line-height: 1.55; font-weight: 600; }

.pfcr-main { display: grid; grid-template-columns: 310px minmax(0, 1fr); gap: 24px; padding: 28px; align-items: start; }
.pfcr-guide { position: sticky; top: 20px; background: var(--pfcr-surface); border: 1px solid var(--pfcr-border); border-radius: 20px; padding: 22px; color: var(--pfcr-text) !important; }
.pfcr-guide h3, .pfcr-section h3, .pfcr-result-card h3 { color: var(--pfcr-text) !important; margin: 0 0 8px !important; font-size: 20px !important; line-height: 1.25; font-weight: 850 !important; }
.pfcr-guide p, .pfcr-section p, .pfcr-result-card p, .pfcr-result-card li { color: var(--pfcr-text-2) !important; }
.pfcr-guide > p { margin: 0 0 18px; line-height: 1.6; }
.pfcr-guide__rule { display: grid; grid-template-columns: 78px 1fr; gap: 12px; align-items: center; padding: 14px 0; border-top: 1px solid var(--pfcr-border); color: var(--pfcr-text-2) !important; }
.pfcr-guide__num { display: grid; place-items: center; height: 56px; border-radius: 16px; background: var(--pfcr-surface-2); color: var(--pfcr-accent-2) !important; font-size: 24px; font-weight: 900; }
.pfcr-guide__note { padding: 12px; border-radius: 14px; background: #fff8e6; border: 1px solid #ecdba9; color: #5d4b1e !important; font-size: 13px; }

.pfcr-formarea { min-width: 0; }
.pfcr-form, .pfcr-results { display: grid; gap: 18px; }
.pfcr-results[hidden] { display: none !important; }
.pfcr-section, .pfcr-result-card { background: var(--pfcr-surface); border: 1px solid var(--pfcr-border); border-radius: 20px; padding: 22px; }
.pfcr-section__head { display: flex; gap: 13px; align-items: flex-start; margin-bottom: 18px; }
.pfcr-section__head p { margin: 3px 0 0; font-size: 14px; }
.pfcr-step { flex: 0 0 34px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: var(--pfcr-accent); color: #fff !important; font-weight: 900; }

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

.pfcr-field { display: grid; gap: 7px; color: var(--pfcr-text) !important; font-weight: 800; font-size: 14px; }
.pfcr-field input,
.pfcr-field select,
.pfcr-field textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--pfcr-border) !important;
  border-radius: 12px !important;
  background: #ffffff !important;
  color: #152623 !important;
  padding: 11px 12px !important;
  font: inherit !important;
  font-weight: 650 !important;
  box-shadow: none !important;
}
.pfcr-field input::placeholder, .pfcr-field textarea::placeholder { color: #7a8c88 !important; opacity: 1; }
.pfcr-field select option { background: #ffffff !important; color: #152623 !important; }
.pfcr-field input:focus,
.pfcr-field select:focus,
.pfcr-option:focus-within,
.pfcr-button:focus-visible,
.pfcr-inline-link:focus-visible { outline: 3px solid var(--pfcr-focus) !important; outline-offset: 2px; }

.pfcr-fieldset { border: 0; padding: 0; margin: 20px 0 0; min-width: 0; }
.pfcr-fieldset legend { color: var(--pfcr-text) !important; font-size: 14px; font-weight: 850; margin-bottom: 10px; }
.pfcr-options { display: grid; gap: 10px; }
.pfcr-options--4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.pfcr-option { position: relative; display: block; min-height: 118px; padding: 14px; border: 1px solid var(--pfcr-border); border-radius: 16px; background: #ffffff; color: var(--pfcr-text) !important; cursor: pointer; transition: .18s ease; }
.pfcr-option:hover { transform: translateY(-1px); border-color: #8ab5aa; }
.pfcr-option.is-selected { background: var(--pfcr-selected-bg) !important; border-color: var(--pfcr-accent) !important; color: var(--pfcr-selected-text) !important; box-shadow: inset 0 0 0 1px var(--pfcr-accent); }
.pfcr-option input { position: absolute; opacity: 0; pointer-events: none; }
.pfcr-option span { display: grid; gap: 6px; }
.pfcr-option strong { color: inherit !important; font-size: 14px; line-height: 1.25; }
.pfcr-option small { color: var(--pfcr-muted) !important; font-size: 12px; line-height: 1.4; font-weight: 600; }
.pfcr-option.is-selected small { color: #315f57 !important; }
.pfcr-options--compact .pfcr-option { min-height: 102px; }

.pfcr-serving-row { display: grid; grid-template-columns: minmax(160px, 220px) 1fr; gap: 14px; align-items: end; }
.pfcr-serving-note { min-height: 48px; display: flex; align-items: center; padding: 11px 13px; border-radius: 12px; background: var(--pfcr-surface-2); color: var(--pfcr-text-2) !important; font-size: 13px; line-height: 1.45; }
.pfcr-field--dv > div { display: flex; align-items: center; border: 1px solid var(--pfcr-border); border-radius: 12px; background: #fff; overflow: hidden; }
.pfcr-field--dv input { border: 0 !important; border-radius: 0 !important; }
.pfcr-field--dv b { padding: 0 10px; white-space: nowrap; color: var(--pfcr-muted) !important; font-size: 12px; }

.pfcr-actions, .pfcr-result-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.pfcr-button { min-height: 48px; border-radius: 12px !important; padding: 12px 18px !important; border: 1px solid transparent !important; font: inherit !important; font-weight: 850 !important; cursor: pointer; transition: .18s ease; text-decoration: none !important; }
.pfcr-button:hover { transform: translateY(-1px); }
.pfcr-button--primary { background: var(--pfcr-accent) !important; color: #fff !important; border-color: var(--pfcr-accent) !important; }
.pfcr-button--ghost { background: var(--pfcr-surface) !important; color: var(--pfcr-text) !important; border-color: var(--pfcr-border) !important; }
.pfcr-button--secondary { background: #173f47 !important; color: #fff !important; border-color: #173f47 !important; }

.pfcr-results { margin-top: 22px; }
.pfcr-result-card { width: 100%; }
.pfcr-result-card--main { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; background: linear-gradient(135deg, #e4f5ef, #f7fbfa); border-color: #a9d6c9; }
.pfcr-result-kicker { margin: 0 0 6px; color: var(--pfcr-accent) !important; font-size: 12px; text-transform: uppercase; letter-spacing: .12em; font-weight: 900; }
.pfcr-result-title { margin: 0 !important; font-size: 30px !important; line-height: 1.05 !important; color: #0d3e37 !important; }
.pfcr-result-summary { margin: 10px 0 0; font-size: 16px; line-height: 1.6; }
.pfcr-result-badge { padding: 10px 12px; border-radius: 999px; background: #0d6d61; color: #fff !important; font-weight: 850; white-space: nowrap; }
.pfcr-scan-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 10px; margin-top: 14px; }
.pfcr-scan { padding: 13px; border: 1px solid var(--pfcr-border); border-radius: 14px; background: var(--pfcr-surface-2); }
.pfcr-scan strong { display: block; color: var(--pfcr-text) !important; font-size: 13px; }
.pfcr-scan span { display: block; margin-top: 7px; color: var(--pfcr-text-2) !important; font-size: 13px; line-height: 1.45; }
.pfcr-scan[data-level="high"] { background: #fff2e3; border-color: #e4bd87; }
.pfcr-scan[data-level="low"] { background: #e9f7ef; border-color: #add9c0; }
.pfcr-scan[data-level="moderate"] { background: #f3f6f6; }
.pfcr-scan[data-level="none"] { background: #f8faf9; border-style: dashed; }
.pfcr-reasons { margin: 10px 0 0 20px; padding: 0; line-height: 1.65; }
.pfcr-next-actions { display: grid; gap: 10px; margin-top: 12px; }
.pfcr-next-actions p { margin: 0; padding: 12px 14px; background: var(--pfcr-surface-2); border-radius: 12px; line-height: 1.55; }
.pfcr-inline-link { color: var(--pfcr-accent-2) !important; font-weight: 800; text-decoration: underline !important; text-underline-offset: 3px; }
.pfcr-footer { padding: 18px 28px 24px; color: var(--pfcr-text-2) !important; font-size: 13px; line-height: 1.55; border-top: 1px solid var(--pfcr-border); background: var(--pfcr-surface-3); }
.pfcr-footer strong { color: var(--pfcr-text) !important; }

@media (max-width: 980px) {
  .pfcr-main { grid-template-columns: 1fr; }
  .pfcr-guide { position: static; }
  .pfcr-options--4, .pfcr-grid--4 { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .pfcr-hero__content { width: min(760px, 76%); }
}

@media (max-width: 680px) {
  .pfcr-shell { border-radius: 20px; }
  .pfcr-hero { min-height: 560px; }
  .pfcr-hero__image { object-position: 64% center; }
  .pfcr-hero__scrim { background: linear-gradient(180deg, rgba(7,30,28,.88) 0%, rgba(7,30,28,.70) 58%, rgba(7,30,28,.78) 100%); }
  .pfcr-hero__content { width: 100%; padding: 30px 22px; }
  .pfcr-hero h2 { font-size: clamp(39px, 13vw, 60px) !important; }
  .pfcr-hero__lede { font-size: 16px; }
  .pfcr-main { padding: 16px; }
  .pfcr-grid--2, .pfcr-grid--4, .pfcr-options--4, .pfcr-serving-row, .pfcr-scan-grid { grid-template-columns: 1fr; }
  .pfcr-option { min-height: auto; }
  .pfcr-result-card--main { grid-template-columns: 1fr; }
  .pfcr-result-badge { justify-self: start; }
  .pfcr-actions, .pfcr-result-actions { align-items: stretch; }
  .pfcr-button { width: 100%; }
}

@media (prefers-color-scheme: dark) {
  .pfcr-app {
    --pfcr-bg: #0d1716;
    --pfcr-surface: #152321;
    --pfcr-surface-2: #1c2c29;
    --pfcr-surface-3: #111d1b;
    --pfcr-text: #f3f8f6;
    --pfcr-text-2: #d4e1de;
    --pfcr-muted: #a9bdb8;
    --pfcr-border: #33514b;
    --pfcr-accent: #3ec0aa;
    --pfcr-accent-2: #92e1d3;
    --pfcr-selected-bg: #20463f;
    --pfcr-selected-text: #f5fffc;
  }
  .pfcr-field input,
  .pfcr-field select,
  .pfcr-field textarea,
  .pfcr-field select option,
  .pfcr-option,
  .pfcr-field--dv > div { background: #101c1a !important; color: #f4fbf8 !important; }
  .pfcr-field input::placeholder, .pfcr-field textarea::placeholder { color: #92a7a2 !important; }
  .pfcr-guide__note { background: #302914; border-color: #695f2e; color: #f3e5aa !important; }
  .pfcr-result-card--main { background: linear-gradient(135deg, #153c35, #172522); border-color: #397f70; }
  .pfcr-result-title { color: #f1fffb !important; }
  .pfcr-scan[data-level="high"] { background: #3a2b1a; border-color: #76572e; }
  .pfcr-scan[data-level="low"] { background: #17372a; border-color: #316c51; }
}

html[data-theme="dark"] .pfcr-app,
.dark-mode .pfcr-app,
body.dark .pfcr-app {
  --pfcr-bg: #0d1716;
  --pfcr-surface: #152321;
  --pfcr-surface-2: #1c2c29;
  --pfcr-surface-3: #111d1b;
  --pfcr-text: #f3f8f6;
  --pfcr-text-2: #d4e1de;
  --pfcr-muted: #a9bdb8;
  --pfcr-border: #33514b;
  --pfcr-accent: #3ec0aa;
  --pfcr-accent-2: #92e1d3;
  --pfcr-selected-bg: #20463f;
  --pfcr-selected-text: #f5fffc;
}
html[data-theme="dark"] .pfcr-app .pfcr-field input,
html[data-theme="dark"] .pfcr-app .pfcr-field select,
html[data-theme="dark"] .pfcr-app .pfcr-field select option,
html[data-theme="dark"] .pfcr-app .pfcr-option,
html[data-theme="dark"] .pfcr-app .pfcr-field--dv > div,
.dark-mode .pfcr-app .pfcr-field input,
.dark-mode .pfcr-app .pfcr-field select,
.dark-mode .pfcr-app .pfcr-field select option,
.dark-mode .pfcr-app .pfcr-option,
.dark-mode .pfcr-app .pfcr-field--dv > div,
body.dark .pfcr-app .pfcr-field input,
body.dark .pfcr-app .pfcr-field select,
body.dark .pfcr-app .pfcr-field select option,
body.dark .pfcr-app .pfcr-option,
body.dark .pfcr-app .pfcr-field--dv > div { background: #101c1a !important; color: #f4fbf8 !important; }

/* Explicit dark-theme surfaces for themes that toggle a class/data attribute instead of OS dark mode. */
html[data-theme="dark"] .pfcr-app .pfcr-guide__note,
.dark-mode .pfcr-app .pfcr-guide__note,
body.dark .pfcr-app .pfcr-guide__note {
  background: #302914 !important;
  border-color: #695f2e !important;
  color: #f3e5aa !important;
}
html[data-theme="dark"] .pfcr-app .pfcr-result-card--main,
.dark-mode .pfcr-app .pfcr-result-card--main,
body.dark .pfcr-app .pfcr-result-card--main {
  background: linear-gradient(135deg, #153c35, #172522) !important;
  border-color: #397f70 !important;
}
html[data-theme="dark"] .pfcr-app .pfcr-result-title,
.dark-mode .pfcr-app .pfcr-result-title,
body.dark .pfcr-app .pfcr-result-title {
  color: #f1fffb !important;
}
html[data-theme="dark"] .pfcr-app .pfcr-scan[data-level="high"],
.dark-mode .pfcr-app .pfcr-scan[data-level="high"],
body.dark .pfcr-app .pfcr-scan[data-level="high"] {
  background: #3a2b1a !important;
  border-color: #76572e !important;
}
html[data-theme="dark"] .pfcr-app .pfcr-scan[data-level="low"],
.dark-mode .pfcr-app .pfcr-scan[data-level="low"],
body.dark .pfcr-app .pfcr-scan[data-level="low"] {
  background: #17372a !important;
  border-color: #316c51 !important;
}
html[data-theme="dark"] .pfcr-app .pfcr-scan[data-level="moderate"],
.dark-mode .pfcr-app .pfcr-scan[data-level="moderate"],
body.dark .pfcr-app .pfcr-scan[data-level="moderate"],
html[data-theme="dark"] .pfcr-app .pfcr-scan[data-level="none"],
.dark-mode .pfcr-app .pfcr-scan[data-level="none"],
body.dark .pfcr-app .pfcr-scan[data-level="none"] {
  background: #101c1a !important;
  border-color: #33514b !important;
}

/* =========================================================
   v1.1.0 readability + responsive two-column refinement
   The experience now responds to its OWN content width, not
   merely the browser viewport. This prevents a squeezed
   two-column layout inside a WordPress article + sidebar.
   ========================================================= */

.pfcr-shell {
  container-type: inline-size;
  container-name: pfcrshell;
}

/* Wide experience: deliberate 33/67 split, not 50/50. */
.pfcr-main {
  grid-template-columns: minmax(250px, 32%) minmax(0, 1fr);
  gap: 30px;
  padding: 32px;
}

.pfcr-guide {
  padding: 26px;
  border-radius: 22px;
  box-shadow: 0 12px 34px rgba(19, 55, 49, .08);
}

.pfcr-guide h3,
.pfcr-section h3,
.pfcr-result-card h3 {
  font-size: 22px !important;
  line-height: 1.22 !important;
  letter-spacing: -.015em;
}

.pfcr-guide > p {
  font-size: 16px;
  line-height: 1.7;
}

.pfcr-guide__rules {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin: 4px 0 16px;
}

.pfcr-guide__rule {
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 14px;
  padding: 16px 0;
  font-size: 15px;
  line-height: 1.55;
}

.pfcr-guide__rule strong {
  color: var(--pfcr-text) !important;
  font-size: 16px;
}

.pfcr-guide__num {
  height: 60px;
  font-size: 25px;
  border: 1px solid var(--pfcr-border);
}

.pfcr-guide__note {
  padding: 14px 15px;
  font-size: 14px;
  line-height: 1.55;
}

.pfcr-section,
.pfcr-result-card {
  padding: 26px;
  border-radius: 22px;
}

.pfcr-section__head {
  gap: 14px;
  margin-bottom: 22px;
}

.pfcr-section__head p {
  margin-top: 5px;
  font-size: 15px;
  line-height: 1.55;
}

.pfcr-step {
  flex-basis: 40px;
  width: 40px;
  height: 40px;
  font-size: 17px;
}

.pfcr-field,
.pfcr-fieldset legend {
  font-size: 15px;
  line-height: 1.4;
}

.pfcr-fieldset legend {
  margin-bottom: 12px;
}

.pfcr-field input,
.pfcr-field select,
.pfcr-field textarea {
  min-height: 52px;
  padding: 12px 14px !important;
  font-size: 15px !important;
  line-height: 1.35 !important;
}

/* Four choices are intentionally rendered as a readable 2 x 2 grid. */
.pfcr-options--4 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.pfcr-option,
.pfcr-options--compact .pfcr-option {
  min-height: 112px;
  padding: 18px;
  border-width: 1.5px;
  border-radius: 17px;
}

.pfcr-option span {
  gap: 8px;
}

.pfcr-option strong {
  font-size: 16px;
  line-height: 1.3;
  font-weight: 850;
}

.pfcr-option small {
  font-size: 14px;
  line-height: 1.5;
  font-weight: 650;
  color: var(--pfcr-text-2) !important;
}

.pfcr-option.is-selected {
  box-shadow: inset 0 0 0 2px var(--pfcr-accent), 0 8px 20px rgba(13, 109, 97, .10);
}

.pfcr-option.is-selected::after {
  content: "Selected";
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--pfcr-accent);
  color: #fff !important;
  font-size: 11px;
  line-height: 1;
  font-weight: 900;
  letter-spacing: .03em;
}

.pfcr-option.is-selected strong,
.pfcr-option.is-selected small {
  padding-right: 62px;
}

.pfcr-serving-note {
  min-height: 52px;
  padding: 12px 15px;
  font-size: 14px;
  line-height: 1.55;
}

/* Label values also stay comfortably readable. */
.pfcr-grid--4,
.pfcr-scan-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.pfcr-field--dv b {
  font-size: 13px;
  padding: 0 12px;
}

.pfcr-button {
  min-height: 52px;
  padding: 13px 20px !important;
  font-size: 15px !important;
}

.pfcr-result-summary,
.pfcr-result-card li,
.pfcr-next-actions p {
  font-size: 15px;
}

.pfcr-scan {
  padding: 16px;
}

.pfcr-scan strong {
  font-size: 15px;
}

.pfcr-scan span {
  font-size: 14px;
  line-height: 1.5;
}

/* Component-width breakpoint: fixes the exact WordPress + sidebar case. */
@container pfcrshell (max-width: 900px) {
  .pfcr-main {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 22px;
  }

  .pfcr-guide {
    position: static;
  }

  .pfcr-guide__rules {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .pfcr-guide__rule {
    border: 1px solid var(--pfcr-border);
    border-radius: 16px;
    padding: 14px;
  }

  .pfcr-options--4,
  .pfcr-grid--4,
  .pfcr-scan-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@container pfcrshell (max-width: 620px) {
  .pfcr-main {
    padding: 16px;
  }

  .pfcr-guide,
  .pfcr-section,
  .pfcr-result-card {
    padding: 20px;
  }

  .pfcr-guide__rules,
  .pfcr-grid--2,
  .pfcr-grid--4,
  .pfcr-options--4,
  .pfcr-serving-row,
  .pfcr-scan-grid,
  .pfcr-result-card--main {
    grid-template-columns: 1fr;
  }

  .pfcr-option,
  .pfcr-options--compact .pfcr-option {
    min-height: 0;
  }

  .pfcr-option.is-selected strong,
  .pfcr-option.is-selected small {
    padding-right: 0;
  }

  .pfcr-option.is-selected::after {
    position: static;
    justify-self: start;
    width: max-content;
    margin-top: 8px;
  }
}

/* Dark-mode selected-state helper text must remain explicit and obvious. */
@media (prefers-color-scheme: dark) {
  .pfcr-option small,
  .pfcr-option.is-selected small { color: #d5e6e1 !important; }
}

html[data-theme="dark"] .pfcr-app .pfcr-option small,
html[data-theme="dark"] .pfcr-app .pfcr-option.is-selected small,
.dark-mode .pfcr-app .pfcr-option small,
.dark-mode .pfcr-app .pfcr-option.is-selected small,
body.dark .pfcr-app .pfcr-option small,
body.dark .pfcr-app .pfcr-option.is-selected small {
  color: #d5e6e1 !important;
}

/* =========================================================
   v1.2.0: ACTUAL COMPONENT-WIDTH LAYOUT GUARD
   JS adds .pfcr-is-compact / .pfcr-is-narrow from the
   rendered shortcode width. This deliberately overrides
   viewport-based WordPress/theme breakpoints.
   ========================================================= */

.pfcr-app.pfcr-is-compact .pfcr-main {
  grid-template-columns: 1fr !important;
  gap: 20px !important;
  padding: 22px !important;
}

.pfcr-app.pfcr-is-compact .pfcr-guide {
  position: static !important;
  top: auto !important;
  width: 100% !important;
}

.pfcr-app.pfcr-is-compact .pfcr-guide__rules {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

.pfcr-app.pfcr-is-compact .pfcr-guide__rule {
  border: 1px solid var(--pfcr-border) !important;
  border-radius: 16px !important;
  padding: 14px !important;
}

.pfcr-app.pfcr-is-compact .pfcr-options--4 {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 14px !important;
}

.pfcr-app.pfcr-is-compact .pfcr-grid--4,
.pfcr-app.pfcr-is-compact .pfcr-scan-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.pfcr-app.pfcr-is-compact .pfcr-serving-row {
  grid-template-columns: minmax(170px, 220px) minmax(0, 1fr) !important;
}

/* Option cards: selected state must be unmistakable and text must stay obvious. */
.pfcr-app .pfcr-option {
  min-width: 0 !important;
}

.pfcr-app .pfcr-option strong {
  font-size: 16px !important;
  line-height: 1.28 !important;
  font-weight: 850 !important;
}

.pfcr-app .pfcr-option small {
  font-size: 14px !important;
  line-height: 1.5 !important;
  font-weight: 650 !important;
}

.pfcr-app .pfcr-option.is-selected {
  background: #0d6d61 !important;
  border-color: #61d2bf !important;
  box-shadow: inset 0 0 0 2px #61d2bf, 0 7px 18px rgba(3, 38, 33, .18) !important;
  color: #ffffff !important;
}

.pfcr-app .pfcr-option.is-selected strong,
.pfcr-app .pfcr-option.is-selected small {
  color: #ffffff !important;
}

.pfcr-app .pfcr-option.is-selected::after {
  content: "Selected";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
  min-height: 24px;
  width: max-content;
  padding: 4px 9px;
  border-radius: 999px;
  background: #ffffff !important;
  color: #0b554b !important;
  font-size: 11px !important;
  line-height: 1 !important;
  font-weight: 900 !important;
  letter-spacing: .02em;
}

/* Narrow shortcode: no squeezed two-column UI anywhere. */
.pfcr-app.pfcr-is-narrow .pfcr-main {
  padding: 14px !important;
  gap: 14px !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-guide,
.pfcr-app.pfcr-is-narrow .pfcr-section,
.pfcr-app.pfcr-is-narrow .pfcr-result-card {
  padding: 18px !important;
  border-radius: 18px !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-guide__rules,
.pfcr-app.pfcr-is-narrow .pfcr-grid--2,
.pfcr-app.pfcr-is-narrow .pfcr-grid--4,
.pfcr-app.pfcr-is-narrow .pfcr-options--4,
.pfcr-app.pfcr-is-narrow .pfcr-serving-row,
.pfcr-app.pfcr-is-narrow .pfcr-scan-grid,
.pfcr-app.pfcr-is-narrow .pfcr-result-card--main {
  grid-template-columns: 1fr !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-guide__rule {
  grid-template-columns: 72px minmax(0, 1fr) !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-option,
.pfcr-app.pfcr-is-narrow .pfcr-options--compact .pfcr-option {
  min-height: 0 !important;
  padding: 16px !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-section__head {
  margin-bottom: 16px !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-section h3,
.pfcr-app.pfcr-is-narrow .pfcr-guide h3,
.pfcr-app.pfcr-is-narrow .pfcr-result-card h3 {
  font-size: 20px !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-section__head p,
.pfcr-app.pfcr-is-narrow .pfcr-guide > p,
.pfcr-app.pfcr-is-narrow .pfcr-serving-note,
.pfcr-app.pfcr-is-narrow .pfcr-result-summary,
.pfcr-app.pfcr-is-narrow .pfcr-result-card li,
.pfcr-app.pfcr-is-narrow .pfcr-next-actions p {
  font-size: 15px !important;
  line-height: 1.6 !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-field,
.pfcr-app.pfcr-is-narrow .pfcr-fieldset legend {
  font-size: 15px !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-field input,
.pfcr-app.pfcr-is-narrow .pfcr-field select,
.pfcr-app.pfcr-is-narrow .pfcr-field textarea {
  min-height: 52px !important;
  font-size: 16px !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-button {
  width: 100% !important;
  min-height: 54px !important;
  font-size: 16px !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-actions,
.pfcr-app.pfcr-is-narrow .pfcr-result-actions {
  align-items: stretch !important;
}

/* Protect selected text in every supported dark-mode pattern. */
@media (prefers-color-scheme: dark) {
  .pfcr-app .pfcr-option.is-selected,
  .pfcr-app .pfcr-option.is-selected strong,
  .pfcr-app .pfcr-option.is-selected small {
    color: #ffffff !important;
  }
}

html[data-theme="dark"] .pfcr-app .pfcr-option.is-selected,
html[data-theme="dark"] .pfcr-app .pfcr-option.is-selected strong,
html[data-theme="dark"] .pfcr-app .pfcr-option.is-selected small,
.dark-mode .pfcr-app .pfcr-option.is-selected,
.dark-mode .pfcr-app .pfcr-option.is-selected strong,
.dark-mode .pfcr-app .pfcr-option.is-selected small,
body.dark .pfcr-app .pfcr-option.is-selected,
body.dark .pfcr-app .pfcr-option.is-selected strong,
body.dark .pfcr-app .pfcr-option.is-selected small {
  color: #ffffff !important;
}


/* =========================================================
   v1.3.0 RESULT-CARD CONTRAST HARDENING
   Fixes pale/white label-scan cards receiving light text when
   the OS is dark but the WordPress theme does not expose a
   matching dark-mode class. Base scan text is now explicitly
   dark on light surfaces; every dark-mode path then explicitly
   flips both the surface AND all text to high-contrast colors.
   ========================================================= */

/* Light/default safety: never inherit white text into a light scan card. */
.pfcr-app .pfcr-scan,
.pfcr-app .pfcr-scan[data-level="none"],
.pfcr-app .pfcr-scan[data-level="moderate"] {
  background: #f7faf9 !important;
  border-color: #c8d8d3 !important;
  color: #132b27 !important;
}

.pfcr-app .pfcr-scan strong,
.pfcr-app .pfcr-scan span,
.pfcr-app .pfcr-scan b {
  color: #132b27 !important;
  opacity: 1 !important;
}

.pfcr-app .pfcr-scan span {
  color: #405a55 !important;
}

.pfcr-app .pfcr-scan[data-level="high"] {
  background: #fff1df !important;
  border-color: #d9a969 !important;
}

.pfcr-app .pfcr-scan[data-level="low"] {
  background: #e9f7ef !important;
  border-color: #9ecfb2 !important;
}

/* OS dark mode: explicit surface AND text, including NONE/MODERATE. */
@media (prefers-color-scheme: dark) {
  .pfcr-app .pfcr-scan,
  .pfcr-app .pfcr-scan[data-level="none"],
  .pfcr-app .pfcr-scan[data-level="moderate"] {
    background: #182724 !important;
    border-color: #42625b !important;
    color: #f7fffc !important;
  }

  .pfcr-app .pfcr-scan[data-level="high"] {
    background: #352719 !important;
    border-color: #9a713d !important;
  }

  .pfcr-app .pfcr-scan[data-level="low"] {
    background: #17372b !important;
    border-color: #458669 !important;
  }

  .pfcr-app .pfcr-scan strong,
  .pfcr-app .pfcr-scan span,
  .pfcr-app .pfcr-scan b {
    color: #f7fffc !important;
    opacity: 1 !important;
    text-shadow: none !important;
  }

  .pfcr-app .pfcr-scan span {
    color: #dbe9e5 !important;
  }
}

/* WordPress/Foxiz dark-class variants: same explicit protection. */
html[data-theme="dark"] .pfcr-app .pfcr-scan,
.dark-mode .pfcr-app .pfcr-scan,
body.dark .pfcr-app .pfcr-scan,
html[data-theme="dark"] .pfcr-app .pfcr-scan[data-level="none"],
.dark-mode .pfcr-app .pfcr-scan[data-level="none"],
body.dark .pfcr-app .pfcr-scan[data-level="none"],
html[data-theme="dark"] .pfcr-app .pfcr-scan[data-level="moderate"],
.dark-mode .pfcr-app .pfcr-scan[data-level="moderate"],
body.dark .pfcr-app .pfcr-scan[data-level="moderate"] {
  background: #182724 !important;
  border-color: #42625b !important;
  color: #f7fffc !important;
}

html[data-theme="dark"] .pfcr-app .pfcr-scan[data-level="high"],
.dark-mode .pfcr-app .pfcr-scan[data-level="high"],
body.dark .pfcr-app .pfcr-scan[data-level="high"] {
  background: #352719 !important;
  border-color: #9a713d !important;
}

html[data-theme="dark"] .pfcr-app .pfcr-scan[data-level="low"],
.dark-mode .pfcr-app .pfcr-scan[data-level="low"],
body.dark .pfcr-app .pfcr-scan[data-level="low"] {
  background: #17372b !important;
  border-color: #458669 !important;
}

html[data-theme="dark"] .pfcr-app .pfcr-scan strong,
html[data-theme="dark"] .pfcr-app .pfcr-scan span,
html[data-theme="dark"] .pfcr-app .pfcr-scan b,
.dark-mode .pfcr-app .pfcr-scan strong,
.dark-mode .pfcr-app .pfcr-scan span,
.dark-mode .pfcr-app .pfcr-scan b,
body.dark .pfcr-app .pfcr-scan strong,
body.dark .pfcr-app .pfcr-scan span,
body.dark .pfcr-app .pfcr-scan b {
  color: #f7fffc !important;
  opacity: 1 !important;
  text-shadow: none !important;
}

html[data-theme="dark"] .pfcr-app .pfcr-scan span,
.dark-mode .pfcr-app .pfcr-scan span,
body.dark .pfcr-app .pfcr-scan span {
  color: #dbe9e5 !important;
}

/* Make the result section easier to scan at article-column width. */
.pfcr-app .pfcr-result-card > h3 {
  margin-bottom: 14px !important;
}

.pfcr-app .pfcr-scan {
  min-height: 118px;
  padding: 18px !important;
}

.pfcr-app .pfcr-scan strong {
  font-size: 16px !important;
  line-height: 1.3 !important;
  font-weight: 900 !important;
}

.pfcr-app .pfcr-scan span {
  margin-top: 9px !important;
  font-size: 15px !important;
  line-height: 1.5 !important;
  font-weight: 650 !important;
}

.pfcr-app .pfcr-scan span b {
  font-size: 16px !important;
  font-weight: 900 !important;
}

.pfcr-app.pfcr-is-narrow .pfcr-scan {
  min-height: 0 !important;
}
