/**
 * Voting Contest page — visual pass over the wp-voting-contest plugin's
 * default MUI markup, which ships with no real design: mismatched card
 * media heights, an unstyled filter bar, and off-brand accent colors.
 * Enqueued only on the voting-contest page (see enqueue.php); every rule
 * is scoped under body.voting-contest so it can never leak elsewhere.
 *
 * Brand colors pulled from styles-v2.css: #00a9c6 (site teal, matches the
 * plugin's own inline rgb(1,170,199) almost exactly) and #ea1c2d (site red).
 */

body.voting-contest .wpvc_showcontestant_container {
	padding-left: 0 !important;
	padding-right: 0 !important;
}

/* ---------------------------------------------------------------------
   1. Submit Entry bar + filter bar (both are `.wpvc_app_bar` instances)
   --------------------------------------------------------------------- */

body.voting-contest .wpvc_navigation_bar {
	margin: 0 !important;
}

body.voting-contest .wpvc_app_bar {
	background: linear-gradient(135deg, #00b8d6, #036777) !important;
	border-radius: 10px !important;
	box-shadow: 0 6px 18px rgba(3, 103, 119, 0.25) !important;
}

body.voting-contest .wpvc_app_bar .MuiToolbar-root {
	padding: 16px 20px !important;
	min-height: auto !important;
}

/* Submit Entry link */
body.voting-contest .wpvc_voting_nav_grid {
	width: 100%;
}

body.voting-contest .wpvc_navigation {
	font-family: Montserrat, sans-serif !important;
	font-weight: 700 !important;
	font-size: 14px !important;
	letter-spacing: 0.03em;
	text-transform: uppercase;
}

/* Filter bar fields */
body.voting-contest .wpvc_navigation_show_all_grid {
	align-items: center;
}

body.voting-contest .wpvc_label_grid {
	padding: 0 !important;
}

body.voting-contest .wpvc_form_control_ad {
	width: 100%;
}

/* Search input */
body.voting-contest .wpvc_text_navigation.MuiOutlinedInput-root,
body.voting-contest .wpvc_text_navigation .MuiOutlinedInput-root {
	background: #fff;
	border-radius: 999px;
	height: 44px;
}

body.voting-contest .wpvc_text_navigation .MuiOutlinedInput-notchedOutline {
	border-color: transparent !important;
}

body.voting-contest .wpvc_text_navigation .MuiOutlinedInput-input {
	padding: 10px 4px 10px 18px !important;
	font-family: Montserrat, sans-serif;
	color: #231f20;
}

body.voting-contest .wpvc_allcontest_search {
	margin-right: 4px;
}

body.voting-contest .wpvc_allcontest_search .MuiIconButton-root {
	background: #00a9c6;
	color: #fff;
}

body.voting-contest .wpvc_allcontest_search svg {
	color: inherit;
}

/* Sort + Category selects (MUI "standard/underline" variant) */
body.voting-contest .wpvc_text_navigation.MuiInput-underline {
	background: #fff;
	border-radius: 999px;
	height: 44px;
	display: flex;
	align-items: center;
	padding: 0 18px;
}

body.voting-contest .wpvc_text_navigation.MuiInput-underline::before,
body.voting-contest .wpvc_text_navigation.MuiInput-underline::after {
	display: none !important;
}

body.voting-contest .wpvc_navigation_show_all_grid .MuiSelect-select {
	font-family: Montserrat, sans-serif;
	font-weight: 600;
	font-size: 14px;
	color: #231f20;
	padding-right: 22px !important;
}

body.voting-contest .wpvc_navigation_show_all_grid .MuiSelect-icon {
	color: #00a9c6;
}

/* ---------------------------------------------------------------------
   2. Contestant grid + cards
   --------------------------------------------------------------------- */

body.voting-contest .wpvc_show_style {
	margin-top: 4px !important;
}

body.voting-contest .wpvc_show_style_row {
	display: flex;
}

body.voting-contest .wpvc_card_row.wpvc_showall_container {
	width: 100%;
	display: flex;
	flex-direction: column;
	border-radius: 12px !important;
	overflow: hidden;
	transition: transform 0.18s ease, box-shadow 0.18s ease;
}

body.voting-contest .wpvc_card_row.wpvc_showall_container:hover {
	transform: translateY(-4px);
	box-shadow: 0 14px 28px rgba(23, 41, 56, 0.16) !important;
}

/* Title */
body.voting-contest .wpvc_card_show_header {
	padding: 14px 16px 10px !important;
}

body.voting-contest .wpvc_card_show_header .MuiCardHeader-title a {
	font-family: Montserrat, sans-serif;
	font-weight: 700 !important;
	font-size: 15px !important;
	letter-spacing: 0.02em;
	color: #ea1c2d !important;
}

/* Media — one fixed-ratio box for every entry type (photo, Instagram,
   Facebook, YouTube, Vimeo, TikTok). The plugin only ever set this
   aspect ratio for plain-photo cards, leaving every embed to render at
   whatever height its own SDK inline-styled it to — the direct cause of
   the ragged grid. Forcing every embed's markup to absolutely fill this
   box overrides that inline sizing regardless of embed type. */
body.voting-contest .wpvc_card_media_row,
body.voting-contest .wpvc_card_video_media_row {
	height: 0 !important;
	padding-top: 70% !important;
	position: relative;
	background-color: #eef7fa;
	background-size: cover !important;
	background-position: center !important;
}

body.voting-contest .wpvc_card_video_media_row > *,
body.voting-contest .wpvc_card_video_media_row iframe,
body.voting-contest .wpvc_card_video_media_row span,
body.voting-contest .wpvc_card_video_media_row .fb-video {
	position: absolute !important;
	top: 0 !important;
	left: 0 !important;
	width: 100% !important;
	height: 100% !important;
	min-height: 0 !important;
}

body.voting-contest .wpvc_contestantimage:empty {
	width: auto !important;
}

/* Actions footer */
body.voting-contest .MuiCardActions-root {
	margin-top: auto;
	padding: 10px 14px !important;
	border-top: 1px solid #eef1f4;
}

body.voting-contest .wpvc_allcontest_action .wpvc_vote_cast_btn,
body.voting-contest .wpvc_allcontest_action > div {
	display: flex;
	align-items: center;
}

body.voting-contest .wpvc_allcontest_action .MuiIconButton-root {
	width: 32px !important;
	height: 32px !important;
	min-width: 32px !important;
	border-radius: 50% !important;
}

body.voting-contest .wpvc_allcontest_action .MuiSvgIcon-root {
	font-size: 17px !important;
}

body.voting-contest .wpvc_card_allcontest_actions {
	display: flex;
	justify-content: flex-end;
	gap: 12px;
}

body.voting-contest .wpvc_card_show_actions_single {
	display: inline-flex !important;
	align-items: center;
	gap: 3px;
	color: #6a7681;
	font-family: Montserrat, sans-serif;
	font-size: 13px !important;
}

body.voting-contest .wpvc_card_show_actions_single svg {
	font-size: 17px !important;
	color: #9aa5ae;
}

@media (max-width: 899px) {
	body.voting-contest .wpvc_label_grid {
		padding: 6px 8px !important;
	}
}

/* ---------------------------------------------------------------------
   3. Follow-up fixes (2026-09-24) — card action row order, embed video
   sizing, navigation bar cleanup, card header background/link color.
   Selectors below are pasted as supplied (some target MUI-generated
   classes directly, unscoped) rather than reworked to the
   body.voting-contest convention above, to match what was verified.
   --------------------------------------------------------------------- */

.wpvc_contestantimage { order: 1; }
.MuiCardHeader-root.wpvc_card_show_header { order: 2; }
.MuiCardActions-root { order: 3; }

p.MuiTypography-root.MuiTypography-body1.wpvc_card_show_actions_single {
	margin-bottom: 0;
}
#embed-video-container div[data-testid="embed-video"] {
	max-width: unset !important;
}
.wpvc_video_contest_player {
	background: #000;
}
.MuiGrid2-root.MuiGrid2-container.MuiGrid2-direction-xs-row.wpvc_allcontest_action {
	column-gap: 5px !important;
}
.MuiGrid2-root.MuiGrid2-direction-xs-row.MuiGrid2-grid-xs-4 {
	width: auto;
}
.MuiGrid2-root.MuiGrid2-direction-xs-row.MuiGrid2-grid-xs-4.wpvc_card_allcontest_actions p.MuiTypography-root.MuiTypography-body1.wpvc_card_show_actions_single:first-child {
	display: none !important;
}
.MuiGrid2-root.MuiGrid2-container.MuiGrid2-direction-xs-row.MuiGrid2-grid-xs-12 {
	display: flex;
	justify-content: start;
	padding: 0;
}
body.voting-contest .wpvc_card_show_actions_single svg {
	color: #ec2e3d;
}
body.voting-contest .wpvc_card_show_actions_single span {
	color: #000;
}
.MuiFormControl-root.MuiTextField-root.wpvc_text_navigation {
	background: transparent;
}
button.MuiButtonBase-root.MuiIconButton-root.MuiIconButton-sizeMedium {
	height: 38px;
	width: 38px;
}
body.voting-contest .wpvc_allcontest_search {
	margin: 0;
}
.MuiInputBase-root.MuiOutlinedInput-root.MuiInputBase-colorPrimary.MuiInputBase-formControl.MuiInputBase-adornedEnd {
	padding-right: 4px;
}
svg.MuiSvgIcon-root.MuiSvgIcon-fontSizeMedium {
	font-size: 22px !important;
}
body.voting-contest .wpvc_card_show_header {
	background: #f7f4f0;
}
body.voting-contest .wpvc_card_show_header .MuiCardHeader-title a {
	color: #9b8576 !important;
}
span.MuiButton-icon.MuiButton-startIcon.MuiButton-iconSizeSmall.css-1qfx30c {
	display: none;
}
.MuiGrid2-root.MuiGrid2-container.MuiGrid2-direction-xs-row.wpvc_grid_list.css-evk864 {
	display: none;
}
a.MuiButtonBase-root.MuiButton-root.MuiButton-text.MuiButton-textPrimary.MuiButton-sizeSmall.MuiButton-textSizeSmall.MuiButton-colorPrimary.MuiButton-root.MuiButton-text.MuiButton-textPrimary.MuiButton-sizeSmall.MuiButton-textSizeSmall.MuiButton-colorPrimary.wpvc_navigation.css-rulspo {
	background: #e52728;
	padding: 17px 38px !important;
	line-height: 1 !important;
	border-radius: 50px;
}
a.MuiButtonBase-root.MuiButton-root span {
	text-transform: uppercase;
	font-weight: 600;
	font-family: Montserrat;
	font-size: 16px;
	line-height: 1 !important;
}

