/*
 * style.css - Gen-Z Black & White Core Theme
 * Simplified for maximum contrast and minimalist aesthetic, now with subtle decorations.
 */

/* 1. Global Styles & Variables */
:root {
    /* Black & White Palette */
    --color-white: #FFFFFF;
    --color-black: #000000;
    --color-light-gray: #F2F2F2; /* Very light background for contrast */
    --color-mid-gray: #CCCCCC; /* Used for borders/separators */
    --color-dark-gray: #333333; /* Main text color */
    --color-off-white: #F8F8F8; /* Slightly off-white for elements */
    --color-focus-outline: rgba(0, 0, 0, 0.5); /* Semi-transparent black for outlines */

    /* Typography */
    --font-family-body: 'Inter', sans-serif;
    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-bold: 700;
    --font-weight-extrabold: 800; /* For strong titles */
    --font-weight-black: 900; /* Even stronger for hero titles */

    /* Spacing */
    --spacing-xs: 8px;
    --spacing-sm: 16px;
    --spacing-md: 24px;
    --spacing-lg: 32px;
    --spacing-xl: 48px;
    --spacing-xxl: 64px;

    /* Border Radius */
    --border-radius-sm: 4px;
    --border-radius-md: 8px;
    --border-radius-lg: 12px; /* Slightly larger radius for cards */
}

/* Base Styles */
html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family-body);
    line-height: 1.75; /* Slightly more open for readability */
    color: var(--color-dark-gray);
    background-color: var(--color-light-gray);
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative; /* For background decorations */
    overflow-x: hidden; /* Prevent horizontal scroll from subtle movements */
}

/* Subtle background grid pattern on body for a tech/science feel */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(to right, rgba(0, 0, 0, 0.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 0, 0, 0.03) 1px, transparent 1px);
    background-size: 30px 30px;
    opacity: 0.5;
    z-index: -1; /* Send to back */
    pointer-events: none; /* Ensure elements below are clickable */
}


/* Container for consistent content width */
.container {
    max-width: 960px;
    margin: 0 auto;
    padding: var(--spacing-sm);
    box-sizing: border-box;
}

/* Links */
a {
    color: var(--color-black); /* Links are black */
    text-decoration: none;
    position: relative; /* For underline effect */
    transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
    opacity: 0.8;
}

a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    display: block;
    margin-top: 2px;
    right: 0;
    background: var(--color-black);
    transition: width 0.3s ease;
}

a:hover::after {
    width: 100%;
    left: 0;
    background: var(--color-black);
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    color: var(--color-black);
    line-height: 1.25;
    margin-bottom: var(--spacing-sm);
    font-weight: var(--font-weight-extrabold); /* Stronger headings */
    position: relative; /* For decorative elements */
    padding-bottom: var(--spacing-xs); /* Space for underline */
}

h1 {
    font-size: 3em;
    font-weight: var(--font-weight-black);
    text-shadow: 1px 1px 0 rgba(0,0,0,0.1); /* Subtle shadow for depth */
}

h2 {
    font-size: 2.4em;
    margin-top: var(--spacing-lg);
    border-left: 3px solid var(--color-dark-gray); /* Simple left border */
    padding-left: var(--spacing-sm);
}

h3 {
    font-size: 1.8em;
    margin-top: var(--spacing-md);
    border-bottom: 1px dashed var(--color-mid-gray); /* Dashed underline */
    padding-bottom: var(--spacing-xs);
}

p {
    margin-bottom: var(--spacing-md); /* More space between paragraphs */
}

/* Focus states for accessibility */
*:focus-visible {
    outline: 2px solid var(--color-focus-outline);
    outline-offset: 2px;
    border-radius: var(--border-radius-sm);
}

/* 2. Header Specific Styles */
.main-header {
    background-color: var(--color-white);
    padding: var(--spacing-md) 0;
    border-bottom: 1px solid var(--color-mid-gray); /* Border on header bottom */
    box-shadow: 0 2px 5px rgba(0,0,0,0.05); /* Subtle shadow for lift */
    position: sticky; /* Make header sticky */
    top: 0;
    z-index: 1000;
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.webpage-name {
    margin: 0;
    font-size: 2.4em;
    font-weight: var(--font-weight-black);
    letter-spacing: -0.5px; /* Tighter letter spacing */
}

.webpage-name a {
    color: var(--color-black);
    text-decoration: none;
}

/* Navigation Styles */
.main-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: var(--spacing-lg); /* Increased space between nav items */
    flex-wrap: wrap;
    justify-content: center;
}

