/* ===========================================
   CSS Variables - Dark Mode (Blackish Brown)
   =========================================== */
:root {
    --primary-color: #d4a574;
    --secondary-color: #c9936a;
    --accent-color: #e8b98c;
    --gradient-1: linear-gradient(135deg, #6b4423 0%, #3e2723 100%);
    --gradient-2: linear-gradient(135deg, #8b6347 0%, #5d4037 100%);
    --gradient-3: linear-gradient(135deg, #a1887f 0%, #6d4c41 100%);
    --gradient-animated: linear-gradient(270deg, #6b4423, #3e2723, #5d4037, #4e342e);
    --text-dark: #e8dcc8;
    --text-light: #b8a89a;
    --bg-dark: #1a1311;
    --bg-darker: #0d0907;
    --bg-card: #241b17;
    --bg-card-hover: #332721;
    --border-color: #3d2f26;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.7);
    --shadow-glow: 0 0 40px rgba(212, 165, 116, 0.3);
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --bg-navbar: rgba(13, 9, 7, 0.95);
    --bg-navbar-scrolled: rgba(26, 19, 17, 0.95);
    --navbar-shadow: 0 4px 30px rgba(0, 0, 0, 0.7);
    --footer-link-color: rgba(255, 255, 255, 0.7);
    --footer-link-hover: #ffffff;
    --footer-social-bg: rgba(255, 255, 255, 0.1);
    --footer-social-color: #ffffff;
    --footer-border: rgba(255, 255, 255, 0.1);
}

body.light-theme {
    --primary-color: #b0703c;
    --secondary-color: #92582b;
    --accent-color: #7b461f;
    --gradient-1: linear-gradient(135deg, #f7efe6 0%, #eadccb 100%);
    --gradient-2: linear-gradient(135deg, #efe2d5 0%, #decab8 100%);
    --gradient-3: linear-gradient(135deg, #e3d3c4 0%, #cfb9a3 100%);
    --gradient-animated: linear-gradient(270deg, #f7efe6, #eadccb, #e3d3c4, #decab8);
    --text-dark: #2c1b18;
    --text-light: #6a534e;
    --bg-dark: #faf7f2;
    --bg-darker: #f3eae0;
    --bg-card: #ffffff;
    --bg-card-hover: #faf6f2;
    --border-color: #e5d4c3;
    --shadow: 0 4px 15px rgba(44, 27, 24, 0.05);
    --shadow-lg: 0 20px 40px rgba(44, 27, 24, 0.08);
    --shadow-glow: 0 0 30px rgba(176, 112, 60, 0.15);
    --bg-navbar: rgba(245, 236, 227, 0.95);
    --bg-navbar-scrolled: rgba(250, 245, 240, 0.95);
    --navbar-shadow: 0 4px 30px rgba(44, 27, 24, 0.08);
    --footer-link-color: var(--text-light);
    --footer-link-hover: var(--primary-color);
    --footer-social-bg: rgba(44, 27, 24, 0.05);
    --footer-social-color: var(--text-dark);
    --footer-border: var(--border-color);
}

/* Theme Toggle Button */
.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    color: var(--primary-color);
    padding: 0.5rem;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    border: 1px solid var(--border-color);
    z-index: 1001;
}

.theme-toggle:hover {
    background: var(--bg-card);
    transform: rotate(30deg) scale(1.1);
    box-shadow: var(--shadow-glow);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: linear-gradient(to bottom, var(--bg-darker) 0%, var(--bg-dark) 100%);
    position: relative;
    overflow-x: hidden;
    min-height: 100vh;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(107, 68, 35, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(139, 99, 71, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(161, 136, 127, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
    animation: bgFloat 20s ease-in-out infinite;
}

@keyframes bgFloat {
    0%, 100% { transform: translate(0, 0); }
    25% { transform: translate(-20px, -20px); }
    50% { transform: translate(20px, 20px); }
    75% { transform: translate(-10px, 10px); }
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

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

/* ===========================================
   Navigation
   =========================================== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--bg-navbar) !important;
    backdrop-filter: blur(20px) saturate(180%);
    box-shadow: var(--navbar-shadow);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    padding: 1rem 0;
    transition: var(--transition);
}

.navbar::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--primary-color);
    transition: width 0.3s ease;
    box-shadow: 0 0 10px rgba(212, 165, 116, 0.5);
}

.navbar.scrolled {
    background: var(--bg-navbar-scrolled) !important;
    box-shadow: var(--navbar-shadow);
}

.navbar.scrolled::before {
    width: 100%;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-color) !important;
    position: relative;
    transition: var(--transition);
}

.nav-logo:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 2px 8px rgba(102, 126, 234, 0.3));
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    color: var(--text-dark) !important;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: var(--transition);
}

.nav-link:hover {
    background: var(--bg-card);
    color: var(--primary-color);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    gap: 4px;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    border-radius: 3px;
    transition: var(--transition);
}

/* ===========================================
   Hero Section
   =========================================== */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 8rem 2rem 4rem;
    background: var(--gradient-animated);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    position: relative;
    overflow: hidden;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23ffffff" fill-opacity="0.1" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,154.7C960,171,1056,181,1152,165.3C1248,149,1344,107,1392,85.3L1440,64L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') no-repeat bottom;
    background-size: cover;
    animation: wave 10s ease-in-out infinite;
}

@keyframes wave {
    0%, 100% { transform: translateX(0) translateY(0); }
    50% { transform: translateX(-25px) translateY(-10px); }
}

.hero::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 50%, rgba(255,255,255,0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(255,255,255,0.1) 0%, transparent 50%);
    animation: pulse 8s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.hero-content {
    max-width: 1200px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-text {
    color: var(--text-dark);
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.highlight {
    background: linear-gradient(135deg, #f093fb, #f5576c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    min-height: 2rem;
}

.typing-text::after {
    content: '|';
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.hero-description {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-image img {
    width: 300px !important;
    height: 300px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 3px solid var(--primary-color) !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5),
                0 0 30px rgba(212, 165, 116, 0.3) !important;
    animation: float 6s ease-in-out infinite;
    transition: var(--transition);
}

.hero-image img:hover {
    transform: scale(1.05);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.6),
                0 0 40px rgba(212, 165, 116, 0.5);
}

.image-placeholder {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px);
    border: 3px solid rgba(255, 255, 255, 0.3);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 150px;
    color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3),
                inset 0 0 50px rgba(255, 255, 255, 0.1);
    animation: float 6s ease-in-out infinite;
    position: relative;
    overflow: hidden;
}

.image-placeholder::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 3s infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

@keyframes shimmer {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    animation: bounce 2s infinite;
    z-index: 10;
}

.scroll-indicator a {
    color: white;
    font-size: 2.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    transition: var(--transition);
}

.scroll-indicator a:hover {
    transform: scale(1.2);
    color: rgba(255, 255, 255, 0.9);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { 
        transform: translateY(0); 
        opacity: 1;
    }
    40% { 
        transform: translateY(-20px); 
        opacity: 0.8;
    }
    60% { 
        transform: translateY(-10px); 
    }
}

/* ===========================================
   Buttons
   =========================================== */
.btn {
    display: inline-block;
    padding: 0.9rem 2.5rem;
    border-radius: 50px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn-primary {
    background: var(--gradient-1);
    color: white;
    box-shadow: 0 6px 20px rgba(129, 140, 248, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 30px rgba(129, 140, 248, 0.6);
}

.btn-secondary {
    background: var(--bg-card);
    border-color: var(--primary-color);
    border-width: 2px;
    color: var(--primary-color);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: var(--bg-darker);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 30px rgba(129, 140, 248, 0.4);
}

/* ===========================================
   Sections
   =========================================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

section {
    padding: 5rem 0;
}

.section-title {
    font-size: 3rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 3rem;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    display: inline-block;
    width: 100%;
    animation: titleFloat 3s ease-in-out infinite;
}

@keyframes titleFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: var(--gradient-2);
    border-radius: 2px;
    animation: lineExpand 2s ease-in-out infinite;
}

@keyframes lineExpand {
    0%, 100% { width: 100px; }
    50% { width: 150px; }
}

.about-section {
    background: linear-gradient(180deg, var(--bg-dark) 0%, var(--bg-darker) 100%);
    position: relative;
    overflow: hidden;
}

.about-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 15s ease-in-out infinite;
}

.about-section::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 12s ease-in-out infinite reverse;
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-text p {
    font-size: 1.1rem;
    color: var(--text-light);
    margin-bottom: 2rem;
    line-height: 1.8;
}

.achievement-badges {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(139, 92, 246, 0.1));
    border: 2px solid rgba(102, 126, 234, 0.3);
    border-radius: 50px;
    font-weight: 600;
    color: var(--primary-color);
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.1);
}

.badge:hover {
    background: var(--gradient-1);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.badge i {
    font-size: 1.2rem;
}

.about-text h3 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: var(--text-dark);
}

/* ===========================================
   Skills Grid
   =========================================== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.skill-card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    padding: 2rem 1rem;
    border-radius: 16px;
    text-align: center;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    transition: var(--transition-bounce);
    position: relative;
    overflow: hidden;
}

.skill-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    transform: rotate(45deg);
    transition: var(--transition);
}

.skill-card:hover::before {
    animation: shine 0.8s ease;
}

@keyframes shine {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

.skill-card:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: var(--shadow-glow), var(--shadow-lg);
    border-color: var(--primary-color);
}

.skill-card i {
    font-size: 3.5rem;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1rem;
    display: block;
    transition: var(--transition);
}

.skill-card:hover i {
    transform: rotateY(360deg) scale(1.2);
}

.skill-card span {
    display: block;
    font-weight: 600;
    color: var(--text-dark);
    position: relative;
    z-index: 1;
}

/* ===========================================
   Patents Section
   =========================================== */
.patents-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
}

.patents-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: float 20s ease-in-out infinite;
}

.patents-section .section-title {
    color: white;
    -webkit-text-fill-color: white;
}

.patents-section .section-title::after {
    background: rgba(255, 255, 255, 0.3);
}

.patents-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.patent-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    border: 2px solid var(--border-color);
    transition: var(--transition-bounce);
    position: relative;
    overflow: hidden;
}

.patent-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.6s ease;
}

.patent-card:hover::before {
    left: 100%;
}

.patent-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.8);
    border-color: var(--primary-color);
}

.patent-icon {
    width: 80px;
    height: 80px;
    background: var(--gradient-1);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
    animation: float 3s ease-in-out infinite;
}

.patent-icon i {
    font-size: 2.5rem;
    color: white;
}

.patent-content h3 {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.patent-number {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-family: 'Courier New', monospace;
}

.patent-date {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.patent-date i {
    color: var(--accent-color);
}

.patent-description {
    color: var(--text-light);
    line-height: 1.7;
    margin-bottom: 1.5rem;
    font-size: 1rem;
    text-align: justify;
}

.patent-highlights {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08), rgba(139, 92, 246, 0.08));
    border-left: 4px solid var(--primary-color);
    padding: 1rem 1.2rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
}

.patent-highlights p {
    margin-bottom: 0.6rem;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-dark);
}

.patent-highlights p:last-child {
    margin-bottom: 0;
}

.patent-highlights strong {
    color: var(--primary-color);
    font-weight: 700;
}

.patent-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* ===========================================
   Publications Section
   =========================================== */
.publications-section {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--bg-dark) 0%, var(--bg-darker) 100%);
    position: relative;
    overflow: hidden;
}

.publications-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.05) 0%, transparent 70%);
    animation: float 20s ease-in-out infinite reverse;
}

.publications-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-top: 3rem;
}