body.voting-contest .wpvc_text_navigation .MuiOutlinedInput-input {
	border: none;
}
header.MuiPaper-root.MuiPaper-elevation.MuiPaper-elevation4.MuiAppBar-root.MuiAppBar-colorPrimary.MuiAppBar-positionStatic.wpvc_app_bar.css-1fmwl5v {
	height: auto !important;
	min-height: unset !important;
}
div#wpvc-addcontest-page {
	min-height: unset;
}
div#wpvc_navigation_bar_null {
	margin-bottom: 0 !important;
}

/* TikTok cards: the plugin wraps TikTok's iframe in .wpvc_tiktok_parent_div
   with text-align:center and no width override, so (unlike the other embed
   types, which the .wpvc_card_video_media_row iframe rule above already
   stretches) the iframe just renders at its native width and sits centered
   instead of filling the card. */
body.voting-contest .wpvc_tiktok_parent_div {
	width: 100%;
}
body.voting-contest .wpvc_tiktok_parent_div iframe.tiktok_video {
	width: 100% !important;
	max-width: 100% !important;
}

/* ---------------------------------------------------------------------
   4. Vimeo cards: unlike the other embed types, a Vimeo iframe embeds the
   actual player (not a cover-fit static preview), and the video element
   inside it keeps its native 16:9 aspect ratio letterboxed within our
   1.43:1 card box - black bars top and bottom. That element is inside a
   cross-origin iframe, so it can't be reached directly; scaling the whole
   iframe up and clipping it against the card's own overflow:hidden pushes
   the bars outside the visible area, leaving just the video, cropped
   left/right like every other card. Scoped to Vimeo specifically so the
   YouTube/Instagram/Facebook/TikTok cards, which already fill the box
   correctly, are untouched.
   --------------------------------------------------------------------- */