.main-nav ul li a {
    color: var(--color-dark-gray);
    text-decoration: none;
    font-weight: var(--font-weight-medium);
    padding: 8px 15px; /* Slightly more padding */
    border-radius: var(--border-radius-sm);
    transition: background-color 0.2s ease, color 0.2s ease; /* Removed transform transition */
    text-transform: uppercase; /* Gen-Z vibe */
    letter-spacing: 0.8px; /* More pronounced letter spacing */
    /* Removed position: relative; and overflow: hidden; */
}

/* Removed .main-nav ul li a::before rule entirely */

.main-nav ul li a:hover {
    background-color: var(--color-black);
    color: var(--color-white);
    /* Removed transform: translateY(-1px); */
}

/* Active navigation link */
.main-nav ul li a.active {
    background-color: var(--color-black);
    color: var(--color-white);
    font-weight: var(--font-weight-bold); /* Bold active link */
}

/* 3. Main Content Area */
.main-content {
    flex-grow: 1;
    padding: var(--spacing-xxl) 0; /* More padding top/bottom */
    position: relative;
    z-index: 1;
}

/* 4. Landing Page Specific Styles (index.php) */
.landing-page {
    text-align: center;
    padding: var(--spacing-xl) var(--spacing-md);
    background-color: var(--color-white);
    border-radius: var(--border-radius-lg); /* Larger border radius */
    box-shadow: 0 8px 20px rgba(0,0,0,0.08); /* More noticeable shadow */
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xl);
}

.hero-section {
    padding: var(--spacing-lg);
    background: radial-gradient(circle at center, rgba(0,0,0,0.02) 0%, transparent 70%); /* Subtle radial gradient */
    border-radius: var(--border-radius-lg);
}

.hero-title {
    font-size: 4em; /* Larger hero title */
    color: var(--color-black);
    margin-bottom: var(--spacing-sm);
    line-height: 1.05;
    text-shadow: 2px 2px 0 rgba(0,0,0,0.15); /* More pronounced text shadow */
}

.hero-subtitle {
    font-size: 1.3em;
    color: var(--color-dark-gray);
    margin-bottom: var(--spacing-lg);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    font-weight: var(--font-weight-medium);
}

.cta-button {
    display: inline-block;
    padding: 15px 30px; /* Larger padding for button */
    background-color: var(--color-black);
    color: var(--color-white);
    border: none;
    border-radius: var(--border-radius-md); /* Slightly larger radius */
    font-size: 1.2em;
    font-weight: var(--font-weight-bold);
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1.5px; /* More pronounced letter spacing */
    box-shadow: 0 5px 15px rgba(0,0,0,0.2); /* Stronger shadow */
}

.cta-button:hover {
    background-color: var(--color-dark-gray);
    transform: translateY(-3px); /* More pronounced lift */
    box-shadow: 0 8px 20px rgba(0,0,0,0.3); /* Stronger shadow on hover */
}

.no-content-message {
    text-align: center;
    font-size: 1.1em;
    color: var(--color-dark-gray);
    padding: var(--spacing-lg);
    background-color: var(--color-white);
    border-radius: var(--border-radius-md);
    border: 1px solid var(--color-mid-gray);
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

/* 5. Blog List Page Styles (articles-menu.php) */
.blog-list {
    background-color: var(--color-white);
    padding: var(--spacing-xl);
    border-radius: var(--border-radius-lg);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

.blog-list h1 {
    text-align: center;
    margin-bottom: var(--spacing-xxl); /* More space */
    font-size: 3.5em;
    color: var(--color-black);
    position: relative;
    display: inline-block; /* For the pseudo-element underline */
}

.blog-list h1::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -10px; /* Position below text */
    transform: translateX(-50%);
    width: 60px; /* Short underline */
    height: 3px;
    background-color: var(--color-black);
    border-radius: 2px;
}

.blog-post-preview {
    background-color: var(--color-off-white);
    padding: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
    border-radius: var(--border-radius-lg); /* Larger radius */
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    border: 1px solid var(--color-mid-gray);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    position: relative;
    overflow: hidden; /* For subtle background animation */
}

.blog-post-preview::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(0,0,0,0.02) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
}

