/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&family=Noto+Sans+KR:wght@400;500;700&display=swap');

:root {
    --bg-color: #0f1117;
    --second-bg-color: #181b23;
    --card-bg: #1e2230;
    --text-color: #e4e4e7;
    --text-muted: #9ca3af;
    --main-color: #60a5fa;
    --main-color-dim: rgba(96, 165, 250, 0.12);
    --accent-gradient: linear-gradient(135deg, #60a5fa, #a78bfa);
    --accent-glow: rgba(96, 165, 250, 0.25);

    --font-primary: 'Noto Sans KR', sans-serif;
    --font-secondary: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
    border: none;
    outline: none;
    font-family: var(--font-primary);
}

html {
    font-size: 62.5%;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

body {
    background: var(--bg-color);
    color: var(--text-color);
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-color);
}

::-webkit-scrollbar-thumb {
    background: var(--main-color-dim);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--main-color);
}

/* ===== Header ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.8rem 9%;
    background: rgba(15, 17, 23, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    transition: all 0.3s ease;
    border-bottom: 1px solid transparent;
}

.header.sticky {
    border-bottom: 1px solid rgba(96, 165, 250, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.logo {
    font-size: 2.4rem;
    color: var(--text-color);
    font-weight: 700;
    cursor: default;
    font-family: var(--font-secondary);
    letter-spacing: -0.02em;
}

.logo .dot {
    color: var(--main-color);
}

.navbar a {
    font-size: 1.5rem;
    color: var(--text-muted);
    margin-left: 3.5rem;
    transition: color 0.3s ease;
    font-weight: 500;
    position: relative;
    letter-spacing: 0.02em;
}

.navbar a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    border-radius: 1px;
    transition: width 0.3s ease;
}

.navbar a:hover,
.navbar a.active {
    color: var(--text-color);
}

.navbar a:hover::after,
.navbar a.active::after {
    width: 100%;
}

#menu-icon {
    font-size: 3.2rem;
    color: var(--text-color);
    display: none;
    cursor: pointer;
}

/* ===== Sections Base ===== */
section {
    min-height: 100vh;
    padding: 10rem 9% 6rem;
}

