/* OpenAI-Inspired Modern Design */
/* Clean, minimal, typography-focused */

@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:wght@400;500;600;700;800&family=DM+Sans:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
    --bg: #ffffff;
    --bg-secondary: #fafafa;
    --bg-card: #ffffff;
    --text: #171717;
    --text-secondary: #525252;
    --text-muted: #a3a3a3;
    --accent: #10a37f;
    --accent-hover: #0d8a6a;
    --accent-light: rgba(16, 163, 127, 0.1);
    --border: #e5e5e5;
    --border-light: #f0f0f0;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.08);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition: 0.2s ease;
}

/* Dark Mode */
[data-theme="dark"] {
    --bg: #0d0d0d;
    --bg-secondary: #171717;
    --bg-card: #1a1a1a;
    --text: #fafafa;
    --text-secondary: #a3a3a3;
    --text-muted: #737373;
    --accent: #10a37f;
    --accent-hover: #1db990;
    --accent-light: rgba(16, 163, 127, 0.15);
    --border: #2a2a2a;
    --border-light: #222222;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.4);
}

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    font-weight: 400;
    min-height: 100vh;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* ==========================================
   NAVIGATION
   ========================================== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 64px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    z-index: 1000;
    transition: all var(--transition);
}

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

.nav-logo {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
    letter-spacing: -0.02em;
}

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

.nav-link {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color var(--transition);
}

.nav-link:hover {
    color: var(--text);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.theme-toggle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
}

.theme-toggle:hover {
    background: var(--bg-secondary);
    color: var(--text);
}

.theme-toggle svg {
    width: 18px;
    height: 18px;
}

.theme-toggle .sun-icon { display: none; }
.theme-toggle .moon-icon { display: block; }
[data-theme="dark"] .theme-toggle .sun-icon { display: block; }
[data-theme="dark"] .theme-toggle .moon-icon { display: none; }

/* ==========================================
   MAIN CONTAINER
   ========================================== */
.main {
    padding-top: 64px;
}

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

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

/* ==========================================
   HERO SECTION
   ========================================== */
.hero {
    padding: 120px 0 80px;
    text-align: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--accent-light);
    color: var(--accent);
    border-radius: 100px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 24px;
    border: 1px solid transparent;
    transition: all var(--transition);
}

.hero-badge:hover {
    border-color: var(--accent);
}

.hero-title {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: clamp(48px, 8vw, 80px);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-bottom: 24px;
}

.hero-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
    line-height: 1.6;
}

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

.hero-profile {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 32px;
    border: 3px solid var(--border);
    transition: all var(--transition);
}

.hero-profile:hover {
    border-color: var(--accent);
    transform: scale(1.02);
}

/* ==========================================
   BUTTONS
   ========================================== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius-md);
    text-decoration: none;
    cursor: pointer;
    transition: all var(--transition);
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: var(--text);
    color: var(--bg);
}

.btn-primary:hover {
    opacity: 0.85;
    transform: translateY(-1px);
}

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

.btn-secondary:hover {
    background: var(--bg-secondary);
    border-color: var(--text-muted);
}

.btn-accent {
    background: var(--accent);
    color: white;
}

.btn-accent:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
}

.btn svg {
    width: 18px;
    height: 18px;
}

/* ==========================================
   SECTIONS
   ========================================== */
.section {
    padding: 80px 0;
    border-top: 1px solid var(--border);
}

.section-header {
    text-align: center;
    margin-bottom: 56px;
}

.section-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 12px;
}

.section-title {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: clamp(32px, 5vw, 48px);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 16px;
}

.section-desc {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* ==========================================
   ABOUT SECTION
   ========================================== */
.about-content {
    max-width: 720px;
    margin: 0 auto;
}

.about-text {
    font-size: 18px;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 24px;
}

.about-text strong {
    color: var(--text);
    font-weight: 600;
}

/* ==========================================
   RESEARCH AREAS / TAGS
   ========================================== */
.tags-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.tag {
    padding: 10px 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 100px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all var(--transition);
}

.tag:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-light);
}

