:root {
    --bg-color: rgb(13, 44, 44);
    --text-color: #dcf2ff;
    --accent-color: #0c3d40;
    --secondary-color: #005b5b;
    --dark-bg-color: #2F4F4F;
    --dark-text-color: #E0FFFF;
    --dark-accent-color: #02183a;
    --dark-secondary-color: #034c48;
    --accent-color-rgb: 12, 61, 64;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    transition: background-color 0.3s, color 0.3s;
    margin: 0;
    padding: 0;
}

.dark-mode {
    --bg-color: var(--dark-bg-color);
    --text-color: var(--dark-text-color);
    --accent-color: var(--dark-accent-color);
    --secondary-color: var(--dark-secondary-color);
}

.header1 {
    background-color: rgba(13, 44, 44, 0.9);
    padding: 1rem;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease-in-out;
}

.header-scrolled {
    background-color: var(--bg-color);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
}

nav ul {
    display: flex;
    list-style-type: none;
    align-items: center;
}

nav li {
    margin-left: 2rem;
}

nav a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s;
}

nav a:hover {
    color: var(--accent-color);
}

#darkModeToggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.5rem;
    margin-left: 1rem;
    color: var(--text-color);
}

.fa-moon, .fa-sun {
    display: none;
}

.dark-mode .fa-moon {
    display: inline;
}

body:not(.dark-mode) .fa-sun {
    display: inline;
}

.blog-content {
    max-width: 1200px;
    margin: 80px auto 0;
    padding: 20px;
}

.featured-posts-slider {
    position: relative;
    height: 400px;
    overflow: hidden;
    margin-bottom: 30px;
}

.slider-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
}

.slider-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 20px;
}

.slide-content h3 {
    margin-top: 0;
}

.search-container {
    max-width: 800px;
    margin: 20px auto;
    padding: 0 20px;
}

#search-form {
    display: flex;
}

#search-input {
    flex-grow: 1;
    padding: 10px;
    border: 1px solid var(--secondary-color);
    border-radius: 5px 0 0 5px;
    background-color: var(--bg-color);
    color: var(--text-color);
}

#search-form button {
    padding: 10px 20px;
    background-color: var(--accent-color);
    color: var(--text-color);
    border: none;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
}

.two-column-layout {
    display: flex;
    gap: 30px;
}

.main-content {
    flex: 2;
}

.sidebar {
    flex: 1;
}

.post {
    background-color: var(--secondary-color);
    border-radius: 10px;
    margin-bottom: 20px;
    transition: transform 0.3s;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.post:hover {
    transform: translateY(-5px);
}

.post-image-container {
    height: 200px;
    overflow: hidden;
}

.post-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post:hover .post-image {
    transform: scale(1.05);
}

.post-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.post-title {
    margin-top: 0;
}

.post-excerpt {
    flex-grow: 1;
}

.post-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
}

.read-more {
    background-color: var(--accent-color);
    color: var(--text-color);
    padding: 5px 10px;
    border-radius: 5px;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.read-more:hover {
    background-color: var(--secondary-color);
}

.tag {
    display: inline-block;
    background-color: var(--accent-color);
    color: var(--text-color);
    padding: 5px 10px;
    border-radius: 5px;
    margin-right: 5px;
    margin-bottom: 5px;
    cursor: pointer;
}

.tag:hover {
    background-color: var(--secondary-color);
}

.widget {
    background-color: var(--secondary-color);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
}

.widget h3 {
    margin-top: 0;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 20px;
}

.pagination button {
    padding: 10px 20px;
    background-color: var(--accent-color);
    color: var(--text-color);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin: 0 10px;
}

#currentPage {
    font-weight: bold;
}

#subscribe {
    background-color: var(--secondary-color);
    padding: 40px 0;
    text-align: center;
}

#subscribe .container {
    max-width: 600px;
    margin: 0 auto;
}

#subscribe-form {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

