/* FoodZy Case Study Card. All selectors and variables are prefixed with fz- to avoid theme clashes. */
.fz-wrap, .fz-modal {
  --fz-bg: #ffffff;
  --fz-fg: #101a2e;
  --fz-muted: #4a5568;
  --fz-accent: #1f5fa6;
  --fz-line: #cdd4dc;
  --fz-surface: #f2f4f7;
  --fz-stage1: #efebe7;
  --fz-stage2: #e1dcd6;
  --fz-scrim: rgba(10, 16, 28, 0.62);
  --fz-brand: #ff6b35;
  --fz-ink: #1f2937;
  --fz-app-bg: #ffffff;
  --fz-app-fg: #1f2937;
  --fz-app-muted: #8a93a0;
  --fz-app-line: #e6e9ee;
  --fz-app-soft: #f5f6f8;
  --fz-display: 'Outfit', system-ui, sans-serif;
  --fz-serif: 'Source Serif 4', Georgia, serif;
  --fz-app: 'Poppins', system-ui, sans-serif;
  color: var(--fz-fg);
  font-family: var(--fz-serif);
  font-size: 16px;
  line-height: 1.5;
  text-align: left;
}
.fz-wrap *, .fz-wrap *::before, .fz-wrap *::after,
.fz-modal *, .fz-modal *::before, .fz-modal *::after { box-sizing: border-box; }
.fz-modal[hidden] { display: none !important; }
.fz-wrap :focus-visible, .fz-modal :focus-visible { outline: 3px solid var(--fz-accent); outline-offset: 3px; }
.fz-wrap h2, .fz-wrap h3, .fz-modal h2, .fz-modal h3 {
  font-family: var(--fz-display); text-wrap: balance; margin: 0; padding: 0;
  color: var(--fz-fg); text-transform: none; letter-spacing: normal; font-style: normal; line-height: 1.2;
}
.fz-wrap p, .fz-modal p { margin-bottom: 0; }
.fz-cat {
  font-family: var(--fz-display); font-weight: 500; font-size: 14px;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--fz-accent);
}

/* Card */
.fz-card { display: flex; flex-direction: column; min-width: 0; border-bottom: 1px solid var(--fz-line); }
.fz-stage {
  container-type: inline-size;
  background: linear-gradient(160deg, var(--fz-stage1), var(--fz-stage2));
  padding: 36px 16px 28px;
  border-bottom: 1px solid var(--fz-line);
}
.fz-card .fz-stage { --fz-max: 12px; }
.fz-card-body { padding: 28px 0 32px; }
.fz-card-body h2 { font-size: clamp(26px, 3.4vw, 34px); font-weight: 600; margin: 10px 0 14px; }
.fz-card-body p { margin: 0; color: var(--fz-muted); font-size: 19px; line-height: 1.6; max-width: 46ch; }
.fz-btn {
  font-family: var(--fz-display); font-weight: 600; font-size: 18px; cursor: pointer;
  border-radius: 999px; padding: 14px 32px; text-decoration: none; display: inline-block;
  border: 2px solid var(--fz-accent); color: var(--fz-accent); background: transparent;
  transition: background 0.15s, color 0.15s;
}
.fz-btn:hover { background: var(--fz-accent); color: var(--fz-bg); }
.fz-btn.fz-solid { background: var(--fz-accent); color: var(--fz-bg); }
.fz-btn.fz-solid:hover { opacity: 0.88; }
.fz-card .fz-btn { margin-top: 26px; }