body.voting-contest .wpvc_video_contest_player iframe[src*="vimeo.com"] {
	transform: scale(1.25);
	transform-origin: center center;
}

/* ---------------------------------------------------------------------
   5. Follow-up fixes (2026-09-25) - "Cast Your Vote" h5 heading, nav bar
   cleanup, join/submission form restyle, last-row grid gap.
   --------------------------------------------------------------------- */

.voting-contest-row h5.join-contest-heading,
h5.MuiTypography-root.MuiTypography-h5.wpvc_grid_header.css-elr2b6 {
	box-shadow: 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12);
	text-shadow: 1px 1px 6px rgba(0, 0, 0, 0.35);
	font-family: playfair-display, serif;
	margin-bottom: 16px !important;
	padding: 14px 0 18px 0;
	border-radius: 11px;
	background: #9b8576;
	text-align: center;
	font-weight: 600;
	font-size: 32px;
	line-height: 1;
	color: #f7f4f0;
	width: 100%;
}
body.voting-contest div#wpvc_navigation_bar_null .wpvc_app_bar {
	background: unset !important;
	box-shadow: unset !important;
}
body.voting-contest div#wpvc_navigation_bar_null .wpvc_app_bar .MuiToolbar-root {
	padding: 0 !important;
}
#join-wrapper .MuiGrid2-root.MuiGrid2-container.MuiGrid2-direction-xs-row.MuiGrid2-grid-xs-12 > div {
	width: 100%
}
#join-wrapper form#add_contestant {
	margin-top: 18px;
}
#join-wrapper form div.wpvc_submit_form {
	box-shadow: 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12);
	background: #01aac7 !important;
	border: none !important;
	border-radius: 12px;
}
#join-wrapper form div.wpvc_submit_form input,
#join-wrapper form div.wpvc_submit_form select,
#join-wrapper form div.wpvc_submit_form div#mui-component-select-all_category_drop {
	padding-left: 24px !important;
	background: #FFF !important;
	border-radius: 50px;
	color: #000;
}
#join-wrapper form div.wpvc_submit_form label[data-shrink="false"] {
	margin-bottom: 0 !important;
	font-size: 14px !important;
	padding-left: 18px;
	margin-top: 3px;
	color: #848484;
	z-index: 1;
}
#join-wrapper form div.wpvc_submit_form label[data-shrink="true"] {
	margin-bottom: 0 !important;
	font-size: 14px !important;
	padding-left: 0;
	margin-top: -3px;
	color: #000;
	z-index: 1;
}
input#null_contestant-image {
	padding-left: 0 !important;
}
#join-wrapper form div.wpvc_submit_form .MuiInputBase-root.MuiInput-root.MuiInput-underline:before {
	border-color: #FFF;
	border: none;
}
/* :after is a separate MUI pseudo-element that only appears once the
   field is focused (.Mui-focused) - defaults to a bright blue
   (rgb(25,118,210)), which is the underline the user found. The
   :before rule above (border-color + border shorthand right after it)
   doesn't fully work here - the shorthand resets color back to
   default regardless of the color declared just before it - so this
   one goes straight for `border: none !important` instead. */
