/* ============================================================
   cani.css  |  atlas-guide.com/resources/can-i/
   Prefix: .ci-*  ·  "Border Control" edition
   Signature: the rubber-stamp verdict.
   All colors come from global.css --ag- tokens.
   ============================================================ */

/* ---------- Hero : the dark side of the border desk ---------- */
.ci-hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(900px 500px at 70% -10%, rgba(46,107,74,.35) 0%, transparent 60%),
    var(--ag-green-900);
  color: var(--ag-parchment);
  padding: clamp(4.5rem, 10vw, 7.5rem) 1.25rem clamp(5rem, 9vw, 7rem);
  text-align: center;
}

/* faint passport stamps scattered behind the title */
.ci-hero__stamps {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .5;
}
.ci-hero__stamps span {
  position: absolute;
  border: 2px dashed rgba(201,168,92,.18);
  border-radius: 50%;
  width: 150px; height: 150px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: rgba(201,168,92,.22);
}
.ci-hero__stamps span:nth-child(1) { top: 8%;  left: 6%;   transform: rotate(-14deg); }
.ci-hero__stamps span:nth-child(2) { top: 55%; left: 12%;  transform: rotate(9deg); width: 110px; height: 110px;
  border-radius: 10px; border-color: rgba(195,221,208,.14); color: rgba(195,221,208,.18); }
.ci-hero__stamps span:nth-child(3) { top: 14%; right: 8%;  transform: rotate(11deg); width: 130px; height: 130px;
  border-radius: 12px; border-color: rgba(195,221,208,.13); color: rgba(195,221,208,.17); }
.ci-hero__stamps span:nth-child(4) { bottom: 12%; right: 14%; transform: rotate(-7deg); width: 170px; height: 170px; }

.ci-hero__eyebrow {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ag-gold-500);
  margin: 0 0 1.5rem;
}
.ci-hero__eyebrow::before,
.ci-hero__eyebrow::after {
  content: '';
  width: 34px; height: 1.5px;
  background: var(--ag-gold-500);
  opacity: .6;
}

.ci-hero__title {
  position: relative;
  font-family: var(--font-display);
  font-size: clamp(3.4rem, 10vw, 6.8rem);
  font-weight: 700;
  font-style: italic;
  line-height: 1.02;
  letter-spacing: -.02em;
  margin: 0 0 .5rem;
  color: var(--ag-warm-white);
}

/* rotating question ticker */
.ci-hero__ticker {
  position: relative;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4.4vw, 2.6rem);
  font-weight: 500;
  font-style: italic;
  color: var(--ag-gold-400);
  min-height: 1.4em;
  margin: 0 0 2rem;
}
.ci-hero__ticker span {
  display: inline-block;
  animation: ci-ticker-in .5s var(--ease-out);
}
@keyframes ci-ticker-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.ci-hero__subtitle {
  position: relative;
  font-size: 1.05rem;
  color: rgba(245,240,232,.78);
  max-width: 460px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
}

/* stats as a document footer strip */
.ci-hero__stats {
  position: relative;
  display: inline-flex;
  gap: 0;
  border: 1px solid rgba(245,240,232,.18);
  border-radius: var(--radius-sm);
  overflow: hidden;
  backdrop-filter: blur(2px);
}
.ci-hero__stat {
  display: flex;
  flex-direction: column;
  gap: .15rem;
  padding: .85rem 1.6rem;
}
.ci-hero__stat + .ci-hero__stat { border-left: 1px solid rgba(245,240,232,.18); }
.ci-hero__stat-num {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1;
  color: var(--ag-warm-white);
}
.ci-hero__stat-label {
  font-size: .64rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(245,240,232,.55);
}

/* ---------- Finder : the boarding pass ---------- */
.ci-finder {
  max-width: 920px;
  margin: -3.25rem auto 3rem;
  padding: 0 1.25rem;
  position: relative;
  z-index: 2;
}

.ci-finder__inner {
  display: flex;
  background: var(--ag-white);
  border-radius: var(--radius-md);
  box-shadow: 0 24px 60px rgba(13,33,24,.28), 0 4px 14px rgba(13,33,24,.12);
  overflow: hidden;
}

/* main section of the pass */
.ci-finder__main {
  flex: 1;
  padding: 1.75rem 2rem 1.9rem;
  display: flex;
  gap: 1.5rem;
}

.ci-finder__step {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: .5rem;
}

