/**
 * Custom Styles for OPA Bahá'í India Theme
 *
 * @package OPA_Bahai_India
 */

/* Root Variables */
:root {
	--opa-transition: all 0.3s ease;
	--opa-shadow-subtle: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
	--opa-shadow-medium: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
	--opa-shadow-large: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* Base Styles */
html {
	scroll-behavior: smooth;
}

body {
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

/* Skip Link */
.skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 999999;
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--white);
	padding: 1rem 2rem;
	text-decoration: none;
}

.skip-link:focus {
	left: 50%;
	transform: translateX(-50%);
}

/* Header Styles */
.site-header {
	position: relative;
	z-index: 100;
	box-shadow: var(--opa-shadow-subtle);
}

.site-header.is-sticky {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	animation: slideDown 0.3s ease;
}

@keyframes slideDown {
	from {
		transform: translateY(-100%);
	}
	to {
		transform: translateY(0);
	}
}

/* Navigation Styles */
.wp-block-navigation {
	gap: 2rem;
}

.wp-block-navigation-item a {
	position: relative;
	transition: var(--opa-transition);
}

.wp-block-navigation-item a::after {
	content: '';
	position: absolute;
	bottom: -4px;
	left: 0;
	width: 0;
	height: 2px;
	background: var(--wp--preset--color--secondary);
	transition: width 0.3s ease;
}

.wp-block-navigation-item a:hover::after {
	width: 100%;
}

/* Button Styles */
.wp-block-button__link {
	transition: var(--opa-transition);
}

.wp-block-button__link:hover {
	transform: translateY(-2px);
	box-shadow: var(--opa-shadow-medium);
}

/* Outline Button Style */
.is-style-outline .wp-block-button__link {
	border: 2px solid currentColor;
}

.is-style-outline .wp-block-button__link:hover {
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--white);
}

/* Custom Button Styles */
.is-style-opa-outline .wp-block-button__link {
	background: transparent;
	border: 2px solid var(--wp--preset--color--primary);
	color: var(--wp--preset--color--primary);
}

.is-style-opa-outline .wp-block-button__link:hover {
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--white);
}

.is-style-opa-rounded .wp-block-button__link {
	border-radius: 50px;
}

.is-style-opa-shadow .wp-block-button__link {
	box-shadow: var(--opa-shadow-medium);
}

/* Image Styles */
.is-style-opa-rounded img {
	border-radius: 16px;
}

.is-style-opa-shadow img {
	box-shadow: var(--opa-shadow-large);
}

.is-style-opa-border img {
	border: 4px solid var(--wp--preset--color--gray);
}

/* Group/Card Styles */
.is-style-opa-card {
	background: var(--wp--preset--color--white);
	border-radius: 16px;
	padding: var(--wp--preset--spacing--50);
	box-shadow: var(--opa-shadow-medium);
}

.is-style-opa-bordered {
	border: 2px solid var(--wp--preset--color--gray);
	border-radius: 16px;
}

.is-style-opa-shadow {
	box-shadow: var(--opa-shadow-medium);
	transition: var(--opa-transition);
}

.is-style-opa-shadow:hover {
	box-shadow: var(--opa-shadow-large);
	transform: translateY(-4px);
}

/* Separator Styles */
.is-style-opa-dotted hr {
	border-style: dotted;
}

.is-style-opa-thick hr {
	border-width: 3px;
}

/* Quote Styles */
.is-style-opa-large {
	font-size: 1.5rem;
}

.is-style-opa-plain {
	border: none;
	padding: 0;
}

/* List Styles */
.is-style-opa-checkmark li::marker {
	content: '✓ ';
	color: var(--wp--preset--color--secondary);
}

.is-style-opa-no-bullets {
	list-style: none;
	padding-left: 0;
}

/* Post Template Card Style */
.is-style-opa-cards > li {
	background: var(--wp--preset--color--white);
	border-radius: 16px;
	padding: var(--wp--preset--spacing--40);
	box-shadow: var(--opa-shadow-subtle);
	transition: var(--opa-transition);
}

.is-style-opa-cards > li:hover {
	box-shadow: var(--opa-shadow-medium);
	transform: translateY(-4px);
}

/* Navigation Pills Style */
.is-style-opa-pills .wp-block-navigation-item a {
	background: var(--wp--preset--color--light-gray);
	border-radius: 50px;
	padding: 0.5rem 1rem;
}

.is-style-opa-pills .wp-block-navigation-item a:hover {
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--white);
}

.is-style-opa-pills .wp-block-navigation-item a::after {
	display: none;
}

/* Large Gap Columns */
.is-style-opa-gap-large {
	gap: var(--wp--preset--spacing--70) !important;
}

/* Cover Gradient Overlay */
.is-style-opa-gradient-overlay .wp-block-cover__background {
	background: linear-gradient(135deg, rgba(26, 54, 93, 0.8) 0%, rgba(45, 80, 22, 0.6) 100%) !important;
}

/* Heading Styles */
.is-style-opa-underlined {
	display: inline-block;
	border-bottom: 3px solid var(--wp--preset--color--accent);
	padding-bottom: 0.5rem;
}

.is-style-opa-decorated {
	position: relative;
	padding-left: 2rem;
}

.is-style-opa-decorated::before {
	content: '';
	position: absolute;
	left: 0;
	top: 0.25em;
	width: 1rem;
	height: 3px;
	background: var(--wp--preset--color--accent);
}

/* Paragraph Styles */
.is-style-opa-lead {
	font-size: 1.25rem;
	line-height: 1.6;
	color: var(--wp--preset--color--medium-gray);
}

