/*
Theme Name: Canvas Visual
Author: Tu Nombre
Description: Un portafolio minimalista y animado para diseñadores visuales.
Version: 1.0
*/

:root {
    --bg-color: #0a0a0a;
    --text-color: #f3f3f3;
    --link-color: #ffffff;
    --accent-color: #ff3366; /* Rosa neón para acentos */
    --font-main: 'Helvetica Neue', sans-serif;
    --gap: 2rem;
}

* { box-sizing: border-box; margin: 0; padding: 0; cursor: none; /* Ocultamos cursor nativo */ }

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--link-color);
    text-decoration: none;
    transition: color 0.3s;
}

a:hover {
    color: var(--accent-color);
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    overflow-x: hidden;
    line-height: 1.6;
}

/* --- CURSOR PERSONALIZADO --- */
.cursor {
    width: 20px; height: 20px;
    border: 1px solid var(--text-color);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.1s;
    mix-blend-mode: difference;
}

/* --- HERO SECTION --- */
.hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 5%;
    position: relative;
}

.hero h1 {
    font-size: clamp(3rem, 10vw, 8rem);
    line-height: 0.9;
    text-transform: uppercase;
    font-weight: 800;
    opacity: 0; /* Para animación */
    transform: translateY(50px);
    animation: fadeUp 1s ease forwards 0.5s;
}

.hero span {
    color: transparent;
    -webkit-text-stroke: 1px var(--text-color);
    display: block;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    right: 2rem;
    animation: bounce 2s infinite;
}

/* --- GRID PORTAFOLIO --- */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: var(--gap);
    padding: 5%;
}

.project-card {
    position: relative;
    overflow: hidden;
    opacity: 0; /* Para Intersection Observer */
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.project-card.visible { opacity: 1; transform: translateY(0); }

.project-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    filter: grayscale(100%);
}

.project-card:hover img {
    transform: scale(1.1);
    filter: grayscale(0%);
}

.project-info {
    position: absolute;
    bottom: 0; left: 0;
    padding: 1.5rem;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    width: 100%;
    transform: translateY(100%);
    transition: transform 0.4s;
}

.project-card:hover .project-info { transform: translateY(0); }

/* --- ANIMACIONES --- */
@keyframes fadeUp {
    to { opacity: 1; transform: translateY(0); }
}
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
    40% {transform: translateY(-10px);}
    60% {transform: translateY(-5px);}
}

/* --- SITE HEADER & NAV --- */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 5%;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    background: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(10px);
}

.logo a {
    font-size: 1.5rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--link-color);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.main-navigation ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.main-navigation a {
    text-decoration: none;
    color: var(--link-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: color 0.3s;
}

.main-navigation a:hover {
    color: var(--accent-color);
}

/* --- PAGE & SINGLE --- */
.site-main {
    padding: 8rem 5% 4rem; /* Top padding to account for fixed header */
    min-height: 80vh;
}

.single-post, .page-content {
    max-width: 800px;
    margin: 0 auto;
}

.single-post h1, .page-content h1 {
    font-size: clamp(2rem, 5vw, 4rem);
    margin-bottom: 1rem;
}

.post-meta {
    margin-bottom: 2rem;
    color: #888;
    font-size: 0.9rem;
}

.entry-content, .post-content {
    font-size: 1.1rem;
    line-height: 1.8;
}

.entry-content p, .post-content p {
    margin-bottom: 1.5rem;
}

/* --- 404 PAGE --- */
.error-404 {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 80vh;
}

.error-404 h1 {
    font-size: 8rem;
    color: var(--accent-color);
    line-height: 1;
    margin-bottom: 1rem;
}

.btn-home {
    display: inline-block;
    margin-top: 2rem;
    padding: 1rem 2rem;
    border: 1px solid var(--link-color);
    color: var(--link-color);
    text-decoration: none;
    text-transform: uppercase;
    transition: all 0.3s;
}

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