/* v2.172.14: Sign In / Join Free pop-up + the Join banner of the home page (inc/auth-popup.php). */

/* ---------- Picture panel (shared) ---------- */
.vbap-side, .vbh-join-side {
	position: relative; display: flex; flex-direction: column; justify-content: center; gap: 22px; padding: 30px 34px;
	background: radial-gradient(120% 80% at 80% 0%, #4c1d95 0%, rgba(76, 29, 149, 0) 60%), linear-gradient(160deg, #1e1b4b 0%, #2a1050 55%, #3b0a45 100%);
	color: #fff; overflow: hidden;
}
.vbap-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; width: 100%; max-width: 470px; margin: 0 auto; }
.vbap-tile { position: relative; aspect-ratio: 1 / 1; border-radius: 16px; overflow: hidden; background: #2b2150; box-shadow: 0 10px 26px rgba(0, 0, 0, .35), inset 0 0 0 1px rgba(255, 255, 255, .12); }
.vbap-tile:nth-child(even) { transform: translateY(26px); }
.vbap-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.vbap-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(17, 10, 40, .92) 0%, rgba(17, 10, 40, .35) 55%, rgba(17, 10, 40, .05) 100%); }
.vbap-tile-txt { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; display: flex; flex-direction: column; align-items: center; padding: 12px 10px 16px; text-align: center; }
.vbap-tile-txt b { font-size: clamp(24px, 2.6vw, 34px); font-weight: 800; line-height: 1.05; letter-spacing: -.5px; text-shadow: 0 2px 10px rgba(0, 0, 0, .45); }
.vbap-tile-txt span { margin-top: 4px; font-size: 14px; line-height: 1.3; opacity: .95; }
.vbap-side-foot { display: flex; flex-direction: column; align-items: center; gap: 4px; margin-top: 24px; text-align: center; }
.vbap-side-foot b { font-size: 24px; font-weight: 800; letter-spacing: -.3px; }
.vbap-side-foot span { font-size: 14.5px; opacity: .85; }

