/* --- 全局設置 --- */
:root {
	--bg-paper: #fcfaf2;      /* 鳥之子色 - 米紙背景 */
	--text-main: #2b2b2b;     /* 墨色 */
	--accent-red: #b22c2c;    /* 朱砂 - 點綴紅 */
	--accent-gold: #c7a252;   /* 枯金 - 裝飾金 */
	--accent-blue: #2f4f4f;   /* 鐵御納戶 - 深青灰 */
	--border-color: #dcd6bc;
}

html {
	line-height: 1.15;
	-webkit-text-size-adjust: 100%;
	-webkit-tap-highlight-color: transparent;
	height: 100%
}

body {
	font-family: 'Noto Serif TC', 'SimSun', 'PMingLiU', serif;
	background-color: var(--bg-paper);
	color: var(--text-main);
	/* SVG 背景圖案保持不變 */
	background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23dcd6bc' fill-opacity='0.15' fill-rule='evenodd'/%3E%3C/svg%3E");
}

h1.border-primary, h2.border-primary, h3.border-primary, h4.border-primary, h5.border-primary, h6.border-primary {
	color: var(--accent-blue);
}

.border-primary {
	border-color: var(--accent-blue) !important;
}

.btn-primary {
	background-color: var(--accent-blue);
	color: #fff;
	border: 1px solid var(--accent-blue);
	border-radius: 2px;
	transition: all 0.3s;
}

.btn-primary:hover {
	background-color: var(--bg-paper);
	border: 1px solid var(--accent-blue);
	color: var(--accent-blue);
	text-decoration: none; /* BS4 修復 */
}


.cobox {
	background-color: rgba(255, 255, 255, .75);
	border-radius: .25rem
}





#whatsapptop {
	color: #6c6c6c;
	height: auto;
	position: fixed;
	bottom: 40px;
	right: 40px;
	margin: 0;
	z-index: 10000
}

#whatsapptop>img {
	width: 60px;
	height: 60px;
	line-height: 60px;
	text-decoration: none;
	-o-border-radius: 60px;
	-moz-border-radius: 60px;
	-webkit-border-radius: 60px;
	border-radius: 60px;
	border: 2px solid #fff;
	background-color: #fff;
	box-shadow: 0 0 18px rgba(33, 33, 33, .73);
	text-align: center;
	position: relative;
	display: inline-block
}


/* --- 導航欄 --- */
.navbar {
	background-color: rgba(255, 255, 255, 0.95);
	border-bottom: 3px double var(--accent-gold);
	box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
}

.navbar-brand {
	font-weight: 700;
	font-size: 1.5rem;
	color: var(--accent-blue) !important;
	letter-spacing: 0.1em;
	display: flex;
	align-items: center;
}

