/* Frugal Coupons public UI. Scoped to plugin content; site fonts/accent are retained. */
.ffc {
  --ffc-accent: #16724b;
  --ffc-ink: #20372e;
  --ffc-line: #dde6e1;
  --ffc-muted: #56665e;
  --ffc-soft: #f4f7f5;
  --ffc-radius: 14px;
  color: var(--ffc-ink);
  font-size: 16px;
  line-height: 1.65;
  max-width: 1120px;
  min-width: 0;
  margin: 0 auto;
  padding: 8px 0 28px;
  text-align: start;
}
.ffc *, .ffc *::before, .ffc *::after { box-sizing: border-box; }
.ffc [hidden] { display: none !important; }
.ffc h2, .ffc h3, .ffc p { color: inherit; }
.ffc h2 { font-size: clamp(23px, 3vw, 30px); line-height: 1.3; margin: 0 0 16px; font-weight: 750; }
.ffc h3 { font-size: 21px; line-height: 1.4; margin: 14px 0; }
.ffc p { margin: 0 0 14px; }
.ffc a { color: var(--ffc-accent); }
.ffc button, .ffc input, .ffc select, .ffc textarea { font: inherit; }
.ffc button { cursor: pointer; text-transform: none; letter-spacing: normal; }
.ffc button:disabled { opacity: .65; cursor: default; }
.ffc :focus-visible { outline: 3px solid #ae651d; outline-offset: 3px; }
.ffc .ffc-ui-heading { font-size: 1.35rem; font-weight: 750; line-height: 1.35; margin: 0 0 12px; color: inherit; overflow-wrap: anywhere; }
.ffc .ffc-eyebrow { font-size: 11px; letter-spacing: 1.25px; text-transform: uppercase; font-weight: 700; margin: 0 0 7px; color: var(--ffc-muted); }
.ffc .ffc-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); clip-path: inset(50%); white-space: nowrap; border: 0; }