/* ==========================================
   SKILLS / FRAMEWORKS GRID
   ========================================== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr));
    gap: 24px;
}

.skill-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 28px;
    transition: all var(--transition);
}

.skill-card:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-md);
}

.skill-card-title {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.skill-card-title::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--accent);
    border-radius: 50%;
}

.skill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.skill-item {
    padding: 6px 14px;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
    transition: all var(--transition);
}

.skill-item:hover {
    color: var(--accent);
    background: var(--accent-light);
}

/* ==========================================
   EXPERIENCE CARDS
   ========================================== */
.experience-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 720px;
    margin: 0 auto;
}

.experience-card {
    display: flex;
    gap: 20px;
    padding: 28px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    transition: all var(--transition);
}

.experience-card:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-md);
}

.experience-icon {
    width: 48px;
    height: 48px;
    background: var(--accent-light);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    flex-shrink: 0;
}

.experience-icon svg {
    width: 24px;
    height: 24px;
}

.experience-content {
    flex: 1;
}

.experience-title {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 6px;
}

.experience-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.experience-meta {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 8px;
}

/* ==========================================
   CERTIFICATIONS
   ========================================== */
.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
    gap: 20px;
    max-width: 720px;
    margin: 0 auto;
}

.cert-card {
    padding: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    transition: all var(--transition);
}

.cert-card:hover {
    border-color: var(--accent);
}

.cert-title {
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
}

.cert-desc {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Rapid Learner Badge */
.rapid-learner-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 20px auto 0;
    padding: 12px 20px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    max-width: fit-content;
    transition: all 0.2s ease;
}

.rapid-learner-badge:hover {
    border-color: var(--accent);
}

.rapid-icon {
    font-size: 24px;
    line-height: 1;
}

.rapid-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.rapid-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--accent);
}

.rapid-desc {
    font-size: 13px;
    color: var(--text-secondary);
}

.cert-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 12px;
}

.cert-badge {
    padding: 4px 10px;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

/* ==========================================
   OPEN SOURCE / PROJECT CARD
   ========================================== */
.project-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 40px;
    max-width: 800px;
    margin: 0 auto;
    transition: all var(--transition);
}

.project-card:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-lg);
}

.project-header {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 24px;
}

.project-logo {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #ee4c2c 0%, #ff6f3c 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    flex-shrink: 0;
}

.project-info {
    flex: 1;
}

.project-title {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 4px;
}

.project-tagline {
    font-size: 14px;
    color: var(--text-secondary);
}

.project-desc {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 28px;
}

.project-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 28px;
}

.project-cat {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 13px;
    color: var(--text-secondary);
    transition: all var(--transition);
}

.project-cat:hover {
    border-color: #ee4c2c;
    color: #ee4c2c;
}

.project-cat svg {
    width: 16px;
    height: 16px;
    opacity: 0.7;
}

.project-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-pytorch {
    background: linear-gradient(135deg, #ee4c2c 0%, #ff6f3c 100%);
    color: white;
}

.btn-pytorch:hover {
    opacity: 0.9;
}

/* ==========================================
   AI PLAYGROUND / DEMOS
   ========================================== */
.demos-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.demo-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    transition: all var(--transition);
}

.demo-card:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-md);
}

.demo-card.wide {
    grid-column: 1 / -1;
}

.demo-card h3 {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.demo-card h3 svg {
    width: 18px;
    height: 18px;
    color: var(--accent);
}

.demo-card > p {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.5;
}

.demo-canvas-container {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    aspect-ratio: 4/3;
}

.demo-card.wide .demo-canvas-container {
    aspect-ratio: 21/9;
}

.demo-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.demo-controls {
    display: flex;
    gap: 8px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.demo-controls-row {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    align-items: center;
    margin-top: 16px;
}

.demo-controls-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.demo-controls-group label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

.demo-btn {
    padding: 8px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
}

.demo-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.demo-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
}

.demo-select {
    padding: 8px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 12px;
    color: var(--text);
    cursor: pointer;
    font-family: inherit;
}

.demo-slider {
    width: 80px;
    height: 4px;
    -webkit-appearance: none;
    background: var(--border);
    border-radius: 2px;
    outline: none;
}

.demo-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
}

.demo-value {
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    color: var(--accent);
    min-width: 45px;
}

