@import url('https://fonts.googleapis.com/css2?family=Google+Sans:wght@400;500;700&display=swap');

body {
    font-family: 'Google Sans', sans-serif;
    background-color: #202124;
    color: #e8eaed;
    margin: 0;
    padding: 2rem;
    text-align: center;
}

header {
    margin-bottom: 3rem;
}

h1 {
    font-size: 3rem;
    font-weight: 700;
    color: #8ab4f8;
    margin-bottom: 0.5rem;
}

#idea-count {
    color: #9aa0a6;
    margin-top: -1rem;
    margin-bottom: 1.5rem;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

#search-input {
    width: 100%;
    max-width: 400px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    border: 1px solid #5f6368;
    border-radius: 24px;
    margin-top: 1.5rem;
    font-family: 'Google Sans', sans-serif;
    background-color: #303134;
    color: #e8eaed;
}

#search-input:focus {
    outline: none;
    border-color: #8ab4f8;
    box-shadow: 0 0 0 2px rgba(138, 180, 248, 0.2);
}

#filter-container {
    margin-top: 1.5rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.filter-btn {
    background-color: #303134;
    border: 1px solid #5f6368;
    color: #e8eaed;
    border-radius: 16px;
    padding: 0.5rem 1rem;
    font-family: 'Google Sans', sans-serif;
    font-size: 0.875rem;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.filter-btn:hover {
    background-color: #3c4043;
}

.filter-btn.active {
    background-color: #8ab4f8;
    color: #202124;
    border-color: #8ab4f8;
}

main {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.card {
    background-color: #303134;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.3), 0 2px 6px rgba(0,0,0,0.15);
    padding: 1.5rem;
    text-align: left;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    border-left: 4px solid #5f6368; /* Default border */
}

/* Category-specific border colors */
.category-logistics { border-left-color: #4285F4; } /* Blue */
.category-education { border-left-color: #34A853; } /* Green */
.category-finance { border-left-color: #FBBC04; } /* Yellow */
.category-lifestyle { border-left-color: #EA4335; } /* Red */
.category-productivity { border-left-color: #9AA0A6; } /* Gray */
.category-utilities { border-left-color: #A142F4; } /* Purple */
.category-health { border-left-color: #24C1E0; } /* Cyan */
.category-developer-tools { border-left-color: #FF6D01; } /* Orange */
.category-e-commerce { border-left-color: #137333; } /* Dark Green */

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3), 0 8px 16px rgba(0,0,0,0.15);
}


.card h2 {
    font-size: 1.5rem;
    margin-top: 0;
    margin-bottom: 0.5rem;
    color: #e8eaed;
}

.card .abstract {
    font-style: italic;
    margin-bottom: 1rem;
    color: #bdc1c6;
}

.card .category-tag {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    background-color: #3c4043;
    color: #e8eaed;
    display: inline-block;
    margin-bottom: 1rem;
}

.card .info {
    font-size: 0.875rem;
    color: #9aa0a6;
    margin-bottom: 1rem;
}

.card .links {
    margin-top: 1.5rem;
    display: flex;
    justify-content: space-between;
}

.card a {
    text-decoration: none;
    color: #8ab4f8;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border: 1px solid #5f6368;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.card a:hover {
    background-color: #3c4043;
}

#status-log {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 1rem;
    background-color: #303134;
    border: 1px solid #5f6368;
    border-radius: 8px;
    text-align: left;
    font-family: monospace;
    white-space: pre-wrap;
    box-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

footer {
    margin-top: 4rem;
    color: #9aa0a6;
}

@media (max-width: 600px) {
    body {
        padding: 1rem;
    }

    h1 {
        font-size: 2.5rem;
    }

    main {
        grid-template-columns: 1fr;
    }
}

.timeline-container {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 0 1rem;
}

.timeline-container h3 {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 500;
    color: #e8eaed;
    margin-bottom: 1rem;
}

.timeline-bar {
    width: 100%;
    height: 8px;
    background-color: #5f6368;
    border-radius: 4px;
    position: relative;
}

#timeline-events {
    position: relative;
    height: 100%;
}

.timeline-dot {
    position: absolute;
    width: 16px;
    height: 16px;
    background-color: #8ab4f8; /* Default color */
    border-radius: 50%;
    transform: translateX(-50%);
    top: -4px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.timeline-dot.today {
    background-color: #8ab4f8; /* Blue */
}

.timeline-dot.past {
    background-color: #f28b82; /* Red */
}

.timeline-dot.future {
    background-color: #fdd663; /* Yellow */
}

.timeline-dot:hover {
    transform: translateX(-50%) scale(1.2);
}

.timeline-dot .tooltip {
    visibility: hidden;
    width: 220px;
    background-color: #5f6368;
    color: #e8eaed;
    text-align: center;
    border-radius: 6px;
    padding: 8px;
    position: absolute;
    z-index: 1;
    bottom: 170%;
    left: 50%;
    margin-left: -110px;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.timeline-dot .tooltip::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: #5f6368 transparent transparent transparent;
}

.timeline-dot:hover .tooltip {
    visibility: visible;
    opacity: 1;
}

.timeline-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    color: #9aa0a6;
    font-size: 0.875rem;
}

#event-selector-container {
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
    gap: 1rem;
    align-items: center;
}

#event-selector-container h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 500;
    color: #e8eaed;
}

.event-btn {
    text-decoration: none;
    background-color: #303134;
    border: 1px solid #5f6368;
    border-radius: 16px;
    padding: 0.5rem 1rem;
    font-family: 'Google Sans', sans-serif;
    font-size: 0.875rem;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
    color: #e8eaed;
}

.event-btn:hover {
    background-color: #3c4043;
}

.event-btn.active {
    background-color: #8ab4f8;
    color: #202124;
    border-color: #8ab4f8;
    font-weight: 700;
}

#multi-day-timeline-labels {
    position: relative;
    height: 20px;
}

.card-img {
    width: calc(100% - 8px); /* Adjust width for padding */
    height: auto;
    margin-top: 1rem;
    border-radius: 8px;
    padding: 4px;
    background-color: #3c4043;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05), 0 8px 24px rgba(161, 66, 244, 0.15), 0 2px 8px rgba(26, 115, 232, 0.15);
}
