/*
Theme Name: SpeakerGrid Child
Template: astra
Author: Faran
Author URI: https://faran.dev
Description: Custom child theme for the SpeakerGrid WordPress speaker directory.
Tags: custom-menu,custom-logo,entertainment,one-column,two-columns,left-sidebar,e-commerce,right-sidebar,custom-colors,editor-style,featured-images,full-width-template,microformats,post-formats,rtl-language-support,theme-options,threaded-comments,translation-ready,blog
Version: 1.0.0.1791408558
Updated: 2026-10-07 21:29:18
*/

/* Design tokens. Colours follow Astra's palette; the fallback is the current design. */

:root {

	/* Colour.
	   Accent is deliberately Astra's near-black, not the purple palette colour -
	   the Speaker pages stay black / white like the rest of the site. */
	--sg-accent:    var(--ast-global-color-2, #171c26);
	--sg-heading:   var(--ast-global-color-2, #171c26);
	--sg-body:      var(--ast-global-color-3, #59616d);
	--sg-surface:   var(--ast-global-color-4, #f5f6f8);
	--sg-page:      var(--ast-global-color-5, #ffffff);
	--sg-muted:     #78808c;
	--sg-border:    #e4e7ec;
	--sg-border-strong: #d3d8e0;

	/* Shape */
	--sg-radius:    16px;
	--sg-radius-md: 10px;
	--sg-radius-sm: 8px;

	/* Elevation */
	--sg-shadow:       0 1px 2px rgba(16, 22, 33, 0.04);

	/* Rhythm */
	--sg-gutter:    clamp(18px, 2vw, 26px);
	--sg-section:   clamp(56px, 7vw, 96px);

	/* Controls */
	--sg-control-h: 50px;
}


/* Shared icon defaults */

.sg-icon {
	flex: none;
	display: inline-block;
	vertical-align: middle;
}

/* SpeakerGrid - Single Speaker */


/* HERO */

.sg-speaker-hero {
	padding: var(--sg-section) 0;
}

.sg-hero-grid {
	display: grid;
	grid-template-columns: 0.9fr 1.1fr;
	gap: 75px;
	align-items: center;
}

.sg-speaker-image {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 5;
	object-fit: cover;
	border-radius: 8px;
}

.sg-speaker-intro h1 {
	margin: 16px 0;
	font-size: clamp(48px, 5vw, 72px);
	line-height: 1;
	letter-spacing: -2px;
	color: #151922;
}

.sg-back {
	display: inline-block;
	margin-bottom: 22px;
	font-size: 14px;
	font-weight: 600;
	color: #68707c;
	text-decoration: none;
}

.sg-tagline {
	margin: 0 0 10px;
	font-size: 23px;
	line-height: 1.4;
	color: #343b47;
}

.sg-position {
	margin: 0 0 24px;
	color: #707884;
}

.sg-short-bio {
	max-width: 620px;
	margin: 0 0 30px;
	font-size: 17px;
	line-height: 1.75;
	color: #59616d;
}


/* TAGS */

.sg-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.sg-tags > * {
	display: inline-block;
	padding: 7px 14px;
	border-radius: 999px;
	background: #f1f2f4;
	color: #343a44;
	font-size: 13px;
	font-weight: 500;
	text-decoration: none;
}


/* BUTTON */


/* CONTENT */

.sg-speaker-content {
	padding: calc(var(--sg-section) * 0.8) 0 var(--sg-section);
}

.sg-content-grid {
	display: grid;
	grid-template-columns: 1fr 360px;
	gap: 90px;
	align-items: start;
}

.sg-label {
	margin: 0 0 12px;
	font-size: 12px;
	font-weight: 800;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--sg-muted);
}

.sg-about h2 {
	margin: 0 0 28px;
	font-size: clamp(36px, 4vw, 48px);
	line-height: 1.15;
	letter-spacing: -1px;
}

.sg-bio {
	max-width: 720px;
	font-size: 18px;
	line-height: 1.8;
	color: #59616d;
}

.sg-expertise {
	margin-top: 50px;
	padding-top: 35px;
	border-top: 1px solid #e3e6ea;
}

.sg-expertise h3 {
	margin-bottom: 18px;
}


/* DETAILS CARD */

.sg-details {
	position: sticky;
	top: 100px;
	padding: 38px;
	background: #171c26;
	color: #fff;
	border-radius: 8px;
	box-shadow: 0 18px 40px rgba(20, 27, 38, 0.1);
}

.sg-details h3 {
	margin: 0 0 24px;
	color: #fff;
	font-size: 24px;
}

.sg-detail {
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding: 18px 0;
	border-bottom: 1px solid rgba(255,255,255,0.13);
}

.sg-detail span {
	font-size: 11px;
	letter-spacing: 1px;
	text-transform: uppercase;
	color: #9ca4af;
}

.sg-detail strong {
	font-size: 16px;
	color: #fff;
}

/* Sits on the dark details card, so it inverts Astra's button */
.sg-button-light,
.sg-button-light:hover {
	width: 100%;
	margin-top: 28px;
	background: #fff;
	border-color: #fff;
	color: #171c26;
}


/* TABLET */

@media (max-width: 921px) {

	.sg-hero-grid {
		gap: 45px;
	}

	.sg-content-grid {
		grid-template-columns: 1fr 300px;
		gap: 45px;
	}

}


/* MOBILE */

@media (max-width: 767px) {

	.sg-hero-grid,
	.sg-content-grid {
		grid-template-columns: 1fr;
	}

	.sg-hero-grid {
		gap: 40px;
	}

	.sg-speaker-intro h1 {
		font-size: 44px;
	}

	.sg-content-grid {
		gap: 50px;
	}

	.sg-details {
		position: static;
	}

}


/* SpeakerGrid - Speaker Directory */

.sg-directory {
	/* Fill Astra's flex container regardless of the results' intrinsic width. */
	width: 100%;
	min-width: 0;
}


/* HERO */

.sg-directory-hero {
	padding: var(--sg-section) 0 calc(var(--sg-section) * 0.7);
	background: var(--sg-surface);
}

.sg-directory-hero h1 {
	max-width: 16ch;
	margin: 0 0 20px;
	font-size: clamp(38px, 5.5vw, 68px);
	line-height: 1.05;
	letter-spacing: -0.03em;
	color: var(--sg-heading);
}

.sg-directory-intro {
	max-width: 62ch;
	margin: 0;
	font-size: clamp(16px, 1.2vw, 18px);
	line-height: 1.7;
	color: var(--sg-body);
}


/* RESULTS */

.sg-directory-results {
	padding: calc(var(--sg-section) * 0.8) 0 var(--sg-section);
}


/* Speaker Grid */

/* A column per 270px; desktop pins three. */
.sg-speaker-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
	gap: calc(var(--sg-gutter) + 8px) var(--sg-gutter);
}

@media (min-width: 922px) {

	.sg-speaker-grid {
		grid-template-columns: repeat(3, 1fr);
	}

}


/* Speaker Card */

.sg-card {
	position: relative;
	display: flex;
	flex-direction: column;
	height: 100%;

	/* The inset frame around the portrait */
	padding: 10px;

	border: 1px solid var(--sg-border);
	border-radius: var(--sg-radius);
	box-shadow: var(--sg-shadow);
}

/* Only hover state: the border darkens. No transforms - one would lift the footer above
   the stretched link and kill the bottom-right click target. */
.sg-card:hover {
	border-color: var(--sg-border-strong);
}


/* Media */

/* Decorative duplicate of the title link, kept out of hit testing. */
.sg-card-media {
	display: block;
	overflow: hidden;
	pointer-events: none;

	aspect-ratio: 4 / 5;
	border-radius: var(--sg-radius-md);
	background: var(--sg-surface);
}

.sg-card-media img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* A full-width 4:5 portrait makes a phone page enormous, so cards go square. */
@media (max-width: 599px) {

	.sg-card-media {
		aspect-ratio: 1 / 1;
	}

}

/* Shown when a speaker has no featured image */
.sg-card-placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	color: var(--sg-muted);
	opacity: 0.5;
}


/* Body */

.sg-card-body {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: 18px 8px 0;
}

.sg-card-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-bottom: 12px;
}

.sg-chip {
	display: inline-flex;
	align-items: center;
	padding: 7px 14px;

	border-radius: 999px;

	background: #f1f2f4;
	color: #343a44;

	font-size: 13px;
	font-weight: 500;
	line-height: 1.2;
}

.sg-card-title {
	margin: 0 0 7px;
	font-size: clamp(20px, 1.5vw, 24px);
	line-height: 1.25;
	letter-spacing: -0.015em;
}

.sg-card-title a {
	color: var(--sg-heading);
	text-decoration: none;
}

/* Stretches the title link over the card: one tab stop, every pixel clickable. */
.sg-card-title a::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	border-radius: var(--sg-radius);
}

