/*
Theme Name: Syntro
Author: tronajay
Author URI: https://github.com/tronajay
Description: A minimalistic blog theme for WordPress using Tailwind CSS
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: syntro
Tags: blog, minimalist, clean, tailwind, responsive
*/

/* Minimal custom styles - Tailwind handles most styling */

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* Custom Logo Styling */
.custom-logo-wrapper {
    display: flex;
    align-items: center;
    padding: 0.25rem 0;
}

.custom-logo {
    max-height: 50px;
    width: auto;
    height: auto;
    display: block;
}

.custom-logo-link {
    display: inline-block;
    line-height: 0;
}

/* Navigation Menu Styling */
.menu,
.menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 2rem;
}

.menu li {
    position: relative;
}

.menu a {
    display: inline-block;
    padding: 0.5rem 0;
    color: #374151;
    font-weight: 500;
    text-decoration: none;
    position: relative;
    transition: color 0.3s ease;
}

.menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #3b82f6;
    transition: width 0.3s ease;
}

.menu a:hover {
    color: #1f2937;
}

.menu a:hover::after {
    width: 100%;
}

.menu .current-menu-item a,
.menu .current_page_item a {
    color: #1f2937;
    font-weight: 600;
}

.menu .current-menu-item a::after,
.menu .current_page_item a::after {
    width: 100%;
    background-color: #3b82f6;
}

/* Dropdown Menu Styling */
.menu .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: white;
    min-width: 220px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    z-index: 50;
    padding: 0.5rem 0;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
    flex-direction: column;
    gap: 0;
}

.menu li:hover>.sub-menu,
.menu li:focus-within>.sub-menu {
    display: flex;
    animation: fadeIn 0.1s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.menu .sub-menu li {
    width: 100%;
    position: relative;
    /* Required for nested sub-menu positioning */
}

/* Nested Sub-Menu Styling */
.menu .sub-menu .sub-menu {
    top: 0;
    left: 100%;
    margin-top: 0;
    margin-left: 0.5rem;
    /* Space between menus */
}

.menu .sub-menu a {
    display: block;
    padding: 0.625rem 1.25rem;
    color: #374151;
    white-space: nowrap;
    width: 100%;
    transition: all 0.2s;
}

.menu .sub-menu a:hover {
    background-color: #f9fafb;
    color: #2563eb;
}

/* Remove the underline effect from top-level links for dropdown items */
.menu .sub-menu a::after {
    display: none;
}

/* Dropdown Icon */
.menu-item-has-children>a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding-right: 1rem;
}

.menu-item-has-children>a::after {
    content: '';
    display: block;
    width: 0.5rem;
    height: 0.5rem;
    border: solid #3b82f6;
    /* Primary blue */
    border-width: 0 1.5px 1.5px 0;
    transform: rotate(45deg);
    transition: transform 0.2s ease;
    margin-top: -2px;
    /* Visual alignment */
    opacity: 1;
    position: static;
    /* Reset absolute positioning */
    background-color: transparent;
    /* Remove inherited background */
}

.menu-item-has-children:hover>a::after {
    transform: rotate(225deg);
    opacity: 1;
}

/* Mobile Menu Styling */
.mobile-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-menu-list li {
    margin-bottom: 0.5rem;
}

.mobile-menu-list a {
    display: block;
    padding: 0.75rem 1rem;
    color: #374151;
    font-weight: 500;
    text-decoration: none;
    border-radius: 0.5rem;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.mobile-menu-list a:hover {
    background-color: #f3f4f6;
    color: #1f2937;
}

.mobile-menu-list .current-menu-item a,
.mobile-menu-list .current_page_item a {
    background-color: #eff6ff;
    color: #3b82f6;
    font-weight: 600;
}

/* WordPress Core Alignment */
.alignleft {
    float: left;
    margin-right: 1.5rem;
    margin-bottom: 1rem;
}

.alignright {
    float: right;
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* WordPress Gallery */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
}

/* Smooth transitions */
a {
    transition: color 0.2s ease;
}

/* Focus styles for accessibility */
a:focus,
button:focus,
input:focus,
textarea:focus {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Typography Styles for Single Posts (.prose) */
.prose {
    color: #374151;
    max-width: 65ch;
    font-size: 1.125rem;
    line-height: 1.75;
}

.prose p {
    margin-top: 1.25em;
    margin-bottom: 1.25em;
}

.prose h1,
.prose h2,
.prose h3,
.prose h4 {
    color: #111827;
    font-weight: 700;
    margin-top: 2em;
    margin-bottom: 1em;
    line-height: 1.3;
}

.prose h2 {
    font-size: 1.5em;
}

.prose h3 {
    font-size: 1.25em;
}

.prose h4 {
    font-size: 1.125em;
}

.prose ul,
.prose ol {
    margin-top: 1.25em;
    margin-bottom: 1.25em;
    padding-left: 1.625em;
}

.prose li {
    margin-top: 0.5em;
    margin-bottom: 0.5em;
}

.prose ul {
    list-style-type: disc;
}

.prose ol {
    list-style-type: decimal;
}

.prose blockquote {
    font-weight: 500;
    font-style: italic;
    color: #111827;
    border-left-width: 0.25rem;
    border-left-color: #e5e7eb;
    margin-top: 1.6em;
    margin-bottom: 1.6em;
    padding-left: 1em;
}

.prose img {
    margin-top: 2em;
    margin-bottom: 2em;
    border-radius: 0.5rem;
}

.prose a {
    color: var(--primary-color, #2563eb);
    text-decoration: underline;
    font-weight: 500;
}

.prose pre {
    color: #e5e7eb;
    background-color: #1f2937;
    overflow-x: auto;
    font-size: 0.875em;
    line-height: 1.7142857;
    margin-top: 1.7142857em;
    margin-bottom: 1.7142857em;
    border-radius: 0.375rem;
    padding: 0.8571429em 1.1428571em;
}

.prose code {
    color: #111827;
    font-weight: 600;
    font-size: 0.875em;
}

.prose pre code {
    background-color: transparent;
    border-width: 0;
    border-radius: 0;
    padding: 0;
    font-weight: 400;
    color: inherit;
    font-size: inherit;
    font-family: inherit;
    line-height: inherit;
}