.publication-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    border: 2px solid var(--border-color);
    transition: var(--transition-bounce);
    position: relative;
    overflow: hidden;
}

.publication-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    transition: left 0.6s ease;
}

.publication-card:hover::before {
    left: 100%;
}

.publication-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(102, 126, 234, 0.15);
    border-color: var(--primary-color);
}

.publication-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.publication-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #FF9900 0%, #FF6B00 100%);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 20px rgba(255, 153, 0, 0.3);
    flex-shrink: 0;
}

.publication-icon i {
    font-size: 2rem;
    color: white;
}

.publication-meta {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.publication-type {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
    color: var(--primary-color);
}

.publication-platform {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-dark);
}

.publication-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.8rem;
    line-height: 1.3;
}

.publication-date {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.publication-date i {
    color: var(--primary-color);
}

.publication-excerpt {
    color: var(--text-light);
    line-height: 1.7;
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

.publication-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background: linear-gradient(135deg, #FF9900 0%, #FF6B00 100%);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition-bounce);
    box-shadow: 0 4px 15px rgba(255, 153, 0, 0.3);
}

.publication-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 153, 0, 0.4);
}

.publication-link i {
    font-size: 1rem;
}

.personal-blog-cta {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(139, 92, 246, 0.1));
    border-radius: 24px;
    padding: 2.5rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border: 2px solid rgba(102, 126, 234, 0.2);
}

