/* Mentometry Game Directory — neon look matching the Mentometry theme.
   Colours come from the theme's own variables when present (--accent, --border, --text-main…)
   and fall back to the same neon palette. Supports the theme's dark/light toggle. */

.mgd-app, .mgd-page, .mgd-widget {
	--mgd-bg: #060810;
	--mgd-panel: #0d1120;
	--mgd-panel-2: #10152a;
	--mgd-card: #131a30;
	--mgd-card-hover: #182140;
	--mgd-border: #232c4a;
	--mgd-cyan: #00e5ff;
	--mgd-magenta: #ff2ec4;
	--mgd-purple: #7b5cff;
	--mgd-gold: #ffc94d;
	--mgd-green: #33ff9c;
	--mgd-red: #ff4d6d;
	--mgd-text: #eaf0ff;
	--mgd-dim: #8a94b8;
	--mgd-radius: 12px;
	--mgd-grad: linear-gradient(135deg, #00e5ff 0%, #7b5cff 55%, #ff2ec4 100%);
	font-family: 'Poppins', -apple-system, 'Segoe UI', sans-serif;
	color: var(--mgd-text);
	box-sizing: border-box;
	direction: ltr;
	text-align: left;
}
html[data-theme="light"] .mgd-app, html[data-theme="light"] .mgd-page, html[data-theme="light"] .mgd-widget {
	--mgd-bg: #f4f6fb; --mgd-panel: #ffffff; --mgd-panel-2: #f0f3fa; --mgd-card: #ffffff; --mgd-card-hover: #f7f9ff;
	--mgd-border: #dde3f0; --mgd-text: #141a2e; --mgd-dim: #5d6787; --mgd-cyan: #0087a8; --mgd-gold: #d99a00; --mgd-green: #0a9d58;
}
.mgd-app *, .mgd-page *, .mgd-widget * { box-sizing: border-box; }
.mgd-app a, .mgd-page a, .mgd-widget a { text-decoration: none; }
.mgd-app, .mgd-widget { max-width: 1800px; margin: 0 auto; padding: 24px 16px 48px; }
.mgd-page { max-width: 1800px; margin: 0 auto; padding: 18px 16px 56px; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mgd-link { background: none; border: 0; color: var(--mgd-cyan); cursor: pointer; padding: 0; font: inherit; font-size: 13px; }
.mgd-link:hover { text-decoration: underline; }

/* buttons */
.mgd-btn { display: inline-flex; align-items: center; gap: 8px; background: var(--mgd-panel-2); color: var(--mgd-text) !important; border: 1px solid var(--mgd-border); border-radius: 10px; padding: 10px 16px; font-family:inherit;font-weight:600;font-size:14px;line-height:1.2; cursor: pointer; transition: .15s; }
.mgd-btn:hover { border-color: var(--mgd-cyan); box-shadow: 0 0 0 3px rgba(0,229,255,.12); }
.mgd-btn--primary { background: var(--mgd-grad); border-color: transparent; color: #04121a !important; }
.mgd-btn--primary:hover { box-shadow: 0 6px 24px rgba(123,92,255,.4); border-color: transparent; filter: brightness(1.06); }
.mgd-btn small { font-weight: 500; opacity: .8; }
.mgd-btn svg, .mgd-filter-toggle svg { fill: currentColor; }

/* hero */
.mgd-hero { margin: 0 0 20px; }
.mgd-hero__title { font: 800 clamp(28px, 4vw, 44px)/1.1 'Orbitron','Poppins',sans-serif; margin: 0 0 8px; background: var(--mgd-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.mgd-hero__sub { margin: 0; color: var(--mgd-dim); max-width: 720px; }

/* toolbar */
.mgd-toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.mgd-search { flex: 1 1 320px; display: flex; align-items: center; gap: 10px; background: var(--mgd-panel); border: 1px solid var(--mgd-border); border-radius: 12px; padding: 0 14px; transition: .15s; }
.mgd-search:focus-within { border-color: var(--mgd-cyan); box-shadow: 0 0 0 3px rgba(0,229,255,.14); }
.mgd-search svg { fill: var(--mgd-dim); flex: none; }
.mgd-search input { flex: 1; min-width: 0; background: transparent !important; border: 0 !important; outline: 0 !important; box-shadow: none !important; color: var(--mgd-text) !important; padding: 13px 0 !important; font-size: 15px !important; }
.mgd-select select { background: var(--mgd-panel); color: var(--mgd-text); border: 1px solid var(--mgd-border); border-radius: 12px; padding: 12px 14px; font-family:inherit;font-weight:500;font-size:14px; cursor: pointer; }
.mgd-view { display: flex; border: 1px solid var(--mgd-border); border-radius: 12px; overflow: hidden; }
.mgd-view button { background: var(--mgd-panel); color: var(--mgd-dim); border: 0; padding: 12px 13px; cursor: pointer; display: grid; place-items: center; }
.mgd-view button svg { fill: currentColor; }
.mgd-view button.is-active { background: var(--mgd-panel-2); color: var(--mgd-cyan); }
.mgd-filter-toggle { display: none; }
.mgd-badge-count { background: var(--mgd-magenta); color: #fff; border-radius: 10px; font-size: 11px; padding: 1px 7px; }

/* quick category bar */
.mgd-catbar { display: flex; flex-wrap: wrap; gap: 8px; padding: 4px 2px 12px; margin-bottom: 6px; }
.mgd-catbar:empty { display: none; }
.mgd-pill { flex: 0 0 auto; justify-content: center; display: inline-flex; align-items: center; gap: 6px; background: var(--mgd-panel); color: var(--mgd-text); border: 1px solid var(--mgd-border); border-radius: 8px; padding: 7px 14px; font-family:inherit;font-weight:500;font-size:13px; cursor: pointer; white-space: nowrap; transition: .15s; }
.mgd-pill:hover { border-color: var(--mgd-cyan); }
.mgd-pill.is-on { background: var(--mgd-grad); color: #04121a; border-color: transparent; font-weight: 700; }
.mgd-pill em { font-style: normal; opacity: .65; font-size: 11px; }

/* layout */
.mgd-layout { display: grid; grid-template-columns: clamp(240px, 21%, 330px) minmax(0, 1fr); gap: clamp(14px, 1.6vw, 24px); align-items: start; }
.mgd-filters { background: var(--mgd-panel); border: 1px solid var(--mgd-border); border-radius: var(--mgd-radius); padding: 16px; position: static; }
.mgd-filters__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.mgd-filters__head b { font: 700 15px 'Orbitron','Poppins',sans-serif; letter-spacing: .3px; }
.mgd-filters__close, .mgd-filters__apply { display: none; }
.mgd-fg { border-top: 1px solid var(--mgd-border); padding: 12px 0 6px; }
.mgd-fg:first-of-type { border-top: 0; }
.mgd-fg > summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; font-family:inherit;font-weight:600;font-size:13px; text-transform: uppercase; letter-spacing: .6px; color: var(--mgd-dim); margin-bottom: 8px; }
.mgd-fg > summary::-webkit-details-marker { display: none; }
.mgd-fg > summary::after { content: '+'; font-size: 18px; color: var(--mgd-cyan); }
.mgd-fg[open] > summary::after { content: '–'; }
.mgd-fg__n { background: var(--mgd-cyan); color: #04121a; border-radius: 9px; font-size: 10px; padding: 1px 6px; margin-left: 6px; }
.mgd-opt { display: flex; align-items: center; gap: 9px; padding: 5px 4px; border-radius: 8px; cursor: pointer; font-size: 14px; color: var(--mgd-text); }
.mgd-opt:hover { background: var(--mgd-panel-2); }
.mgd-opt input { appearance: none; -webkit-appearance: none; flex: none; width: 17px; height: 17px; margin: 0; border: 1.5px solid var(--mgd-border); border-radius: 5px; background: var(--mgd-panel-2); display: grid; place-content: center; cursor: pointer; transition: .12s; }
.mgd-opt input[type=radio] { border-radius: 50%; }
.mgd-opt input:checked { background: var(--mgd-cyan); border-color: var(--mgd-cyan); }
.mgd-opt input:checked::after { content: ''; width: 7px; height: 7px; background: #04121a; border-radius: 2px; }
.mgd-opt input[type=radio]:checked::after { border-radius: 50%; }
.mgd-opt span { flex: 1; min-width: 0; }
.mgd-opt em { font-style: normal; color: var(--mgd-dim); font-size: 12px; }
.mgd-opt.is-zero { opacity: .38; }
.mgd-more { margin: 4px 4px 8px; }
.mgd-toggles { border-top: 1px solid var(--mgd-border); padding-top: 10px; margin-top: 4px; }

/* results */
.mgd-summary { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; margin-bottom: 14px; min-height: 34px; }
.mgd-summary__count { font-family:inherit;font-weight:700;font-size:15px; }
.mgd-active { display: flex; flex-wrap: wrap; gap: 6px; }
.mgd-tagx { display: inline-flex; align-items: center; gap: 6px; background: var(--mgd-panel-2); border: 1px solid var(--mgd-border); color: var(--mgd-text); border-radius: 999px; padding: 4px 6px 4px 12px; font-size: 12px; cursor: pointer; }
.mgd-tagx:hover { border-color: var(--mgd-magenta); }
.mgd-tagx b { width: 18px; height: 18px; display: grid; place-items: center; background: rgba(255,46,196,.18); border-radius: 50%; color: var(--mgd-magenta); font-size: 13px; line-height: 1; }
.mgd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; transition: opacity .15s; }
.mgd-widget .mgd-grid { grid-template-columns: repeat(var(--mgd-cols, 4), minmax(0, 1fr)); }
.mgd-grid.is-loading { opacity: .45; pointer-events: none; }
.mgd-widget__head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.mgd-widget__head h2 { font: 800 24px 'Orbitron','Poppins',sans-serif; margin: 0; color: var(--mgd-text); }
.mgd-widget__head a { color: var(--mgd-cyan); font-size: 14px; }

/* card */
.mgd-card { position: relative; display: flex; flex-direction: column; background: var(--mgd-card); border: 1px solid var(--mgd-border); border-radius: var(--mgd-radius); overflow: hidden; transition: transform .18s, border-color .18s, box-shadow .18s; }
.mgd-card:hover { transform: translateY(-3px); border-color: rgba(0,229,255,.55); box-shadow: 0 10px 30px rgba(0,229,255,.12), 0 0 0 1px rgba(123,92,255,.25); background: var(--mgd-card-hover); }
.mgd-card__cover { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--mgd-panel-2); }
.mgd-card__bg { position: absolute; inset: -20px; background-size: cover; background-position: center; filter: blur(22px) saturate(1.3) brightness(.75); }
.mgd-card__cover img { position: relative; z-index: 1; width: 100%; height: 100%; display: block; }
.mgd-cover--wide img { object-fit: cover; }
.mgd-cover--square img { object-fit: contain; padding: 10px 0; }
.mgd-cover--square .mgd-card__bg { opacity: 1; }
.mgd-cover--wide .mgd-card__bg { display: none; }
.mgd-cover--square img { width: auto; height: 100%; margin: 0 auto; border-radius: 22px; box-shadow: 0 6px 18px rgba(0,0,0,.45); padding: 12px; }
.mgd-card__noimg { position: relative; z-index: 1; display: grid; place-items: center; width: 100%; height: 100%; font: 800 44px 'Orbitron',sans-serif; color: var(--mgd-cyan); }
.mgd-price, .mgd-soon { position: absolute; z-index: 2; left: 10px; bottom: 10px; background: rgba(6,8,16,.82); color: var(--mgd-text); backdrop-filter: blur(6px); border: 1px solid rgba(255,255,255,.14); border-radius: 8px; padding: 3px 9px; font-family:inherit;font-weight:700;font-size:12px; }
.mgd-price--free { color: var(--mgd-green); border-color: rgba(51,255,156,.4); }
.mgd-soon { left: auto; right: 10px; color: var(--mgd-gold); border-color: rgba(255,201,77,.4); }
.mgd-price--inline, .mgd-soon--inline { position: static; display: inline-block; background: var(--mgd-panel-2); }
.mgd-fav { position: absolute; z-index: 3; top: 10px; right: 10px; width: 34px; height: 34px; display: grid; place-items: center; background: rgba(6,8,16,.72); backdrop-filter: blur(6px); border: 1px solid rgba(255,255,255,.16); border-radius: 50%; color: #fff; cursor: pointer; transition: .15s; padding: 0; }
.mgd-fav { box-sizing: border-box; min-width: 0; min-height: 0; line-height: 0; overflow: visible; margin: 0; }
.mgd-fav svg { display: block; flex: none; width: 18px; height: 18px; max-width: none; overflow: visible; fill: transparent; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.mgd-fav--btn svg { width: 16px; height: 16px; }
.mgd-fav:hover { border-color: var(--mgd-magenta); color: var(--mgd-magenta); }
.mgd-fav.is-on { color: var(--mgd-magenta); border-color: var(--mgd-magenta); }
.mgd-fav.is-on svg { fill: currentColor; }
.mgd-fav--btn { position: static; width: auto; height: auto; border-radius: 10px; padding: 10px 16px; gap: 8px; display: inline-flex; background: var(--mgd-panel-2); color: var(--mgd-text); border: 1px solid var(--mgd-border); font-family:inherit;font-weight:600;font-size:14px; backdrop-filter: none; }
.mgd-card__body { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px 14px; flex: 1; }
.mgd-card__title { margin: 0; font: 700 15px/1.3 'Poppins',sans-serif; height: 2.6em; overflow: hidden; }
.mgd-card__title a { color: var(--mgd-text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mgd-card__title a:hover { color: var(--mgd-cyan); }
.mgd-card__dev { color: var(--mgd-dim); font-size: 12px; line-height: 16px; height: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mgd-card__rating { display: flex; align-items: center; flex-wrap: nowrap; gap: 6px; height: 22px; overflow: hidden; }
.mgd-card__chips, .mgd-gh__chips, .mgd-details__chips { display: flex; flex-wrap: wrap; gap: 5px; }
.mgd-card__chips { align-content: flex-start; height: 64px; overflow: hidden; }
.mgd-card__chips .mgd-chip { line-height: 18px; }
.mgd-app.is-list .mgd-card__title { height: auto; }
.mgd-app.is-list .mgd-card__chips { height: auto; }
.mgd-card__desc { display: none; margin: 4px 0 0; color: var(--mgd-dim); font-size: 13px; line-height: 1.5; }
.mgd-card__foot { margin-top: auto; padding-top: 6px; display: flex; flex-wrap: wrap; gap: 5px; }
.mgd-chip { background: rgba(123,92,255,.16); color: #b9a8ff !important; border: 1px solid rgba(123,92,255,.35); border-radius: 999px; padding: 2px 10px; font-size: 11px; font-weight: 600; transition: .12s; }
html[data-theme="light"] .mgd-chip { color: #5a3fd8 !important; }
.mgd-chip:hover { background: rgba(123,92,255,.3); }
.mgd-plat { display: inline-block; border-radius: 6px; padding: 1px 8px; font-size: 11px; font-weight: 600; border: 1px solid var(--mgd-border); color: var(--mgd-dim); background: var(--mgd-panel-2); }
.mgd-plat--steam { color: #66c0f4; border-color: rgba(102,192,244,.4); }
.mgd-plat--app_store { color: #7ab8ff; border-color: rgba(122,184,255,.4); }
.mgd-plat--google_play { color: #5cf0a3; border-color: rgba(92,240,163,.4); }
.mgd-plat--playstation { color: #6d8bff; border-color: rgba(109,139,255,.4); }

/* stars & rating */
.mgd-stars { --star: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 1.5l2.6 5.5 6 .8-4.4 4.2 1.1 6-5.3-2.9-5.3 2.9 1.1-6L1.4 7.8l6-.8z'/%3E%3C/svg%3E"); position: relative; display: inline-block; width: 5.5em; height: 1.1em; font-size: 13px; vertical-align: middle; background: rgba(138,148,184,.3); -webkit-mask: var(--star) 0 0 / 1.1em 1.1em repeat-x; mask: var(--star) 0 0 / 1.1em 1.1em repeat-x; }
.mgd-stars__fill { position: absolute; left: 0; top: 0; bottom: 0; background: var(--mgd-gold); }
.mgd-stars--lg { font-size: 20px; }
.mgd-rating { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.mgd-rating__num { font-weight: 700; }
.mgd-rating__count, .mgd-rating--none { color: var(--mgd-dim); font-size: 12px; }
.mgd-comm-tag { background: rgba(255,46,196,.14); color: #ff8fdc; border-radius: 999px; padding: 1px 8px; font-size: 11px; font-weight: 600; }
html[data-theme="light"] .mgd-comm-tag { color: #b3007f; }

/* list view */
.mgd-app.is-list .mgd-grid { grid-template-columns: 1fr; }
.mgd-app.is-list .mgd-card { flex-direction: row; }
.mgd-app.is-list .mgd-card__cover { width: 220px; flex: none; aspect-ratio: auto; min-height: 150px; }
.mgd-app.is-list .mgd-card__desc { display: block; }
.mgd-app.is-list .mgd-card__title { font-size: 17px; }

/* empty + pager */
.mgd-empty { grid-column: 1 / -1; text-align: center; padding: 60px 20px; border: 1px dashed var(--mgd-border); border-radius: var(--mgd-radius); color: var(--mgd-dim); }
.mgd-empty__icon { font-size: 42px; } .mgd-empty h3 { color: var(--mgd-text); margin: 8px 0 4px; }
.mgd-pager { margin-top: 26px; }
.mgd-pager__list { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; list-style: none; margin: 0; padding: 0; }
.mgd-pager__a { display: block; min-width: 38px; text-align: center; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--mgd-border); background: var(--mgd-panel); color: var(--mgd-text) !important; font-size: 14px; }
.mgd-pager__a:hover { border-color: var(--mgd-cyan); }
.mgd-pager__a.is-current { background: var(--mgd-grad); color: #04121a !important; border-color: transparent; font-weight: 700; }
.mgd-pager__gap { padding: 8px 4px; color: var(--mgd-dim); }

/* category tiles */
.mgd-cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }
.mgd-cat { display: flex; flex-direction: column; gap: 2px; padding: 16px; background: var(--mgd-card); border: 1px solid var(--mgd-border); border-radius: var(--mgd-radius); color: var(--mgd-text) !important; transition: .18s; }
.mgd-cat:hover { transform: translateY(-3px); border-color: var(--mgd-cyan); box-shadow: 0 8px 24px rgba(0,229,255,.12); }
.mgd-cat__icon { font-size: 28px; } .mgd-cat__name { font-weight: 700; } .mgd-cat__count { color: var(--mgd-dim); font-size: 12px; }

/* ===== single page ===== */
.mgd-crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13px; color: var(--mgd-dim); margin-bottom: 14px; }
.mgd-crumbs a { color: var(--mgd-cyan); }
.mgd-gh { position: relative; border: 1px solid var(--mgd-border); border-radius: 18px; overflow: hidden; background: var(--mgd-panel); margin-bottom: 22px; }
.mgd-gh__bg { position: absolute; inset: -30px; background-size: cover; background-position: center; filter: blur(34px) saturate(1.4) brightness(.45); }
html[data-theme="light"] .mgd-gh__bg { filter: blur(34px) saturate(1.2) brightness(1.05) opacity(.6); }
.mgd-gh__inner { position: relative; display: grid; grid-template-columns: 300px 1fr; gap: 28px; padding: 28px; align-items: center; }
.mgd-gh__cover { border-radius: 16px; overflow: hidden; box-shadow: 0 16px 40px rgba(0,0,0,.5); background: var(--mgd-panel-2); aspect-ratio: 1 / 1; display: grid; place-items: center; }
.mgd-gh__cover.mgd-cover--wide { aspect-ratio: 460 / 215; align-self: center; }
.mgd-gh__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mgd-gh__title { font: 800 clamp(26px, 3.6vw, 40px)/1.15 'Orbitron','Poppins',sans-serif; margin: 10px 0 6px; color: #fff; text-shadow: 0 2px 20px rgba(0,0,0,.4); }
html[data-theme="light"] .mgd-gh__title { color: var(--mgd-text); text-shadow: none; }
.mgd-gh__dev { margin: 0 0 10px; color: var(--mgd-dim); } .mgd-gh__dev b { color: var(--mgd-text); }
.mgd-gh__rating { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 12px; font-size: 15px; }
.mgd-gh__rating .mgd-stars { font-size: 18px; }
.mgd-gh__meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 18px; }
.mgd-gh__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.mgd-single__grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 22px; align-items: start; }
.mgd-block { background: var(--mgd-panel); border: 1px solid var(--mgd-border); border-radius: var(--mgd-radius); padding: 20px 22px; margin-bottom: 20px; }
.mgd-block h2 { font: 700 18px 'Orbitron','Poppins',sans-serif; margin: 0 0 14px; color: var(--mgd-text); }
.mgd-block h2::before { content: ''; display: inline-block; width: 4px; height: 16px; border-radius: 2px; background: var(--mgd-grad); margin-right: 10px; vertical-align: -2px; }
.mgd-shots { display: grid; gap: 12px; grid-template-columns: repeat(3, 1fr); }
.mgd-shots--1 { grid-template-columns: 1fr; } .mgd-shots--2 { grid-template-columns: repeat(2, 1fr); }
.mgd-shot { padding: 0; border: 1px solid var(--mgd-border); background: var(--mgd-panel-2); border-radius: 12px; overflow: hidden; cursor: zoom-in; aspect-ratio: 16 / 9; transition: .15s; }
.mgd-shot:hover { border-color: var(--mgd-cyan); transform: scale(1.015); }
.mgd-shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mgd-desc { color: var(--mgd-text); line-height: 1.75; font-size: 15px; max-height: 15em; overflow: hidden; position: relative; }
.mgd-desc.is-open { max-height: none; }
.mgd-desc:not(.is-open).is-clamped::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 4em; background: linear-gradient(transparent, var(--mgd-panel)); }
.mgd-desc p { margin: 0 0 1em; }
.mgd-details dl { margin: 0; display: grid; grid-template-columns: 105px 1fr; gap: 10px 12px; font-size: 14px; }
.mgd-details dt { color: var(--mgd-dim); } .mgd-details dd { margin: 0; }
.mgd-storelist { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.mgd-storelist li { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; } .mgd-storelist small { color: var(--mgd-dim); }

/* community */
.mgd-comm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.mgd-sum { display: grid; gap: 16px; } .mgd-sum--empty { text-align: center; padding: 26px; border: 1px dashed var(--mgd-border); border-radius: 12px; color: var(--mgd-dim); } .mgd-sum--empty b { display: block; color: var(--mgd-text); }
.mgd-sum__score { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; } .mgd-sum__score b { font: 800 44px 'Orbitron',sans-serif; line-height: 1; }
.mgd-sum__score span { color: var(--mgd-dim); font-size: 13px; }
.mgd-bar, .mgd-attr { display: grid; grid-template-columns: 34px 1fr 34px; align-items: center; gap: 8px; font-size: 12px; color: var(--mgd-dim); }
.mgd-attr { grid-template-columns: 110px 1fr 32px; } .mgd-attr b { color: var(--mgd-text); }
.mgd-bar i, .mgd-attr i { height: 8px; background: var(--mgd-panel-2); border-radius: 6px; overflow: hidden; }
.mgd-bar u, .mgd-attr u { display: block; height: 100%; background: var(--mgd-grad); text-decoration: none; }
.mgd-bar em { font-style: normal; text-align: right; }
.mgd-rate { background: var(--mgd-panel-2); border: 1px solid var(--mgd-border); border-radius: 12px; padding: 18px; display: grid; gap: 12px; align-content: start; }
.mgd-rate h3 { margin: 0; font: 700 16px 'Poppins',sans-serif; color: var(--mgd-text); }
.mgd-starinput { display: flex; align-items: center; gap: 2px; }
.mgd-starinput button { background: none; border: 0; padding: 0 2px; font-size: 34px; line-height: 1; color: rgba(138,148,184,.4); cursor: pointer; transition: .1s; }
.mgd-starinput button.is-on { color: var(--mgd-gold); text-shadow: 0 0 14px rgba(255,201,77,.5); }
.mgd-starinput button:hover { transform: scale(1.15); }
.mgd-starinput__hint { margin-left: 10px; color: var(--mgd-dim); font-size: 13px; }
.mgd-sliders { display: grid; gap: 8px; }
.mgd-sliders label { display: grid; grid-template-columns: 110px 1fr 22px; align-items: center; gap: 10px; font-size: 13px; color: var(--mgd-dim); }
.mgd-sliders input[type=range] { width: 100%; accent-color: var(--mgd-cyan); opacity: .5; } .mgd-sliders input[type=range].is-set { opacity: 1; }
.mgd-sl-val { order: 3; color: var(--mgd-text); font-weight: 700; text-align: right; }
.mgd-rate input[type=text], .mgd-rate textarea { width: 100%; background: var(--mgd-panel) !important; color: var(--mgd-text) !important; border: 1px solid var(--mgd-border) !important; border-radius: 10px !important; padding: 10px 12px !important; font: inherit; font-size: 14px; resize: vertical; }
.mgd-rate input:focus, .mgd-rate textarea:focus { outline: 0; border-color: var(--mgd-cyan) !important; }
.mgd-rate__foot { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.mgd-rate__who { color: var(--mgd-dim); font-size: 12px; margin-left: auto; }
.mgd-rate__msg { margin: 0; font-size: 13px; min-height: 1em; } .mgd-rate__msg.is-ok { color: var(--mgd-green); } .mgd-rate__msg.is-err { color: var(--mgd-red); }
.mgd-reviews { margin-top: 22px; display: grid; gap: 14px; }
.mgd-review { border: 1px solid var(--mgd-border); border-radius: 12px; padding: 14px 16px; background: var(--mgd-panel-2); } .mgd-review.is-mine { border-color: rgba(0,229,255,.5); }
.mgd-review__head { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }
.mgd-avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--mgd-grad); color: #04121a; font-weight: 800; }
.mgd-review__meta { display: flex; align-items: center; gap: 10px; color: var(--mgd-dim); font-size: 12px; }
.mgd-review__title { margin: 4px 0; font: 700 15px 'Poppins',sans-serif; color: var(--mgd-text); }
.mgd-review__body { margin: 0; line-height: 1.65; font-size: 14px; }
.mgd-review__tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; } .mgd-review__tags span { background: var(--mgd-panel); border: 1px solid var(--mgd-border); border-radius: 999px; padding: 2px 10px; font-size: 11px; color: var(--mgd-dim); }
.mgd-skeleton { color: var(--mgd-dim); padding: 20px; }
#mgd-more-reviews { margin-top: 14px; }
.mgd-similar { margin-top: 8px; } .mgd-grid--similar { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }

/* lightbox */
.mgd-lightbox { position: fixed; inset: 0; z-index: 999999; background: rgba(2,4,10,.94); display: grid; place-items: center; padding: 30px; }
.mgd-lightbox[hidden] { display: none; }
.mgd-lightbox img { max-width: min(1200px, 94vw); max-height: 88vh; max-height: 88dvh; border-radius: 10px; box-shadow: 0 20px 60px rgba(0,0,0,.6); }
.mgd-lightbox button { position: absolute; background: rgba(255,255,255,.1); color: #fff; border: 0; border-radius: 50%; width: 46px; height: 46px; font-size: 28px; line-height: 1; cursor: pointer; }
.mgd-lightbox button:hover { background: rgba(0,229,255,.35); }
.mgd-lightbox__close { top: 18px; right: 18px; } .mgd-lightbox__prev { left: 18px; top: 50%; } .mgd-lightbox__next { right: 18px; top: 50%; }

.mgd-toast { position: fixed; z-index: 999999; left: 50%; bottom: 26px; max-width: calc(100vw - 24px); text-align: center; transform: translateX(-50%); background: var(--mgd-panel, #0d1120); color: var(--mgd-text, #eaf0ff); border: 1px solid var(--mgd-cyan, #00e5ff); border-radius: 12px; padding: 12px 18px; font: 500 14px 'Poppins',sans-serif; box-shadow: 0 10px 40px rgba(0,0,0,.5); }

/* responsive */
@media (max-width: 1100px) { .mgd-single__grid { grid-template-columns: 1fr; } .mgd-comm-grid { grid-template-columns: 1fr; } }
@media (max-width: 900px) {
	.mgd-layout { grid-template-columns: 1fr; }
	.mgd-filter-toggle { display: inline-flex; }
	.mgd-filters { position: fixed; z-index: 99998; top: 0; left: 0; bottom: 0; width: min(88vw, 360px); max-height: none; border-radius: 0 16px 16px 0; transform: translateX(-105%); visibility: hidden; transition: transform .25s, visibility 0s linear .25s; padding-bottom: 80px; overflow-y: auto; overscroll-behavior: contain; }
	.mgd-filters.is-open { transform: none; visibility: visible; transition: transform .25s, visibility 0s; box-shadow: 0 0 60px rgba(0,0,0,.7); }
	.mgd-filters__close { display: block; background: none; border: 0; color: var(--mgd-text); font-size: 28px; cursor: pointer; line-height: 1; }
	.mgd-filters__apply { display: block; position: fixed; bottom: 14px; left: 14px; width: min(88vw, 360px); margin-right: 14px; justify-content: center; }
	.mgd-overlay { position: fixed; inset: 0; z-index: 99997; background: rgba(2,4,10,.6); } .mgd-overlay[hidden] { display: none; }
	.mgd-gh__inner { grid-template-columns: 1fr; padding: 20px; } .mgd-gh__cover { max-width: 260px; }
	.mgd-gh__cover.mgd-cover--wide { max-width: 100%; }
	.mgd-widget .mgd-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
	.mgd-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.mgd-card__body { padding: 10px; } .mgd-card__title { font-size: 13px; } .mgd-card__chips { display: none; }
	.mgd-app.is-list .mgd-card__cover { width: 110px; min-height: 110px; } .mgd-app.is-list .mgd-grid { grid-template-columns: 1fr; }
	.mgd-shots { grid-template-columns: 1fr; } .mgd-sliders label { grid-template-columns: 96px 1fr 20px; }
	.mgd-block { padding: 16px; } .mgd-details dl { grid-template-columns: 90px 1fr; }
	.mgd-select { flex: 1; } .mgd-select select { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .mgd-app *, .mgd-page * { transition: none !important; } }

/* keep theme heading rules (h1-h6 use clamp() sizes) from inflating plugin headings */
.mgd-app h3.mgd-card__title, .mgd-widget h3.mgd-card__title { font-size: 15px; line-height: 1.3; margin: 0; }
.mgd-app.is-list h3.mgd-card__title { font-size: 17px; }
.mgd-page .mgd-rate h3, .mgd-page .mgd-review__title { font-size: 16px; }
.mgd-page .mgd-review__title { font-size: 15px; }
.mgd-app img, .mgd-page img, .mgd-widget img { max-width: none; }
.mgd-card__cover img, .mgd-shot img, .mgd-gh__cover img { max-width: 100%; }
@media (max-width: 560px) { .mgd-app h3.mgd-card__title, .mgd-widget h3.mgd-card__title { font-size: 13px; } }

/* [hidden] must win over component display rules */
.mgd-app [hidden], .mgd-page [hidden], .mgd-widget [hidden] { display: none !important; }
.mgd-rating, .mgd-rating__num, .mgd-rating__count { white-space: nowrap; }
.mgd-card__rating { row-gap: 2px; }
@media (max-width: 560px) { .mgd-card__rating .mgd-rating__count { display: none; } .mgd-search input { font-size: 14px !important; } }

.mgd-i { display: inline-block; vertical-align: -0.2em; flex: none; }
.mgd-pill .mgd-i { width: 16px; height: 16px; opacity: .9; }
.mgd-cat__icon { display: inline-flex; color: var(--mgd-cyan); margin-bottom: 4px; }
.mgd-empty__icon { color: var(--mgd-cyan); display: flex; justify-content: center; }
.mgd-btn .mgd-i { vertical-align: -0.15em; }

/* Wide mode: on big screens the directory may be wider than the theme's content column (up to --mgd-max).
   mgd-core.js measures the real column and sets --mgd-w / --mgd-x, so it works with ANY theme container
   (centered or not, RTL, overflow:hidden…). Without JS the directory simply fills the column. No transform is used,
   so position:fixed children (filter drawer, overlay) keep working. */
.mgd-app { --mgd-max: 1800px; }
.mgd-app.is-wide { width: var(--mgd-w); max-width: none; margin-left: 0; margin-right: 0; position: relative; left: var(--mgd-x, 0px); }
/* theme wrappers that would clip a wide directory (added by mgd-core.js only when needed) */
.mgd-unclip { overflow: visible !important; overflow-x: visible !important; contain: none !important; clip-path: none !important; }

/* Overview paragraph (SEO text) */
.mgd-overview h2 { margin-top: 0; }
.mgd-overview__text p { margin: 0 0 .6em; line-height: 1.7; overflow-wrap: anywhere; }
.mgd-overview__text p:last-child { margin-bottom: 0; }

/* Portrait phone screenshots (App Store / Google Play): natural aspect, fixed height, no cropping. */
.mgd-shots--tall, .mgd-shots--tall.mgd-shots--1, .mgd-shots--tall.mgd-shots--2 { display: flex; flex-wrap: wrap; gap: 14px; grid-template-columns: none; }
.mgd-shots--tall .mgd-shot { aspect-ratio: auto; height: 520px; width: auto; flex: none; display: block; }
.mgd-shots--tall .mgd-shot img { width: auto; height: 100%; max-width: none; object-fit: contain; }
.mgd-shots--wide .mgd-shot img { object-fit: cover; }
@media (max-width: 700px) {
	.mgd-catbar { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; }
	.mgd-catbar::-webkit-scrollbar { display: none; }
	.mgd-shots--tall { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
	.mgd-shots--tall::-webkit-scrollbar { display: none; }
	.mgd-shots--tall .mgd-shot { height: 380px; }
}

@media (max-width: 700px) { .mgd-pill { flex: none; } }

/* Pager: kill theme list bullets / decorative dots */
.mgd-pager__list li { list-style: none !important; margin: 0 !important; padding: 0 !important; background: none !important; }
.mgd-pager__list li::before, .mgd-pager__list li::after { content: none !important; display: none !important; }
.mgd-pager__list li::marker { content: none; }
.mgd-app ul li::before, .mgd-page ul li::before, .mgd-widget ul li::before { content: none !important; display: none !important; }
.mgd-app ul li, .mgd-page ul li, .mgd-widget ul li { list-style: none; }

/* brain-skill radar */
.mgd-radar { display: block; width: 100%; max-width: 340px; height: auto; margin: 4px auto 0; overflow: visible; }
.mgd-radar__grid polygon { fill: none; stroke: var(--mgd-border); stroke-width: 1; }
.mgd-radar__grid polygon:last-of-type { stroke: rgba(255,255,255,.22); }
.mgd-radar__grid line { stroke: var(--mgd-border); stroke-width: 1; }
.mgd-radar__area { fill: rgba(0,229,255,.22); stroke: var(--mgd-cyan); stroke-width: 2; stroke-linejoin: round; }
.mgd-radar__dots circle { fill: var(--mgd-cyan); stroke: var(--mgd-panel); stroke-width: 1.5; }
.mgd-radar__labels text { fill: var(--mgd-dim); font: 600 10.5px 'Poppins', sans-serif; }
.mgd-radar__labels text.is-hi { fill: var(--mgd-text); }
.mgd-profile__note { margin: 6px 0 0; font-size: 11.5px; color: var(--mgd-dim); text-align: center; }
html[data-theme="light"] .mgd-radar__grid polygon:last-of-type { stroke: rgba(0,0,0,.2); }

.mgd-radar__est { fill: none; stroke: var(--mgd-magenta); stroke-width: 1.5; stroke-dasharray: 4 3; stroke-linejoin: round; opacity: .85; }
.mgd-skillrate { margin: 4px 0 12px; border: 1px solid var(--mgd-border); border-radius: 10px; padding: 10px 14px; background: var(--mgd-panel-2); }
.mgd-skillrate summary { cursor: pointer; font-weight: 600; font-size: 14px; color: var(--mgd-text); }
.mgd-skillrate summary em { font-style: normal; color: var(--mgd-dim); font-weight: 400; }
.mgd-skillrate__hint { margin: 8px 0 6px; font-size: 12.5px; color: var(--mgd-dim); }

.mgd-profile__rate { display: flex; justify-content: center; gap: 8px; width: 100%; margin-top: 12px; }

/* archive pages */
.mgd-hero--archive { margin-bottom: 18px; }
.mgd-hero--archive .mgd-hero__sub { max-width: 860px; }
.mgd-hero--archive .mgd-hero__sub p { margin: 0 0 8px; }
.mgd-hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin: 14px 0 0; }
.mgd-related { margin-top: 34px; }
.mgd-related h2 { font: 700 18px 'Orbitron','Poppins',sans-serif; margin: 0 0 12px; color: var(--mgd-text); }
.mgd-related__links { display: flex; flex-wrap: wrap; gap: 8px; }
.mgd-related__links .mgd-chip { padding: 5px 14px; font-size: 13px; border-radius: 8px; }
.mgd-related__links .mgd-chip em { font-style: normal; opacity: .65; font-size: 11px; }
.mgd-cats--collections .mgd-cat { min-height: 120px; }

/* ================= v1.4 — discovery, lists, collections ================= */
.mgd-btn--ghost { background: transparent; }
.mgd-btn[disabled] { opacity: .5; cursor: not-allowed; }
.mgd-hero__actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }

/* compare button on cards */
.mgd-cmpbtn { position: absolute; z-index: 3; top: 10px; right: 52px; width: 34px; height: 34px; display: grid; place-items: center; padding: 0; margin: 0; line-height: 0; background: rgba(6,8,16,.72); backdrop-filter: blur(6px); border: 1px solid rgba(255,255,255,.16); border-radius: 50%; color: #fff; cursor: pointer; transition: .15s; }
.mgd-cmpbtn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mgd-cmpbtn:hover { border-color: var(--mgd-cyan); color: var(--mgd-cyan); }
.mgd-cmpbtn.is-on { background: var(--mgd-cyan); color: #04101a; border-color: var(--mgd-cyan); }
.mgd-card.is-hidden-me { display: none; }

/* compare bar */
.mgd-cmpbar { position: fixed; z-index: 99990; left: 50%; bottom: 18px; transform: translateX(-50%); display: flex; align-items: center; flex-wrap: wrap; gap: 10px; max-width: calc(100vw - 24px); padding: 10px 14px; background: #0d1120; border: 1px solid #232c4a; border-radius: 14px; box-shadow: 0 10px 40px rgba(0,0,0,.55), 0 0 0 1px rgba(0,229,255,.25); color: #eaf0ff; font: 500 13px 'Poppins', sans-serif; }
.mgd-cmpbar[hidden] { display: none; }
.mgd-cmpbar__t { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 50%; background: #131a30; border: 1px solid #232c4a; color: #00e5ff; flex: none; }
.mgd-cmpbar__t svg { width: 16px; height: 16px; }
.mgd-cmpbar__name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.mgd-cmpbar__item { display: inline-flex; align-items: center; gap: 6px; max-width: 200px; padding: 5px 6px 5px 11px; background: #131a30; border: 1px solid #232c4a; border-radius: 8px; white-space: nowrap; overflow: hidden; }
.mgd-cmpbar__item button { flex: none; background: none; border: 0; color: #8a94b8; cursor: pointer; font-size: 18px; line-height: 1; padding: 2px 6px; min-width: 28px; min-height: 28px; }
.mgd-cmpbar__item button:hover { color: #ff4d6d; }
.mgd-cmpbar .mgd-link { color: #00e5ff; }

/* modal */
.mgd-modal { position: fixed; z-index: 99995; inset: 0; display: grid; place-items: center; padding: 16px; background: rgba(3,5,12,.78); backdrop-filter: blur(4px); font-family: 'Poppins', sans-serif; --mgd-panel: #0d1120; --mgd-panel-2: #10152a; --mgd-card: #131a30; --mgd-border: #232c4a; --mgd-cyan: #00e5ff; --mgd-magenta: #ff2ec4; --mgd-gold: #ffc94d; --mgd-green: #33ff9c; --mgd-red: #ff4d6d; --mgd-text: #eaf0ff; --mgd-dim: #8a94b8; --mgd-purple: #7b5cff; --mgd-grad: linear-gradient(135deg,#00e5ff 0%,#7b5cff 55%,#ff2ec4 100%); color: var(--mgd-text); box-sizing: border-box; }
.mgd-modal * { box-sizing: border-box; }
.mgd-modal__box { position: relative; width: min(520px, 100%); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow: auto; padding: 26px; background: var(--mgd-panel); border: 1px solid var(--mgd-border); border-radius: 16px; box-shadow: 0 20px 80px rgba(0,0,0,.6), 0 0 0 1px rgba(123,92,255,.25); }
.mgd-modal--wide .mgd-modal__box { width: min(1080px, 100%); }
.mgd-modal__title { margin: 0 34px 16px 0; font-size: 20px; font-weight: 700; color: var(--mgd-text); background: var(--mgd-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.mgd-modal__x { position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--mgd-border); background: var(--mgd-card); color: var(--mgd-text); font-size: 20px; line-height: 1; cursor: pointer; }
.mgd-modal__x:hover { border-color: var(--mgd-magenta); color: var(--mgd-magenta); }
.mgd-modal__err { min-height: 18px; margin: 6px 0; font-size: 13px; color: var(--mgd-red); }
.mgd-modal__err.is-ok { color: var(--mgd-green); }
.mgd-skeleton { padding: 40px; text-align: center; color: var(--mgd-dim); }
.mgd-fbform { display: flex; flex-direction: column; gap: 12px; }
.mgd-fbform label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--mgd-dim); }
.mgd-fbform input, .mgd-fbform select, .mgd-fbform textarea { width: 100%; padding: 10px 12px; background: var(--mgd-card); border: 1px solid var(--mgd-border); border-radius: 8px; color: var(--mgd-text); font: 400 14px 'Poppins', sans-serif; }
.mgd-fbform input:focus, .mgd-fbform select:focus, .mgd-fbform textarea:focus { outline: none; border-color: var(--mgd-cyan); box-shadow: 0 0 0 3px rgba(0,229,255,.15); }
.mgd-modal .mgd-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; border-radius: 10px; border: 1px solid var(--mgd-border); background: var(--mgd-card); color: var(--mgd-text); font: 600 14px 'Poppins', sans-serif; cursor: pointer; }
.mgd-modal .mgd-btn--primary { background: var(--mgd-grad); border-color: transparent; color: #fff; }

/* compare content */
.mgd-cmp__radar { display: grid; justify-items: center; gap: 12px; margin-bottom: 20px; }
.mgd-cmp__radar svg { max-width: 360px; width: 100%; height: auto; }
.mgd-cmp__legend { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 18px; font-size: 13px; font-weight: 600; }
.mgd-cmp__legend span { display: inline-flex; align-items: center; gap: 6px; }
.mgd-cmp__legend i { width: 12px; height: 12px; border-radius: 3px; background: var(--c); display: inline-block; }
.mgd-cmp__cols { display: grid; gap: 14px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.mgd-cmp__cols--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mgd-cmp__col { padding: 14px; background: var(--mgd-card); border: 1px solid var(--mgd-border); border-top: 3px solid var(--c, var(--mgd-cyan)); border-radius: 12px; font-size: 13px; }
.mgd-cmp__col h3 { margin: 10px 0 2px; font-size: 16px; color: var(--mgd-text); }
.mgd-cmp__col a { color: inherit; }
.mgd-cmp__cover { display: block; aspect-ratio: 16/9; border-radius: 8px; overflow: hidden; background: var(--mgd-panel-2); }
.mgd-cmp__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mgd-cmp__dev { color: var(--mgd-dim); margin-bottom: 8px; }
.mgd-cmp__col dl { margin: 8px 0 0; display: grid; grid-template-columns: auto 1fr; gap: 4px 10px; }
.mgd-cmp__col dt { color: var(--mgd-dim); margin: 0; } .mgd-cmp__col dd { margin: 0; text-align: right; font-weight: 600; overflow-wrap: anywhere; }
.mgd-cmp__col dl { align-items: baseline; }
@media (max-width: 720px) { .mgd-cmp__cols, .mgd-cmp__cols--2 { grid-template-columns: 1fr; } .mgd-modal__box { padding: 20px 16px; } }

/* list popover */
.mgd-listwrap { position: relative; display: inline-block; }
.mgd-listpop { position: absolute; z-index: 99991; min-width: 190px; padding: 6px; background: #0d1120; border: 1px solid #232c4a; border-radius: 12px; box-shadow: 0 14px 40px rgba(0,0,0,.55); display: flex; flex-direction: column; gap: 2px; font-family: 'Poppins', sans-serif; }
.mgd-listpop button { text-align: left; padding: 9px 12px; background: none; border: 0; border-radius: 8px; color: #eaf0ff; font: 500 13px 'Poppins', sans-serif; cursor: pointer; }
.mgd-listpop button:hover { background: #182140; }
.mgd-listpop button.is-on { background: rgba(0,229,255,.14); color: #00e5ff; }
.mgd-listpop .mgd-listpop__rm { color: #ff4d6d; border-top: 1px solid #232c4a; border-radius: 0 0 8px 8px; margin-top: 4px; }
.mgd-listbtn.is-set { border-color: var(--mgd-cyan); color: var(--mgd-cyan); }

/* My games panel */
.mgd-mylists { margin: 0 0 24px; padding: 20px; background: var(--mgd-panel); border: 1px solid var(--mgd-border); border-radius: 16px; }
.mgd-mylists[hidden], .mgd-foryou[hidden], .mgd-mylists__empty[hidden] { display: none; }
.mgd-mylists__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.mgd-mylists__head h2 { margin: 0; font-size: 20px; color: var(--mgd-text); }
.mgd-mylists__tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.mgd-mylists__tabs button { padding: 8px 14px; border-radius: 8px; border: 1px solid var(--mgd-border); background: var(--mgd-card); color: var(--mgd-dim); font: 600 13px 'Poppins', sans-serif; cursor: pointer; }
.mgd-mylists__tabs button.is-on { color: #fff; background: var(--mgd-grad); border-color: transparent; }
.mgd-mylists__empty { padding: 28px; text-align: center; color: var(--mgd-dim); }
.mgd-mylists-grid, #mgd-mylists-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

/* badges */
.mgd-badges { display: flex; flex-wrap: wrap; gap: 10px; }
.mgd-badge { display: flex; align-items: center; gap: 10px; padding: 8px 14px 8px 8px; background: var(--mgd-card); border: 1px solid var(--mgd-border); border-radius: 12px; opacity: .45; filter: grayscale(1); font-size: 13px; font-weight: 600; color: var(--mgd-text); }
.mgd-badge.is-earned { opacity: 1; filter: none; border-color: rgba(255,201,77,.6); box-shadow: 0 0 18px rgba(255,201,77,.15); }
.mgd-badge__icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; background: var(--mgd-grad); color: #fff; }
.mgd-badge__icon svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mgd-badges-wrap { margin-bottom: 8px; }

/* widgets: for you, game of the day */
.mgd-widget__head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 8px 16px; margin-bottom: 14px; }
.mgd-widget__head h2 { margin: 0; font-size: 22px; font-weight: 700; color: var(--mgd-text); }
.mgd-widget__head a { color: var(--mgd-cyan); font-size: 13px; font-weight: 600; }
.mgd-foryou__reason { font-size: 13px; color: var(--mgd-dim); }
.mgd-foryou { margin-bottom: 26px; }
.mgd-gotd__card { position: relative; display: grid; grid-template-columns: minmax(220px, 380px) 1fr; gap: 24px; align-items: center; overflow: hidden; padding: 20px; background: var(--mgd-panel); border: 1px solid var(--mgd-border); border-radius: 16px; }
.mgd-gotd__bg { position: absolute; inset: -20px; background-size: cover; background-position: center; filter: blur(34px) saturate(1.3); opacity: .22; }
.mgd-gotd__cover, .mgd-gotd__body { position: relative; }
.mgd-gotd__cover { display: block; aspect-ratio: 16/10; border-radius: 12px; overflow: hidden; background: var(--mgd-panel-2); box-shadow: 0 10px 30px rgba(0,0,0,.4); }
.mgd-gotd__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mgd-gotd__body h3 { margin: 0 0 8px; font-size: 26px; line-height: 1.2; } .mgd-gotd__body h3 a { color: var(--mgd-text); }
.mgd-gotd__body p { color: var(--mgd-dim); margin: 0 0 14px; line-height: 1.55; }
@media (max-width: 720px) { .mgd-gotd__card { grid-template-columns: 1fr; } }

/* archive pages */
.mgd-hero--archive { padding: 28px 28px 24px; }
.mgd-hero--archive .mgd-hero__title { margin: 0 0 10px; }
.mgd-crumbs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; font-size: 13px; color: var(--mgd-dim); }
.mgd-crumbs a { color: var(--mgd-cyan); }
.mgd-cats--collections { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin: 20px 0; }
.mgd-related { margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--mgd-border); }
.mgd-related h2 { font-size: 18px; margin: 0 0 12px; color: var(--mgd-text); }
.mgd-related__links { display: flex; flex-wrap: wrap; gap: 8px; }
.mgd-archive .mgd-grid { margin-top: 20px; }

/* ================= v1.4 responsive pass ================= */
.mgd-app, .mgd-page, .mgd-widget { overflow-x: clip; }
.mgd-app img, .mgd-page img, .mgd-widget img { max-width: 100%; }
@media (max-width: 1280px) {
	.mgd-widget .mgd-grid { grid-template-columns: repeat(min(var(--mgd-cols, 4), 4), minmax(0, 1fr)); }
}
@media (max-width: 1024px) {
	.mgd-grid--similar { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
	.mgd-hero--archive, .mgd-gh__inner { padding: 20px; }
}
@media (max-width: 900px) {
	.mgd-app, .mgd-widget { padding: 14px 12px 36px; }
	.mgd-page { padding: 12px 12px 40px; }
	.mgd-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
	.mgd-widget .mgd-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.mgd-mylists { padding: 14px; }
	.mgd-gotd__body h3 { font-size: 21px; }
}
@media (max-width: 640px) {
	.mgd-grid, .mgd-grid--similar { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.mgd-card__chips { display: flex; height: 28px; }
	.mgd-card__chips .mgd-chip:nth-child(n+2) { display: none; }
	.mgd-fav, .mgd-cmpbtn { width: 30px; height: 30px; top: 8px; }
	.mgd-fav { right: 8px; } .mgd-cmpbtn { right: 44px; }
	.mgd-fav svg { width: 16px; height: 16px; } .mgd-cmpbtn svg { width: 15px; height: 15px; }
	.mgd-hero__actions { gap: 8px; } .mgd-hero__actions .mgd-btn { flex: 1 1 auto; justify-content: center; }
	.mgd-widget__head h2 { font-size: 18px; }
	.mgd-cats--collections { grid-template-columns: 1fr 1fr; gap: 10px; }
	.mgd-mylists-grid, #mgd-mylists-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.mgd-mylists__tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
	.mgd-mylists__tabs::-webkit-scrollbar { display: none; }
	.mgd-mylists__tabs button { flex: none; }
	.mgd-badge { flex: 1 1 calc(50% - 10px); font-size: 12px; }
	.mgd-cmpbar { left: 8px; right: 8px; bottom: 8px; transform: none; max-width: none; padding: 8px 10px; gap: 6px; }
	.mgd-cmpbar__item { max-width: 120px; }
	.mgd-cmpbar .mgd-btn { flex: 1 1 100%; }
	.mgd-modal { padding: 0; align-items: end; }
	.mgd-modal__box { width: 100%; max-height: 92vh; max-height: 92dvh; border-radius: 16px 16px 0 0; }
	.mgd-modal--wide .mgd-modal__box { width: 100%; }
	.mgd-listpop { position: fixed; left: 12px !important; right: 12px; bottom: 12px; top: auto !important; width: auto; }
	.mgd-gh__title, .mgd-hero__title { font-size: clamp(22px, 7vw, 30px); }
}
@media (max-width: 380px) {
	.mgd-grid, .mgd-grid--similar { gap: 8px; }
	.mgd-card__body { padding: 8px; } .mgd-card__title { font-size: 12.5px; }
}

/* compare bar + modal: self-contained styling (they live outside .mgd-app) */
.mgd-cmpbar .mgd-btn { display: inline-flex; align-items: center; justify-content: center; padding: 9px 16px; border-radius: 10px; border: 1px solid #232c4a; background: #131a30; color: #eaf0ff; font: 600 13px 'Poppins', sans-serif; cursor: pointer; }
.mgd-cmpbar .mgd-btn--primary { background: linear-gradient(135deg,#00e5ff 0%,#7b5cff 55%,#ff2ec4 100%); border-color: transparent; color: #fff; }
.mgd-cmpbar .mgd-btn[disabled] { opacity: .55; cursor: not-allowed; }
.mgd-cmpbar .mgd-link { background: none; border: 0; cursor: pointer; font: 500 13px 'Poppins', sans-serif; }
.mgd-cmp__col h3, .mgd-cmp__col h4 { color: var(--mgd-text) !important; font-size: 16px !important; line-height: 1.3 !important; margin: 10px 0 2px !important; padding: 0 !important; text-align: left !important; background: none !important; -webkit-text-fill-color: currentColor !important; }
.mgd-cmp__col a, .mgd-cmp__col h3 a, .mgd-cmp__col h4 a { color: var(--mgd-text) !important; text-decoration: none; }
.mgd-cmp__col .mgd-cmp__dev { margin-bottom: 8px; }
.mgd-hero--archive .mgd-hero__sub, .mgd-hero--archive p { text-align: left !important; max-width: 920px; }

/* ===== mobile overflow fix: 1fr tracks must not grow with their content ===== */
@media (max-width: 1100px) { .mgd-single__grid, .mgd-comm-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 900px) { .mgd-layout { grid-template-columns: minmax(0, 1fr); } }
.mgd-single__grid > *, .mgd-comm-grid > *, .mgd-layout > *, .mgd-gh__inner > * { min-width: 0; }
.mgd-single__main, .mgd-single__side, .mgd-block { min-width: 0; max-width: 100%; }
.mgd-shots--tall { max-width: 100%; overflow-x: auto; overflow-y: hidden; scrollbar-width: none; -ms-overflow-style: none; }
.mgd-shots--tall::-webkit-scrollbar { display: none; width: 0; height: 0; }
/* no scale on hover here: a scaled shot is taller than its row and made a vertical scrollbar appear */
.mgd-shots--tall .mgd-shot:hover { transform: none; filter: brightness(1.08); }
@media (max-width: 700px) { .mgd-gh__inner { grid-template-columns: minmax(0, 1fr); } }

/* ===== compare button: icon-only round button (top-left of the cover); sits above the theme's header (z-index up to 999999) ===== */
.mgd-cmpbtn { position: absolute; z-index: 3; top: 10px; left: 10px; right: auto; width: 34px; height: 34px; min-width: 0; min-height: 0; padding: 0; margin: 0; display: grid; place-items: center; line-height: 0; border-radius: 50%; font-size: 0; }
.mgd-cmpbtn span { display: grid; place-items: center; line-height: 0; pointer-events: none; }
.mgd-cmpbtn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transform: none; }
.mgd-cmpbtn__on { display: none !important; }
.mgd-cmpbtn.is-on .mgd-cmpbtn__on { display: grid !important; }
.mgd-cmpbtn.is-on .mgd-cmpbtn__off { display: none !important; }
.mgd-cmpbtn.is-on { background: var(--mgd-cyan); color: #04101a; border-color: var(--mgd-cyan); box-shadow: 0 0 0 3px rgba(0,229,255,.25); }
.mgd-cmpbar { z-index: 2147483000; }
.mgd-modal { z-index: 2147483001; }
.mgd-listpop { z-index: 2147482999; }
.mgd-modal__box { max-height: calc(100vh - 32px); margin: auto; }
@media (max-width: 640px) {
	.mgd-cmpbtn { top: 8px; left: 8px; right: auto !important; width: 30px; height: 30px; padding: 0; }
	.mgd-cmpbtn svg { width: 15px; height: 15px; }
}

/* "Your status" poll inside the rating form */
.mgd-poll { margin: 0 0 18px; padding-bottom: 16px; border-bottom: 1px solid var(--mgd-border); }
.mgd-poll__t { font-weight: 700; font-size: 15px; color: var(--mgd-text); margin-bottom: 10px; }
.mgd-poll__t span { margin-left: 8px; font-weight: 400; font-size: 12px; color: var(--mgd-dim); }
.mgd-poll__opts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.mgd-poll__opt { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 6px; background: var(--mgd-card); border: 1px solid var(--mgd-border); border-radius: 10px; color: var(--mgd-text); font: 600 12.5px/1.2 'Poppins', sans-serif; text-align: center; cursor: pointer; transition: .15s; }
.mgd-poll__opt svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; color: var(--mgd-cyan); }
.mgd-poll__opt .mgd-poll__n { font-size: 11px; font-weight: 600; color: var(--mgd-dim); }
.mgd-poll__opt:hover { border-color: var(--mgd-cyan); }
.mgd-poll__opt.is-on { background: var(--mgd-grad); border-color: transparent; color: #fff; box-shadow: 0 6px 20px rgba(123,92,255,.35); }
.mgd-poll__opt.is-on svg, .mgd-poll__opt.is-on .mgd-poll__n { color: #fff; }
.mgd-poll__opt[disabled] { opacity: .6; cursor: wait; }
@media (max-width: 420px) { .mgd-poll__t span { display: none; } .mgd-poll__opt { padding: 9px 4px; font-size: 11.5px; } }

/* "Not interested" button on cards (under the heart) */
.mgd-nibtn { position: absolute; z-index: 3; top: 50px; right: 10px; width: 34px; height: 34px; display: grid; place-items: center; padding: 0; margin: 0; line-height: 0; background: rgba(6,8,16,.72); backdrop-filter: blur(6px); border: 1px solid rgba(255,255,255,.16); border-radius: 50%; color: #fff; cursor: pointer; transition: .15s; opacity: 0; }
.mgd-nibtn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mgd-card:hover .mgd-nibtn, .mgd-nibtn:focus-visible { opacity: 1; }
.mgd-nibtn:hover { border-color: var(--mgd-red); color: var(--mgd-red); }
.mgd-nibtn[disabled] { opacity: .4; }
@media (hover: none) { .mgd-nibtn { opacity: 1; } }
@media (max-width: 640px) { .mgd-nibtn { top: 44px; right: 8px; width: 30px; height: 30px; } }
#mgd-mylists-grid .mgd-nibtn { opacity: 1; }

/* FAQ on category / collection pages */
.mgd-faq { margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--mgd-border); max-width: 920px; }
.mgd-faq h2 { font-size: 18px; margin: 0 0 12px; color: var(--mgd-text); }
.mgd-faq__item { background: var(--mgd-card); border: 1px solid var(--mgd-border); border-radius: 10px; margin-bottom: 8px; padding: 0 16px; }
.mgd-faq__item summary { cursor: pointer; padding: 13px 0; font-weight: 600; font-size: 14.5px; color: var(--mgd-text); list-style: none; }
.mgd-faq__item summary::-webkit-details-marker { display: none; }
.mgd-faq__item summary::after { content: '+'; float: right; color: var(--mgd-cyan); font-size: 18px; line-height: 1; }
.mgd-faq__item[open] summary::after { content: '–'; }
.mgd-faq__item p { margin: 0 0 14px; color: var(--mgd-dim); line-height: 1.6; font-size: 14px; text-align: left; }


/* ---- 1.4.1: accessibility ---- */
.mgd-search:focus-within { outline: 2px solid var(--mgd-cyan, #00e5ff); outline-offset: 2px; }
.mgd-app a:focus-visible, .mgd-app button:focus-visible, .mgd-app select:focus-visible, .mgd-app summary:focus-visible, .mgd-app input[type=checkbox]:focus-visible, .mgd-app input[type=radio]:focus-visible,
.mgd-page a:focus-visible, .mgd-page button:focus-visible, .mgd-page summary:focus-visible, .mgd-page input:focus-visible, .mgd-page textarea:focus-visible,
.mgd-modal a:focus-visible, .mgd-modal button:focus-visible, .mgd-modal input:focus-visible, .mgd-modal select:focus-visible, .mgd-modal textarea:focus-visible,
.mgd-lightbox button:focus-visible, .mgd-widget a:focus-visible, .mgd-widget button:focus-visible { outline: 2px solid var(--mgd-cyan, #00e5ff) !important; outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
	.mgd-app *, .mgd-page *, .mgd-modal *, .mgd-widget *, .mgd-toast { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* Brain-games block on Mentometry player profiles */
.mgd-pblock { max-width: 960px; margin: 28px auto; padding: 20px; background: var(--mgd-panel); border: 1px solid var(--mgd-border); border-radius: 16px; }
.mgd-pblock .mgd-widget__head h2 { font-size: 20px; }
.mgd-pblock__stats { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 0 0 14px; color: var(--mgd-dim); font-size: 13px; }
.mgd-pblock__stats b { color: var(--mgd-text); font-size: 18px; margin-right: 4px; }
.mgd-pblock__empty { color: var(--mgd-dim); margin: 0; font-size: 14px; }
.mgd-pblock__foryou { margin: 18px 0 0; padding-top: 16px; border-top: 1px solid var(--mgd-border); }
.mgd-pblock__foryou h3 { margin: 0 0 12px; font-size: 16px; color: var(--mgd-text); }
.mgd-pblock__foryou .mgd-foryou__reason { font-size: 12px; font-weight: 400; color: var(--mgd-dim); display: block; margin-top: 4px; }
.mgd-pblock .mgd-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.mgd-card__chips .mgd-chip { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