/* Logo 圖示樣式 */
.navbar-brand .fa-dharmachakra {
	color: var(--accent-gold); /* 金色法輪 */
	margin-right: 10px;
	font-size: 1.8rem;
	text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.nav-link {
	color: var(--text-main) !important;
	font-weight: 500;
	margin: 0 10px;
	position: relative;
	transition: color 0.3s;
}

.nav-link:hover, .nav-link.active {
	color: var(--accent-red) !important;
}

.nav-link::after {
	content: '';
	position: absolute;
	width: 0;
	height: 2px;
	bottom: 0;
	left: 50%;
	background-color: var(--accent-red);
	transition: all 0.3s ease;
}

.nav-link:hover::after {
	width: 100%;
	left: 0;
}

/* 認證按鈕區樣式 (Login/Logout) */
.auth-divider {
	height: 24px;
	width: 1px;
	background-color: #ddd;
	margin: 0 15px;
	display: none;
}
@media (min-width: 992px) {
	.auth-divider { display: block; }
}

.btn-auth-login {
	color: var(--accent-blue);
	border: 1px solid var(--accent-blue);
	border-radius: 50px; /* 圓潤造型 */
	padding: 5px 20px;
	font-size: 0.9rem;
	transition: all 0.3s;
	margin-right: 10px;
	white-space: nowrap;
}
.btn-auth-login:hover {
	background-color: var(--accent-blue);
	color: #fff;
}

.btn-auth-logout {
	color: #888;
	font-size: 0.9rem;
	text-decoration: none;
	padding: 5px 10px;
	transition: color 0.3s;
	white-space: nowrap;
}
.btn-auth-logout:hover {
	color: var(--accent-red);
}

/* --- Hero Banner --- */
.hero-section {

	position: relative;
	height: 60vh;
	background: linear-gradient(rgba(47, 79, 79, 0.7), rgba(47, 79, 79, 0.3));
	background-size: cover;
	background-position: center;
	display: flex;
	align-items: center;
	justify-content: center;
	border-bottom: 1px solid var(--accent-gold);
	overflow: hidden;
}

.hero-section::before {
	content: "";
	position: absolute;
	top: 10px; left: 10px; right: 10px; bottom: 10px;
	border: 1px solid rgba(255,255,255,0.3);
	pointer-events: none;
}

.hero-content {
	text-align: center;
	color: white;
	padding: 3rem;
	background: rgba(0, 0, 0, 0.4);
	border: 1px solid rgba(199, 162, 82, 0.5);
	backdrop-filter: blur(2px);
	box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.hero-title {
	font-size: 3rem;
	margin-bottom: 1rem;
	letter-spacing: 0.2em;
	text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.hero-subtitle {
	font-size: 1.2rem;
	font-weight: 300;
	letter-spacing: 0.3em;
	border-top: 1px solid var(--accent-gold);
	padding-top: 1rem;
	display: inline-block;
}

.vertical-text-decor {
	position: absolute;
	right: 5%;
	top: 15%;
	writing-mode: vertical-rl;
	text-orientation: upright;
	color: rgba(255,255,255,0.8);
	font-size: 1.5rem;
	font-weight: 300;
	letter-spacing: 0.5em;
	border-right: 1px solid var(--accent-gold);
	padding-right: 15px;
	display: none; 
    white-space: nowrap;
}

@media (min-width: 992px) {
	.vertical-text-decor { display: block; }
}

/* --- 內容區域 --- */
.section-header {
	text-align: center;
	margin: 4rem 0 3rem 0;
	position: relative;
}

.section-header h2 {
	font-size: 2rem;
	color: var(--accent-blue);
	display: inline-block;
	padding: 0 2rem;
	position: relative;
}

.section-header h2::before,
.section-header h2::after {
	content: "✦";
	color: var(--accent-gold);
	font-size: 1.2rem;
	vertical-align: top;
	margin: 0 15px;
	line-height: 2.4rem;
}

/* --- 法會卡片 --- */
.event-card {
	border: none;
	background-color: #fff;
	border-radius: 4px;
	overflow: hidden;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
	box-shadow: 0 2px 10px rgba(0,0,0,0.05);
	border-top: 4px solid var(--accent-blue); 
	height: 100%;
	display: flex;
	flex-direction: column;
}

.event-card:hover {
	transform: translateY(-5px);
	box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.card-body {
	padding: 2rem;
	display: flex;
	flex-direction: column;
	flex-grow: 1;
	background-image: linear-gradient(to bottom, #fff 0%, #fcfcfc 100%);
}

@media (max-width:768px){
	.card-body {
		padding: 1rem;
	}
}

.event-date {
	font-size: 0.9rem;
	color: var(--accent-red);
	font-weight: 700;
	margin-top: 0.5rem;
	letter-spacing: 0.1em;
	border-bottom: 1px solid var(--border-color);
	padding-bottom: 0.5rem;
	display: inline-block;
}

.event-title {
	font-size: 1.5rem;
	margin: 1rem 0;
	color: var(--text-main);
	font-weight: 700;
	line-height: 1.4;
}

.event-desc {
	color: #666;
	font-size: 0.95rem;
	line-height: 1.8;
	margin-bottom: 1.5rem;
	flex-grow: 1;
}

.btn-register {
	background-color: var(--accent-blue);
	color: #fff;
	border: 1px solid var(--accent-blue);
	border-radius: 2px;
	padding: 10px 20px;
	letter-spacing: 0.1em;
	transition: all 0.3s;
	width: 100%;
	text-align: center;
}

.btn-register:hover {
	background-color: var(--bg-paper);
	color: var(--accent-blue);
	text-decoration: none; /* BS4 修復 */
}

/* 狀態標籤 */
.status-badge {
	font-size: 0.8rem;
	padding: 4px 8px;
	border-radius: 2px;
	margin-left: 10px;
	vertical-align: middle;
}
.status-open { background-color: rgba(46, 139, 87, 0.1); color: seagreen; border: 1px solid seagreen; }
.status-full { background-color: rgba(178, 44, 44, 0.1); color: var(--accent-red); border: 1px solid var(--accent-red); }

/* --- Footer --- */
footer {
	background-color: var(--accent-blue);
	color: rgba(255,255,255,0.7);
	padding: 3rem 0;
	margin-top: 5rem;
	text-align: center;
	border-top: 4px solid var(--accent-gold);
}

footer h5 {
	color: #fff;
	margin-bottom: 1rem;
	font-weight: 500;
	letter-spacing: 0.1em;
}

.lotus-icon {
	width: 40px;
	height: 40px;
	margin-bottom: 1rem;
	opacity: 0.8;
}

/* BS4 Helper classes replacement if needed */
.opacity-50 {
	opacity: 0.5;
}




.pagination {
	display: inline-block;
	padding-left: 0;
	margin: 20px 0;
	border-radius: 4px;
}

.pagination > li {
	display: inline;
}

.pagination > li > a, 
.pagination > li > span {
position: relative;
float: left;
padding: 6px 12px;
margin-left: -1px;
line-height: 1.42857143;
color: #f36ea7;
text-decoration: none;
background-color: #fff;
border: 1px solid #ddd;
}

@media screen and (max-width: 600px) {
.pagination > li > a, 
.pagination > li > span {
	padding: 5px 10px;
	font-size: 12px;
	line-height: 1.5;
}
}

.pagination > li:first-child > a, 
.pagination > li:first-child > span {
margin-left: 0;
border-top-left-radius: 4px;
border-bottom-left-radius: 4px;
}

.pagination > li:last-child > a,
.pagination > li:last-child > span {
border-top-right-radius: 4px;
border-bottom-right-radius: 4px;
}

@media screen and (max-width: 600px) {
.pagination > li:first-child > a, 
.pagination > li:first-child > span {
border-top-left-radius: 3px;
border-bottom-left-radius: 3px;
}

.pagination>li:last-child>a, 
.pagination>li:last-child>span {
border-top-right-radius: 3px;
border-bottom-right-radius: 3px;
}

.pagination > li > a, 
.pagination > li > span {
padding: 5px 10px;
font-size: 12px;
line-height: 1.5;
}
}

.pagination>li>a:focus, 
.pagination>li>a:hover, 
.pagination>li>span:focus, 
.pagination>li>span:hover {
z-index: 2;
color: #f36ea7;
background-color: #eee;
border-color: #ddd;
}

.pagination>.active>a,
.pagination>.active>a:focus, 
.pagination>.active>a:hover, 
.pagination>.active>span, 
.pagination>.active>span:focus, 
.pagination>.active>span:hover {
z-index: 3;
color: #fff;
cursor: default;
background-color: #f36ea7;
border-color: #f36ea7;
}

.pagination > .disabled > a, 
.pagination>.disabled>a:focus, 
.pagination>.disabled>a:hover, 
.pagination>.disabled>span, 
.pagination>.disabled>span:focus, 
.pagination>.disabled>span:hover {
color: #777;
cursor: not-allowed;
background-color: #fff;
border-color: #ddd;
}


.form-required {
	color: #cd201f;
}

  .form-fieldset {
	background: #f8f9fa;
	border: 1px solid #e9ecef;
	padding: 0.5rem;
	border-radius: 3px;
	margin-bottom: 1rem;
	}



	.selectgroup {
		display: -ms-inline-flexbox;
		display: inline-flex;
	  }
	  
	  .selectgroup-item {
		-ms-flex-positive: 1;
		flex-grow: 1;
		position: relative;
	  }
	  
	  .selectgroup-item + .selectgroup-item {
		margin-left: -1px;
	  }
	  
	  .selectgroup-item:not(:first-child) .selectgroup-button {
		border-top-left-radius: 0;
		border-bottom-left-radius: 0;
	  }
	  
	  .selectgroup-item:not(:last-child) .selectgroup-button {
		border-top-right-radius: 0;
		border-bottom-right-radius: 0;
	  }
	  
	  .selectgroup-input {
		opacity: 0;
		position: absolute;
		z-index: -1;
		top: 0;
		left: 0;
	  }
	  
	  .selectgroup-button {
		display: block;
		border: 1px solid rgba(0, 40, 100, 0.12);
		text-align: center;
		padding: 0.375rem 1rem;
		position: relative;
		cursor: pointer;
		border-radius: 3px;
		color: #9aa0ac;
		-webkit-user-select: none;
		-moz-user-select: none;
		-ms-user-select: none;
		user-select: none;
		font-size: 0.9375rem;
		line-height: 1.5rem;
		min-width: 2.375rem;
		background-color: white;
	  }

	  .selectgroup-input:checked + .selectgroup-button {
		border-color: #8c4529;
		z-index: 1;
		color: #8c4529;
		background: #fed3ca;
	  }
	  
	  .selectgroup-input:focus + .selectgroup-button {
		border-color: #8c4529;
		z-index: 2;
		color: #8c4529;
		box-shadow: 0 0 0 2px rgba(70, 127, 207, 0.25);
	  }
	  



.detailBody .card-header {
	background: none;
	padding: 0.5rem 1.5rem;
	display: -ms-flexbox;
	display: flex;
	min-height: 3.5rem;
	-ms-flex-align: center;
	align-items: center;
}

.detailBody .card-header .card-title {
	margin-bottom: 0;
}

.detailBody .card-title:only-child {
	margin-bottom: 0;
}

.detailBody .card-title {
	font-size: 1.125rem;
	line-height: 1.2;
	font-weight: 400;
	margin-bottom: 1.5rem;
}


/*
lozad animations
*/

.lozad{
  opacity: 0;
}

.lozadloaded {
	min-height: auto !important;
  opacity: 1;
  -webkit-transition: all 0.6s;
     -moz-transition: all 0.6s;
      -ms-transition: all 0.6s;
       -o-transition: all 0.6s;
          transition: all 0.6s;
}