/**
 * DiviPerfect Modules: DP FAQ. Markup: includes/faq.php; behaviour: faq.js.
 * Defaults weigh one class (:where() around the rest), so they beat theme resets and lose to the Design settings.
 */

.dp-faq {
  --dpfaq-accent: #2c59fa;
  --dpfaq-card: #f1f1f0;
  --dpfaq-ink: #060606;
  --dpfaq-line: rgba(6, 6, 6, .14);
  --dpfaq-radius: 14px;
  --dpfaq-gap: 12px;
  --dpfaq-pad: 24px;
  container-type: inline-size;
  min-width: 0;
  color: var(--dpfaq-ink);
}

/* ---------- search and Open All ---------- */
.dp-faq-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-bottom: 24px;
}
.dp-faq-search {
  position: relative;
  flex: 1 1 260px;
  display: block;
  margin: 0;
}
.dp-faq-search svg {
  position: absolute;
  left: 16px;
  top: 50%;
  width: 18px;
  height: 18px;
  transform: translateY(-50%);
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  opacity: .55;
  pointer-events: none;
}
:where(.dp-faq) .dp-faq-input {
  box-sizing: border-box;
  width: 100%;
  margin: 0;
  padding: 13px 18px 13px 44px;
  border: 1px solid var(--dpfaq-line);
  border-radius: var(--dpfaq-radius);
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 16px;
  line-height: 1.3;
  box-shadow: none;
}
.dp-faq .dp-faq-input:focus { outline: 2px solid var(--dpfaq-accent); outline-offset: 1px; border-color: transparent; }
.dp-faq-sr {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
:where(.dp-faq) .dp-faq-all {
  -webkit-appearance: none;
  appearance: none;
  margin: 0 0 0 auto;
  padding: 6px 2px;
  border: 0;
  background: none;
  color: var(--dpfaq-accent);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
}
.dp-faq .dp-faq-all:focus-visible { outline: 2px solid var(--dpfaq-accent); outline-offset: 3px; }
:where(.dp-faq) .dp-faq-none { margin: 20px 0 0; padding: 0; opacity: .7; }
.dp-faq-hide { display: none !important; }

/* ---------- list and questions ---------- */
.dp-faq-list { counter-reset: dpfaq; min-width: 0; }
/* Divi gives modules a bottom margin on phones; the questions are spaced by the FAQ itself. */
.dp-faq .dp-faq-list > .et_pb_module.dp-faq-cell { margin: 0; }
.dp-faq-entry { counter-increment: dpfaq; min-width: 0; }
:where(.dp-faq) .dp-faq-entry { margin: 0; padding: 0; border-bottom: 1px solid var(--dpfaq-line); }
.dp-faq .dp-faq-q {
  display: flex;
  align-items: center;
  gap: 16px;
  list-style: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.dp-faq .dp-faq-q::-webkit-details-marker { display: none; }
.dp-faq .dp-faq-q::marker { content: ''; }
:where(.dp-faq) .dp-faq-q { padding: 22px 0; }
.dp-faq .dp-faq-q:focus { outline: none; }
.dp-faq .dp-faq-q:focus-visible { outline: 2px solid var(--dpfaq-accent); outline-offset: 2px; border-radius: 4px; }
.dp-faq .dp-faq-qt { flex: 1 1 auto; min-width: 0; transition: color .25s ease; }
:where(.dp-faq) .dp-faq-qt {
  margin: 0;
  padding: 0;
  color: var(--dpfaq-ink);
  font-size: 19px;
  font-weight: 600;
  line-height: 1.35;
}
.dp-faq .dp-faq-q:hover .dp-faq-qt,
.dp-faq .dp-faq-entry[open]:not(.is-closing) > .dp-faq-q .dp-faq-qt { color: var(--dpfaq-accent); }
.dp-faq-num { display: none; }

/* Icons */
.dp-faq-icon {
  position: relative;
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: var(--dpfaq-accent);
  transition: transform .35s cubic-bezier(.2, .7, .3, 1), background-color .25s ease, color .25s ease;
}
.dp-faq[data-dpfaq-icon="none"] .dp-faq-icon { display: none; }
.dp-faq[data-dpfaq-side="left"] .dp-faq-icon { order: -1; }
.dp-faq[data-dpfaq-side="left"] .dp-faq-num { order: -2; }
.dp-faq[data-dpfaq-icon="plus"] .dp-faq-icon { box-shadow: inset 0 0 0 1.5px var(--dpfaq-line); }
.dp-faq[data-dpfaq-icon="plus"] .dp-faq-icon::before,
.dp-faq[data-dpfaq-icon="plus"] .dp-faq-icon::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 12px;
  height: 2px;
  margin: -1px 0 0 -6px;
  border-radius: 2px;
  background: currentColor;
  transition: transform .35s cubic-bezier(.2, .7, .3, 1);
}
.dp-faq[data-dpfaq-icon="plus"] .dp-faq-icon::after { transform: rotate(90deg); }
.dp-faq[data-dpfaq-icon="plus"] .dp-faq-entry[open]:not(.is-closing) > .dp-faq-q .dp-faq-icon { background: var(--dpfaq-accent); color: #fff; box-shadow: none; }
.dp-faq[data-dpfaq-icon="plus"] .dp-faq-entry[open]:not(.is-closing) > .dp-faq-q .dp-faq-icon::after { transform: rotate(0deg); }
.dp-faq[data-dpfaq-icon="chevron"] .dp-faq-icon::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 9px;
  height: 9px;
  margin: -7px 0 0 -5px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}
.dp-faq[data-dpfaq-icon="chevron"] .dp-faq-entry[open]:not(.is-closing) > .dp-faq-q .dp-faq-icon { transform: rotate(180deg); }

/* Answers */
.dp-faq .dp-faq-a { overflow: hidden; }
:where(.dp-faq) .dp-faq-ai { padding: 0 46px 24px 0; color: var(--dpfaq-ink); opacity: .78; line-height: 1.7; }
.dp-faq[data-dpfaq-side="left"] .dp-faq-ai,
.dp-faq[data-dpfaq-icon="none"] .dp-faq-ai { padding-right: 0; }
.dp-faq[data-dpfaq-side="left"]:not([data-dpfaq-icon="none"]) .dp-faq-ai { padding-left: 46px; }
.dp-faq .dp-faq-ai > :last-child { margin-bottom: 0; padding-bottom: 0; }
.dp-faq .dp-faq-ai a { color: var(--dpfaq-accent); }
:where(.dp-faq) .dp-faq-ai :is(ul, ol) { margin: 0 0 1em; padding: 0 0 0 1.4em; }
.dp-faq .dp-faq-ai ul { list-style: disc; }
.dp-faq .dp-faq-ai ol { list-style: decimal; }
:where(.dp-faq) .dp-faq-ai li { margin: 0 0 .3em; padding: 0; }

/* Lines: no line above the first question, one under each. */

/* Cards */
.dp-faq[data-dpfaq-style="cards"] .dp-faq-list { display: flex; flex-direction: column; gap: var(--dpfaq-gap); }
:where(.dp-faq[data-dpfaq-style="cards"]) .dp-faq-entry {
  padding: 0 var(--dpfaq-pad);
  border: 1px solid transparent;
  border-radius: var(--dpfaq-radius);
  background: var(--dpfaq-card);
  transition: border-color .25s ease, background-color .25s ease, box-shadow .25s ease;
}
.dp-faq[data-dpfaq-style="cards"] .dp-faq-entry[open]:not(.is-closing) { border-color: var(--dpfaq-accent); box-shadow: 0 12px 30px -18px rgba(6, 6, 6, .35); }

/* Boxed */
:where(.dp-faq[data-dpfaq-style="boxed"]) .dp-faq-list {
  overflow: hidden;
  border: 1px solid var(--dpfaq-line);
  border-radius: var(--dpfaq-radius);
}
:where(.dp-faq[data-dpfaq-style="boxed"]) .dp-faq-entry { padding: 0 var(--dpfaq-pad); transition: background-color .25s ease; }
.dp-faq[data-dpfaq-style="boxed"] .dp-faq-entry[open]:not(.is-closing) { background: var(--dpfaq-card); }
.dp-faq[data-dpfaq-style="boxed"] .dp-faq-list > :last-child .dp-faq-entry,
.dp-faq[data-dpfaq-style="boxed"] .dp-faq-list > .dp-faq-entry:last-child { border-bottom: 0; }

/* Numbered */
.dp-faq[data-dpfaq-style="numbered"] .dp-faq-num { display: block; flex: 0 0 auto; min-width: 2.2em; }
.dp-faq[data-dpfaq-style="numbered"] .dp-faq-num::before { content: counter(dpfaq, decimal-leading-zero); }
:where(.dp-faq[data-dpfaq-style="numbered"]) .dp-faq-num { color: var(--dpfaq-accent); font-size: 15px; font-weight: 700; letter-spacing: .04em; line-height: 1.35; }
:where(.dp-faq[data-dpfaq-style="numbered"]) .dp-faq-q { align-items: baseline; padding: 26px 0; }
.dp-faq[data-dpfaq-style="numbered"] .dp-faq-icon { align-self: center; }
.dp-faq[data-dpfaq-style="numbered"]:not([data-dpfaq-side="left"]) .dp-faq-ai { padding-left: calc(2.2em + 16px); }

/* Two Columns (one column when the module is narrow) */
.dp-faq[data-dpfaq-style="columns"] .dp-faq-list { display: grid; grid-template-columns: minmax(0, 1fr); column-gap: 48px; align-items: start; }
@container (min-width: 760px) {
  .dp-faq[data-dpfaq-style="columns"] .dp-faq-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  .dp-faq .dp-faq-icon, .dp-faq .dp-faq-icon::before, .dp-faq .dp-faq-icon::after, .dp-faq .dp-faq-entry { transition: none !important; }
}

@media (max-width: 600px) {
  .dp-faq { --dpfaq-pad: 18px; }
  :where(.dp-faq) .dp-faq-q { padding: 18px 0; }
  :where(.dp-faq) .dp-faq-qt { font-size: 17px; }
  :where(.dp-faq) .dp-faq-ai { padding-right: 0; }
  .dp-faq[data-dpfaq-style="numbered"]:not([data-dpfaq-side="left"]) .dp-faq-ai { padding-left: 0; }
}
