/* STRive Sponsors – everything is scoped to .strs-* so nothing else on the site is affected. */
.strs-wrap { width: 100%; }
.strs-wrap *, .strs-modal * { box-sizing: border-box; }

.strs-section { padding: 90px 20px; color: var(--strs-fg); }
.strs-section:not(.strs-has-bg) { --strs-fg: inherit; padding: 32px 0; }

.strs-heading {
	margin: 0 0 60px; padding: 0; text-align: center; color: var(--strs-fg);
	font-family: inherit; font-size: 20px; font-weight: 700; letter-spacing: 0; line-height: 1.2; text-transform: uppercase;
}

/* Themes often force heading colours; the level's own text colour must win. */
.strs-wrap .strs-section .strs-heading { color: var(--strs-fg) !important; }

.strs-grid {
	display: flex; flex-wrap: wrap; justify-content: center; align-items: center;
	gap: var(--strs-gap, 28px); max-width: 1700px; margin: 0 auto;
}

.strs-wrap .strs-logo {
	-webkit-appearance: none; appearance: none; display: inline-flex; align-items: center; justify-content: center;
	margin: 0; padding: 12px; border: 0; border-radius: 12px; background: transparent; box-shadow: none;
	color: inherit; line-height: 0; cursor: pointer; text-decoration: none;
	transition: transform .2s ease, background-color .2s ease;
}
.strs-wrap span.strs-logo { cursor: default; }
.strs-wrap .strs-logo:hover, .strs-wrap .strs-logo:focus { background: rgba(255, 255, 255, .10); transform: translateY(-3px); }
.strs-level-gold .strs-logo:hover, .strs-level-silver .strs-logo:hover,
.strs-section:not(.strs-has-bg) .strs-logo:hover { background: rgba(0, 0, 0, .06); }
.strs-wrap .strs-logo:focus { outline: none; }
.strs-wrap .strs-logo:focus-visible { outline: 3px solid currentColor; outline-offset: 2px; }

/* Optical logo box: the image is positioned so only its visible (trimmed) area fills the box. */
.strs-crop { position: relative; display: block; overflow: hidden; width: calc(var(--w) * 1px); height: calc(var(--h) * 1px); }
.strs-wrap .strs-crop img {
	position: absolute; left: var(--cl); top: var(--ct);
	width: var(--cw) !important; height: var(--ch) !important; max-width: none !important; max-height: none !important;
	margin: 0 !important; padding: 0 !important; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; opacity: 1;
}
.strs-name { display: block; max-width: 220px; font-size: 18px; font-weight: 700; line-height: 1.25; color: var(--strs-fg); }
.strs-empty { padding: 24px; border: 2px dashed #c9c2d0; border-radius: 8px; text-align: center; font: 14px/1.4 sans-serif; color: #4a3b58; }

@media (max-width: 767px) {
	.strs-section { padding: 44px 14px; }
	.strs-heading { margin-bottom: 26px; }
	/* Phones: an even two-column grid; every logo is capped to its cell and keeps its proportions. */
	.strs-grid {
		display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); justify-items: center; align-items: center;
		gap: 12px 8px; max-width: 520px;
	}
	.strs-level-presenting .strs-grid, .strs-level-sapphire .strs-grid { grid-template-columns: minmax(0, 1fr); }
	.strs-grid > *:last-child:nth-child(odd) { grid-column: 1 / -1; }
	.strs-profiles { grid-template-columns: minmax(0, 1fr); gap: 44px; }
	.strs-profile .strs-crop { width: calc(var(--w) * 1px); }
	.strs-wrap .strs-profile .strs-logo-static { min-height: 110px; }
	.strs-wrap .strs-logo { width: 100%; padding: 8px; justify-content: center; }
	.strs-crop {
		width: calc(var(--w) * var(--strs-mscale, .7) * 1px); max-width: 100%;
		height: auto; aspect-ratio: var(--w) / var(--h);
	}
}

