:root {
    /* Light Mode (default) colors from dev.dmodena.me */
    --bg-color: rgb(245, 245, 245);       /* var(--code-bg) */
    --card-bg: rgb(255, 255, 255);        /* var(--entry) */
    --card-hover: rgb(240, 240, 240);
    --text-primary: rgb(30, 30, 30);      /* var(--primary) */
    --text-secondary: rgb(108, 108, 108);  /* var(--secondary) */
    --border-color: rgb(238, 238, 238);   /* var(--border) */
    --border-hover: rgb(214, 214, 214);
    --shadow-color: rgba(0, 0, 0, 0.05);
    --accent: rgb(30, 30, 30);
    
    /* Fonts from dev.dmodena.me */
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
    --font-serif: Georgia, Cambria, "Times New Roman", Times, serif;
}

@media (prefers-color-scheme: dark) {
    :root {
        /* Dark Mode overrides from dev.dmodena.me */
        --bg-color: rgb(29, 30, 32);         /* var(--theme) */
        --card-bg: rgb(46, 46, 51);          /* var(--entry) */
        --card-hover: rgb(55, 56, 62);
        --text-primary: rgb(218, 218, 219);  /* var(--primary) */
        --text-secondary: rgb(155, 156, 157);/* var(--secondary) */
        --border-color: rgb(51, 51, 51);     /* var(--border) */
        --border-hover: rgb(65, 66, 68);
        --shadow-color: rgba(0, 0, 0, 0.2);
        --accent: rgb(218, 218, 219);
    }

    .profile-icon img {
        filter: invert(0.9);
    }
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
}

body {
    background: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-sans);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    padding: 60px 24px 30px 24px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Container limits width and handles vertical centering on desktop */
.profile-container {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-top: auto;
    margin-bottom: auto;
}

/* Avatar circular photo with clean border matching blog style */
.profile-avatar {
    width: 130px;
    height: 130px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--border-color);
    box-shadow: 0 4px 20px var(--shadow-color);
    margin-bottom: 24px;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.profile-avatar:hover {
    transform: scale(1.05);
    border-color: var(--accent);
    box-shadow: 0 8px 30px var(--shadow-color);
}

/* Profile name styling */
.profile-name {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

/* Tagline description in serif italic format */
.profile-tagline {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-style: italic;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 36px;
    max-width: 320px;
}

/* Link tree list styling */
.profile-links {
    list-style: none;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 40px;
}

.profile-links li {
    width: 100%;
}

/* Card buttons matching blog post card styling */
.profile-links a {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 16px 20px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px; /* PaperMod standard border-radius */
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 8px var(--shadow-color);
}

.profile-links a:hover {
    background: var(--card-hover);
    border-color: var(--border-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px var(--shadow-color);
}

.profile-links a:active {
    transform: translateY(-1px) scale(0.99);
}

/* Circular background block for the icon */
.profile-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-color);
    margin-right: 18px;
    transition: background-color 0.2s ease;
}

.profile-links a:hover .profile-icon {
    background: var(--card-bg);
}

/* SVG Icon inside */
.profile-icon img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    display: block;
    transition: filter 0.2s ease;
}

/* Pseudo-element arrow icon on the right */
.profile-links a::after {
    content: "→";
    font-size: 1.3rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-left: auto;
    transition: transform 0.2s ease, color 0.2s ease;
}

.profile-links a:hover::after {
    transform: translateX(5px);
    color: var(--text-primary);
}

/* Copyright footer matching blog footer */
.profile-footer {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-align: center;
    padding-top: 20px;
    width: 100%;
}

.profile-footer p {
    font-weight: 400;
    letter-spacing: 0.2px;
}

/* Media Query for mobile screen optimizations */
@media (max-width: 480px) {
    body {
        padding: 40px 16px 20px 16px;
    }
    
    .profile-avatar {
        width: 110px;
        height: 110px;
        margin-bottom: 20px;
    }
    
    .profile-name {
        font-size: 1.8rem;
    }
    
    .profile-tagline {
        font-size: 1.05rem;
        margin-bottom: 28px;
    }
    
    .profile-links {
        gap: 12px;
    }
    
    .profile-links a {
        padding: 14px 16px;
        font-size: 1rem;
    }
}