.ci-finder__label {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-size: .66rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ag-ink-light);
}
.ci-finder__label b {
  color: var(--ag-gold-600);
  font-weight: 800;
}

.ci-select-wrap { position: relative; }

.ci-select {
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  background: var(--ag-parchment);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: .85rem 2.5rem .85rem 1rem;
  font-family: var(--font-body);
  font-size: .95rem;
  font-weight: 500;
  color: var(--ag-ink);
  cursor: pointer;
  transition: border-color .15s, background .15s, box-shadow .15s;
}
.ci-select:focus-visible {
  outline: none;
  border-color: var(--ag-green-600);
  background: var(--ag-white);
  box-shadow: 0 0 0 3px rgba(46,107,74,.14);
}
.ci-select-arrow {
  position: absolute;
  right: .9rem;
  top: 50%;
  transform: translateY(-58%);
  color: var(--ag-ink-light);
  pointer-events: none;
}

/* perforated divider + notches */
.ci-finder__perf {
  position: relative;
  width: 0;
  border-left: 2px dashed var(--ag-green-100);
  flex-shrink: 0;
}
.ci-finder__perf::before,
.ci-finder__perf::after {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--bg);
  box-shadow: inset 0 2px 6px rgba(13,33,24,.10);
}
.ci-finder__perf::before { top: -11px; }
.ci-finder__perf::after  { bottom: -11px; }

/* the stub with the stamp button */
.ci-finder__stub {
  flex-shrink: 0;
  background: var(--ag-green-50);
  padding: 1.75rem 1.9rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .6rem;
}
.ci-finder__stub-label {
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ag-green-600);
}

.ci-finder__btn {
  background: var(--ag-green-800);
  color: var(--ag-warm-white);
  border: none;
  border-radius: var(--radius-full);
  padding: .9rem 1.9rem;
  font-family: var(--font-body);
  font-size: .92rem;
  font-weight: 700;
  letter-spacing: .04em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  white-space: nowrap;
  box-shadow: 0 6px 22px rgba(26,58,43,.30);
  transition: background .2s, transform .12s var(--ease-out), box-shadow .2s;
}
.ci-finder__btn:hover:not(:disabled) {
  background: var(--ag-green-600);
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(26,58,43,.34);
}
.ci-finder__btn:active:not(:disabled) { transform: scale(.96); }
.ci-finder__btn:disabled {
  background: var(--ag-ink-light);
  box-shadow: none;
  cursor: not-allowed;
  opacity: .55;
}
.ci-btn-stamp {
  font-size: 1.05rem;
  line-height: 1;
  transform: rotate(-8deg);
}

/* ---------- Answer area : the stamped document ---------- */
.ci-answer-area {
  max-width: 760px;
  margin: 0 auto 4rem;
  padding: 0 1.25rem;
  min-height: 150px;
}

.ci-answer-placeholder[hidden],
.ci-answer-card[hidden] { display: none; }

.ci-answer-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .6rem;
  padding: 2.75rem 1.5rem;
  border: 2px dashed var(--ag-green-100);
  border-radius: var(--radius-md);
  text-align: center;
  color: var(--ag-ink-light);
  background: rgba(232,244,237,.35);
}
.ci-placeholder-stamp {
  width: 56px; height: 56px;
  border: 2.5px solid var(--ag-green-100);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.5rem;
  color: var(--ag-green-100);
  transform: rotate(-10deg);
}
.ci-answer-placeholder p { margin: 0; font-size: .93rem; }

/* the document itself */
.ci-answer-card {
  position: relative;
  background:
    linear-gradient(0deg, rgba(201,168,92,.04), rgba(201,168,92,.04)),
    var(--ag-warm-white);
  border: 1.5px solid var(--border-warm);
  border-radius: 4px;
  box-shadow: var(--shadow-lg);
  animation: ci-doc-in .35s var(--ease-out);
}

/* corner ticks, like a customs form */
.ci-answer-card::before,
.ci-answer-card::after,
.ci-answer-card .ci-corner::before,
.ci-answer-card .ci-corner::after {
  content: '';
  position: absolute;
  width: 16px; height: 16px;
  border-color: var(--ag-gold-500);
  border-style: solid;
}
.ci-answer-card::before { top: 10px; left: 10px;  border-width: 2px 0 0 2px; }
.ci-answer-card::after  { top: 10px; right: 10px; border-width: 2px 2px 0 0; }
.ci-answer-card .ci-corner::before { bottom: 10px; left: 10px;  border-width: 0 0 2px 2px; }
.ci-answer-card .ci-corner::after  { bottom: 10px; right: 10px; border-width: 0 2px 2px 0; }