.blog-post-preview:hover::before {
    opacity: 1;
}

.blog-post-preview:hover {
    transform: translateY(-5px); /* More pronounced lift */
    box-shadow: 0 10px 25px rgba(0,0,0,0.15); /* Stronger shadow */
    border-color: var(--color-dark-gray); /* Darker border on hover */
}

.blog-post-preview h2 {
    font-size: 2em;
    margin-bottom: var(--spacing-xs);
    border-left: none;
    padding-left: 0;
}

.blog-post-preview h2 a {
    color: var(--color-black);
    font-weight: var(--font-weight-extrabold);
    transition: color 0.2s ease;
}

.blog-post-preview h2 a:hover {
    color: var(--color-dark-gray); /* Subtle change on hover */
}

.blog-post-preview .post-meta {
    font-size: 0.9em;
    color: var(--color-dark-gray);
    margin-bottom: var(--spacing-sm);
}

.blog-post-preview .category,
.blog-post-preview .tags a {
    background-color: var(--color-black);
    color: var(--color-white);
    padding: 5px 12px; /* Slightly more padding */
    border-radius: var(--border-radius-sm);
    font-size: 0.8em;
    font-weight: var(--font-weight-medium);
    display: inline-block;
    margin-right: 8px;
    vertical-align: middle;
    text-transform: uppercase;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.blog-post-preview .tags a:hover {
    background-color: var(--color-dark-gray);
    transform: scale(1.05); /* Slight scale on hover */
}

.blog-post-preview p {
    color: var(--color-dark-gray);
}

.blog-post-preview .read-more {
    display: inline-block;
    margin-top: var(--spacing-md);
    padding: 10px 22px; /* Larger button */
    background-color: var(--color-black);
    color: var(--color-white);
    border-radius: var(--border-radius-sm);
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    font-weight: var(--font-weight-bold);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

.blog-post-preview .read-more:hover {
    background-color: var(--color-dark-gray);
    transform: translateY(-2px);
    box-shadow: 0 5px 12px rgba(0,0,0,0.25);
}

/* 6. Individual Article Page Styles */
.article-page {
    background-color: var(--color-white);
    padding: var(--spacing-xl);
    border-radius: var(--border-radius-lg);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

.article-header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid var(--color-mid-gray);
    position: relative;
    overflow: hidden;
}

.article-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, rgba(0,0,0,0.01) 25%, transparent 25%, transparent 75%, rgba(0,0,0,0.01) 75%, rgba(0,0,0,0.01));
    background-size: 40px 40px;
    opacity: 0.7;
    z-index: 0;
    pointer-events: none;
}

.article-header h1 {
    font-size: 3.5em;
    margin-bottom: var(--spacing-xs);
    position: relative; /* Ensure text is above pseudo-element */
    z-index: 1;
}

.article-header .post-meta {
    font-size: 0.95em;
    color: var(--color-dark-gray);
    margin-bottom: var(--spacing-sm);
    position: relative;
    z-index: 1;
}

.article-header .category,
.article-header .tags a {
    background-color: var(--color-black);
    color: var(--color-white);
    padding: 6px 14px; /* Larger padding */
    border-radius: var(--border-radius-sm);
    font-size: 0.85em;
    font-weight: var(--font-weight-medium);
    display: inline-block;
    margin-right: 8px;
    vertical-align: middle;
    text-transform: uppercase;
    transition: background-color 0.2s ease, transform 0.2s ease;
    position: relative;
    z-index: 1;
}

.article-header .tags a:hover {
    background-color: var(--color-dark-gray);
    transform: scale(1.05);
}

.blog-content {
    color: var(--color-dark-gray);
    font-size: 1.15em; /* Slightly larger body text */
    line-height: 1.8; /* Enhanced readability */
}

.blog-content p {
    color: var(--color-dark-gray);
    margin-bottom: var(--spacing-md);
}

