/**
 * Groups Page - Professional Modern Design
 *
 * @package Coursee
 * @since 1.0.0
 */

/* ============================================
   GROUPS PAGE LAYOUT
   ============================================ */

.coursee-groups-list {
	max-width: 1400px;
	margin: 0 auto;
	padding: 3rem 2rem;
}

/* Groups Header */
.groups-page-header {
	text-align: center;
	margin-bottom: 4rem;
	padding: 3rem 0;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: #ffffff;
	border-radius: 16px;
	position: relative;
	overflow: hidden;
}

.groups-page-header::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
	opacity: 0.3;
}

.groups-page-header h1 {
	font-size: 3rem;
	font-weight: 900;
	margin: 0 0 1rem 0;
	position: relative;
	z-index: 1;
	text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.groups-page-header p {
	font-size: 1.25rem;
	margin: 0;
	opacity: 0.95;
	position: relative;
	z-index: 1;
}

/* Groups Grid */
.groups-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
	gap: 2rem;
	margin-top: 2rem;
}

/* Group Item Card */
.group-item {
	background: #ffffff;
	border-radius: 16px;
	padding: 2rem;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
	border: 2px solid #e5e7eb;
	transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	position: relative;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	height: 100%;
}

.group-item::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 4px;
	background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
	transform: scaleX(0);
	transition: transform 0.3s ease;
}

.group-item:hover {
	transform: translateY(-8px);
	box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
	border-color: #667eea;
}

.group-item:hover::before {
	transform: scaleX(1);
}

/* Group Header */
.group-item-header {
	display: flex;
	align-items: flex-start;
	gap: 1rem;
	margin-bottom: 1.5rem;
}

.group-icon {
	width: 64px;
	height: 64px;
	border-radius: 12px;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 2rem;
	flex-shrink: 0;
	color: #ffffff;
	box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.group-item h3 {
	font-size: 1.5rem;
	font-weight: 900;
	color: #000000;
	margin: 0;
	flex: 1;
	line-height: 1.3;
}

/* Group Content */
.group-item p {
	font-size: 1rem;
	line-height: 1.6;
	color: #6b7280;
	margin: 0 0 1.5rem 0;
	flex: 1;
}

/* Group Meta */
.group-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
	margin-bottom: 1.5rem;
	padding-top: 1.5rem;
	border-top: 1px solid #e5e7eb;
}

.group-meta-item {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	font-size: 0.875rem;
	color: #6b7280;
}

.group-meta-item-icon {
	width: 20px;
	height: 20px;
	display: flex;
	align-items: center;
	justify-content: center;
	color: #667eea;
}

.group-members-count,
.group-posts-count {
	font-weight: 600;
	color: #374151;
}

/* Group Actions */
.group-actions {
	display: flex;
	gap: 0.75rem;
	margin-top: auto;
}

.group-item .button {
	flex: 1;
	padding: 0.875rem 1.5rem;
	font-weight: 600;
	border-radius: 8px;
	text-align: center;
	transition: all 0.3s ease;
	border: 2px solid transparent;
}

.group-item .button-primary {
	background: #000000;
	color: #ffffff;
	border-color: #000000;
}

.group-item .button-primary:hover {
	background: #374151;
	border-color: #374151;
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.group-item .button-outline {
	background: transparent;
	color: #000000;
	border-color: #000000;
}

.group-item .button-outline:hover {
	background: #000000;
	color: #ffffff;
}

/* Empty State */
.coursee-groups-list > p {
	text-align: center;
	padding: 4rem 2rem;
	font-size: 1.125rem;
	color: #6b7280;
	background: #ffffff;
	border-radius: 16px;
	border: 2px dashed #e5e7eb;
}

/* Create Group Button */
.create-group-section {
	text-align: center;
	margin-bottom: 3rem;
}

.create-group-button {
	display: inline-flex;
	align-items: center;
	gap: 0.75rem;
	padding: 1rem 2rem;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: #ffffff;
	font-size: 1.125rem;
	font-weight: 700;
	border-radius: 12px;
	text-decoration: none;
	box-shadow: 0 4px 16px rgba(102, 126, 234, 0.3);
	transition: all 0.3s ease;
	border: none;
	cursor: pointer;
}

.create-group-button:hover {
	transform: translateY(-4px);
	box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.create-group-button-icon {
	font-size: 1.5rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
	.groups-grid {
		grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
		gap: 1.5rem;
	}
}

@media (max-width: 768px) {
	.coursee-groups-list {
		padding: 2rem 1rem;
	}
	
	.groups-page-header {
		padding: 2rem 1rem;
		margin-bottom: 2rem;
	}
	
	.groups-page-header h1 {
		font-size: 2rem;
	}
	
	.groups-page-header p {
		font-size: 1rem;
	}
	
	.groups-grid {
		grid-template-columns: 1fr;
		gap: 1.5rem;
	}
	
	.group-item {
		padding: 1.5rem;
	}
	
	.group-item h3 {
		font-size: 1.25rem;
	}
	
	.group-actions {
		flex-direction: column;
	}
	
	.group-item .button {
		width: 100%;
	}
}

