/* Home: FAQ (resources/views/home/faq.blade.php). Prefix: agh-faq- */

.agh-faq { background: var(--ag-bg-alt); overflow: clip; isolation: isolate; }
.agh-faq > .container { position: relative; z-index: 1; }

/* ---------- Decoration ---------- */
.agh-faq-deco { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.agh-faq-blob {
  position: absolute; width: 420px; height: 420px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, var(--ag-glow), transparent 68%);
  filter: blur(8px); opacity: .9;
  animation: ag-blob 26s ease-in-out infinite;
}
.agh-faq-blob-1 { top: -140px; left: -160px; }
.agh-faq-blob-2 { bottom: -180px; right: -140px; width: 520px; height: 520px; animation-duration: 32s; animation-direction: reverse; }

/* ---------- Left column ---------- */
.agh-faq-aside { position: sticky; top: 96px; }
.agh-faq-lead { max-width: 30rem; margin-bottom: 28px; }

.agh-faq-card {
  position: relative; overflow: hidden; isolation: isolate;
  background: var(--ag-grad); color: #fff;
  border-radius: var(--ag-radius); padding: 30px 28px 28px;
  box-shadow: var(--ag-shadow-lg);
}
.agh-faq-card::after { /* soft sheen sweep */
  content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 45%; z-index: -1;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .10), transparent);
  transform: translateX(-130%) skewX(-20deg);
  animation: ag-shimmer 7s ease-in-out 1.5s infinite;
}
/* thin solid ring; a conic sheen travels slowly around it */
.agh-faq-card-ring {
  position: absolute; z-index: -1; top: -70px; right: -70px; width: 220px; height: 220px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .2);
}
.agh-faq-card-ring::before {
  content: ""; position: absolute; inset: -1px; border-radius: 50%; padding: 1.5px;
  background: conic-gradient(from 0deg, rgba(255, 255, 255, 0) 0deg 200deg, rgba(255, 255, 255, .5) 292deg, rgba(209, 250, 229, .95) 320deg, rgba(255, 255, 255, 0) 342deg 360deg);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  animation: ag-spin-slow 16s linear infinite;
}
.agh-faq-card-ring-2 {
  top: -30px; right: -30px; width: 140px; height: 140px;
  border: 1px solid rgba(255, 255, 255, .16); background: rgba(255, 255, 255, .05);
}
.agh-faq-card-ring-2::before { content: none; }
.agh-faq-card-icon {
  display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 16px;
  background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .28);
  font-size: 1.45rem; color: #fff; margin-bottom: 18px;
  animation: ag-float 6s ease-in-out infinite;
}
.agh-faq-card-title { color: #fff; font-weight: 700; font-size: 1.35rem; line-height: 1.3; margin: 0 0 8px; }
.agh-faq-card-text { color: rgba(255, 255, 255, .86); line-height: 1.7; margin: 0 0 16px; max-width: 26rem; }
.agh-faq-card-chips { list-style: none; padding: 0; margin: 0 0 22px; display: flex; flex-wrap: wrap; gap: 8px; }
.agh-faq-card-chips li {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: .82rem; font-weight: 600; color: #fff;
  padding: 6px 12px; border-radius: 999px;
  background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .22);
}
.agh-faq-card-chips i { color: #6EE7B7; }
.agh-faq-card-btn {
  display: inline-flex; align-items: center; gap: 10px;
  background: #fff; color: #034D3B; font-weight: 600; text-decoration: none;
  padding: 13px 26px; border-radius: 999px;
  box-shadow: 0 12px 26px rgba(2, 44, 34, .28);
  transition: translate .35s var(--ag-ease), transform .3s var(--ag-ease), box-shadow .3s var(--ag-ease), color .3s;
}
.agh-faq-card-btn i { transition: transform .3s var(--ag-ease); }
.agh-faq-card-btn:hover { color: #022C22; box-shadow: 0 18px 34px rgba(2, 44, 34, .36); }
.agh-faq-card-btn:hover i { transform: translateX(4px); }
.agh-faq-card-btn:focus-visible { outline: 3px solid #6EE7B7; outline-offset: 3px; }

/* ---------- Accordion ---------- */
.agh-faq-list { display: flex; flex-direction: column; gap: 14px; }

.agh-faq-item {
  position: relative;
  background: var(--ag-surface);
  border: 1px solid var(--ag-line);
  border-radius: var(--ag-radius);
  box-shadow: 0 1px 2px rgba(2, 44, 34, .04);
  transition: border-color .35s var(--ag-ease), box-shadow .35s var(--ag-ease), background-color .35s;
}
.agh-faq-item::before { /* brand accent bar, grows in when open */
  content: ""; position: absolute; left: -1px; top: 18px; bottom: 18px; width: 3px; border-radius: 3px;
  background: linear-gradient(180deg, #12A37A, #05664F);
  transform: scaleY(0); transform-origin: 50% 0; opacity: 0;
  transition: transform .45s var(--ag-ease), opacity .3s;
}
html[data-theme="dark"] .agh-faq-item::before { background: linear-gradient(180deg, #6EE7B7, #10B981); }

.agh-faq-item:hover { border-color: color-mix(in srgb, var(--ag-brand) 40%, var(--ag-line)); box-shadow: var(--ag-shadow); }

.agh-faq-item[open]:not(.is-closing) {
  border-color: var(--ag-brand);
  background: linear-gradient(180deg, var(--ag-brand-soft), transparent 75%), var(--ag-surface);
  box-shadow: 0 0 0 4px var(--ag-glow), var(--ag-shadow);
}
.agh-faq-item[open]:not(.is-closing)::before { transform: scaleY(1); opacity: 1; }

.agh-faq-q {
  display: flex; align-items: center; gap: 16px;
  padding: 20px 22px; cursor: pointer; list-style: none;
  border-radius: var(--ag-radius);
  -webkit-tap-highlight-color: transparent;
}
.agh-faq-q::-webkit-details-marker { display: none; }
.agh-faq-q::marker { content: ""; }
.agh-faq-q:focus { outline: none; }
.agh-faq-q:focus-visible { outline: 3px solid var(--ag-brand-mid); outline-offset: -3px; }

.agh-faq-num {
  flex: 0 0 auto; font-size: .78rem; font-weight: 700; letter-spacing: .06em;
  color: var(--ag-muted); min-width: 1.6rem; font-variant-numeric: tabular-nums;
  transition: color .3s;
}
.agh-faq-q-text {
  flex: 1 1 auto; font-weight: 600; font-size: 1.05rem; line-height: 1.45; color: var(--ag-ink);
  transition: color .3s;
}
.agh-faq-item:hover .agh-faq-q-text,
.agh-faq-item[open]:not(.is-closing) .agh-faq-q-text { color: var(--ag-brand); }
.agh-faq-item[open]:not(.is-closing) .agh-faq-num { color: var(--ag-brand); }

/* plus -> minus */
.agh-faq-icon {
  position: relative; flex: 0 0 auto; width: 34px; height: 34px; border-radius: 50%;
  background: var(--ag-brand-soft); color: var(--ag-brand);
  transition: background-color .35s, color .35s, transform .45s var(--ag-ease);
}
.agh-faq-icon::before,
.agh-faq-icon::after {
  content: ""; position: absolute; top: 50%; left: 50%; width: 13px; height: 2px; margin: -1px 0 0 -6.5px;
  border-radius: 2px; background: currentColor;
  transition: transform .45s var(--ag-ease), opacity .3s;
}
.agh-faq-icon::after { transform: rotate(90deg); }
.agh-faq-item:hover .agh-faq-icon { transform: rotate(90deg); }
.agh-faq-item[open]:not(.is-closing) .agh-faq-icon {
  background: var(--ag-brand); color: var(--ag-on-brand); transform: rotate(180deg);
}
.agh-faq-item[open]:not(.is-closing) .agh-faq-icon::after { transform: rotate(90deg) scaleX(0); opacity: 0; }

.agh-faq-body { overflow: hidden; }
.agh-faq-inner { padding: 0 22px 22px calc(22px + 1.6rem + 16px); }
.agh-faq-inner p { margin: 0; color: var(--ag-text); line-height: 1.75; font-size: .98rem; }
.agh-faq-link {
  color: var(--ag-brand); font-weight: 600; text-decoration: underline;
  text-decoration-thickness: 1.5px; text-underline-offset: 3px;
  text-decoration-color: color-mix(in srgb, var(--ag-brand) 45%, transparent);
  transition: color .25s, text-decoration-color .25s;
}
.agh-faq-link:hover { color: var(--ag-brand-strong); text-decoration-color: currentColor; }
.agh-faq-link:focus-visible { outline: 2px solid var(--ag-brand-mid); outline-offset: 2px; border-radius: 4px; }

/* ---------- Dark ---------- */
html[data-theme="dark"] .agh-faq-item { box-shadow: none; }
html[data-theme="dark"] .agh-faq-item:hover { box-shadow: var(--ag-shadow); }
html[data-theme="dark"] .agh-faq-item[open]:not(.is-closing) { box-shadow: 0 0 0 4px var(--ag-glow), var(--ag-shadow); }
html[data-theme="dark"] .agh-faq-card { box-shadow: 0 24px 60px rgba(0, 0, 0, .45), 0 0 0 1px rgba(110, 231, 183, .12); }

/* ---------- Responsive ---------- */
@media (max-width: 991.98px) {
  .agh-faq-aside { position: static; }
  .agh-faq-lead { max-width: none; }
}
@media (max-width: 575.98px) {
  .agh-faq-q { padding: 16px 16px; gap: 12px; }
  .agh-faq-num { display: none; }
  .agh-faq-q-text { font-size: 1rem; }
  .agh-faq-inner { padding: 0 16px 18px; }
  .agh-faq-card { padding: 26px 20px 22px; }
  .agh-faq-card-btn { width: 100%; justify-content: center; }
  .agh-faq-blob { width: 300px; height: 300px; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .agh-faq-blob, .agh-faq-card::after, .agh-faq-card-ring::before, .agh-faq-card-icon { animation: none; }
  .agh-faq-item, .agh-faq-item::before, .agh-faq-icon, .agh-faq-icon::before, .agh-faq-icon::after,
  .agh-faq-card-btn, .agh-faq-card-btn i { transition: none; }
}
