/*
Theme Name: SWD Media Theme
Theme URI: https://swd.media
Author: SWD Media Limited
Author URI: https://swd.media
Description: Video licensing portal theme for SWD Media.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: swd-media
*/

/* ==========================================================================
   1. Theme Variables & Base Layout
   ========================================================================== */
:root {
	--swd-blue: #56c2f5;
	--swd-blue-hover: #2ba6df;
	--swd-blue-soft: rgba(86, 194, 245, 0.14);
	--swd-cream: #f3efe2;
	--swd-black: #0b0d0e;

	--bg-main: #0b0d0e;
	--bg-card: #12171b;
	--bg-surface: #161d23;
	--bg-hover: #192229;
	--bg-header: rgba(11, 13, 14, 0.94);
	--text-primary: #f3efe2;
	--text-secondary: #9fb3c2;
	--border: rgba(86, 194, 245, 0.22);
	--accent: #56c2f5;
}

html.light-theme,
html[data-theme="light"] {
	--bg-main: #f7fafc;
	--bg-card: #ffffff;
	--bg-surface: #f8fafc;
	--bg-hover: #f1f5f9;
	--bg-header: rgba(255, 255, 255, 0.96);
	--text-primary: #0b0d0e;
	--text-secondary: #475569;
	--border: rgba(43, 166, 223, 0.28);
	--accent: #2ba6df;
}

body {
	background-color: var(--bg-main);
	color: var(--text-primary);
	margin: 0;
}

/* ==========================================================================
   2. Site Header & Navigation
   ========================================================================== */
.swd-site-header {
	position: sticky;
	top: 0;
	z-index: 100;
	background: var(--bg-header);
	border-bottom: 1px solid var(--border);
	backdrop-filter: blur(8px);
}

.swd-header-inner {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0.75rem 1rem;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.25rem;
}

.swd-brand-link {
	display: inline-flex;
	align-items: center;
	gap: 0.75rem;
	text-decoration: none;
	color: var(--text-primary);
}

.swd-brand-logo {
	width: 44px;
	height: 44px;
	border-radius: 50%;
	display: block;
	object-fit: cover;
	border: 2px solid var(--accent);
}

.swd-brand-text {
	display: flex;
	flex-direction: column;
	line-height: 1.15;
}

.swd-brand-name {
	font-size: 1.05rem;
	font-weight: 800;
	letter-spacing: 0.02em;
	color: var(--text-primary);
}

.swd-brand-tagline {
	font-size: 0.75rem;
	color: var(--accent);
	font-weight: 600;
}

.swd-nav-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	align-items: center;
	gap: 1rem;
}

.swd-nav-list a {
	color: var(--text-primary);
	text-decoration: none;
	font-size: 0.92rem;
	font-weight: 600;
	padding: 0.35rem 0.6rem;
	border-radius: 6px;
	transition: background-color 0.15s ease, color 0.15s ease;
}

.swd-nav-list a:hover,
.swd-nav-list .current-menu-item a {
	background: var(--swd-blue-soft);
	color: var(--accent);
}

.swd-header-actions {
	display: flex;
	align-items: center;
	gap: 0.65rem;
}

.swd-theme-btn {
	background: transparent;
	color: var(--text-primary);
	border: 1px solid var(--border);
	padding: 0.48rem 0.75rem;
	border-radius: 6px;
	font-size: 0.85rem;
	font-weight: 600;
	cursor: pointer;
}

.swd-theme-btn:hover {
	border-color: var(--accent);
	color: var(--accent);
}

.swd-header-cta {
	background: var(--accent);
	color: #0b0d0e;
	padding: 0.52rem 0.95rem;
	border-radius: 6px;
	font-size: 0.88rem;
	font-weight: 700;
	text-decoration: none;
	transition: background-color 0.15s ease;
}

.swd-header-cta:hover {
	background: var(--swd-blue-hover);
	color: #ffffff;
}

@media (max-width: 768px) {
	.swd-primary-nav {
		display: none;
	}
	.swd-brand-tagline {
		display: none;
	}
}