.sg-card-tagline {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	line-clamp: 2;
	overflow: hidden;

	margin: 0;
	font-size: 14.5px;
	line-height: 1.6;
	color: var(--sg-body);
}


/* Footer */

.sg-card-footer {
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px;

	margin-top: 16px;
	padding: 14px 8px 4px;

	border-top: 1px solid var(--sg-border);
}

.sg-card-location {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-width: 0;
	margin: 0;

	font-size: 13px;
	font-weight: 600;
	color: var(--sg-muted);
}

/* Long country names ellipsize instead of pushing the button down. */
.sg-card-location span {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.sg-card-location .sg-icon {
	opacity: 0.75;
}

.sg-card-cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: none;

	width: 38px;
	height: 38px;

	border: 1px solid var(--sg-border);
	border-radius: 50%;

	color: var(--sg-heading);

	/* Purely a visual affordance - the whole card is the link */
	pointer-events: none;
}

.sg-card:hover .sg-card-cta {
	background: var(--sg-accent);
	border-color: var(--sg-accent);
	color: #fff;
}


/* Keyboard focus */

.sg-card:has(a:focus-visible) {
	outline: 2px solid var(--sg-accent);
	outline-offset: 3px;
}

.sg-card:has(a:focus-visible) .sg-card-cta {
	background: var(--sg-accent);
	border-color: var(--sg-accent);
	color: #fff;
}

