/* Existing styles */
body {
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #20232a;
    color: white;
}

.sidebar {
    width: 250px;
    background-color: #282c34;
    position: fixed;
    top: 0;
    bottom: 0;
    left: -250px; /* Hide sidebar by default */
    padding: 20px;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: left 0.5s ease; /* Adjusted transition timing */
}

.sidebar.open {
    left: 0; /* Show sidebar when open */
}

.logo img {
    width: 100%;
}

.menu-toggle {
    background-color: #4CAF50;
    border: none;
    color: white;
    padding: 12px 18px; /* Increased padding */
    font-size: 18px; /* Slightly reduced font size */
    cursor: pointer;
    position: fixed;
    top: 20px; /* Increased top spacing */
    left: 20px; /* Increased left spacing */
    z-index: 1000;
    border-radius: 5px; /* Added border radius */
    transition: background-color 0.3s; /* Smooth transition for background color */
}

.menu-toggle:hover {
    background-color: #45a049; /* Darkened background color on hover */
}

.menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.menu li {
    margin: 10px 0;
}

.menu a {
    display: block;
    padding: 10px;
    border-radius: 5px;
    color: white;
    text-decoration: none;
    background-color: #282c34; /* Same as sidebar background */
    text-align: center;
    border: 1px solid transparent; /* Add transparent border */
}

.menu a:hover, .menu a.selected {
    background-color: #333;
    border: 1px solid #444;
}

.main-content {
    margin-left: 270px;
    padding: 20px;
    transition: margin-left 0.3s ease-in-out;
}

.top-stories {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.story {
    background-color: #444;
    border-radius: 10px;
    overflow: hidden;
    width: 24%;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s;
}

.story img {
    width: 100%;
}

.story-title {
    padding: 10px;
    background-color: #333;
    text-align: center;
}

.story:hover {
    transform: scale(1.05);
}

/* Mobile styles */
@media (max-width: 768px) {
    .sidebar {
        width: 250px;
        left: -250px; /* Hide sidebar by default */
    }

    .sidebar.open {
        left: 0; /* Show sidebar when open */
    }

    .main-content {
        margin-left: 0;
    }

    .menu-toggle {
        display: block;
    }

    .top-stories {
        flex-direction: column;
    }

    .story {
        width: 100%;
        margin-bottom: 20px;
    }
}
