/* OfficeCalculator.Net v155 — shared calculator palette, fields and result contrast. */

/* Keep the palette local to calculator workspaces so articles and other pages are unaffected. */
:where(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) {
  --oc-primary:#285f90;
  --oc-primary-2:#2d6b9e;
  --oc-primary-3:#153a57;
  --oc-accent:#285f90;
  --oc-accent-soft:#eaf2f8;
  --oc-bg:#f2f6fa;
  --oc-surface:#ffffff;
  --oc-surface-2:#edf3f8;
  --oc-text:#152a40;
  --oc-muted:#40566d;
  --oc-border:#9bb1c5;
  --oc-danger:#942b2b;
  --r47-bg:#f1f5f9;
  --r47-surface:#ffffff;
  --r47-soft:#edf3f8;
  --r47-strong:#dfe9f2;
  --r47-text:#152a40;
  --r47-muted:#40566d;
  --r47-line:#9bb1c5;
  --r47-primary:#285f90;
  --r47-primary-hover:#1b4a73;
  --r47-primary-soft:#e5eff7;
  --r47-love:#285f90;
  --r47-love-soft:#eaf2f8;
  --r47-shadow:0 10px 26px rgba(19,54,82,.10);
  --oc30-ink:#152a40;
  --oc30-muted:#40566d;
  --oc30-line:#9bb1c5;
  --oc30-panel:#ffffff;
  --oc30-panel-2:#edf3f8;
  --oc-v97-result-border:#9bb1c5;
  --oc-v97-result-bg:linear-gradient(135deg,#edf3f8,#ffffff);
  --oc-v97-result-shadow:0 10px 26px rgba(19,54,82,.09);
  --oc-v97-text:#152a40;
  --oc-v97-muted:#40566d;
  --oc-v97-line:#9bb1c5;
  --oc-v97-soft:#edf3f8;
  --oc-v97-primary:#285f90;
}

body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input),
body[data-oc-workspace="stable-v30"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) {
  color:#152a40;
  border-color:#9bb1c5 !important;
  background-color:#ffffff !important;
}

body[data-oc-workspace="stable-v30"] .cal-section,
body[data-oc-workspace="stable-v30"] .oc-r47-tool,
body[data-oc-workspace="stable-v30"] .oc-adv-tool {
  box-shadow:0 10px 26px rgba(19,54,82,.09) !important;
}

