/* ========================================
   PORTFOLIO RAPHAEL - STYLES
   ======================================== */

/* VARIABLES CSS */
:root {
    /* Light Theme Colors */
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-hero: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --text-primary: #2c3e50;
    --text-secondary: #666666;
    --text-light: #ffffff;
    --accent-color: #3498db;
    --accent-hover: #2980b9;
    --shadow-light: rgba(0, 0, 0, 0.1);
    --shadow-medium: rgba(0, 0, 0, 0.15);
    --shadow-dark: rgba(0, 0, 0, 0.2);
    --border-color: #e9ecef;
    --card-bg: #ffffff;
    --navbar-bg: rgba(255, 255, 255, 0.95);
    --footer-bg: #2c3e50;
    --footer-text: #000000;

    --background: #f9f9f9;
    --text-primary: #333333;
    --text-secondary: #555555;
    --primary: #0078d7;
    --secondary: #00bcd4;
    --accent: #ff5722;
    --navbar-bg: rgba(255, 255, 255, 0.95);
    --footer-bg: #e0e0e0;
    --shadow-light: rgba(0, 0, 0, 0.1);
}

/* Dark Theme Colors */
[data-theme="dark"] {
    --bg-primary: #1a202c;
    --bg-secondary: #2d3748;
    --bg-hero: linear-gradient(135deg, #1a202c 0%, #2d3748 100%);
    --text-primary: #f7fafc;
    --text-secondary: #a0aec0;
    --text-light: #ffffff;
    --accent-color: #4299e1;
    --accent-hover: #3182ce;
    --shadow-light: rgba(0, 0, 0, 0.3);
    --shadow-medium: rgba(0, 0, 0, 0.4);
    --shadow-dark: rgba(0, 0, 0, 0.5);
    --border-color: #4a5568;
    --card-bg: #2d3748;
    --navbar-bg: rgba(26, 32, 44, 0.95);
    --footer-bg: #1a202c;
    --footer-text: #f7fafc;

    --background: #121212;
    --text-primary: #e0e0e0;
    --text-secondary: #b0b0b0;
    --primary: #bb86fc;
    --secondary: #03dac6;
    --accent: #cf6679;
    --navbar-bg: rgba(18, 18, 18, 0.95);
    --footer-bg: #1f1f1f;
    --shadow-light: rgba(255, 255, 255, 0.1);
}

/* RESET & BASE */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* THEME TOGGLE BUTTON */
.theme-toggle {
    position: fixed;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    z-index: 1001;
    background: var(--accent-color);
    color: var(--text-light);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px var(--shadow-medium);
}

.theme-toggle:hover {
    background: var(--accent-hover);
    transform: translateY(-50%) scale(1.1);
}

/* NAVBAR */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--navbar-bg) !important;
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    z-index: 1000;
    box-shadow: 0 2px 20px var(--shadow-light);
    transition: transform 0.3s ease, background-color 0.3s ease;
    will-change: transform;
}

.nav-container {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.logo {
    margin-right: auto;
    font-size: 1.5rem;
    font-weight: bold;
    text-transform: uppercase;
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
    z-index: 1001;
}

.logo img {
    padding-left: 2rem;
    transition: opacity 0.3s ease;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin: 0;
    padding: 0 2rem 0 0;
}

.nav-menu li {
    margin: 0;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    padding: 0.5rem 0;
    display: block;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--accent-color);
}

.nav-menu a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

/* MOBILE MENU */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.mobile-menu-toggle:hover {
    color: var(--accent-color);
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: block;
    }
    
    .nav-menu {
        position: fixed;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--navbar-bg);
        backdrop-filter: blur(10px);
        flex-direction: column;
        padding: 2rem;
        gap: 1rem;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        box-shadow: 0 10px 30px var(--shadow-medium);
    }
    
    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .nav-menu li {
        text-align: center;
    }
    
    .nav-menu a {
        font-size: 1.2rem;
        padding: 1rem;
    }
    .hero-container {
        padding-top: 35px !important;
    }
}

/* HERO SECTION */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    background: var(--bg-hero);
    color: var(--text-light);
    padding-top: 80px;
    position: relative;
    overflow: hidden;
}

/* PARTICLES JS */
#particles-js {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 1;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, var(--accent-color), #9b59b6);
    opacity: 0.1;
    z-index: 1;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    padding: 0 2rem;
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    opacity: 0;
    animation: slideInLeft 1s ease 0.2s forwards;
}

.hero-content h2 {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 2rem;
    opacity: 0;
    animation: slideInLeft 1s ease 0.4s forwards;
}

.hero-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0;
    animation: slideInLeft 1s ease 0.6s forwards;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    opacity: 0;
    animation: slideInLeft 1s ease 0.8s forwards;
}

.btn {
    padding: 12px 30px;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-color);
    color: var(--text-light);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px var(--shadow-medium);
}

.btn-outline {
    background: transparent;
    color: var(--text-light);
    border: 2px solid var(--text-light);
}

.btn-outline:hover {
    background: var(--text-light);
    color: var(--accent-color);
}

/* FOTO PROFILE */
.hero-image {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    animation: slideInRight 1s ease 0.5s forwards;
    margin-top: 3rem;
    margin-bottom: 1rem;
}

.profile-img {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    border: 5px solid rgba(255,255,255,0.3);
    object-fit: cover;
    box-shadow: 0 20px 40px var(--shadow-dark);
    transition: all 0.3s ease;
    position: relative;
}

.profile-img:hover {
    transform: scale(1.05);
    box-shadow: 0 25px 50px var(--shadow-dark);
}

