/* Blogs Listing & Details Styles */

.blogs-page-wrapper {
    padding: 80px 0;
}

.blogs-container {
    display: grid;
    grid-template-columns: minmax(0, 8fr) minmax(0, 4fr);
    gap: 40px;
}

.blogs-container.no-sidebar {
    grid-template-columns: 1fr;
}

/* --- Main Listing & Teasers --- */
.blog-listing-items {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.blog-teaser-card {
    background: #F5F5F5;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.03);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px;
}

.blog-teaser-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08);
}

.blog-teaser-image {
    width: 100%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    position: relative;
}

.blog-teaser-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.blog-teaser-card:hover .blog-teaser-image img {
    transform: scale(1.08);
}

.blog-teaser-content-wrapper {
    padding: 30px 45px 0px 40px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.blog-teaser-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #7c7e9c;
    font-weight: 500;
    padding-left: 4px;
}

.meta-item svg {
    color: #0080FF;
}

.blog-teaser-title {
    font-size: 24px !important;
    font-weight: 700 !important;
    line-height: 1.3 !important;
    margin-bottom: 20px !important;
    margin-top: 0 !important;
}

.blog-teaser-title a {
    color: #0c1e33;
    text-decoration: none;
    transition: color 0.3s ease;
}

.blog-teaser-title a:hover {
    color: #0080FF;
}

.blog-teaser-summary {
    font-size: 16px;
    color: #7c7e9c;
    line-height: 1.7;
    margin-bottom: 30px;
    flex-grow: 1;
}

.blog-teaser-footer {
    margin-top: auto;
}

.read-more-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #0080FF;
    font-weight: 700;
    text-decoration: none;
    font-size: 15px;
    transition: gap 0.3s ease;
}

.read-more-link:hover {
    gap: 10px;
}

.read-more-icon {
    font-size: 18px;
    line-height: 1;
}

/* --- Sidebar Styles --- */
.sidebar-wrapper {
    display: flex;
    flex-direction: column;
    gap: 30px;
}
.sidebar-wrapper .field--name-field-side-bar-blocks > .field__item{
    margin-bottom: 20px;
}
.sidebar-listing-wrapper .field--name-field-side-bar-blocks > .field__item{
    margin-bottom: 3rem;
}

.sidebar-block {
    background: #fff;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
    border: 1px solid #f1f5f9;
}

.sidebar-block-title {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #3b82f633;
    position: relative;
}

.sidebar-block-title::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 40px;
    height: 2px;
    background: #3b82f6;
}

/* Search Widget Styling (Supporting standard Drupal structure) */
.search-block-form form {
    align-items: center;
    border: 1px solid #e2e8f0;
    border-radius: 50px;
    padding: 2px 5px 2px 5px;
    background: #fff;
    transition: all 0.3s ease;
    overflow: hidden;
    justify-content: space-between;
    width: 100%;
    margin: auto;
}

/* Container focus effect when input is focused */
.search-block-form form:focus-within {
    border-color: #3b82f6;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

.search-widget input[type="text"],
.search-widget input[type="search"],
.search-block-form input[type="text"],
.search-block-form .form-search {
    flex: 1;
    padding: 12px 20px;
    border: none !important;
    border-radius: 50px 0 0 50px;
    outline: none !important;
    font-size: 15px;
    background: transparent !important;
    color: #1e293b;
    box-shadow: none !important;
}

.search-widget input::placeholder,
.search-block-form input::placeholder {
    color: #525672;
    opacity: 1; /* Ensure opacity is full on all browsers */
}

.search-widget button,
.search-widget input[type="submit"],
.search-block-form button,
.search-block-form .form-submit {
    background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23334155' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E") no-repeat center !important;
    color: transparent !important;
    border: none;
    width: 50px;
    height: 44px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-indent: -9999px;
    flex-shrink: 0;
    padding: 0;
    border-radius: 0 50px 50px 0;
}

.search-widget button:hover,
.search-block-form .form-submit:hover {
    transform: scale(1.1);
    background-color: rgba(59, 130, 246, 0.05) !important;
}

/* Category Widget */
.category-list {
    list-style: none;
    padding: 0;
    margin-bottom: 0;
}

.category-list li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f1f5f9;
}

