/* ================= VARIABLES DE COLOR ================= */
:root {
    --bg-black: #0d0d0d;
    --bg-card: #1a1a1a;
    --text-light: #f5f5f5;
    --text-muted: #a3a3a3;
    --red-light: #ff4d4d;
    --red-primary: #cc0000;
    --red-dark: #8b0000;
    --red-glow: rgba(204, 0, 0, 0.4);
}

/* ================= RESET Y BASE ================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-black);
    color: var(--text-light);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: var(--red-light);
    transition: color 0.3s ease;
}

a:hover {
    color: var(--red-primary);
}

h1, h2, h3 {
    color: var(--text-light);
}

/* ================= NAVEGACIÓN ================= */
header {
    background-color: rgba(13, 13, 13, 0.95);
    padding: 1rem 5%;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 2px solid var(--red-dark);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--red-primary);
}

.logo span {
    color: var(--text-light);
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

nav ul li a {
    color: var(--text-light);
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

nav ul li a:hover {
    color: var(--red-light);
}

/* ================= SECCIÓN HERO ================= */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5%;
    margin-top: 60px;
    gap: 4rem;
    flex-wrap: wrap;
}

.hero-content {
    flex: 1;
    min-width: 300px;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 0.5rem;
}

.hero-content h1 span {
    color: var(--red-primary);
}

.hero-content h2 {
    font-size: 1.5rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    font-weight: 400;
}

.hero-content p {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    max-width: 600px;
}

.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    background-color: var(--red-primary);
    color: white;
    border-radius: 5px;
    font-weight: bold;
    text-transform: uppercase;
    transition: all 0.3s ease;
    border: 1px solid var(--red-primary);
    box-shadow: 0 0 15px var(--red-glow);
}

.btn:hover {
    background-color: transparent;
    color: var(--red-primary);
    box-shadow: 0 0 25px var(--red-glow);
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    min-width: 300px;
}

/* Contenedor para la foto */
.photo-placeholder {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background-color: var(--bg-card);
    border: 4px solid var(--red-primary);
    box-shadow: 0 0 30px var(--red-glow);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.photo-placeholder span {
    color: var(--text-muted);
    font-size: 1.2rem;
}

.photo-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 1; /* PON ESTO A 1 CUANDO SUBAS TU FOTO */
}

/* ================= SECCIONES GENERALES ================= */
section {
    padding: 5rem 5%;
}

.bg-alt {
    background-color: var(--bg-card);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background-color: var(--red-primary);
    margin: 10px auto 0;
    border-radius: 2px;
}

/* ================= HABILIDADES ================= */
.skills-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    max-width: 800px;
    margin: 0 auto;
}

.skill-tag {
    background-color: var(--bg-card);
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    border: 1px solid var(--red-dark);
    font-weight: bold;
    transition: all 0.3s;
}

.skill-tag:hover {
    background-color: var(--red-primary);
    border-color: var(--red-primary);
    transform: translateY(-3px);
}

/* ================= PROYECTOS ================= */
.projects-grid {
    display: flex;
    justify-content: center; /* Centra el proyecto en medio de la pantalla */
    gap: 2rem;
}

.project-card {
    background-color: var(--bg-black);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #333;
    transition: transform 0.3s ease, border-color 0.3s ease;
    width: 100%;
    max-width: 450px;
}

.project-card:hover {
    transform: translateY(-10px);
    border-color: var(--red-primary);
    box-shadow: 0 10px 20px rgba(0,0,0,0.5);
}

.project-img-placeholder {
    width: 100%;
    height: 200px;
    background-color: #222;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 2px solid var(--red-dark);
    color: var(--text-muted);
}

.project-img-placeholder img {
    width: 50%;
    height: 100%;
    object-fit: cover;
}

.project-info {
    padding: 1.5rem;
}

.project-info h3 {
    color: var(--red-light);
    margin-bottom: 0.5rem;
}

.project-info p {
    color: var(--text-muted);
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.project-links a {
    display: inline-block;
    margin-right: 1rem;
    font-size: 0.9rem;
    border-bottom: 1px solid var(--red-primary);
    padding-bottom: 2px;
}

/* ================= CONTACTO Y FOOTER ================= */
footer {
    background-color: var(--bg-card);
    text-align: center;
    padding: 3rem 5%;
    border-top: 2px solid var(--red-dark);
}

.contact-info {
    margin-bottom: 2rem;
}

.contact-info p {
    margin: 0.5rem 0;
    font-size: 1.1rem;
}

.contact-info a {
    color: var(--red-light);
}

.social-links {
    margin-bottom: 2rem;
}

.social-links a {
    display: inline-block;
    margin: 0 10px;
    padding: 10px 20px;
    border: 1px solid var(--text-muted);
    border-radius: 5px;
    color: var(--text-light);
}

.social-links a:hover {
    background-color: var(--red-primary);
    border-color: var(--red-primary);
}

.copyright {
    color: var(--text-muted); 
    font-size: 0.9rem; 
    margin-top: 3rem;
}

/* ================= MEDIA QUERIES ================= */
@media (max-width: 768px) {
    .hero {
        flex-direction: column-reverse;
        text-align: center;
        padding-top: 5rem;
    }
    .hero-content p {
        margin: 0 auto 2rem;
    }
    nav ul {
        display: none; 
    }
}

/* ================= CURRÍCULUM ================= */
.cv-container {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.cv-container p {
    color: var(--text-muted);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.cv-buttons {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.btn-outline {
    background-color: transparent;
    color: var(--red-light);
    border: 1px solid var(--red-light);
    box-shadow: none;
}

.btn-outline:hover {
    background-color: var(--red-light);
    color: var(--bg-black);
    box-shadow: 0 0 15px var(--red-glow);
}