.personal-blog-cta h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.personal-blog-cta p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

@media (max-width: 768px) {
    .publications-content {
        grid-template-columns: 1fr;
    }
}

/* ===========================================
   Creative Coding Section
   =========================================== */
.creative-coding-section {
    padding: 6rem 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    position: relative;
    overflow: hidden;
}

.creative-coding-section::before {
    content: '';
    position: absolute;
    top: -30%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 70%);
    animation: float 15s ease-in-out infinite;
}

.creative-coding-section .section-title {
    color: white;
    -webkit-text-fill-color: white;
}

.creative-coding-section .section-title::after {
    background: rgba(255, 255, 255, 0.3);
}

.section-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.9);
    margin-top: -1rem;
    margin-bottom: 3rem;
    font-weight: 400;
}

.creative-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.creative-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.6);
    border: 2px solid var(--border-color);
    transition: var(--transition-bounce);
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.creative-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.4);
}

.creative-placeholder {
    text-align: center;
    padding: 3rem;
    color: var(--text-light);
}

.creative-placeholder i {
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    display: block;
}

.creative-placeholder p {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-dark);
}

/* ===========================================
   Projects
   =========================================== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.project-card {
    background: var(--bg-card);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    border: 2px solid transparent;
}

.project-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-1);
    opacity: 0;
    transition: var(--transition);
    z-index: 0;
    border-radius: 20px;
}

.project-card:hover {
    transform: translateY(-15px) rotateX(5deg);
    box-shadow: var(--shadow-glow), 0 25px 50px rgba(0, 0, 0, 0.25);
    border-color: var(--primary-color);
}

.project-card:hover::after {
    opacity: 0.05;
}

.project-image {
    height: 200px;
    overflow: hidden;
    background: var(--gradient-animated);
    background-size: 400% 400%;
    animation: gradientShift 10s ease infinite;
    position: relative;
}

.project-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: var(--transition);
}

.project-card:hover .project-image::before {
    left: 100%;
    transition: left 0.7s ease;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.6);
    animation: float 4s ease-in-out infinite;
}

.project-content {
    padding: 1.5rem;
    position: relative;
    z-index: 1;
}

.project-content h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
    transition: var(--transition);
}

.project-card:hover .project-content h3 {
    color: var(--primary-color);
    transform: translateX(5px);
}

.project-content p {
    color: var(--text-light);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tag {
    display: inline-block;
    padding: 0.35rem 0.9rem;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(139, 92, 246, 0.1));
    color: var(--primary-color);
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid rgba(102, 126, 234, 0.2);
    transition: var(--transition);
}

.tag:hover {
    background: var(--gradient-1);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.project-links {
    display: flex;
    gap: 1rem;
}

.project-link {
    padding: 0.6rem 1.2rem;
    background: var(--gradient-1);
    color: var(--text-dark);
    border-radius: 25px;
    font-weight: 600;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(107, 68, 35, 0.4);
    position: relative;
    overflow: hidden;
    border: 2px solid var(--primary-color);
}

.project-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s ease;
}

.project-link:hover::before {
    left: 100%;
}

.project-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(212, 165, 116, 0.6);
    background: var(--primary-color);
    color: var(--bg-darker);
}

/* ===========================================
   Contact Section
   =========================================== */
