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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: #24292f;
    background-color: #ffffff;
}

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

/* Navigation */
.navbar {
    background-color: #24292f;
    padding: 1rem 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

.nav-logo h2 {
    color: #ffffff;
    font-size: 1.5rem;
    font-weight: 600;
}

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

.nav-link {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #58a6ff;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: #ffffff;
    margin: 3px 0;
    transition: 0.3s;
}

/* Main Content */
main {
    margin-top: 80px;
}

/* Home Section */
.home {
    background: linear-gradient(135deg, #f6f8fa 0%, #ffffff 100%);
    padding: 4rem 0;
    /* min-height: 80vh; */ /* Remova ou comente esta linha */
    display: flex;
    align-items: center;
}

.home-content {
    text-align: center;
}

.profile-avatar {
    margin-bottom: 2rem;
}

.profile-image {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #58a6ff;
    box-shadow: 0 8px 32px rgba(88, 166, 255, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.profile-image:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 40px rgba(88, 166, 255, 0.4);
}

.avatar-placeholder {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: linear-gradient(135deg, #58a6ff, #1f6feb);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    box-shadow: 0 8px 32px rgba(88, 166, 255, 0.3);
}

.avatar-placeholder i {
    font-size: 4rem;
    color: white;
}

.home h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #24292f;
}

.subtitle {
    font-size: 1.5rem;
    color: #656d76;
    margin-bottom: 1rem;
}

.location {
    color: #656d76;
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.location i {
    margin-right: 0.5rem;
    color: #58a6ff;
}

.stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: #58a6ff;
}

.stat-label {
    font-size: 0.9rem;
    color: #656d76;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tech-stack {
    margin-top: 3rem;
    width: 100%;
}

.tech-stack h3 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-align: center;
    color: var(--text-primary);
}

/* ============================
   GRID DOS ÍCONES
============================ */
.tech-icons {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 1.5rem;
    padding: 0 1rem;
}

/* ============================
   TITULOS DAS CATEGORIAS
============================ */
.category-title {
    grid-column: 1 / -1;
    margin: 2.5rem 0 0.8rem;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-secondary);
    position: relative;
    padding-left: 0.5rem;
}

.category-title::after {
    content: "";
    display: block;
    height: 2px;
    width: 100%;
    background: linear-gradient(to right, var(--accent-color), transparent);
    margin-top: 4px;
    border-radius: 4px;
}

/* ============================
   CARDS DOS ÍCONES
============================ */
.tech-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    padding: 1.1rem 0.7rem;
    border-radius: 14px;
    background: var(--card-bg);
    box-shadow: var(--shadow-soft);
    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        background 0.25s ease;
    cursor: pointer;
}

/* ANIMAÇÃO NO HOVER */
.tech-item:hover {
    transform: translateY(-6px) scale(1.04);
    box-shadow: var(--shadow-strong);
}

/* ICONES */
.tech-item i {
    font-size: 2.6rem;
}

/* LABEL */
.tech-item span {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Variáveis principais */
:root {
    --text-primary: #24292f;
    --text-secondary: #4d4d4d;
    --card-bg: #ffffff;
    --accent-color: #3b82f6;
    /* azul suave */
    --shadow-soft: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-strong: 0 8px 25px rgba(0, 0, 0, 0.15);
}


/* ============================
   MOBILE / RESPONSIVIDADE EXTRA
============================ */
@media (max-width: 480px) {
    .tech-icons {
        grid-template-columns: repeat(auto-fill, minmax(95px, 1fr));
        gap: 1.2rem;
    }

    .tech-item i {
        font-size: 2.2rem;
    }
}

/* Section Styles */
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 3rem;
    color: #24292f;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, #58a6ff, #1f6feb);
    border-radius: 2px;
}

/* About Section */
.about {
    padding: 5rem 0;
    background-color: #f6f8fa;
}

.about-text {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #24292f;
}

.about-text p {
    margin-bottom: 1.5rem;
}

/* Projects Section */
.projects {
    padding: 5rem 0;
    background-color: #ffffff;
}

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

.project-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #d1d9e0;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
}

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

.project-header h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: #24292f;
    flex: 1;
}

