/* ==========================================================
   CAS Site FAQ v1.0.0
   Searchable FAQ layout for /faq/ and /it/faq/.
   Central theme asset, no inline CSS required.
   ========================================================== */

.cas-faq-page {
  max-width: 1120px;
  margin: 0 auto;
}

.cas-faq-page .cas-faq-hero {
  position: relative;
  overflow: hidden;
}

.cas-faq-page .cas-faq-hero::after {
  content: "";
  position: absolute;
  inset: auto -140px -180px auto;
  width: 360px;
  height: 360px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(124, 58, 237, .18), rgba(124, 58, 237, 0) 68%);
  pointer-events: none;
}

.cas-faq-toolbar {
  position: sticky;
  top: 88px;
  z-index: 5;
  margin: 26px 0 30px;
  padding: 16px;
  border: 1px solid rgba(124, 58, 237, .16);
  border-radius: 28px;
  background: linear-gradient(145deg, rgba(255,255,255,.92), rgba(248,245,255,.82));
  box-shadow: 0 24px 70px rgba(59, 34, 94, .08);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.cas-faq-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}

.cas-faq-search input {
  width: 100%;
  border: 1px solid rgba(124, 58, 237, .18);
  border-radius: 999px;
  background: #ffffff;
  padding: 15px 18px;
  color: #172033;
  font-size: 16px;
  font-weight: 650;
  line-height: 1.3;
  box-shadow: 0 14px 34px rgba(15, 23, 42, .05);
}

.cas-faq-search input:focus {
  outline: none;
  border-color: rgba(124, 58, 237, .54);
  box-shadow: 0 0 0 5px rgba(124, 58, 237, .13);
}

.cas-faq-clear,
.cas-faq-control,
.cas-faq-chip {
  appearance: none;
  border: 1px solid rgba(124, 58, 237, .18);
  border-radius: 999px;
  background: rgba(255,255,255,.84);
  color: #5b21b6;
  cursor: pointer;
  font-weight: 850;
  line-height: 1;
  transition: transform .18s ease, background .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.cas-faq-clear {
  padding: 14px 17px;
}

.cas-faq-clear:hover,
.cas-faq-control:hover,
.cas-faq-chip:hover {
  transform: translateY(-1px);
  background: #ffffff;
  border-color: rgba(124, 58, 237, .34);
  box-shadow: 0 12px 30px rgba(124, 58, 237, .12);
}

.cas-faq-chips,
.cas-faq-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cas-faq-chips {
  margin-top: 14px;
}

.cas-faq-chip {
  padding: 10px 13px;
  font-size: 13px;
}

.cas-faq-chip.is-active,
.cas-faq-chip[aria-pressed="true"] {
  color: #ffffff;
  border-color: rgba(124, 58, 237, .65);
  background: linear-gradient(135deg, #7c3aed, #6d28d9);
  box-shadow: 0 14px 34px rgba(124, 58, 237, .22);
}

.cas-faq-controls {
  justify-content: space-between;
  align-items: center;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(124, 58, 237, .10);
}

.cas-faq-count {
  margin: 0;
  color: #64748b;
  font-size: 13px;
  font-weight: 750;
}

.cas-faq-control {
  padding: 10px 13px;
  font-size: 13px;
}

.cas-faq-groups {
  display: grid;
  gap: 22px;
}

.cas-faq-group {
  border: 1px solid rgba(124, 58, 237, .14);
  border-radius: 30px;
  background: linear-gradient(145deg, rgba(255,255,255,.90), rgba(248,250,252,.72));
  box-shadow: 0 22px 70px rgba(15, 23, 42, .06);
  overflow: hidden;
}

.cas-faq-group__head {
  padding: 24px 26px 16px;
  border-bottom: 1px solid rgba(124, 58, 237, .10);
}

.cas-faq-group__head .cas-kicker,
.cas-faq-group__head h2,
.cas-faq-group__head p {
  margin-top: 0;
}

.cas-faq-group__head h2 {
  margin-bottom: 8px;
}

.cas-faq-group__head p {
  max-width: 820px;
  margin-bottom: 0;
  color: #64748b;
  font-size: 15px;
  line-height: 1.6;
}

.cas-faq-list {
  display: grid;
  gap: 12px;
  padding: 18px;
}

.cas-faq-item {
  border: 1px solid rgba(124, 58, 237, .13);
  border-radius: 22px;
  background: rgba(255,255,255,.92);
  box-shadow: 0 12px 34px rgba(15, 23, 42, .04);
  overflow: hidden;
}

.cas-faq-item[open] {
  border-color: rgba(124, 58, 237, .28);
  box-shadow: 0 18px 44px rgba(124, 58, 237, .10);
}

.cas-faq-item summary {
  position: relative;
  list-style: none;
  cursor: pointer;
  padding: 18px 56px 18px 20px;
  color: #172033;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.35;
}

.cas-faq-item summary::-webkit-details-marker {
  display: none;
}

.cas-faq-item summary::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 18px;
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #f4efff;
  color: #6d28d9;
  font-size: 22px;
  font-weight: 800;
  transform: translateY(-50%);
  transition: transform .18s ease, background .18s ease;
}

.cas-faq-item[open] summary::after {
  content: "−";
  background: #ede9fe;
}

.cas-faq-answer {
  padding: 0 20px 20px;
  color: #475569;
  font-size: 15px;
  line-height: 1.72;
}

.cas-faq-answer p,
.cas-faq-answer ul {
  margin-top: 0;
}

.cas-faq-answer p:last-child,
.cas-faq-answer ul:last-child {
  margin-bottom: 0;
}

.cas-faq-answer a {
  font-weight: 850;
}

.cas-faq-empty {
  display: none;
  margin: 24px 0 0;
  padding: 22px;
  border: 1px dashed rgba(124, 58, 237, .34);
  border-radius: 24px;
  background: rgba(255,255,255,.78);
  color: #475569;
  font-weight: 750;
  text-align: center;
}

.cas-faq-empty.is-visible {
  display: block;
}

.cas-faq-item.is-hidden,
.cas-faq-group.is-hidden {
  display: none;
}

.cas-faq-bottom-cta {
  margin-top: 28px;
  text-align: center;
}

@media (max-width: 900px) {
  .cas-faq-toolbar {
    top: 0;
    position: relative;
  }
}

@media (max-width: 720px) {
  .cas-faq-search {
    grid-template-columns: 1fr;
  }

  .cas-faq-controls {
    align-items: flex-start;
  }

  .cas-faq-group__head {
    padding: 20px 18px 14px;
  }

  .cas-faq-list {
    padding: 14px;
  }

  .cas-faq-item summary {
    padding: 16px 50px 16px 16px;
    font-size: 16px;
  }

  .cas-faq-answer {
    padding: 0 16px 18px;
    font-size: 14px;
  }
}
