/* Gamer Store Core: shared front-end building blocks.
   Colours come from the theme's CSS variables (set on :root); fallbacks keep the plugin usable with any theme. */

.gsx, .gsx * { box-sizing: border-box; }

.gsx {
	--gsx-bg: var(--bg, #f6f6fa);
	--gsx-surface: var(--surface, #ffffff);
	--gsx-surface2: var(--surface2, #efeff6);
	--gsx-text: var(--text, #0c0c14);
	--gsx-muted: var(--muted, #5a5a6e);
	--gsx-border: var(--border, #e4e4ee);
	--gsx-primary: var(--primary, #5b3df5);
	--gsx-on-primary: var(--on-primary, #ffffff);
	--gsx-mint: var(--mint, #12b886);
	--gsx-on-mint: var(--on-mint, #032a1f);
	--gsx-coral: var(--coral, #ff5c6c);
	--gsx-on-coral: var(--on-coral, #2a0610);
	--gsx-amber: var(--amber, #e8b84a);
	--gsx-on-amber: var(--on-amber, #2a1d00);
	color: var(--gsx-text);
	font-family: inherit;
}

.gsx-btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 48px; padding: 0 26px; border-radius: 999px; border: 2px solid transparent;
	font: inherit; font-weight: 700; font-size: 16px; text-decoration: none; cursor: pointer; line-height: 1;
	background: var(--gsx-primary); color: var(--gsx-on-primary);
}
.gsx-btn:hover { filter: brightness(1.06); }
.gsx-btn:disabled, .gsx-btn[aria-disabled="true"] { background: var(--gsx-surface2); color: var(--gsx-muted); cursor: not-allowed; filter: none; }
.gsx-btn--ghost { background: transparent; color: var(--gsx-primary); border-color: var(--gsx-primary); }
.gsx-btn--gold { background: var(--gsx-amber); color: var(--gsx-on-amber); }
.gsx-btn--block { display: flex; width: 100%; }
.gsx-btn--sm { min-height: 40px; padding: 0 18px; font-size: 14px; }

.gsx-card { background: var(--gsx-surface); border: 1px solid var(--gsx-border); border-radius: 20px; padding: 22px; }
.gsx-muted { color: var(--gsx-muted); }

.gsx-field { display: flex; flex-direction: column; gap: 6px; margin: 0 0 14px; }
.gsx-field label { font-weight: 700; font-size: 14px; }
.gsx-field input[type="text"], .gsx-field input[type="email"], .gsx-field input[type="number"], .gsx-field input[type="password"],
.gsx-field select, .gsx-field textarea {
	width: 100%; min-height: 48px; padding: 10px 16px; border-radius: var(--field-radius, 14px); border: 1px solid var(--field-border, var(--gsx-border));
	background: var(--field-bg, var(--gsx-bg)); color: var(--gsx-text); font: inherit; font-size: 16px;
}
.gsx-field textarea { resize: vertical; }
.gsx-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

.gsx-notice { padding: 12px 16px; border-radius: 14px; background: var(--gsx-surface2); font-weight: 600; font-size: 14px; margin: 0 0 14px; }
.gsx-notice--error { border-left: 4px solid var(--gsx-coral); }
.gsx-notice--success { border-left: 4px solid var(--gsx-mint); }

.gsx-badge { display: inline-block; padding: 5px 10px; border-radius: 8px; font-size: 12px; font-weight: 700; letter-spacing: .6px; line-height: 1.2; text-transform: uppercase; }
.gsx-badge--hot { background: var(--gsx-coral); color: var(--gsx-on-coral); }
.gsx-badge--new { background: var(--gsx-mint); color: var(--gsx-on-mint); }
.gsx-badge--sale { background: var(--gsx-amber); color: var(--gsx-on-amber); }
.gsx-badge--rank { background: #16133a; color: #fff; }
.gsx-badge--custom { background: var(--gsx-primary); color: var(--gsx-on-primary); }

.gsx-pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--gsx-border); background: var(--gsx-surface); font-size: 13px; font-weight: 600;box-shadow:0 4px 14px rgba(0,0,0,.55);}
.gsx-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gsx-mint); display: inline-block; }

.gsx-countdown { display: flex; gap: 8px; max-width: 400px; }
.gsx-countdown__unit { flex: 1 1 0; text-align: center; padding: 10px 0; border-radius: 16px; background: var(--gsx-surface2); }
.gsx-countdown__num { display: block; font-weight: 700; font-size: 28px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.gsx-countdown__label { display: block; font-size: 11px; font-weight: 700; letter-spacing: 1px; color: var(--gsx-muted); }
.gsx-countdown__unit:last-child { background: var(--gsx-amber); color: var(--gsx-on-amber); }
.gsx-countdown__unit:last-child .gsx-countdown__label { color: inherit; }
.gsx-countdown.is-ended { opacity: .6; }

/* Square cards: the fallback image of the plugin's own cards */
.gsx-wc-card-fallback__img { aspect-ratio: 1 / 1 !important; }

/* Achievements and gamerscore */
.gsx-stats { display: inline-flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.gsx-stat { display: inline-flex; align-items: center; gap: 5px; box-sizing: border-box; height: 28px; padding: 0 9px 0 8px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--gsx-stat-bg, rgba(5,7,6,.6)); box-shadow: 0 4px 12px rgba(0,0,0,.6); white-space: nowrap; }
.gsx-stat--ach { color: #ffc83d; }
.gsx-stat--gs { color: #2ee66b; }
.gsx-stat { line-height: 1; }
.gsx-stat svg { display: block; flex: none; }
.gsx-stat--gs b { display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; width: 15px; height: 15px; padding: 1px 0 0 0; border-radius: 50%; background: #2ee66b; color: #04130a; font-size: 10px; font-weight: 800; line-height: 1; text-align: center; letter-spacing: 0; }

/* Game without a price: "Price missing / Request now!" instead of 0,00 */
.gsx-price-missing { display: inline-flex; flex-direction: column; align-items: center; gap: 2px; line-height: 1.2; }
.gsx-price-missing__a { font-weight: 700; font-size: .78em; color: var(--gsx-muted, #9aa3a0); }
.gsx-price-missing__b { font-weight: 800; font-size: .92em; margin-left: 0 !important; }
.gs-game-card__meta:has(+ .gs-game-card__price .gsx-price-missing) { display: none; }

/* Cloudflare Turnstile: the widget itself cannot be restyled, so it gets a frame that matches the site's boxes and fills the width. */
.gsx-captcha { margin: 14px 0 2px; background: var(--field-bg, #111614); border: 1px solid var(--field-border, #303a35); border-radius: var(--field-radius, 12px); overflow: hidden; }
.gsx-captcha .cf-turnstile, .gsx-captcha .gsx-cf { width: 100%; }
.gsx-captcha { padding: 0; }
.gsx-captcha .cf-turnstile, .gsx-captcha .gsx-cf { margin: -2px -5px -6px -2px; }
.gsx-captcha iframe { display: block; width: calc(100% + 7px) !important; max-width: none; filter: brightness(.62) saturate(.9); }
/* cover the widget's own white edge lines (cannot be styled inside the iframe) */
.gsx-captcha { position: relative; }
.gsx-captcha::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; box-shadow: inset -5px -5px 0 0 #313131, inset 0 0 0 1px var(--field-border, #303a35); }
.gsx-chat__cf { margin: -2px -5px -6px -2px; }
.gsx-chat__captcha { margin: 10px 0; min-height: 4px; }

/* Upcoming game on a card: the release timer replaces "Price missing / Request now!". */
.gsx-price-missing--timer { display: block; width: 100%; }
.gsx-price-missing--timer .gsx-countdown { display: flex; justify-content: center; gap: 3px; margin: 0; width: auto; max-width: 100%; }
.gsx-price-missing--timer .gsx-countdown__unit { flex: 0 0 auto; width: 40px; aspect-ratio: 1; padding: 0; border-radius: 7px; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.gsx-price-missing--timer .gsx-countdown__num { font-size: .95rem; }
.gsx-price-missing--timer .gsx-countdown__label { font-size: .52rem; }

/* Upcoming tag: blue. */
body .gsx-badge--upcoming { background: #2f8cff; color: #fff; border-color: #2f8cff; }

/* Menu tags (the small label above a menu item) */
.gs-nav .gs-nav__list>li>a{transform:none}@media (min-width:861px) {.gs-nav .gs-nav__list>li>a{padding-top:17px;padding-bottom:11px}}.gsx-mt{position:relative;display:inline-block;line-height:1;vertical-align:baseline}.gsx-mt__t{position:absolute;display:block;height:auto;right:0;top:-10px;margin:0;font-size:9px;line-height:1;font-weight:800;letter-spacing:.06em;color:#2ee66b;text-transform:uppercase;white-space:nowrap}.gs-nav__list a[href*="/arcade"]::after{background:#ffc233!important;color:#1a1500!important;box-shadow:0 0 8px rgba(255,194,51,.55)!important}

/* Wheel card: prize chances list */
/* Invisible Turnstile (setting "Captcha: invisible widget"): the widget still needs a box to run in, so it stays in the page, out of sight and out of the layout. */
.gsx-captcha.gsx-captcha--invisible { position: fixed; left: 0; bottom: 0; width: 300px; height: 65px; margin: 0; padding: 0; border: 0; opacity: .01; overflow: hidden; pointer-events: none; z-index: -1; }
.gsx-captcha.gsx-captcha--invisible::after { content: none; }

/* Section title used by Arcade, Membership and Gamerscore pages */
.gsx-archead .gs-h2,.gsx-memhead .gs-h2,.gsb__sech .gs-h2{font-size:clamp(30px,3.6vw,44px)!important;line-height:1.05!important;margin:0!important}

/* Game price: Basic and Premium in two separate boxes */
.gsx-pboxes{display:inline-flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:6px;vertical-align:middle}
.gsx-pbox{display:inline-flex;align-items:center;gap:4px;padding:1px 6px;border-radius:6px;border:1px solid;font-size:.85em;line-height:1.3;white-space:nowrap;box-shadow:0 4px 14px rgba(0,0,0,.55);}
.gs-game-card .gsx-pboxes{flex-wrap:nowrap;gap:4px}
.gs-game-card .gsx-pbox{padding:1px 5px;font-size:.8em}
.gsx-pbox:not(.gsx-pbox--plain) .woocommerce-Price-amount,.gsx-pbox:not(.gsx-pbox--plain) .amount,.gsx-pbox:not(.gsx-pbox--plain) bdi,.gsx-pbox:not(.gsx-pbox--plain) ins,.gsx-pbox:not(.gsx-pbox--plain) del{color:inherit!important;background:none!important;text-decoration:none}
.gsx-pbox:not(.gsx-pbox--plain) del{opacity:.6;text-decoration:line-through;font-weight:500}
.gsx-pbox--basic{color:#2ee66b;background:rgba(46,230,107,.10);border-color:rgba(46,230,107,.45)}
:root{--gsx-gold:#ffc83d}
.gsx-pbox--premium{color:var(--gsx-gold);background:rgba(255,200,61,.11);border-color:rgba(255,200,61,.5)}
.single-product .gsx-wc-price .gsx-pbox{padding:5px 14px;border-radius:10px;font-size:1em}
.single-product .gsx-wc-price .gsx-pboxes{margin-bottom:8px}
.single-product .gsx-wc-price .gsx-pbox{position:relative}
.single-product .gsx-wc-price .gsx-pbox--basic{color:#d4dad6;background:rgba(212,218,214,.08);border-color:rgba(212,218,214,.3)}
/* Game page: the Basic / Premium names are shown as a tag on the bottom edge of each price box, like on the game cards */
.single-product .gsx-wc-price .gsx-pbox>.screen-reader-text:first-child{width:auto;height:auto;margin:0;overflow:visible;clip:auto;clip-path:none;left:50%;bottom:-9px;transform:translateX(-50%);padding:1px 8px;border-radius:99px;background:#101512;border:1px solid currentColor;font:700 9px/1.4 var(--font-body,sans-serif);letter-spacing:.12em;text-transform:uppercase;-webkit-text-fill-color:currentColor}
.gsx-crown,.single-product .gsx-wc-price .gsx-pbox--premium>.screen-reader-text:first-child::before{display:inline-block;width:1em;height:1em;vertical-align:-.12em;background:currentColor;-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 8l4.5 4L12 5l4.5 7L21 8l-1.8 10H4.8L3 8zm2 12h14v2H5z'/%3E%3C/svg%3E") center/contain no-repeat;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 8l4.5 4L12 5l4.5 7L21 8l-1.8 10H4.8L3 8zm2 12h14v2H5z'/%3E%3C/svg%3E") center/contain no-repeat}
.single-product .gsx-wc-price .gsx-pbox--premium>.screen-reader-text:first-child::before{content:"";margin-right:.35em}
/* Plain price (Daily Deals): no box, the page styles the price itself; only a Premium price keeps its gold. */
.gsx-pbox--plain{display:contents;color:inherit}
.gsx-pboxes .gsx-pbox--plain{display:flex;flex-direction:column;align-items:flex-start}
.gsx-pbox-or{font-size:.8em;font-weight:600;letter-spacing:.04em;text-transform:lowercase;color:#9aa7a0;text-shadow:0 2px 8px rgba(0,0,0,.75);}

/* Platform tag colours (their own brand colours): used by the card badges, the game page tags and the cart tags */
.gsx-plat--ogx { --gsx-plat: #5fd35f; }
.gsx-plat--360 { --gsx-plat: #8dc63f; }
.gsx-plat--one { --gsx-plat: #107c10; }
.gsx-plat--xs { --gsx-plat: #9bf00b; }
.gsx-plat--win { --gsx-plat: #afc9fd; }
.gsx-plat--gfwl { --gsx-plat: #ff8a1f; }
.gsx-plat--switch { --gsx-plat: #ff3d5a; }
.gsx-plat--ios { --gsx-plat: #e6e9ee; }
.gsx-plat--android { --gsx-plat: #3ddc84; }
.gsx-plat--appletv { --gsx-plat: #8e8e93; }

/* Connected accounts: one line per account (icon, name, status, button on the right). */
.gsx-connections__list { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.gsx-connections__item { display: flex; align-items: center; gap: 14px; padding: 14px 18px; margin: 0; }
.gsx-connections__item > svg, .gsx-connections__item > img, .gsx-connections__item > span:first-child { flex: none; }
.gsx-connections__name { display: flex; align-items: baseline; gap: 10px; flex: 1 1 auto; min-width: 0; }
.gsx-connections__name br { display: none; }
.gsx-connections__item form { margin: 0 0 0 auto; }
.gsx-connections__item > .gsx-btn { margin-left: auto; flex: none; }
