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

:root {
    --bg-primary: #F2F2F2;
    --bg-secondary: #D8D8D6;
    --text-heading: #595858;
    --text-body: #6F7675;
    --action-color: #FF7E1A;
    --white: #FFFFFF;
    --dark-section-bg: #595858;
    --dark-section-text: #F2F2F2;
    
    --radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Breakpoints */
    --tablet: 768px;
    --laptop: 1024px;
    --desktop: 1200px;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-body);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    color: var(--text-heading);
    font-weight: 700;
}

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

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

section {
    padding: 6rem 0;
}

/* Typography Utilities */
.text-uppercase { text-transform: uppercase; letter-spacing: 0.1em; }
.font-bold { font-weight: 800; }
.bg-white { background-color: var(--white) !important; }
.bg-primary { background-color: var(--bg-primary) !important; }
.bg-secondary { background-color: var(--bg-secondary) !important; }

/* Navigation Refinement */
.nav-logo {
    color: var(--text-heading);
    font-size: 1.2rem;
    font-weight: 800;
    text-transform: uppercase;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-heading);
    cursor: pointer;
}

.nav-cta {
    padding: 0.5rem 1.5rem !important;
    color: white !important;
}

/* Hero Refinement */
.hero-container {
    max-width: 800px;
    padding: 0 2rem;
}

.hero-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    justify-content: center;
    text-align: left;
}

.hero-image {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--action-color);
    flex-shrink: 0;
}

.hero-title-area {
    flex: 1;
    min-width: 250px;
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem) !important;
    margin: 0 !important;
}

.hero-subtitle {
    font-size: 1.1rem !important;
    margin-top: 0.5rem !important;
    margin-bottom: 0 !important;
    line-height: 1.4;
}

.hero-bio {
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: var(--radius);
    margin-bottom: 2rem;
    text-align: left;
}

.bio-label {
    font-size: 0.8rem;
    color: var(--action-color);
    margin-bottom: 1rem;
}

.bio-text {
    font-size: 1rem;
    color: var(--text-heading);
    line-height: 1.7;
    margin: 0 !important;
}

.hero-contact-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
}

.hero-social-link {
    font-size: 1.5rem;
    color: var(--text-heading);
}

.resume-link {
    color: var(--action-color) !important;
}

.hero-email {
    font-size: 0.9rem;
    color: var(--text-body);
}

/* Section Common */
.edu-card {
    background-color: var(--bg-primary) !important;
    border: 1px solid var(--bg-secondary) !important;
}

.edu-date {
    color: var(--action-color);
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
}

.edu-degree {
    margin-bottom: 0.25rem;
    font-size: 1.2rem;
}

.edu-institution {
    font-weight: 600;
    margin-bottom: 1rem;
}

.edu-desc {
    font-size: 0.9rem;
}

.quote-card {
    background-color: var(--bg-primary) !important;
    border: 1px dashed var(--action-color) !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    padding: 2.5rem !important;
}

.quote-icon {
    color: var(--action-color);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.quote-text {
    font-size: 1.1rem;
    font-style: italic;
    color: var(--text-heading);
    font-weight: 500;
    line-height: 1.6;
}

.quote-author {
    margin-top: 1rem;
    font-size: 0.8rem;
    color: var(--action-color);
    font-weight: 700;
}

.skill-section-title {
    color: var(--white);
    margin-bottom: 4rem;
}

.skill-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)) !important;
}

.exp-card {
    background-color: var(--white) !important;
    border: 1px solid var(--bg-secondary) !important;
}

.exp-list {
    padding-left: 1.2rem;
    font-size: 0.9rem;
}

.github-card-link {
    display: flex !important;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border: 2px dashed var(--action-color) !important;
    background: transparent !important;
    text-decoration: none;
    min-height: 15rem;
    transition: var(--transition);
}

.github-icon {
    font-size: 3rem;
    color: var(--action-color);
    margin-bottom: 1rem;
}

.github-title {
    color: var(--text-heading);
}

.github-desc {
    font-size: 0.8rem;
    text-align: center;
    color: var(--text-body);
}

.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.cert-card {
    padding: 1.5rem;
    background: var(--white);
    border-radius: var(--radius);
    border: 1px solid var(--bg-secondary);
}

.cert-org {
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
    color: var(--action-color);
}

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

.additional-card {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius);
}

.strength-list {
    font-size: 0.9rem;
    columns: 2;
    padding-left: 1.2rem;
}

.interest-text {
    font-size: 0.9rem;
    line-height: 1.8;
}

.footer-links {
    margin: 2rem 0;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
}