.sg-card-title a:focus-visible {
	outline: none;
}

/* Featured Speakers [speakergrid_speakers].
   auto-fit responds to the container; the archive media query measures the viewport,
   which is wrong inside a page builder. */

.sg-speaker-grid.sg-featured {
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

/* No scrollbar on the swipe row - the part-visible next card is the cue. */
.sg-speaker-grid.sg-featured-carousel {
	scrollbar-width: none;
}

.sg-speaker-grid.sg-featured-carousel::-webkit-scrollbar {
	display: none;
}


@media (max-width: 599px) {

	.sg-speaker-grid.sg-featured-carousel {
		grid-auto-flow: column;
		grid-auto-columns: 78%;
		grid-template-columns: none;

		overflow-x: auto;
		scroll-snap-type: x mandatory;
		overscroll-behavior-x: contain;
	}

	.sg-featured-carousel .sg-card {
		scroll-snap-align: start;
	}

}


/* Speaker Filters */

.sg-filters {
	margin-bottom: 30px;
	padding: clamp(18px, 2vw, 24px);

	border: 1px solid var(--sg-border);
	border-radius: var(--sg-radius);
	box-shadow: var(--sg-shadow);
}

.sg-filters-heading {
	display: flex;
	align-items: center;
	gap: 8px;

	margin: 0 0 16px;
	padding-bottom: 14px;

	border-bottom: 1px solid var(--sg-border);

	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--sg-muted);
}

