:root {
    --seg-primary: #2C349C;
    --seg-secondary: #007A33;
    --seg-accent-red: #C8102E;
    --seg-accent-yellow: #FFCD00;
    --seg-white: #ffffff;
    --seg-light-gray: #f4f4f4;
    --seg-medium-gray: #dddddd;
    --seg-dark-gray: #333333;
    --seg-text: #222222;
}

/* Load fonts if not already loaded */
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700&family=Montserrat:wght@700&display=swap');

/* Headings use Montserrat */
h1, h2, h3, h4, h5, h6 {
    font-family: "Montserrat", sans-serif;
}

/* Body text uses Manrope */
body, p, span, div, li, a, button, input, textarea, select {
    font-family: "Manrope", sans-serif;
}

.sita-wrapper {
    background: var(--seg-white);
    padding: 20px 20px 30px 20px;
    border-radius: 20px 0px 20px 0px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

/* --- CONTAINER & TYPOGRAPHY --- */
.sita-flex-container {
    font-family: 'Manrope', sans-serif;
    color: var(--seg-text);
    line-height: 1.6;
    margin: 20px auto;
    animation: seg-fade-in 0.3s ease-in-out;
    display: flex; 
    flex-wrap: wrap; 
	justify-content: center;
}

/* H2 Styling */
.sita-flex-container h2 {
    font-size: 48px;
    font-weight: 700;
    line-height: 55px;
}

/* H3 Styling */
.sita-flex-container h3 {
    font-size: 30px;
    font-weight: 700;
    line-height: 38px;
}
.sita-flex-container h3 a {
    font-family: "Montserrat", sans-serif !important;
    color: var(--seg-primary);
}

/* H4 Styling */
.sita-flex-container h4 {
    font-size: 24px;
    font-weight: 700;
    line-height: 28px;
    margin-bottom: 15px;
}

/* Paragraph Styling */
.sita-flex-container p {
    font-size: 18px;
    font-weight: 400;
    line-height: 26px;
}

@media (max-width: 768px) {
    .sita-flex-container h2 { font-size: 40px; line-height: 55px; }
    .sita-flex-container h3 { font-size: 26px; line-height: 32px; }
    .sita-flex-container h4 { font-size: 22px; }
    .sita-flex-container p { font-size: 16px; }
    .sita-flex-container { padding-left: 10px; padding-right: 10px; }
}

/* --- FILTERS --- */
.sita-filters-row {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 30px;
    align-items: center;
    background: #f9f9f9;
    padding: 20px;
    border-radius: 30px 0px 30px;
}

/* Common sizing */
.sita-search-input, 
.sita-custom-select {
    flex: 1;
    min-width: 180px;
    font-size: 14px;
    position: relative; 
}

/* Search Input */
.sita-search-input {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    height: 45px;
    box-sizing: border-box;
}

/* --- CUSTOM DROPDOWN STYLES --- */
.sita-custom-select {
    cursor: pointer;
    user-select: none;
    height: 45px;
}

.sita-select-display {
    background: #fff;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: border-color 0.3s;
	padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.sita-select-display:hover {
    border-color: var(--seg-secondary);
}

.sita-arrow {
    font-size: 10px;
    color: #666;
    transition: transform 0.2s;
}
.sita-arrow.rotated {
    transform: rotate(180deg);
}

.sita-select-options {
    position: absolute;
    top: 105%;
    left: 0;
    width: 100%;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    z-index: 100;
    max-height: 250px;
    overflow-y: auto;
    display: none;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.sita-option {
    padding: 10px 15px;
    color: #333;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s;
}

.sita-option:last-child {
    border-bottom: none;
}

.sita-option:hover {
    background-color: var(--seg-secondary);
    color: #fff;
}

/* Scrollbar for dropdown */
.sita-select-options::-webkit-scrollbar { width: 6px; }
.sita-select-options::-webkit-scrollbar-track { background: #f1f1f1; }
.sita-select-options::-webkit-scrollbar-thumb { background: #ccc; border-radius: 3px; }

/* Reset Button */
.sita-reset-btn {
    padding: 0 20px;
    height: 45px;
    font-weight:700 !important;
    background-color: var(--seg-accent-red);
    color: #fff;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    white-space: nowrap;
}
.sita-reset-btn:hover { background-color: var(--seg-primary); }

/* --- LOADER & LAYOUT --- */
.sita-loader { text-align: center; width: 100%; margin: 20px 0; }
.sita-loader img { width: 60px; height: auto; }

.sita-no-results {
    text-align: center;
    width: 100%;
}

.sita-card {
    background: #fff;
    border: 2px solid var(--seg-secondary);
    border-radius: 42px 0px 42px;
    /* CHANGED: Must be visible to allow ribbon to pop out */
    overflow: visible; 
    position: relative;
    display: flex;
    flex-direction: column;
    margin: 0 15px 30px 15px;
    width: calc(33.333% - 30px);
    box-sizing: border-box;
}

@media (max-width: 992px) { .sita-card { width: calc(50% - 30px); } }
@media (max-width: 600px) { 
    .sita-card { width: 100%; } 
    .sita-filters-row { flex-direction: column; }
    .sita-search-input, .sita-custom-select, .sita-reset-btn { width: 100%; }
}

.sita-load-more-container { text-align: center; margin-top: 20px; margin-bottom: 40px; width: 100%; }
.sita-load-more-btn { background-color: var(--seg-secondary); color: white; padding: 15px 40px; border: none; border-radius: 30px; font-size: 16px; font-weight: 700; cursor: pointer; transition: background 0.3s ease; }
.sita-load-more-btn:hover { background-color: var(--seg-secondary); }

/* --- CARD INTERNALS --- */
.sita-card-header { 
    position: relative; 
    height: 200px; 
    /* CHANGED: Must be visible for ribbon */
    overflow: visible; 
    border-radius: 40px 0px 40px; 
}

.sita-card-header img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    /* Added radius here since we removed overflow:hidden from container */
    border-radius: 40px 0px 40px; 
}

/* --- UPDATED DATE BADGE (3D Pop-out) --- */
.sita-date-badge {
    position: absolute;
    bottom: 20px;
    left: -10px; /* Moves it off the edge */
    background-color: var(--seg-secondary);
    color: #fff;
    padding: 8px 12px;
    text-align: center;
    border-radius: 0 5px 5px 0; /* Rounded right side only */
    min-width: 50px;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.2);
/*     z-index: 10; */
}

/* The Fold (Triangle) behind the ribbon */
.sita-date-badge::before {
    content: '';
    position: absolute;
    top: -10px; /* Height of the fold */
    left: 0;
    width: 0;
    height: 0;
    border-top: 10px solid transparent;
    border-right: 10px solid #004d20; /* Darker green for depth */
}

.sita-day { display: block; font-size: 18px; font-weight: bold; line-height: 1; }
.sita-month { display: block; font-size: 12px; text-transform: uppercase; margin-top: 2px; }

.sita-card-body { padding: 20px; display: flex; flex-direction: column; flex-grow: 1; }
.sita-meta { font-size: 14px; color: #666; margin-bottom: 10px; display: flex; align-items: start; gap: 5px; }

/* --- NEW: TAGS AS BUTTONS --- */
.sita-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 12px;
}

.sita-tag-pill {
    background-color: var(--seg-light-gray);
    color: var(--seg-secondary);
    border: 1px solid var(--seg-secondary);
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 600;
    text-transform: uppercase;
    white-space: nowrap;
}

/* --- NEW: TITLE TRUNCATION (3 Lines) --- */
.sita-title {
    font-size: 18px;
    color: var(--seg-primary);
    margin: 0 0 10px 0;
    line-height: 1.4;
    
    /* Clamp to 3 lines */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sita-excerpt { font-size: 18px; color: var(--seg-dark-gray); margin-bottom: 20px; line-height: 1.6; }
.sita-read-more { margin-top: auto; color: var(--seg-primary); font-weight: bold; text-decoration: underline !important;text-underline-offset: 3px; font-size: 16px; }
.sita-read-more:hover{
    color: var(--seg-secondary)
}
.sita-meta span.dashicons .icon-folder{
    font-size: 18px;
}

a.sita-read-more svg.e-font-icon-svg.e-fas-arrow-right {
    transform: rotate(320deg) !important;
    width: 12px;
    margin-bottom: -2px;
    margin-left: -2px;
    fill: var(--seg-primary) !important;
}

textarea#comment {
    border-radius: 0px 20px 0px 20px !important;
}

.single-blog_post #comments input#submit {
    background: var(--seg-secondary);
    border-radius: 25px;
}

.single-blog_post #comments input#submit:hover {
    background: var(--seg-primary);
}
.single-blog_post comment-reply-title {
    color: var(--e-global-color-6bd8eb0);
    font-family: var(--e-global-typography-b4844b4-font-family), Sans-serif;
    font-size: var(--e-global-typography-b4844b4-font-size);
    font-weight: var(--e-global-typography-b4844b4-font-weight);
    line-height: var(--e-global-typography-b4844b4-line-height);
}

/* --- EVENT FEATURED LAYOUT --- */
.sita-event-featured-wrapper {
    display: flex;
    gap: 30px;
    margin-bottom: 50px;
}

.sita-event-main {
    flex: 2; /* Takes 2/3 width */
    position: relative;
}

.sita-event-side-grid {
    flex: 1; /* Takes 1/3 width */
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Large Card */
.sita-event-large {
    height: 625px;
    background-size: cover;
    background-position: center;
    border-radius: 15px;
    position: relative;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}

.sita-event-large::before {
    content: ''; position: absolute; top:0; left:0; right:0; bottom:0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.8) 100%);
}

