/* ==========================================
   RESET & CONFIGURACIÓN GENERAL
   ========================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: #f7f4ed; /* Fondo marfil cálido */
    color: #0b2545; /* Azul petróleo profundo y sofisticado */
    font-family: 'Georgia', 'Times New Roman', Times, serif;
    line-height: 1.6;
}

/* ==========================================
   NAVEGACIÓN SUPERIOR
   ========================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2.5rem;
    background-color: rgba(247, 244, 237, 0.95);
    backdrop-filter: blur(5px);
    z-index: 1000;
    border-bottom: 1px solid #d4cbb8;
}

.nav-logo a {
    text-decoration: none;
    color: #0b2545;
    display: flex;
    flex-direction: column;
}

.logo-name {
    font-family: 'Elephant', 'Georgia', serif;
    font-size: 0.75rem;
    font-weight: bold;
    letter-spacing: 0.28em;
    text-transform: uppercase;
}

.logo-sub {
    font-family: 'Georgia', serif;
    font-size: 0.8rem;
    font-style: italic;
    color: #d9534f; /* Toque coral/terracota creativo en el subtítulo */
    letter-spacing: 0.03em;
    white-space: nowrap;
    margin-top: 0.1rem;
}

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

.nav-links a {
    text-decoration: none;
    color: #0b2545;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #d9534f; /* Color llamativo al hacer hover */
}

/* ==========================================
   CABECERA / HOME (Compacta)
   ========================================== */
.header {
    min-height: 50vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 7rem 2rem 2rem 2rem;
    border-bottom: 1px solid #d4cbb8;
}

.bold-title {
    font-family: 'Elephant', 'Georgia', serif;
    font-size: clamp(2.5rem, 6vw, 5.5rem);
    font-weight: normal;
    text-transform: uppercase;
    letter-spacing: 0.22em;
    margin-bottom: 1rem;
    line-height: 1.1;
    color: #0b2545;
}

.subtitle {
    font-size: 1.15rem;
    font-style: italic;
    color: #d9534f; /* Acento creativo */
    margin-bottom: 1rem;
    letter-spacing: 0.05em;
}

.bio {
    max-width: 550px;
    font-size: 0.95rem;
    color: #334e68; /* Tono gris-azulado suave para lectura */
    line-height: 1.6;
}

/* ==========================================
   GALERÍA COMPACTA (10 proyectos)
   ========================================== */
.gallery {
    column-count: 3;
    column-gap: 1.2rem;
    padding: 2rem 2.5rem;
    background-color: #ffffff;
}

.project-card {
    break-inside: avoid;
    margin-bottom: 1.2rem;
    display: inline-block;
    width: 100%;
    background: #ffffff;
}

.project-link {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: opacity 0.3s ease;
}

.project-link:hover {
    opacity: 0.95;
}

/* Alturas dinámicas compactas */
.size-tall .image-container {
    height: 380px;
}

.size-medium .image-container {
    height: 280px;
}

.size-short .image-container {
    height: 200px;
}

.image-container {
    width: 100%;
    overflow: hidden;
    background-color: #f0ebe1;
    position: relative;
    border: 1px solid #e2dac9;
}

.image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .image-container img {
    transform: scale(1.03);
}

.project-info {
    padding: 0.6rem 0 0.2rem 0;
}

.project-info h2 {
    font-size: 0.95rem;
    font-weight: normal;
    letter-spacing: 0.02em;
    margin-bottom: 0.1rem;
    color: #0b2545;
    transition: color 0.3s ease;
}

.project-card:hover .project-info h2 {
    color: #d9534f; /* Destaca el título del proyecto en coral al pasar el cursor */
}

.project-info p {
    font-size: 0.8rem;
    color: #627d98;
    font-style: italic;
}

/* ==========================================
   ESTILOS PARA LAS SUBSECCIONES DE DETALLE
   ========================================== */
.project-detail-header {
    padding: 8rem 2.5rem 2rem 2.5rem;
    max-width: 900px;
    margin: 0 auto;
}

.back-link {
    display: inline-block;
    text-decoration: none;
    color: #627d98;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: #d9534f;
}

.project-detail-title {
    font-family: 'Elephant', 'Georgia', serif;
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: normal;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    color: #0b2545;
}

.project-detail-desc {
    font-size: 1.1rem;
    color: #334e68;
    line-height: 1.7;
    font-style: italic;
}

.project-gallery {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 2.5rem 5rem 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.detail-image-container {
    width: 100%;
    height: 600px;
    background-color: #f0ebe1;
    border: 1px solid #e2dac9;
    overflow: hidden;
}

.detail-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ==========================================
   SECCIÓN SOBRE MÍ
   ========================================== */
.about-section {
    padding: 5rem 2.5rem;
    background-color: #f7f4ed;
    border-top: 1px solid #d4cbb8;
    display: flex;
    justify-content: center;
}

.about-content {
    max-width: 800px;
}

.section-title {
    font-family: 'Elephant', 'Georgia', serif;
    font-size: 1.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1.5rem;
    font-weight: normal;
    color: #0b2545;
}

.about-content p {
    font-size: 1.1rem;
    line-height: 1.7;
    color: #334e68;
}

/* ==========================================
   FOOTER / CONTACTO
   ========================================== */
.footer {
    padding: 5rem 2.5rem 3rem 2.5rem;
    background-color: #0b2545; /* Footer profundo con el color principal en oscuro */
    color: #f7f4ed;
}

.footer .section-title {
    color: #f7f4ed;
}

.footer p {
    color: #bcccdc;
    margin-bottom: 0.4rem;
}

.email-link {
    color: #ff6b6b; /* Un tono coral brillante perfecto para llamadas a la acción */
    text-decoration: underline;
    font-size: 1.1rem;
    letter-spacing: 0.05em;
    transition: opacity 0.3s ease;
}

.email-link:hover {
    opacity: 0.8;
}

.copyright {
    margin-top: 3rem;
    font-size: 0.8rem;
    color: #829ab1;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* ==========================================
   DISEÑO RESPONSIVO (Móviles y Tablets)
   ========================================== */
@media (max-width: 1024px) {
    .gallery {
        column-count: 2;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 1rem 1.5rem;
    }
    
    .nav-links {
        display: none; 
    }

    .gallery {
        column-count: 1;
        padding: 1.5rem;
        column-gap: 0;
    }

    .size-tall .image-container,
    .size-medium .image-container,
    .size-short .image-container {
        height: 260px; 
    }

    .detail-image-container {
        height: 350px;
    }

    .header, .about-section, .footer, .project-detail-header, .project-gallery {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
}
