:root {
    --primary: #1e293b; /* Slate-800 */
    --primary-deep: #0f172a; /* Slate-900 */
    --accent: #f43f5e; /* Rose-500 */
    --accent-light: #fff1f2; /* Rose-50 */
    --accent-glow: rgba(244, 63, 94, 0.15);
    --surface: #ffffff;
    --surface-dark: #f8fafc; /* Slate-50 */
    --surface-darker: #f1f5f9; /* Slate-100 */
    --text: #334155; /* Slate-700 */
    --text-muted: #94a3b8; /* Slate-400 */
    --text-light: #cbd5e1; /* Slate-300 */
    --border: #e2e8f0; /* Slate-200 */
    --radius: 14px;
    --heading-font: 'DM Serif Display', serif;
    --body-font: 'DM Sans', sans-serif;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.06);
    --shadow-lg: 0 12px 32px rgba(0,0,0,0.08);
}

html { scroll-behavior: smooth; }

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

body {
    background-color: var(--surface);
    color: var(--text);
    font-family: var(--body-font);
    line-height: 1.7;
    padding-top: 72px;
    font-size: 16px;
}

h1, h2, h3, h4 {
    font-family: var(--heading-font);
    font-weight: 400;
    line-height: 1.25;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: all 0.3s ease;
}

.container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===================== NAVIGATION ===================== */
.navbar {
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    background: rgba(255,255,255,0.96);
    backdrop-filter: blur(16px);
    z-index: 1000;
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-family: var(--heading-font);
    font-size: 1.3rem;
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    background: var(--primary);
    color: white;
    border-radius: 10px;
    font-family: var(--heading-font);
    font-size: 0.95rem;
    letter-spacing: 1px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 6px;
}

.nav-link {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.25s ease;
}

.nav-link:hover {
    color: var(--primary);
    background: var(--surface-darker);
}

.hamburger {
    display: none;
    cursor: pointer;
    background: none;
    border: none;
    padding: 4px;
}

.bar {
    display: block;
    width: 22px;
    height: 2px;
    margin: 5px auto;
    background: var(--primary);
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* ===================== HERO ===================== */
.hero {
    position: relative;
    padding: 100px 0 120px;
    background: var(--primary-deep);
    color: white;
    overflow: hidden;
}

.hero-bg-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 48px 48px;
    z-index: 0;
}

.hero-inner {
    position: relative;
    z-index: 1;
    max-width: 680px;
}

.hero-badge {
    display: inline-block;
    padding: 6px 18px;
    background: var(--accent-glow);
    color: var(--accent);
    border: 1px solid rgba(244, 63, 94, 0.25);
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 28px;
}

.hero h1 {
    font-size: 4.5rem;
    line-height: 1.05;
    margin-bottom: 28px;
    color: white;
}

.hero-bio {
    font-size: 1.1rem;
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 36px;
    max-width: 560px;
}

.hero-cta {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 48px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.92rem;
    font-family: var(--body-font);
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.btn-accent {
    background: var(--accent);
    color: white;
    box-shadow: 0 4px 16px rgba(244, 63, 94, 0.3);
}

.btn-accent:hover {
    background: #e11d48;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 63, 94, 0.35);
}

.btn-ghost {
    background: transparent;
    color: white;
    border: 1.5px solid rgba(255,255,255,0.25);
}

.btn-ghost:hover {
    border-color: white;
    background: rgba(255,255,255,0.08);
    color: white;
}

.social-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    background: rgba(255,255,255,0.07);
    color: var(--text-light);
    text-decoration: none;
    font-size: 1rem;
    border: 1px solid rgba(255,255,255,0.1);
    transition: all 0.3s ease;
}

.social-icon:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    transform: translateY(-3px);
}

/* ===================== SECTIONS ===================== */
.section {
    padding: 100px 0;
}

.section-dark {
    background: var(--surface-dark);
}

.section-header {
    margin-bottom: 50px;
}

.section-number {
    display: block;
    font-family: var(--heading-font);
    font-size: 0.95rem;
    color: var(--accent);
    margin-bottom: 8px;
    letter-spacing: 2px;
}

.section-header h2 {
    font-size: 2.4rem;
    color: var(--primary);
    position: relative;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 48px;
    height: 3px;
    background: var(--accent);
    border-radius: 2px;
}

/* ===================== ABOUT / SPLIT LAYOUT ===================== */
.split-layout {
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 48px;
    align-items: start;
}

.split-left .lead-text {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--primary);
    margin-bottom: 20px;
    line-height: 1.75;
}

.split-left p {
    margin-bottom: 18px;
    color: var(--text);
    line-height: 1.8;
}

.info-card {
    background: var(--surface-dark);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    overflow: hidden;
}

.info-row {
    display: flex;
    flex-direction: column;
    padding: 20px 28px;
    border-bottom: 1px solid var(--border);
}

.info-row:last-child {
    border-bottom: none;
}