/* Calm blue page headers unify the agriculture, farm economics and rebuilt tools. */
.agri-hero,.fe-hero {
  color:#152a40;
  background:linear-gradient(135deg,#eaf2f8,#f7fafd) !important;
  border-color:#9bb1c5 !important;
}
.agri-hero h1,.fe-hero h1,.fe-workspace-head h2,.fe-content-card h2,
.agri-info h2,.oc-r47-head h2,.oc-adv-head h2 { color:#173b59 !important; }
.agri-kicker,.fe-kicker,.oc-r47-eyebrow,.oc-adv-eyebrow { color:#285f90 !important; }
.agri-badges span,.fe-badges span { color:#25445f; border-color:#a7bbcd; background:#ffffff; }
.oc-r47-hero,.oc-r47-content-card,.oc-adv-content-card,.fe-content-card,.agri-info {
  color:#152a40;
  border-color:#9bb1c5 !important;
  background:#ffffff !important;
}
.oc-r47-hero { background:linear-gradient(135deg,#eaf2f8,#f7fafd) !important; }
.oc-r47-trust span,.oc-r47-private,.oc-adv-private,.fe-private {
  color:#40566d !important;
  background:#edf3f8 !important;
  border-color:#9bb1c5 !important;
}
.oc-r47-related-card,.agri-related a,.fe-related-card {
  color:#152a40 !important;
  background:#ffffff !important;
  border-color:#9bb1c5 !important;
}
.oc-r47-related-card strong,.agri-related a strong,.fe-related-card strong { color:#173f67 !important; }
.oc-r47-related-card small,.agri-related a small,.fe-related-card small { color:#40566d !important; }
.oc-r47-example,.oc-adv-example,.fe-content-card .fe-note {
  color:#344e66 !important;
  background:#eaf2f8 !important;
  border-color:#285f90 !important;
}

/* Clear labels, help text, and full-width fields at every breakpoint. */
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) label,
body :is(.oc-r47-field,.oc-adv-field,.agri-form,.fe-field) label {
  color:#1d3d5a !important;
  font-weight:750;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) small,
body :is(.oc-r47-field,.oc-adv-field,.agri-form,.fe-field) small,
.fe-help,.oc-r47-help,.oc-adv-help,.oc-r54-help,.oc-v55-help {
  color:#40566d !important;
  line-height:1.5;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="hidden"]),select,textarea) {
  box-sizing:border-box;
  width:100%;
  max-width:100%;
  min-width:0;
  min-height:46px;
  padding:10px 12px;
  color:#152a40 !important;
  background:#ffffff !important;
  border:1px solid #7892aa !important;
  border-radius:10px !important;
  box-shadow:inset 0 1px 2px rgba(18,45,68,.05) !important;
  font:inherit;
  font-size:16px;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) textarea {
  min-height:96px;
  resize:vertical;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input::placeholder,
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) textarea::placeholder {
  color:#596f83;
  opacity:1;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input[type="checkbox"],
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input[type="radio"] {
  accent-color:#285f90;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input[type="range"] {
  accent-color:#285f90;
}

/* One primary blue for calculator actions; secondary and reset controls stay distinct. */
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  button:not(:disabled):not(.oc-r47-secondary):not(.oc-adv-secondary):not(.secondary):not(.fe-secondary):not(.agri-preset button):not(.oc-r47-close):not(.oc-v97-result-close):not([type="reset"]):not(.reset):not(.clear):not(.reset-btn):not(.clear-btn):not(.clear-button):not([data-action="clear"]),
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(input[type="submit"],input[type="button"]):not([type="reset"]) {
  min-height:44px;
  color:#ffffff !important;
  background:#285f90 !important;
  border:1px solid #174b77 !important;
  border-radius:9px;
  box-shadow:0 3px 8px rgba(22,66,100,.14) !important;
  font-weight:750;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  button:not(:disabled):not(.oc-r47-secondary):not(.oc-adv-secondary):not(.secondary):not(.fe-secondary):not(.oc-r47-close):not(.oc-v97-result-close):not([type="reset"]):not(.reset):not(.clear):not(.reset-btn):not(.clear-btn):not(.clear-button):not([data-action="clear"]):hover {
  color:#ffffff !important;
  background:#1b4a73 !important;
  border-color:#123e63 !important;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-secondary,.oc-adv-secondary,.secondary,.fe-secondary,.reset-btn,.clear-btn,.clear-button,[type="reset"],.agri-preset button) {
  color:#203f5b !important;
  background:#eaf1f7 !important;
  border:1px solid #829bb2 !important;
  box-shadow:none !important;
}
.agri-preset button.active,.agri-preset button[aria-pressed="true"] {
  color:#ffffff !important;
  background:#285f90 !important;
  border-color:#174b77 !important;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) button:disabled,
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input:disabled,
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) select:disabled {
  color:#4b6075 !important;
  background:#e4ebf2 !important;
  border-color:#a5b7c8 !important;
  opacity:1;
  cursor:not-allowed;
}

/* Standard result surfaces, labels, values, and supporting detail. */
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-result,.oc-r58-result-panel,.oc-adv-result,.oc-v97-adv-placeholder,.oc-v97-simple-result,.oc-result-panel,.fe-results,.agri-results) {
  color:#152a40 !important;
  background:#edf3f8 !important;
  border-color:#91a8be !important;
  box-shadow:0 6px 18px rgba(19,54,82,.07) !important;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat,.oc-adv-stat,.oc-v97-simple-stat,.oc-result-detail,.agri-result,.fe-kpi) {
  color:#152a40 !important;
  background:#ffffff !important;
  border-color:#9bb1c5 !important;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-result-label,.oc-r58-result-kicker,.oc-adv-result-label,.oc-v97-simple-result-label,.oc-result-label) {
  color:#285f90 !important;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-main,.oc-r58-result-live,.oc-adv-main,.oc-v97-simple-result-main,.oc-result-main,.agri-result strong,.fe-kpi strong) {
  color:#173f67 !important;
  font-size:clamp(1.8rem,7vw,3rem);
  line-height:1.08;
  overflow-wrap:anywhere;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-summary,.oc-adv-summary,.oc-result-detail,.fe-result-summary,.fe-empty) {
  color:#263e55 !important;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat span,.oc-adv-stat span,.oc-result-label,.agri-result span,.fe-kpi span,.fe-result-note) {
  color:#40566d !important;
}
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-formula,.oc-adv-formula,.oc-adv-note,.fe-note,.agri-note,.oc-v117-preview) {
  color:#344e66 !important;
  background:#eaf2f8 !important;
  border-color:#a7bbcd !important;
}
.agri-form input,.agri-form select,.fe-field input,.fe-field select { border-color:#7892aa !important; }
.agri-actions .agri-btn.primary,.fe-button:not(.fe-secondary) { background:#285f90 !important; color:#fff !important; border-color:#174b77 !important; }
.agri-actions .agri-btn.secondary,.fe-button.fe-secondary { background:#eaf1f7 !important; color:#203f5b !important; border:1px solid #829bb2 !important; }
.fe-kpi-primary,.fe-kpi-primary strong { color:#173f67 !important; background:#e5eff7 !important; border-color:#9bb1c5 !important; }
body .fe-card .fe-kpi-primary { background:#e5eff7 !important; border-color:#9bb1c5 !important; }

/* Strong keyboard focus remains visible in every calculator template. */
body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(button,input,select,textarea,a):focus-visible {
  outline:3px solid #174f89 !important;
  outline-offset:2px;
  box-shadow:0 0 0 4px #ffffff !important;
}

/* Dark mode uses the same blue controls with readable surfaces and fields. */
html.oc-dark-preload :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input),
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input),
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input),
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) {
  --oc-primary:#285f90;
  --oc-primary-2:#3d83b5;
  --oc-primary-3:#d4e4f0;
  --oc-accent:#4c99ca;
  --oc-accent-soft:#1c3347;
  --oc-bg:#101c28;
  --oc-surface:#152535;
  --oc-surface-2:#1c3041;
  --oc-text:#f0f6fb;
  --oc-muted:#c2d1de;
  --oc-border:#60798f;
  --oc-danger:#ffbaba;
  --r47-bg:#101c28;
  --r47-surface:#152535;
  --r47-soft:#1c3041;
  --r47-strong:#294155;
  --r47-text:#f0f6fb;
  --r47-muted:#c2d1de;
  --r47-line:#60798f;
  --r47-primary:#285f90;
  --r47-primary-hover:#1b4a73;
  --r47-primary-soft:#1c3347;
  --r47-love:#4c99ca;
  --r47-love-soft:#1c3347;
  --oc30-ink:#f0f6fb;
  --oc30-muted:#c2d1de;
  --oc30-line:#60798f;
  --oc30-panel:#152535;
  --oc30-panel-2:#1c3041;
  --oc-v97-result-border:#60798f;
  --oc-v97-result-bg:linear-gradient(135deg,#1b3041,#152535);
  --oc-v97-result-shadow:0 10px 26px rgba(0,0,0,.28);
  --oc-v97-text:#f0f6fb;
  --oc-v97-muted:#c2d1de;
  --oc-v97-line:#60798f;
  --oc-v97-soft:#1c3041;
  --oc-v97-primary:#4c99ca;
  color:#f0f6fb !important;
  background-color:#152535 !important;
  border-color:#60798f !important;
}
html.oc-dark-preload .agri-hero,body.oc-dark .agri-hero,
body[data-theme="dark"] .agri-hero,body.dark-mode .agri-hero,html.dark .agri-hero,
html.oc-dark-preload .fe-hero,body.oc-dark .fe-hero,
body[data-theme="dark"] .fe-hero,body.dark-mode .fe-hero,html.dark .fe-hero {
  color:#f0f6fb !important;
  background:linear-gradient(135deg,#172d3e,#142433) !important;
  border-color:#60798f !important;
}
html.oc-dark-preload .agri-hero h1,body.oc-dark .agri-hero h1,
body[data-theme="dark"] .agri-hero h1,body.dark-mode .agri-hero h1,html.dark .agri-hero h1,
html.oc-dark-preload .fe-hero h1,body.oc-dark .fe-hero h1,
body[data-theme="dark"] .fe-hero h1,body.dark-mode .fe-hero h1,html.dark .fe-hero h1,
html.oc-dark-preload .fe-workspace-head h2,body.oc-dark .fe-workspace-head h2,
body[data-theme="dark"] .fe-workspace-head h2,body.dark-mode .fe-workspace-head h2,html.dark .fe-workspace-head h2 {
  color:#e1eff8 !important;
}
html.oc-dark-preload .agri-hero p,body.oc-dark .agri-hero p,
body[data-theme="dark"] .agri-hero p,body.dark-mode .agri-hero p,html.dark .agri-hero p,
html.oc-dark-preload .fe-hero p,body.oc-dark .fe-hero p,
body[data-theme="dark"] .fe-hero p,body.dark-mode .fe-hero p,html.dark .fe-hero p {
  color:#c2d1de !important;
}
html.oc-dark-preload :is(.oc-r47-hero,.oc-r47-content-card,.oc-adv-content-card,.fe-content-card,.agri-info),
body.oc-dark :is(.oc-r47-hero,.oc-r47-content-card,.oc-adv-content-card,.fe-content-card,.agri-info),
body[data-theme="dark"] :is(.oc-r47-hero,.oc-r47-content-card,.oc-adv-content-card,.fe-content-card,.agri-info),
body.dark-mode :is(.oc-r47-hero,.oc-r47-content-card,.oc-adv-content-card,.fe-content-card,.agri-info),
html.dark :is(.oc-r47-hero,.oc-r47-content-card,.oc-adv-content-card,.fe-content-card,.agri-info) {
  color:#f0f6fb !important;
  background:#152535 !important;
  border-color:#60798f !important;
}
html.oc-dark-preload :is(.oc-r47-trust span,.oc-r47-private,.oc-adv-private,.fe-private),
body.oc-dark :is(.oc-r47-trust span,.oc-r47-private,.oc-adv-private,.fe-private),
body[data-theme="dark"] :is(.oc-r47-trust span,.oc-r47-private,.oc-adv-private,.fe-private),
body.dark-mode :is(.oc-r47-trust span,.oc-r47-private,.oc-adv-private,.fe-private),
html.dark :is(.oc-r47-trust span,.oc-r47-private,.oc-adv-private,.fe-private) {
  color:#c2d1de !important;
  background:#1c3041 !important;
  border-color:#60798f !important;
}
html.oc-dark-preload :is(.oc-r47-related-card,.agri-related a,.fe-related-card),
body.oc-dark :is(.oc-r47-related-card,.agri-related a,.fe-related-card),
body[data-theme="dark"] :is(.oc-r47-related-card,.agri-related a,.fe-related-card),
body.dark-mode :is(.oc-r47-related-card,.agri-related a,.fe-related-card),
html.dark :is(.oc-r47-related-card,.agri-related a,.fe-related-card) {
  color:#f0f6fb !important;
  background:#1a2e3f !important;
  border-color:#60798f !important;
}
html.oc-dark-preload :is(.oc-r47-related-card strong,.agri-related a strong,.fe-related-card strong),
body.oc-dark :is(.oc-r47-related-card strong,.agri-related a strong,.fe-related-card strong),
body[data-theme="dark"] :is(.oc-r47-related-card strong,.agri-related a strong,.fe-related-card strong),
body.dark-mode :is(.oc-r47-related-card strong,.agri-related a strong,.fe-related-card strong),
html.dark :is(.oc-r47-related-card strong,.agri-related a strong,.fe-related-card strong) {
  color:#e1eff8 !important;
}
html.oc-dark-preload :is(.oc-r47-related-card small,.agri-related a small,.fe-related-card small),
body.oc-dark :is(.oc-r47-related-card small,.agri-related a small,.fe-related-card small),
body[data-theme="dark"] :is(.oc-r47-related-card small,.agri-related a small,.fe-related-card small),
body.dark-mode :is(.oc-r47-related-card small,.agri-related a small,.fe-related-card small),
html.dark :is(.oc-r47-related-card small,.agri-related a small,.fe-related-card small) {
  color:#c2d1de !important;
}
html.oc-dark-preload :is(.oc-r47-eyebrow,.oc-adv-eyebrow,.agri-kicker,.fe-kicker,.oc-r47-result-label,.oc-r58-result-kicker,.oc-adv-result-label,.oc-v97-simple-result-label),
html.dark :is(.oc-r47-eyebrow,.oc-adv-eyebrow,.agri-kicker,.fe-kicker,.oc-r47-result-label,.oc-r58-result-kicker,.oc-adv-result-label,.oc-v97-simple-result-label),
body:is(.oc-dark,[data-theme="dark"],.dark-mode) :is(.oc-r47-eyebrow,.oc-adv-eyebrow,.agri-kicker,.fe-kicker,.oc-r47-result-label,.oc-r58-result-kicker,.oc-adv-result-label,.oc-v97-simple-result-label) {
  color:#8fc7e9 !important;
}
html.oc-dark-preload :is(.oc-r47-field small,.oc-adv-field small,.fe-help,.oc-r47-help,.oc-adv-help,.oc-r54-help,.oc-v55-help),
html.dark :is(.oc-r47-field small,.oc-adv-field small,.fe-help,.oc-r47-help,.oc-adv-help,.oc-r54-help,.oc-v55-help),
body:is(.oc-dark,[data-theme="dark"],.dark-mode) :is(.oc-r47-field small,.oc-adv-field small,.fe-help,.oc-r47-help,.oc-adv-help,.oc-r54-help,.oc-v55-help) {
  color:#c2d1de !important;
}
html.oc-dark-preload .fe-card .fe-kpi-primary,html.dark .fe-card .fe-kpi-primary,
body:is(.oc-dark,[data-theme="dark"],.dark-mode) .fe-card .fe-kpi-primary {
  color:#f0f6fb !important;
  background:#22384a !important;
  border-color:#60798f !important;
}
html.oc-dark-preload .fe-card .fe-kpi-primary strong,html.dark .fe-card .fe-kpi-primary strong,
body:is(.oc-dark,[data-theme="dark"],.dark-mode) .fe-card .fe-kpi-primary strong { color:#e8f3fb !important; }
html.oc-dark-preload :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(label,strong,legend),
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(label,strong,legend),
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(label,strong,legend),
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(label,strong,legend),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(label,strong,legend) {
  color:#e4eff7 !important;
}
html.oc-dark-preload body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="hidden"]),select,textarea),
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="hidden"]),select,textarea),
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="hidden"]),select,textarea),
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="hidden"]),select,textarea),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="hidden"]),select,textarea) {
  color:#f0f6fb !important;
  background:#0e1a25 !important;
  border-color:#70879b !important;
}
html.oc-dark-preload body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input::placeholder,
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input::placeholder,
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) textarea::placeholder,
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input::placeholder,
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) textarea::placeholder,
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input::placeholder,
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) textarea::placeholder,
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) input::placeholder,
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) textarea::placeholder {
  color:#bac9d6;
  opacity:1;
}
html.oc-dark-preload body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-result,.oc-r58-result-panel,.oc-adv-result,.oc-v97-adv-placeholder,.oc-v97-simple-result,.oc-result-panel,.fe-results,.agri-results),
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-result,.oc-r58-result-panel,.oc-adv-result,.oc-v97-adv-placeholder,.oc-v97-simple-result,.oc-result-panel,.fe-results,.agri-results),
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-result,.oc-r58-result-panel,.oc-adv-result,.oc-v97-adv-placeholder,.oc-v97-simple-result,.oc-result-panel,.fe-results,.agri-results),
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-result,.oc-r58-result-panel,.oc-adv-result,.oc-v97-adv-placeholder,.oc-v97-simple-result,.oc-result-panel,.fe-results,.agri-results),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-result,.oc-r58-result-panel,.oc-adv-result,.oc-v97-adv-placeholder,.oc-v97-simple-result,.oc-result-panel,.fe-results,.agri-results) {
  color:#f0f6fb !important;
  background:#1a2e3f !important;
  border-color:#60798f !important;
  box-shadow:0 8px 20px rgba(0,0,0,.2) !important;
}
html.oc-dark-preload body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat,.oc-adv-stat,.oc-v97-simple-stat,.oc-result-detail,.agri-result,.fe-kpi),
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat,.oc-adv-stat,.oc-v97-simple-stat,.oc-result-detail,.agri-result,.fe-kpi),
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat,.oc-adv-stat,.oc-v97-simple-stat,.oc-result-detail,.agri-result,.fe-kpi),
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat,.oc-adv-stat,.oc-v97-simple-stat,.oc-result-detail,.agri-result,.fe-kpi),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat,.oc-adv-stat,.oc-v97-simple-stat,.oc-result-detail,.agri-result,.fe-kpi) {
  color:#f0f6fb !important;
  background:#22384a !important;
  border-color:#60798f !important;
}
html.oc-dark-preload body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-main,.oc-r58-result-live,.oc-adv-main,.oc-v97-simple-result-main,.oc-result-main,.agri-result strong,.fe-kpi strong),
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-main,.oc-r58-result-live,.oc-adv-main,.oc-v97-simple-result-main,.oc-result-main,.agri-result strong,.fe-kpi strong),
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-main,.oc-r58-result-live,.oc-adv-main,.oc-v97-simple-result-main,.oc-result-main,.agri-result strong,.fe-kpi strong),
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-main,.oc-r58-result-live,.oc-adv-main,.oc-v97-simple-result-main,.oc-result-main,.agri-result strong,.fe-kpi strong),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-main,.oc-r58-result-live,.oc-adv-main,.oc-v97-simple-result-main,.oc-result-main,.agri-result strong,.fe-kpi strong) {
  color:#e8f3fb !important;
}
html.oc-dark-preload body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat span,.oc-adv-stat span,.oc-result-label,.agri-result span,.fe-kpi span,.fe-result-note,.oc-r47-summary,.oc-adv-summary,.oc-result-detail,.fe-result-summary),
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat span,.oc-adv-stat span,.oc-result-label,.agri-result span,.fe-kpi span,.fe-result-note,.oc-r47-summary,.oc-adv-summary,.oc-result-detail,.fe-result-summary),
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat span,.oc-adv-stat span,.oc-result-label,.agri-result span,.fe-kpi span,.fe-result-note,.oc-r47-summary,.oc-adv-summary,.oc-result-detail,.fe-result-summary),
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat span,.oc-adv-stat span,.oc-result-label,.agri-result span,.fe-kpi span,.fe-result-note,.oc-r47-summary,.oc-adv-summary,.oc-result-detail,.fe-result-summary),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
  :is(.oc-r47-stat span,.oc-adv-stat span,.oc-result-label,.agri-result span,.fe-kpi span,.fe-result-note,.oc-r47-summary,.oc-adv-summary,.oc-result-detail,.fe-result-summary) {
  color:#c2d1de !important;
}
html.oc-dark-preload body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(.oc-r47-formula,.oc-adv-formula,.oc-adv-note,.fe-note,.agri-note,.oc-v117-preview),
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(.oc-r47-formula,.oc-adv-formula,.oc-adv-note,.fe-note,.agri-note,.oc-v117-preview),
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(.oc-r47-formula,.oc-adv-formula,.oc-adv-note,.fe-note,.agri-note,.oc-v117-preview),
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(.oc-r47-formula,.oc-adv-formula,.oc-adv-note,.fe-note,.agri-note,.oc-v117-preview),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(.oc-r47-formula,.oc-adv-formula,.oc-adv-note,.fe-note,.agri-note,.oc-v117-preview) {
  color:#c2d1de !important;
  background:#1c3041 !important;
  border-color:#60798f !important;
}
html.oc-dark-preload body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input,select,textarea,a):focus-visible,
body.oc-dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input,select,textarea,a):focus-visible,
body[data-theme="dark"] :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input,select,textarea,a):focus-visible,
body.dark-mode :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input,select,textarea,a):focus-visible,
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input,select,textarea,a):focus-visible {
  outline-color:#b6ddf7 !important;
  box-shadow:0 0 0 4px #152535 !important;
}
html.oc-dark-preload :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(.oc-r47-secondary,.oc-adv-secondary,.secondary,.fe-secondary,.reset-btn,.clear-btn,.clear-button,[type="reset"],.agri-preset button),
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(.oc-r47-secondary,.oc-adv-secondary,.secondary,.fe-secondary,.reset-btn,.clear-btn,.clear-button,[type="reset"],.agri-preset button),
body:is(.oc-dark,[data-theme="dark"],.dark-mode) :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(.oc-r47-secondary,.oc-adv-secondary,.secondary,.fe-secondary,.reset-btn,.clear-btn,.clear-button,[type="reset"],.agri-preset button) {
  color:#e8f2fa !important;
  background:#263b4e !important;
  border-color:#70879b !important;
}
html.oc-dark-preload :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input,select):disabled,
html.dark :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input,select):disabled,
body:is(.oc-dark,[data-theme="dark"],.dark-mode) :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input,select):disabled {
  color:#cedae4 !important;
  background:#2b4053 !important;
  border-color:#73899d !important;
}

