/* Reset & Base Styles */
:root {
    --primary-color: #2563eb; /* Modern Blue */
    --primary-hover: #1d4ed8;
    --text-color: #1f2937; /* Gray-900 */
    --text-light: #6b7280; /* Gray-500 */
    --bg-color: #f9fafb; /* Gray-50 */
    --card-bg: #ffffff;
    --header-bg: #ffffff;
    --footer-bg: #111827; /* Gray-900 */
    --border-color: #e5e7eb;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --radius: 8px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--bg-color);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: #111827;
    margin-top: 1.5em;
    margin-bottom: 0.75em;
    line-height: 1.3;
}

h1 {
    font-size: 2.25rem;
    font-weight: 800;
    letter-spacing: -0.025em;
}

h2 {
    font-size: 1.75rem;
    font-weight: 700;
    border-bottom: 2px solid var(--primary-color);
    display: inline-block;
    padding-bottom: 0.25rem;
}

h3 {
    font-size: 1.35rem;
    font-weight: 600;
}

p {
    margin-bottom: 1.25rem;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

strong, b {
    font-weight: 600;
    color: #111827;
}

/* Header */
header {
    background-color: var(--header-bg);
    color: #111827;
    padding: 1.25rem 1rem;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
}

header a {
    color: #111827;
    font-size: 1.25rem;
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

header a:hover {
    color: var(--primary-color);
    text-decoration: none;
}

/* Main Content */
main {
    flex: 1;
    width: 100%;
    max-width: 1200px; /* Widened from 800px */
    margin: 0 auto;
    box-sizing: border-box;
}

.page-home {
    padding: 60px 20px;
}

/* Spacing for other pages */
.page-content {
    background: var(--card-bg);
    padding: 3rem 2.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    margin-top: 2rem;
    border: 1px solid var(--border-color);
}

@media (max-width: 640px) {
    .page-content {
        padding: 1.5rem;
    }
}

/* Blog Styles */
.blog-post {
    background: var(--card-bg);
    padding: 2.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    margin-top: 2rem;
    border: 1px solid var(--border-color);
}

@media (max-width: 640px) {
    .blog-post {
        padding: 1.5rem;
    }
    h1 {
        font-size: 1.75rem;
    }
}

/* Images */
img.hero-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    margin-bottom: 2rem;
    object-fit: cover;
    max-height: 500px;
}

/* Lists */
ul {
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
}

li {
    margin-bottom: 0.5rem;
    position: relative;
}

/* Footer */
footer {
    background-color: var(--footer-bg);
    color: #d1d5db;
    padding: 3rem 1rem;
    text-align: center;
    font-size: 0.95rem;
}

footer nav {
    margin-bottom: 1.5rem;
}

footer a {
    color: #d1d5db;
    margin: 0 15px;
    font-weight: 500;
}

footer a:hover {
    color: white;
    text-decoration: none;
}

/* Back to Top Button */
#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 50%;
    cursor: pointer;
    display: none; /* Controlled by JS */
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
    z-index: 50;
    /* display: flex; - handled by JS */
    align-items: center;
    justify-content: center;
}

#back-to-top:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px -2px rgba(0, 0, 0, 0.15);
}

#back-to-top svg {
    width: 24px;
    height: 24px;
    stroke-width: 2.5;
}