.sg-filters-row {
	display: grid;
	grid-template-columns: 1fr;
	gap: 14px;
	align-items: end;
}

@media (min-width: 600px) {

	.sg-filters-row {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

}

@media (min-width: 922px) {

	.sg-filters-row {
		grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1fr) auto;
	}

}

.sg-filter-field {
	display: flex;
	min-width: 0;
	flex-direction: column;
	gap: 7px;
}

.sg-filter-field label {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--sg-muted);
}


/* Input and select share one shell so the icons line up */

.sg-control {
	position: relative;
	display: flex;
	align-items: center;
}

.sg-control input,
.sg-control select {
	width: 100%;
	height: var(--sg-control-h);
	padding: 0 14px;

	border: 1px solid var(--sg-border);
	border-radius: var(--sg-radius-sm);

	background-color: var(--sg-page);

	font-size: 15px;
	line-height: 1.2;

	text-overflow: ellipsis;
}

.sg-control select {
	appearance: none;
	padding-right: 40px;
	cursor: pointer;
}

.sg-control-icon {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	pointer-events: none;
	color: var(--sg-muted);
}

.sg-control-icon-left {
	left: 14px;
}

.sg-control-icon-right {
	right: 14px;
}

.sg-control-icon-left ~ input {
	padding-left: 40px;
}

.sg-control input:focus-visible,
.sg-control select:focus-visible {
	outline: none;
	border-color: var(--sg-accent);
	box-shadow: 0 0 0 3px color-mix(in srgb, var(--sg-accent) 20%, transparent);
}

.sg-filter-actions {
	display: flex;
	align-items: center;
}

/* Colour, padding, border and font come from Astra's button styling. */
.sg-filter-button {
	width: 100%;
	height: var(--sg-control-h);
	white-space: nowrap;
}


/* Results header */

.sg-results-header {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 10px 20px;
	margin-bottom: 22px;
}

.sg-results-count {
	margin: 0;
	font-size: 14px;
	font-weight: 600;
	color: var(--sg-body);
}

.sg-filter-reset {
	display: inline-flex;
	align-items: center;
	gap: 6px;

	font-size: 13px;
	font-weight: 600;
	color: var(--sg-muted);
	text-decoration: none;
}

.sg-filter-reset:hover {
	color: var(--sg-heading);
}


/* Empty results */

.sg-no-results {
	padding: clamp(48px, 7vw, 76px) 24px;
	text-align: center;

	border: 1px solid var(--sg-border);
	border-radius: var(--sg-radius);
}

.sg-no-results-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;

	width: 64px;
	height: 64px;
	margin-bottom: 20px;

	border-radius: 50%;
	background: var(--sg-surface);
	color: var(--sg-muted);
}

.sg-no-results h2 {
	margin: 0 0 10px;
	font-size: clamp(22px, 2.4vw, 28px);
}

.sg-no-results p {
	margin: 0 0 24px;
	color: var(--sg-body);
}


/* Pagination */

.sg-pagination {
	margin-top: clamp(44px, 5vw, 70px);
}

.sg-pagination .nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.sg-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 7px;

	min-width: 46px;
	height: 46px;
	padding: 0 16px;

	border: 1px solid var(--sg-border);
	border-radius: var(--sg-radius-sm);

	background: var(--sg-page);
	color: var(--sg-heading);

	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
}

.sg-pagination a.page-numbers:hover {
	border-color: var(--sg-border-strong);
	background: var(--sg-surface);
}

.sg-pagination .page-numbers.current {
	background: var(--sg-heading);
	border-color: var(--sg-heading);
	color: #fff;
}

.sg-pagination .page-numbers.dots {
	border-color: transparent;
	background: transparent;
}