#subscribe-form input {
    flex-grow: 1;
    padding: 10px;
    border: 1px solid var(--accent-color);
    border-radius: 5px 0 0 5px;
    background-color: var(--bg-color);
    color: var(--text-color);
}

#subscribe-form button {
    padding: 10px 20px;
    background-color: var(--accent-color);
    color: var(--text-color);
    border: none;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
}

footer {
    background-color: var(--accent-color);
    color: var(--text-color);
    padding: 40px 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-section {
    flex: 1;
    margin: 0 20px;
    min-width: 200px;
}

.footer-section h4 {
    margin-bottom: 20px;
}

.quick-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.quick-links li {
    background-color: var(--secondary-color);
    padding: 5px 10px;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.quick-links li:hover {
    background-color: var(--accent-color);
}

.quick-links li a {
    text-decoration: none;
    color: #dcf2ff;
}

.social-icons{
    display: flex;
}
.social-icons a img {
    height: 50px;
    width: 50px;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.social-icons a img:hover {
    transform: scale(1.1) rotate(5deg);
    filter: brightness(1.2) drop-shadow(0 0 5px rgba(0, 0, 0, 0.3));
}
.social-icons a {
    color: var(--text-color);
    font-size: 1.5rem;
    margin-right: 15px;
}

.author-info {
    margin-top: 20px;
    text-align: center;
}

.author-photo {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent-color);
}

.author-social-links a {
    font-size: 1.2rem;
    margin: 0 5px;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    margin-top: 20px;
    border-top: 1px solid var(--text-color);
}

.modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.4);
}

.modal-content {
    background-color: var(--bg-color);
    margin: 15% auto;
    padding: 20px;
    border-radius: 10px;
    width: 300px;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

.auth-tabs {
    display: flex;
    justify-content: space-around;
    margin-bottom: 20px;
}

.auth-tab {
    background: none;
    border: none;
    color: var(--text-color);
    cursor: pointer;
    font-size: 1.1rem;
    padding: 10px 20px;
    transition: all 0.3s ease;
}

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

.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
}

.auth-form input {
    width: 93%;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid var(--secondary-color);
    border-radius: 5px;
    background-color: var(--bg-color);
    color: var(--text-color);
}

.auth-form button {
    width: 100%;
    padding: 10px;
    background-color: var(--accent-color);
    color: var(--text-color);
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.auth-form button:hover {
    background-color: var(--secondary-color);
}

#backToTop {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99;
    border: none;
    outline: none;
    background-color: var(--accent-color);
    color: var(--text-color);
    cursor: pointer;
    padding: 15px;
    border-radius: 50%;
    font-size: 18px;
}

#backToTop:hover {
    background-color: var(--secondary-color);
}

.comment-section {
    margin-top: 20px;
    border-top: 1px solid var(--secondary-color);
    padding-top: 20px;
}

.comment-form textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid var(--secondary-color);
    border-radius: 5px;
    background-color: var(--bg-color);
    color: var(--text-color);
}

.comment-form button {
    padding: 10px 20px;
    background-color: var(--accent-color);
    color: var(--text-color);
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.comments-list {
    margin-top: 20px;
}

.comment {
    background-color: var(--secondary-color);
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 5px;
}

@media (max-width: 768px) {
    .two-column-layout {
        flex-direction: column;
    }
    
    #sidebar {
        margin-top: 2rem;
    }
    
    .footer-content {
        flex-direction: column;
    }
    
    .footer-section {
        margin-bottom: 30px;
    }

    nav ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--bg-color);
    }

    nav ul.show {
        display: flex;
    }

    nav li {
        margin: 1rem 0;
    }

    #darkModeToggle {
        margin-left: auto;
    }

    #subscribe-form {
        flex-direction: column;
    }

    #subscribe-form input,
    #subscribe-form button {
        width: 100%;
        border-radius: 5px;
        margin-bottom: 10px;
    }
}