/* Reset and Base Styles */
html {
    font-size: 100%;
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    box-sizing: border-box;
}

*, *:before, *:after {
    box-sizing: inherit;
    margin: 0;
    padding: 0;
    border: 0;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.75;
    color: #333;
    background-color: #fff;
    margin: 0;
    padding: 0;
    min-height: 100vh; /* Ensures body takes up at least the full height of the viewport */
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    margin: 2.75rem 0 1.05rem;
    line-height: 1.2;
}

h1 {
    font-size: 2.5em;
}

h2 {
    font-size: 2em;
}

h3 {
    font-size: 1.75em;
}

h4 {
    font-size: 1.5em;
}

h5 {
    font-size: 1.25em;
}

h6 {
    font-size: 1em;
}

/* Links */
a {
    color: #1a1a1a;
    text-decoration: none;
    border-bottom: 1px solid;
}

a:hover {
    border-bottom: 2px solid;
}

/* Container styles */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    overflow: hidden; /* Ensures that floated elements are contained */
}

/* Sidebar styles */
.sidebar {
    width: 250px;
    padding-right: 20px;
    float: left; /* Float sidebar to the left */
    box-sizing: border-box;
    text-align: center; /* Center content in the sidebar */
}

.sidebar h1 {
    font-family: 'Inter', sans-serif;
    font-size: 2.0em;
    margin-bottom: 20px;
    color: #333;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

.sidebar nav ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.sidebar nav ul li {
    margin-bottom: 10px;
}

.sidebar nav ul li a {
    border-bottom: none;
    color: #1a1a1a;
}
.sidebar footer {
    font-size: 0.8em;
    color: #666;
    text-align: center;
}

/* Divider styles */
.divider {
    width: 1px;
    background-color: #e0e0e0;
    margin: 0 20px;
    float: left; /* Float divider to the left */
    height: 100%; /* Ensure the divider spans the full height of the container */
}

/* Content styles */
.content {
    margin-left: 270px; /* Add margin to the left to accommodate the sidebar width and divider */
    padding-left: 20px;
    box-sizing: border-box;
}

/* Content Styles */
.content h2 {
    font-size: 2em;
    margin-bottom: 20px;
}

/* Tag List */
.tag-list {
    list-style-type: none;
    padding: 0;
}

.tag-list li {
    display: inline-block;
    margin-right: 10px;
    margin-bottom: 10px;
}

.tag-list li a {
    text-decoration: none;
    color: #1a1a1a;
    background-color: #f1f1f1;
    padding: 5px 10px;
    border-radius: 3px;
    border-bottom: none;
}

/* Code Blocks */
pre, code {
    font-size: 0.9em;
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 3px;
}

pre {
    padding: 1em;
    overflow-x: auto;
}

pre code {
    border: none;
    padding: 0;
    background: none;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 1em 0;
}

th, td {
    padding: 0.5em;
    border: 1px solid #ddd;
}

thead, tr:nth-child(even) {
    background-color: #f8f8f8;
}

/* Typing Effect */
.typing-section {
    margin-top: 40px; /* Adjust to move the typing effect lower */
    text-align: center; /* Centers the typing effect horizontally */
    position: relative;
}

/* Typing Effect */
#typing-effect::after {
    content: '|';
    animation: blink 0.7s infinite;
}

@keyframes blink {
    0% { opacity: 1; }
    50% { opacity: 0; }
    100% { opacity: 1; }
}

.main-page #typing-effect {
    display: inline;
}

/* Footer Styles */
footer {
    padding: 10px;
    text-align: center;
    font-size: 0.8em;
    color: #666;
}

/* Responsive Design */
@media (max-width: 960px) {
    .container {
        padding: 10px;
    }

    .sidebar {
        width: 100%;
        padding-right: 0;
        margin-bottom: 30px;
        text-align: center;
        float: none; /* Remove floating */
    }

    .divider {
        width: 100%;
        height: 1px;
        margin: 20px 0;
        float: none; /* Remove floating */
    }

    .content {
        margin-left: 0;
        width: 100%;
        padding-left: 0;
        text-align: left; /* Align text to the left */
    }

    section {
        padding: 0 10px; /* Adjust padding for smaller screens */
    }
}

@media (max-width: 480px) {
    body {
        font-size: 16px;
    }

    h1 {
        font-size: 2em;
    }

    h2 {
        font-size: 1.75em;
    }

    h3 {
        font-size: 1.5em;
    }

    .container {
        padding: 10px;
    }

    .sidebar {
        padding: 10px;
    }

    .content {
        padding: 10px;
        text-align: left; /* Align text to the left */
    }

    section {
        padding: 0 5px; /* Adjust padding for very small screens */
    }
}
