/* Global variables for consistent design */
:root {
    --bg-primary: #f5f7fa;
    --text-primary: #1d1d1f;
    --text-secondary: #48484a;
    --accent-color: #0071e3;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.4);
    --glass-shadow: 0 4px 24px -1px rgba(0, 0, 0, 0.06);
    --transition-standard: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    background: radial-gradient(circle at top left, #ffffff 0%, #f0f2f7 50%, #e2e8f0 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Glassmorphism Utility */
.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(12px) saturate(180%);
    -webkit-backdrop-filter: blur(12px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-radius: 18px;
    box-shadow: var(--glass-shadow);
}

.glass-dark {
    background: rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 0.75rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

nav .logo {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

nav .logo i {
    color: var(--accent-color);
}

nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

nav ul li a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.9rem;
    transition: var(--transition-standard);
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
}

nav ul li a:hover {
    color: var(--text-primary);
    background: rgba(0, 0, 0, 0.03);
}

/* Header / Hero */
header.content {
    margin-top: 8rem;
    margin-bottom: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding-left: 20px;
    /* Nudge to the right per user request */
}

.profile-container {
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
    width: 100%;
}

header h1 {
    font-size: 3.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #1d1d1f 0%, #434343 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

header p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* Main Content */
main {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 1.5rem 4rem;
}

.card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px) saturate(180%);
    -webkit-backdrop-filter: blur(12px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 2.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--glass-shadow);
    transition: var(--transition-standard);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px -4px rgba(0, 0, 0, 0.08);
}

h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

h2 i {
    color: var(--accent-color);
    font-size: 1.5rem;
}

/* Tech Icons */
.tech-icons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2.5rem;
    padding: 1rem 0;
}

.tech-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    padding: 1.25rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.4);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    width: 100px;
}

.tech-item:hover {
    background: rgba(255, 255, 255, 0.8);
    transform: translateY(-8px);
    box-shadow: 0 10px 25px rgba(0, 113, 227, 0.1);
    border-color: var(--accent-color);
}

.tech-icon {
    font-size: 2.5rem;
    transition: var(--transition-standard);
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.05));
}

.tech-item:hover .tech-icon {
    transform: scale(1.1);
}

.tech-item span {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Projects Grid */
/* --- PROJECTS SECTION --- */
/* A grid layout for your projects - easy to add more! */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.project-item {
    display: flex;
    flex-direction: column;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    transition: var(--transition-standard);
    height: 100%;
}

.project-item :last-child {
    margin-top: auto;
}

.project-item:hover {
    background: white;
    transform: scale(1.02);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.project-item h3 {
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
}

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

.project-item a {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
}



/* --- COOKIE BANNER --- */
/* Subtle glassmorphic banner for cookie consent */
.cookie-banner {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    right: 2rem;
    max-width: 600px;
    margin: 0 auto;
    z-index: 3000;
    display: none;
    /* Controlled by JS */
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 2rem;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.cookie-banner p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
    flex: 1;
}

.cookie-btn,
.primary-btn {
    background: var(--accent-color);
    color: #ffffff !important;
    border: none;
    padding: 0.75rem 1.75rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: var(--transition-standard);
    white-space: nowrap;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.cookie-btn:hover,
.primary-btn:hover {
    background: #0056b3;
    color: #ffffff !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 113, 227, 0.3);
}

/* --- FOOTER --- */
footer {
    padding: 4rem 2rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.4);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

footer p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Preloader */
#preloader {
    background: #ffffff;
    z-index: 2000;
}

.loader {
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--accent-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Animations */
.animate-float {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    header h1 {
        font-size: 2.5rem;
    }

    nav {
        padding: 0.75rem 1rem;
    }

    #menu-toggle {
        display: block !important;
        background: none;
        border: none;
        font-size: 1.25rem;
        cursor: pointer;
    }

    #menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        gap: 0;
    }

    #menu.menu-active {
        display: flex;
    }

    nav ul li a {
        display: block;
        padding: 1rem;
        width: 100%;
        text-align: center;
    }
}