.is-style-opa-dropcap::first-letter {
	float: left;
	font-size: 4rem;
	line-height: 1;
	margin-right: 0.5rem;
	color: var(--wp--preset--color--primary);
	font-weight: 700;
}

/* Post Meta Styles */
.post-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
	font-size: 0.875rem;
	color: var(--wp--preset--color--medium-gray);
}

.post-meta span {
	display: flex;
	align-items: center;
	gap: 0.5rem;
}

.post-meta a {
	color: inherit;
	text-decoration: none;
}

.post-meta a:hover {
	color: var(--wp--preset--color--primary);
}

/* Author Box */
.author-box {
	display: flex;
	gap: 1.5rem;
	padding: var(--wp--preset--spacing--50);
	background: var(--wp--preset--color--light-gray);
	border-radius: 16px;
	margin-top: var(--wp--preset--spacing--60);
}

.author-avatar img {
	border-radius: 50%;
}

.author-name {
	margin: 0 0 0.5rem;
}

.author-bio {
	margin-bottom: 1rem;
}

.author-posts-link {
	font-size: 0.875rem;
	font-weight: 600;
}

/* Related Posts */
.related-posts {
	margin-top: var(--wp--preset--spacing--70);
}

.related-posts-title {
	margin-bottom: var(--wp--preset--spacing--50);
}

.related-posts-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: var(--wp--preset--spacing--50);
}

.related-post {
	background: var(--wp--preset--color--white);
	border-radius: 12px;
	overflow: hidden;
	box-shadow: var(--opa-shadow-subtle);
	transition: var(--opa-transition);
}

.related-post:hover {
	box-shadow: var(--opa-shadow-medium);
	transform: translateY(-4px);
}

.related-post-thumbnail img {
	width: 100%;
	height: 150px;
	object-fit: cover;
}

.related-post-title {
	padding: 1rem;
	margin: 0;
}

.related-post-date {
	display: block;
	padding: 0 1rem 1rem;
	font-size: 0.75rem;
	color: var(--wp--preset--color--medium-gray);
}

/* Social Share */
.social-share {
	display: flex;
	align-items: center;
	gap: 1rem;
	margin-top: var(--wp--preset--spacing--50);
}

.share-label {
	font-weight: 600;
}

.share-link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	background: var(--wp--preset--color--light-gray);
	border-radius: 50%;
	color: var(--wp--preset--color--dark-gray);
	transition: var(--opa-transition);
}

.share-link:hover {
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--white);
}

/* Post Navigation */
.post-navigation {
	display: flex;
	justify-content: space-between;
	gap: 2rem;
	margin-top: var(--wp--preset--spacing--60);
	padding-top: var(--wp--preset--spacing--50);
	border-top: 1px solid var(--wp--preset--color--gray);
}

.post-navigation a {
	display: block;
	text-decoration: none;
	max-width: 45%;
}

.nav-label {
	display: block;
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: var(--wp--preset--color--medium-gray);
	margin-bottom: 0.25rem;
}

.nav-title {
	font-weight: 600;
	color: var(--wp--preset--color--primary);
}

.nav-next {
	text-align: right;
}

/* Social Links */
.social-links {
	display: flex;
	gap: 1rem;
}

.social-link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	transition: var(--opa-transition);
}

.social-link:hover {
	transform: scale(1.1);
}

/* Breadcrumbs */
.breadcrumbs {
	font-size: 0.875rem;
	margin-bottom: var(--wp--preset--spacing--50);
}

.breadcrumbs a {
	color: var(--wp--preset--color--medium-gray);
	text-decoration: none;
}

.breadcrumbs a:hover {
	color: var(--wp--preset--color--primary);
}

.breadcrumb-separator {
	margin: 0 0.5rem;
	color: var(--wp--preset--color--gray);
}

/* Pagination */
.wp-block-query-pagination {
	gap: 0.5rem;
}

.wp-block-query-pagination-numbers a,
.wp-block-query-pagination-numbers span {
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 0.75rem;
	background: var(--wp--preset--color--light-gray);
	border-radius: 8px;
	text-decoration: none;
	transition: var(--opa-transition);
}

.wp-block-query-pagination-numbers a:hover {
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--white);
}

.wp-block-query-pagination-numbers span.current {
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--white);
}

/* Footer Styles */
.site-footer {
	margin-top: auto;
}

.site-footer h3,
.site-footer h4,
.site-footer h5 {
	margin-bottom: 1rem;
}

.site-footer .wp-block-navigation-item a {
	padding: 0.25rem 0;
}

.site-footer .wp-block-navigation-item a::after {
	display: none;
}

/* Comments */
.comments-section {
	margin-top: var(--wp--preset--spacing--70);
}

/* Animations */
@media (prefers-reduced-motion: no-preference) {
	.wp-block-image img {
		transition: transform 0.3s ease;
	}

	.wp-block-image:hover img {
		transform: scale(1.02);
	}
}

/* Responsive */
@media (max-width: 781px) {
	.site-header .wp-block-group {
		flex-direction: column;
		gap: 1rem;
	}

	.author-box {
		flex-direction: column;
		text-align: center;
	}

	.post-navigation {
		flex-direction: column;
	}

	.post-navigation a {
		max-width: 100%;
		text-align: left !important;
	}
}

/* Print Styles */
@media print {
	.site-header,
	.site-footer,
	.comments-section,
	.post-navigation,
	.social-share,
	.related-posts {
		display: none !important;
	}

	body {
		font-size: 12pt;
		line-height: 1.5;
	}
}