.category-list li:last-child {
    border-bottom: none;
}

.category-list a {
    color: #475569;
    text-decoration: none;
    transition: color 0.2s;
}

.category-list a:hover {
    color: #3b82f6;
}

.category-count {
    background: #f1f5f9;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 12px;
    color: #64748b;
}

/* Recent Posts Widget */
.recent-post-item {
    display: flex;
    gap: 15px;
    margin-bottom: 2rem;
}

.recent-post-thumb {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.recent-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recent-post-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.recent-post-info h4 {
    font-size: 16px;
    margin: 0;
    line-height: 1.25;
    margin-top: 9px;
    padding-right: 4rem;
}

.recent-post-info a {
    color: #0c1e33; /* Dark Navy from Figma */
    text-decoration: none;
    transition: color 0.2s ease;
}

.recent-post-info a:hover {
    color: #3b82f6;
}

.recent-post-date {
    font-size: 13px;
    color: #7c7e9c; /* Soft purple-grey from Figma */
    font-weight: 500;
}

/* Tag Cloud Widget */
.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-cloud a {
    background: #f1f5f9;
    color: #64748b;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.2s;
}

.tag-cloud a:hover {
    background: #3b82f6;
    color: #fff;
}

/* --- Blog Details Specific --- */
.blog-details-header {
    text-align: center;
    margin-bottom: 50px;
}

.blog-details-image {
    width: 100%;
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 40px;
}

.blog-post-body {
    font-size: 18px;
    line-height: 1.8;
    color: #334155;
    word-break: break-word; /* Prevent long words from breaking layout */
}

.blog-post-body img {
    max-width: 100%;
    height: auto;
}

.blog-hero-full-width {
    width: 100%;
    margin-bottom: 60px;
}

.blog-hero-full-width img {
    width: 100%;
    height: auto;
}

/* Drop Cap */
.has-drop-cap p:first-of-type::first-letter,
.has-drop-cap .field__item > p:first-child::first-letter,
.has-drop-cap::first-letter {
    float: left !important;
    font-size: 80px !important;
    line-height: 1 !important;
    padding-top: 4px !important;
    padding-right: 20px !important;
    padding-left: 5px !important;
    font-weight: 700 !important;
    color: #3b82f6 !important;
    text-transform: uppercase !important;
    display: block !important;
}

/* Image Grid Paragraph */
.blog-image-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 40px 0;
}

.blog-image-grid img {
    width: 100%;
    border-radius: 12px;
}

/* Wide Image Paragraph */
.blog-wide-image {
    width: 100%;
    margin-bottom: 40px;
}

.blog-wide-image img {
    width: 100%;
    height: auto;
    border-radius: 16px;
}
.page-node-type-blog-post .container {
  width: 95%;
}
.view-related-blogs .view-header{
    margin-bottom: 25px;
}
.view-blog-categories .view-header h3{
    font-size: 32px;
    font-weight: 500;
    color: #0A0A0A;
    margin-bottom: 25px;
}
.view-blog-categories .view-content{
    background-color: #F0F2F4;
    border-radius: 21px;
    width: 83%;
}
.view-blog-categories .category-list-wrapper{
    width: 82%;
    margin: auto;
    padding: 1rem 0px;
}

/* Popular Tags Block */
.view-popular-tags .view-header h3 {
    font-size: 32px;
    font-weight: 500;
    color: #0A0A0A;
    margin-bottom: 25px;
}