/* Profiles layout (sponsor pages): a card per sponsor with logo, description and links */
.strs-profiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 56px 64px; max-width: 1100px; margin: 0 auto; align-items: start; }
.strs-profile { text-align: left; color: var(--strs-fg); }
.strs-wrap .strs-profile .strs-logo-static { display: flex; width: 100%; min-height: 150px; padding: 0; margin: 0 0 14px; align-items: center; justify-content: flex-start; cursor: default; }
.strs-wrap .strs-profile .strs-logo-static:hover { transform: none; background: transparent; }
.strs-wrap .strs-profile .strs-p-name { margin: 0 0 12px; padding: 0; font-size: 22px; font-weight: 700; line-height: 1.25; color: var(--strs-fg) !important; }
.strs-wrap .strs-p-text, .strs-wrap .strs-p-text p, .strs-wrap .strs-p-text li, .strs-wrap .strs-p-text a { color: var(--strs-fg) !important; }
.strs-p-text { font-size: 16px; line-height: 1.65; }
.strs-p-text p { margin: 0 0 12px; }
.strs-p-links { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin-top: 18px; }
.strs-wrap a.strs-p-btn { display: inline-block; padding: 11px 22px; border-radius: 999px; background: var(--strs-btn, #FF00C7); color: #fff; font-weight: 700; font-size: 15px; text-decoration: none; line-height: 1.2; }
.strs-wrap a.strs-p-btn:hover { filter: brightness(1.08); }
.strs-wrap a.strs-p-soc { color: var(--strs-fg); font-weight: 600; font-size: 15px; text-decoration: underline; text-underline-offset: 3px; }

/* Popup */
.strs-modal {
	position: fixed; inset: 0; z-index: 999999; display: flex; align-items: center; justify-content: center; padding: 20px;
	background: rgba(20, 9, 28, .72); opacity: 0; visibility: hidden; transition: opacity .2s ease, visibility .2s ease;
	font-family: inherit;
}
.strs-modal.is-open { opacity: 1; visibility: visible; }
.strs-dialog {
	position: relative; width: 100%; max-width: 580px; max-height: calc(100vh - 40px); overflow: auto;
	background: #fff; color: #14091C; border-radius: 18px; box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
	transform: translateY(12px); transition: transform .2s ease; text-align: left;
}
.strs-modal.is-open .strs-dialog { transform: none; }
.strs-d-head {
	padding: 14px 60px 14px 24px; background: var(--strs-lvl, #323232); color: var(--strs-lvlfg, #fff);
	font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; line-height: 1.4;
}
.strs-modal .strs-d-close {
	position: absolute; top: 7px; right: 10px; width: 38px; height: 38px; padding: 0; margin: 0;
	display: flex; align-items: center; justify-content: center; border: 0; border-radius: 50%;
	background: rgba(0, 0, 0, .28); color: #fff; font-size: 24px; line-height: 1; cursor: pointer;
}
.strs-modal .strs-d-close:hover { background: rgba(0, 0, 0, .45); }
.strs-d-body { padding: 28px 28px 30px; }
.strs-d-logo { display: flex; align-items: center; justify-content: center; height: 96px; margin: 0 0 18px; }
.strs-d-logo img { max-width: 72%; max-height: 96px; width: auto; height: auto; object-fit: contain; }
.strs-d-name { margin: 0 0 12px; font-size: 24px; font-weight: 700; line-height: 1.25; text-align: center; color: #14091C; }
.strs-d-short { margin: 0 0 14px; font-size: 16px; line-height: 1.6; }
.strs-d-more { margin: 0 0 12px; }
.strs-d-more summary { cursor: pointer; font-weight: 700; font-size: 15px; color: #4a3b58; }
.strs-d-more div { margin-top: 10px; font-size: 15px; line-height: 1.6; }
.strs-d-more div p { margin: 0 0 10px; }
.strs-d-offer {
	margin: 16px 0 4px; padding: 12px 16px; border-left: 4px solid var(--strs-btn, #FF00C7); border-radius: 8px;
	background: #FFF0FB; font-size: 15px; line-height: 1.5;
}
.strs-d-offer strong { display: block; margin-bottom: 2px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.strs-d-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px; margin-top: 22px; }
.strs-modal a.strs-d-btn {
	display: inline-block; padding: 13px 28px; border-radius: 999px; background: var(--strs-btn, #FF00C7);
	color: #fff !important; font-size: 15px; font-weight: 700; line-height: 1.2; text-decoration: none !important;
}
.strs-modal a.strs-d-btn:hover { filter: brightness(1.08); }
.strs-d-social { display: flex; gap: 8px; }
.strs-modal .strs-d-social a {
	display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px;
	border-radius: 50%; background: #F2EEF5; color: #14091C; text-decoration: none;
}
.strs-modal .strs-d-social a:hover { background: #E7DDF0; }
.strs-d-social svg { width: 18px; height: 18px; fill: currentColor; }
.strs-d-event { margin-top: 20px; text-align: center; font-size: 12px; color: #7a6c86; }
body.strs-lock { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
	.strs-wrap .strs-logo, .strs-modal, .strs-dialog { transition: none; }
}

/* v1.0.8: mobile profiles must come after the base .strs-profiles rule to win the cascade */
@media (max-width: 767px) {
	.strs-wrap .strs-profiles { grid-template-columns: minmax(0, 1fr); gap: 44px; }
	.strs-wrap .strs-profile .strs-p-name { font-size: 20px; overflow-wrap: anywhere; }
	.strs-wrap .strs-profile .strs-logo-static { min-height: 110px; }
}
