/* Global */
:root {
    --bg: #14171c;
    --surface: #20252c;
    --text: #f5f5f5;
    --muted: #9ba5b4;
    --accent: #68b7ff;
    --border: #323842;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.7;
}

/* Header */
header {
    max-width: 1100px;
    margin: 0 auto;
    padding: 30px 24px;
}

header h1 {
    margin: 0;
    font-size: 28px;
}

header p {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    letter-spacing: 1px;
}

nav {
    display: flex;
    gap: 24px;
    margin-top: 20px;
}

nav a {
    color: var(--muted);
    text-decoration: none;
    font-size: 14px;
}

nav a:hover {
    color: var(--accent);
}

/* Main Content */
main {
    max-width: 1100px;
    min-height: 65vh;
    margin: 0 auto;
    padding: 50px 24px;
}

main h2 {
    font-size: 32px;
    margin-top: 0;
}

main p {
    color: var(--muted);
}

/* Sections */
section {
    margin-bottom: 48px;
}

section h3 {
    font-size: 20px;
}

/* Footer */
footer {
    max-width: 1100px;
    margin: 0 auto;
    padding: 24px;
    border-top: 1px solid var(--border);
}

footer p {
    color: var(--muted);
    font-size: 13px;
}

/* Responsive */
@media (max-width: 600px) {
    header {
        padding: 24px 16px;
    }

    main {
        padding: 32px 16px;
    }

    main h2 {
        font-size: 26px;
    }

    nav {
        gap: 16px;
        flex-wrap: wrap;
    }
}


/* Development Log List */

.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
    gap: 24px;
    margin-top: 32px;
}

.post-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 24px;
    transition: border-color 0.2s ease,
                transform 0.2s ease;
}

.post-card:hover {
    border-color: var(--accent);
    transform: translateY(-3px);
}

.post-card time {
    color: var(--muted);
    font-size: 12px;
}

.post-card h3 {
    margin: 12px 0;
    font-size: 20px;
}

.post-card h3 a {
    color: var(--text);
    text-decoration: none;
}

.post-card h3 a:hover {
    color: var(--accent);
}

.post-card p {
    color: var(--muted);
    font-size: 14px;
}

.read-more {
    display: inline-block;
    margin-top: 12px;
    color: var(--accent);
    text-decoration: none;
    font-size: 14px;
}

.read-more:hover {
    text-decoration: underline;
}

/* Individual Development Log */

.post-detail {
    max-width: 850px;
    margin: 0 auto;
}

.post-detail-header {
    padding: 0 0 30px;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--border);
}

.post-detail-header h1 {
    font-size: clamp(28px, 5vw, 42px);
    line-height: 1.3;
    margin-bottom: 16px;
}

.post-detail-header time {
    color: var(--accent);
    font-size: 13px;
}

.post-content {
    line-height: 1.9;
}

.post-content h2 {
    margin-top: 48px;
    font-size: 26px;
}

.post-content h3 {
    margin-top: 32px;
    font-size: 21px;
}

.post-content img,
.post-content video {
    display: block;
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 24px auto;
}

.post-content a {
    color: var(--accent);
}

.post-back {
    margin-top: 64px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.post-back a {
    color: var(--accent);
    text-decoration: none;
}

/* Post Thumbnail */

.post-card {
    padding: 0;
    overflow: hidden;
}

.post-thumbnail {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #292f38;
}

.post-thumbnail img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post-card:hover .post-thumbnail img {
    transform: scale(1.04);
}

.thumbnail-placeholder {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
    justify-content: center;
    color: var(--muted);
    font-size: 14px;
}

.post-card-body {
    padding: 24px;
}

/* Home Page */

.home-intro {
    padding: 30px 0 50px;
}

.home-intro h2 {
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.3;
}

.recent-posts {
    margin-top: 30px;
}

.view-all {
    margin-top: 32px;
    text-align: center;
}

.view-all a {
    color: var(--accent);
    text-decoration: none;
    font-size: 14px;
}

.view-all a:hover {
    text-decoration: underline;
}


/* About Page */

.about-page {
    max-width: 850px;
    margin: 0 auto;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 28px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--border);
}

.profile-avatar {
    width: 120px;
    height: 120px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--surface);
    overflow: hidden;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-info h1 {
    margin: 0 0 8px;
    font-size: 32px;
}

.profile-info p {
    margin: 4px 0;
}

.profile-role {
    color: var(--accent) !important;
    font-size: 16px;
}

.about-content {
    margin-top: 40px;
    line-height: 1.9;
}

.about-content h2 {
    margin-top: 40px;
    font-size: 24px;
}

.about-content a {
    color: var(--accent);
}

@media (max-width: 600px) {
    .profile-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .profile-avatar {
        width: 100px;
        height: 100px;
    }
}

/* ========================================
   TA Portfolio - Visual Refinement v1
   ======================================== */

:root {
    --bg: #101318;
    --surface: #1a1f27;
    --text: #eef2f7;
    --muted: #a0aab8;
    --accent: #79baff;
    --border: #303846;
}

/* Typography */

body {
    font-family: "Segoe UI", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
    letter-spacing: -0.025em;
    line-height: 1.3;
}

a {
    transition: color 0.2s ease;
}

/* Header */

header {
    padding-top: 36px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--border);
}

header h1 {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.04em;
}

header p {
    margin-top: 6px;
    letter-spacing: 1.4px;
}

nav {
    gap: 30px;
    margin-top: 26px;
}