.MuiInputBase-root.MuiInput-root.MuiInput-underline.MuiInputBase-colorPrimary.MuiInputBase-formControl:after {
	border: none !important;
}
#join-wrapper form div.wpvc_submit_form button.wpvc_save_contestant_btn {
	background: #FFF !important;
	color: #000 !important;
}
.MuiInputBase-root input.MuiInput-input {
	height: 36px;
	padding: 0 !important;
}

/* ---------------------------------------------------------------------
   6. Single-contestant page (2026-09-25): this stylesheet now also loads
   there (see vds_enqueue_voting_contest_styles in enqueue.php) so future
   single-page-only rules can just go in this file.
   --------------------------------------------------------------------- */
.wpvc_single_contestants_page {
	margin-top: 120px;
}
/* The contestant's own name heading on the single page shares the exact
   same classes (including the volatile MUI css-elr2b6 hash) as the
   "Cast Your Vote!" / "Join the Contest!" page headings styled above -
   same component, reused. Scoped under .wpvc_single_contestants_page so
   only this page's instance changes; the grid page's headings (under
   body.voting-contest, a different template) are untouched. Color/font-
   size need !important because the plugin sets both inline per-instance
   (style="font-size:16px;color:rgb(0,0,0)"), which otherwise beats any
   external rule regardless of specificity. */