.info-key {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.info-val {
    font-weight: 500;
    color: var(--primary);
}

/* ===================== TIMELINE MODERN ===================== */
.timeline-modern {
    position: relative;
    padding-left: 40px;
    max-width: 720px;
}

.timeline-modern::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.tm-item {
    position: relative;
    margin-bottom: 48px;
}

.tm-item:last-child { margin-bottom: 0; }

.tm-dot {
    position: absolute;
    left: -40px;
    top: 6px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--surface);
    border: 3px solid var(--accent);
    z-index: 1;
}

.tm-date {
    display: inline-block;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.tm-content h3 {
    font-size: 1.35rem;
    color: var(--primary);
    margin-bottom: 6px;
}

.tm-company {
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.tm-content > p:last-child {
    color: var(--text);
    line-height: 1.75;
}

/* ===================== EDUCATION ===================== */
.edu-highlight {
    display: flex;
    gap: 36px;
    align-items: flex-start;
    background: var(--surface-dark);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 44px;
    max-width: 720px;
    transition: transform 0.3s ease;
}

.edu-highlight:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.edu-icon-wrap {
    flex-shrink: 0;
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: white;
}

.edu-body h3 {
    font-size: 1.3rem;
    color: var(--primary);
    margin-bottom: 8px;
}

.edu-institution {
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 4px;
}

.edu-period {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 14px;
}

.edu-desc {
    color: var(--text);
    line-height: 1.75;
}

/* ===================== COMPETENCE GRID ===================== */
.competence-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.comp-item {
    background: var(--surface);
    padding: 32px 24px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    text-align: center;
    transition: all 0.3s ease;
}

.comp-item:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent);
}

.comp-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: var(--accent-light);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
    font-size: 1.3rem;
    color: var(--accent);
    transition: all 0.3s ease;
}

.comp-item:hover .comp-icon {
    background: var(--accent);
    color: white;
}

.comp-item h3 {
    font-size: 0.95rem;
    font-family: var(--body-font);
    font-weight: 600;
    color: var(--primary);
    line-height: 1.4;
}

/* ===================== PROJECT SHOWCASE ===================== */
.project-showcase {
    background: linear-gradient(135deg, var(--primary-deep), var(--primary));
    border-radius: var(--radius);
    padding: 56px;
    color: white;
    position: relative;
    overflow: hidden;
    max-width: 720px;
}

.project-showcase::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 300px;
    height: 300px;
    background: var(--accent);
    border-radius: 50%;
    opacity: 0.08;
}

.project-label {
    display: inline-block;
    padding: 4px 14px;
    background: rgba(244, 63, 94, 0.2);
    color: var(--accent);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 18px;
}

.project-info h3 {
    font-size: 2rem;
    color: white;
    margin-bottom: 16px;
}

.project-info p {
    color: var(--text-light);
    line-height: 1.8;
    margin-bottom: 28px;
    max-width: 520px;
}

.project-info .btn-accent {
    position: relative;
    z-index: 1;
}

/* ===================== CONTACT ===================== */
.contact-box {
    text-align: center;
    max-width: 520px;
    margin: 0 auto;
    background: var(--surface);
    padding: 52px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md);
}

.contact-box p {
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 28px;
    line-height: 1.75;
}

/* ===================== FOOTER ===================== */
footer {
    text-align: center;
    padding: 40px 0;
    background: var(--primary-deep);
    color: var(--text-muted);
    font-size: 0.88rem;
}

/* ===================== SCROLL TO TOP ===================== */
#scrollTopBtn {
    display: none;
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 99;
    border: none;
    outline: none;
    background: var(--primary);
    color: white;
    cursor: pointer;
    width: 46px;
    height: 46px;
    border-radius: 12px;
    font-size: 16px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
    align-items: center;
    justify-content: center;
}

#scrollTopBtn[style*="display: flex"],
#scrollTopBtn[style*="display: block"] {
    display: flex !important;
}

#scrollTopBtn:hover {
    background: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(244, 63, 94, 0.3);
}

/* ===================== ANIMATIONS ===================== */
.fade-up {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 1024px) {
    .competence-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .hamburger { display: block; }

    .hamburger.active .bar:nth-child(2) { opacity: 0; }
    .hamburger.active .bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .hamburger.active .bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 64px;
        flex-direction: column;
        background: rgba(255,255,255,0.99);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 30px rgba(0,0,0,0.06);
        padding: 20px 0;
        gap: 4px;
    }

    .nav-menu.active { left: 0; }

    .hero h1 { font-size: 3rem; }

    .split-layout {
        grid-template-columns: 1fr;
        gap: 32px;
    }

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

    .edu-highlight {
        flex-direction: column;
        padding: 32px;
    }

    .project-showcase {
        padding: 36px;
    }

    .section { padding: 70px 0; }

    .contact-box { padding: 36px; }
}

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

    .hero-cta {
        flex-direction: column;
    }

    .btn {
        text-align: center;
        justify-content: center;
    }

    .competence-grid {
        grid-template-columns: 1fr;
    }
}
