/* Import Inter font */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&display=swap');

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

/* Smooth Scroll */
html {
    scroll-behavior: smooth;
}

/* Variables */
:root {
    --bg: #ffffff;
    --text: #111111;
    --text-dim: #666666;
    --accent: #ff4d4d;
    --spacing: clamp(1.5rem, 8vw, 4rem);
    --border: 1px solid #e5e5e5;
    --radius: 0px;
}

/* Base Styles */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    font-size: 16px;
    letter-spacing: -0.01em;
    overflow-x: hidden;
}

/* Typography */
h1 {
    font-size: clamp(3.5rem, 10vw, 7rem);
    font-weight: 500;
    line-height: 0.9;
    letter-spacing: -0.03em;
    margin: calc(var(--spacing) * 2) 0;
}

h2 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 500;
    letter-spacing: -0.02em;
    margin-bottom: var(--spacing);
}

p {
    color: var(--text-dim);
    font-size: clamp(1.125rem, 2vw, 1.25rem);
    max-width: 65ch;
    font-weight: 400;
}

/* Navigation */
nav {
    display: flex;
    justify-content: space-between;
    padding: 2rem var(--spacing);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    z-index: 100;
    border-bottom: var(--border);
}

.nav-links {
    display: flex;
    gap: 2rem;
}

/* Mobile Menu Button */
.mobile-menu-button {
    width: 30px;
    height: 30px;
    position: relative;
    cursor: pointer;
    z-index: 50;
}

.menu-line {
    width: 100%;
    height: 2px;
    background-color: var(--text);
    position: absolute;
    transition: all 0.3s ease;
}

.menu-line:first-child {
    top: 35%;
}

.menu-line:last-child {
    bottom: 35%;
}

/* Mobile Menu */
.mobile-menu {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
    display: block;
}

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

a:hover {
    color: var(--accent);
}

/* Sections */
section {
    min-height: 100vh;
    padding: calc(var(--spacing) * 2) var(--spacing);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Hero Section */
.hero {
    padding-top: calc(var(--spacing) * 6);
    min-height: 100vh;
}

.hero p:first-child {
    color: var(--accent);
    font-weight: 500;
    font-size: 1.25rem;
}

/* Clients Section */
.client-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing);
    margin-top: var(--spacing);
}

.client {
    padding: var(--spacing);
    border: var(--border);
    border-radius: var(--radius);
    transition: all 0.3s ease;
}

.client:hover {
    background: var(--text);
    color: var(--bg);
    transform: translateY(-4px);
}

.client:hover * {
    color: var(--bg);
}

.client-year {
    font-size: 1rem;
    margin-bottom: 1rem;
    display: block;
    font-weight: 500;
    color: var(--text-dim);
}

.client h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 500;
    letter-spacing: -0.02em;
}

/* Experience Section */
.timeline {
    display: grid;
    gap: var(--spacing);
    margin-top: var(--spacing);
}

.timeline-item {
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: var(--spacing);
    padding: var(--spacing);
    border: var(--border);
    border-radius: var(--radius);
    transition: all 0.3s ease;
}

.timeline-item:hover {
    background: var(--text);
    color: var(--bg);
    transform: translateY(-4px);
}

.timeline-item:hover * {
    color: var(--bg);
}

.timeline-date {
    color: var(--text-dim);
    font-weight: 500;
}

.timeline-content h3 {
    font-size: clamp(1.25rem, 2.5vw, 1.75rem);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.timeline-content .company {
    color: var(--text-dim);
    font-size: 1rem;
    margin-bottom: 1rem;
    font-weight: 500;
}

/* Project Grid */
.project-grid {
    display: grid;
    gap: calc(var(--spacing) * 2);
    margin-top: calc(var(--spacing) * 2);
}

.project-card {
    display: grid;
    grid-template-columns: 1fr;
    padding: calc(var(--spacing) * 2);
    border: var(--border);
    border-radius: var(--radius);
    transition: all 0.3s ease;
    position: relative;
}

.project-card::before {
    content: attr(data-number);
    position: absolute;
    top: 2rem;
    right: 2rem;
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 500;
    color: var(--text-dim);
    opacity: 0.5;
    letter-spacing: -0.03em;
}

.project-card:hover {
    background: var(--text);
    color: var(--bg);
    transform: translateY(-4px);
}

.project-card:hover * {
    color: var(--bg);
}

.project-card:hover::before {
    color: var(--bg);
    opacity: 0.2;
}

.project-year {
    color: var(--text-dim);
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 1rem;
}

.project-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1.5rem;
    font-weight: 500;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

/* Social Links */
.social-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing);
    margin-top: var(--spacing);
}

.social-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: var(--spacing);
    border: var(--border);
    border-radius: var(--radius);
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--text);
    color: var(--bg);
    transform: translateY(-4px);
}

.social-link:hover svg {
    color: var(--bg);
}

.social-link svg {
    width: 1.5rem;
    height: 1.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    .project-card {
        padding: var(--spacing);
    }

    .project-card::before {
        top: 1rem;
        right: 1rem;
        font-size: 1.5rem;
    }

    .timeline-item {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .nav-links {
        display: none;
    }

    section {
        padding: var(--spacing) calc(var(--spacing) / 2);
    }

    .hero {
        padding-top: calc(var(--spacing) * 4);
    }
}

/* Selection */
::selection {
    background: var(--accent);
    color: var(--bg);
}

/* Ensure the text is aligned and styled correctly */
#work .flex {
  align-items: center;
  justify-content: space-between;
}

#work h3 {
  text-align: right;
  color: black;
}

#work .text-gray-500 {
  color: #4a4a4a;
}
