/**
 * Golf Club Notice Board - Frontend Block Styles
 * 
 * Responsive styles for the notice board display block
 */

/* Main container */
.gcnb-notices-container {
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0;
}

/* Important notices container styling */
.gcnb-notices-container.gcnb-important-notices {
	background: rgba(0, 0, 0, 0.4);
	padding: 10px;
	border-radius: 8px;
}

/* Announcements header (when showing only important notices) */
.gcnb-announcements-header {
	margin-bottom: 25px;
	text-align: center;
}

.gcnb-announcements-title {
	font-size: 32px;
	font-weight: bold;
	color: #ffffff;
	margin: 0 0 15px 0;
	text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
	line-height: 1.2;
}

.gcnb-announcements-separator {
	width: 50%;
	height: 3px;
	background: linear-gradient(90deg, #45AF70 0%, rgba(69, 175, 112, 0.3) 100%);
	border: none;
	margin: 0 auto;
	border-radius: 2px;
}

/* Individual notice card */
.gcnb-notice-card {
	background: #ffffff;
	border: 1px solid #e1e1e1;
	border-radius: 8px;
	padding: 20px;
	margin-bottom: 15px;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	transition: box-shadow 0.3s ease;
	position: relative;
}

/* NEW badge for unread notices */
.gcnb-new-badge {
	position: absolute;
	top: 10px;
	right: 10px;
	background: #28a745;
	color: white;
	font-size: 11px;
	font-weight: bold;
	padding: 4px 8px;
	border-radius: 12px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	z-index: 10;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
	border: 1px solid #1e7e34;
}

.gcnb-notice-card:hover {
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.gcnb-notice-card:last-child {
	margin-bottom: 0;
}

/* Notice title */
.gcnb-notice-title {
	font-size: 18px;
	font-weight: bold;
	color: #333333;
	margin: 0 0 15px 0;
	line-height: 1.4;
}

/* Notice content */
.gcnb-notice-content {
	margin-bottom: 15px;
}

.gcnb-notice-text {
	font-size: 16px;
	line-height: 1.6;
	color: #555555;
	margin: 0;
}

/* Read more button */
.gcnb-read-more {
	color: #0073aa;
	text-decoration: underline;
	background: none;
	border: none;
	cursor: pointer;
	font-size: inherit;
	font-family: inherit;
	padding: 0;
	margin-left: 5px;
	transition: color 0.3s ease;
}

.gcnb-read-more:hover,
.gcnb-read-more:focus {
	color: #005a87;
	text-decoration: none;
}

.gcnb-read-more:focus {
	outline: 2px solid #0073aa;
	outline-offset: 2px;
}

/* Meta section (attachments and links) */
.gcnb-notice-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 15px;
	align-items: center;
}

/* Attachment and link tags */
.gcnb-attachment-tag,
.gcnb-link-tag {
	display: inline-flex;
	align-items: center;
	padding: 6px 12px;
	border-radius: 16px;
	text-decoration: none;
	font-size: 14px;
	font-weight: 500;
	transition: all 0.3s ease;
	max-width: 100%;
	overflow: hidden;
}

.gcnb-attachment-tag {
	background-color: #e3f2fd;
	color: #1976d2;
	border: 1px solid #bbdefb;
}

.gcnb-attachment-tag:hover {
	background-color: #bbdefb;
	color: #1565c0;
	text-decoration: none;
}

.gcnb-link-tag {
	background-color: #e8f5e9;
	color: #388e3c;
	border: 1px solid #c8e6c9;
}

.gcnb-link-tag:hover {
	background-color: #c8e6c9;
	color: #2e7d32;
	text-decoration: none;
}

/* File and link icons */
.gcnb-file-icon,
.gcnb-link-icon {
	margin-right: 6px;
	font-size: 16px;
	flex-shrink: 0;
}

/* File and link names */
.gcnb-file-name,
.gcnb-link-text {
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	max-width: 200px;
}

/* Notice date */
.gcnb-notice-date {
	font-size: 12px;
	color: #999999;
	text-align: right;
	margin: 0;
	font-style: italic;
}

/* Empty state */
.gcnb-notices-container p {
	text-align: center;
	color: #666666;
	font-style: italic;
	padding: 40px 20px;
	margin: 0;
}

/* Responsive Design */

/* Tablet styles (481px - 768px) */
@media screen and (max-width: 768px) {
	.gcnb-notice-card {
		padding: 15px;
		margin-bottom: 12px;
	}
	
	.gcnb-notice-title {
		font-size: 17px;
		margin-bottom: 12px;
	}
	
	.gcnb-notice-text {
		font-size: 15px;
	}
	
	.gcnb-notice-meta {
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}
	
	.gcnb-attachment-tag,
	.gcnb-link-tag {
		width: 100%;
		max-width: none;
		justify-content: flex-start;
	}
	
	.gcnb-file-name,
	.gcnb-link-text {
		max-width: none;
		white-space: normal;
		overflow: visible;
		text-overflow: clip;
	}
}

/* Mobile styles (max-width: 480px) */
@media screen and (max-width: 480px) {
	.gcnb-notice-card {
		padding: 12px;
		margin-bottom: 10px;
		border-radius: 6px;
	}
	
	.gcnb-notice-title {
		font-size: 16px;
		margin-bottom: 10px;
		line-height: 1.3;
	}
	
	.gcnb-notice-text {
		font-size: 14px;
		line-height: 1.5;
	}
	
	.gcnb-notice-content {
		margin-bottom: 12px;
	}
	
	.gcnb-notice-meta {
		margin-bottom: 12px;
		gap: 6px;
	}
	
	.gcnb-attachment-tag,
	.gcnb-link-tag {
		padding: 8px 12px;
		font-size: 13px;
		border-radius: 20px;
	}
	
	.gcnb-notice-date {
		font-size: 11px;
		text-align: left;
	}
	
	/* Stack everything vertically on mobile */
	.gcnb-notice-meta {
		flex-direction: column;
		align-items: stretch;
	}
	
	.gcnb-attachment-tag,
	.gcnb-link-tag {
		width: 100%;
		text-align: left;
	}
}

/* High contrast mode support */
@media (prefers-contrast: high) {
	.gcnb-notice-card {
		border: 2px solid #000000;
		box-shadow: none;
	}
	
	.gcnb-notice-title {
		color: #000000;
	}
	
	.gcnb-notice-text {
		color: #000000;
	}
	
	.gcnb-read-more {
		color: #0000ff;
		text-decoration: underline;
	}
	
	.gcnb-attachment-tag {
		background-color: #ffffff;
		color: #000000;
		border: 2px solid #000000;
	}
	
	.gcnb-link-tag {
		background-color: #ffffff;
		color: #000000;
		border: 2px solid #000000;
	}
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
	.gcnb-notice-card,
	.gcnb-read-more,
	.gcnb-attachment-tag,
	.gcnb-link-tag {
		transition: none;
	}
	
	.gcnb-notice-text {
		transition: none;
	}
}

/* Print styles */
@media print {
	.gcnb-notice-card {
		box-shadow: none;
		border: 1px solid #000000;
		break-inside: avoid;
		margin-bottom: 20px;
	}
	
	.gcnb-read-more {
		display: none;
	}
	
	.gcnb-notice-full {
		display: inline !important;
	}
	
	.gcnb-notice-excerpt {
		display: none !important;
	}
	
	.gcnb-attachment-tag,
	.gcnb-link-tag {
		background-color: transparent;
		border: 1px solid #000000;
		color: #000000;
	}
}
