@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,300&family=DM+Serif+Display:ital@0;1&display=swap');

:root {
    --white: #ffffff;
    --off-white: #f8f9fb;
    --black: #0a0a0a;
    --navy: #111827;
    --blue-primary: #2563eb;
    --blue-light: #3b82f6;
    --blue-faint: #eff6ff;
    --blue-mid: #dbeafe;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --border: #e2e8f0;
    --border-strong: #cbd5e1;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.04);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.1), 0 4px 12px rgba(0,0,0,0.06);
    --transition-speed: 0.3s;
    --container-width: 1200px;
    --card-gray: #f8f9fb;
    --border-light: #e2e8f0;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'DM Sans', system-ui, sans-serif;
    background-color: var(--white);
    color: var(--text-primary);
    line-height: 1.65;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
    opacity: 0;
    animation: pageReveal 0.5s ease 0.05s forwards;
}

@keyframes pageReveal {
    to { opacity: 1; }
}

a {
    color: inherit;
    text-decoration: none;
}

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(10, 10, 10, 0.97);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    padding: 0;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    box-shadow: 0 2px 20px rgba(0,0,0,0.2);
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 28px;
    height: 66px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-family: 'DM Serif Display', Georgia, serif;
    font-size: 1.1rem;
    font-weight: 400;
    letter-spacing: 0.08em;
    color: #ffffff;
    text-decoration: none;
    transition: opacity var(--transition-speed) ease;
}

.nav-logo:hover {
    opacity: 0.8;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 0.25rem;
    align-items: center;
}

.nav-link {
    color: #9ca3af;
    text-decoration: none;
    font-weight: 400;
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    padding: 6px 14px;
    border-radius: 6px;
    transition: color var(--transition-speed) ease,
                background var(--transition-speed) ease;
}

.nav-link:hover {
    color: #ffffff;
    background: rgba(255,255,255,0.07);
}

.nav-link.active {
    color: #ffffff;
    background: rgba(37, 99, 235, 0.25);
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 6px;
}

.mobile-menu-btn span {
    width: 22px;
    height: 2px;
    background: #ffffff;
    border-radius: 2px;
    transition: transform var(--transition-speed) ease,
                opacity var(--transition-speed) ease;
    transform-origin: center;
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.main-content {
    flex: 1;
    max-width: var(--container-width);
    margin: 66px auto 0;
    padding: 52px 28px 80px;
    width: 100%;
}

.footer {
    background: var(--navy);
    padding: 36px 0;
    width: 100%;
    border-top: 3px solid var(--blue-primary);
}

.footer-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 28px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
    color: #ffffff;
    font-size: 0.875rem;
}

.footer-container a {
    color: #93c5fd;
    text-decoration: none;
    transition: color var(--transition-speed) ease;
    font-weight: 400;
}

.footer-container a:hover {
    color: #ffffff;
}

.footer-separator {
    color: #374151;
    font-weight: 300;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(22px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.main-content > *:nth-child(1) { animation: fadeIn 0.5s cubic-bezier(0.22,1,0.36,1) 0.1s both; }
.main-content > *:nth-child(2) { animation: fadeIn 0.5s cubic-bezier(0.22,1,0.36,1) 0.18s both; }
.main-content > *:nth-child(3) { animation: fadeIn 0.5s cubic-bezier(0.22,1,0.36,1) 0.26s both; }
.main-content > *:nth-child(4) { animation: fadeIn 0.5s cubic-bezier(0.22,1,0.36,1) 0.34s both; }
.main-content > *:nth-child(5) { animation: fadeIn 0.5s cubic-bezier(0.22,1,0.36,1) 0.42s both; }
.main-content > *:nth-child(n+6) { animation: fadeIn 0.5s cubic-bezier(0.22,1,0.36,1) 0.5s both; }

.main-content h1,
.main-content h2,
.main-content h3 {
    font-family: 'DM Serif Display', Georgia, serif;
    font-weight: 400;
    color: var(--text-primary);
    line-height: 1.2;
    letter-spacing: -0.01em;
}

.main-content h1 { font-size: clamp(2rem, 4vw, 3rem); }
.main-content h2 { font-size: clamp(1.4rem, 2.5vw, 2rem); }
.main-content h3 { font-size: 1.15rem; }

.main-content p {
    color: var(--text-secondary);
    font-size: 0.975rem;
    line-height: 1.8;
}

.main-content a:not(.btn):not(.nav-link):not(.contact-link) {
    color: var(--blue-primary);
    transition: color var(--transition-speed) ease;
}

.main-content a:not(.btn):not(.nav-link):not(.contact-link):hover {
    color: var(--blue-light);
}

.card,
[class*="-card"] {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: box-shadow var(--transition-speed) ease,
                transform var(--transition-speed) ease;
}

.card:hover,
[class*="-card"]:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.btn,
button:not(.mobile-menu-btn) {
    font-family: 'DM Sans', system-ui, sans-serif;
    font-size: 0.85rem;
    font-weight: 500;
    padding: 10px 22px;
    border: 1.5px solid var(--border-strong);
    background: transparent;
    color: var(--text-primary);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color var(--transition-speed) ease,
                color var(--transition-speed) ease,
                background var(--transition-speed) ease;
}

.btn:hover,
button:not(.mobile-menu-btn):hover {
    border-color: var(--blue-primary);
    color: var(--blue-primary);
    background: var(--blue-faint);
}

hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 2.5rem 0;
}

.project-status {
    margin: 0.5rem 0 1rem;
}

.status-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.status-ongoing {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fcd34d;
}

.status-completed {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--off-white); }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

::selection {
    background: var(--blue-mid);
    color: var(--blue-primary);
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: flex;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        flex-direction: column;
        align-items: center;
        padding: 1.5rem;
        gap: 0.25rem;
        border-bottom: 1px solid rgba(255,255,255,0.06);
    }

    .nav-menu.active {
        display: flex;
        animation: fadeIn 0.2s ease both;
    }

    .nav-link {
        width: 100%;
        text-align: center;
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    .main-content {
        padding: 40px 20px 60px;
    }

    .footer-container {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    .footer-separator {
        display: none;
    }
}