:root {
    --primary-color: #007bff;
    --bg-color: #f8f9fa;
    --text-color: #333;
    --card-bg: #fff;
    --shadow: 0 2px 4px rgba(0,0,0,0.1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    background-color: var(--bg-color);
    color: var(--text-color);
}

header {
    background-color: var(--primary-color);
    color: white;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
}

.btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.hidden {
    display: none !important;
}

main {
    max-width: 600px;
    margin: 0 auto;
    padding-bottom: 80px;
}

.tabs {
    display: flex;
    background: white;
    border-bottom: 1px solid #ddd;
}

.tab-btn {
    flex: 1;
    padding: 1rem;
    border: none;
    background: none;
    font-weight: bold;
    color: #666;
    cursor: pointer;
}

.tab-btn.active {
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color);
}

.status-bar {
    padding: 0.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    font-size: 0.8rem;
    background: #e9ecef;
    color: #495057;
}

.btn-text {
    background: none;
    border: none;
    color: var(--primary-color);
    font-weight: bold;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
}

.post-card {
    background: var(--card-bg);
    margin: 0.75rem;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.post-meta {
    font-size: 0.75rem;
    color: #777;
    margin-top: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #eee;
    padding-top: 0.5rem;
}

.vote-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.vote-btn {
    background: #eee;
    border: none;
    border-radius: 4px;
    padding: 2px 8px;
    cursor: pointer;
    font-size: 1rem;
}

.vote-btn:hover {
    background: #ddd;
}

.score {
    font-weight: bold;
    color: var(--text-color);
}

.fab {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    border-radius: 30px;
    background-color: var(--primary-color);
    color: white;
    font-size: 2rem;
    border: none;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal {
    position: fixed;
    z-index: 200;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: white;
    padding: 2rem;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    position: relative;
}

.close-modal {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 1.5rem;
    cursor: pointer;
}

textarea {
    width: 100%;
    height: 100px;
    margin: 1rem 0;
    padding: 0.5rem;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 4px;
    resize: none;
}

#welcome-screen {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-msg {
    text-align: center;
    color: #888;
    margin-top: 2rem;
    padding: 1rem;
}