.blog-content img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius-md); /* Match card radius */
    margin: var(--spacing-md) auto; /* Centers image */
    display: block;
    border: 1px solid var(--color-mid-gray);
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    transition: transform 0.3s ease;
}

.blog-content img:hover {
    transform: scale(1.01); /* Subtle zoom on image hover */
}

.blog-content .video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    margin: var(--spacing-md) 0;
    border-radius: var(--border-radius-md);
    background-color: var(--color-black);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.blog-content .video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.blog-content ul,
.blog-content ol {
    margin-bottom: var(--spacing-md);
    padding-left: var(--spacing-lg); /* More indentation */
    color: var(--color-dark-gray);
    list-style: none; /* Remove default bullet */
}

.blog-content ul li {
    margin-bottom: var(--spacing-xs);
    color: var(--color-dark-gray);
    position: relative;
    padding-left: var(--spacing-md); /* Space for custom bullet */
}

.blog-content ul li::before {
    content: '→'; /* Custom arrow bullet point */
    position: absolute;
    left: 0;
    color: var(--color-black);
    font-weight: var(--font-weight-bold);
}
.blog-content ol li {
    margin-bottom: var(--spacing-xs);
    color: var(--color-dark-gray);
}


/* 7. Comments Section Styles */
.comments-section {
    margin-top: var(--spacing-xl);
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--color-mid-gray);
}

.comments-section h2 {
    text-align: center;
    margin-bottom: var(--spacing-lg);
    font-size: 2.5em;
    color: var(--color-black);
    border-left: none;
    padding-left: 0;
}

.comments-list {
    background-color: var(--color-off-white);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-md);
    border: 1px solid var(--color-mid-gray);
    margin-bottom: var(--spacing-md);
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.comment-item {
    padding: var(--spacing-sm);
    border-bottom: 1px dashed var(--color-mid-gray); /* Dashed border for visual separation */
    margin-bottom: var(--spacing-sm);
    background-color: var(--color-white);
    border-radius: var(--border-radius-sm);
    transition: background-color 0.2s ease;
}

.comment-item:hover {
    background-color: var(--color-off-white); /* Slight highlight on hover */
}

.comment-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.commenter-info {
    display: flex;
    align-items: center;
    margin-bottom: var(--spacing-xs);
    font-weight: var(--font-weight-bold);
    color: var(--color-black);
    font-size: 0.9em;
}

