/* General Styles */
body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #121212;
    color: #e0e0e0;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background-color: #333;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-radius: 10px;
}

header .logo h4 {
    margin: 0;
    font-size: 24px;
    color: #e0e0e0;
}

header .user-info {
    display: flex;
    align-items: center;
}

header .profile-photo {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 10px;
}

header .followers-info,
header .notifications {
    display: flex;
    align-items: center;
    margin-left: 20px;
    position: relative;
}

header .followers-info i,
header .notifications i {
    margin-right: 5px;
}

header .notification-count {
    background-color: red;
    color: white;
    border-radius: 50%;
    padding: 2px 6px;
    font-size: 12px;
    position: absolute;
    top: -5px;
    right: -10px;
}

main {
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

section {
    width: 100%;
    max-width: 1200px;
    margin-bottom: 40px;
}

h1, h2 {
    color: #e0e0e0;
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.card {
    background-color: #333;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    display: flex;
    flex-direction: row;
    height: 180px;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

.card img {
    width: 40%;
    height: auto;
    object-fit: cover;
    border-radius: 0 10px 10px 0;
}

.card .content {
    padding: 10px;
    width: 60%;
    position: relative;
}

.card .content a {
    text-decoration: none;
    color: #e0e0e0;
}

.card .content a:hover {
    text-decoration: underline;
}

.card .content h3 {
    margin: 0;
    font-size: 14px;
}

.card .content p {
    font-size: 12px;
    color: #999;
    margin: 5px 0 0;
}

.view-count {
    font-size: 12px;
    color: #999;
    position: absolute;
    bottom: 10px;
    right: 10px;
}

.view-count i {
    margin-right: 3px;
}

.actions {
    position: absolute;
    top: 50%;
    right: 10px;
    display: flex;
    align-items: center;
    transform: translateY(-50%);
}

.actions .dropdown {
    position: relative;
    display: inline-block;
}

.actions .dropdown-content {
    display: none;
    position: absolute;
    background-color: #444;
    min-width: 120px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
    z-index: 1;
    border-radius: 10px;
    padding: 5px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.actions .dropdown-content a {
    color: #e0e0e0;
    padding: 5px;
    text-decoration: none;
    display: block;
    border-radius: 5px;
}

.actions .dropdown-content a:hover {
    background-color: #555;
}

.actions .dropdown:hover .dropdown-content {
    display: block;
}

.actions .edit-icon {
    font-size: 16px;
    color: #999;
    cursor: pointer;
    margin-right: 5px;
}

.actions .edit-icon:hover {
    color: #e0e0e0;
}

.actions .delete-icon {
    font-size: 16px;
    color: #999;
    cursor: pointer;
}

.actions .delete-icon:hover {
    color: #e0e0e0;
}

.like-count {
    font-size: 12px;
    color: #999;
    position: absolute;
    bottom: 10px;
    left: 10px;
}

.like-count i {
    margin-right: 3px;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #333;
    margin: 15% auto;
    padding: 20px;
    border-radius: 20px;
    box-shadow: 7px 7px 20px #444, -7px -7px 20px #222;
    width: 80%;
    max-width: 500px;
    position: relative;
}

.modal-content h2 {
    margin-top: 0;
    color: #e0e0e0;
}

.close {
    color: #999;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: #e0e0e0;
    text-decoration: none;
    cursor: pointer;
}

#graphsSection {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#graphsSection canvas {
    max-width: 100%;
    margin-bottom: 20px;
}

#readsTrend {
    font-size: 18px;
    margin-top: 10px;
    color: #e0e0e0;
}

/* Media Queries for Mobile Responsiveness */
@media (max-width: 1200px) {
    .grid-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .grid-container {
        grid-template-columns: 1fr;
    }

    .card {
        flex-direction: column;
        height: auto;
    }

    .card img {
        width: 100%;
        border-radius: 10px 10px 0 0;
    }

    .card .content {
        width: 100%;
    }

    .actions {
        top: 10px;
        right: 10px;
        transform: none;
    }

    .view-count {
        bottom: 10px;
        right: 10px;
    }

    .like-count {
        bottom: 10px;
        left: 10px;
    }
}

/* Followers Card Styles */
.follower-card {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 10px;
    background-color: #333;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    transition: transform 0.2s, box-shadow 0.2s;
    margin-bottom: 10px;
    cursor: pointer;
}

.follower-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

.follower-card img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    margin-right: 10px;
}

.follower-card p {
    margin: 0;
    font-size: 14px;
    color: #e0e0e0;
}

/* Followers Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #333;
    margin: 15% auto;
    padding: 20px;
    border-radius: 20px;
    box-shadow: 7px 7px 20px #444, -7px -7px 20px #222;
    width: 80%;
    max-width: 500px;
    position: relative;
}

.modal-content h2 {
    margin-top: 0;
    color: #e0e0e0;
}

.close {
    color: #999;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: #e0e0e0;
    text-decoration: none;
    cursor: pointer;
}

/* Followers List in Modal */
#followerList {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.follower-modal-card {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 10px;
    background-color: #333;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    transition: transform 0.2s, box-shadow 0.2s;
    margin-bottom: 10px;
    width: 100%;
}

