body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    font-family: Arial, sans-serif;
    background: #1e1e1e;
}
.container {
    text-align: center;
    max-width: 600px;
    padding: 20px;
}

h1 {
    font-size: 22px;
    color: #f5f5f5;
}

button {
    padding: 18px 30px;
    font-size: 20px;
    border: none;
    border-radius: 10px;
    background: #3366cc;
    color: white;
    cursor: pointer;
}

button:hover {
    background: #2855a8;
}

button:disabled {
    background: #99aedd;
    cursor: default;
}

#result {
    margin-top: 30px;
    text-align: left;
    background: #2b2b2b;
    color: #f5f5f5;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

#result img {
    max-width: 100%;
    border-radius: 6px;
    margin-bottom: 12px;
}

#articleLink {
    color: #7fa5e6;
    text-decoration: none;
    font-weight: bold;
}

#articleLink:hover {
    text-decoration: underline;
}

.hidden {
    display: none;
}

select {
    padding: 10px;
    border-radius: 8px;
    border: none;
    font-size: 16px;
    margin-right: 10px;
}

.result-links {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-top: 10px;
}

.result-links button {
    padding: 8px 14px;
    font-size: 14px;
    border: none;
    border-radius: 6px;
    background: #3366cc;
    color: white;
    cursor: pointer;
}

.tabs {
    display: flex;
    gap: 8px;
    margin-top: 30px;
}

.tab-button {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 6px 6px 0 0;
    background: #444;
    color: #ccc;
    cursor: pointer;
}

.tab-button.active {
    background: #2b2b2b;
    color: #fff;
}

.side-list {
    list-style: none;
    margin: 0;
    padding: 10px;
    background: #2b2b2b;
    border-radius: 0 0 10px 10px;
    max-height: 200px;
    overflow-y: auto;
    color: #f5f5f5;
}

.side-list li {
    padding: 8px;
    cursor: pointer;
    border-bottom: 1px solid #444;
}

#counter {
    color: #ccc;
    font-size: 14px;
    margin-top: -10px;
    margin-bottom: 10px;
}

#confettiContainer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 999;
}

.confetti-piece {
    position: absolute;
    top: -10px;
    width: 8px;
    height: 14px;
    opacity: 0.9;
    animation: confetti-fall linear forwards;
}

@keyframes confetti-fall {
    to {
        transform: translateY(105vh) rotate(720deg);
    }
}

#milestoneMessage {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: #3366cc;
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    z-index: 1000;
    animation: milestone-pop 2.5s ease forwards;
}

@keyframes milestone-pop {
    0% { opacity: 0; transform: translateX(-50%) translateY(-20px); }
    15% { opacity: 1; transform: translateX(-50%) translateY(0); }
    85% { opacity: 1; }
    100% { opacity: 0; transform: translateX(-50%) translateY(-10px); }
}

#funFact {
    color: #a8b8d8;
    font-size: 13px;
    font-style: italic;
    max-width: 500px;
    margin: 0 auto 20px;
}