.footer-email-link {
    font-weight: 800;
    color: var(--text-heading);
    font-size: clamp(1.1rem, 4vw, 2.2rem);
    display: inline-flex;
    align-items: center;
    transition: var(--transition);
}

.footer-icon {
    font-size: 1.5rem;
    margin-right: 1.5rem;
}

.chat-title {
    font-size: 0.8rem;
}

.chat-close-btn {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
}

.chat-send-btn {
    background: var(--action-color);
    color: white;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: var(--radius);
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 126, 26, 0.3);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(242, 242, 242, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 1px solid var(--bg-secondary);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-heading);
}

.nav-links a:hover {
    color: var(--action-color);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--bg-primary);
    padding-top: 5rem;
    text-align: center;
}

.hero-grid {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 800px;
    gap: 2rem;
}

.hero-content h1 {
    font-size: clamp(2.5rem, 8vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    max-width: 600px;
}

/* Project Grid */
.projects {
    background-color: var(--white);
}

.section-title {
    font-size: clamp(2rem, 5vw, 2.8rem);
    margin-bottom: 3rem;
    text-align: center;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

.project-card {
    background-color: var(--bg-secondary);
    border-radius: var(--radius);
    padding: 2rem;
    transition: var(--transition);
    border: 2px solid transparent;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    border-color: var(--action-color);
    background-color: var(--white);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.project-thumbnail {
    width: 100%;
    aspect-ratio: 16/9;
    background: #ccc;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    filter: grayscale(100%);
    transition: var(--transition);
    background-size: cover;
    background-position: center;
}

.project-card:hover .project-thumbnail {
    filter: grayscale(0%);
}

.project-card h3 {
    margin-bottom: 0.5rem;
}

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

.tag {
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 600;
    color: var(--action-color);
    background: rgba(255, 126, 26, 0.1);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
}

.project-link {
    font-weight: 600;
    margin-top: auto;
    color: var(--text-heading);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.project-card:hover .project-link {
    color: var(--action-color);
}

.highlight-data {
    color: var(--action-color);
    font-weight: 700;
}

/* About / Skills Section (Dark) */
.about {
    background-color: var(--dark-section-bg);
    color: var(--dark-section-text);
}

.about h2 {
    color: var(--dark-section-text);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
}

.skill-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.skill-item {
    margin-bottom: 1.5rem;
}

.skill-item h4 {
    color: var(--dark-section-text);
    margin-bottom: 0.8rem;
    font-size: 0.9rem;
    text-transform: uppercase;
}

.skill-bar {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

.skill-progress {
    height: 100%;
    background: var(--action-color);
    border-radius: 2px;
}

/* Contact Footer */
.footer {
    background-color: var(--bg-secondary);
    padding: 6rem 0;
    text-align: center;
}

.footer-email {
    font-weight: 800;
    color: var(--text-heading);
    display: inline-flex;
    align-items: center;
    transition: var(--transition);
}

.footer-email:hover {
    color: var(--action-color);
    transform: translateY(-2px);
}

/* AI Assistant Premium Visuals */
.ai-assistant {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.ai-bubble {
    width: 65px;
    height: 65px;
    background: var(--action-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 30px rgba(255, 126, 26, 0.4);
    color: var(--white);
    font-size: 1.8rem;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.ai-bubble::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--action-color);
    opacity: 0.5;
    z-index: -1;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.5; }
    100% { transform: scale(1.5); opacity: 0; }
}

.ai-bubble:hover {
    transform: scale(1.1);
}

.chat-window {
    width: 380px;
    max-height: 550px;
    background: var(--white);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(0,0,0,0.05);
    margin-bottom: 1.5rem;
    transform-origin: bottom right;
    animation: popIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popIn {
    from { opacity: 0; transform: scale(0.8) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

.chat-window.active {
    display: flex;
}

.chat-header {
    background: var(--dark-section-bg);
    color: var(--white);
    padding: 1.2rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-messages {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    max-height: 380px;
    background: #fdfdfd;
}

.message-node {
    display: flex;
    flex-direction: column;
    max-width: 85%;
    position: relative;
    animation: slideUp 0.3s ease-out;
}

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

.message {
    padding: 1rem 1.4rem;
    border-radius: 18px;
    font-size: 0.9rem;
    line-height: 1.5;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    position: relative;
}

.bot-node {
    align-self: flex-start;
}

.bot-node .message {
    background: var(--white);
    color: var(--text-heading);
    border: 1px solid var(--bg-secondary);
    border-bottom-left-radius: 4px;
}

.user-node {
    align-self: flex-end;
}

.user-node .message {
    background: var(--action-color);
    color: var(--white);
    border-bottom-right-radius: 4px;
}

.message-info {
    font-size: 0.7rem;
    margin-bottom: 0.3rem;
    opacity: 0.7;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
}

.bot-node .message-info {
    color: var(--text-body);
}

.user-node .message-info {
    align-self: flex-end;
    color: var(--action-color);
}

.chat-input-area {
    padding: 1.2rem;
    background: var(--white);
    border-top: 1px solid var(--bg-secondary);
    display: flex;
    gap: 0.8rem;
}

.chat-input-area input {
    flex: 1;
    border: 1px solid var(--bg-secondary);
    padding: 0.7rem 1.2rem;
    border-radius: 25px;
    outline: none;
}

.quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    padding: 0 1.5rem 1.2rem;
}

.quick-btn {
    background: var(--white);
    border: 1px solid rgba(255, 126, 26, 0.2);
    color: var(--action-color);
    padding: 0.45rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s;
}

.quick-btn:hover {
    background: var(--action-color);
    color: var(--white);
    transform: translateY(-2px);
}

/* Typing Indicator */
.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 0.5rem 1rem;
    align-self: flex-start;
    background: var(--white);
    border: 1px solid var(--bg-secondary);
    border-radius: 18px;
    border-bottom-left-radius: 4px;
    margin-bottom: 1rem;
}

.typing-dot {
    width: 6px;
    height: 6px;
    background: var(--text-body);
    border-radius: 50%;
    opacity: 0.4;
    animation: typingPulse 1.5s infinite ease-in-out;
}

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

@keyframes typingPulse {
    0%, 100% { transform: translateY(0); opacity: 0.4; }
    50% { transform: translateY(-4px); opacity: 0.9; }
}

/* GitHub Sync Status */
.sync-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.7rem;
    color: var(--text-muted);
    padding: 4px 12px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
}

.sync-dot {
    width: 6px;
    height: 6px;
    background: #238636; /* GitHub Green */
    border-radius: 50%;
    box-shadow: 0 0 5px #238636;
    animation: livePulse 2s infinite;
}

@keyframes livePulse {
    0% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(1.2); }
    100% { opacity: 1; transform: scale(1); }
}

.feedback-node {
    margin-top: 0.5rem;
    display: flex;
    gap: 8px;
}

.feedback-btn {
    padding: 4px 10px;
    font-size: 0.75rem;
    border: 1px solid var(--action-color);
    background: transparent;
    color: var(--action-color);
    border-radius: 12px;
    cursor: pointer;
    transition: 0.3s;
}

.feedback-btn:hover {
    background: var(--action-color);
    color: var(--white);
}

/* Responsive Refinements */
@media (max-width: 1024px) {
    .container { max-width: 950px; }
    .hero-container { max-width: 750px; }
}

@media (max-width: 900px) {
    section { padding: 4rem 0; }
    .about-content { grid-template-columns: 1fr; gap: 2rem; }
    .hero-header { gap: 1.5rem; }
}

@media (max-width: 768px) {
    .container { padding: 0 1.5rem; }
    .hero-header { flex-direction: column; text-align: center; }
    .hero-title-area { text-align: center; }
    .hero-image { width: 120px; height: 120px; }
    .hero-title { font-size: 2.8rem !important; }
    .strength-list { columns: 1; }
    .nav-links { gap: 1rem; }
}

@media (max-width: 992px) {
    .nav-toggle { display: block !important; }
    .nav-links { 
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--bg-primary);
        flex-direction: column;
        padding: 1.5rem;
        border-bottom: 1px solid var(--bg-secondary);
        box-shadow: 0 10px 20px rgba(0,0,0,0.05);
        gap: 1.5rem;
    }
    
    .nav-links.active {
        display: flex;
    }
}

@media (max-width: 600px) {
    
    .hero-title { font-size: 2.2rem !important; }
    .hero-subtitle { font-size: 1rem !important; }
    .hero-bio { padding: 1.5rem; }
    .section-title { font-size: 1.8rem; margin-bottom: 2rem; }
    .chat-window {
        width: calc(100vw - 2rem);
        right: 1rem;
        bottom: 5.5rem;
        height: 70vh;
    }
    .ai-bubble {
        width: 55px;
        height: 55px;
        font-size: 1.4rem;
    }
}

@media (max-width: 400px) {
    .hero-title { font-size: 1.8rem !important; }
    .hero-contact-links { gap: 1rem; }
    .hero-social-link { font-size: 1.2rem; }
    .hero-email { font-size: 0.8rem; }
}