.follower-modal-card img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    margin-right: 10px;
}

.follower-modal-card p {
    margin: 0;
    font-size: 14px;
    color: #e0e0e0;
}

.follower-modal-card .follow-button {
    margin-left: auto;
    padding: 5px 10px;
    background-color: rgb(55, 90, 0);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.follower-modal-card .follow-button:hover {
    background-color: rgb(40, 60, 0);
}

/* Dark Mode Styles */
body.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

header.dark-mode {
    background-color: #333;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

main.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

.card.dark-mode {
    background-color: #333;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.card.dark-mode img {
    border-radius: 0 10px 10px 0;
}

.card.dark-mode .content {
    color: #e0e0e0;
}

.modal.dark-mode {
    background-color: rgba(0, 0, 0, 0.8);
}

.modal-content.dark-mode {
    background-color: #333;
    box-shadow: 7px 7px 20px #444, -7px -7px 20px #222;
    color: #e0e0e0;
}

.dropdown-content.dark-mode {
    background-color: #444;
    color: #e0e0e0;
}

/* Additional Dark Mode Styles */
header .logo h4.dark-mode {
    color: #e0e0e0;
}

header .user-info .profile-photo.dark-mode {
    border: 2px solid #e0e0e0;
}

header .followers-info i.dark-mode,
header .notifications i.dark-mode {
    color: #e0e0e0;
}

header .notification-count.dark-mode {
    background-color: red;
    color: white;
}

/* Followers Card Styles */
.follower-card.dark-mode {
    background-color: #333;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.follower-card.dark-mode p {
    color: #e0e0e0;
}

/* Followers Modal Styles */
.modal-content.dark-mode {
    background-color: #333;
    box-shadow: 7px 7px 20px #444, -7px -7px 20px #222;
    color: #e0e0e0;
}

.close.dark-mode {
    color: #999;
}

.close.dark-mode:hover,
.close.dark-mode:focus {
    color: #e0e0e0;
}

/* Modal for full-size image */
#myModal .modal-content.dark-mode {
    background-color: #333;
    box-shadow: 7px 7px 20px #444, -7px -7px 20px #222;
    color: #e0e0e0;
}

#myModal .controls.dark-mode a {
    color: #e0e0e0;
}

#myModal .controls.dark-mode a:hover {
    text-decoration: underline;
}
    
    /* Styles for the subscription button and modal */
.subscription-info {
    display: flex;
    align-items: center;
    margin-left: 20px;
    position: relative;
}

.subscription-info i {
    font-size: 24px;
    cursor: pointer;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #333;
    margin: 15% auto;
    padding: 20px;
    border-radius: 20px;
    box-shadow: 7px 7px 20px #444, -7px -7px 20px #222;
    width: 80%;
    max-width: 500px;
    position: relative;
}

.modal-content h2 {
    margin-top: 0;
    color: #e0e0e0;
}

.close {
    color: #999;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: #e0e0e0;
    text-decoration: none;
    cursor: pointer;
}