.wpvc_single_contestants_page h5.MuiTypography-root.MuiTypography-h5.wpvc_grid_header.css-elr2b6 {
	color: #fff !important;
	font-size: 28px !important;
}
.wpvc_single_contestants_page h5.wpvc_grid_header a {
	pointer-events: none;
	color: #fff !important;
	text-decoration: none;
}
.MuiCardActions-root .MuiGrid2-root.MuiGrid2-container.MuiGrid2-direction-xs-row.MuiGrid2-grid-xs-12 {
	justify-content: space-between;
}
#join-wrapper form div.wpvc_submit_form select,
#join-wrapper form div.wpvc_submit_form div#mui-component-select-all_category_drop {
	padding-top: 6.5px !important;
	padding-bottom: 6.5px !important;
}
/* Same gradient/border-radius as the grid page's .wpvc_app_bar bars
   (body.voting-contest .wpvc_app_bar, section 1 above) - single page
   has its own single .wpvc_app_bar (the Gallery/Category bar), not
   covered by that rule since this page doesn't carry body.voting-contest. */
.wpvc_single_contestants_page header.wpvc_app_bar {
	background: linear-gradient(135deg, #00b8d6, #036777) !important;
	border-radius: 10px !important;
}
.wpvc_single_contestants_page p.wpvc_single_top_category {
	display: none;
}
.wpvc_show_style_row .wpvc_card_row {
	height: 100%;
	display: flex;
	flex-direction: column-reverse;
	justify-content: space-between;
}
body.single-contestants a.MuiTypography-root.MuiTypography-inherit.MuiLink-root.MuiLink-underlineAlways.wpvc_single_prev_button, body.single-contestants a.MuiTypography-root.MuiTypography-inherit.MuiLink-root.MuiLink-underlineAlways.wpvc_single_next_button {
	display: flex;
	align-items: center;
}
body.single-contestants p.MuiTypography-root.MuiTypography-body1.wpvc_card_sub_header.css-fyswvn {
	display: none;
}
body.single-contestants h5.MuiTypography-root.MuiTypography-h5.wpvc_grid_header.css-elr2b6 {
	margin-bottom: 0 !important;
}
body.single-contestants #content a.MuiTypography-root.MuiTypography-inherit.MuiLink-root.MuiLink-underlineAlways.wpvc_share_social_single.css-8zz4wg {
	color: #FFF !important;
}
body.single-contestants #content a.MuiTypography-root.MuiTypography-inherit.MuiLink-root.MuiLink-underlineAlways.wpvc_share_social_single.css-8zz4wg:hover {
	color: #FFF !important;
	opacity: 0.75;
}
body.single-contestants p.MuiTypography-root.MuiTypography-body1.wpvc_card_actions_single.css-fyswvn {
	color: #e52728;
}
body.single-contestants p.MuiTypography-root.MuiTypography-body1.wpvc_card_actions_single.css-fyswvn span {
	color: #000;
}
body.single-contestants .MuiGrid2-root.MuiGrid2-direction-xs-row.css-1n5khr6 p.MuiTypography-root.MuiTypography-body1.wpvc_card_actions_single.css-fyswvn:nth-child(2) {
	display: none !important;
}
body.single-contestants .MuiGrid2-root.MuiGrid2-direction-xs-row.MuiGrid2-grid-xs-12.wpvc_vote_cast_single_btn.css-j5005a {
	margin-bottom: 0;
	margin-top: 12px;
}
body.single-contestants .MuiPaper-root.MuiPaper-elevation.MuiPaper-rounded.MuiPaper-elevation1.MuiCard-root.wpvc_card_row.css-q8lpi9 {
	background: #f7f4f0;
}
small.important-note {
	font-family: Montserrat, sans-serif;
	font-weight: 600;
	font-size: 14px;
	text-transform: uppercase;
}