.project-date {
    background: #58a6ff;
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.project-description {
    margin-bottom: 1.5rem;
}

.project-description p {
    color: #656d76;
    line-height: 1.6;
}

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

.tech-tag {
    background: #f1f8ff;
    color: #0969da;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid #c7e1ff;
}

.project-impact {
    margin-bottom: 1rem;
    padding: 0.8rem;
    background: #dcfce7;
    border-radius: 8px;
    border-left: 4px solid #16a34a;
}

.project-impact strong {
    color: #16a34a;
    font-weight: 600;
}

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

.project-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #58a6ff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.project-link:hover {
    color: #1f6feb;
}

/* Resume Section */
.resume {
    padding: 5rem 0;
    background-color: #f6f8fa;
}

.resume-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.resume-content p {
    font-size: 1.1rem;
    color: #656d76;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.download-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    background: linear-gradient(135deg, #58a6ff, #1f6feb);
    color: white;
    padding: 1rem 2rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 16px rgba(88, 166, 255, 0.3);
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(88, 166, 255, 0.4);
}

.download-btn i {
    font-size: 1.2rem;
}

/* Contact Section */
.contact {
    padding: 5rem 0;
    background-color: #ffffff;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: #f6f8fa;
    border-radius: 12px;
    transition: transform 0.3s ease;
}

.contact-item:hover {
    transform: translateX(5px);
}

.contact-item i {
    font-size: 1.5rem;
    color: #58a6ff;
    width: 30px;
    text-align: center;
}

.contact-details h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #24292f;
    margin-bottom: 0.3rem;
}

.contact-details p {
    color: #656d76;
    font-size: 1rem;
}

.social-links h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #24292f;
    margin-bottom: 1.5rem;
}

.social-icons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.social-link,
.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 500;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.social-link.linkedin {
    background: #f1f8ff;
    color: #0077b5;
    border: 1px solid #c7e1ff;
}

.social-link.github {
    background: #f6f8fa;
    color: #24292f;
    border: 1px solid #d1d9e0;
}

/* WakaTime Social Link */
.social-link.wakatime {
    background: #f7f8fa;
    color: #3a3a3a;
    border: 1px solid #d1d9e0;
}

.social-link.instagram {
    background: #fef7ff;
    color: #e1306c;
    border: 1px solid #f7c2d8;
}

.social-link:hover,
.contact-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.social-link i {
    font-size: 1.5rem;
}

/* Footer */
.footer {
    background-color: #24292f;
    color: #ffffff;
    text-align: center;
    padding: 2rem 0;
}

.footer p {
    color: #8b949e;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 80px;
        flex-direction: column;
        background-color: #24292f;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        margin: 1rem 0;
    }

    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .home h1 {
        font-size: 2.5rem;
    }

    .subtitle {
        font-size: 1.3rem;
    }

    .stats {
        gap: 2rem;
    }

    .stat-number {
        font-size: 2rem;
    }

    .tech-icons {
        gap: 1rem;
    }

    .tech-item {
        padding: 0.8rem;
    }

    .tech-item i {
        font-size: 2rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .projects-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .social-icons {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.8rem;
    }

    .social-link {
        flex: 1;
        min-width: 120px;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .home {
        padding: 3rem 0;
    }

    .home h1 {
        font-size: 2rem;
    }

    .subtitle {
        font-size: 1.1rem;
    }

    .stats {
        flex-direction: column;
        gap: 1.5rem;
    }

    .tech-icons {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.8rem;
    }

    .tech-item {
        padding: 0.6rem;
    }

    .tech-item i {
        font-size: 1.8rem;
    }

    .tech-item span {
        font-size: 0.8rem;
    }

    .project-card {
        padding: 1.5rem;
    }

    .project-header {
        flex-direction: column;
        gap: 1rem;
    }

    .contact-item {
        padding: 1rem;
    }

    .social-link {
        padding: 0.8rem 1rem;
        font-size: 0.9rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #58a6ff;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #1f6feb;
}



/* WhatsApp Link */
.whatsapp-link {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

.whatsapp-link:hover {
    color: #25d366;
}

/* AI Chat Section */
.ai-chat-section {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 3rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    border: 1px solid #d1d9e0;
}

.ai-chat-section h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #24292f;
    margin-bottom: 0.5rem;
}

.ai-chat-section p {
    color: #656d76;
    margin-bottom: 1.5rem;
}

.chat-container {
    border: 1px solid #d1d9e0;
    border-radius: 12px;
    overflow: hidden;
    background: #f6f8fa;
}

.chat-messages {
    height: 300px;
    overflow-y: auto;
    padding: 1rem;
    background: white;
}

.message {
    margin-bottom: 1rem;
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
}

.bot-message {
    justify-content: flex-start;
}

.user-message {
    justify-content: flex-end;
}

.message-content {
    max-width: 70%;
    padding: 0.8rem 1rem;
    border-radius: 12px;
    font-size: 0.9rem;
    line-height: 1.4;
}

.bot-message .message-content {
    background: #f1f8ff;
    color: #24292f;
    border: 1px solid #c7e1ff;
}

.user-message .message-content {
    background: #58a6ff;
    color: white;
}

.chat-input-container {
    display: flex;
    padding: 1rem;
    background: #f6f8fa;
    border-top: 1px solid #d1d9e0;
}

#chatInput {
    flex: 1;
    padding: 0.8rem 1rem;
    border: 1px solid #d1d9e0;
    border-radius: 8px;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.3s ease;
}

#chatInput:focus {
    border-color: #58a6ff;
}