.view-popular-tags .view-content {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.view-popular-tags .tag-cloud-item a,
.view-popular-tags .tag-cloud-item span,
.view-popular-tags .tag-cloud-item .views-field-name {
    display: inline-block;
    border: 1px solid #c8cdd5;
    border-radius: 50px;
    padding: 7px 20px;
    font-size: 14px;
    color: #525672;
    text-decoration: none;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.view-popular-tags .tag-cloud-item .views-field-name:hover,
.view-popular-tags .tag-cloud-item a:hover {
    background-color: #3b82f6;
    border-color: #3b82f6;
    color: #fff;
}

/* Social Media Icons Paragraph */
.social-media-icons-list .social-icons-wrapper {
    display: flex;
    gap: 15px;
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.social-icon-inner {
    background-color: #3b82f6;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.social-icon-inner:hover {
    background-color: #2563eb;
    transform: translateY(-3px);
}

.social-icon-inner img,
.social-icon-inner svg {
    width: 20px;
    height: 20px;
    fill: #ffffff;
    filter: brightness(0) invert(1); /* Force white color for standard images if needed */
}
.field--name-field-social-icons-list{
    display: flex;
    gap: 20px;
}

/* Comments Section & 'Leave a Reply' Form */
.blog-post-comments {
    border-top: 1px solid #6966871A;
    margin-top: 3rem;
    padding-top: 2rem;
    margin-bottom: 3rem;
}

.blog-post-comments h2 {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 15px;
    text-transform: none;
}

.blog-post-comments .comment-form-help-text {
    font-size: 14px;
    color: #666;
    margin-bottom: 30px;
}

#comment-form {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
}

#comment-form .form-item {
    margin-bottom: 0px;
    flex: 1 1 100%;
    margin-top: 0;
}

#comment-form > .form-item:not(.form-type-checkbox) {
    display: flex;
    flex-direction: column-reverse;
}

#comment-form .form-item-name,
#comment-form .form-item-mail {
    flex: 1 1 calc(50% - 15px);
}

#comment-form label {
    font-size: 14px;
    color: #525672;
    margin-bottom: 8px;
    font-weight: 400;
}

#comment-form input:not([type="checkbox"]),
#comment-form textarea {
    border: none;
    border-bottom: 1px solid #dcdcdc;
    padding: 12px 0;
    background: transparent;
    border-radius: 0;
    font-size: 16px;
    color: #1a1a1a;
    transition: all 0.3s ease;
}

#comment-form input:focus,
#comment-form textarea:focus {
    outline: none;
    border-bottom-color: #3b82f6;
}

#comment-form textarea {
    min-height: 120px;
}

#comment-form .form-type-checkbox {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: -10px;
    padding-left: 0;
}

#comment-form .form-type-checkbox input {
    margin: 0;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

#comment-form .form-type-checkbox label {
    font-size: 14px;
    color: #525672;
    cursor: pointer;
    margin-bottom: 0;
}

#comment-form .form-actions {
    width: 100%;
    margin-top: 0px;
}


.field--name-comment-body{
    width: 100%;
}
.field--type-language.field--name-langcode{
    display: none;
}


#comment-form .form-submit {
    background: linear-gradient(90deg, #0080FF 0%, #2b4d91 100%) !important;
    color: #fff !important;
    border-radius: 50px !important;
    padding: 15px 18px !important;
    font-size: 12px !important;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease !important;
    width: auto;
    font-weight: 600;
}

#comment-form .form-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.blog-post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 4rem;
    margin-bottom: 3rem;
}
.blog-tag-item {
    display: inline-block;
    background-color: #6254E70A;
    border: 1px solid #6966871A;
    border-radius: 50px;
    padding: 6px 20px;
    font-size: 14px;
    color: #525672;
    font-weight: 500;
    transition: all 0.3s ease;
}


/* --- Content Listing Page Node Specific --- */
.content-listing-page .header-banner-area {
    margin-bottom: 0px;
}

.content-listing-page .blogs-page-wrapper {
    padding-top: 60px;
}