/* ---------- Pop-up ---------- */
html.vbap-lock, html.vbap-lock body { overflow: hidden; }
.vbap {
	position: fixed; inset: 0; z-index: 99990; display: flex; align-items: center; justify-content: center; padding: 20px;
	background: rgba(15, 18, 30, .45); -webkit-backdrop-filter: blur(9px) saturate(1.1); backdrop-filter: blur(9px) saturate(1.1);
	opacity: 0; transition: opacity .2s ease;
}
.vbap[hidden] { display: none; }
.vbap.is-open { opacity: 1; }
.vbap-box {
	position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); width: min(1040px, 100%); max-height: min(720px, calc(100vh - 40px));
	border-radius: 24px; overflow: hidden; background: #fff; color: #101828; box-shadow: 0 30px 80px rgba(0, 0, 0, .35);
	transform: translateY(14px) scale(.98); transition: transform .25s cubic-bezier(.2, .9, .3, 1);
}
.vbap.is-open .vbap-box { transform: none; }
.vbap-x {
	position: absolute; right: 14px; top: 14px; z-index: 5; display: grid; place-items: center; width: 40px; height: 40px; padding: 0;
	border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); color: #101828; font-size: 18px; cursor: pointer; box-shadow: 0 2px 10px rgba(0, 0, 0, .18);
}
.vbap-x:hover, .vbap-x:focus-visible { background: #fff; outline: 3px solid rgba(20, 88, 125, .35); }
.vbap-main { min-height: 0; overflow-y: auto; padding: 34px 40px 28px; overscroll-behavior: contain; }
.vbap-brand { margin: 0 0 18px; font-size: 14px; font-weight: 700; letter-spacing: .3px; color: #14587d; text-transform: uppercase; }
.vbap-h { margin: 0 0 6px; font-size: 30px; line-height: 1.15; font-weight: 800; letter-spacing: -.5px; color: #101828; }
.vbap-sub { margin: 0 0 18px; font-size: 15px; line-height: 1.5; color: #475467; }
.vbap-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin: 0 0 18px; padding: 4px; border-radius: 12px; background: #f2f4f7; }
.vbap-tab { min-height: 42px; border: 0; border-radius: 9px; background: transparent; color: #475467; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; }
.vbap-tab.is-on { background: #fff; color: #14587d; box-shadow: 0 1px 4px rgba(16, 24, 40, .12); }
.vbap-form[hidden] { display: none; }
.vbap-seg { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.vbap-seg button, .vbap-chip {
	display: inline-flex; align-items: center; gap: 7px; min-height: 40px; padding: 0 16px; border: 1px solid #d0d5dd; border-radius: 999px;
	background: #fff; color: #344054; font: inherit; font-size: 14px; font-weight: 600; cursor: pointer;
}
.vbap-seg button.is-on, .vbap-chip:has(input:checked) { border-color: #14587d; background: #eaf2f8; color: #14587d; }
.vbap-chip input { width: 16px; height: 16px; margin: 0; accent-color: #14587d; }
.vbap-radios { display: grid; gap: 6px; margin: 0 0 14px; }
.vbap-radio { display: flex; align-items: center; gap: 9px; min-height: 36px; font-size: 14.5px; color: #344054; cursor: pointer; }
.vbap-radio input { width: 18px; height: 18px; margin: 0; accent-color: #14587d; flex: 0 0 auto; }
.vbap-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; }
.vbap-wide { grid-column: 1 / -1; }
.vbap-field { margin: 0 0 14px; min-width: 0; }
.vbap-grid .vbap-field { margin: 0; }
.vbap-field[hidden], .vbap-hint[hidden] { display: none; }
.vbap-lbl { display: block; margin: 0 0 6px; font-size: 14px; font-weight: 600; color: #344054; }
.vbap-lbl em { color: #d92d20; font-style: normal; }
.vbap-main input[type="text"], .vbap-main input[type="tel"], .vbap-main input[type="email"], .vbap-main input[type="password"], .vbap-main select {
	width: 100%; min-width: 0; height: 48px; padding: 0 14px; border: 1px solid #d0d5dd; border-radius: 10px; background: #fff;
	color: #101828; font: inherit; font-size: 16px; box-sizing: border-box; transition: border-color .15s, box-shadow .15s;
}
.vbap-main input:focus, .vbap-main select:focus { outline: 0; border-color: #14587d; box-shadow: 0 0 0 3px rgba(20, 88, 125, .18); }
.vbap-row { display: flex; gap: 8px; }
.vbap-row select { flex: 0 0 92px; width: 92px; padding: 0 8px; }
.vbap-pw { position: relative; }
.vbap-pw input { padding-right: 48px; }
.vbap-eye { position: absolute; right: 4px; top: 4px; width: 40px; height: 40px; border: 0; background: none; color: #667085; font-size: 16px; cursor: pointer; }
.vbap-forgot { display: inline-block; margin-top: 8px; font-size: 14px; color: #14587d; }
.vbap-hint { display: flex; gap: 8px; align-items: flex-start; margin: -4px 0 14px; padding: 10px 12px; border-radius: 10px; background: #ecfdf3; color: #05603a; font-size: 13.5px; line-height: 1.45; }
.vbap-hint i { margin-top: 2px; color: #25d366; font-size: 16px; }
.vbap-grid + .vbap-hint { margin-top: 14px; }
.vbap .vb-consent { display: flex; gap: 10px; align-items: flex-start; margin: 14px 0 0; font-size: 13px; line-height: 1.45; color: #475467; }
.vbap .vb-consent input { margin-top: 2px; }
.vbap-btn {
	display: flex; align-items: center; justify-content: center; width: 100%; min-height: 50px; margin: 18px 0 0; border: 0; border-radius: 12px;
	background: #14587d; color: #fff; font: inherit; font-size: 16px; font-weight: 700; cursor: pointer; transition: background .15s;
}
.vbap-btn:hover { background: #0e4463; }
.vbap-btn:focus-visible { outline: 3px solid rgba(20, 88, 125, .4); outline-offset: 2px; }
.vbap-btn.is-busy { opacity: .7; cursor: progress; }
.vbap-switch { margin: 16px 0 0; font-size: 14.5px; color: #475467; text-align: center; }
.vbap-go { padding: 0; border: 0; background: none; color: #14587d; font: inherit; font-weight: 700; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.vbap-trap { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.vbap-side { padding: 40px 34px; }

/* Tablet / phone: the form only (the picture panel needs room); the pop-up becomes a sheet. */
@media (max-width: 860px) {
	.vbap-box { grid-template-columns: 1fr; width: min(560px, 100%); }
	.vbap-side { display: none; }
}
@media (max-width: 560px) {
	.vbap { align-items: flex-end; padding: 0; }
	.vbap-box { width: 100%; max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); border-radius: 22px 22px 0 0; }
	.vbap-main { padding: 24px 18px calc(22px + env(safe-area-inset-bottom)); }
	.vbap-h { font-size: 25px; padding-right: 44px; }
	.vbap-grid { grid-template-columns: 1fr; }
	.vbap-x { right: 10px; top: 10px; }
}

/* ---------- Join banner (home page, under "Explore topics") ---------- */
.vbh-join {
	display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); margin: 4px 0 18px; border-radius: 22px; overflow: hidden;
	background: #fff; box-shadow: 0 6px 22px rgba(0, 0, 0, .16); color: #101828;
}
body.logged-in .vbh-join { display: none; }
.vbh-join-main { display: flex; flex-direction: column; justify-content: center; padding: 36px 40px; }
.vbh-join-kicker { align-self: flex-start; padding: 5px 12px; border-radius: 999px; background: #eaf2f8; color: #14587d; font-size: 13px; font-weight: 700; }
.vbh-join-h { margin: 14px 0 8px; font-size: clamp(24px, 2.6vw, 34px); line-height: 1.15; font-weight: 800; letter-spacing: -.5px; color: #101828; }
.vbh-join-text { margin: 0 0 14px; font-size: 15.5px; line-height: 1.55; color: #475467; }
.vbh-join-points { display: grid; gap: 8px; margin: 0 0 22px; padding: 0; list-style: none; font-size: 15px; color: #344054; }
.vbh-join-points i { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: 6px; border-radius: 50%; background: #dcfae6; color: #067647; font-size: 11px; }
.vbh-join-btns { display: flex; flex-wrap: wrap; gap: 10px; }
.vbh-join-btn {
	display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 26px; border: 1px solid #d0d5dd; border-radius: 12px;
	background: #fff; color: #101828 !important; font-size: 15.5px; font-weight: 700; text-decoration: none !important;
}
.vbh-join-btn.is-main { border-color: #14587d; background: #14587d; color: #fff !important; }
.vbh-join-btn:hover { border-color: #14587d; }
.vbh-join-btn.is-main:hover { background: #0e4463; }
.vbh-join-side { padding: 30px 30px 50px; }
.vbh-join .vbap-tiles { grid-template-columns: repeat(var(--n, 4), 1fr); max-width: none; gap: 14px; }
.vbh-join .vbap-tile { aspect-ratio: 3 / 4; }
.vbh-join .vbap-tile-txt b { font-size: clamp(20px, 2vw, 28px); }
.vbh-join .vbap-tile-txt span { font-size: 13px; }
.vbh-join .vbap-side-foot { margin-top: 18px; }
.vbh-join .vbap-side-foot b { font-size: 21px; }
@media (max-width: 1100px) {
	.vbh-join { grid-template-columns: 1fr; }
	.vbh-join-main { padding: 28px 26px 22px; }
}
@media (max-width: 640px) {
	.vbh-join { border-radius: 18px; }
	.vbh-join-main { padding: 22px 18px 18px; }
	.vbh-join-btn { flex: 1 1 140px; }
	.vbh-join-side { padding: 20px 16px 40px; }
	.vbh-join .vbap-tiles { grid-template-columns: 1fr 1fr; gap: 12px; }
	.vbh-join .vbap-tile { aspect-ratio: 1 / 1; }
}

/* Dark mode. */
html.dark .vbap-box, html.dark .vbh-join { background: #161d27; color: #e5e7eb; }
html.dark .vbap-h, html.dark .vbh-join-h { color: #f3f4f6; }
html.dark .vbap-sub, html.dark .vbh-join-text, html.dark .vbap-switch { color: #9ca3af; }
html.dark .vbap-lbl, html.dark .vbap-radio, html.dark .vbh-join-points { color: #d1d5db; }
html.dark .vbap-tabs { background: #1f2937; }
html.dark .vbap-tab.is-on { background: #111827; color: #93c5fd; }
html.dark .vbap-main input[type="text"], html.dark .vbap-main input[type="tel"], html.dark .vbap-main input[type="email"], html.dark .vbap-main input[type="password"], html.dark .vbap-main select { background: #0f141b; border-color: #374151; color: #f3f4f6; }
html.dark .vbap-seg button, html.dark .vbap-chip, html.dark .vbh-join-btn:not(.is-main) { background: #111827; border-color: #374151; color: #e5e7eb !important; }
html.dark .vbap-seg button.is-on, html.dark .vbap-chip:has(input:checked) { background: #1e3a52; border-color: #60a5fa; color: #93c5fd; }
html.dark .vbap-x { background: #1f2937; color: #f3f4f6; }
html.dark .vbap-brand, html.dark .vbap-go, html.dark .vbap-forgot { color: #93c5fd; }
html.dark .vbh-join-kicker { background: #1e3a52; color: #93c5fd; }

@media (prefers-reduced-motion: reduce) { .vbap, .vbap-box { transition: none; } }
