/* ==========================================================================
   Foundation "Our Impact - Problem" (nafas.com/foundation, Global version)
   Live: frame .framer-vbyfia (desktop >= 1200 and tablet 810-1199.98) and .framer-pix7fw (phone).
   The section is the 12px-padded column slot (padding 0 12px 12px); the rounded photo frame is its child.
   Desktop: content column 936 wide (gap 40); cards are rows (padding 40 60, space-between) with a 334px text side.
   Tablet: content column 546 wide (wider than the 506 box at 810, centred like live), cards stack (gap 40, red 20),
   the second card turns white. Phone: frame padding 80 20, 24px statements, separate plain cards (gap 20, padding 40)
   with full stops instead of footnote marks and Inter 10px footnotes that do not fade.
   Hover (>= 810, pointer devices): card background to black, text to white, red card background to black.
   Live mixes colours in linear light with a spring (~0.4s, 1.5% overshoot); reproduced per direction with
   linear() curves: darkening uses 1 - sqrt(1 - s(t)), lightening sqrt(s(t)).
   Text fades (opacity only) in at >= 50% in view and out again below it (spring, ~0.5s).
   ========================================================================== */

@font-face { font-family: Inter; src: url("../../../assets/fonts/inter-400-latin.woff2") format("woff2"); font-display: swap; font-style: normal; font-weight: 400; unicode-range: U+0-FF, U+131, U+152-153, U+2BB-2BC, U+2C6, U+2DA, U+2DC, U+2000-206F, U+2070, U+2074-207E, U+2080-208E, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

.nf-fd-problem {
  --nf-fd-problem-font: "SF Pro Display Regular", "SF Pro Display Regular Placeholder", sans-serif;
  --nf-fd-problem-card-font: "SF Pro Display Regular", sans-serif;
  --nf-fd-problem-fade: linear(0, 0.0142, 0.051, 0.1032, 0.1653, 0.2329, 0.3026, 0.372, 0.4394, 0.5033, 0.5632, 0.6184, 0.6688, 0.7143, 0.7551, 0.7913, 0.8232, 0.8511, 0.8754, 0.8964, 0.9145, 0.9299, 0.943, 0.954, 0.9633, 0.971, 0.9774, 0.9826, 0.9869, 0.9904, 0.9931, 0.9953, 0.9971, 0.9984, 0.9994, 1.0001, 1.0007, 1.0011, 1.0013, 1.0015, 1);
  --nf-fd-problem-darken: linear(0, 0.0117, 0.0419, 0.085, 0.1372, 0.1952, 0.2568, 0.3203, 0.3842, 0.4475, 0.5094, 0.5695, 0.6273, 0.6828, 0.736, 0.7874, 0.838, 0.8906, 0.9608, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
  --nf-fd-problem-lighten: linear(0, 0.1523, 0.2863, 0.4035, 0.5055, 0.5935, 0.6691, 0.7335, 0.7879, 0.8335, 0.8714, 0.9026, 0.928, 0.9484, 0.9645, 0.9771, 0.9868, 0.994, 0.9992, 1.0029, 1.0053, 1.0067, 1.0074, 1.0076, 1.0073, 1.0069, 1.0062, 1.0055, 1.0048, 1.0041, 1.0034, 1.0028, 1.0022, 1.0018, 1.0014, 1.001, 1.0007, 1.0005, 1.0003, 1.0002, 1);
  position: relative;
  width: 100%;
  padding: 0 12px 12px;
  background: var(--nf-white);
}

/* ---------- desktop (>= 1200) ---------- */
.nf-fd-problem__frame {
  position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 40px;
  width: 100%; height: min-content; padding: 140px;
  border-radius: 12px; overflow: clip; will-change: transform;
}
.nf-fd-problem__bg { position: absolute; inset: 0; border-radius: 12px; }
.nf-fd-problem__bg picture { display: contents; }
.nf-fd-problem__bg-img {
  display: block; width: 100%; height: 100%; border-radius: 12px;
  object-fit: cover; object-position: 50% 50%;
}
.nf-fd-problem__inner {
  position: relative; flex: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 40px;
  width: 936px; height: min-content; padding: 0; overflow: clip;
}
.nf-fd-problem__box { position: relative; flex: none; width: 100%; }
.nf-fd-problem__lead {
  font-family: var(--nf-fd-problem-font); font-weight: 400; font-style: normal;
  font-size: 36px; line-height: 1.2em; letter-spacing: normal; text-align: left; color: rgb(255, 255, 255);
  white-space: pre-wrap; word-break: break-word; overflow-wrap: break-word;
}
.nf-fd-problem__green { color: rgb(145, 200, 81); }

.nf-fd-problem__cards.nf-fd-problem__phone, .nf-fd-problem__pcard.nf-fd-problem__phone { display: none; }

/* cards >= 810 */
.nf-fd-problem__cards {
  position: relative; flex: none;
  display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 10px;
  width: 100%; height: min-content; padding: 0; overflow: clip;
}
.nf-fd-problem__card, .nf-fd-problem__red {
  position: relative; flex: none;
  display: flex; flex-direction: row; align-items: center; justify-content: space-between;
  width: 100%; height: min-content; padding: 40px 60px;
  border-radius: 12px; overflow: clip; will-change: transform; cursor: pointer;
  transition: background-color 0.4s var(--nf-fd-problem-lighten);
}
.nf-fd-problem__card--white { background-color: rgb(255, 255, 255); }
.nf-fd-problem__card--grey { background-color: rgb(245, 245, 245); }
.nf-fd-problem__red { background-color: rgb(181, 45, 45); }
.nf-fd-problem__pre { position: relative; flex: none; width: auto; height: auto; white-space: pre; }
.nf-fd-problem__wrap { position: relative; flex: none; width: 100%; height: auto; }
.nf-fd-problem__side {
  position: relative; flex: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  width: min-content; height: min-content; padding: 0; overflow: clip;
}
.nf-fd-problem__side--red { gap: 10px; }
.nf-fd-problem__side .nf-fd-problem__wrap { width: 334px; }
.nf-fd-problem__label, .nf-fd-problem__num, .nf-fd-problem__desc, .nf-fd-problem__note {
  font-family: var(--nf-fd-problem-card-font); font-weight: 400; font-style: normal;
  line-height: 1.2em; letter-spacing: normal; text-align: left; color: rgb(0, 0, 0);
  transition: color 0.4s var(--nf-fd-problem-darken);
}
.nf-fd-problem__label { font-size: 21px; white-space: pre; }
.nf-fd-problem__num { font-size: 32px; white-space: pre; }
.nf-fd-problem__desc { font-size: 21px; white-space: pre-wrap; word-break: break-word; overflow-wrap: break-word; }
.nf-fd-problem__note { font-size: 12px; white-space: pre-wrap; word-break: break-word; overflow-wrap: break-word; }
.nf-fd-problem__red .nf-fd-problem__label, .nf-fd-problem__red .nf-fd-problem__num,
.nf-fd-problem__red .nf-fd-problem__desc, .nf-fd-problem__red .nf-fd-problem__note { color: rgb(255, 255, 255); }
.nf-fd-problem__red-head {
  position: relative; flex: none;
  display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 10px;
  width: min-content; height: min-content; padding: 0; overflow: visible;
}
.nf-fd-problem__red-label { position: relative; flex: none; width: 117px; height: auto; }
.nf-fd-problem__red-label .nf-fd-problem__label { white-space: pre-wrap; word-break: break-word; overflow-wrap: break-word; }

@media (hover: hover) {
  .nf-fd-problem__card:hover, .nf-fd-problem__red:hover {
    background-color: rgb(0, 0, 0);
    transition: background-color 0.4s var(--nf-fd-problem-darken);
  }
  .nf-fd-problem__card:hover .nf-fd-problem__label, .nf-fd-problem__card:hover .nf-fd-problem__num,
  .nf-fd-problem__card:hover .nf-fd-problem__desc, .nf-fd-problem__card:hover .nf-fd-problem__note {
    color: rgb(255, 255, 255);
    transition: color 0.4s var(--nf-fd-problem-lighten);
  }
}

/* text fades */
.nf-fd-problem [data-fd-fade] { opacity: 0; transition: opacity 0.5s var(--nf-fd-problem-fade); }
.nf-fd-problem [data-fd-fade].is-in { opacity: 1; }
@media (scripting: none) { .nf-fd-problem [data-fd-fade] { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .nf-fd-problem [data-fd-fade] { opacity: 1; transition: none; }
  .nf-fd-problem__card, .nf-fd-problem__red, .nf-fd-problem__card *, .nf-fd-problem__red * { transition: none !important; }
}

/* ---------- tablet (810 - 1199.98): 546 column, stacked cards ---------- */
@media (min-width: 810px) and (max-width: 1199.98px) {
  .nf-fd-problem__inner { width: 546px; }
  .nf-fd-problem__card {
    flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: 40px;
  }
  .nf-fd-problem__card--grey { background-color: rgb(255, 255, 255); }
  .nf-fd-problem__card .nf-fd-problem__side { width: 100%; }
  .nf-fd-problem__card .nf-fd-problem__side .nf-fd-problem__wrap { width: 100%; }
  .nf-fd-problem__red { flex-direction: column; align-items: flex-start; justify-content: center; gap: 20px; }
  .nf-fd-problem__red-head { flex-direction: column; align-content: flex-start; align-items: flex-start; width: 117px; height: 82px; }
}

/* ---------- phone (<= 809.98) ---------- */
@media (max-width: 809.98px) {
  .nf-fd-problem__frame { align-items: flex-start; justify-content: flex-start; padding: 80px 20px; }
  .nf-fd-problem__inner { align-items: flex-start; justify-content: flex-start; width: 100%; overflow: visible; }
  .nf-fd-problem__lead { font-size: 24px; }
  .nf-fd-problem__wide { display: none; }
  .nf-fd-problem__cards.nf-fd-problem__phone, .nf-fd-problem__pcard.nf-fd-problem__phone { display: flex; }
  .nf-fd-problem__cards { justify-content: flex-start; gap: 20px; }
  .nf-fd-problem__pcard {
    position: relative; flex: none;
    flex-direction: column; align-items: flex-start; justify-content: center; gap: 20px;
    width: 100%; height: min-content; padding: 40px;
    background-color: rgb(255, 255, 255); border-radius: 12px; overflow: clip; will-change: transform;
  }
  .nf-fd-problem__cards .nf-fd-problem__pcard { display: flex; }
  .nf-fd-problem__pcard--red { background-color: rgb(181, 45, 44); }
  .nf-fd-problem__plabel, .nf-fd-problem__pdesc {
    font-family: var(--nf-fd-problem-font); font-weight: 400; font-style: normal;
    line-height: 1.2em; letter-spacing: normal; text-align: left; color: rgb(0, 0, 0);
    white-space: pre-wrap; word-break: break-word; overflow-wrap: break-word;
  }
  .nf-fd-problem__plabel { font-size: 18px; }
  .nf-fd-problem__pdesc { font-size: 16px; }
  .nf-fd-problem__pdesc--small { font-size: 14px; }
  .nf-fd-problem__pcard .nf-fd-problem__num { font-family: var(--nf-fd-problem-font); transition: none; }
  .nf-fd-problem__num--wrap { white-space: pre-wrap; word-break: break-word; overflow-wrap: break-word; }
  .nf-fd-problem__pnote {
    font-family: Inter, "Inter Placeholder", sans-serif; font-weight: 400; font-style: normal;
    font-size: 10px; line-height: 1.2em; letter-spacing: 0em; text-align: start; color: rgb(0, 0, 0);
    white-space: pre-wrap; word-break: break-word; overflow-wrap: break-word;
  }
  .nf-fd-problem__pcard--red .nf-fd-problem__plabel, .nf-fd-problem__pcard--red .nf-fd-problem__num,
  .nf-fd-problem__pcard--red .nf-fd-problem__pdesc, .nf-fd-problem__pcard--red .nf-fd-problem__pnote { color: rgb(255, 255, 255); }
}