@keyframes ci-doc-in {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

.ci-answer-card__header {
  padding: 2rem 2.5rem 1rem;
}
.ci-answer-card__kicker {
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--ag-ink-light);
  margin: 0 0 .8rem;
}
.ci-answer-card__question {
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 3.4vw, 1.9rem);
  font-weight: 700;
  line-height: 1.18;
  margin: 0;
  color: var(--ag-green-800);
  /* leave room for the stamp on the right */
  padding-right: clamp(120px, 22vw, 170px);
}

/* THE STAMP */
.ci-answer-badge {
  position: absolute;
  top: 1.4rem;
  right: 1.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: clamp(96px, 18vw, 128px);
  height: clamp(96px, 18vw, 128px);
  border-radius: 50%;
  border: 3.5px solid currentColor;
  box-shadow: inset 0 0 0 2px var(--ag-warm-white), inset 0 0 0 4.5px currentColor;
  font-family: var(--font-body);
  font-weight: 800;
  font-size: clamp(.92rem, 2vw, 1.12rem);
  letter-spacing: .14em;
  text-transform: uppercase;
  line-height: 1.15;
  padding: 10px;
  transform: rotate(-9deg);
  mix-blend-mode: normal;
  opacity: .92;
  pointer-events: none;
  animation: ci-stamp-down .42s cubic-bezier(.2, 1.6, .35, 1) both;
  animation-delay: .18s;
}
.ci-answer-badge.yes { color: var(--ag-green-500); }
.ci-answer-badge.no  { color: var(--ag-terra-500); }
.ci-answer-badge.dep { color: var(--ag-gold-600); }

@keyframes ci-stamp-down {
  0%   { opacity: 0; transform: rotate(-22deg) scale(2.1); }
  70%  { opacity: .95; transform: rotate(-8deg) scale(.94); }
  100% { opacity: .92; transform: rotate(-9deg) scale(1); }
}

.ci-answer-card__summary {
  padding: 1rem 2.5rem 0;
  font-size: 1.08rem;
  line-height: 1.7;
  font-weight: 500;
  color: var(--ag-ink);
  margin: 0 0 1.1rem;
}

.ci-answer-card__detail {
  margin: 0 2.5rem 1.4rem;
  padding-top: 1.1rem;
  border-top: 1px dashed var(--ag-green-100);
  font-size: .94rem;
  color: var(--ag-ink-mid);
  line-height: 1.75;
}
.ci-answer-card__detail p { margin: 0 0 .5rem; }
.ci-answer-card__detail p:last-child { margin-bottom: 0; }

.ci-answer-card__link {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  margin: 0 2.5rem 2rem;
  color: var(--ag-green-800);
  font-size: .88rem;
  font-weight: 700;
  border-bottom: 1.5px solid var(--ag-gold-400);
  padding-bottom: 2px;
  transition: color .15s, border-color .15s;
}
.ci-answer-card__link:hover {
  color: var(--ag-green-600);
  border-color: var(--ag-green-600);
}

/* ---------- Intro / SEO copy ---------- */
.ci-intro {
  max-width: 760px;
  margin: 0 auto 3rem;
  padding: 0 1.25rem;
}
.ci-intro p {
  font-size: .98rem;
  color: var(--ag-ink-mid);
  line-height: 1.8;
  margin: 0;
}

/* ---------- Browse categories ---------- */
.ci-browse {
  max-width: 760px;
  margin: 0 auto 1.5rem;
  padding: 0 1.25rem;
}
.ci-browse__title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 1rem;
  color: var(--ag-green-800);
}
.ci-browse__cats {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}
.ci-browse-btn {
  background: var(--ag-white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-full);
  padding: .45rem 1.1rem;
  font-family: var(--font-body);
  font-size: .85rem;
  font-weight: 600;
  color: var(--ag-ink);
  cursor: pointer;
  transition: all .15s;
}
.ci-browse-btn:hover,
.ci-browse-btn.active {
  background: var(--ag-green-800);
  border-color: var(--ag-green-800);
  color: var(--ag-warm-white);
}

