/* =========================================================================
   WNC Event Calendar — Public Styles
   ========================================================================= */

:root {
	--ec-green-dark:  #1b4332;
	--ec-green:       #2d6a4f;
	--ec-green-mid:   #40916c;
	--ec-green-light: #52b788;
	--ec-green-pale:  #d8f3dc;
	--ec-green-xpale: #f0faf2;
	--ec-text:        #1a1a1a;
	--ec-muted:       #666;
	--ec-border:      #e0e0e0;
	--ec-radius:      10px;
	--ec-shadow:      0 2px 12px rgba(0,0,0,.08);
	--ec-font:        -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* =========================================================================
   CALENDAR WIDGET  [wnc_event_calendar]
   Design: clean white grid, day numbers top-right, poster images fill cells
   ========================================================================= */

.wnc-ec-wrap {
	font-family: var(--ec-font);
	max-width: 1140px;
	margin: 0 auto;
	border: 2px solid #3a5a3a;
	border-radius: 4px;
	overflow: hidden;
	background: #fff;
}

/* ── Header: white, large serif title, minimal arrows ───────────────── */
.wnc-ec-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 22px 28px 16px;
	background: #fff;
	border-bottom: 1px solid #e8e8e8;
}

.wnc-ec-month-label {
	font-size: 2rem;
	font-weight: 400;
	letter-spacing: .01em;
	margin: 0;
	color: #1a1a1a;
	flex: 1;
	text-align: center;
	font-family: Georgia, 'Times New Roman', serif;
}

.wnc-ec-nav {
	background: transparent;
	border: none;
	color: #555;
	font-size: 1.4rem;
	cursor: pointer;
	padding: 6px 12px;
	border-radius: 4px;
	transition: color .15s, background .15s;
	line-height: 1;
}
.wnc-ec-nav:hover {
	color: #1a1a1a;
	background: #f4f4f4;
}

/* ── Day-of-week row: SU MO TU WE TH FR SA ─────────────────────────── */
.wnc-ec-day-names {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	background: #fff;
	border-bottom: 1px solid #e8e8e8;
}
.wnc-ec-day-names span {
	padding: 14px 0 10px;
	text-align: center;
	font-size: .72rem;
	font-weight: 400;
	letter-spacing: .1em;
	color: #999;
	text-transform: uppercase;
}

