/**
 * Upcoming Releases - My Account Tab Styles
 *
 * @package OnCloudWine
 * @since 2.0.0
 */

.oncloudwine-upcoming-releases h2 {
	font-family: 'Lora', Georgia, serif;
	font-size: 1.5rem;
	color: #2c2c2c;
	margin-bottom: 1.5rem;
}

.oncloudwine-empty-state {
	text-align: center;
	padding: 3rem 1rem;
	color: #5c5c5c;
}

.oncloudwine-releases-list {
	display: flex;
	flex-direction: column;
	gap: 1.25rem;
}

.oncloudwine-release-item {
	border: 1px solid rgba(139, 119, 101, 0.2);
	border-radius: 8px;
	padding: 1.25rem 1.5rem;
	background: #fff;
	transition: box-shadow 0.2s ease;
}

.oncloudwine-release-item:hover {
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.release-item-header {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 1rem;
	margin-bottom: 0.75rem;
}

.release-item-name {
	font-family: 'Lora', Georgia, serif;
	font-size: 1.15rem;
	margin: 0 0 0.25rem;
}

.release-item-name a {
	color: #2c2c2c;
	text-decoration: none;
	transition: color 0.2s ease;
}

.release-item-name a:hover {
	color: #8b7765;
}

.release-item-date {
	color: #5c5c5c;
	font-size: 0.9rem;
	margin: 0;
}

.release-eligibility-badge {
	display: inline-block;
	padding: 0.25rem 0.75rem;
	border-radius: 12px;
	font-size: 0.8rem;
	font-weight: 600;
	white-space: nowrap;
	background: #f0f0f0;
	color: #666;
}

.release-eligibility-badge.eligible {
	background: #e8f5e9;
	color: #2e7d32;
}

.release-eligibility-badge.not-eligible {
	background: #fce4ec;
	color: #c62828;
}

.release-item-details {
	margin-bottom: 0.75rem;
}

.release-item-details p {
	margin: 0.25rem 0;
	font-size: 0.9rem;
	color: #5c5c5c;
}

.release-item-details strong {
	color: #2c2c2c;
}

.release-item-eligibility-issues {
	margin-bottom: 0.75rem;
}

.release-item-eligibility-issues .issue {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	font-size: 0.85rem;
	color: #c62828;
	margin: 0.25rem 0;
}

.release-item-eligibility-issues .issue::before {
	content: '!';
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background: #fce4ec;
	color: #c62828;
	font-size: 0.7rem;
	font-weight: 700;
	flex-shrink: 0;
}

.release-item-actions {
	padding-top: 0.75rem;
	border-top: 1px solid rgba(139, 119, 101, 0.1);
}

.release-item-actions .button {
	display: inline-block;
	padding: 0.5rem 1.25rem;
	background: #8b7765;
	color: #fff;
	border: none;
	border-radius: 4px;
	font-size: 0.9rem;
	text-decoration: none;
	cursor: pointer;
	transition: background 0.2s ease;
}

.release-item-actions .button:hover {
	background: #5c4a3d;
	color: #fff;
}

@media (max-width: 600px) {
	.release-item-header {
		flex-direction: column;
	}

	.oncloudwine-release-item {
		padding: 1rem;
	}
}

/* ===========================
   Release Detail Modal
   =========================== */
.oncloudwine-release-modal {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 100000;
}

.release-modal-overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0, 0, 0, 0.5);
}

.release-modal-container {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	background: #fff;
	border-radius: 8px;
	width: 94%;
	max-width: 960px;
	max-height: 90vh;
	display: flex;
	flex-direction: column;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}

.release-modal-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 1rem 1.5rem;
	border-bottom: 1px solid rgba(139, 119, 101, 0.2);
	flex-shrink: 0;
}

.release-modal-title {
	font-family: 'Lora', Georgia, serif;
	font-size: 1.25rem;
	margin: 0;
	color: #2c2c2c;
}

.release-modal-close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	background: transparent;
	border: none;
	border-radius: 4px;
	cursor: pointer;
	transition: background 0.2s ease;
	color: #5c5c5c;
}

.release-modal-close:hover {
	background: #f0f0f0;
	color: #2c2c2c;
}

.release-modal-body {
	flex: 1;
	padding: 1.5rem;
	overflow-y: auto;
	overflow-x: hidden;
	-webkit-overflow-scrolling: touch;
}

.release-modal-loading {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 3rem 1rem;
	color: #5c5c5c;
}

.release-modal-loading .spinner {
	float: none;
	margin: 0 0 0.75rem;
}

.release-modal-loading p {
	margin: 0;
	font-size: 0.95rem;
}

/* Ensure nested single release content fits inside modal */
.release-modal-content .oncloudwine-single-release {
	margin: 0;
	padding: 0;
}

.release-modal-content .release-back-link {
	display: none;
}

.release-modal-content .release-header {
	margin-bottom: 1rem;
}

.release-modal-content .release-header h1 {
	font-size: 1.15rem;
}

/* Error state inside modal */
.release-modal-content .oncloudwine-error {
	text-align: center;
	padding: 2rem 1rem;
	color: #c62828;
}

@media (max-width: 768px) {
	.release-modal-container {
		width: 100%;
		height: 100%;
		max-width: 100%;
		max-height: 100%;
		border-radius: 0;
		top: 0;
		left: 0;
		transform: none;
	}

	.release-modal-body {
		padding: 1rem;
	}
}
