/* --- Tile Container --- */
.tile-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    justify-content: center;
    margin-top: 40px;
}

/* --- Tile Card --- */
.tile-card {
    background-color: #ffffff;
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.2s ease, background-color 0.2s ease;
    text-align: left;
    width: 100%;
    max-width: 350px;
    height: 440px;               /* Consistent card height */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.main-content-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

.tile-card:hover {
    background-color: #f8f9fa;
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.tile-card img {
    width: 100%;
    height: 250px;               /* Consistent image height */
    object-fit: cover;           /* Crop image to fit nicely */
    border-radius: 12px;
    margin-bottom: 10px;
}
/* --- Tile Header --- */
.tile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tile-title {
    font-size: 18px; /* Nice readable size */
    font-weight: 600; /* Bold enough to stand out */
    color: #023047; /* Deep blue tone */
    white-space: nowrap; /* Prevent line breaks */
    overflow: hidden; /* Hide overflowing text */
    text-overflow: ellipsis; /* Add "..." at the end if text is too long */
}

/* --- Tags --- */
.tile-tags {
    margin: 10px 0;
}

.tile-tag {
    display: inline-block;
    background-color: #e0e0e0;
    border-radius: 8px;
    padding: 2px 8px;
    margin: 2px;
    font-size: 12px;
    color: #333;
}

/* --- Button --- */
.tile-btn {
    background-color: #007bff;
    color: white;
    border-radius: 8px;
    padding: 8px 16px;
    text-decoration: none;
    font-weight: 500;
    margin-top: 10px;
    display: inline-block;
}

.tile-btn:hover {
    background-color: #0056b3;
}

/* --- Help Icon --- */
.help-icon {
    cursor: pointer;
    font-size: 18px;
    color: #555;
    margin-left: 8px;
}

/* --- Modal --- */
.modal-overlay {
    display: none;
    position: fixed;
    z-index: 999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.4);
}

.modal-overlay.active {
    display: block;
    z-index: 999;
}

.modal-image {
    width: 100%;
    max-width: 600px;
    height: 300px;                 /* Fixed height for visual consistency */
    object-fit: contain;          /* Show full image without cropping */
    margin-bottom: 20px;
}

.modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 900px;
    max-height: 90vh;              /* Limit height to viewport */
    overflow-y: auto;              /* Enable scroll if too tall */
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.modal-close {
    position: absolute;
    right: 20px;
    top: 10px;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
}



.tag-container {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag-link {
    padding: 6px 12px;
    background-color: #f2f2f2;
    border-radius: 12px;
    font-size: 14px;
    color: #333;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.tag-link:hover {
    background-color: #ddd;
}


.home-header {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    max-width: 1200px;
    margin: 0 auto 40px;
    padding: 0 16px;
}

.home-title {
    font-size: 38px;
    font-weight: 700;
    margin-bottom: 10px;
    color: #111;
}

.home-description {
    font-size: 16px;
    line-height: 1.6;
    max-width: 800px;
    color: #333;
}





/* Base loader wrapper */
.standard-loader {
    position: relative;
}

/* Center spinner over content */
.standard-loader .dash-spinner {
    display: flex !important;
    align-items: center;
    justify-content: center;
}

/* Optional: dim background while loading */
.standard-loader.dimming {
    background-color: rgba(255, 255, 255, 0.6);
}

/* Control spinner size */
.standard-loader .dash-spinner svg {
    width: 60px;
    height: 60px;
}

/* Optional fullscreen loader */
.standard-loader.fullscreen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background-color: rgba(255, 255, 255, 0.85);
}
