/* wrapper for entire post (author, content, comments) */
#cms_post_container {
	
	
}

/* post author */
.cms-post-author {
	
	
}

/* above blog post content directly below author */
.cms-post-info {
    color: grey;
    font-size: 80%;
    font-style: italic;
	margin-bottom: 20px;
    padding-left: 5px;
}

/* post content */
.cms-post-content {
    text-align: justify;
}

/* post rating */
.cms-post-rating {
    cursor: pointer; 
}
.cms-post-social.stars {
    margin-top: 0px;
    margin-bottom: 20px;
    cursor: pointer; 
}
.cms-post-social.stars {
    margin-top: 0px;
    margin-bottom: 20px;
}
.cms-post-social.stars img {
    border-top: solid 1px darkgray;
    display: block;
    margin: 0 auto;
    margin-top: -5px;
    padding-top: 5px;
}
.cms-post-social .cms-post-rating-user {
    align-items: center;  
    aspect-ratio: 1 / 1;
    background-color: white;
    border: 2px solid #666;
    border-radius: 50%;  
    display: flex;
    justify-content: center;
    margin: 0 auto;
    width: 4ch; /* Set this to slightly wider than the longest string */
    position: relative;
    z-index: 2;
}


/* wrapper for both comments header and comments */
#cms_comments_container {
	font-size: 8pt;
	font-size: .75rem;
	/*height: 500px;*/
	padding: 5px;
}

/* wrapper for showing header (with counts and sorting ops) */
#cms_comments_header {
	border-bottom: solid 1px darkgrey; 
	color: grey;
	font-size: 9pt;
	margin-bottom: 10px; 
	margin-top: 10px;
}

#cms_comments_header .cms-comments-sort {
	background-color: transparent; 
	border: none; 
	color: #888888;
}	

/* wrapper for all comments */
#cms_comments {
	/*max-height: 500px;
	overflow-x: hidden;
	overflow-y: scroll;
	position: relative;
	padding-right: 50px;
	padding-top: 1px;
	*/ 
	/* to ensure comments wrap rather than 
	   go past vertical scroller * /
	width: 100%;                  /* 1. Sets the exact wrapping point * /
	white-space: normal;          /* 2. Resets any inherited no-wrap behavior * /
	overflow-wrap: break-word;    /* 3. Forces long, unbroken words to break * /	
	*/
	position: relative;
	/*padding-top: 1px;*/
	
	display: flex;
	flex-direction: column;	
}

/* Base Thread variables configured on the branch wrappers */
.thread-branch {
	--line-color: #cbd5e1;
	position: relative;
}

/* 
* 1. THE CASCADING HOVER FIX
* When you hover ANY wrapper branch, it updates the --line-color variable.
* Because CSS variables cascade downwards, all deeper children instantly 
* inherit this new color matching their parent lines.
*/
.thread-branch:hover {
	--line-color: #3b82f6;
}

/* individual comment */
.cms-comment {
	--line-color: #cbd5e1; 

	/*margin-bottom: 16px;  /* 12px */
	margin-top: 16px;
	padding: 12px;
	background: #f9f9f9;
	border: 1px solid #e0e0e0;
	border-radius: 6px;
	margin-left: calc(var(--depth) * 24px);
	position: relative;
	
	/* Sync the box border to follow the dynamic inherited line color */
	border-color: var(--line-color);
	transition: border-color 0.2s ease;	
}

/* 
 * 1. THE TEXT DIMMING
 * Target the specific content containers inside your card to dim them.
 * This keeps the background card solid but softens text nodes.
 */
.cms-comment {
	opacity: 0.65; /* Dims text slightly for a cleaner, non-intrusive appearance */
	transition: opacity 0.2s ease; /* Fluid shifting animation */
}

/* 
 * 1. DYNAMIC COLOR CHANGE ON HOVER
 * When hovering over a specific comment box, its specific 
 * hierarchy lines immediately pop out.
 */
.cms-comment:hover {
	--line-color: #3b82f6;  /* Modern interactive blue */
	border-color: #bfdbfe;  /* Optional: Lighten card border on hover */
	opacity: 1;
}

