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

html {
    scroll-behavior: smooth;
    overflow-y: scroll;
}

:root {
    --bg-color: #ffffff;
    --text-color: #111111;
    --text-secondary: #555555;
    --text-tertiary: #666666;
    --link-color: #0a66c2;
    --link-hover: #004182;
    --tab-active: #0a66c2;
    --border-color: #dddddd;
    --tag-bg: #e8f4f8;
    --tag-text: #0a66c2;
}

[data-theme="dark"] {
    --bg-color: #121212;
    --text-color: #e0e0e0;
    --text-secondary: #b0b0b0;
    --text-tertiary: #999999;
    --link-color: #58a6ff;
    --link-hover: #79b8ff;
    --tab-active: #58a6ff;
    --border-color: #333333;
    --tag-bg: #1a3a52;
    --tag-text: #58a6ff;
}

body {
    background: var(--bg-color);
    color: var(--text-color);
    font-family: "Inter", sans-serif;
    font-size: 16px;
    line-height: 1.7;
    transition: background-color 0.3s ease, color 0.3s ease;
    min-height: 100vh;
}

.container {
    max-width: 750px;
    margin: 0 auto;
    padding: 60px 20px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* HEADER */
.header {
    margin-bottom: 40px;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.header h1 {
    font-family: "Libre Baskerville", serif;
    font-size: 2rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.2;
}

#theme-toggle {
    background: transparent;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 4px 8px;
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

#theme-toggle:hover {
    transform: scale(1.1);
}

.toggle-light {
    color: #ffffff;
}

.toggle-dark {
    color: #000000;
}

.subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 8px 0;
    line-height: 1.5;
}

.contact-links {
    font-size: 0.95rem;
    margin-top: 12px;
    line-height: 1.6;
}

.contact-links a {
    color: var(--link-color);
    text-decoration: none;
}

.contact-links a:hover {
    color: var(--link-hover);
    text-decoration: underline;
}

.divider {
    margin: 0 6px;
    color: var(--text-tertiary);
}

/* TABS */
.tabs {
    display: flex;
    gap: 20px;
    margin: 20px 0;
    border-bottom: 1px solid var(--border-color);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.tab {
    background: none;
    border: none;
    color: var(--text-secondary);
    padding: 10px 0;
    font-size: 1rem;
    font-weight: 400;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.tab:hover {
    color: var(--text-color);
}

.tab.active {
    color: var(--tab-active);
    border-bottom-color: var(--tab-active);
    font-weight: 500;
}

/* TAB CONTENT */
.tab-content {
    display: none;
    padding: 10px 0;
    min-height: 400px;
    width: 100%;
}

.tab-content.active {
    display: block;
}

/* TYPOGRAPHY */
h2 {
    font-family: "Libre Baskerville", serif;
    font-size: 1.4rem;
    font-weight: 700;
    margin: 2em 0 0.5em 0;
    line-height: 1.3;
}

h2:first-child {
    margin-top: 0;
}

h3 {
    font-family: "Libre Baskerville", serif;
    font-size: 1.15rem;
    font-weight: 700;
    margin: 1.8em 0 0.3em 0;
    line-height: 1.3;
}

p {
    margin: 0.8em 0;
    line-height: 1.7;
}

ul {
    margin: 0.8em 0 1.5em 1.5em;
    padding: 0;
    line-height: 1.7;
}

li {
    margin: 0.4em 0;
}

/* META INFO */
.meta-info {
    font-size: 0.95rem;
    color: var(--text-tertiary);
    margin: 0.3em 0 0.8em 0;
}

/* SECTIONS */
.role,
.edu-item,
.project,
.cert-item {
    margin-bottom: 2.5em;
}

.role:last-child,
.edu-item:last-child,
.project:last-child,
.cert-item:last-child {
    margin-bottom: 0;
}

/* SKILLS */
.skill-group {
    margin-bottom: 2em;
}

.skill-group:last-child {
    margin-bottom: 0;
}



.skill-list {
    color: var(--text-secondary);
    line-height: 1.8;
}

/* PROJECT TAGS */
.tech-tags {
    margin-top: 0.8em;
}

.tech-tags span {
    display: inline-block;
    background-color: var(--tag-bg);
    color: var(--tag-text);
    padding: 4px 12px;
    border-radius: 16px;
    margin: 4px 6px 4px 0;
    font-size: 0.85rem;
    font-weight: 500;
}

/* FOOTER */
footer {
    margin-top: auto;
    padding: 40px 0 30px;
    text-align: center;
    color: var(--text-tertiary);
    font-size: 0.9rem;
}

/* PRINT */
@media print {

    .tabs,
    #theme-toggle {
        display: none;
    }

    .tab-content {
        display: block !important;
        min-height: auto;
    }
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .container {
        padding: 40px 20px 20px;
    }

    .header h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.25rem;
    }

    h3 {
        font-size: 1.05rem;
    }

    body {
        font-size: 15px;
    }

    .tabs {
        gap: 16px;
    }

    .tab {
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .header h1 {
        font-size: 1.6rem;
    }

    .tabs {
        gap: 12px;
    }

    .tab {
        font-size: 0.9rem;
        padding: 8px 0;
    }
}