/* Gallery redesign "B" (bento), 2.13.0. Only loaded while cskgal_mode is active
   on the gallery page (includes/gallery-b.php). Content edge = header edge:
   1240px, with a 20px gutter below 1281px. The theme forces sizes and colours on
   p/td/li/headings, hence the !important on those properties. */

.cgb {
	--cgb-ink: #0a0e14;
	--cgb-text: #0f1222;
	--cgb-body: #4a5063;
	--cgb-muted: #5f6678;
	--cgb-line: #e3e7ee;
	--cgb-soft: #f5f7fa;
	--cgb-signal: #30e87a;
	--cgb-indigo: #4353ff;
	--cgb-indigo-ink: #2f3bd9;
	background: var(--cgb-soft);
	color: var(--cgb-text);
	font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
	-webkit-font-smoothing: antialiased;
}
.cgb *, .cgb *::before, .cgb *::after { box-sizing: border-box; }
.cgb a { text-decoration: none; }
.cgb-wrap { max-width: 1240px; margin-left: auto; margin-right: auto; }
@media (max-width: 1280px) { .cgb-wrap { padding-left: 20px; padding-right: 20px; } }

/* Shared type */
.cgb h1, .cgb h2, .cgb h3 { font-family: inherit; color: var(--cgb-text); margin: 0; text-transform: none; }
.cgb .cgb-h2 { font-size: clamp(24px, 3vw, 30px) !important; line-height: 1.2 !important; letter-spacing: -0.02em; font-weight: 800; }
.cgb .cgb-h2--deep { color: #06301a; }
.cgb .cgb-p { margin: 0; font-size: 16px !important; line-height: 1.75 !important; color: var(--cgb-body); }
.cgb .cgb-p strong { color: var(--cgb-text); font-weight: 800; }
.cgb-eyebrow { font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: #0a7743; }

/* Buttons */
.cgb .cgb-btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 22px; border-radius: 12px; font-size: 15px; font-weight: 700; line-height: 1; border: 1px solid transparent; transition: background .15s, border-color .15s, color .15s, box-shadow .15s; }
.cgb .cgb-btn--ink { background: var(--cgb-ink); color: #fff; }
.cgb .cgb-btn--ink:hover { background: #1b2230; color: #fff; }
.cgb .cgb-btn--light { background: var(--cgb-soft); color: var(--cgb-ink); border-color: var(--cgb-line); }
.cgb .cgb-btn--light:hover { background: #fff; border-color: #c9cfdb; color: var(--cgb-ink); }
.cgb .cgb-btn--signal { background: var(--cgb-signal); color: var(--cgb-ink); min-height: 46px; padding: 0 20px; border-radius: 10px; }
.cgb .cgb-btn--signal:hover { background: #26d36c; color: var(--cgb-ink); }
.cgb .cgb-btn--outline { border-color: rgba(255,255,255,0.22); color: #f2f4fb; min-height: 46px; padding: 0 20px; border-radius: 10px; }
.cgb .cgb-btn--outline:hover { border-color: var(--cgb-signal); color: var(--cgb-signal); }

/* Hero: the shared demo hero (parts/hero.php); its wrapper keeps a 42px gap for white demo pages, closed here so the grey bento meets the band. */
.capskip-landing--heroonly + .cgb { margin-top: 0; }
.capskip-landing--heroonly:has(+ .cgb) { margin-bottom: 0 !important; }

/* Bento */
.cgb-bento { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 18px; padding-top: 40px; padding-bottom: 24px; }
.cgb-tile { grid-column: span 4; background: #fff; border: 1px solid var(--cgb-line); border-radius: 24px; padding: 26px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.cgb-tile--hero { grid-column: span 7; grid-row: span 2; min-height: 460px; background: var(--cgb-ink); border-color: var(--cgb-ink); color: #f2f4fb; padding: 32px; gap: 16px; position: relative; overflow: hidden; }
.cgb-tile--rc { grid-column: span 5; grid-row: span 2; padding: 28px; gap: 14px; }
.cgb-tile__glow { position: absolute; right: -60px; top: -40px; width: 380px; height: 380px; border-radius: 50%; background: radial-gradient(circle at 40% 40%, rgba(243,128,32,0.55), rgba(243,128,32,0) 65%); pointer-events: none; }
.cgb-tile--hero > *:not(.cgb-tile__glow) { position: relative; }
.cgb-tile__tags { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cgb-vendor { font-size: 12px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--cgb-muted); }
.cgb-vendor--cf { color: #f6a35b; }
.cgb-badge { font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: rgba(48,232,122,0.15); color: var(--cgb-signal); }
.cgb .cgb-tile__title { font-size: 30px !important; line-height: 1.15 !important; letter-spacing: -0.02em; font-weight: 800; }
.cgb .cgb-tile__title--xl { font-size: clamp(30px, 3.2vw, 40px) !important; line-height: 1.05 !important; letter-spacing: -0.03em; color: #f5f7fb; }
.cgb .cgb-tile__title--md { font-size: 24px !important; }
.cgb .cgb-tile__text { margin: 0; font-size: 17px !important; line-height: 1.6 !important; color: #b8bfd0; max-width: 470px; }
.cgb .cgb-tile__text--sm { font-size: 15px !important; color: var(--cgb-body); }
.cgb-tile__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.cgb-mock { margin-top: auto; align-self: flex-start; display: flex; align-items: center; gap: 14px; background: #fff; color: var(--cgb-text); border-radius: 10px; padding: 14px 18px; min-width: min(300px, 100%); }
.cgb-mock__check { width: 26px; height: 26px; border-radius: 6px; border: 2px solid #30a46c; display: inline-flex; align-items: center; justify-content: center; color: #30a46c; font-weight: 800; }
.cgb-mock__text { font-weight: 600; }
.cgb-mock__brand { margin-left: auto; font-size: 12px; font-weight: 800; color: #f38020; }

/* reCAPTCHA rows */
.cgb .cgb-rows { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.cgb .cgb-rows li { margin: 0; padding: 0; }
.cgb .cgb-row { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--cgb-line); color: var(--cgb-text); transition: background .15s, border-color .15s; }
.cgb .cgb-row:hover { background: var(--cgb-soft); border-color: #c9cfdb; color: var(--cgb-text); }
.cgb-row__txt { display: flex; flex-direction: column; min-width: 0; }
.cgb-row__name { font-weight: 800; font-size: 16px; }
.cgb-row__note { font-size: 13px; color: var(--cgb-muted); }
.cgb-row__arrow { margin-left: auto; color: var(--cgb-indigo); font-weight: 800; }
.cgb-pill { flex: none; min-width: 92px; text-align: center; font-size: 12px; font-weight: 800; padding: 5px 10px; border-radius: 999px; }

/* Picker buttons (GeeTest, hCaptcha, text) */
.cgb-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: auto; }
.cgb .cgb-pick { border: 1px solid transparent; border-radius: 14px; padding: 14px; color: var(--cgb-text); display: flex; flex-direction: column; gap: 4px; min-height: 44px; transition: border-color .15s, box-shadow .15s; }
.cgb .cgb-pick:hover { border-color: var(--cgb-indigo); color: var(--cgb-text); box-shadow: 0 8px 18px -14px rgba(15,18,34,0.4); }
.cgb-pick--solo { margin-top: auto; }
.cgb-pick__name { font-weight: 800; font-size: 15px; }
.cgb-pick__note { font-size: 13px; color: var(--cgb-body); }

/* Colour chips */
.is-green { background: #e7fbef; color: #0a7743; }
.is-indigo { background: #eef0ff; color: var(--cgb-indigo-ink); }
.is-amber { background: #fff4dc; color: #8a5a00; }
.is-violet { background: #f1edff; color: #5b3fd6; }
.is-orange { background: #ffe9dc; color: #9a3c00; }
.cgb-pick.is-green, .cgb-pick.is-indigo, .cgb-pick.is-amber, .cgb-pick.is-violet, .cgb-pick.is-orange { color: var(--cgb-text); }

/* Solve band */
.cgb-solve-wrap { padding-top: 18px; padding-bottom: 24px; }
.cgb-solve { background: #e7fbef; border-radius: 24px; padding: 30px 32px; display: flex; flex-direction: column; gap: 20px; }
.cgb-solve__head { display: flex; flex-wrap: wrap; gap: 8px 24px; align-items: baseline; justify-content: space-between; }
.cgb .cgb-solve__sub { margin: 0; color: #24533b; font-size: 15px !important; }
.cgb-solve__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 12px; }
.cgb .cgb-solve__card { background: #fff; border: 1px solid #c9f2da; border-radius: 16px; padding: 18px; color: #06301a; display: flex; flex-direction: column; gap: 4px; transition: border-color .15s; }
.cgb .cgb-solve__card:hover { border-color: #0a7743; color: #06301a; }
.cgb-solve__name { font-weight: 800; font-size: 16px; }
.cgb-solve__note { font-size: 14px; color: #24533b; }

/* About */
.cgb-about { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 32px; align-items: start; padding-top: 48px; padding-bottom: 24px; }
.cgb-about__copy { display: flex; flex-direction: column; gap: 14px; }
.cgb-facts { display: grid; gap: 12px; }
.cgb-fact { background: #fff; border: 1px solid var(--cgb-line); border-radius: 16px; padding: 18px 20px; display: flex; gap: 14px; }
.cgb-fact__n { flex: none; width: 36px; height: 36px; border-radius: 10px; background: #eef0ff; color: var(--cgb-indigo-ink); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; }
.cgb-fact__t { font-weight: 800; font-size: 16px; }
.cgb-fact__d { font-size: 15px; line-height: 1.55; color: var(--cgb-body); }

/* Sections */
.cgb-section { padding-top: 32px; padding-bottom: 24px; display: flex; flex-direction: column; gap: 18px; }
.cgb-section--last { padding-bottom: 72px; }
.cgb .cgb-steps { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 12px; }
.cgb .cgb-step { margin: 0; background: #fff; border: 1px solid var(--cgb-line); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 6px; }
.cgb-step__k { font-size: 13px; font-weight: 800; color: #0a7743; }
.cgb-step__t { font-weight: 800; font-size: 18px; }
.cgb-step__d { font-size: 15px; line-height: 1.55; color: var(--cgb-body); }

/* Returns table */
.cgb-table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--cgb-line); border-radius: 18px; }
.cgb .cgb-table { width: 100%; border-collapse: collapse; min-width: 720px; margin: 0; border: 0; }
.cgb .cgb-table th, .cgb .cgb-table td { text-align: left; padding: 14px 20px; border: 0; border-bottom: 1px solid #eef0f4; font-size: 15px !important; line-height: 1.5 !important; vertical-align: middle; background: transparent; }
.cgb .cgb-table thead th { font-size: 12px !important; letter-spacing: 0.06em; text-transform: uppercase; color: var(--cgb-muted); font-weight: 700; border-bottom: 1px solid var(--cgb-line); }
.cgb .cgb-table tbody tr:last-child th, .cgb .cgb-table tbody tr:last-child td { border-bottom: 0; }
.cgb .cgb-table tbody th { font-weight: 800; }
.cgb .cgb-table tbody th a { color: var(--cgb-text); }
.cgb .cgb-table tbody th a:hover { color: var(--cgb-indigo-ink); }
.cgb .cgb-table td { color: var(--cgb-body); }
.cgb .cgb-table code { font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; background: #eef0ff; color: var(--cgb-indigo-ink); padding: 3px 8px; border-radius: 6px; white-space: nowrap; }

/* FAQ */
.cgb-faq { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 480px), 1fr)); gap: 12px; align-items: start; }
.cgb-faq__q { background: #fff; border: 1px solid var(--cgb-line); border-radius: 16px; padding: 0; transition: border-color .25s, box-shadow .25s; }
.cgb-faq__q:hover { border-color: #c9cfdb; }
.cgb-faq__q[open] { border-color: #c9cfdb; box-shadow: 0 10px 28px -18px rgba(16,24,40,.28); }
.cgb-faq__q summary { list-style: none; cursor: pointer; padding: 18px 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px; font-weight: 800; font-size: 16px; line-height: 1.45; color: var(--cgb-text); }
.cgb-faq__q summary::-webkit-details-marker { display: none; }
.cgb-faq__icon { flex: none; width: 10px; height: 10px; border-right: 2px solid var(--cgb-indigo); border-bottom: 2px solid var(--cgb-indigo); transform: rotate(45deg); transition: transform .35s cubic-bezier(.2,.8,.2,1); margin-right: 4px; }
.cgb-faq__q[open] .cgb-faq__icon { transform: rotate(-135deg); }
/* Answers: height animated by the footer script in includes/gallery-b.php; text slides in. */
.cgb-faq__a { overflow: hidden; }
.cgb-faq__a p { transition: opacity .3s ease, transform .35s cubic-bezier(.2,.8,.2,1); }
.cgb-faq__q.is-closing .cgb-faq__a p, .cgb-faq__q.is-opening-start .cgb-faq__a p { opacity: 0; transform: translateY(-6px); }
.cgb .cgb-faq__q p { margin: 0; padding: 0 20px 18px; font-size: 15px !important; line-height: 1.7 !important; color: var(--cgb-body); }

/* Phones and tablets: the bento stacks */
@media (max-width: 900px) {
	.cgb-tile, .cgb-tile--hero, .cgb-tile--rc { grid-column: 1 / -1; grid-row: auto; min-height: 0; }
	.cgb-tile--hero { padding: 26px; }
}
@media (max-width: 640px) {
	.cgb-solve { padding: 24px 20px; }
	.cgb-pair { grid-template-columns: 1fr; }
	.cgb .cgb-tile__title { font-size: 26px !important; }
}

/* Type icons (site icon set, same marks as the Solvers menu) */
.cgb .cgb-mark { flex: none; width: 18px; height: 18px; display: block; }
.cgb .cgb-vendor { display: inline-flex; align-items: center; gap: 8px; }
.cgb .cgb-vendor .cgb-mark { width: 18px; height: 18px; }
.cgb .cgb-pick__ico { display: grid; place-items: center; width: 34px; height: 34px; margin-bottom: 6px; border-radius: 10px; background: #fff; box-shadow: 0 0 0 1px rgba(16,24,40,0.06), 0 2px 6px -3px rgba(16,24,40,0.18); transition: transform .2s cubic-bezier(.2,.8,.2,1); }
.cgb .cgb-pick__ico .cgb-mark { width: 20px; height: 20px; }
.cgb .cgb-pick:hover .cgb-pick__ico { transform: translateY(-2px); }
.cgb .cgb-tname { display: inline-flex; align-items: center; gap: 10px; }
.cgb .cgb-tname .cgb-mark { width: 20px; height: 20px; }

/* Hero "Pick a demo" panel (inside the shared landing hero box, dark) */
.cgb-hpick { display: flex; flex-direction: column; gap: 14px; width: 100%; text-align: left; }
.cgb-hpick__h { font-size: 12px !important; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: #9aa3b5; }
.cgb-hpick__list { list-style: none; margin: 0 !important; padding: 0 !important; display: flex; flex-wrap: wrap; gap: 8px; }
.cgb-hpick__list li { margin: 0 !important; padding: 0 !important; list-style: none; }
.cgb-hpick__list li::before { display: none !important; }
a.cgb-hpick__item { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 14px 0 10px; border-radius: 11px; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1); color: #eef1f8; font-size: 14px !important; font-weight: 700; line-height: 1.2; white-space: nowrap; text-decoration: none; transition: background-color .2s, border-color .2s, transform .2s cubic-bezier(.2,.8,.2,1); }
a.cgb-hpick__item:hover, a.cgb-hpick__item:focus-visible { background: rgba(255,255,255,0.12); border-color: rgba(46,230,122,0.55); color: #fff; transform: translateY(-1px); }
a.cgb-hpick__item .cgb-mark { flex: none; width: 20px; height: 20px; display: block; padding: 2px; border-radius: 6px; background: #fff; box-sizing: content-box; }

/* Phones: the demo pills become one swipeable row, so the hero stays short. */
@media (max-width: 767px) {
	/* min-width:0 lets the swipe row shrink to the hero box (a grid item otherwise grows to the full pill row, 1759px). */
	.cgb-hpick { gap: 10px; min-width: 0; max-width: 100%; }
	.cgb-hpick__list { flex-wrap: nowrap; overflow-x: auto; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch; scrollbar-width: none; margin: 0 -16px !important; padding: 0 16px 2px !important; -webkit-mask-image: linear-gradient(to right, transparent 0, #000 16px, #000 calc(100% - 28px), transparent 100%); mask-image: linear-gradient(to right, transparent 0, #000 16px, #000 calc(100% - 28px), transparent 100%); }
	.cgb-hpick__list::-webkit-scrollbar { display: none; }
	.cgb-hpick__list li { flex: none; scroll-snap-align: start; }
}