/* 2. Generate the vertical lines using a repeating gradient background */
.cms-comment::before {
	content: "";
	position: absolute;
	top: -18px; 				/* - 16px */
	bottom: 0;
	height: calc(100% + 18px);  /* + 16px */
	left: calc(var(--depth) * -24px); 
	width: calc(var(--depth) * 24px); 
	pointer-events: none;

	/* Smooth transition animation for the line color */
	transition: background 0.2s ease;

	/* Creates a 2px vertical line repeating exactly every 24px step */
	background: linear-gradient(
		90deg,
		transparent 0px,
		transparent 10px,
		/*#cbd5e1 10px,
		#cbd5e1 12px,*/
		var(--line-color) 10px,
		var(--line-color) 12px,		
		transparent 12px
	);
	background-size: 24px 100%;

	/* 
	 * 2. THE TRAIL-OFF EFFECT
	 * Uses a CSS linear-gradient mask to fade the vertical line 
	 * smoothly into complete transparency at the bottom edge.
	 * /
	-webkit-mask-image: linear-gradient(
		to bottom, 
		#000000 0%, 
		#000000 75%, 
		transparent 100%
	);
	mask-image: linear-gradient(
		to bottom, 
		#000000 0%, 
		#000000 75%, 
		transparent 100%
	);
	*/	
}

/* 
 * 2. THE L-SHAPED BRANCH CONNECTOR
 * Creates the horizontal branch locking the card to the nearest vertical thread.
 */
.cms-comment::after {
	content: "";
	position: absolute;
	/* Aligns the horizontal connector line to the middle of the card's author/top text */
	top: -16px; 
	
	/*height: 38px; /* Extends down just enough to form the bottom hook of the 'L' */
	height: 32px;
	
	/* Positions the box exactly in the gap between the box edge and the closest thread line */
	left: -14px; 
	width: 14px; 
	pointer-events: none;

	/* Draws the bottom and left edges to mimic a sharp L-bracket */
	border-left: 2px solid var(--line-color);
	border-bottom: 2px solid var(--line-color);

	/* Applies subtle rounding to the corner bend of the L-shape */
	border-bottom-left-radius: 4px;
	transition: border-color 0.2s ease;
}

/* Completely remove the pseudo-element line mask for parent items */
.comment-box[style*="--depth: 0"]::before,
.comment-box[style*="--depth:0"]::before,
.comment-box[style*="--depth: 0"]::after,
.comment-box[style*="--depth:0"]::after {
	border: none !important;
	display: none !important;
}


.cms-comment-author img.hovercard {
	border-radius: 50%;
}

.cms-comment-badge {
	background-color: grey; 
    border-radius: 4px;
	color: white;	
	display: inline;
    font-size: 70%;
	margin-left: 5px;
    padding: 2px;
    text-transform: uppercase;
}
.cms-comment-badge.staff {
	background-color: blue;
}
.cms-comment-social {
    font-style: normal;
	/*margin-bottom: 5px;*/
    margin-top: 10px;
	margin-left: -5px;
	padding-left: 0px;
}
.cms-comment-social .fa-thumbs-up,
.cms-comment-social .fa-thumbs-down {
    color: darkgrey;
    padding: 2px;
}
.cms-comment-social .fa-thumbs-down {
    margin-left: 2px;
}
.cms-comment-social .fa-thumbs-up.selected,
.cms-comment-social .fa-thumbs-down.selected {
    color: black;
}
.cms-comment-social a {
    color: #645d5d !important;
    margin-bottom: 5px;
    /*margin-left: 5px;*/
	/*padding: 2px;*/
    text-decoration: none;    
}

/* adding a new comment */
#cms_add_comment_form {
	margin-top: 20px;
}


/* for loading more comments */
.cms-comments-load {
	color: grey !important;
	display: block;
	margin-top: 10px;
	text-decoration: none;
}
.cms-comments-load:hover {
	text-decoration: underline;
}

/* modal for editing/replying to comments */
.modal-header button.close {
	position: absolute;
	top: 0;
	right: 0;
	padding: 30px;
}
.modal-title {
	font-weight: 700;
}
.cms-modal-avatar {
	float: left;
	margin-right: 5px;
	max-height: 30px;
	max-width: 30px;
}
.cms-modal-in-reply-to {
	display: block;
	font-weight: 400;
	font-size: 80%;
}
.cms-modal-in-reply-to span {
	font-style: italic;
}
.cms-modal-original-comment {
	font-size: 80%;
	font-style: italic;
	font-weight: 400;
	margin-top: 10px;
}
.cms-modal-terms {
	display: inline;
	font-size: 80%;
}