.demo-info {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 12px;
    font-style: italic;
}

.nn-tooltip {
    position: absolute;
    background: var(--bg-card);
    border: 1px solid var(--accent);
    border-radius: var(--radius-sm);
    padding: 8px 12px;
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    color: var(--text);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s ease;
    z-index: 10;
    white-space: nowrap;
}

.nn-tooltip.visible { opacity: 1; }
.nn-tooltip .label { color: var(--text-muted); font-size: 10px; display: block; }
.nn-tooltip .value { color: var(--accent); font-weight: 500; }

.gd-legend {
    display: flex;
    gap: 16px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.gd-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-muted);
}

.gd-legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

/* ==========================================
   SOCIAL LINKS
   ========================================== */
.social-links {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.social-link {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 50%;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all var(--transition);
}

.social-link:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-light);
}

.social-link svg {
    width: 20px;
    height: 20px;
}

/* ==========================================
   FOOTER
   ========================================== */
.footer {
    padding: 40px 0;
    border-top: 1px solid var(--border);
    text-align: center;
}

.footer-text {
    font-size: 14px;
    color: var(--text-muted);
}

.footer-links {
    display: flex;
    gap: 24px;
    justify-content: center;
    margin-bottom: 16px;
}

.footer-link {
    font-size: 14px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color var(--transition);
}

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

/* ==========================================
   CHATBOT
   ========================================== */
.chatbot-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1000;
    font-family: 'DM Sans', sans-serif;
}

.chatbot-toggle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--text);
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg);
}

.chatbot-toggle:hover {
    transform: scale(1.05);
}

.chatbot-toggle svg {
    width: 24px;
    height: 24px;
}

.chatbot-toggle .close-icon { display: none; }
.chatbot-container.open .chatbot-toggle .chat-icon { display: none; }
.chatbot-container.open .chatbot-toggle .close-icon { display: block; }

.chatbot-window {
    position: absolute;
    bottom: 70px;
    right: 0;
    width: 380px;
    max-height: 520px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transform: translateY(16px) scale(0.96);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.chatbot-container.open .chatbot-window {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.chatbot-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid var(--border);
    position: relative;
    overflow: visible;
}

.chatbot-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border);
}

.chatbot-header-info {
    flex: 1;
}

.chatbot-name {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-weight: 600;
    font-size: 15px;
    color: var(--text);
}

.chatbot-status {
    font-size: 12px;
    color: var(--text-muted);
}

.async-badge {
    position: relative;
    background: var(--accent);
    color: white;
    font-size: 10px;
    font-weight: 600;
    padding: 5px 10px;
    border-radius: 100px;
    cursor: pointer;
    transition: all var(--transition);
}

.async-badge:hover {
    transform: scale(1.05);
}

.async-tooltip {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: 240px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.2s ease;
    z-index: 100;
    box-shadow: var(--shadow-lg);
}

.async-badge:hover .async-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.async-tooltip h4 {
    font-size: 13px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 8px;
}

.async-tooltip p {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 12px;
}

.async-tooltip code {
    display: block;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    font-size: 11px;
    font-family: 'JetBrains Mono', monospace;
    color: var(--accent);
    overflow-x: auto;
}

.chatbot-close-btn {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--text-muted);
    transition: color var(--transition);
    flex-shrink: 0;
}

.chatbot-close-btn:hover {
    color: var(--text);
}

.chatbot-close-btn svg {
    width: 20px;
    height: 20px;
}

.chatbot-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 300px;
    min-height: 200px;
}

.chat-message {
    display: flex;
    max-width: 85%;
    animation: messageSlide 0.3s ease;
}