#sendMessage {
    background: #58a6ff;
    color: white;
    border: none;
    padding: 0.8rem 1rem;
    margin-left: 0.8rem;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#sendMessage:hover {
    background: #1f6feb;
}

#sendMessage:disabled {
    background: #8b949e;
    cursor: not-allowed;
}

/* Contact Form Section */
.contact-form-section {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 3rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    border: 1px solid #d1d9e0;
}

.contact-form-section h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #24292f;
    margin-bottom: 1.5rem;
}

.contact-form {
    display: grid;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-weight: 500;
    color: #24292f;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    padding: 0.8rem 1rem;
    border: 1px solid #d1d9e0;
    border-radius: 8px;
    font-size: 0.9rem;
    font-family: inherit;
    outline: none;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: #58a6ff;
    box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.submit-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    background: linear-gradient(135deg, #58a6ff, #1f6feb);
    color: white;
    padding: 1rem 2rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 16px rgba(88, 166, 255, 0.3);
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(88, 166, 255, 0.4);
}

.submit-btn:disabled {
    background: #8b949e;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.submit-btn i {
    font-size: 1.1rem;
}

/* Loading states */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

.typing-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #656d76;
    font-style: italic;
    font-size: 0.8rem;
}

.typing-dots {
    display: flex;
    gap: 2px;
}

.typing-dots span {
    width: 4px;
    height: 4px;
    background: #656d76;
    border-radius: 50%;
    animation: typing 1.4s infinite ease-in-out;
}

.typing-dots span:nth-child(1) {
    animation-delay: -0.32s;
}

.typing-dots span:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes typing {

    0%,
    80%,
    100% {
        transform: scale(0);
        opacity: 0.5;
    }

    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Success/Error messages */
.form-message {
    padding: 1rem;
    border-radius: 8px;
    margin-top: 1rem;
    font-weight: 500;
}

.form-message.success {
    background: #dcfce7;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

.form-message.error {
    background: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

/* Responsive adjustments */
@media (max-width: 768px) {

    .ai-chat-section,
    .contact-form-section {
        padding: 1.5rem;
        margin-bottom: 2rem;
    }

    .chat-messages {
        height: 250px;
    }

    .message-content {
        max-width: 85%;
    }

    .chat-input-container {
        flex-direction: column;
        gap: 0.8rem;
    }

    #sendMessage {
        margin-left: 0;
        align-self: flex-end;
        width: auto;
    }
}

@media (max-width: 480px) {

    .ai-chat-section h3,
    .contact-form-section h3 {
        font-size: 1.3rem;
    }

    .chat-messages {
        height: 200px;
        padding: 0.8rem;
    }

    .message-content {
        max-width: 90%;
        padding: 0.6rem 0.8rem;
        font-size: 0.85rem;
    }

    .form-group input,
    .form-group textarea {
        padding: 0.7rem 0.8rem;
        font-size: 0.85rem;
    }

    .submit-btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }
}