.sita-event-large-content {
    position: relative; z-index: 2; padding: 30px; color: #fff;
}

.sita-event-label {
    background: #007f30; padding: 5px 10px; border-radius: 4px; 
    font-size: 12px; font-weight: bold; text-transform: uppercase;
}

.sita-event-large h2 { font-size: 28px; margin: 10px 0; color: #fff; }
.sita-large-meta { margin-bottom: 20px; font-size: 16px; opacity: 0.9; }

.sita-btn-white {
    background: #fff; color: var(--seg-secondary); padding: 10px 20px; text-decoration: none; 
    border-radius: 25px; font-weight: bold; display: inline-block;
}

/* Small Card */
.sita-event-small {
    background: #fff; border: 1px solid #ddd; border-radius: 20px 0px 20px 0px;
    padding: 15px; display: flex; gap: 15px; align-items: center;
}

/* Small Thumb */
.sita-small-thumb {
    width: 70px; height: 70px; flex-shrink: 0; border-radius: 10px 0 10px 0; overflow: hidden;
}
.sita-small-thumb img { width: 100%; height: 100%; object-fit: cover; }

.sita-small-info h4 { margin: 0 0 5px 0; font-size: 14px; }
.sita-small-meta { font-size: 12px; color: #666; display: block; line-height: 1.4; }

/* Responsive Event */
@media (max-width: 768px) {
    .sita-event-featured-wrapper { flex-direction: column; }
    .sita-event-large { height: 300px; }
}

/* --- EVENT FORM --- */
.sita-hs-form-wrapper {
    background: #f9f9f9;
    padding: 35px 30px;
    border-radius: 30px 0px;
    border: 1px solid #eee;
}

.sita-form-group { margin-bottom: 15px; }
.sita-form-group input, .sita-form-group textarea {
    width: 100%; padding: 12px; border: 1px solid #ccc; border-radius: 5px; font-family: inherit;
}
.sita-form-group textarea { height: 100px; }

.sita-submit-btn {
    background: #007f30; color: #fff; padding: 12px 30px; border: none; 
    border-radius: 30px; cursor: pointer; font-size: 16px; font-weight: bold;
}

.webz-event-form .sita-hs-form-wrapper h3 {
    display: none;
}
.webz-event-form .sita-hs-form-wrapper {
    border-radius: 40px 0px 40px 0px;
}
.sita-small-info h4 a {
    color: var(--seg-primary) !important;
	font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
	text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

#sita-event-form input[type="number"], #sita-event-form input[type="text"], #sita-event-form input[type="email"], #sita-event-form .sita-form-group textarea {
    border-radius: 20px;
}

/* --- LOAD MORE SPINNER --- */
.sita-btn-spinner {
    display: inline-block;
    width: 12px; height: 12px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: sita-spin 1s ease-in-out infinite;
    margin-left: 8px;
    vertical-align: middle;
}

@keyframes sita-spin {
    to { transform: rotate(360deg); }
}

/* --- DOCUMENT LIBRARY UPDATES --- */
.sita-doc-nav { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.sita-doc-back { color: var(--seg-secondary); text-decoration: none; font-weight: bold; cursor: pointer; }
.sita-doc-back:hover { text-decoration: underline; }

/* Category Card Updates */
.sita-doc-cat-card {
    background: #fff; border: 1px solid #eee; border-radius: 8px;
    padding: 25px; text-align: center; cursor: pointer; transition: 0.3s;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    min-height: 180px;
}
.sita-doc-cat-card:hover {
    border-color: var(--seg-secondary); transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}
.sita-doc-cat-card .dashicons { font-size: 32px; height: 32px; width: 32px; color: var(--seg-secondary); margin-bottom: 15px; }
.sita-doc-cat-card h3 { margin: 0 0 10px 0; font-size: 20px; color: var(--seg-primary); }
.sita-doc-cat-desc { font-size: 13px; color: #666; margin-bottom: 15px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.sita-doc-cat-count { font-size: 11px; color: #999; text-transform: uppercase; letter-spacing: 1px; font-weight: bold; margin-top: auto; }

/* Article Item Updates */
.sita-doc-item { padding: 20px; background: #fff; border: 1px solid #eee; border-radius: 8px; margin-bottom: 15px; display: flex; flex-direction:column; transition: 0.2s; }
.sita-doc-item:hover { border-color: var(--seg-secondary); box-shadow: 0 5px 15px rgba(0,0,0,0.05); }
.sita-doc-content { flex: 1; padding-right: 20px; }
.sita-doc-item h4 { margin: 0 0 5px 0; font-size: 18px; color: var(--seg-primary); }
.sita-doc-meta { font-size: 12px; color: #999; margin-bottom: 10px; }
.sita-doc-excerpt { font-size: 14px; color: #555; line-height: 1.5; }
.sita-doc-download-btn {
    background: var(--seg-secondary); color: #fff; padding: 12px 20px;
    border-radius: 25px; text-decoration: none; font-size: 16px; font-weight: bold; white-space: nowrap;
}
.sita-doc-download-btn:hover { background: var(--seg-primary); color:#fff; }


.sita-large-excerpt {
    margin-bottom: 30px;
}





/* ... (Keep your Root Variables & Previous Styles) ... */

/* --- DOCUMENT LIBRARY GRID (3 Columns) --- */
.sita-doc-cats-grid { 
    display: grid; 
    grid-template-columns: repeat(3, 1fr); /* 3 cards per row */
    gap: 30px; 
}

/* Category Card */
.sita-doc-cat-card { 
    background: #fff; border: 1px solid #eee; border-radius: 30px 0px;
    padding: 30px 20px; text-align: center; cursor: pointer; transition: 0.3s;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    box-shadow: 0 4px 6px rgba(0,0,0,0.02);
}
.sita-doc-cat-card:hover {
    border-color: var(--seg-secondary); transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}
.sita-doc-cat-card h3, .sita-doc-nav h3 {margin: 15px 0 10px;     color: var(--e-global-color-primary);
    font-family: var(--e-global-typography-ca99605-font-family), Sans-serif;
    font-size: var(--e-global-typography-ca99605-font-size);
    font-weight: var(--e-global-typography-ca99605-font-weight);
    line-height: var(--e-global-typography-ca99605-line-height);}
.sita-doc-cat-desc { font-size: 14px; color: #666; margin-bottom: 15px; line-height: 1.5; }
.sita-doc-cat-count { font-size: 11px; font-weight: 700; color: #2e8b57; text-transform: uppercase; letter-spacing: 1px; margin-top: auto; }

/* Responsive Mobile */
@media (max-width: 768px) {
    .sita-doc-cats-grid { grid-template-columns: repeat(2, 1fr); } /* 1 column on mobile */
}
/* Responsive Mobile */
@media (max-width: 600px) {
    .sita-doc-cats-grid { grid-template-columns: 1fr; } /* 1 column on mobile */
}

/* --- DOCUMENT SEARCH BAR (Improved) --- */
.sita-doc-search-wrapper {
    background: #f9f9f9; padding: 20px; border-radius: 30px 0 30px; 
    display: flex; gap: 10px; margin-bottom: 30px; align-items: center;
}
.sita-doc-search-wrapper input {
    flex: 1; padding: 12px 15px; border: 1px solid #ddd; border-radius: 5px; height: 45px;
}
.sita-doc-search-wrapper button {
    height: 45px; padding: 0 25px; border: none; border-radius: 25px; 
    font-weight: 700; cursor: pointer; color: #fff;
}
#sita-doc-search-btn { background-color: var(--seg-primary); }
#sita-doc-reset-btn { background-color: var(--seg-accent-red); }

/* --- DOCUMENT ACCORDION ITEM --- */
.sita-doc-item {
    background: #fff; border: 1px solid #eee; border-radius: 40px 0px; 
    margin-bottom: 20px; overflow: hidden;
}
.sita-doc-header {
    padding: 20px; cursor: pointer; display: flex; 
    justify-content: space-between; align-items: center;
    transition: background 0.2s;
}
.sita-doc-header:hover { background: #f9f9f9; border-radius: 40px 0px; }

.sita-doc-header h4 { margin: 0; font-size: 20px; color: var(--seg-secondary); }
.sita-doc-arrow { font-size: 30px; color: var(--seg-primary); transition: 0.3s; }
.sita-doc-arrow.rotated { transform: rotate(180deg); }

/* --- DOCUMENT BODY / PREVIEW --- */
.sita-doc-body {
    display: none; /* Hidden by default */
    padding: 20px; border-top: 1px solid #eee; background: #fafafa;
}
.sita-doc-meta { font-size: 14px; color: #777; margin-bottom: 15px; display: block; }
.sita-doc-excerpt { margin-bottom: 20px; color: #444; }

.sita-doc-preview-box {
    background: #fff; border: 1px solid #ddd; padding: 30px 20px; border-radius: 5px;
    text-align: center; margin-top: 15px;
}
.sita-doc-preview-box iframe { width: 100%; height: 500px; border: none; }

.sita-doc-no-file {
    padding: 30px; background: #fff0f0; border: 1px solid #ffcccc; 
    border-radius: 5px; color: #c00; text-align: center;
}
.sita-goto-request {
    display: inline-block; margin-top: 10px; background: var(--seg-accent-red);
    color: #fff; padding: 8px 15px; text-decoration: none; border-radius: 4px; font-size: 13px;
}



.sita-card.sita-is-featured {
    border: 1px solid #006b32; /* Green border for featured cards */
}

.sita-featured-ribbon {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #006b32;
    color: #fff;
    padding: 3px 10px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    border-radius: 4px;
    z-index: 5;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

@media (max-width: 768px) {
	.sita-wrapper {
		padding: 0px 0px 1px !important;
	}
}