/* United Loans — FAQ page (faq.html).
   Loaded after united-site.css and united-sections.css. Reuses the header,
   .u-questions accordion, .u-btn and footer; adds the search hero, topic tabs,
   related cards and closing band. Classes are prefixed f-. */

/* ---------- Hero: headline, search, quick topics ---------- */
.f-hero {
  padding: clamp(56px, 8vw, 120px) 0 clamp(60px, 7.5vw, 110px);
  background: var(--navy); color: #fff; text-align: center;
}
.f-hero > .shell, .f-body > .shell, .f-related > .shell, .f-close > .shell { width: min(1480px, calc(100% - 80px)); }
.f-hero h1 {
  max-width: 15em; margin: 0 auto;
  font-size: clamp(38px, 5.2vw, 72px); line-height: 1.08; letter-spacing: -.025em;
}
.f-search {
  position: relative; display: block;
  width: min(640px, 100%); margin: clamp(32px, 4vw, 52px) auto 0;
}
.f-search .u-i { position: absolute; left: 26px; top: 50%; translate: 0 -50%; color: var(--muted); pointer-events: none; }
.f-search input {
  width: 100%; height: 72px; padding: 0 64px;
  border: 2px solid transparent; border-radius: 999px;
  background: #fff; color: var(--ink);
  font: inherit; font-size: 18px;
  box-shadow: 0 18px 40px -18px #000a;
  transition: border-color .18s;
}
.f-search input::placeholder { color: #53677cb3; }
.f-search input:focus-visible { outline: none; border-color: var(--green); }
.f-search input::-webkit-search-cancel-button { display: none; }
.f-clear {
  position: absolute; right: 16px; top: 50%; translate: 0 -50%;
  display: grid; place-items: center; width: 40px; height: 40px;
  border: 0; border-radius: 50%; background: var(--soft); color: var(--ink); cursor: pointer;
}
.f-clear:hover { background: var(--line); }
.f-clear[hidden] { display: none; }

.f-quick {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px;
  margin-top: 28px; font-size: 15px; font-weight: 700;
}
.f-quick span { margin-right: 6px; }
.f-quick button {
  min-height: 44px; padding: 10px 20px;
  border: 1px solid #ffffff3d; border-radius: 999px;
  background: transparent; color: #fff; font: inherit; cursor: pointer;
  transition: background .18s, border-color .18s, color .18s;
}
.f-quick button:hover { background: #fff; border-color: #fff; color: var(--navy); }

/* ---------- Topic tabs ---------- */
.f-body { padding: clamp(44px, 5.5vw, 80px) 0 clamp(72px, 8vw, 115px); }
.f-tabs-scroll { display: flex; overflow-x: auto; scrollbar-width: none; margin-inline: -20px; padding-inline: 20px; }
.f-tabs-scroll::-webkit-scrollbar { display: none; }
.f-tabs {
  position: relative; display: flex; gap: 2px; flex-shrink: 0;
  margin: 0 auto; padding: 5px;
  border-radius: 999px; background: #122c4814;
}
.f-tabs button {
  position: relative; z-index: 1;
  min-height: 46px; padding: 10px 20px;
  border: 0; border-radius: 999px; background: none;
  color: var(--muted); font: inherit; font-size: 16px; font-weight: 700; white-space: nowrap; cursor: pointer;
  transition: color .25s;
}
.f-tabs button:hover, .f-tabs button[aria-selected="true"] { color: var(--navy); }
.f-tab-pill {
  position: absolute; top: 5px; bottom: 5px; left: 0; width: 0;
  border-radius: 999px; background: var(--sky);
  transition: transform .45s var(--u-out), width .45s var(--u-out), opacity .25s;
}
.f-tabs.is-ready .f-tab-pill { transition: transform .45s var(--u-out), width .45s var(--u-out), opacity .25s; }
.f-tabs:not(.is-ready) .f-tab-pill { transition: none; }
.f-searching .f-tab-pill { opacity: 0; }
.f-searching .f-tabs button[aria-selected="true"] { color: var(--muted); }

/* ---------- Question lists ---------- */
.f-status { margin-top: clamp(32px, 4vw, 52px); font-size: 17px; color: var(--muted); }
.f-status:empty { display: none; }
.f-status a { color: var(--ink); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.f-panel { padding-top: clamp(36px, 4.5vw, 60px); }
.f-panel[hidden] { display: none; }
.f-panel h2 { margin: 0 0 clamp(18px, 2.4vw, 32px); font-size: clamp(30px, 3.2vw, 44px); line-height: 1.1; letter-spacing: -.02em; }
.f-panel.is-swap { animation: f-swap .45s var(--u-ease) both; }
@keyframes f-swap { from { opacity: 0; transform: translateY(14px); } }

.f-panel .u-questions summary { padding: 28px 0 14px; cursor: pointer; }
.f-panel .u-questions details:first-child summary { padding-top: 28px; }
.f-panel .u-questions details:first-child { border-top: 1px solid #122c4829; }
.f-panel .u-questions details p { max-width: 1180px; padding: 0 44px 30px 0; color: var(--muted); }
.f-panel .u-questions details p a { color: var(--ink); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.f-panel .u-questions details[hidden] { display: none; }

/* ---------- Related resources ---------- */
.f-related { padding-bottom: clamp(72px, 8vw, 115px); }
.f-related h2 { margin: 0 0 clamp(26px, 3vw, 40px); font-size: clamp(30px, 3.2vw, 44px); line-height: 1.1; letter-spacing: -.02em; }
.f-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.f-card {
  display: flex; flex-direction: column; gap: 12px;
  min-height: 220px; padding: clamp(24px, 2.4vw, 34px);
  border: 1px solid var(--line); border-radius: var(--u-radius); background: #fff;
  transition: border-color .2s, transform .3s var(--u-ease);
}
.f-card:hover { border-color: var(--navy); transform: translateY(-4px); }
.f-card h3 { margin: 0; font-size: 22px; letter-spacing: -.015em; }
.f-card p { margin: 0; font-size: 16px; line-height: 1.55; color: var(--muted); }
.f-card span { display: inline-flex; align-items: center; gap: 10px; margin-top: auto; padding-top: 14px; font-size: 16px; font-weight: 700; }
.f-card .u-i { transition: transform .25s var(--u-ease); }
.f-card:hover .u-i { transform: translateX(4px); }

/* ---------- Closing band ---------- */
.f-close { padding: clamp(64px, 7.5vw, 110px) 0; background: var(--u-dark-bg); color: #fff; }
.f-close-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: clamp(36px, 6vw, 100px); align-items: center; }
.f-close h2 { margin: 0; font-size: clamp(34px, 4vw, 58px); line-height: 1.08; letter-spacing: -.025em; }
.f-close p { max-width: 520px; margin: 20px 0 0; font-size: 18px; line-height: 1.55; color: #ffffffc7; }
.f-close ul { display: grid; gap: 16px; margin: 0 0 32px; padding: 0; list-style: none; font-size: 19px; font-weight: 700; }
.f-close li { display: flex; align-items: center; gap: 14px; }
.f-close li .u-i { color: var(--green); }
.f-close-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; }
.f-close-actions > a:not(.u-btn) { font-size: 17px; font-weight: 700; text-decoration: underline; text-underline-offset: 4px; }

.f-hero :focus-visible, .f-close :focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.f-body :focus-visible, .f-related :focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }

@media (max-width: 1000px) {
  .f-tabs { margin: 0; }
  .f-close-grid { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .f-hero > .shell, .f-body > .shell, .f-related > .shell, .f-close > .shell { width: calc(100% - 40px); }
  .f-search input { height: 62px; padding: 0 56px; font-size: 16px; }
  .f-search .u-i { left: 22px; }
  .f-cards { grid-template-columns: 1fr; }
  .f-card { min-height: 0; }
  .f-panel .u-questions summary { font-size: 18px; }
  .f-panel .u-questions details p { padding-right: 0; }
  .f-close-actions .u-btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .f-tab-pill, .f-card, .f-card .u-i { transition: none; }
  .f-panel.is-swap { animation: none; }
}