.content-listing-page .bottom-sections-area {
    margin-top: 60px;
}
.block-search > form{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}


/* --- Categories Sidebar Block (Isolated) --- */
.view-blog-categories-listing ul.category-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.view-blog-categories-listing ul.category-list li {
    padding: 15px 0;
    border-bottom: 1px solid #E5E7EB;
    transition: all 0.3s ease;
}

.view-blog-categories-listing ul.category-list li:last-child {
    border-bottom: none;
}

.view-blog-categories-listing ul.category-list li .views-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
}

.view-blog-categories-listing ul.category-list li a {
    color: #1a1a1a;
    font-weight: 500;
    font-size: 1rem;
    text-decoration: none;
    transition: color 0.3s ease;
}

.view-blog-categories-listing ul.category-list li a:hover {
    color: #6e62e5;
}

.view-blog-categories-listing ul li .views-field-name span {
    color: #0A0A0A;
    font-weight: 600;
    font-size: 16px;
}

.view-blog-categories-listing ul.category-list li .views-field-nid {
    color: #1a1a1a;
    font-weight: 600;
    font-size: 0.95rem;
}
[class*="block-views-blockblog-categories-listing-block"] h2,
.block-search h2 {
    font-size: 20px;
    font-weight: 700;
    color: #0A0A0A;
    margin-bottom: 25px;
}

/* --- Recent Posts Sidebar Block (Vertical) --- */
.view-recent-blog-posts-sidebar ul.recent-posts-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.view-recent-blog-posts-sidebar ul.recent-posts-list li {
    margin-bottom: 40px;
    padding: 0;
}

.view-recent-blog-posts-sidebar ul.recent-posts-list li:last-child {
    margin-bottom: 0;
}

.view-recent-blog-posts-sidebar .views-field-field-featured-image {
    margin-bottom: 15px;
}

.view-recent-blog-posts-sidebar .views-field-field-featured-image img {
    width: 100%;
    height: 130px;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.view-recent-blog-posts-sidebar .views-row-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 10px;
}

.view-recent-blog-posts-sidebar .views-field-created,
.view-recent-blog-posts-sidebar .views-field-uid {
    font-size: 14px;
    color: #525672;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Base styles for the icons if not using font-awesome */
.view-recent-blog-posts-sidebar .views-field-created::before {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%233b82f6' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z' /%3E%3C/svg%3E");
    background-repeat: no-repeat;
}

.view-recent-blog-posts-sidebar .views-field-uid::before {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%233b82f6' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z' /%3E%3C/svg%3E");
    background-repeat: no-repeat;
}

.view-recent-blog-posts-sidebar .views-field-title a {
    font-size: 18px;
    font-weight: 600;
    color: #0A0A0A;
    line-height: 1.4;
    text-decoration: none;
    transition: color 0.3s ease;
}

.view-recent-blog-posts-sidebar .views-field-title a:hover {
    color: #0080FF;
}

/* Specific Block padding adjustments */
.sidebar-listing-wrapper [class*="block-views-blockrecent-blog-posts-sidebar-block"] {
    margin-top: 2rem;
}
[class*="block-views-blockrecent-blog-posts-sidebar-block"] h2{
    font-size: 20px;
    font-weight: 700;
    color: #0A0A0A;
    margin-bottom: 25px;
}
.sidebar-listing-wrapper{
    background-color: #F5F5F5;
    padding: 2rem 2rem;
    border-radius: 15px;
    height: 91rem;
}
.view-blogs-listing .view-content .views-row{
    margin-bottom: 3rem;
}
.sidebar-listing-wrapper .view-popular-tags .tag-cloud-item .views-field-name{
    background: #30A3FF;
    color: #fff; 
}
.view-popular-tags .tag-cloud-item .views-field-name:hover{
    background: #30A3FF;
}
.sidebar-listing-wrapper .view-popular-tags .view-header h3{
    font-size: 20px;
    font-weight: 700;
}