/* Fallback caso a imagem não carregue */
.profile-img[src="imgs/profile.jpg"] {
    background: linear-gradient(135deg, var(--accent-color), #9b59b6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    font-size: 4rem;
    font-weight: bold;
}

.profile-img[src="imgs/profile.jpg"]::before {
    content: "📸";
}

/* SECTIONS */
.section {
    padding: 3rem 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: var(--text-primary);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 4px;
    background: var(--accent-color);
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

/* SOBRE MIM */
.about-content {
    display: block;
    max-width: 900px;
    margin: 0 auto;
}

.about-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-secondary);
    text-align: justify;
    margin-bottom: 2rem;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.stat-item {
    text-align: center;
    padding: 1.5rem;
    background: var(--card-bg);
    border-radius: 10px;
    box-shadow: 0 5px 15px var(--shadow-light);
    transition: transform 0.3s ease;
}

.stat-item:hover {
    transform: translateY(-5px);
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-color);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-top: 0.5rem;
}

/* HABILIDADES */
.skills {
    background: var(--bg-secondary);
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.skill-item {
    text-align: center;
    padding: 2rem 1rem;
    background: var(--card-bg);
    border-radius: 15px;
    box-shadow: 0 10px 30px var(--shadow-light);
    transition: all 0.3s ease;
    cursor: pointer;
}

.skill-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px var(--shadow-medium);
}

.skill-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--accent-color);
    transition: transform 0.3s ease;
}

.skill-item:hover .skill-icon {
    transform: scale(1.1);
}

.skill-name {
    font-weight: 600;
    color: var(--text-primary);
}

/* Destaque para habilidades principais */
.skill-highlight {
    background: linear-gradient(135deg, var(--accent-color), #9b59b6);
    color: var(--text-light);
    transform: scale(1.05);
}

.skill-highlight .skill-icon {
    color: var(--text-light);
    font-size: 3.5rem;
}

.skill-highlight .skill-name {
    color: var(--text-light);
    font-weight: 700;
}

.skill-highlight:hover {
    transform: scale(1.1) translateY(-10px);
    box-shadow: 0 25px 50px var(--shadow-medium);
}

/* PROJETOS */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--card-bg);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px var(--shadow-light);
    transition: all 0.3s ease;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px var(--shadow-medium);
}

.project-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(45deg, var(#858a8a), #180c1d);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    font-size: 3rem;
    transition: all 0.3s ease;
}

.project-card:hover .project-image {
    transform: scale(1.05);
}

.project-content {
    padding: 1.5rem;
}

.project-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.project-description {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.tech-tag {
    background: var(--bg-secondary);
    color: var(--accent-color);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid var(--accent-color);
}

.project-links {
    display: flex;
    gap: 1rem;
}

.project-link {
    text-decoration: none;
    color: var(--accent-color);
    font-weight: 500;
    transition: color 0.3s ease;
}

.project-link:hover {
    color: var(--accent-hover);
}

/* Projeto futuro */
.project-future {
    border: 2px dashed var(--accent-color);
    background: linear-gradient(135deg, var(--card-bg), var(--bg-secondary));
}

.badge-future {
    background: var(--accent-color);
    color: var(--text-light);
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    margin-left: 0.5rem;
}

/* CONTATO */
.contact {
    background: var(--bg-secondary);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: var(--accent-color);
    color: var(--text-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.contact-item:hover .contact-icon {
    background: var(--accent-hover);
    transform: scale(1.1);
}

.contact-item h4 {
    color: var(--text-primary);
    margin-bottom: 0.2rem;
}

.contact-item p {
    color: var(--text-secondary);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.social-link {
    width: 50px;
    height: 50px;
    background: var(--accent-color);
    color: var(--text-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.social-link:hover {
    background: var(--accent-hover);
    transform: translateY(-3px);
}

.contact-form {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px var(--shadow-light);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    background: var(--bg-primary);
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

/* FOOTER */
.footer {
    background: var(--footer-bg) !important;
    color: var(--footer-text) !important;
    text-align: center;
    padding: 2rem 0;
    transition: all 0.3s ease;
}

/* Estilo para os ícones das redes sociais na seção 'Início' */
.hero-socials {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1rem;
}

.hero-socials .social-link {
    font-size: 1.5rem;
    color: var(--text-primary);
    transition: color 0.3s ease;
}

.hero-socials .social-link:hover {
    color: var(--primary);
}

/* ANIMATIONS */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* RESPONSIVIDADE */
@media (max-width: 768px) {
    .theme-toggle {
        right: 10px;
        width: 45px;
        height: 45px;
        font-size: 1rem;
    }

    .hero-image {
        margin-top: 1.5rem;
        margin-bottom: 0.5rem;
    }

    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .profile-img {
        width: 250px;
        height: 250px;
    }

    .about-content {
        max-width: 100%;
        padding: 0 1rem;
    }
    
    .about-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .contact-content {
        grid-template-columns: 1fr;
    }

    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .section {
        padding: 3rem 0;
    }

    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 0 1rem;
    }

    .container {
        padding: 0 1rem;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .hero-content h2 {
        font-size: 1.2rem;
    }

    .profile-img {
        width: 200px;
        height: 200px;
    }
    
    .hero-image {
        margin-top: 1rem;
        margin-bottom: 0;
    }
    
    .about-stats {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .stat-item {
        padding: 1rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
}

/* SMOOTH SCROLLING ENHANCEMENT */
html {
    scroll-behavior: smooth;
}

/* LOADING ANIMATION */
.loading {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

/* SUCCESS STATES */
.success {
    color: #27ae60;
}

.error {
    color: #e74c3c;
}