/* Dialog */
.fz-modal {
  position: fixed; inset: 0; z-index: 100000; background: var(--fz-scrim);
  display: flex; align-items: center; justify-content: center;
  padding: calc(16px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) calc(16px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
}
.fz-panel {
  width: min(940px, 100%); max-height: 100%; overflow-y: auto; overscroll-behavior: contain;
  background: var(--fz-bg); border: 1px solid var(--fz-line); border-radius: 20px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
}
@keyframes fz-rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.fz-modal:not([hidden]) .fz-panel { animation: fz-rise 0.25s ease-out; }
@media (prefers-reduced-motion: reduce) { .fz-modal:not([hidden]) .fz-panel { animation: none; } }
.fz-m-head {
  position: sticky; top: 0; z-index: 5; background: var(--fz-bg); border-bottom: 1px solid var(--fz-line);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px clamp(20px, 4vw, 40px);
}
.fz-m-head h2 { font-size: 20px; font-weight: 600; margin-top: 2px; }
.fz-x { width: 42px; height: 42px; border-radius: 50%; border: 1.5px solid var(--fz-line); background: var(--fz-surface); color: var(--fz-fg); cursor: pointer; display: grid; place-items: center; flex: none; }
.fz-x:hover { border-color: var(--fz-accent); color: var(--fz-accent); }
.fz-x svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.fz-m-body { padding: 0 clamp(20px, 4vw, 40px) clamp(24px, 4vw, 40px); }
.fz-m-hero { margin-top: clamp(20px, 3vw, 32px); border-radius: 14px; overflow: hidden; border: 1px solid var(--fz-line); }
.fz-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.fz-tags span { font-family: var(--fz-display); font-size: 14px; font-weight: 500; padding: 6px 14px; border-radius: 999px; background: var(--fz-surface); border: 1px solid var(--fz-line); }
.fz-m-title { font-size: clamp(30px, 4.6vw, 44px); font-weight: 600; margin-top: 22px; }
.fz-sec { display: grid; grid-template-columns: minmax(0, 170px) minmax(0, 1fr); gap: 12px 32px; padding-block: 32px; border-top: 1px solid var(--fz-line); margin-top: 32px; }
.fz-sec:first-of-type { margin-top: 28px; }
.fz-sec > h3 { font-size: 14px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--fz-accent); padding-top: 4px; }
.fz-sec p, .fz-sec li { font-size: 18px; line-height: 1.65; color: var(--fz-muted); }
.fz-sec p { margin: 0; }
.fz-lead { font-size: 22px !important; line-height: 1.55 !important; color: var(--fz-fg) !important; }
.fz-sec ul { margin: 0; padding-left: 1.1em; display: flex; flex-direction: column; gap: 10px; }
.fz-snap { margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.fz-snap dt { font-family: var(--fz-display); font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--fz-muted); }
.fz-snap dd { margin: 4px 0 0; font-family: var(--fz-display); font-size: 18px; font-weight: 500; color: var(--fz-fg); }
.fz-feat { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 28px !important; }
.fz-feat b { display: block; font-family: var(--fz-display); font-weight: 600; font-size: 18px; color: var(--fz-fg); }
.fz-feat span { font-size: 16px; line-height: 1.5; }
.fz-steps { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px !important; counter-reset: s; }
.fz-steps li { counter-increment: s; border-top: 3px solid var(--fz-accent); padding-top: 12px; }
.fz-steps li::before { content: counter(s); font-family: var(--fz-display); font-weight: 600; color: var(--fz-accent); }
.fz-steps b { display: block; font-family: var(--fz-display); font-size: 18px; color: var(--fz-fg); margin: 2px 0 6px; }
.fz-steps span { font-size: 15px; line-height: 1.5; display: block; }
.fz-swatches { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.fz-sw i { display: block; height: 64px; border-radius: 12px; border: 1px solid var(--fz-line); }
.fz-sw b { display: block; font-family: var(--fz-display); font-size: 15px; color: var(--fz-fg); margin-top: 8px; }
.fz-sw span { font-size: 14px; color: var(--fz-muted); font-variant-numeric: tabular-nums; }
.fz-type { display: flex; align-items: center; gap: 20px; margin-top: 20px; padding: 18px 20px; border: 1px solid var(--fz-line); border-radius: 12px; flex-wrap: wrap; }
.fz-type .fz-aa { font-family: var(--fz-app); font-weight: 600; font-size: 52px; line-height: 1; color: var(--fz-fg); }
.fz-type p { font-size: 16px; }
.fz-shots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.fz-shots figure { margin: 0; min-width: 0; }
.fz-shots figcaption { margin-top: 12px; font-size: 15px; line-height: 1.5; color: var(--fz-muted); }
.fz-shots figcaption b { display: block; font-family: var(--fz-display); font-size: 17px; color: var(--fz-fg); }
.fz-note { margin-top: 16px !important; padding: 14px 18px; border-radius: 10px; background: var(--fz-surface); font-size: 16px !important; }
.fz-m-foot { display: flex; flex-wrap: wrap; gap: 12px; padding-top: 28px; border-top: 1px solid var(--fz-line); }

@media (max-width: 720px) {
  .fz-sec { grid-template-columns: minmax(0, 1fr); }
  .fz-snap, .fz-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fz-feat { grid-template-columns: minmax(0, 1fr); }
  .fz-shots { grid-template-columns: minmax(0, 1fr); max-width: 320px; }
  .fz-swatches { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.fz-btn, .fz-x {
  -webkit-appearance: none; appearance: none; margin: 0; line-height: 1.2;
  box-shadow: none; text-transform: none; letter-spacing: normal; text-decoration: none;
}
.fz-x { padding: 0; }
.fz-btn { font-family: var(--fz-display); }
.fz-modal .fz-btn.fz-solid, .fz-modal .fz-btn.fz-solid:hover { color: var(--fz-bg); }
.fz-wrap img, .fz-modal img { max-width: 100%; }

/* Portfolio Case Studies additions */
.fz-grid { display: grid; gap: 40px; grid-template-columns: repeat(var(--fz-cols, 2), minmax(0, 1fr)); }
@media (max-width: 780px) { .fz-grid { grid-template-columns: minmax(0, 1fr); } }
.fz-stage.fz-has-img { padding: 0; }
.fz-stage img, .fz-m-hero img { display: block; width: 100%; height: auto; margin: 0; }
.fz-ph { aspect-ratio: 4 / 3; display: grid; place-items: center; padding: 24px; text-align: center;
  font-family: var(--fz-display); font-size: 18px; color: var(--fz-muted); }
.fz-m-hero .fz-stage { border-bottom: 0; }
.fz-type .fz-aa { font-family: var(--fz-display); }
.fz-shots img { border: 1px solid var(--fz-line); border-radius: 12px; }
@media (max-width: 720px) { .fz-shots { max-width: none; } }
.fz-card .fz-btn { margin-top: 26px; }
.fz-lead-p { margin: 0; }