/* Responsive controls, text, and result cards on tablets and narrow phones. */
@media (max-width:760px) {
  body :is(.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace) :is(.oc-r47-fields,.oc-adv-grid,.agri-form,.fe-grid) {
    grid-template-columns:minmax(0,1fr) !important;
  }
  body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input)
    :is(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]):not([type="hidden"]),select,textarea) {
    min-height:48px;
    font-size:16px;
  }
  body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) :is(button,input[type="submit"],input[type="button"]) {
    min-height:44px;
  }
  body :is(.oc-r47-result,.oc-r58-result-panel,.oc-adv-result,.oc-v97-adv-placeholder,.oc-v97-simple-result,.oc-result-panel,.fe-results,.agri-results) {
    box-sizing:border-box;
    min-width:0;
    max-width:100%;
    overflow-wrap:anywhere;
  }
}
@media (max-width:520px) {
  .agri-hero,.fe-hero { padding:18px 15px; border-radius:15px; }
  .agri-tool,.fe-card,.fe-workspace { padding:15px !important; }
  body :is(.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace) :is(.oc-r47-stats,.oc-adv-stats,.fe-results-grid,.agri-results) {
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
  body :is(.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace) :is(.oc-r47-actions,.oc-adv-actions,.fe-actions,.agri-actions,.oc-r47-result-actions,.oc-adv-result-actions) {
    gap:8px;
  }
  body :is(.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace) :is(.oc-r47-actions,.oc-adv-actions,.oc-r47-result-actions,.oc-adv-result-actions) button {
    min-width:0;
    padding-inline:8px !important;
    font-size:.88rem;
  }
}
@media (max-width:360px) {
  body :is(.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace) :is(.oc-r47-stats,.oc-adv-stats,.fe-results-grid,.agri-results) {
    grid-template-columns:minmax(0,1fr) !important;
  }
  .oc-r47-main,.oc-r58-result-live,.oc-adv-main,.oc-v97-simple-result-main,.oc-result-main {
    font-size:clamp(1.6rem,8vw,2.4rem) !important;
  }
}

@media (prefers-reduced-motion:reduce) {
  body :is(.cal-section,.oc-r47-tool,.oc-adv-tool,.agri-tool,.fe-card,.fe-workspace,.oc-v97-simple-input) * {
    scroll-behavior:auto !important;
    transition:none !important;
  }
}
