/* .card{background:#fff;border-radius:6px;box-shadow:0 1px 3px rgba(0,0,0,.1);padding:1rem;margin-bottom:1rem}.card-header{font-size:1.5rem;font-weight:bold;margin-bottom:.5rem}.card-body{font-size:1rem;line-height:1.5}.card-footer{margin-top:.5rem;text-align:right} */

/* .card{background:#fff;border-radius:6px;box-shadow:0 1px 3px rgba(0,0,0,.1);padding:1rem;margin-bottom:1rem;display:grid;grid-template-rows:auto 1fr auto}.card-header{font-size:1.5rem;font-weight:bold;margin-bottom:.5rem}.card-body{font-size:1rem;line-height:1.5}.card-footer{margin-top:.5rem;text-align:right} */

/* .card{background:#fff;border-radius:6px;box-shadow:0 1px 3px rgba(0,0,0,.1);padding:1rem;margin-bottom:1rem;display:grid;grid-template-rows:auto 1fr auto}.card-header,.card-footer,.card-body{position:relative}.card-img{width:100%;height:100%;object-fit:cover;position:absolute;top:0;left:0}.card-header{font-size:1.5rem;font-weight:bold;margin-bottom:.5rem}.card-body{font-size:1rem;line-height:1.5}.card-footer{margin-top:.5rem;text-align:right} */

/* .card{background:#fff;border-radius:6px;box-shadow:0 1px 3px rgba(0,0,0,.1);padding:1rem;margin-bottom:1rem;display:grid;grid-template-rows:auto 1fr auto}.card-header,.card-footer,.card-body{position:relative}.card-img-background{width:100%;height:100%;background-position:center;background-repeat:no-repeat;background-size:cover;position:absolute;top:0;left:0}.card-img-element{width:100%;object-fit:cover}.card-header{font-size:1.5rem;font-weight:bold;margin-bottom:.5rem}.card-body{font-size:1rem;line-height:1.5}.card-footer{margin-top:.5rem;text-align:right}
.card-header {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.img-wrapper {
    width: 100%;
    overflow: hidden;
}

.card-img {
    width: 100%;
    object-fit: cover;
} */
/* Main card styles */
.card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,.1);
    padding: 1rem;
    margin-bottom: 1rem;
    display: grid;
    grid-template-rows: min-content 1fr auto auto;
    grid-template-areas: "header" "title" "body" "footer";
}

.card-header,
.card-footer,
.card-body,
.card-title {
    position: relative;
}

.card-header {
    grid-area: header;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.card-title {
    grid-area: title;
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.card-body {
    grid-area: body;
    font-size: 1rem;
    line-height: 1.6;
}

.card-body.push-img-top {
    grid-area: unset;
}

.card-footer {
    grid-area: footer;
    margin-top: 0.5rem;
    text-align: right;
}

.img-wrapper {
    width: 100%;
    overflow: hidden;
}

.card-img {
    width: 100%;
    object-fit: cover;
}

/* Dark mode support */
[data-theme="dark"] .card {
    background: #2d3748;
    border-color: #4a5568;
    color: #e0e0e0;
}

[data-theme="dark"] .card-title {
    color: #f1f5f9;
}



.img-wrapper.img-cover {
    height: 200px; /* or whatever height you want */
    overflow: hidden;
}

.img-wrapper.img-cover img {
    height: 100%;
    width: 100%;
    object-fit: cover;
}
.not-truncated {
    margin-bottom:-16px !important;
}

/* ============================================
   FilterBus Integration
   Visibility and transition styles for cards
   subscribing to FilterBus state changes
   ============================================ */

/**
 * Hidden state for FilterBus-controlled cards
 * Uses display:none to collapse grid space
 */
.card.card-filterbus-hidden {
    display: none !important;
}

/**
 * Hide the parent slot-item when card is hidden
 * This collapses the grid cell so remaining cards shift left
 */
.slot-item:has(.card.card-filterbus-hidden) {
    display: none !important;
}

/**
 * Visible state - default
 * Cards are visible by default before FilterBus initializes
 */
.card:not(.card-filterbus-hidden) {
    opacity: 1;
    visibility: visible;
}

/**
 * Transition for initialized cards
 * Only apply transitions after FilterBus is initialized
 * to prevent flash on page load
 */
.card.card-filterbus-initialized {
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/**
 * Reduce motion for accessibility
 * Respects user's motion preferences
 */
@media (prefers-reduced-motion: reduce) {
    .card.card-filterbus-initialized {
        transition: none;
    }
}

/* ============================================
   Date Filter Integration
   Visibility styles for cards filtered by
   date range picker
   ============================================ */

/**
 * Hidden state for date-filtered cards
 * Uses display:none to collapse grid space
 */
.card.card-date-hidden {
    display: none !important;
}

/**
 * Hide the parent slot-item when card is hidden by date filter
 * This collapses the grid cell so remaining cards shift left
 */
.slot-item:has(.card.card-date-hidden) {
    display: none !important;
}