/* Brand header: image, title and counts read as one compact unit. */
.ffc .ffc-hero { display: flex; align-items: center; gap: 20px; padding: 24px; border-radius: var(--ffc-radius); background: var(--ffc-soft); border: 1px solid var(--ffc-line); margin: 0 0 22px; }
.ffc .ffc-hero-copy { min-width: 0; flex: 1; overflow-wrap: anywhere; }
.ffc .ffc-hero .ffc-ui-heading { font-size: clamp(24px, 3vw, 32px); margin-bottom: 10px; letter-spacing: -.025em; }
.ffc .ffc-logo { flex: none; width: 80px; height: 80px; object-fit: contain; border-radius: 12px; background: #fff; }
.ffc .ffc-counts { display: flex; flex-wrap: wrap; gap: 6px; }
.ffc .ffc-counts span { background: #fff; padding: 3px 10px; border: 1px solid var(--ffc-line); border-radius: 6px; font-size: 12px; line-height: 1.5; }
.ffc .ffc-hero--compact { padding: 16px 20px; gap: 16px; margin-bottom: 16px; }
.ffc .ffc-hero--compact .ffc-ui-heading { font-size: clamp(21px, 3vw, 28px); margin-bottom: 8px; }
.ffc .ffc-hero-media { flex: none; width: 80px; height: 80px; border: 1px solid var(--ffc-line); background: #fff; border-radius: 12px; overflow: hidden; }
.ffc .ffc-hero-media--medium { width: 112px; height: 112px; }
.ffc .ffc-hero-image { display: block !important; width: 100% !important; height: 100% !important; object-fit: contain; margin: 0 !important; border: 0; padding: 6px; }
.ffc .ffc-hero--image-right .ffc-hero-media { order: 2; }

/* A single proportional filter bar. All four options share the same geometry. */
.ffc .ffc-offer-section { min-width: 0; container-type: inline-size; }
.ffc .ffc-section-heading { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px 20px; margin: 0 0 16px; }
.ffc .ffc-section-heading > .ffc-ui-heading, .ffc .ffc-section-heading > h2 { flex: 1 0 auto; margin: 0; font-size: 21px; line-height: 1.35; letter-spacing: -.02em; }
.ffc .ffc-filters { display: inline-grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); align-items: stretch; gap: 4px; padding: 4px; margin: 0; min-width: 0; max-width: 100%; border: 1px solid var(--ffc-line); border-radius: 12px; background: var(--ffc-soft); }
.ffc .ffc-filters button {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 38px; min-width: 0; width: auto; height: auto; margin: 0; padding: 7px 12px;
  border: 1px solid transparent; border-radius: 8px; background: transparent;
  color: var(--ffc-muted); font-family: inherit; font-size: 13px; font-weight: 650;
  line-height: 1.3; letter-spacing: normal; text-transform: none; text-decoration: none;
  box-shadow: none; float: none; white-space: nowrap; cursor: pointer;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.ffc .ffc-filters button:hover { background: #e8eee9; color: var(--ffc-ink); }
.ffc .ffc-filters button[aria-pressed="true"] { background: #fff; border-color: var(--ffc-line); color: var(--ffc-accent); box-shadow: 0 1px 3px rgba(20,45,30,.07); }
.ffc .ffc-filter-label { min-width: 0; }
.ffc .ffc-filter-count { display: inline-flex; flex-shrink: 0; align-items: center; justify-content: center; min-width: 21px; height: 21px; padding: 0 5px; background: #e5ebe7; border-radius: 5px; color: var(--ffc-muted); font-size: 11px; line-height: 1; font-weight: 700; font-variant-numeric: tabular-nums; }
.ffc .ffc-filters button[aria-pressed="true"] .ffc-filter-count { background: var(--ffc-accent); color: #fff; }
.ffc .ffc-filter-empty:not(:empty) { padding: 22px; margin: 0; border: 1px dashed var(--ffc-line); border-radius: var(--ffc-radius); color: var(--ffc-muted); }
.ffc .ffc-filter-empty:empty { display: none; }

/* Coupon cards keep the saving dominant and the action within easy reach. */
.ffc .ffc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.ffc .ffc-offer { display: flex; flex-direction: column; min-width: 0; margin: 0; padding: 22px; border: 1px solid var(--ffc-line); border-radius: var(--ffc-radius); background: #fff; box-shadow: 0 2px 8px rgba(20,45,30,.025); overflow-wrap: anywhere; }
.ffc .ffc-offer:hover { border-color: #bdcfc3; }
.ffc .ffc-offer-labels { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 12px; }
.ffc .ffc-pill { display: inline-flex; align-items: center; font-size: 10px; letter-spacing: .5px; line-height: 1.4; text-transform: uppercase; font-weight: 750; padding: 4px 8px; border-radius: 5px; background: var(--ffc-soft); color: var(--ffc-accent); }
.ffc .ffc-featured { background: #fff3dd; color: #7a4914; }
.ffc .ffc-pending { background: #fff0c2; color: #6e4b00; }
.ffc .ffc-offer .ffc-ui-heading { font-size: 19px; line-height: 1.4; letter-spacing: -.015em; margin-bottom: 10px; }
.ffc .ffc-offer > p:not(.ffc-ui-heading):not(.ffc-card-status) { font-size: 14px; line-height: 1.65; color: var(--ffc-muted); }
.ffc .ffc-offer-meta { display: flex; flex-wrap: wrap; gap: 3px 14px; font-size: 12px; line-height: 1.6; color: var(--ffc-muted); margin: 0 0 16px; }
.ffc .ffc-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; width: auto; height: auto; margin: 0; padding: 11px 18px; border: 1px solid var(--ffc-accent); border-radius: 9px; background: var(--ffc-accent); color: #fff; font: inherit; font-size: 14px; font-weight: 700; line-height: 1.45; text-align: center; text-decoration: none; text-transform: none; letter-spacing: normal; box-shadow: none; float: none; cursor: pointer; }
.ffc .ffc-button:hover { filter: brightness(.94); color: #fff; text-decoration: none; }
.ffc .ffc-code-action { display: flex; align-items: stretch; gap: 8px; margin-top: auto; min-width: 0; }
.ffc .ffc-mask { display: inline-flex; align-items: center; justify-content: center; flex: 0 1 auto; min-width: 72px; max-width: 42%; min-height: 46px; padding: 9px 12px; border: 1px dashed #a8bbb0; border-radius: 9px; background: var(--ffc-soft); color: var(--ffc-ink); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 14px; letter-spacing: .14em; overflow-wrap: anywhere; }
.ffc .ffc-code-action .ffc-reveal { flex: 1; min-width: 0; }
.ffc .ffc-offer > .ffc-button { margin-top: auto; }
.ffc .ffc-offer > .ffc-code-action + .ffc-button { margin-top: 9px; }
.ffc .ffc-terms { margin-top: 14px; color: var(--ffc-muted); font-size: 13px; }
.ffc .ffc-terms summary { cursor: pointer; font-weight: 600; }
.ffc .ffc-terms p { margin: 9px 0 0; white-space: normal; }
.ffc .ffc-card-status:empty { display: none; }
.ffc .ffc-card-status:not(:empty) { margin: 0; padding-top: 12px; font-size: 13px; }
.ffc .ffc-open-note { font-size: 13px; margin: 8px 0; color: var(--ffc-muted); }
.ffc .ffc-empty { padding: 24px; border: 1px dashed var(--ffc-line); border-radius: var(--ffc-radius); grid-column: 1 / -1; }
.ffc .ffc-empty p:last-child { margin-bottom: 0; }

/* Historical offers use the same cards and grid, not a second oversized layout. */
.ffc .ffc-offer--expired { background: #f8faf9; border-color: var(--ffc-line); box-shadow: none; }
.ffc .ffc-pill--expired { background: #e8ece9; color: #506158; }
.ffc .ffc-expired-code { display: flex; align-items: center; gap: 10px; margin: auto 0 12px; flex-wrap: wrap; min-width: 0; }
.ffc .ffc-expired-code > span, .ffc .ffc-expired-no-code { font-size: 13px; color: var(--ffc-muted); }
.ffc .ffc-expired-code code { max-width: 100%; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 16px; font-weight: 650; letter-spacing: .02em; padding: 7px 11px; border: 1px dashed #a8b6ae; border-radius: 7px; background: #fff; overflow-wrap: anywhere; white-space: normal; user-select: all; color: #34473d; }
.ffc .ffc-expired-note { color: var(--ffc-muted); font-size: 13px; font-weight: 500; margin: -3px 0 13px; }
.ffc .ffc-expired { margin-top: 24px; padding: 22px; background: var(--ffc-soft); border: 1px solid var(--ffc-line); border-radius: var(--ffc-radius); }
.ffc .ffc-expired li { margin-bottom: 10px; }
.ffc .ffc-expired small { color: var(--ffc-muted); }

/* rc15 dialog structure, without opening animations or a holding screen. */
.ffc .ffc-dialog { width: min(92vw, 540px); max-width: calc(100vw - 24px); max-height: 90vh; max-height: 90dvh; height: fit-content; overflow: auto; border: 1px solid var(--ffc-line); border-radius: 18px; padding: 0; background: #fff; color: var(--ffc-ink); box-shadow: 0 24px 90px rgba(15,34,26,.25); text-align: start; }
.ffc .ffc-dialog::backdrop { background: rgba(15,30,23,.6); }
.ffc .ffc-dialog:not([open]) { display: none !important; }
.ffc .ffc-dialog[open] { display: block !important; position: fixed; inset: 0; margin: auto; z-index: 2147483000; visibility: visible; opacity: 1; }
.ffc .ffc-dialog[data-ffc-fallback="1"][open] { height: fit-content; box-shadow: 0 0 0 100vmax rgba(15,30,23,.6), 0 24px 90px rgba(15,34,26,.25); }
.ffc .ffc-dialog-inner { position: relative; padding: 30px; }
.ffc .ffc-dialog-inner > .ffc-ui-heading { padding-inline-end: 20px; font-size: 23px; line-height: 1.35; }
.ffc .ffc-dialog-close { position: absolute; inset-inline-end: 8px; top: 8px; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; min-height: 40px; margin: 0; padding: 0; font-size: 28px !important; line-height: 1; font-weight: 400; background: transparent; border: 0; border-radius: 50%; box-shadow: none; color: var(--ffc-muted); }
.ffc .ffc-dialog-close:hover { background: var(--ffc-soft); color: var(--ffc-ink); }
.ffc .ffc-copy-row { display: flex; gap: 8px; margin-top: 18px; }
.ffc .ffc-copy-row input { flex: 1; min-width: 0; width: 100%; height: auto; margin: 0; border: 1px dashed var(--ffc-accent); padding: 11px; border-radius: 9px; text-align: center; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 21px; line-height: 1.5; letter-spacing: 1px; background: var(--ffc-soft); color: var(--ffc-ink); box-shadow: none; }
.ffc .ffc-copy-row .ffc-button { flex: none; }
.ffc [data-ffc-copy-status] { font-size: 13px; color: var(--ffc-muted); margin: 9px 0 0; overflow-wrap: anywhere; }
.ffc [data-ffc-copy-status]:empty { display: none; }
.ffc .ffc-merchant { width: 100%; margin: 16px 0 0; }
.ffc .ffc-dialog-note { font-size: 13px; color: var(--ffc-muted); margin-bottom: 0 !important; }
.ffc .ffc-feedback { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--ffc-line); }
.ffc .ffc-feedback .ffc-ui-heading, .ffc .ffc-feedback h3 { font-size: 17px; margin: 0 0 5px; }
.ffc .ffc-feedback p { font-size: 13px; margin: 6px 0; }
.ffc .ffc-feedback-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.ffc .ffc-feedback-actions .ffc-button { font-size: 13px; padding: 9px 12px; min-height: 42px; }
.ffc .ffc-feedback-no { background: #fff; color: var(--ffc-ink); border-color: #bacbc0; }
.ffc .ffc-feedback-no:hover { background: var(--ffc-soft); color: var(--ffc-ink); filter: none; }
.ffc .ffc-feedback-later { background: transparent; color: var(--ffc-muted); border: 0; border-radius: 7px; padding: 9px 8px; font-size: 13px; min-height: 42px; }
.ffc .ffc-feedback small { font-size: 12px; display: block; margin-top: 12px; color: var(--ffc-muted); }
.ffc .ffc-feedback-open { border: 0; background: transparent; color: inherit; text-decoration: underline; cursor: pointer; padding: 9px 0; text-align: start; font: inherit; font-size: 13px; }
.ffc .ffc-feedback-details { margin: 12px 0 16px; text-align: start; font-size: 13px; }
.ffc .ffc-feedback-details summary { cursor: pointer; }
.ffc .ffc-feedback-details label { display: block; margin: 10px 0 4px; }
.ffc .ffc-feedback-details select, .ffc .ffc-feedback-details textarea { width: 100%; max-width: 100%; box-sizing: border-box; font: inherit; font-size: 16px; padding: 9px; border: 1px solid #bacbc0; border-radius: 7px; background: #fff; color: var(--ffc-ink); }
.ffc .ffc-feedback-details textarea { resize: vertical; min-height: 64px; }

/* Supporting modules: consistent spacing and quieter chrome. */
.ffc .ffc-top-pick, .ffc .ffc-trust, .ffc .ffc-author { margin: 24px 0; padding: 22px; border: 1px solid var(--ffc-line); border-radius: var(--ffc-radius); background: var(--ffc-soft); }
.ffc .ffc-top-pick { border-inline-start: 3px solid var(--ffc-accent); }
.ffc .ffc-top-pick .ffc-code-action { max-width: 28rem; margin-top: 16px; }
.ffc .ffc-top-pick > .ffc-button { margin-top: 8px; }
.ffc .ffc-check-list { list-style: none !important; margin: 0 !important; padding: 0 !important; }
.ffc .ffc-check-list li { position: relative; padding: 8px 0 8px 28px; border-bottom: 1px solid var(--ffc-line); }
.ffc .ffc-check-list li:last-child { border-bottom: 0; }
.ffc .ffc-check-list li::before { content: '\2713'; position: absolute; left: 2px; top: 8px; font-weight: 800; color: var(--ffc-accent); }
.ffc .ffc-author { display: flex; align-items: flex-start; gap: 16px; }
.ffc .ffc-author-avatar { flex: none; }
.ffc .ffc-author-avatar img { border-radius: 50%; display: block; }
.ffc .ffc-author p:last-child { margin-bottom: 0; }
.ffc .ffc-author-role { font-size: 15px; }
.ffc .ffc-disclosure { font-size: 12px; line-height: 1.65; color: var(--ffc-muted); margin: 16px 0 26px; }
.ffc .ffc-prose { padding: 22px 0; border-bottom: 1px solid var(--ffc-line); overflow-wrap: anywhere; }
.ffc #ffc-section-intro { padding-top: 4px; margin-bottom: 20px; }
.ffc .ffc-prose p { max-width: 82ch; }
.ffc .ffc-prose p:last-child { margin-bottom: 0; }
.ffc .ffc-prose ul, .ffc .ffc-prose ol { margin: 0 0 18px 24px; }
.ffc .ffc-prose h2 { margin-top: 28px; }
.ffc .ffc-prose h2:first-child { margin-top: 0; }
.ffc .ffc-prose h3 { margin-top: 24px; }
.ffc .ffc-prose a { text-decoration: underline; text-underline-offset: 3px; }
.ffc .ffc-editorial-toc { border: 1px solid var(--ffc-line); border-radius: 10px; padding: 16px 20px; margin: 0 0 24px; }
.ffc .ffc-toc-title { font-weight: 700; margin: 0 0 8px; }
.ffc .ffc-editorial-toc ul { margin: 0; padding-left: 21px; }
.ffc .ffc-editorial-toc a { overflow-wrap: anywhere; }
.ffc .ffc-editorial h2 { scroll-margin-top: 5rem; }
.ffc .ffc-stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px,1fr)); gap: 12px; margin: 16px 0; }
.ffc .ffc-stat-grid > div { padding: 16px; border: 1px solid var(--ffc-line); border-radius: 10px; background: #fff; }
.ffc .ffc-stat-grid strong { display: block; font-size: 1.4rem; line-height: 1.2; }
.ffc .ffc-stat-grid span { display: block; margin-top: 6px; font-size: 13px; color: var(--ffc-muted); }
.ffc .ffc-table-wrap { overflow-x: auto; border: 1px solid var(--ffc-line); border-radius: 10px; }
.ffc .ffc-history table { width: 100%; border-collapse: collapse; margin: 0; font-size: 14px; }
.ffc .ffc-history th, .ffc .ffc-history td { padding: 11px 14px; border-bottom: 1px solid var(--ffc-line); text-align: start; vertical-align: top; }
.ffc .ffc-history th { background: var(--ffc-soft); font-size: 12px; }
.ffc .ffc-history tr:last-child td { border-bottom: 0; }
.ffc .ffc-facts dl { margin: 0; }
.ffc .ffc-facts dl > div { display: grid; grid-template-columns: 1fr 2fr; gap: 24px; padding: 14px 0; border-bottom: 1px solid var(--ffc-line); }
.ffc .ffc-facts dt { font-weight: 700; }
.ffc .ffc-facts dd { margin: 0; overflow-wrap: anywhere; }
.ffc .ffc-facts small { display: block; color: var(--ffc-muted); font-size: 12px; }
.ffc .ffc-preview-banner, .ffc .ffc-warning { padding: 16px !important; background: #fff3cd; color: #674c0b !important; border: 1px solid #e3cf8b; border-radius: 8px; margin-bottom: 18px !important; font-size: 14px; }

/* Optional standalone photographs. Logo and hero image modes never crop. */
.ffc .ffc-page-image { margin: 0 0 24px; border: 1px solid var(--ffc-line); border-radius: var(--ffc-radius); overflow: hidden; background: var(--ffc-soft); padding: 22px; }
.ffc .ffc-page-image-photo { display: block; margin: 0 auto; max-width: 100%; width: auto; height: auto; max-height: 340px; object-fit: contain; border-radius: 10px; }
.ffc .ffc-page-image--banner { padding: 0; }
.ffc .ffc-page-image--banner .ffc-page-image-photo { width: 100%; height: clamp(180px,28vw,360px); max-height: none; object-fit: cover; border-radius: 0; }
.ffc .ffc-page-image--compact { padding: 10px; margin-bottom: 16px; border-radius: 12px; }
.ffc .ffc-page-image--compact .ffc-page-image-photo { max-height: 140px; width: auto; object-fit: contain; }
.ffc[data-ffc-spacing="compact"] .ffc-hero { padding: 16px; gap: 16px; margin-bottom: 14px; }
.ffc[data-ffc-spacing="compact"] #ffc-section-intro { padding: 8px 0 14px; margin: 0 0 14px; }
.ffc[data-ffc-spacing="compact"] .ffc-top-pick { padding: 16px 18px; margin: 14px 0; }
.ffc[data-ffc-spacing="compact"] .ffc-section-heading { margin-bottom: 12px; }
.ffc[data-ffc-spacing="compact"] .ffc-offer { padding: 18px; }

/* Plugin-owned templates only; no generic body/header/button theme resets. */
.ffc-template { max-width: 1180px; margin: 0 auto; padding: 28px 24px; }
.ffc-template > h1 { font-size: clamp(28px,5vw,42px); line-height: 1.25; margin-bottom: 24px; }
.ffc-canvas { margin: 0; background: #fff; color: #20372e; font-family: system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
.ffc-canvas-header { max-width: 1180px; margin: auto; padding: 20px 24px; border-bottom: 1px solid #dde6e1; }
.ffc-canvas-header a { color: #20372e; font-size: 18px; text-decoration: none; font-weight: 700; }

/* Narrow content columns as well as narrow devices get four equal filter cells. */
@container (max-width: 690px) {
  .ffc .ffc-section-heading { flex-direction: column; align-items: stretch; gap: 10px; }
  .ffc .ffc-filters { display: grid; width: 100%; }
  .ffc .ffc-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .ffc .ffc-section-heading { flex-direction: column; align-items: stretch; gap: 10px; }
  .ffc .ffc-filters { display: grid; width: 100%; }
}
@media (max-width: 650px) {
  .ffc .ffc-grid { grid-template-columns: 1fr; gap: 12px; }
  .ffc .ffc-hero { padding: 18px; gap: 14px; }
  .ffc .ffc-logo { width: 60px; height: 60px; }
  .ffc .ffc-offer { padding: 18px; }
  .ffc .ffc-filters button { min-height: 40px; padding: 7px 8px; gap: 5px; }
  .ffc .ffc-dialog-inner { padding: 28px 20px 22px; }
  .ffc .ffc-copy-row input { font-size: 18px; }
  .ffc .ffc-facts dl > div { grid-template-columns: 1fr; gap: 5px; }
  .ffc .ffc-hero--compact { padding: 12px; gap: 12px; }
  .ffc .ffc-hero-media { width: 64px; height: 64px; border-radius: 10px; }
  .ffc .ffc-hero-media--medium { width: 80px; height: 80px; }
  .ffc .ffc-hero--compact .ffc-eyebrow { font-size: 10px; letter-spacing: .6px; margin-bottom: 4px; }
  .ffc .ffc-page-image { padding: 16px; border-radius: 12px; }
  .ffc .ffc-page-image--banner { padding: 0; }
  .ffc .ffc-page-image-photo { max-height: 240px; }
  .ffc .ffc-page-image--compact { padding: 10px; }
  .ffc .ffc-page-image--compact .ffc-page-image-photo { max-height: 96px; }
  .ffc[data-ffc-spacing="compact"] .ffc-hero { padding: 12px; gap: 12px; }
  .ffc .ffc-expired { padding: 16px; }
  .ffc-template { padding: 22px 16px; }
}
@media (max-width: 420px) {
  .ffc .ffc-filters { gap: 2px; padding: 3px; }
  .ffc .ffc-filters button { padding: 7px 4px; gap: 4px; font-size: 12px; }
  .ffc .ffc-filter-count { min-width: 18px; height: 19px; padding: 0 3px; font-size: 10px; }
  .ffc .ffc-code-action .ffc-mask { min-width: 64px; padding: 9px; font-size: 13px; }
  .ffc .ffc-code-action .ffc-button { padding-inline: 10px; }
  .ffc .ffc-feedback-actions .ffc-button { flex: 1; }
}
@container (max-width: 330px) {
  .ffc .ffc-filters button { gap: 3px; font-size: 12px; padding-inline: 3px; }
  /* Keep every label readable in very narrow columns; full counts remain in aria-label. */
  .ffc .ffc-filter-count { display: none; }
}
@media (max-width: 360px) {
  .ffc .ffc-filter-count { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .ffc * { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

/* rc21 opt-in layouts. Classic geometry and the dialog remain unchanged. */
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-grid { grid-template-columns: minmax(0,1fr); gap: 12px; }
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-offer { padding: 16px; border-radius: 12px; }
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-offer .ffc-ui-heading { font-size: 17px; margin-bottom: 8px; }
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-offer-labels { margin-bottom: 8px; }
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-offer-meta { margin-bottom: 12px; gap: 3px 10px; }
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-offer > p:not(.ffc-ui-heading):not(.ffc-card-status) { margin-bottom: 10px; }
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-offer .ffc-mask { min-width: 58px; padding: 8px; font-size: 12px; }
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-offer .ffc-button { min-height: 44px; padding: 10px 12px; font-size: 13px; }
.ffc .ffc-offer-details { color: var(--ffc-muted); font-size: 13px; margin: 0 0 10px; }
.ffc .ffc-offer-details summary { cursor: pointer; font-weight: 600; padding: 4px 0; }
.ffc .ffc-offer-details p { margin: 7px 0 0; }
.ffc[data-ffc-design="tiles"]:not([data-ffc-design="classic"]) .ffc-offer { border-top: 3px solid var(--ffc-accent); box-shadow: none; }
.ffc[data-ffc-design="tiles"]:not([data-ffc-design="classic"]) .ffc-offer--expired { border-top-color: var(--ffc-line); }
.ffc[data-ffc-design="tiles"]:not([data-ffc-design="classic"]) .ffc-offer .ffc-ui-heading { font-size: 18px; }
.ffc[data-ffc-design="tiles"]:not([data-ffc-design="classic"]) .ffc-offer .ffc-terms { margin-top: 10px; }
.ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-grid { gap: 8px; }
.ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-offer { box-shadow: none; }
@container (min-width: 560px) {
  .ffc[data-ffc-design="two_column"]:not([data-ffc-design="classic"]) .ffc-grid,
  .ffc[data-ffc-design="three_column"]:not([data-ffc-design="classic"]) .ffc-grid,
  .ffc[data-ffc-design="tiles"]:not([data-ffc-design="classic"]) .ffc-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@container (min-width: 920px) {
  .ffc[data-ffc-design="three_column"]:not([data-ffc-design="classic"]) .ffc-grid,
  .ffc[data-ffc-design="tiles"]:not([data-ffc-design="classic"]) .ffc-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
}
@container (min-width: 680px) {
  .ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-offer { display: grid; grid-template-columns: minmax(0,1fr) 220px; column-gap: 24px; align-content: start; }
  .ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-offer > * { grid-column: 1; }
  .ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-offer > .ffc-code-action,
  .ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-offer > .ffc-button { grid-column: 2; grid-row: 1 / span 4; align-self: center; margin-top: 0; }
  .ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-offer > .ffc-terms,
  .ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-offer > .ffc-card-status { grid-column: 1 / -1; }
  .ffc[data-ffc-design="rows"]:not([data-ffc-design="classic"]) .ffc-offer .ffc-offer-meta { margin-bottom: 0; }
}
/* A separate historical section establishes the same local-width layout rules. */
.ffc[data-ffc-design]:not([data-ffc-design="classic"]) .ffc-expired { container-type: inline-size; padding: 16px; }
/* Optional dated verification is compact, subordinate to the saving and action. */
.ffc .ffc-offer-verification{display:flex;flex-wrap:wrap;gap:.2rem .55rem;align-items:center;font-size:.8rem;line-height:1.45;margin:.35rem 0}
.ffc .ffc-verification-result{font-weight:600}
.ffc .ffc-named-module>.ffc-ui-heading{margin:0 0 .65rem}

/* rc24: one tick, even when themes style every list item or add a second marker. */
.ffc .ffc-trust .ffc-check-list > li { display:block; list-style:none!important; }
.ffc .ffc-trust .ffc-check-list > li::marker { content:""!important; }
.ffc .ffc-trust .ffc-check-list > li::after { content:none!important; display:none!important; }
.ffc .ffc-trust .ffc-check-list > li::before { content:"\2713"!important; background:none!important; border:0!important; }
