/*
Theme Name: StoryTime & Confessions Premium
Theme URI: https://storytimeandconfessions.com/
Description: A premium, custom-built WordPress theme for storytimeandconfessions.com featuring News, Stories, and Productivity Tools with 4K imagery, smooth animations, and mobile-first design.
Author: storytimeandconfessions
Author URI: https://storytimeandconfessions.com/
Version: 1.0.0
License: GPL v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: storytimeandconfessions
Domain Path: /languages
Requires at least: 5.8
Requires PHP: 7.4
Tags: news, stories, tools, responsive, mobile-friendly, 4k-images, seo-optimized

Owned by storytimeandconfessions
*/

:root {
	--primary-color: #1a1a1a;
	--secondary-color: #d32f2f;
	--accent-color: #ff6b6b;
	--text-dark: #2c3e50;
	--text-light: #7f8c8d;
	--bg-light: #f8f9fa;
	--bg-white: #ffffff;
	--border-color: #e0e0e0;
	--shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
	--shadow-md: 0 4px 12px rgba(0, 0, 0, 0.12);
	--shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
	--transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

body {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
	font-size: 16px;
	line-height: 1.6;
	color: var(--text-dark);
	background-color: var(--bg-white);
	overflow-x: hidden;
}

/* ========================= HEADER ========================= */

.site-header {
	background: var(--bg-white);
	box-shadow: var(--shadow-sm);
	position: sticky;
	top: 0;
	z-index: 1000;
	padding: 1rem 0;
	animation: slideDown 0.5s ease-out;
}

@keyframes slideDown {
	from {
		opacity: 0;
		transform: translateY(-20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.header-container {
	max-width: 1400px;
	margin: 0 auto;
	padding: 0 1rem;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.site-logo {
	display: flex;
	align-items: center;
	gap: 1rem;
	text-decoration: none;
	transition: var(--transition);
}

.site-logo:hover {
	transform: scale(1.05);
}

.site-logo img {
	height: 50px;
	width: auto;
	display: block;
}

.site-branding {
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--primary-color);
	letter-spacing: -0.5px;
}

.site-branding a {
	color: inherit;
	text-decoration: none;
	transition: var(--transition);
}

.site-branding a:hover {
	color: var(--secondary-color);
}

.ownership-badge {
	font-size: 0.75rem;
	color: var(--secondary-color);
	font-weight: 600;
	letter-spacing: 1px;
	text-transform: uppercase;
	display: block;
	margin-top: 0.25rem;
}

/* ========================= NAVIGATION ========================= */

.main-navigation {
	display: flex;
	gap: 2rem;
	align-items: center;
}

.main-navigation ul {
	list-style: none;
	display: flex;
	gap: 2rem;
	align-items: center;
}

.main-navigation a {
	color: var(--text-dark);
	text-decoration: none;
	font-weight: 500;
	position: relative;
	transition: color 0.3s ease;
	font-size: 0.95rem;
}

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

.main-navigation a:hover,
.main-navigation a.current {
	color: var(--secondary-color);
}

.main-navigation a:hover::after,
.main-navigation a.current::after {
	width: 100%;
}

.menu-toggle {
	display: none;
	background: none;
	border: none;
	cursor: pointer;
	font-size: 1.5rem;
	color: var(--primary-color);
}

/* Submenu */
.main-navigation .sub-menu {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	flex-direction: column;
	gap: 0;
	background: var(--bg-white);
	border-radius: 8px;
	box-shadow: var(--shadow-md);
	min-width: 200px;
	padding: 0.5rem 0;
	margin-top: 0.5rem;
}

.main-navigation li:hover .sub-menu {
	display: flex;
}

.main-navigation .sub-menu li {
	padding: 0;
}

.main-navigation .sub-menu a {
	display: block;
	padding: 0.75rem 1.5rem;
	font-size: 0.9rem;
	border-bottom: 1px solid var(--border-color);
}

.main-navigation .sub-menu a:hover {
	background: var(--bg-light);
}

/* Mobile Menu */
@media (max-width: 768px) {
	.menu-toggle {
		display: block;
	}

	.main-navigation {
		display: none;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		flex-direction: column;
		gap: 0;
		background: var(--bg-white);
		box-shadow: var(--shadow-md);
		padding: 1rem;
		border-radius: 0 0 8px 8px;
		width: 100%;
	}

	.main-navigation.open {
		display: flex;
	}

	.main-navigation ul {
		flex-direction: column;
		gap: 0;
		width: 100%;
	}

	.main-navigation li {
		width: 100%;
		border-bottom: 1px solid var(--border-color);
		padding: 0.5rem 0;
	}

	.main-navigation a {
		display: block;
		padding: 0.75rem 0;
	}

	.main-navigation .sub-menu {
		position: static;
		box-shadow: none;
		background: var(--bg-light);
		margin-top: 0;
		border-radius: 0;
	}
}

/* ========================= HERO SECTION ========================= */

.hero-section {
	position: relative;
	height: 500px;
	background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}

.hero-image {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	opacity: 0.3;
}

.hero-content {
	position: relative;
	z-index: 2;
	text-align: center;
	color: white;
	animation: slideUp 0.8s ease-out;
}

@keyframes slideUp {
	from {
		opacity: 0;
		transform: translateY(30px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.hero-content h1 {
	font-size: 3.5rem;
	font-weight: 900;
	margin-bottom: 1rem;
	text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
	letter-spacing: -1px;
}

.hero-content p {
	font-size: 1.25rem;
	margin-bottom: 2rem;
	font-weight: 300;
	text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
}

.hero-buttons {
	display: flex;
	gap: 1rem;
	justify-content: center;
	flex-wrap: wrap;
}

.btn {
	display: inline-block;
	padding: 0.75rem 2rem;
	border-radius: 50px;
	font-weight: 600;
	text-decoration: none;
	transition: var(--transition);
	border: 2px solid transparent;
	cursor: pointer;
	font-size: 0.95rem;
}

.btn-primary {
	background: var(--accent-color);
	color: white;
}

.btn-primary:hover {
	background: #ff5252;
	transform: translateY(-2px);
	box-shadow: var(--shadow-md);
}

.btn-secondary {
	background: transparent;
	color: white;
	border-color: white;
}

.btn-secondary:hover {
	background: white;
	color: var(--secondary-color);
	transform: translateY(-2px);
}

/* ========================= CONTENT SECTIONS ========================= */

.container {
	max-width: 1400px;
	margin: 0 auto;
	padding: 0 1rem;
}

.section {
	padding: 4rem 0;
}

.section-title {
	font-size: 2.5rem;
	margin-bottom: 3rem;
	text-align: center;
	position: relative;
	color: var(--primary-color);
}

.section-title::after {
	content: '';
	display: block;
	width: 60px;
	height: 4px;
	background: var(--secondary-color);
	margin: 1rem auto 0;
	border-radius: 2px;
}

.content-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 2rem;
	margin-top: 2rem;
}

/* ========================= CONTENT CARDS ========================= */

.content-card {
	background: var(--bg-white);
	border-radius: 12px;
	overflow: hidden;
	box-shadow: var(--shadow-sm);
	transition: var(--transition);
	display: flex;
	flex-direction: column;
}

.content-card:hover {
	transform: translateY(-8px);
	box-shadow: var(--shadow-lg);
}

.card-image {
	position: relative;
	width: 100%;
	padding-top: 66.67%;
	overflow: hidden;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.card-image img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.5s ease;
}

.content-card:hover .card-image img {
	transform: scale(1.1);
}

.card-overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.3);
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.3s ease;
}

.content-card:hover .card-overlay {
	background: rgba(0, 0, 0, 0.5);
}

.card-icon {
	font-size: 3rem;
	color: white;
	text-align: center;
}

.card-content {
	padding: 1.5rem;
	flex-grow: 1;
	display: flex;
	flex-direction: column;
}

.card-category {
	font-size: 0.75rem;
	text-transform: uppercase;
	color: var(--secondary-color);
	font-weight: 700;
	letter-spacing: 1px;
	margin-bottom: 0.5rem;
}

.card-title {
	font-size: 1.25rem;
	font-weight: 700;
	margin-bottom: 0.75rem;
	color: var(--primary-color);
	line-height: 1.3;
}

.card-description {
	font-size: 0.9rem;
	color: var(--text-light);
	margin-bottom: 1rem;
	flex-grow: 1;
}

.card-link {
	display: inline-block;
	color: var(--secondary-color);
	text-decoration: none;
	font-weight: 600;
	transition: var(--transition);
	font-size: 0.9rem;
}

.card-link:hover {
	color: var(--accent-color);
	transform: translateX(4px);
}

/* ========================= FEATURED SECTION ========================= */

.featured-section {
	background: linear-gradient(135deg, var(--bg-light) 0%, var(--bg-white) 100%);
	padding: 4rem 0;
}

.featured-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 3rem;
	align-items: center;
}

.featured-image {
	width: 100%;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: var(--shadow-lg);
}

.featured-image img {
	width: 100%;
	height: auto;
	display: block;
	transition: transform 0.6s ease;
}

.featured-section:hover .featured-image img {
	transform: scale(1.05);
}

.featured-content h2 {
	font-size: 2rem;
	margin-bottom: 1rem;
	color: var(--primary-color);
}

.featured-content p {
	margin-bottom: 1.5rem;
	line-height: 1.8;
	color: var(--text-light);
}

.featured-list {
	list-style: none;
	margin-bottom: 2rem;
}

.featured-list li {
	padding: 0.75rem 0;
	padding-left: 2rem;
	position: relative;
	color: var(--text-dark);
}

.featured-list li::before {
	content: '✓';
	position: absolute;
	left: 0;
	color: var(--secondary-color);
	font-weight: bold;
	font-size: 1.2rem;
}

/* ========================= RECENT POSTS ========================= */

.post-card {
	background: var(--bg-white);
	border-radius: 12px;
	overflow: hidden;
	box-shadow: var(--shadow-sm);
	transition: var(--transition);
	display: flex;
	flex-direction: column;
}

.post-card:hover {
	transform: translateY(-8px);
	box-shadow: var(--shadow-lg);
}

.post-image {
	position: relative;
	width: 100%;
	padding-top: 56.25%;
	overflow: hidden;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.post-image img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.5s ease;
}

.post-card:hover .post-image img {
	transform: scale(1.1);
}

.post-meta {
	position: absolute;
	top: 1rem;
	left: 1rem;
	display: flex;
	gap: 0.5rem;
	flex-wrap: wrap;
}

.post-tag {
	background: var(--secondary-color);
	color: white;
	padding: 0.4rem 0.8rem;
	border-radius: 20px;
	font-size: 0.75rem;
	font-weight: 600;
	text-transform: uppercase;
}

.post-content {
	padding: 1.5rem;
	flex-grow: 1;
	display: flex;
	flex-direction: column;
}

.post-title {
	font-size: 1.2rem;
	font-weight: 700;
	margin-bottom: 0.75rem;
	color: var(--primary-color);
	line-height: 1.4;
}

.post-title a {
	color: inherit;
	text-decoration: none;
	transition: color 0.3s ease;
}

.post-title a:hover {
	color: var(--secondary-color);
}

.post-excerpt {
	font-size: 0.9rem;
	color: var(--text-light);
	margin-bottom: 1rem;
	line-height: 1.6;
	flex-grow: 1;
}

.post-footer {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding-top: 1rem;
	border-top: 1px solid var(--border-color);
}

.post-author {
	font-size: 0.85rem;
	color: var(--text-light);
}

.post-date {
	font-size: 0.85rem;
	color: var(--text-light);
}

.post-link {
	color: var(--secondary-color);
	text-decoration: none;
	font-weight: 600;
	transition: var(--transition);
	font-size: 0.9rem;
}

.post-link:hover {
	color: var(--accent-color);
	transform: translateX(4px);
}

/* ========================= SEARCH KEYWORDS ========================= */

.search-keywords {
	background: var(--bg-light);
	padding: 2rem;
	border-radius: 12px;
	margin-top: 2rem;
}

.keywords-title {
	font-size: 0.9rem;
	font-weight: 700;
	color: var(--text-light);
	text-transform: uppercase;
	letter-spacing: 1px;
	margin-bottom: 1rem;
}

.keywords-list {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
}

.keyword {
	background: var(--bg-white);
	padding: 0.5rem 1rem;
	border-radius: 20px;
	font-size: 0.85rem;
	color: var(--text-dark);
	border: 1px solid var(--border-color);
	transition: var(--transition);
}

.keyword:hover {
	background: var(--secondary-color);
	color: white;
	border-color: var(--secondary-color);
	cursor: pointer;
}

/* ========================= INTERNAL LINKING ========================= */

.related-posts {
	background: var(--bg-light);
	padding: 2rem;
	border-radius: 12px;
	margin-top: 3rem;
}

.related-title {
	font-size: 1.5rem;
	margin-bottom: 1.5rem;
	color: var(--primary-color);
}

.related-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 1.5rem;
}

.related-card {
	background: var(--bg-white);
	padding: 1rem;
	border-radius: 8px;
	text-align: center;
	transition: var(--transition);
}

.related-card:hover {
	transform: translateY(-4px);
	box-shadow: var(--shadow-md);
}

.related-card a {
	color: var(--primary-color);
	text-decoration: none;
	font-weight: 600;
	display: block;
	font-size: 0.9rem;
	line-height: 1.4;
	transition: color 0.3s ease;
}

.related-card a:hover {
	color: var(--secondary-color);
}

/* ========================= FOOTER ========================= */

.site-footer {
	background: var(--primary-color);
	color: white;
	padding: 3rem 0 1rem;
	margin-top: 4rem;
}

.footer-content {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 2rem;
	margin-bottom: 2rem;
}

.footer-section h3 {
	font-size: 1.1rem;
	margin-bottom: 1rem;
	color: var(--accent-color);
}

.footer-section ul {
	list-style: none;
}

.footer-section li {
	margin-bottom: 0.75rem;
}

.footer-section a {
	color: rgba(255, 255, 255, 0.8);
	text-decoration: none;
	transition: var(--transition);
	font-size: 0.9rem;
}

.footer-section a:hover {
	color: var(--accent-color);
	padding-left: 4px;
}

.footer-bottom {
	border-top: 1px solid rgba(255, 255, 255, 0.1);
	padding-top: 2rem;
	text-align: center;
	font-size: 0.9rem;
	color: rgba(255, 255, 255, 0.8);
}

.footer-ownership {
	font-weight: 600;
	color: var(--accent-color);
	margin-bottom: 0.5rem;
}

/* ========================= RESPONSIVE DESIGN ========================= */

@media (max-width: 768px) {
	.hero-section {
		height: 350px;
	}

	.hero-content h1 {
		font-size: 2rem;
	}

	.hero-content p {
		font-size: 1rem;
	}

	.hero-buttons {
		flex-direction: column;
		gap: 0.75rem;
	}

	.btn {
		width: 100%;
	}

	.section {
		padding: 2rem 0;
	}

	.section-title {
		font-size: 1.75rem;
	}

	.featured-grid {
		grid-template-columns: 1fr;
		gap: 2rem;
	}

	.content-grid {
		grid-template-columns: 1fr;
		gap: 1.5rem;
	}

	.main-navigation a {
		font-size: 0.9rem;
	}

	.site-branding {
		font-size: 1.2rem;
	}

	.site-logo img {
		height: 40px;
	}
}

@media (max-width: 480px) {
	.hero-section {
		height: 280px;
	}

	.hero-content h1 {
		font-size: 1.5rem;
	}

	.section-title {
		font-size: 1.5rem;
	}

	.card-title {
		font-size: 1.1rem;
	}

	.featured-content h2 {
		font-size: 1.5rem;
	}

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

	.footer-content {
		grid-template-columns: 1fr;
	}
}

/* ========================= ANIMATIONS ========================= */

@keyframes pulse {
	0%, 100% {
		opacity: 1;
	}
	50% {
		opacity: 0.7;
	}
}

@keyframes spin {
	from {
		transform: rotate(0deg);
	}
	to {
		transform: rotate(360deg);
	}
}

.loading {
	animation: pulse 2s ease-in-out infinite;
}

/* ========================= UTILITY CLASSES ========================= */

.text-center {
	text-align: center;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

/* ========================= ACCESSIBILITY ========================= */

.skip-link {
	position: absolute;
	top: -40px;
	left: 0;
	background: var(--secondary-color);
	color: white;
	padding: 0.5rem 1rem;
	text-decoration: none;
	z-index: 100;
}

.skip-link:focus {
	top: 0;
}

@media (prefers-reduced-motion: reduce) {
	* {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}

/* ========================= PRINT ========================= */

@media print {
	.site-header,
	.site-footer,
	.hero-section,
	.btn {
		display: none;
	}

	body {
		background: white;
	}

	.content-card,
	.post-card {
		box-shadow: none;
		border: 1px solid var(--border-color);
	}
}
