/* Color System */
:root {
    /* Background */
    --bg-start: #1B0F2E;
    --bg-end: #2A1852;

    /* Typography */
    --text-heading: #F2F3F7;
    --text-body: #C9CBD9;
    --text-muted: #9CA0B5;

    /* Accent (purple only) */
    --accent: #8F7CFF;
    --accent-hover: #A99BFF;
    --focus-ring: rgba(143, 124, 255, 0.35);

    /* Card (glass panel) */
    --card-bg: rgba(18, 12, 32, 0.78);
    --card-border: rgba(255, 255, 255, 0.06);
    --card-shadow: 0 20px 60px rgba(0, 0, 0, 0.50);

    /* Layout */
    --width: 69rem;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Quicksand', sans-serif;
    background: linear-gradient(135deg, var(--bg-start) 0%, var(--bg-end) 100%);
    background-attachment: fixed;
    color: var(--text-body);
    line-height: 1.6;
    font-weight: 300;
    font-size: 1rem;
    min-height: 100vh;
}

/* Main Container */
main {
    max-width: var(--width);
    margin: 0 auto;
    padding: 9rem 3rem;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

/* Typography */
h1 {
    font-size: 5.5em;
    font-weight: 400;
    letter-spacing: 0.3rem;
    line-height: 1.1;
    margin-bottom: 0.5rem;
    color: var(--text-heading);
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.35);
}

h2 {
    font-size: 2.5em;
    font-weight: 400;
    letter-spacing: 0.1rem;
    margin-bottom: 1.5rem;
    color: var(--text-heading);
}

h3 {
    font-size: 1.5em;
    font-weight: 400;
    color: var(--text-heading);
    margin-bottom: 0.75rem;
}

p {
    font-size: 1.125em;
    font-weight: 300;
    line-height: 1.6;
    color: var(--text-body);
}

/* Hero Section */
.hero {
    padding: 4rem 0;
}

.tagline {
    font-size: 1.75em;
    color: var(--accent);
    font-weight: 400;
}

/* About Section - Glass Card */
.about {
    padding: 2.5rem;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.about p {
    max-width: 100%;
    margin-bottom: 1.5rem;
    color: var(--text-body);
    line-height: 1.6;
}

.about p:last-of-type {
    margin-bottom: 2rem;
}

/* Button Group */
.button-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Pill Button Style */
.pill-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 0 2rem;
    height: 3.75rem;
    min-width: 13.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 2.5rem;
    background: var(--card-bg);
    color: var(--text-body);
    text-decoration: none;
    font-family: 'Quicksand', sans-serif;
    font-size: 1rem;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.25s ease;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.pill-button:hover {
    transform: scale(1.05);
    color: var(--accent-hover);
    border-color: var(--accent);
    background: rgba(143, 124, 255, 0.1);
}

.pill-button:focus-visible {
    outline: none;
    box-shadow: 0 0 0 4px var(--focus-ring);
}

.pill-button svg {
    transition: transform 0.25s ease;
}

.pill-button:hover svg {
    transform: translateY(3px);
}

/* Primary Button Variant */
.pill-button.primary {
    background: var(--accent);
    color: var(--text-heading);
    border-color: var(--accent);
}

.pill-button.primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: var(--text-heading);
}

/* Divider */
.divider {
    width: 100%;
    height: 1px;
    background-color: var(--card-border);
    margin: 2rem 0;
}

/* Projects Section */
.projects {
    padding: 2rem 0;
}

.project-item {
    padding: 2rem;
    margin-bottom: 1.5rem;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: border-color 0.25s ease, transform 0.25s ease;
}

.project-item:hover {
    border-color: rgba(143, 124, 255, 0.3);
    transform: translateY(-3px);
}

.project-item:last-of-type {
    margin-bottom: 0;
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.project-header h3 {
    margin-bottom: 0;
}

.country-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.25rem 0.75rem;
    background: rgba(143, 124, 255, 0.15);
    border: 1px solid rgba(143, 124, 255, 0.3);
    border-radius: 1rem;
    color: var(--accent);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.05rem;
    flex-shrink: 0;
}

.country-badge .flag {
    font-size: 0.9rem;
    filter: saturate(0.6) brightness(1.1);
    opacity: 0.85;
}

.project-item p {
    font-size: 1.1em;
    margin-bottom: 1rem;
    color: var(--text-body);
}

.project-link {
    color: var(--accent);
    text-decoration: none;
    font-weight: 400;
    font-size: 1rem;
    transition: all 0.25s ease;
}

.project-link:hover {
    color: var(--accent-hover);
    text-decoration: underline;
    text-decoration-color: rgba(143, 124, 255, 0.6);
}

/* Contact Section */
.contact {
    padding: 2rem 0;
}

.contact > p {
    margin-bottom: 2rem;
    color: var(--text-body);
}

/* Contact Form */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    max-width: 25rem;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 1rem 1.5rem;
    height: 3.75rem;
    border: 1px solid var(--card-border);
    border-radius: 2.5rem;
    background: var(--card-bg);
    color: var(--text-heading);
    font-family: 'Quicksand', sans-serif;
    font-size: 1rem;
    font-weight: 300;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.contact-form textarea {
    height: auto;
    min-height: 8rem;
    border-radius: 1.5rem;
    resize: vertical;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--text-muted);
}

.contact-form input:-webkit-autofill,
.contact-form input:-webkit-autofill:hover,
.contact-form input:-webkit-autofill:focus,
.contact-form textarea:-webkit-autofill,
.contact-form textarea:-webkit-autofill:hover,
.contact-form textarea:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px rgba(18, 12, 32, 0.95) inset;
    -webkit-text-fill-color: var(--text-heading);
    border-color: var(--accent);
    caret-color: var(--text-heading);
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--focus-ring);
}

.contact-form .pill-button {
    margin-top: 0.5rem;
    width: fit-content;
}

/* Footer */
footer {
    padding: 4rem 0 2rem;
    text-align: center;
}

footer p {
    font-size: 0.9em;
    color: var(--text-muted);
}

/* Responsive Design */
@media (max-width: 980px) {
    h1 {
        font-size: 4em;
    }

    h2 {
        font-size: 2em;
    }

    main {
        padding: 6rem 2rem;
    }
}

@media (max-width: 736px) {
    h1 {
        font-size: 3em;
        letter-spacing: 0.1rem;
    }

    h2 {
        font-size: 1.75em;
    }

    p {
        font-size: 1em;
    }

    main {
        padding: 4rem 1.5rem;
    }

    .about {
        padding: 1.5rem;
    }

    .project-item {
        padding: 1.5rem;
    }

    .pill-button {
        min-width: auto;
        width: 100%;
    }

    .button-group {
        flex-direction: column;
    }

    .contact-form {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2.5em;
    }

    main {
        padding: 3rem 1rem;
    }

    .about {
        padding: 1.25rem;
        border-radius: 16px;
    }

    .project-item {
        padding: 1.25rem;
        border-radius: 16px;
    }
}