@keyframes messageSlide {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.chat-message.bot { align-self: flex-start; }
.chat-message.user { align-self: flex-end; }

.message-content {
    padding: 12px 16px;
    border-radius: var(--radius-lg);
    font-size: 14px;
    line-height: 1.5;
}

.chat-message.bot .message-content {
    background: var(--bg-secondary);
    color: var(--text);
    border-bottom-left-radius: 4px;
}

.chat-message.user .message-content {
    background: var(--text);
    color: var(--bg);
    border-bottom-right-radius: 4px;
}

.chatbot-suggestions {
    display: flex;
    gap: 8px;
    padding: 0 20px 16px;
    flex-wrap: wrap;
}

.suggestion-chip {
    padding: 8px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 100px;
    font-size: 12px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
}

.suggestion-chip:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.chatbot-input-container {
    display: flex;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid var(--border);
}

.chatbot-input {
    flex: 1;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 100px;
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: border-color var(--transition);
}

.chatbot-input:focus {
    border-color: var(--accent);
}

.chatbot-input::placeholder {
    color: var(--text-muted);
}

.chatbot-send {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--text);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg);
    transition: all var(--transition);
}

.chatbot-send:hover {
    transform: scale(1.05);
}

.chatbot-send svg {
    width: 18px;
    height: 18px;
}

.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 12px 16px;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    background: var(--text-muted);
    border-radius: 50%;
    animation: typing 1.4s infinite ease-in-out;
}

.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing {
    0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
    30% { transform: translateY(-6px); opacity: 1; }
}

/* ==========================================
   CV FILTER (Profile Picture Demo)
   ========================================== */
.profile-demo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-bottom: 32px;
}

#profile-canvas {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 3px solid var(--border);
    cursor: pointer;
    transition: all var(--transition);
}

#profile-canvas:hover {
    border-color: var(--accent);
}

.cv-filter-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.cv-filter-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cv-filter-header label {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
}

.cv-info-btn {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cv-info-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
}

#cv-filter-select {
    padding: 8px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 13px;
    font-family: inherit;
    cursor: pointer;
    outline: none;
    transition: border-color var(--transition);
}

#cv-filter-select:hover,
#cv-filter-select:focus {
    border-color: var(--accent);
}

.cv-tooltip {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    width: 320px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    z-index: 1000;
    box-shadow: var(--shadow-lg);
}

.cv-tooltip.active {
    opacity: 1;
    visibility: visible;
}