.contact-section {
    background: linear-gradient(180deg, white 0%, var(--bg-light) 50%, #667eea 100%);
    position: relative;
    overflow: hidden;
}

.contact-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--gradient-1);
    box-shadow: 0 0 20px rgba(102, 126, 234, 0.5);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-info h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

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

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-card);
    border-radius: 8px;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1.2rem;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    background: var(--bg-darker);
    color: var(--text-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1),
                0 4px 20px rgba(102, 126, 234, 0.2);
    transform: translateY(-2px);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-light);
    opacity: 0.7;
}

/* ===========================================
   Footer
   =========================================== */
.footer {
    background: var(--bg-darker);
    color: var(--text-dark);
    padding: 3rem 0 1rem;
    border-top: 1px solid var(--border-color);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--footer-link-color);
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--footer-link-hover);
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--footer-social-bg);
    border-radius: 50%;
    color: var(--footer-social-color);
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--footer-border);
    color: var(--footer-link-color);
}

.footer-bottom i {
    color: #e25555;
}

/* ===========================================
   Utility Classes
   =========================================== */
.text-center {
    text-align: center;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-state i {
    font-size: 4rem;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

/* ===========================================
   Responsive Design
   =========================================== */
@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: var(--bg-card);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow);
        padding: 2rem 0;
        border-bottom: 1px solid var(--border-color);
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .patents-grid {
        grid-template-columns: 1fr;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
}

/* Creative Coding Sketches Styling */
.creative-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.sketch-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-dark);
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: var(--shadow);
}

.sketch-btn:hover {
    transform: translateY(-2px);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-glow);
}

.sketch-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--bg-darker) !important;
}

.creative-canvas-container {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
    background: var(--bg-card);
}

#p5-canvas-container {
    width: 100%;
    height: 400px;
    display: block;
    position: relative;
}

.canvas-instructions {
    background: var(--bg-darker);
    padding: 1rem;
    text-align: center;
    border-top: 1px solid var(--border-color);
}