.heading {
    text-align: center;
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.heading span {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    font-size: 1.5rem;
    color: var(--text-muted);
    margin-bottom: 5rem;
}

/* ===== Home ===== */
.home {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.home::before {
    content: '';
    position: absolute;
    top: 20%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.home-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.home-content .greeting {
    display: inline-block;
    font-size: 1.5rem;
    color: var(--main-color);
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 2rem;
    padding: 0.6rem 2rem;
    background: var(--main-color-dim);
    border-radius: 3rem;
    border: 1px solid rgba(96, 165, 250, 0.2);
}

.home-content h1 {
    font-size: 5.6rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.home-content .typed-wrap {
    font-size: 2.8rem;
    font-weight: 600;
    margin-bottom: 2.5rem;
    min-height: 4rem;
}

.home-content .typed-wrap .multiple-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.home-content .typed-wrap .typed-cursor {
    color: var(--main-color);
}

.home-content p {
    font-size: 1.7rem;
    color: var(--text-muted);
    line-height: 1.8;
    max-width: 600px;
    margin: 0 auto 3rem;
}

.social-media a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4.5rem;
    height: 4.5rem;
    background: var(--card-bg);
    border: 1px solid rgba(96, 165, 250, 0.2);
    border-radius: 50%;
    font-size: 2rem;
    color: var(--main-color);
    margin: 0 0.8rem;
    transition: all 0.3s ease;
}

.social-media a:hover {
    background: var(--main-color);
    color: var(--bg-color);
    border-color: var(--main-color);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px var(--accent-glow);
}

/* ===== About ===== */
.about {
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--second-bg-color);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-content h2 {
    text-align: center;
    line-height: 1.2;
}

.about-content h3 {
    font-size: 2.2rem;
    text-align: center;
    color: var(--main-color);
    margin-bottom: 2.5rem;
    font-weight: 600;
}

.about-content > p {
    font-size: 1.6rem;
    line-height: 1.9;
    color: var(--text-muted);
    margin-bottom: 3rem;
}

.about-content > p strong {
    color: var(--text-color);
    font-weight: 600;
}

.personal-info {
    display: flex;
    justify-content: center;
    gap: 3rem;
    flex-wrap: wrap;
    margin-top: 3rem;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 2rem;
    background: var(--card-bg);
    border-radius: 1rem;
    border: 1px solid rgba(96, 165, 250, 0.1);
    font-size: 1.5rem;
    color: var(--text-muted);
    transition: all 0.3s ease;
}

.info-item:hover {
    border-color: rgba(96, 165, 250, 0.3);
    transform: translateY(-2px);
}

.info-item i {
    font-size: 2rem;
    color: var(--main-color);
}

/* ===== Resume ===== */
.resume {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    min-height: auto;
    padding-bottom: 6rem;
}

.resume .heading {
    margin-bottom: 1rem;
}

.resume-row {
    display: flex;
    flex-wrap: wrap;
    gap: 5rem;
    max-width: 1200px;
    width: 100%;
}

.resume-column {
    flex: 1 1 40rem;
}

.resume-column .title {
    font-size: 2.2rem;
    margin: 0 0 2rem 2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.resume-column .title i {
    color: var(--main-color);
    font-size: 2.4rem;
}

.resume-box {
    border-left: 2px solid rgba(96, 165, 250, 0.25);
    position: relative;
}

.resume-content {
    position: relative;
    padding-left: 2.5rem;
}

.resume-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: -7px;
    width: 12px;
    height: 12px;
    background: var(--main-color);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-glow);
}

.resume-content .content {
    padding: 2rem;
    background: var(--card-bg);
    border: 1px solid rgba(96, 165, 250, 0.08);
    border-radius: 1.2rem;
    margin-bottom: 2rem;
    transition: all 0.3s ease;
}

.resume-content .content:hover {
    border-color: rgba(96, 165, 250, 0.25);
    transform: translateX(5px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.resume-content .content .year {
    font-size: 1.3rem;
    color: var(--main-color);
    padding-bottom: 0.8rem;
    font-weight: 600;
    font-family: var(--font-secondary);
    letter-spacing: 0.02em;
}

.resume-content .content h3 {
    font-size: 1.9rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.resume-content .content p {
    font-size: 1.5rem;
    color: var(--text-muted);
    line-height: 1.8;
}

.resume-content .content p strong {
    color: var(--text-color);
    font-weight: 600;
}

.job-rank {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--bg-color);
    background: var(--accent-gradient);
    padding: 0.2rem 0.8rem;
    border-radius: 0.4rem;
    margin-left: 0.5rem;
    vertical-align: middle;
    display: inline-block;
}

/* ===== Portfolio ===== */
.portfolio {
    background: var(--second-bg-color);
}

.portfolio .heading {
    margin-bottom: 1rem;
}

.portfolio-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.portfolio-card {
    background: var(--card-bg);
    padding: 3rem 2rem;
    border-radius: 1.6rem;
    text-align: center;
    border: 1px solid rgba(96, 165, 250, 0.08);
    transition: all 0.35s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.2rem;
    position: relative;
    overflow: hidden;
}

.portfolio-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--accent-gradient);
    opacity: 0;
    transition: opacity 0.35s ease;
}

.portfolio-card:hover {
    border-color: rgba(96, 165, 250, 0.3);
    transform: translateY(-5px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

.portfolio-card:hover::before {
    opacity: 1;
}

.portfolio-card i {
    font-size: 4rem;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: all 0.3s ease;
}

.portfolio-card h3 {
    font-size: 1.8rem;
    color: var(--text-color);
    font-weight: 600;
}

.portfolio-card p {
    font-size: 1.35rem;
    color: var(--text-muted);
}

.portfolio-separator {
    grid-column: 1 / -1;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--main-color), transparent);
    margin: 1rem 0;
    opacity: 0.3;
}

/* ===== Contact (email only) ===== */
.contact {
    min-height: auto;
    padding: 8rem 9% 6rem;
    text-align: center;
}

.contact .heading {
    margin-bottom: 1rem;
}

.contact-content {
    max-width: 600px;
    margin: 0 auto;
}

.contact-card {
    display: inline-flex;
    align-items: center;
    gap: 1.5rem;
    padding: 2rem 4rem;
    background: var(--card-bg);
    border: 1px solid rgba(96, 165, 250, 0.15);
    border-radius: 1.2rem;
    transition: all 0.3s ease;
    color: var(--text-color);
    font-size: 1.8rem;
    font-weight: 500;
}

.contact-card:hover {
    border-color: var(--main-color);
    transform: translateY(-3px);
    box-shadow: 0 8px 30px var(--accent-glow);
}

.contact-card i {
    font-size: 2.4rem;
    color: var(--main-color);
}

/* ===== Footer ===== */
.footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    padding: 2rem 9%;
    background: var(--second-bg-color);
    border-top: 1px solid rgba(96, 165, 250, 0.08);
}

.footer-text p {
    font-size: 1.4rem;
    color: var(--text-muted);
}

.footer-iconTop a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 4rem;
    height: 4rem;
    background: var(--card-bg);
    border: 1px solid rgba(96, 165, 250, 0.2);
    border-radius: 0.8rem;
    transition: all 0.3s ease;
}

.footer-iconTop a:hover {
    background: var(--main-color);
    border-color: var(--main-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px var(--accent-glow);
}

.footer-iconTop a i {
    font-size: 2.2rem;
    color: var(--main-color);
    transition: color 0.3s ease;
}

.footer-iconTop a:hover i {
    color: var(--bg-color);
}

/* ===== Responsive ===== */
@media (max-width: 991px) {
    .header {
        padding: 1.8rem 3%;
    }

    section {
        padding: 10rem 3% 4rem;
    }

    .footer {
        padding: 2rem 3%;
    }
}

@media (max-width: 768px) {
    #menu-icon {
        display: block;
    }

    .navbar {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        padding: 1.5rem 3%;
        background: rgba(15, 17, 23, 0.95);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        border-top: 1px solid rgba(96, 165, 250, 0.1);
        display: none;
    }

    .navbar.active {
        display: block;
    }

    .navbar a {
        display: block;
        font-size: 1.8rem;
        margin: 2.5rem 0;
    }

    .navbar a::after {
        display: none;
    }

    .home {
        flex-direction: column;
    }

    .home-content h1 {
        font-size: 4rem;
    }

    .home-content .typed-wrap {
        font-size: 2.2rem;
    }

    .about {
        flex-direction: column-reverse;
    }

    .portfolio-container {
        grid-template-columns: repeat(2, 1fr);
    }

    .personal-info {
        flex-direction: column;
        align-items: center;
    }

    .contact-card {
        padding: 1.5rem 2.5rem;
        font-size: 1.5rem;
    }
}

@media (max-width: 500px) {
    .portfolio-container {
        grid-template-columns: 1fr;
    }

    .home-content h1 {
        font-size: 3.2rem;
    }

    .heading {
        font-size: 3.2rem;
    }
}