/* ==========================================================================
   3. Hero & Unlock Panels
   ========================================================================== */
.swd-front-wrap .swd-hero-banner,
.swd-hero-banner {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	width: 100%;
	max-width: 100% !important;
	margin-left: auto;
	margin-right: auto;
	padding-left: 1rem;
	padding-right: 1rem;
	box-sizing: border-box;
	background-color: var(--bg-main) !important;
}

.swd-front-wrap,
.swd-front-wrap .swd-hero-banner,
.swd-hero-banner > * {
	background-color: transparent !important;
	background-image: none !important;
	box-shadow: none !important;
	border-radius: 0 !important;
}

.swd-hero-banner .swd-hero-title,
.swd-hero-banner .swd-hero-copy,
.swd-hero-banner p,
.swd-hero-banner h1,
.swd-hero-banner h2 {
	margin-left: auto;
	margin-right: auto;
	text-align: center;
}

.swd-hero-banner .swd-hero-copy,
.swd-hero-banner p {
	max-width: 68ch;
}

#swdPublisherUnlockPanel[hidden] {
	display: none !important;
}

/* ==========================================================================
   4. Complianz Privacy & Cookie Styling
   ========================================================================== */
#cmplz-document,
#cmplz-document p,
#cmplz-document span,
#cmplz-document li,
#cmplz-cookies-overview,
#cmplz-cookies-overview p,
#cmplz-cookies-overview span,
#cmplz-cookies-overview li {
	color: var(--text-primary);
}

#cmplz-document a,
#cmplz-cookies-overview a {
	color: var(--accent);
}

#cmplz-document a:visited,
#cmplz-cookies-overview a:visited {
	color: #9ad8f7;
}

#cmplz-cookies-overview .cmplz-dropdown,
#cmplz-document .cmplz-dropdown {
	background-color: var(--bg-card);
	border-color: var(--border);
}

#cmplz-cookies-overview .cmplz-dropdown summary,
#cmplz-document .cmplz-dropdown summary {
	background-color: var(--bg-surface);
	color: var(--text-primary);
	font-weight: 600;
}

#cmplz-cookies-overview .cmplz-dropdown summary p,
#cmplz-document .cmplz-dropdown summary p,
#cmplz-cookies-overview .cmplz-dropdown summary span,
#cmplz-document .cmplz-dropdown summary span {
	color: var(--text-primary);
	font-weight: 600;
}

#cmplz-cookies-overview .cmplz-dropdown .cookies-per-purpose,
#cmplz-document .cmplz-dropdown .cookies-per-purpose,
#cmplz-cookies-overview .cmplz-dropdown .cookies-per-purpose div,
#cmplz-document .cmplz-dropdown .cookies-per-purpose div {
	background-color: var(--bg-card) !important;
	color: var(--text-primary) !important;
}

#cmplz-document table,
#cmplz-cookies-overview table,
#cmplz-document thead,
#cmplz-cookies-overview thead,
#cmplz-document tbody,
#cmplz-cookies-overview tbody,
#cmplz-document tr,
#cmplz-cookies-overview tr,
#cmplz-document th,
#cmplz-cookies-overview th,
#cmplz-document td,
#cmplz-cookies-overview td {
	background-color: var(--bg-card);
	color: var(--text-primary);
	border-color: var(--border);
}

#cmplz-document th,
#cmplz-cookies-overview th {
	background-color: #182026;
	color: var(--accent);
	font-weight: 700;
}

#cmplz-document tbody tr:nth-child(even) td,
#cmplz-cookies-overview tbody tr:nth-child(even) td {
	background-color: var(--bg-surface);
}

#cmplz-manage-consent-container .cmplz-categories .cmplz-category,
#cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header {
	background-color: var(--bg-card) !important;
	border-color: var(--border) !important;
}

#cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header .cmplz-always-active {
	background-color: #182026 !important;
	color: var(--text-primary) !important;
	border-color: var(--border) !important;
}

#cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-description {
	padding: 10px;
	background: var(--bg-card);
	color: var(--text-primary);
}

#cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header .cmplz-category-title,
#cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header button,
#cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header span:not(.cmplz-always-active),
#cmplz-manage-consent-container .cmplz-category-title {
	color: var(--accent) !important;
	font-weight: 700 !important;
}

html:not(.light-theme) #cmplz-cookies-overview .cmplz-dropdown summary::marker,
html:not(.light-theme) #cmplz-document .cmplz-dropdown summary::marker,
html:not(.light-theme) #cmplz-cookies-overview .cmplz-dropdown summary::before,
html:not(.light-theme) #cmplz-document .cmplz-dropdown summary::before,
html:not(.light-theme) #cmplz-cookies-overview .cmplz-dropdown summary::after,
html:not(.light-theme) #cmplz-document .cmplz-dropdown summary::after,
html:not(.light-theme) #cmplz-manage-consent-container .cmplz-category-header::before,
html:not(.light-theme) #cmplz-manage-consent-container .cmplz-category-header::after,
html:not(.light-theme) #cmplz-manage-consent-container .cmplz-category-header button::before,
html:not(.light-theme) #cmplz-manage-consent-container .cmplz-category-header button::after {
	content: none !important;
	display: none !important;
	background-image: none !important;
}

html:not(.light-theme) #cmplz-cookies-overview .cmplz-dropdown summary::-webkit-details-marker,
html:not(.light-theme) #cmplz-document .cmplz-dropdown summary::-webkit-details-marker {
	display: none !important;
}

html:not(.light-theme) #cmplz-cookies-overview .cmplz-dropdown .cmplz-icon,
html:not(.light-theme) #cmplz-document .cmplz-dropdown .cmplz-icon,
html:not(.light-theme) #cmplz-cookies-overview .cmplz-dropdown [class*="arrow"],
html:not(.light-theme) #cmplz-document .cmplz-dropdown [class*="arrow"],
html:not(.light-theme) #cmplz-cookies-overview .cmplz-dropdown [class*="chevron"],
html:not(.light-theme) #cmplz-document .cmplz-dropdown [class*="chevron"],
html:not(.light-theme) #cmplz-manage-consent-container .cmplz-category-header .cmplz-icon,
html:not(.light-theme) #cmplz-manage-consent-container .cmplz-category-header [class*="arrow"],
html:not(.light-theme) #cmplz-manage-consent-container .cmplz-category-header [class*="chevron"] {
	display: none !important;
}

html:not(.light-theme) #cmplz-cookies-overview .cmplz-dropdown summary,
html:not(.light-theme) #cmplz-document .cmplz-dropdown summary,
html:not(.light-theme) #cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header {
	background-color: var(--bg-surface) !important;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
	background-repeat: no-repeat !important;
	background-position: right 1rem center !important;
	background-size: 16px 16px !important;
}

html.light-theme #cmplz-document .cmplz-dropdown summary,
html.light-theme #cmplz-cookies-overview .cmplz-dropdown summary,
html.light-theme #cmplz-document th,
html.light-theme #cmplz-cookies-overview th,
html.light-theme #cmplz-document tbody tr:nth-child(even) td,
html.light-theme #cmplz-cookies-overview tbody tr:nth-child(even) td {
	background-color: #f1f5f9;
	color: #0b0d0e;
}

html.light-theme #cmplz-document .cmplz-dropdown .cookies-per-purpose,
html.light-theme #cmplz-cookies-overview .cmplz-dropdown .cookies-per-purpose,
html.light-theme #cmplz-document .cmplz-dropdown .cookies-per-purpose div,
html.light-theme #cmplz-cookies-overview .cmplz-dropdown .cookies-per-purpose div,
html.light-theme #cmplz-document td,
html.light-theme #cmplz-cookies-overview td {
	background-color: #ffffff !important;
	color: #0b0d0e !important;
}

html.light-theme #cmplz-manage-consent-container .cmplz-categories .cmplz-category,
html.light-theme #cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header {
	background-color: #ffffff !important;
	border-color: rgba(43, 166, 223, 0.28) !important;
}

html.light-theme #cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header .cmplz-category-title,
html.light-theme #cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header button {
	color: #0b0d0e !important;
}