.commenter-info .commenter-name {
    margin-right: var(--spacing-sm);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.commenter-info .created-at {
    font-size: 0.8em;
    color: var(--color-dark-gray);
}

.comment-text {
    font-size: 1em;
    color: var(--color-dark-gray);
    margin-top: var(--spacing-xs);
}

.comment-form {
    background-color: var(--color-off-white);
    padding: var(--spacing-md);
    border-radius: var(--border-radius-md);
    border: 1px solid var(--color-mid-gray);
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.comment-form label {
    display: block;
    margin-bottom: 5px;
    color: var(--color-dark-gray);
    font-weight: var(--font-weight-medium);
    text-transform: uppercase;
    font-size: 0.9em;
}

.comment-form input[type="text"],
.comment-form textarea {
    width: calc(100% - 20px);
    padding: 10px;
    border: 1px solid var(--color-mid-gray);
    background-color: var(--color-white);
    color: var(--color-black);
    border-radius: var(--border-radius-sm);
    font-family: var(--font-family-body);
    font-size: 1em;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.comment-form input[type="text"]:focus,
.comment-form textarea:focus {
    border-color: var(--color-black);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0,0,0,0.1); /* Subtle black glow */
}

.comment-form textarea {
    resize: vertical;
    min-height: 100px; /* Slightly taller textarea */
}

.comment-form button {
    padding: 14px 30px; /* Larger button */
    background-color: var(--color-black);
    color: var(--color-white);
    border: none;
    border-radius: var(--border-radius-md); /* More rounded button */
    cursor: pointer;
    font-size: 1.1em;
    font-weight: var(--font-weight-bold);
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    align-self: flex-end;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.comment-form button:hover {
    background-color: var(--color-dark-gray);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.comment-form button:disabled {
    background-color: var(--color-mid-gray);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 8. Footer Specific Styles */
.main-footer {
    background-color: var(--color-white);
    padding: var(--spacing-md) 0;
    border-top: 1px solid var(--color-mid-gray); /* Border on footer top */
    text-align: center;
    color: var(--color-dark-gray);
    font-size: 0.9em;
    margin-top: var(--spacing-xl);
    box-shadow: 0 -2px 5px rgba(0,0,0,0.05); /* Subtle shadow for lift */
    position: relative;
    overflow: hidden;
}

.main-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        45deg,
        rgba(0,0,0,0.02),
        rgba(0,0,0,0.02) 10px,
        transparent 10px,
        transparent 20px
    );
    opacity: 0.3;
    z-index: 0;
    pointer-events: none;
    animation: moveGradient 30s linear infinite; /* Subtle background movement */
}

@keyframes moveGradient {
    0% { background-position: 0% 0%; }
    100% { background-position: 100% 100%; }
}

.main-footer .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-xs);
    position: relative; /* Ensure content is above pseudo-element */
    z-index: 1;
}

.main-footer p {
    margin: 0;
    color: var(--color-dark-gray);
}

.main-footer .footer-nav {
    margin-top: var(--spacing-sm);
}

.main-footer .footer-nav a {
    color: var(--color-dark-gray);
    margin: 0 10px;
    font-weight: var(--font-weight-medium);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.main-footer .footer-nav a:hover {
    color: var(--color-black);
}

/* 9. Responsive Adjustments */
@media (max-width: 768px) {
    .container {
        padding: var(--spacing-xs);
    }
    h1 {
        font-size: 2.5em;
    }
    h2 {
        font-size: 1.8em;
    }
    .webpage-name {
        font-size: 2.2em;
        margin-bottom: var(--spacing-sm);
    }
    .main-header .container {
        flex-direction: column;
        gap: var(--spacing-sm);
    }
    .main-nav ul {
        flex-direction: column;
        text-align: center;
        gap: var(--spacing-xs);
        width: 100%;
    }
    .blog-list, .article-page, .landing-page {
        padding: var(--spacing-md);
    }
    .article-header h1 {
        font-size: 2.8em;
    }
    .blog-content {
        font-size: 1.05em;
    }
    .comment-form button {
        align-self: stretch;
    }
    .hero-title {
        font-size: 3.2em;
    }
    .hero-subtitle {
        font-size: 1.1em;
    }
    .cta-button {
        width: 100%;
        padding: 12px 20px;
        font-size: 1.05em;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2em;
    }
    .webpage-name {
        font-size: 1.8em;
    }
    .blog-list h1 {
        font-size: 2.5em;
    }
    .blog-post-preview h2 {
        font-size: 1.6em;
    }
    .article-header h1 {
        font-size: 2.2em;
    }
    .hero-title {
        font-size: 2.8em;
    }
    .cta-button {
        font-size: 1em;
        padding: 10px 15px;
    }
}


/*
HOMEPAGE

*/

/* Styles for the pop-up overlay (from previous version, retained) */
    .popup-overlay {
        position: fixed; /* Fixes the overlay to the viewport */
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.6); /* Semi-transparent black background */
        display: flex; /* Use flexbox for centering */
        justify-content: center; /* Center horizontally */
        align-items: center; /* Center vertically */
        z-index: 1000; /* Ensure it's on top of other content */
        opacity: 0; /* Start hidden */
        visibility: hidden; /* Start invisible */
        transition: opacity 0.3s ease-out, visibility 0.3s ease-out; /* Smooth transition */
    }
    .popup-overlay.show {
        opacity: 1; /* Fade in */
        visibility: visible; /* Make visible */
    }
    /* Styles for the pop-up box (from previous version, retained) */
    .popup-box {
        background: linear-gradient(135deg, #6BFFB8, #6BFFD9); /* Bright, fresh gradient */
        color: #1a202c; /* Dark text for contrast */
        padding: 2.5rem;
        border-radius: 2rem; /* Even more rounded */
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.5); /* Deeper shadow */
        max-width: 90%;
        width: 450px;
        position: relative; /* For positioning the close button */
        transform: translateY(-50px) scale(0.9); /* Start slightly off and smaller */
        opacity: 0; /* Start hidden */
        transition: transform 0.4s ease-out, opacity 0.4s ease-out; /* Smooth pop-in */
    }
    .popup-overlay.show .popup-box {
        transform: translateY(0) scale(1); /* Pop into place */
        opacity: 1; /* Fade in */
    }
    /* Styles for the close button (from previous version, retained) */
    .popup-close-btn {
        position: absolute;
        top: 1rem;
        right: 1rem;
        background-color: #ff4d4d; /* Red button */
        color: white;
        border: none;
        border-radius: 50%; /* Circular button */
        width: 2.5rem;
        height: 2.5rem;
        font-size: 1.5rem;
        cursor: pointer;
        display: flex;
        justify-content: center;
        align-items: center;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
        transition: background-color 0.2s ease-in-out, transform 0.2s ease-in-out;
    }
    .popup-close-btn:hover {
        background-color: #e60000; /* Darker red on hover */
        transform: rotate(90deg); /* Spin on hover */
    }
    /* Pop-up header and paragraph styling (from previous version, retained) */
    .popup-box h2 {
        font-size: 2.5rem; /* Larger header */
        font-weight: 700;
        margin-bottom: 1rem;
    }
    .popup-box p {
        font-size: 1.25rem;
        font-weight: 400;
        line-height: 1.5;
        opacity: 0.9;
    }

    /* --- NEW STYLES FOR PERSONAL INFO CARDS --- */

    /* Grid for arranging personal info cards */
    .personal-info-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* Responsive grid columns */
        gap: var(--spacing-lg); /* Spacing between cards */
        padding: var(--spacing-xl) 0; /* Padding around the grid */
        margin-top: var(--spacing-xl); /* Space above this section */
    }

    /* Styling for individual personal info cards, similar to blog-post-preview */
    .personal-info-card {
        background-color: var(--color-off-white);
        padding: var(--spacing-lg);
        border-radius: var(--border-radius-lg); /* Larger radius for consistent look */
        box-shadow: 0 4px 10px rgba(0,0,0,0.05);
        border: 1px solid var(--color-mid-gray);
        transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
        position: relative;
        overflow: hidden; /* For subtle background animation */
        display: flex; /* Use flexbox for vertical content arrangement */
        flex-direction: column;
        justify-content: space-between; /* Pushes footer content down if needed */
        min-height: 250px; /* Ensure cards have a minimum height for consistency */
    }

    .personal-info-card::before {
        content: '';
        position: absolute;
        top: -50%;
        left: -50%;
        width: 200%;
        height: 200%;
        background: radial-gradient(circle, rgba(0,0,0,0.02) 0%, transparent 70%);
        opacity: 0;
        transition: opacity 0.3s ease;
        z-index: 0;
    }

    .personal-info-card:hover::before {
        opacity: 1;
    }

    .personal-info-card:hover {
        transform: translateY(-5px); /* More pronounced lift */
        box-shadow: 0 10px 25px rgba(0,0,0,0.15); /* Stronger shadow */
        border-color: var(--color-dark-gray); /* Darker border on hover */
    }

    .personal-info-card .card-header {
        position: relative;
        z-index: 1; /* Ensure content is above pseudo-element */
        margin-bottom: var(--spacing-sm);
    }

    .personal-info-card .card-header h2 {
        font-size: 1.8em; /* Slightly smaller than blog post titles for hierarchy */
        margin-bottom: var(--spacing-xs);
        border-left: none; /* Remove left border for cards */
        padding-left: 0;
        color: var(--color-black);
        font-weight: var(--font-weight-extrabold);
    }

    .personal-info-card .card-body {
        font-size: 1em;
        color: var(--color-dark-gray);
        flex-grow: 1; /* Allows content area to take available space */
        position: relative;
        z-index: 1;
    }

    .personal-info-card .card-body p {
        margin-bottom: var(--spacing-sm);
    }

    .profile-picture {
        width: 100px;
        height: 100px;
        border-radius: 50%; /* Circular image */
        object-fit: cover; /* Ensures image covers the area without distortion */
        margin-bottom: var(--spacing-sm);
        border: 2px solid var(--color-black); /* A nice border */
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    }

    /* Ensure text within cards has good contrast */
    .personal-info-card strong {
        font-weight: var(--font-weight-bold);
        color: var(--color-black);
    }
    .personal-info-card ul {
        list-style: none; /* Remove default bullets */
        padding-left: 0;
    }
    .personal-info-card ul li {
        margin-bottom: 5px;
        position: relative;
        padding-left: 20px;
        color: var(--color-dark-gray);
    }
    .personal-info-card ul li::before {
        content: '▪'; /* Custom bullet point */
        position: absolute;
        left: 0;
        color: var(--color-black);
        font-weight: var(--font-weight-bold);
        font-size: 1.2em;
        line-height: 1;
    }

    /* --- SPECIFIC STYLES FOR THE "WHO AM I?" HERO CARD --- */
    .hero-personal-card {
        max-width: 700px; /* Make it wider than normal cards */
        margin: var(--spacing-xl) auto; /* Center it with top/bottom margin */
        padding: var(--spacing-xxl); /* More generous padding */
        text-align: center; /* Center content within the card */
    }

    .hero-personal-card .profile-picture {
        width: 150px; /* Larger profile picture */
        height: 150px;
        margin-bottom: var(--spacing-md);
    }

    .hero-personal-card .card-header h2 {
        font-size: 2.5em; /* Larger title for the hero card */
    }

    .hero-personal-card .card-body p {
        font-size: 1.1em; /* Slightly larger text for emphasis */
        max-width: 600px;
        margin-left: auto;
        margin-right: auto;
    }

    /* --- CAROUSEL STYLES --- */
    .carousel-container {
        position: relative;
        width: 100%;
        max-width: 960px; /* Match container width */
        margin: var(--spacing-xxl) auto; /* Center with ample vertical space */
        overflow: hidden;
        border-radius: var(--border-radius-lg);
        box-shadow: 0 8px 20px rgba(0,0,0,0.08);
        background-color: var(--color-white);
        border: 1px solid var(--color-mid-gray);
    }

    .carousel-slides {
        display: flex;
        width: 100%; /* Will be multiplied by number of slides in JS */
        transition: transform 0.5s ease-in-out;
    }

    .carousel-slide {
        min-width: 100%; /* Each slide takes full width of container */
        box-sizing: border-box;
        display: flex;
        justify-content: center;
        align-items: center;
        padding: var(--spacing-md);
    }

    .carousel-slide img {
        width: 100%;
        height: auto;
        max-height: 400px; /* Limit image height */
        object-fit: cover; /* Cover area without distortion */
        border-radius: var(--border-radius-md);
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    }

    .carousel-dots {
        text-align: center;
        padding: var(--spacing-sm);
        position: absolute;
        bottom: 10px;
        left: 50%;
        transform: translateX(-50%);
        z-index: 10;
    }

    .dot {
        height: 10px;
        width: 10px;
        margin: 0 5px;
        background-color: var(--color-mid-gray);
        border-radius: 50%;
        display: inline-block;
        cursor: pointer;
        transition: background-color 0.3s ease, transform 0.3s ease;
    }

    .dot.active, .dot:hover {
        background-color: var(--color-black);
        transform: scale(1.2);
    }

    /* Responsive adjustments for personal info grid */
    @media (max-width: 768px) {
        .personal-info-grid {
            grid-template-columns: 1fr; /* Single column on smaller screens */
            padding: var(--spacing-md) 0;
        }
        .personal-info-card {
            min-height: auto; /* Allow height to adapt */
        }
        .hero-personal-card {
            padding: var(--spacing-lg); /* Adjust padding for smaller screens */
            margin: var(--spacing-lg) auto; /* Adjust margin */
        }
        .hero-personal-card .profile-picture {
            width: 100px; /* Adjust image size for mobile */
            height: 100px;
        }
        .hero-personal-card .card-header h2 {
            font-size: 2em; /* Adjust title size for mobile */
        }
        .hero-personal-card .card-body p {
            font-size: 1em; /* Adjust text size for mobile */
        }
        .carousel-container {
            margin: var(--spacing-xl) auto;
            border-radius: var(--border-radius-md);
        }
    }
    @media (max-width: 480px) {
        .personal-info-card .card-header h2 {
            font-size: 1.5em;
        }
        .hero-personal-card .card-header h2 {
            font-size: 1.8em;
        }
    }