/* ===== Reset & Base ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #0a0a0b;
    --bg-card: #141416;
    --bg-hover: #1a1a1f;
    --text: #e4e4e7;
    --text-muted: #a1a1aa;
    --accent: #3b82f6;
    --accent-hover: #2563eb;
    --border: #27272a;
    --radius: 8px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3 { line-height: 1.2; }
h2 {
    font-size: 2rem;
    margin-bottom: 48px;
    text-align: center;
}

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

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: var(--radius);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
}
.btn-primary:hover { background: var(--accent-hover); }

.btn-secondary {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border);
}
.btn-secondary:hover { border-color: var(--text-muted); }

.btn-nav {
    padding: 8px 20px;
    background: var(--accent);
    color: #fff;
    border-radius: var(--radius);
}
.btn-nav:hover { background: var(--accent-hover); }

/* ===== Nav ===== */
.nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 100;
    background: rgba(10, 10, 11, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.nav-logo {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 32px;
    align-items: center;
}

.nav-links a {
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
}
.nav-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text);
    transition: 0.2s;
}

/* ===== Hero ===== */
.hero {
    padding: 160px 0 100px;
    text-align: center;
}

.hero-tag {
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 16px;
}

.hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    font-weight: 700;
    margin-bottom: 20px;
}

.hero-sub {
    color: var(--text-muted);
    font-size: 1.15rem;
    max-width: 560px;
    margin: 0 auto 36px;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ===== Services ===== */
.services {
    padding: 100px 0;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.service-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 36px 28px;
    transition: border-color 0.2s;
}
.service-card:hover { border-color: var(--accent); }

.service-icon {
    font-size: 2rem;
    margin-bottom: 16px;
}

.service-card h3 {
    margin-bottom: 12px;
    font-size: 1.15rem;
}

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

/* ===== Projects ===== */
.projects {
    padding: 100px 0;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.project-card {
    display: block;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: border-color 0.2s, transform 0.2s;
    color: var(--text);
    text-decoration: none;
}
.project-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.project-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
}

.project-info {
    padding: 24px;
}

.project-info h3 {
    margin-bottom: 8px;
    font-size: 1.1rem;
}

.project-info p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 16px;
}

.project-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.project-tags span {
    background: var(--bg);
    color: var(--text-muted);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    border: 1px solid var(--border);
}

/* ===== About ===== */
.about {
    padding: 100px 0;
}

.about-text p {
    color: var(--text-muted);
    font-size: 1.05rem;
    margin-bottom: 16px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.tech-stack {
    margin-top: 36px;
    text-align: center;
}

.tech-stack h3 {
    margin-bottom: 16px;
    font-size: 1.1rem;
}

.tech-tags {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.tech-tags span {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 8px 16px;
    border-radius: var(--radius);
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ===== Contact ===== */
.contact {
    padding: 100px 0;
}

.contact-sub {
    color: var(--text-muted);
    text-align: center;
    margin-top: -32px;
    margin-bottom: 48px;
}

.contact-form {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-row {
    display: flex;
    gap: 16px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text);
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.2s;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.contact-form .btn {
    align-self: flex-start;
}

/* ===== Footer ===== */
.footer {
    border-top: 1px solid var(--border);
    padding: 32px 0;
}

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

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

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 0.85rem;
}
.footer-links a:hover { color: var(--text); }

/* ===== Mobile ===== */
@media (max-width: 768px) {
    .nav-links { display: none; }
    .nav-links.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        padding: 24px;
        gap: 20px;
    }
    .nav-toggle { display: flex; }

    .hero { padding: 120px 0 80px; }
    .hero h1 { font-size: 2rem; }

    .form-row { flex-direction: column; }

    .footer-content {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

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