/*
Theme Name: Aneas Theme
Description: A modern take on the classic blog layout with a 70/30 split, cutting-edge design, and customizable elements.
Version: 1.0.0
*/

* {margin: 0; padding: 0; box-sizing: border-box;}

body {font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif; line-height: 1.6; color: #2d3748; background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%); font-size: 15px;}

.container {max-width: 1200px; margin: 0 auto; padding: 0 20px; position: relative;}

/* Header Styles */
.header {background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(20px); border-bottom: 1px solid rgba(226, 232, 240, 0.8); padding: 12px 0; position: sticky; top: 0; z-index: 100; box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);}
.header-content {/*display: flex; */align-items: center; justify-content: space-between; /*height: 56px;*/}
.logo-section {display: flex; align-items: center; gap: 12px;}
.logo {width: 42px; height: 42px; background: #2d3748; border-radius: 6px; display: flex; align-items: center; justify-content: center; color: white; font-weight: 700; font-size: 16px; margin: 4px}
.site-info h1 {font-size: 24px; font-weight: 700; background: linear-gradient(135deg, #e53e3e, #fc8181); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; margin: 0; letter-spacing: -0.02em;}
.site-info h1 a {text-decoration: none; -webkit-text-fill-color: inherit;} /* For site title link */
.site-info p {font-size: 16px; color: #718096; font-weight: 400;}

/* WordPress Custom Logo Styling */
.logo .custom-logo-link {
    display: flex; /* Ensures the image inside is centered/aligned properly */
    align-items: center;
    justify-content: center;
    height: 100%;
    width: 100%;
}
.logo .custom-logo {
    max-height: 100%;
    max-width: 100%;
    width: auto; /* Maintain aspect ratio */
    height: auto; /* Maintain aspect ratio */
}


/* Navigation Styles */
.nav {position: relative; border: 1px solid rgba(226, 232, 240, 0.8); border-radius: 6px; margin: 4px 4px 0px 4px}
.nav ul {display: flex; justify-content: flex; gap: 0; list-style: none; margin: 0; padding: 0;}
.nav > ul > li {position: relative;}
.nav a {display: block; text-decoration: none; color: #4a5568; padding: 16px 20px; font-weight: 500; font-size: 14px; text-align: center; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); position: relative; overflow: hidden; border-radius: 6px;}
.nav a::before {content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(135deg, #e53e3e, #fc8181); transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1); z-index: -1; border-radius: 6px;}
.nav a:hover::before {left: 0;}
.nav a:hover {color: white; transform: translateY(-1px);}

/* Dropdown Menu Styles */
/* Apply to the LI that has children */
.menu-item-has-children {
    position: relative;
}

/* Apply to the UL that is the sub-menu */
.sub-menu {
    position: absolute;
    top: 100%; /* Position right below the parent link */
    left: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    min-width: 400px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    border-radius: 12px;
    padding: 8px 0;
    border: 1px solid rgba(226, 232, 240, 0.8);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    list-style: none; /* Ensure no bullet points */
    display: block!important;
}
.sub-menu ul {
    position: absolute;
    top: 100%; /* Position right below the parent link */
    left: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    min-width: 200px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    border-radius: 12px;
    padding: 8px 0;
    border: 1px solid rgba(226, 232, 240, 0.8);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    list-style: none; /* Ensure no bullet points */
}

/* On hover of the parent LI, show the sub-menu */
.menu-item-has-children:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    padding: 4px;
    border-radius: 6px;
}

.sub-menu li a {
    padding: 12px 20px;
    color: #4a5568;
    border-radius: 0; /* Sub-menu items usually don't need rounded corners on their own */
    margin: 0 8px; /* Give some internal padding/margin */
    font-size: 13px;
    display: block; /* Make sure links fill the space */
    text-align: left;        
}
.sub-menu li a:hover {
    background: rgba(229, 62, 62, 0.1);
    color: #e53e3e;
    transform: translateY(0); /* Reset transform as parent hover handles it */
}
.sub-menu li a::before {
    display: none; /* No hover effect background for sub-menu items */
}
.nav ul {
    display: flex;
    align-items: center;
}

.menu-login {
    margin-left: auto;
}
.google-login a {
    padding: 0px !important;
    margin: 0px !important;
}

  .user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .logout-link {
    color: #ff4444;
    margin-left: auto;
  }


/* Mobile dropdown styles */
.dropdown.mobile-active .dropdown-content {opacity: 1; visibility: visible; transform: translateY(0); position: static; box-shadow: inset 0 2px 8px rgba(0,0,0,0.1); background: rgba(248, 250, 252, 0.9); margin: 8px 16px; border-radius: 8px;}
.dropdown.mobile-active .dropdown-content a {margin: 0; padding: 12px 16px;}

/* Mobile Navigation */
.mobile-nav-toggle {display: none; background: none; border: none; font-size: 20px; color: #4a5568; cursor: pointer; padding: 10px; border-radius: 6px; transition: all 0.3s ease;}
.mobile-nav-toggle:hover {background: rgba(229, 62, 62, 0.1); color: #e53e3e;}

/* Mobile dropdown styles */
@media (max-width: 768px) {
    /* For mobile, hide sub-menu by default when main nav is not active */
    .nav ul:not(.active) .sub-menu {
        display: none;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
    }

    /* When mobile dropdown is active, show it */
    .menu-item-has-children.mobile-active > .sub-menu { /* Target the direct child sub-menu */
        display: block;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        position: static; /* Stack naturally within the mobile menu */
        box-shadow: inset 0 2px 8px rgba(0,0,0,0.1); /* Inner shadow for mobile dropdown */
        background: rgba(248, 250, 252, 0.9);
        margin: 8px 16px;
        border-radius: 8px;
    }

    .sub-menu li a { /* Adjust internal padding for mobile sub-menu */
        margin: 0;
        padding: 12px 16px;
    }
}
/* Content Layout */
.content-wrapper {display: grid; grid-template-columns: 1fr 300px; gap: 40px; margin-top: 28px; align-items: start;}

/* Main Content */
.main-content {background: rgba(255, 255, 255, 0.8); backdrop-filter: blur(16px); border-radius: 16px; overflow: hidden; box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06); border: 1px solid rgba(226, 232, 240, 0.6);}
.post {padding: 32px; border-bottom: 1px solid rgba(226, 232, 240, 0.6); position: relative; transition: all 0.3s ease;}
.post:last-child {border-bottom: none;}
.post::before {content: ''; position: absolute; left: 0; top: 0; width: 3px; height: 100%; background: linear-gradient(135deg, #e53e3e, #fc8181); transform: scaleY(0); transition: transform 0.3s ease; transform-origin: bottom;}
.post:hover::before {transform: scaleY(1);}
.post:hover {transform: translateX(6px);}
.post h2 {font-size: 28px; font-weight: 700; margin-bottom: 16px; color: #2d3748; line-height: 1.3; letter-spacing: -0.01em;}
.post p {font-size: 15px; color: #4a5568; margin-bottom: 14px; line-height: 1.7;}
.post-meta {font-size: 13px; color: #a0aec0; margin-bottom: 14px; display: flex; gap: 14px; align-items: center;}
.post-meta span {padding: 4px 10px; background: rgba(229, 62, 62, 0.1); border-radius: 16px; color: #e53e3e; font-weight: 500;}
.read-more {display: inline-block; color: #e53e3e; text-decoration: none; font-weight: 600; font-size: 14px; padding: 10px 20px; background: rgba(229, 62, 62, 0.08); border-radius: 8px; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); border: 1px solid rgba(229, 62, 62, 0.2);}
.read-more:hover {background: #e53e3e; color: white; transform: translateY(-1px); box-shadow: 0 6px 20px rgba(229, 62, 62, 0.3);}

/* Sidebar */
.sidebar {display: flex; flex-direction: column; gap: 28px;}
.widget {background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(16px); padding: 24px; border-radius: 16px; box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06); border: 1px solid rgba(226, 232, 240, 0.6); transition: all 0.3s ease; position: relative; overflow: hidden;}
.widget::before {content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, #e53e3e, #fc8181); opacity: 0; transition: opacity 0.3s ease;}
.widget:hover::before {opacity: 1;}
.widget:hover {transform: translateY(-2px); box-shadow: 0 12px 48px rgba(0, 0, 0, 0.1);}
.widget h3 {font-size: 18px; font-weight: 700; margin-bottom: 16px; color: #2d3748; letter-spacing: -0.01em;}
.widget p {font-size: 14px; color: #718096; line-height: 1.6;}
.widget ul {list-style: none; padding: 0; margin: 0;}
.widget li {padding: 10px 0; border-bottom: 1px solid rgba(226, 232, 240, 0.8); transition: all 0.3s ease; cursor: pointer; font-size: 14px;}
.widget li:last-child {border-bottom: none;}
.widget li:hover {color: #e53e3e; padding-left: 10px;}
.search-box {width: 100%; padding: 12px 16px; border: 2px solid rgba(226, 232, 240, 0.8); border-radius: 8px; font-size: 14px; transition: all 0.3s ease; background: rgba(255, 255, 255, 0.8); backdrop-filter: blur(8px);}
.search-box:focus {outline: none; border-color: #e53e3e; box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.1); background: white;}
.tag {display: inline-block; padding: 6px 12px; background: linear-gradient(135deg, #f7fafc, #edf2f7); border-radius: 16px; font-size: 12px; color: #718096; margin: 3px 6px 3px 0; transition: all 0.3s ease; cursor: pointer; border: 1px solid rgba(226, 232, 240, 0.8);}
.tag:hover {background: linear-gradient(135deg, #e53e3e, #fc8181); color: white; transform: translateY(-1px);}

/* Modern Footer */
.footer {margin-top: 60px; background: rgba(45, 55, 72, 0.95); backdrop-filter: blur(20px); color: white; padding: 40px 0 24px 0; border-radius: 16px 16px 0 0; position: relative; overflow: hidden;}
.footer::before {content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, #e53e3e, #fc8181, #f093fb, #f5576c);}
.footer-content {display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 32px; margin-bottom: 32px;}
.footer-section h4 {font-size: 16px; font-weight: 700; margin-bottom: 16px; color: white;}
.footer-section p, .footer-section a {color: #a0aec0; text-decoration: none; font-size: 14px; line-height: 1.6; transition: color 0.3s ease; display: block; margin-bottom: 8px;}
.footer-section a:hover {color: #fc8181;}
.social-links {display: flex; gap: 16px; margin-top: 16px;}
.social-links a {display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; background: rgba(255, 255, 255, 0.1); border-radius: 8px; transition: all 0.3s ease; margin-bottom: 0;}
.social-links a:hover {background: #e53e3e; transform: translateY(-2px);}
.footer-bottom {border-top: 1px solid rgba(255, 255, 255, 0.1); padding-top: 24px; text-align: center; font-size: 13px; color: #a0aec0;}

/* Responsive Design */
@media (max-width: 1024px) {
    .content-wrapper {grid-template-columns: 1fr 260px; gap: 28px;}
    .post {padding: 28px;}
}

@media (max-width: 768px) {
    .container {padding: 0 16px;}
    .header-content {flex-wrap: wrap; height: auto; gap: 12px;}
    .nav {width: 100%; order: 3;}
    .nav ul {display: none; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0; background: rgba(255, 255, 255, 0.98); backdrop-filter: blur(20px); border-radius: 12px; margin-top: 8px; box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15); border: 1px solid rgba(226, 232, 240, 0.8); z-index: 1000;}
    .nav ul.active {display: flex;}
    .nav li {flex: none;}
    .nav a {padding: 14px 20px; text-align: left;}
    .mobile-nav-toggle {display: block; position: absolute; right: 0; top: 50%; transform: translateY(-50%);}
    .nav {position: relative;}
    .content-wrapper {grid-template-columns: 1fr; gap: 28px;}
    .main-content {order: 1;}
    .sidebar {order: 2;}
    .post {padding: 24px;}
    .widget {padding: 20px;}
    .footer-content {grid-template-columns: 1fr; gap: 24px;}
    
    /* For mobile, hide dropdown content by default when nav is not active */
    .nav ul:not(.active) .dropdown-content {
        display: none; /* Use display: none for mobile when parent menu is closed */
        opacity: 0; /* Also keep opacity/visibility for smooth transition when active */
        visibility: hidden;
        transform: translateY(-10px);
    }

    /* When dropdown is active on mobile */
    .dropdown.mobile-active .dropdown-content {
        display: block; /* Show dropdown content when active on mobile */
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        position: static;
        box-shadow: inset 0 2px 8px rgba(0,0,0,0.1);
        background: rgba(248, 250, 252, 0.9);
        margin: 8px 16px;
        border-radius: 8px;
    }    
}

@media (max-width: 480px) {
    .header {padding: 10px 0;}
    .header-content {height: auto; padding: 6px 0;}
    .logo {width: 36px; height: 36px; font-size: 14px;}
    .site-info h1 {font-size: 20px;}
    .site-info p {font-size: 12px;}
    .post {padding: 20px;}
    .post h2 {font-size: 24px;}
    .widget {padding: 18px;}
    .social-links {justify-content: center;}
}

/* Smooth scrolling */
html {scroll-behavior: smooth;}
a {
    color: -webkit-link;
    cursor: pointer;
    text-decoration: none;
}
a {color: #666; font-weight: bold}
a:hover {color: red}

/* Selection colors */
::selection {background: rgba(229, 62, 62, 0.2); color: #2d3748;}

/* Custom scrollbar */
::-webkit-scrollbar {width: 6px;}
::-webkit-scrollbar-track {background: #f7fafc;}
::-webkit-scrollbar-thumb {background: linear-gradient(135deg, #e53e3e, #fc8181); border-radius: 3px;}
::-webkit-scrollbar-thumb:hover {background: linear-gradient(135deg, #c53030, #e53e3e);}

/* WordPress Specific Styles (minimal, to integrate with existing theme styles) */
.screen-reader-text { /* Hide screen reader text visually but not from screen readers */
    clip: rect(1px, 1px, 1px, 1px);
    position: absolute !important;
    height: 1px;
    width: 1px;
    overflow: hidden;
}

/* Align common WordPress elements with existing styles */
.wp-caption {
    max-width: 100%;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(226, 232, 240, 0.6);
    padding: 5px;
    margin-bottom: 20px;
}

.wp-caption-text {
    font-size: 13px;
    text-align: center;
    color: #718096;
    padding: 5px 0;
}

.gallery-caption {
    margin-left: 0;
}

.bypostauthor {
    font-style: italic;
}

.alignright {
    float: right;
    margin: 0 0 1em 1em;
}

.alignleft {
    float: left;
    margin: 0 1em 1em 0;
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.wp-block-image {
    margin-bottom: 1.6em;
}

/* Adjustments for default list styles to match widget ul */
.main-content ul, .main-content ol {
    margin-left: 20px;
    margin-bottom: 1em;
}

.main-content ul li, .main-content ol li {
    margin-bottom: 0.5em;
}

/* Search widget specific styles */
.widget_search .search-box { /* Targeting WordPress default search input */
    box-sizing: border-box;
}
/* comment section */
.comments-area {
    margin-top: 20px;
    padding: 20px;
    background: #f8f8f8;
}
.comment-list {
    list-style: none;
    padding: 0;
}
.comment-list .comment {
    margin-bottom: 15px;
}
.comment-form {
    margin-top: 20px;
}
.comment-form textarea {
    width: 100%;
    padding: 10px;
}
.comment-form .submit {
    background: #333;
    color: #fff;
    padding: 10px 20px;
    border: none;
}

/* html form style */
form {
    margin-bottom: 10px;
    /* padding: 20px; */
    background: #f8f8f8;
    border: 1px solid #ddd;
    border-radius: 5px;
}
label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}
input[type="text"],
input[type="email"],
input[type="url"],
input[type="password"],
input[type="search"],
input[type="tel"],
input[type="date"],
input[type="month"],
input[type="week"],
input[type="time"],
input[type="datetime"],
input[type="datetime-local"] {
    /* width: 100%; */
    padding: 10px;
    /* margin-bottom: 15px; */
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    font-size: 16px;
    color: #333;
}
input[type="number"] {
    /* width: 100%; */
    padding: 10px;
    /* margin-bottom: 15px; */
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    font-size: 16px;
    color: #333;
    text-align: right;
}
textarea {
    /* width: 100%; */
    padding: 10px;
    /* margin-bottom: 15px; */
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    font-size: 16px;
    color: #333;
    resize: vertical;
}
select {
    /* width: 100%; */
    padding: 10px;
    /* margin-bottom: 15px; */
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    font-size: 16px;
    color: #333;
}
input[type="checkbox"],
input[type="radio"] {
    margin-right: 5px;
    vertical-align: middle;
}
button,
input[type="submit"],
input[type="button"],
input[type="reset"] {
    padding: 10px 20px;
    background: #333;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
}
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover {
    background: #555;
}
fieldset {
    border: 1px solid #ddd;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
}
legend {
    padding: 0 10px;
    font-weight: bold;
    color: #333;
}