.canvas-instructions p {
    margin: 0;
    font-size: 0.9rem;
    color: var(--text-light);
}

.canvas-instructions i {
    color: var(--primary-color);
    margin-right: 0.25rem;
}

/* Glassmorphic Explore Card */
.creative-explore-card {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 24px;
    padding: 2.5rem 2rem;
    max-width: 900px;
    margin: 3rem auto 0 auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    text-align: center;
    color: white;
}

.creative-explore-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.creative-explore-desc {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.creative-explore-buttons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.creative-explore-btn {
    background: white;
    color: #764ba2;
    padding: 0.85rem 2.2rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    border: 2px solid transparent;
    text-decoration: none;
}

.creative-explore-btn:hover {
    background: transparent;
    color: white;
    border-color: white;
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(255, 255, 255, 0.2);
}

.creative-explore-btn.btn-outline {
    background: transparent;
    color: white;
    border-color: rgba(255, 255, 255, 0.4);
}

.creative-explore-btn.btn-outline:hover {
    background: white;
    color: #764ba2;
    border-color: white;
    box-shadow: 0 15px 30px rgba(255, 255, 255, 0.25);
}

/* ===========================================
   Blog Landing Page Upgrades
   =========================================== */
.blog-hero {
    padding: 6rem 0 4rem;
    text-align: center;
    background: linear-gradient(135deg, rgba(36, 27, 23, 0.9) 0%, rgba(26, 19, 17, 0.95) 100%);
    border-bottom: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

body.light-theme .blog-hero {
    background: linear-gradient(135deg, #f7efe6 0%, #decab8 100%);
}

.blog-hero .hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(212, 165, 116, 0.1);
    color: var(--primary-color);
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(212, 165, 116, 0.2);
}

.blog-hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--text-dark) 30%, var(--primary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.blog-hero p {
    font-size: 1.2rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto 2.5rem;
}

.search-bar-container {
    max-width: 500px;
    margin: 0 auto;
    position: relative;
}

.search-icon {
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 1rem;
    pointer-events: none;
    transition: var(--transition);
}

#blogSearch {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    border-radius: 30px;
    background: var(--bg-card);
    border: 1.5px solid var(--border-color);
    color: var(--text-dark);
    font-size: 1rem;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

#blogSearch:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: var(--shadow-glow);
}

#blogSearch:focus + .search-icon {
    color: var(--primary-color);
}

/* Filters Section */
.blog-filters-section {
    padding: 2rem 0;
    background: var(--bg-darker);
    border-bottom: 1px solid var(--border-color);
}

body.light-theme .blog-filters-section {
    background: #faf7f2;
}

.filter-wrapper {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.filter-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-dark);
    padding: 0.6rem 1.25rem;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

.filter-btn:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.filter-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--bg-darker) !important;
}

/* Blog Grid */
.blog-list-section {
    padding: 5rem 0;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
    gap: 2rem;
}

.blog-card {
    background: var(--bg-card);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 2px solid transparent;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-glow), 0 20px 40px rgba(0, 0, 0, 0.25);
    border-color: var(--primary-color);
}

.blog-card-image {
    height: 200px;
    overflow: hidden;
    position: relative;
    background: var(--gradient-animated);
    background-size: 400% 400%;
    animation: gradientShift 10s ease infinite;
}

.blog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.blog-card:hover .blog-card-image img {
    transform: scale(1.08);
}

.blog-card-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.25);
    background: linear-gradient(135deg, rgba(212, 165, 116, 0.05) 0%, rgba(212, 165, 116, 0.15) 100%);
}

.blog-card-content {
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--text-light);
    margin-bottom: 0.75rem;
}

.card-meta i {
    margin-right: 0.25rem;
}

.blog-card-content h3 {
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
    line-height: 1.35;
    transition: var(--transition);
}

.blog-card-content h3 a {
    color: var(--text-dark);
    text-decoration: none;
}

.blog-card:hover .blog-card-content h3 a {
    color: var(--primary-color);
}

.blog-card-content p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.tag-badge {
    background: rgba(212, 165, 116, 0.08);
    color: var(--primary-color);
    border: 1px solid rgba(212, 165, 116, 0.15);
    padding: 0.25rem 0.6rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.blog-card-content .read-more {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.95rem;
    transition: var(--transition);
}

.blog-card:hover .blog-card-content .read-more {
    transform: translateX(5px);
}

.blog-card-content .read-more i {
    transition: var(--transition);
}

.blog-card-content .read-more:hover i {
    transform: translateX(4px);
}