nav a {
    font-weight: 500;
}

nav a:hover {
    color: var(--text);
}

/* Main Layout */

main {
    padding-top: 60px;
    padding-bottom: 80px;
}

main h2 {
    font-weight: 700;
}

/* Cards */

.post-grid {
    gap: 28px;
}

.post-card {
    border-radius: 12px;
    background: var(--surface);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.12);
    transition:
        transform 0.25s ease,
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}

.post-card:hover {
    transform: translateY(-5px);
    border-color: #527ba5;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.24);
}

.post-thumbnail {
    background: #252c36;
}

.post-thumbnail img {
    transition: transform 0.4s ease;
}

.post-card:hover .post-thumbnail img {
    transform: scale(1.035);
}

.post-card-body {
    padding: 26px;
}

.post-card h3 {
    margin: 12px 0;
    font-size: 21px;
    line-height: 1.4;
}

.post-card p {
    line-height: 1.7;
}

/* Home */

.home-intro {
    padding-top: 44px;
    padding-bottom: 60px;
    border-bottom: 1px solid var(--border);
}

.home-intro h2 {
    max-width: 780px;
    font-size: clamp(32px, 4.5vw, 48px);
}

.recent-posts {
    margin-top: 44px;
}

/* Detail Page */

.post-detail-header {
    margin-bottom: 48px;
}

.post-content {
    font-size: 16px;
}

.post-content img,
.post-content video {
    border: 1px solid var(--border);
    border-radius: 10px;
}

.post-content img {
    cursor: zoom-in;
}

/* About */

.profile-avatar {
    border: 2px solid var(--border);
}

.profile-info h1 {
    font-size: 36px;
}

/* Footer */

footer {
    padding-top: 32px;
    padding-bottom: 36px;
}

footer p {
    font-size: 12px;
}

/* Mobile */

@media (max-width: 600px) {
    header {
        padding-top: 26px;
        padding-bottom: 22px;
    }

    nav {
        gap: 18px;
        margin-top: 22px;
    }

    main {
        padding-top: 36px;
        padding-bottom: 50px;
    }

    .home-intro {
        padding-top: 16px;
        padding-bottom: 36px;
    }

    .post-grid {
        gap: 20px;
    }

    .post-card-body {
        padding: 20px;
    }

    .profile-info h1 {
        font-size: 30px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .post-card,
    .post-thumbnail img,
    a {
        transition: none;
    }
}


/* Homepage Portfolio Layout */

.home-eyebrow,
.home-section-label,
.home-card-type {
    color: var(--accent) !important;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.8px;
}

.home-intro h2 {
    margin-top: 16px;
    margin-bottom: 20px;
}

.home-description {
    max-width: 650px;
    font-size: 17px;
    line-height: 1.8;
}

.home-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 30px;
}

.home-actions a {
    display: inline-block;
    padding: 12px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
}

.home-primary-link {
    background: var(--accent);
    color: #101318;
}

.home-primary-link:hover {
    background: #a4d0ff;
}

.home-secondary-link {
    color: var(--text);
    border: 1px solid var(--border);
}

.home-secondary-link:hover {
    border-color: var(--accent);
}

.home-projects {
    margin-top: 55px;
    margin-bottom: 75px;
}

.home-section-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 20px;
    margin-bottom: 28px;
}

.home-section-heading h2 {
    margin: 8px 0 0;
    font-size: 28px;
}

.home-section-heading > a {
    color: var(--accent);
    font-size: 13px;
    text-decoration: none;
    white-space: nowrap;
}

.home-section-heading > a:hover {
    text-decoration: underline;
}

.home-card-type {
    margin: 0 !important;
}

@media (max-width: 600px) {
    .home-section-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .home-projects {
        margin-top: 35px;
        margin-bottom: 55px;
    }
}


/* Project Technology Tags */

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
    margin-bottom: 18px;
}

.project-tag {
    display: inline-flex;
    align-items: center;
    padding: 5px 11px;
    border: 1px solid #35465b;
    border-radius: 6px;
    background: #202e3d;
    color: #a8d2ff;
    font-size: 11px;
    font-weight: 500;
    line-height: 1.4;
}


/* Development Log Card Metadata */

.log-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.log-type {
    display: inline-block;
    padding: 4px 8px;
    border: 1px solid #465044;
    border-radius: 5px;
    background: #283126;
    color: #b6d8a5;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    line-height: 1.4;
}

.log-meta time {
    color: var(--muted);
    font-size: 12px;
}


/* Project Detail Cover */

.project-detail-cover {
    width: 100%;
    margin: 32px 0 40px;
    overflow: hidden;
    border-radius: 12px;
    background: #151a22;
}

.project-detail-cover img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 560px;
    object-fit: contain;
}

@media (max-width: 768px) {
    .project-detail-cover {
        margin: 24px 0 32px;
        border-radius: 8px;
    }
}


/* ========================================
   Image Lightbox
======================================== */

.post-content img {
    cursor: zoom-in;
}

.image-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 32px;
    background: rgba(0, 0, 0, 0.92);

    opacity: 0;
    visibility: hidden;
    pointer-events: none;

    transition: opacity 0.2s ease, visibility 0.2s ease;
    cursor: zoom-out;
}

.image-lightbox.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.image-lightbox img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;

    object-fit: contain;
    cursor: default;
}

@media (max-width: 768px) {
    .image-lightbox {
        padding: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .image-lightbox {
        transition: none;
    }
}