/* ── Grid wrapper ───────────────────────────────────────────────────── */
.wnc-ec-grid-wrap { background: #f0f0f0; }

.wnc-ec-grid {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	border-left: 1px solid #e0e0e0;
	border-top: 1px solid #e0e0e0;
}

.wnc-ec-loading {
	grid-column: 1 / -1;
	text-align: center;
	padding: 60px;
	color: #bbb;
	font-size: .9rem;
}

/* ── Cell ────────────────────────────────────────────────────────────── */
.wnc-ec-cell {
	min-height: 130px;
	border-right: 1px solid #e0e0e0;
	border-bottom: 1px solid #e0e0e0;
	background: #fff;
	position: relative;
	overflow: hidden;
	box-sizing: border-box;
}

.wnc-ec-cell--empty { background: #f5f5f5; }
.wnc-ec-cell--past  { background: #fafafa; }
.wnc-ec-cell--today { background: #fff; }

/* ── Day number — top-right of each cell ─────────────────────────────── */
.wnc-ec-cell-num {
	position: absolute;
	top: 8px;
	right: 10px;
	font-size: .82rem;
	font-weight: 400;
	color: #aaa;
	line-height: 1;
	z-index: 2;
	pointer-events: none;
}

/* Today's number: black circle badge */
.wnc-ec-cell-num--today {
	position: absolute;
	top: 6px;
	right: 7px;
	width: 24px;
	height: 24px;
	background: #1a1a1a;
	color: #fff;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: .73rem;
	font-weight: 600;
	z-index: 2;
	pointer-events: none;
}

/* ── Poster-style event — image fills the entire cell ────────────────── */
.wnc-ec-poster-link {
	display: block;
	position: absolute;
	inset: 0;
	text-decoration: none;
	overflow: hidden;
}

.wnc-ec-poster-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform .3s ease;
}
.wnc-ec-poster-link:hover .wnc-ec-poster-img {
	transform: scale(1.05);
}

/* Text fallback when no thumbnail */
.wnc-ec-poster-link--text {
	background: var(--ec-green-pale);
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	justify-content: flex-end;
	padding: 8px;
}
.wnc-ec-poster-text-inner {
	display: flex;
	flex-direction: column;
	gap: 2px;
}
.wnc-ec-poster-title {
	font-size: .7rem;
	font-weight: 700;
	color: var(--ec-green-dark);
	line-height: 1.3;
}
.wnc-ec-poster-time {
	font-size: .62rem;
	color: var(--ec-green-mid);
}

/* "+N more" badge */
.wnc-ec-more-badge {
	position: absolute;
	bottom: 6px;
	left: 6px;
	background: rgba(0,0,0,.55);
	color: #fff;
	font-size: .62rem;
	font-weight: 600;
	padding: 2px 7px;
	border-radius: 10px;
	z-index: 3;
	pointer-events: none;
}

/* =========================================================================
   SINGLE EVENT DETAIL PAGE
   ========================================================================= */

.wnc-ec-container {
	max-width: 1060px;
	margin: 0 auto;
	padding: 0 24px;
}

/* ── Hero image ─────────────────────────────────────────────────────── */
.wnc-ec-single-hero {
	position: relative;
	max-height: 480px;
	overflow: hidden;
}
.wnc-ec-single-hero img {
	width: 100%;
	height: 480px;
	object-fit: cover;
	display: block;
}
.wnc-ec-single-hero__overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(to top, rgba(27,67,50,.85) 0%, rgba(27,67,50,.2) 60%, transparent 100%);
	display: flex;
	align-items: flex-end;
}
.wnc-ec-single-hero__inner {
	padding: 32px 36px;
	width: 100%;
	max-width: 1060px;
	margin: 0 auto;
}

/* No-hero title bar */
.wnc-ec-single-titlebar {
	background: linear-gradient(135deg, var(--ec-green-dark), var(--ec-green-mid));
	padding: 40px 0 32px;
}

/* ── Titles ─────────────────────────────────────────────────────────── */
.wnc-ec-back-link {
	display: inline-block;
	color: rgba(255,255,255,.8);
	text-decoration: none;
	font-size: .85rem;
	font-weight: 500;
	margin-bottom: 10px;
	transition: color .15s;
}
.wnc-ec-back-link:hover { color: #fff; }

.wnc-ec-single-title {
	font-size: 2.4rem;
	font-weight: 800;
	color: #fff;
	margin: 0;
	line-height: 1.25;
	letter-spacing: -.5px;
	text-shadow: 0 1px 4px rgba(0,0,0,.3);
}

/* ── Body layout ────────────────────────────────────────────────────── */
.wnc-ec-single-body {
	padding: 40px 24px 60px;
}
.wnc-ec-single-layout {
	display: grid;
	grid-template-columns: 1fr 340px;
	gap: 40px;
	align-items: flex-start;
}
.wnc-ec-single-content {
	font-size: 1.05rem;
	line-height: 1.8;
	color: var(--ec-text);
}
.wnc-ec-single-content p { margin: 0 0 16px; }
.wnc-ec-single-content a { color: var(--ec-green); }

/* ── Sidebar cards ──────────────────────────────────────────────────── */
.wnc-ec-single-sidebar {
	display: flex;
	flex-direction: column;
	gap: 16px;
	position: sticky;
	top: 24px;
}
.wnc-ec-detail-card {
	background: #fff;
	border: 1px solid #ddd;
	border-radius: var(--ec-radius);
	padding: 20px 22px;
	box-shadow: var(--ec-shadow);
}
.wnc-ec-detail-card__heading {
	font-size: .9rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .07em;
	color: var(--ec-green-dark);
	margin: 0 0 14px;
	display: flex;
	align-items: center;
	gap: 7px;
	border-bottom: 2px solid var(--ec-green-pale);
	padding-bottom: 10px;
}
.wnc-ec-detail-row {
	display: flex;
	flex-direction: column;
	gap: 2px;
	margin-bottom: 10px;
}
.wnc-ec-detail-row:last-of-type { margin-bottom: 0; }
.wnc-ec-detail-label {
	font-size: .7rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: var(--ec-green-mid);
}
.wnc-ec-detail-value {
	font-size: .95rem;
	color: var(--ec-text);
	font-weight: 500;
	line-height: 1.5;
}
.wnc-ec-address-text { line-height: 1.6; }

/* ── Map button ─────────────────────────────────────────────────────── */
.wnc-ec-map-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 7px;
	margin-top: 12px;
	padding: 9px 16px;
	background: var(--ec-green-dark);
	color: #fff;
	border-radius: 6px;
	text-decoration: none;
	font-size: .88rem;
	font-weight: 600;
	transition: background .18s, transform .18s;
	width: 100%;
	box-sizing: border-box;
}
.wnc-ec-map-btn:hover { background: var(--ec-green); transform: translateY(-1px); color: #fff; }

/* ── Link buttons ───────────────────────────────────────────────────── */
.wnc-ec-link-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 10px 16px;
	border-radius: 6px;
	text-decoration: none;
	font-size: .88rem;
	font-weight: 600;
	transition: background .18s, transform .18s;
	margin-top: 8px;
	width: 100%;
	box-sizing: border-box;
}
.wnc-ec-link-btn:first-of-type { margin-top: 4px; }
.wnc-ec-link-btn--primary { background: var(--ec-green); color: #fff; }
.wnc-ec-link-btn--primary:hover { background: var(--ec-green-dark); color: #fff; transform: translateY(-1px); }
.wnc-ec-link-btn--secondary { background: var(--ec-green-pale); color: var(--ec-green-dark); border: 1px solid #cce0d4; }
.wnc-ec-link-btn--secondary:hover { background: var(--ec-green-mid); color: #fff; transform: translateY(-1px); }

/* =========================================================================
   EVENTS LIST  [wnc_events_list]
   ========================================================================= */

.wnc-ec-no-events {
	text-align: center;
	color: var(--ec-muted);
	padding: 32px;
	font-style: italic;
}

.wnc-ec-list-wrap {
	display: grid;
	gap: 24px;
	font-family: var(--ec-font);
}
.wnc-ec-list-cols-3 { grid-template-columns: repeat(3, 1fr); }
.wnc-ec-list-cols-2 { grid-template-columns: repeat(2, 1fr); }
.wnc-ec-list-cols-1 { grid-template-columns: 1fr; }

.wnc-ec-list-card {
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: var(--ec-radius);
	overflow: hidden;
	text-decoration: none;
	color: var(--ec-text);
	box-shadow: var(--ec-shadow);
	transition: box-shadow .2s, transform .2s;
}
.wnc-ec-list-card:hover {
	box-shadow: 0 8px 28px rgba(0,0,0,.13);
	transform: translateY(-3px);
	color: var(--ec-text);
}

.wnc-ec-list-card__thumb {
	position: relative;
	overflow: hidden;
	height: 200px;
	background: var(--ec-green-pale);
	flex-shrink: 0;
}
.wnc-ec-list-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform .35s;
}
.wnc-ec-list-card:hover .wnc-ec-list-card__thumb img { transform: scale(1.04); }
.wnc-ec-list-card__no-thumb {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 3rem;
	background: linear-gradient(135deg, var(--ec-green-pale), var(--ec-green-light));
}

.wnc-ec-list-card__date-badge {
	position: absolute;
	top: 12px;
	left: 12px;
	background: var(--ec-green-dark);
	color: #fff;
	border-radius: 6px;
	padding: 6px 10px;
	text-align: center;
	line-height: 1;
	box-shadow: 0 2px 8px rgba(0,0,0,.25);
	min-width: 44px;
}
.wnc-ec-list-card__date-day { display: block; font-size: 1.3rem; font-weight: 800; }
.wnc-ec-list-card__date-mon { display: block; font-size: .65rem; text-transform: uppercase; letter-spacing: .08em; opacity: .85; margin-top: 2px; }

.wnc-ec-list-card__body { padding: 18px 20px 20px; display: flex; flex-direction: column; flex: 1; }
.wnc-ec-list-card__title { font-size: 1.05rem; font-weight: 700; color: var(--ec-green-dark); margin: 0 0 10px; line-height: 1.35; }
.wnc-ec-list-card__meta { font-size: .83rem; color: var(--ec-muted); margin: 0 0 6px; display: flex; align-items: flex-start; gap: 5px; line-height: 1.5; }
.wnc-ec-list-icon { flex-shrink: 0; margin-top: 1px; }
.wnc-ec-list-ends { display: block; margin-left: 18px; font-size: .78rem; color: var(--ec-green-mid); }
.wnc-ec-list-card__excerpt { font-size: .86rem; color: var(--ec-muted); margin: 8px 0 0; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; flex: 1; }
.wnc-ec-list-card__excerpt p { margin: 0; }
.wnc-ec-list-card__cta { display: inline-block; margin-top: 14px; font-size: .82rem; font-weight: 700; color: var(--ec-green); transition: color .15s; }
.wnc-ec-list-card:hover .wnc-ec-list-card__cta { color: var(--ec-green-dark); }

.wnc-ec-list-cols-1 .wnc-ec-list-card { flex-direction: row; }
.wnc-ec-list-cols-1 .wnc-ec-list-card__thumb { width: 260px; height: auto; min-height: 160px; flex-shrink: 0; }

/* =========================================================================
   RESPONSIVE
   ========================================================================= */
@media (max-width: 900px) {
	.wnc-ec-list-cols-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
	.wnc-ec-month-label       { font-size: 1.3rem; }
	.wnc-ec-cell              { min-height: 80px; }
	.wnc-ec-single-layout     { grid-template-columns: 1fr; }
	.wnc-ec-single-sidebar    { position: static; }
	.wnc-ec-single-title      { font-size: 1.7rem; }
}
@media (max-width: 600px) {
	.wnc-ec-list-cols-3,
	.wnc-ec-list-cols-2       { grid-template-columns: 1fr; }
	.wnc-ec-list-cols-1 .wnc-ec-list-card       { flex-direction: column; }
	.wnc-ec-list-cols-1 .wnc-ec-list-card__thumb { width: 100%; height: 180px; }
}
@media (max-width: 480px) {
	.wnc-ec-month-label       { font-size: 1.1rem; }
	.wnc-ec-cell              { min-height: 60px; }
	.wnc-ec-single-hero img   { height: 240px; }
	.wnc-ec-day-names span    { font-size: .6rem; }
}