html.light-theme #cmplz-cookies-overview .cmplz-dropdown summary,
html.light-theme #cmplz-document .cmplz-dropdown summary,
html.light-theme #cmplz-manage-consent-container .cmplz-categories .cmplz-category .cmplz-category-header {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230b0d0e' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
	background-repeat: no-repeat !important;
	background-position: right 1rem center !important;
	background-size: 16px 16px !important;
}

/* ==========================================================================
   6. Video Player & WP Cloud Plugins / OneDrive Styling
   ========================================================================== */
#ShareoneDrive .wpcp26__about-title,
#ShareoneDrive .wpcp26__about {
	display: none !important;
}

.swd-protected-player {
	position: relative;
	overflow: hidden;
}

.wpcp-upload-box p,
.wpcp-upload-box span,
.wpcp-upload-box div,
[class*="wpcp"] .wpcp-upload-area p,
[class*="wpcp"] .wpcp-upload-area span,
[class*="wpcp"] .wpcp-upload-area div {
	color: var(--text-primary) !important;
}

.wpcp-upload-box a,
[class*="wpcp"] .wpcp-upload-area a {
	color: var(--accent) !important;
}

.wpcp-upload-box a:hover,
[class*="wpcp"] .wpcp-upload-area a:hover {
	color: #8ad6fa !important;
}

.fileupload-header,
.fileupload-header-title,
.fileupload-header-button,
.fileupload-empty,
.fileupload-not-empty,
.fileupload-header-text-title,
.fileupload-header-text-subtitle {
	background-color: transparent !important;
	background: transparent !important;
	color: var(--text-primary) !important;
}

.fileupload-header {
	background-color: var(--bg-surface) !important;
	background: var(--bg-surface) !important;
	color: var(--text-primary) !important;
}

.fileupload-header-text-subtitle a {
	color: var(--accent) !important;
}

.wpcp-icon.wpcp-icon-list-bullet::before,
.fileupload-requirements-button .wpcp-icon-list-bullet::before {
	content: "☰" !important;
	font-family: system-ui, -apple-system, sans-serif !important;
	font-size: 15px !important;
	line-height: 1 !important;
	color: var(--accent) !important;
}

.wpcp-icon.wpcp-icon-plus::before,
.fileupload-add-button .wpcp-icon-plus::before {
	content: "+" !important;
	font-family: system-ui, -apple-system, sans-serif !important;
	font-size: 18px !important;
	line-height: 1 !important;
	color: var(--accent) !important;
}

.wpcp-icon.wpcp-icon-list-bullet:hover,
.wpcp-icon.wpcp-icon-plus:hover {
	background-color: rgba(86, 194, 245, 0.16) !important;
	border-color: var(--accent) !important;
}

@media (max-width: 768px) {
	/* Narrower, snugger outer box for the Contributor card on mobile */
	body.single .swd-info-row > *:nth-child(2),
	body.single .swd-contributor-card,
	body.single .swd-contributor-box,
	body.single .swd-contributor-wrap {
		display: flex !important;
		flex-direction: column !important;
		align-items: center !important;
		justify-content: center !important;
		text-align: center !important;
		width: fit-content !important;
		min-width: 175px !important;
		max-width: 100% !important;
		margin-left: auto !important;
		margin-right: auto !important;
		padding: 0.55rem 0.9rem !important;
		min-height: 0 !important;
		gap: 0.28rem !important;
	}

	body.single .swd-info-row > *:nth-child(2) *,
	body.single .swd-contributor-card *,
	body.single .swd-contributor-box *,
	body.single .swd-contributor-wrap * {
		text-align: center !important;
		margin-top: 0 !important;
		margin-bottom: 0 !important;
		margin-left: auto !important;
		margin-right: auto !important;
	}
}


/* Moved to assets/css/ and loaded only where needed (see swd_enqueue_template_css in functions.php):
   - forms.css                 (was section 5: Gravity Forms)
   - account-videos.css        (was part of section 6: account video module)
   - norfolk-dash-cam.css      (was section 7: Norfolk Dash Cam layout) */
