/* RESET BÁSICO */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* ESTRUCTURA GENERAL */
html, body {
    height: 100%;
    font-family: Arial, sans-serif;
}

body {
    display: flex;
    flex-direction: column;
    background-color: #f5f5f5;
}

/* HEADER */
/* HEADER */
.header {
    background-color: #1e1e1e;
    color: white;
}

.header-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 15px 20px;

    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* LOGO */
.logo a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    font-size: 18px;
}

/* minigames */
.minigames {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 20px;
}

.minigames-header {
    margin-bottom: 40px;
    text-align: center;
}

.minigames-header h1 {
    color: #ffffff;
    text-shadow:
        0 2px 10px rgba(0, 0, 0, 0.6),
        0 0 20px rgba(0, 150, 255, 0.3);
}

.minigames-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.minigame-card {
    display: block;
    width: 100%;
    text-decoration: none;
}

.minigame-img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: contain;
    border-radius: 8px;
    transition: transform 0.2s ease;
}

.minigame-img:hover {
    transform: scale(1.05);
}

@media (max-width: 900px) {
    .minigames-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .minigames-grid {
        grid-template-columns: 1fr;
    }
}


/* =========================
   PROJECTS
========================= */

.projects {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 20px;
}

.projects-header {
    text-align: center;
    margin-bottom: 40px;
}

.projects-header h1 {
    color: white;
    font-size: 32px;
}

.projects-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 30px;
}

.project-card {
    display: block;
    width: 100%;
    max-width: 420px;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.25s ease;
}

.project-card:hover {
    transform: scale(1.05);
}

.project-img {
    display: block;
    width: 100%;
    height: 240px;
    object-fit: cover;
}

/* NAV */
nav {
    display: flex;
    gap: 20px;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: 500;

    transition: transform 0.2s ease;
}

nav a:hover {
    transform: scale(1.3);
}

/* MAIN */
main {
    flex: 1;
    padding: 0;
    background: linear-gradient(135deg, #0f2027, #2c5364, #3ecf8e);
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0;
}


/* HERO FULLSCREEN */
.hero {
    min-height: 100%; /* Ajusta según el header */
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2.5rem 1.25rem;

    color: white;
    text-align: center;
}

/* HERO CONTENT */
.hero-content {
    max-width: 600px;
}

/* AVATAR */
.hero-avatar {
    width: 320px;
    height: 320px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 20px;
    border: 3px solid rgba(255,255,255,0.3);
}

/* TITLE */
.hero h1 {
    font-size: 36px;
    margin-bottom: 10px;
}

/* SUBTITLE */
.hero-subtitle {
    font-size: 18px;
    margin-bottom: 30px;
    color: rgba(255,255,255,0.8);
}

/* BUTTONS */ 
.hero-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.btn {
    padding: 10px 20px;
    background-color: rgba(0,0,0,0.3);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    transition: 0.2s;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 80%;
    height: 100%;

    background: linear-gradient(
        120deg,
        transparent,
        rgba(255,255,255,0.6),
        transparent
    );

    transform: skewX(-20deg);
}

.btn:hover::before {
    left: 120%;
    transition: 0.6s;
}

.btn:hover {
    background-color: rgba(0,0,0,0.5)
}


/* FOOTER */
footer {
    background-color: #1e1e1e;
    color: white;
    text-align: center;
    padding: 10px;
}

/* GALLERY */
.gallery {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
}

/* GALLERY-HEADER */
.gallery-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.btn-back {
    text-decoration: none;
    background-color: #1e1e1e;
    color: white;
    padding: 8px 16px;
    border-radius: 30px;
}

/* GALLERY GRID */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.gallery-grid h3 {
    color: white;
    text-align: right;
}

/* GALLERY-ITEM */
.gallery-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.2s;
}

.gallery-item img:hover {
    transform: scale(1.05);
}

/* GALLERY RESPONSIVE */
@media (max-width: 900px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}

/* GALLERY LIGHTBOX */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background: rgba(0,0,0,0.8);

    display: flex;
    justify-content: center;
    align-items: center;

    backdrop-filter: blur(8px);

    z-index: 999;
}

.lightbox img {
    max-width: 90%;
    max-height: 90%;
    border-radius: 10px;
}

.hidden {
    display: none;
}

/* WRITINGS */
.writing-wrapper {
    position: relative;
    min-height: 100vh;
}

.writing-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: blur(6px) brightness(0.4);
    z-index: 0;
}

.writing {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
    padding: 40px;
    color: white;
    text-align: center;
    font-family: 'Cinzel', serif;
}

.writing h1 {
    margin-bottom: 20px;
    color: white;
}

.writing-content {
    margin-bottom: 15px;
    line-height: 1.8;
}

/* =========================
   CV / SKILLS PAGE
========================= */

.cv-page {
    width: 100%;
    max-width: 68.75rem;
    margin: 0 auto;
    padding: 2.5rem 1.25rem;
    color: white;

}

.cv-header {
    display:flex;
    align-items: center;
    justify-content: center;
    gap: clamp(1.5rem, 4vw, 3rem);
    margin-bottom: 2.5rem;

    padding: clamp(1.5rem, 4vw, 2.5rem);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 1.25rem;
    background-color: rgba(0, 0, 0, 0.28);
}

.cv-header-info {
    line-height: 1.5;
}

.cv-contact{
    line-height: 1.5;
}

.cv-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
}

.cv-photo {
    width: clamp(8rem, 18vw, 11.25rem);
    height: clamp(8rem, 18vw, 11.25rem);
    border-radius: 50%;
    object-fit: cover;
    display: block;
    border: 0.1875rem solid rgba(255,255,255,0.3);
}

.cv-layout {
    display: grid;
    grid-template-columns: minmax(18rem, 0.95fr) minmax(0, 1.45fr);
    gap: clamp(1.5rem, 4vw, 3rem);
    align-items: start;
}

.cv-sidebar,
.cv-main {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    min-width: 0;
}

.cv-block {
    padding: clamp(1rem, 2vw, 1.5rem);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 1rem;
    background-color: rgba(0, 0, 0, 0.25);
}

.cv-block h2 {
    font-size: clamp(1.25rem, 2vw, 1.6rem);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.25);
    text-transform: uppercase;
    letter-spacing: 0.05rem;
}

.cv-block h3 {
    font-size: clamp(1rem, 1.6vw, 1.25rem);
    margin-bottom: 0.35rem;
}

.cv-block p {
    line-height: 1.6;
    margin-bottom: 1rem;
}

.cv-block ul {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding-left: 1.2rem;
    margin-bottom: 1rem;
}

.cv-block li {
    line-height: 1.5;
}

.cv-job {
    margin-bottom: 1.5rem;
}

.cv-job:last-child {
    margin-bottom: 0;
}

