/**
 * Memorial Frontend Forms & Dashboard Styles
 *
 * Styles for memorial creation/editing forms and memorial dashboard
 *
 * @package Betheme Child Theme
 */

/* ==========================================================================
   Messages & Notifications
   ========================================================================== */

.sf-message {
	padding: 15px 20px;
	margin-bottom: 20px;
	border-radius: 4px;
	border-left: 4px solid;
	background-color: #f9f9f9;
}

.sf-message p {
	margin: 0;
}

.sf-message-success {
	border-left-color: #46b450;
	background-color: #ecf7ed;
	color: #2e7d32;
}

.sf-message-error {
	border-left-color: #dc3232;
	background-color: #fef1f1;
	color: #c62828;
}

.sf-message-warning {
	border-left-color: #ffb900;
	background-color: #fff8e5;
	color: #7f6000;
}

.sf-message-warning p + p {
	margin-top: 10px;
}

/* Subscription Warning Banner */
.sf-subscription-warning {
	background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
	color: #fff;
	padding: 0;
	margin-bottom: 0;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.sf-subscription-warning-content {
	display: flex;
	align-items: center;
	gap: 20px;
	padding: 20px;
	max-width: 1200px;
	margin: 0 auto;
}

.sf-subscription-warning-content i {
	font-size: 32px;
	opacity: 0.9;
}

.sf-subscription-warning-content strong {
	display: block;
	font-size: 18px;
	margin-bottom: 8px;
}

.sf-subscription-warning-content p {
	margin: 0 0 12px 0;
	opacity: 0.95;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.sf-button {
	display: inline-block;
	padding: 12px 24px;
	font-size: 16px;
	font-weight: 500;
	text-align: center;
	text-decoration: none;
	border-radius: 4px;
	border: none;
	cursor: pointer;
	transition: all 0.3s ease;
}

.sf-button-primary {
	background-color: #2c3e50;
	color: #ffffff;
}

.sf-button-primary:hover {
	background-color: #1a252f;
	color: #ffffff;
	transform: translateY(-2px);
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.sf-button-secondary {
	background-color: #ecf0f1;
	color: #2c3e50;
}

.sf-button-secondary:hover {
	background-color: #d5dbdb;
	color: #2c3e50;
	transform: translateY(-2px);
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.sf-button-disabled {
	background-color: #bdc3c7;
	color: #7f8c8d;
	cursor: not-allowed;
	opacity: 0.6;
}

.sf-button-disabled:hover {
	transform: none;
	box-shadow: none;
}

/* ==========================================================================
   Memorial Dashboard
   ========================================================================== */

.sf-memorials-dashboard {
	padding: 40px 0;
}

.sf-memorials-dashboard h2 {
	font-size: 32px;
	margin-bottom: 30px;
	color: #2c3e50;
}

.sf-memorials-dashboard h3 {
	font-size: 24px;
	margin-bottom: 20px;
	color: #34495e;
}

.sf-no-memorials {
	text-align: center;
	padding: 60px 20px;
	background-color: #f8f9fa;
	border-radius: 8px;
	margin-bottom: 30px;
}

.sf-no-memorials p {
	font-size: 18px;
	color: #7f8c8d;
	margin-bottom: 20px;
}

/* ==========================================================================
   Memorials List
   ========================================================================== */

.sf-memorials-list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
	gap: 24px;
	margin-bottom: 40px;
}

.sf-memorial-card {
	background: #ffffff;
	border: 1px solid #e1e8ed;
	border-radius: 8px;
	overflow: hidden;
	transition: all 0.3s ease;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.sf-memorial-card:hover {
	box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
	transform: translateY(-4px);
}

.sf-memorial-card-photo {
	width: 100%;
	height: 200px;
	overflow: hidden;
	background-color: #f0f0f0;
}

.sf-memorial-card-photo img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.sf-memorial-card-body {
	padding: 24px;
}

.sf-memorial-card-header {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	margin-bottom: 16px;
	gap: 12px;
}

.sf-memorial-card-header h3 {
	font-size: 20px;
	margin: 0;
	color: #2c3e50;
	flex: 1;
}

.sf-memorial-subscription-status {
	margin-bottom: 8px;
}

.sf-memorial-visibility {
	font-size: 13px;
	color: #7f8c8d;
}

.sf-status-badge {
	display: inline-block;
	padding: 4px 12px;
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	border-radius: 12px;
	white-space: nowrap;
}

.sf-status-active {
	background-color: #d4edda;
	color: #155724;
}

.sf-status-expired {
	background-color: #f8d7da;
	color: #721c24;
}

.sf-status-cancelled {
	background-color: #f8d7da;
	color: #721c24;
}

.sf-status-on-hold {
	background-color: #fff3cd;
	color: #856404;
}

.sf-status-pending-cancel {
	background-color: #fff3cd;
	color: #856404;
}

.sf-status-none {
	background-color: #e2e3e5;
	color: #383d41;
}

.sf-memorial-card-meta {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin-bottom: 20px;
	font-size: 14px;
	color: #657786;
}

.sf-memorial-card-actions {
	display: flex;
	gap: 12px;
}

.sf-memorial-card-actions .sf-button {
	flex: 1;
	padding: 10px 16px;
	font-size: 14px;
}

.sf-memorial-inactive {
	opacity: 0.85;
	background-color: #f8f9fa;
}

/* ==========================================================================
   Create Memorial Section
   ========================================================================== */

.sf-create-memorial-section {
	margin-top: 40px;
	padding-top: 40px;
}

.sf-create-memorial-section hr {
	margin-bottom: 30px;
	border: none;
	border-top: 2px solid #e1e8ed;
}

/* ==========================================================================
   ACF Frontend Forms
   ========================================================================== */

.sf-create-memorial-form,
.sf-edit-memorial-form {
	background: #ffffff;
	padding: 30px;
	border-radius: 8px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
	margin-bottom: 30px;
}

.sf-back-link {
	margin-bottom: 20px;
}

.sf-back-link a {
	color: #2c3e50;
	text-decoration: none;
	font-weight: 500;
	transition: color 0.3s ease;
}

.sf-back-link a:hover {
	color: #3498db;
}

/* ACF Form Field Styles */
.acf-form {
	margin-top: 20px;
}

.acf-field {
	margin-bottom: 24px;
}

.acf-label {
	font-weight: 600;
	margin-bottom: 8px;
	color: #2c3e50;
}

.acf-label label {
	font-size: 15px;
}

.acf-input {
	margin-top: 8px;
}

.acf-input input[type="text"],
.acf-input input[type="email"],
.acf-input input[type="url"],
.acf-input input[type="number"],
.acf-input textarea,
.acf-input select {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid #ddd;
	border-radius: 4px;
	font-size: 15px;
	transition: border-color 0.3s ease;
}

.acf-input input:focus,
.acf-input textarea:focus,
.acf-input select:focus {
	outline: none;
	border-color: #3498db;
	box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.acf-input textarea {
	min-height: 120px;
	resize: vertical;
}

/* ACF Repeater Styles */
.acf-repeater {
	border: 1px solid #e1e8ed;
	border-radius: 4px;
}

.acf-repeater .acf-row {
	padding: 20px;
	border-bottom: 1px solid #e1e8ed;
	background-color: #f8f9fa;
}

.acf-repeater .acf-row:last-child {
	border-bottom: none;
}

.acf-repeater .acf-row-handle {
	background: #ecf0f1;
	padding: 8px 12px;
	border-radius: 4px;
	margin-bottom: 12px;
	cursor: move;
}

.acf-repeater .acf-actions {
	padding: 15px;
	background-color: #fff;
}

.acf-repeater .acf-button {
	background-color: #3498db;
	color: #ffffff;
	border: none;
	padding: 8px 16px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 14px;
	transition: background-color 0.3s ease;
}

.acf-repeater .acf-button:hover {
	background-color: #2980b9;
}

/* ACF Image Upload */
.acf-image-uploader {
	border: 2px dashed #ddd;
	border-radius: 4px;
	padding: 20px;
	text-align: center;
	transition: border-color 0.3s ease;
}

.acf-image-uploader:hover {
	border-color: #3498db;
}

.acf-image-uploader .image-wrap img {
	max-width: 100%;
	height: auto;
	border-radius: 4px;
}

/* Form Submit Button */
.acf-form-submit {
	padding-top: 20px;
	margin-top: 20px;
	border-top: 2px solid #e1e8ed;
}

.acf-form-submit input[type="submit"] {
	background-color: #2c3e50;
	color: #ffffff;
	border: none;
	padding: 14px 32px;
	font-size: 16px;
	font-weight: 600;
	border-radius: 4px;
	cursor: pointer;
	transition: all 0.3s ease;
}

.acf-form-submit input[type="submit"]:hover {
	background-color: #1a252f;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   Dashboard Page
   ========================================================================== */

.sf-dashboard-page {
	padding: 60px 0;
	min-height: 60vh;
}

.sf-login-required {
	text-align: center;
	padding: 80px 20px;
}

.sf-login-required h2 {
	font-size: 32px;
	margin-bottom: 20px;
	color: #2c3e50;
}

.sf-login-required p {
	font-size: 18px;
	color: #7f8c8d;
	margin-bottom: 30px;
}

/* ==========================================================================
   Full-Width Form Pages (Add/Edit Memorial)
   ========================================================================== */

.sf-full-width-form {
	padding: 40px 0;
	min-height: 70vh;
	background-color: #f8f9fa;
}

.sf-form-container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 20px;
}

.sf-page-header {
	margin-bottom: 30px;
	padding-bottom: 20px;
	border-bottom: 2px solid #e1e8ed;
}

.sf-page-header h1 {
	font-size: 36px;
	margin-bottom: 12px;
	color: #2c3e50;
}

.sf-page-header .sf-back-link {
	margin: 0;
}

.sf-page-header .sf-back-link a {
	color: #657786;
	text-decoration: none;
	font-size: 16px;
	transition: color 0.3s ease;
}

.sf-page-header .sf-back-link a:hover {
	color: #2c3e50;
}

.sf-page-header-links {
	display: flex;
	align-items: center;
	gap: 20px;
}

.sf-page-header-links a {
	color: #657786;
	text-decoration: none;
	font-size: 16px;
	transition: color 0.3s ease;
}

.sf-page-header-links a:hover {
	color: #2c3e50;
}

.sf-page-header-links a i {
	margin-right: 5px;
}

.sf-add-memorial-page .sf-create-memorial-form,
.sf-edit-memorial-page .sf-edit-memorial-form {
	background: #ffffff;
	padding: 40px;
	border-radius: 8px;
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.sf-add-memorial-page .sf-create-memorial-form h3,
.sf-edit-memorial-page .sf-edit-memorial-form h3 {
	margin-top: 0;
	margin-bottom: 24px;
	font-size: 24px;
	color: #34495e;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
	.sf-memorials-list {
		grid-template-columns: 1fr;
	}

	.sf-memorial-card-actions {
		flex-direction: column;
	}

	.sf-subscription-warning-content {
		flex-direction: column;
		text-align: center;
	}

	.sf-subscription-warning-content i {
		font-size: 40px;
	}

	.sf-create-memorial-form,
	.sf-edit-memorial-form {
		padding: 20px;
	}

	.sf-memorials-dashboard h2 {
		font-size: 28px;
	}

	.sf-dashboard-page {
		padding: 40px 0;
	}

	.sf-page-header h1 {
		font-size: 28px;
	}

	.sf-add-memorial-page .sf-create-memorial-form,
	.sf-edit-memorial-page .sf-edit-memorial-form {
		padding: 24px;
	}
}

@media (max-width: 480px) {
	.sf-message {
		padding: 12px 15px;
		font-size: 14px;
	}

	.sf-button {
		padding: 10px 20px;
		font-size: 14px;
	}

	.sf-memorial-card-body {
		padding: 20px;
	}

	.sf-memorial-card-header h3 {
		font-size: 18px;
	}

	.sf-create-memorial-form,
	.sf-edit-memorial-form {
		padding: 15px;
	}
}