.cv-tooltip-header {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.cv-tooltip h4 {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-size: 16px;
    color: var(--text);
    margin-bottom: 8px;
}

.cv-tooltip p {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 16px;
}

.cv-tooltip .kernel-display {
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    padding: 12px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: var(--text);
    white-space: pre;
    line-height: 1.5;
}

/* Hidden elements for functionality */
.profile-pic { display: none; }

/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 900px) {
    .nav-links { display: none; }
    
    .demos-grid {
        grid-template-columns: 1fr;
        max-width: 100%;
    }
    
    .demo-card {
        max-width: 100%;
        overflow: hidden;
    }
    
    .demo-card.wide .demo-canvas-container {
        aspect-ratio: 16/10;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .main {
        text-align: center;
        overflow-x: hidden;
        width: 100%;
    }
    
    .hero {
        padding: 80px 0 60px;
        text-align: center;
        overflow-x: hidden;
    }
    
    .hero-title {
        font-size: 36px;
    }
    
    .hero-subtitle {
        font-size: 16px;
    }
    
    .section {
        padding: 60px 0;
        text-align: center;
        overflow-x: hidden;
    }
    
    .section-title {
        font-size: 28px;
    }
    
    .hero-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        justify-content: center;
        width: 100%;
    }
    
    .container {
        padding: 0 16px;
        max-width: 100%;
        text-align: center;
    }
    
    .container-narrow {
        padding: 0 16px;
        max-width: 100%;
        text-align: center;
    }
    
    .skill-card {
        text-align: center;
    }
    
    .skill-card-title {
        justify-content: center;
    }
    
    .skill-list {
        justify-content: center;
    }
    
    .tags-grid {
        justify-content: center;
    }
    
    .about-content {
        text-align: center;
    }
    
    .experience-grid {
        align-items: center;
    }
    
    .cert-card {
        text-align: center;
    }
    
    .cert-badges {
        justify-content: center;
    }
    
    .cert-grid {
        justify-items: center;
    }
    
    .project-card {
        padding: 24px;
        text-align: center;
    }
    
    .project-header {
        flex-direction: column;
        align-items: center;
    }
    
    .project-tech {
        justify-content: center;
    }
    
    .skills-grid {
        justify-items: center;
    }
    
    .demos-grid {
        display: block;
        width: 100%;
    }
    
    .demo-card {
        padding: 16px;
        width: 100%;
        max-width: 100%;
        text-align: center;
        overflow: hidden;
        box-sizing: border-box;
        margin-bottom: 16px;
    }
    
    .demo-card.wide {
        grid-column: auto;
    }
    
    .demo-card h3 {
        justify-content: center;
    }
    
    .demo-card > p {
        text-align: center;
    }
    
    .demo-canvas-container {
        width: 100%;
        max-width: 100%;
        aspect-ratio: 4/3;
    }
    
    .demo-card.wide .demo-canvas-container {
        aspect-ratio: 4/3;
    }
    
    .demo-controls {
        flex-wrap: wrap;
        justify-content: center;
        width: 100%;
    }
    
    .chatbot-container {
        bottom: 16px;
        right: 16px;
    }
    
    .chatbot-toggle {
        width: 50px;
        height: 50px;
    }
    
    .chatbot-window {
        position: fixed;
        width: calc(100vw - 32px);
        max-width: 400px;
        max-height: 70vh;
        right: 16px;
        left: auto;
        bottom: 80px;
    }
    
    .chatbot-close-btn {
        display: block;
    }
    
    .chatbot-header {
        padding: 16px;
        gap: 10px;
    }
    
    .chatbot-avatar {
        width: 36px;
        height: 36px;
    }
    
    .chatbot-name {
        font-size: 14px;
    }
    
    .chatbot-status {
        font-size: 11px;
    }
    
    .async-badge {
        display: none;
    }
    
    .experience-card {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
    
    .demo-controls-row {
        flex-direction: column;
        align-items: center;
        gap: 12px;
        width: 100%;
    }
    
    .demo-controls-group {
        flex-direction: column;
        align-items: center;
        width: 100%;
        gap: 8px;
    }
    
    .demo-controls-group label {
        width: 100%;
        text-align: center;
    }
    
    .demo-btn {
        width: auto;
        min-width: 80px;
    }
    
    .demo-slider {
        width: 100%;
        max-width: 200px;
    }
    
    .wisdom-widget {
        bottom: 80px;
        left: 16px;
    }
    
    .wisdom-card {
        width: 260px;
    }
}

/* ==========================================
   WISDOM WIDGET (Subtle Affirmations)
   ========================================== */
.wisdom-widget {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 999;
    font-family: 'DM Sans', sans-serif;
}

.wisdom-toggle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1px solid var(--border);
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.wisdom-toggle:hover {
    border-color: var(--accent);
    transform: scale(1.05);
}

.wisdom-icon {
    display: block;
}

.wisdom-close {
    display: none;
    font-size: 20px;
    color: var(--text-muted);
}

.wisdom-widget.open .wisdom-icon {
    display: none;
}

.wisdom-widget.open .wisdom-close {
    display: block;
}

.wisdom-card {
    position: absolute;
    bottom: 56px;
    left: 0;
    width: 280px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px) scale(0.96);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.wisdom-widget.open .wisdom-card {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.wisdom-card:hover {
    border-color: var(--accent);
}

.wisdom-image {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: var(--radius-md);
    margin-bottom: 12px;
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.wisdom-card:hover .wisdom-image {
    opacity: 1;
}

.wisdom-text {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    font-style: italic;
    margin-bottom: 8px;
    transition: opacity 0.3s ease;
}

.wisdom-hint {
    font-size: 11px;
    color: var(--text-muted);
    display: block;
}

.multimodal-badge {
    position: relative;
    display: block;
    width: fit-content;
    margin: 0 auto 8px auto;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 10px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
    cursor: help;
    transition: all 0.2s ease;
}

.multimodal-badge:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.multimodal-tooltip {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    width: 220px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 12px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    z-index: 10;
    text-align: left;
}

.multimodal-badge:hover .multimodal-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.multimodal-tooltip h4 {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.multimodal-tooltip p {
    font-size: 11px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 6px;
    font-style: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
}

.multimodal-tooltip p:last-child {
    margin-bottom: 0;
}

.multimodal-tooltip strong {
    color: var(--accent);
}