/* ---------- The archive (all Q&A, static, SEO) ---------- */
.ci-all-qa {
  max-width: 760px;
  margin: 0 auto 5rem;
  padding: 1.5rem 1.25rem 0;
}

.ci-qa-category {
  margin-bottom: 3rem;
  scroll-margin-top: 110px;
}

.ci-qa-category__title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0 0 .4rem;
  color: var(--ag-green-800);
  display: flex;
  align-items: center;
  gap: 10px;
}
.ci-qa-category__title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.ci-qa-item {
  border-bottom: 1px solid var(--border);
  scroll-margin-top: 110px;
}
.ci-qa-item:last-child { border-bottom: none; }

.ci-qa-item__q {
  margin: 0;
  display: flex;
  align-items: center;
  gap: .75rem;
  font-size: .97rem;
  font-weight: 600;
}

.ci-qa-dot {
  flex-shrink: 0;
  width: 9px; height: 9px;
  border-radius: 50%;
}
.ci-qa-dot.yes { background: var(--ag-green-500); }
.ci-qa-dot.no  { background: var(--ag-terra-500); }
.ci-qa-dot.dep { background: var(--ag-gold-500); }

.ci-qa-item__btn {
  flex: 1;
  text-align: left;
  background: none;
  border: none;
  padding: 1rem 0;
  font-family: var(--font-body);
  font-size: .97rem;
  font-weight: 600;
  color: var(--ag-ink);
  cursor: pointer;
  transition: color .15s;
}
.ci-qa-item__btn:hover { color: var(--ag-green-600); }
.ci-qa-item__btn:focus-visible {
  outline: 2px solid var(--ag-green-600);
  outline-offset: 3px;
  border-radius: 4px;
}

.ci-qa-verdict {
  flex-shrink: 0;
  font-size: .66rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ag-ink-light);
  border: 1.5px solid var(--border);
  border-radius: 4px;
  padding: .2rem .55rem;
  transform: rotate(-2deg);
}

.ci-qa-item__a {
  font-size: .91rem;
  color: var(--ag-ink-mid);
  line-height: 1.72;
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}
.ci-qa-item.open .ci-qa-item__a { max-height: 500px; }
.ci-qa-item__a p { margin: 0; padding: 0 0 1.1rem 21px; }
.ci-qa-item__a a {
  color: var(--ag-green-800);
  font-weight: 700;
  border-bottom: 1px solid var(--ag-gold-400);
}

/* no-JS fallback: answers always visible */
.no-js .ci-qa-item__a { max-height: none; }

/* ---------- Motion safety ---------- */
@media (prefers-reduced-motion: reduce) {
  .ci-answer-badge,
  .ci-answer-card,
  .ci-hero__ticker span { animation: none !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 760px) {
  .ci-hero { text-align: left; padding-left: 1.5rem; padding-right: 1.5rem; }
  .ci-hero__stamps span:nth-child(1),
  .ci-hero__stamps span:nth-child(2) { display: none; }
  .ci-hero__stats { display: flex; width: 100%; }
  .ci-hero__stat { flex: 1; padding: .75rem .9rem; }

  .ci-finder { margin-top: -2.5rem; }
  .ci-finder__inner { flex-direction: column; }
  .ci-finder__main { flex-direction: column; padding: 1.4rem 1.4rem 1.5rem; gap: 1.1rem; }
  .ci-finder__perf {
    width: auto; height: 0;
    border-left: none;
    border-top: 2px dashed var(--ag-green-100);
  }
  .ci-finder__perf::before { top: -11px; left: -11px; transform: none; }
  .ci-finder__perf::after  { top: -11px; left: auto; right: -11px; bottom: auto; transform: none; }
  .ci-finder__stub { padding: 1.25rem 1.4rem 1.5rem; }
  .ci-finder__btn { width: 100%; justify-content: center; }

  .ci-answer-card__header { padding: 1.5rem 1.4rem .75rem; }
  .ci-answer-card__question { padding-right: 0; }
  .ci-answer-badge {
    position: static;
    margin: 1rem 1.4rem 0;
    width: 92px; height: 92px;
    font-size: .82rem;
  }
  .ci-answer-card__summary { padding: 1rem 1.4rem 0; }
  .ci-answer-card__detail { margin: 0 1.4rem 1.2rem; }
  .ci-answer-card__link { margin: 0 1.4rem 1.6rem; }

  .ci-qa-verdict { display: none; }
}