/* ============================================
   PERFIL MIEMBRO - STYLESHEET
   Convertido de Tailwind CSS a CSS vanilla
   ============================================ */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600;700&family=Inter:wght@300;400;500;600&display=swap');

/* ============================================
   CSS VARIABLES (Design System)
   ============================================ */
:root {
    /* Cream/beige tones */
    --cream: 38 35% 95%;
    --cream-dark: 38 25% 90%;
    
    /* Main background */
    --background: 40 20% 99%;
    --foreground: 0 0% 7%;
    
    /* Cards */
    --card: 0 0% 100%;
    --card-foreground: 0 0% 7%;
    
    /* Primary */
    --primary: 0 0% 7%;
    --primary-foreground: 40 20% 98%;
    
    /* Secondary */
    --secondary: 38 35% 95%;
    --secondary-foreground: 0 0% 7%;
    
    /* Muted */
    --muted: 38 20% 94%;
    --muted-foreground: 0 0% 40%;
    
    /* Accent */
    --accent: 32 80% 50%;
    --accent-foreground: 0 0% 100%;
    
    /* Borders */
    --border: 38 15% 88%;
    
    --radius: 0.5rem;
}

/* ============================================
   BASE STYLES
   ============================================ */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: hsl(var(--background));
    color: hsl(var(--foreground));
}

/* ============================================
   WRAPPER & CONTAINER
   ============================================ */
.perfil-wrapper {
    min-height: 100vh;
    width: 100%;
    background-color: hsl(var(--background));
    padding-top: 0;
    padding-bottom: 0;
}

.perfil-container {
    max-width: 80rem; /* max-w-7xl */
    margin-left: auto;
    margin-right: auto;
    padding-left: 1.5rem; /* px-6 */
    padding-right: 1.5rem;
}

@media (min-width: 1024px) {
    .perfil-container {
        padding-left: 2rem; /* lg:px-8 */
        padding-right: 2rem;
    }
}

.perfil-main {
    padding-top: 3rem; /* py-12 */
    padding-bottom: 3rem;
}

@media (min-width: 1024px) {
    .perfil-main {
        padding-top: 4rem; /* lg:py-16 */
        padding-bottom: 4rem;
    }
}

/* ============================================
   BACK BUTTON
   ============================================ */
.back-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem; /* gap-2 */
    color: hsl(var(--muted-foreground));
    text-decoration: none;
    margin-bottom: 2rem; /* mb-8 */
    transition: color 0.2s ease;
    font-size: 0.875rem;
}

.back-button:hover {
    color: hsl(var(--foreground));
}

.back-icon {
    width: 1rem; /* w-4 */
    height: 1rem; /* h-4 */
}

/* ============================================
   PROFILE HEADER
   ============================================ */
.profile-header {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem; /* gap-8 */
    margin-bottom: 4rem; /* mb-16 */
}

@media (min-width: 1024px) {
    .profile-header {
        grid-template-columns: 1fr 2fr; /* lg:grid-cols-3 with span */
        gap: 3rem; /* lg:gap-12 */
    }
}

/* Photo Column */
.profile-photo-column {
    /* lg:col-span-1 is default */
}

.profile-photo-wrapper {
    aspect-ratio: 3 / 4; /* aspect-[3/4] */
    border-radius: 1rem; /* rounded-2xl */
    overflow: hidden;
    background-color: hsl(var(--muted));
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05); /* shadow-lg */
}

.profile-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Info Column */
.profile-info-column {
    /* lg:col-span-2 */
}

.profile-title-badge {
    display: inline-block;
    font-size: 0.875rem; /* text-sm */
    font-weight: 500; /* font-medium */
    color: hsl(var(--accent));
    text-transform: uppercase;
    letter-spacing: 0.05em; /* tracking-wider */
    margin-bottom: 0.5rem; /* mb-2 */
}

.profile-name {
    font-family: 'Playfair Display', serif;
    font-size: 1.875rem; /* text-3xl */
    font-weight: 600; /* font-semibold */
    color: hsl(var(--foreground));
    margin-bottom: 0.5rem; /* mb-2 */
    line-height: 1.2;
}

@media (min-width: 768px) {
    .profile-name {
        font-size: 2.25rem; /* md:text-4xl */
    }
}

@media (min-width: 1024px) {
    .profile-name {
        font-size: 3rem; /* lg:text-5xl */
    }
}

.profile-specialty {
    font-size: 1.125rem; /* text-lg */
    color: hsl(var(--muted-foreground));
    margin-bottom: 2rem; /* mb-8 */
}

/* ============================================
   PROFILE SECTIONS
   ============================================ */
.profile-section {
    margin-bottom: 2rem; /* mb-8 */
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem; /* text-xl */
    font-weight: 600; /* font-semibold */
    color: hsl(var(--foreground));
    margin-bottom: 1rem; /* mb-4 */
    display: flex;
    align-items: center;
    gap: 0.5rem; /* gap-2 */
}

.title-line {
    width: 2rem; /* w-8 */
    height: 0.125rem; /* h-0.5 */
    background-color: hsl(var(--primary));
}

.section-text {
    color: hsl(var(--muted-foreground));
    line-height: 1.625; /* leading-relaxed */
    text-align: justify;
}

/* ============================================
   ACADEMIC TRAJECTORY
   ============================================ */
.trajectory-list {
    display: flex;
    flex-direction: column;
    gap: 1rem; /* space-y-4 */
}

.trajectory-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem; /* gap-4 */
    padding: 1rem; /* p-4 */
    background-color: hsla(var(--secondary) / 0.5);
    border-radius: 0.5rem; /* rounded-lg */
}

.trajectory-icon {
    flex-shrink: 0;
    width: 2.5rem; /* w-10 */
    height: 2.5rem; /* h-10 */
    border-radius: 50%; /* rounded-full */
    background-color: hsla(var(--primary) / 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: hsl(var(--primary));
}

.trajectory-icon svg {
    width: 1.25rem; /* w-5 */
    height: 1.25rem; /* h-5 */
}

.trajectory-content {
    flex: 1;
}

.trajectory-degree {
    font-weight: 500; /* font-medium */
    color: hsl(var(--foreground));
    margin-bottom: 0.25rem;
}

.trajectory-details {
    font-size: 0.875rem; /* text-sm */
    color: hsl(var(--muted-foreground));
}

/* ============================================
   EXTERNAL LINKS
   ============================================ */
.external-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem; /* gap-4 */
}

.btn-external {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem; /* gap-2 */
    padding: 0.625rem 1.25rem; /* px-5 py-2.5 */
    border-radius: 0.5rem; /* rounded-lg */
    font-weight: 500; /* font-medium */
    font-size: 0.875rem; /* text-sm */
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.btn-external:hover {
    opacity: 0.9;
}

.btn-primary {
    background-color: hsl(var(--primary));
    color: hsl(var(--primary-foreground));
}

.btn-accent {
    background-color: hsl(var(--accent));
    color: hsl(var(--accent-foreground));
}

.btn-external-icon {
    width: 1rem; /* w-4 */
    height: 1rem; /* h-4 */
}

/* ============================================
   CONTENT SECTIONS
   ============================================ */
.content-section {
    margin-bottom: 4rem; /* mb-16 */
}

.section-header {
    display: flex;
    align-items: center;
    gap: 1rem; /* gap-4 */
    margin-bottom: 2rem; /* mb-8 */
}

.section-main-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem; /* text-2xl */
    font-weight: 600; /* font-semibold */
    color: hsl(var(--foreground));
}

@media (min-width: 768px) {
    .section-main-title {
        font-size: 1.875rem; /* md:text-3xl */
    }
}

.section-divider {
    flex: 1;
    height: 1px;
    background-color: hsl(var(--border));
}

/* ============================================
   PUBLICATIONS
   ============================================ */
.publications-grid {
    display: grid;
    gap: 1rem; /* gap-4 */
}

.publication-card {
    background-color: hsl(var(--card));
    border: 1px solid hsla(var(--border) / 0.5);
    border-radius: 0.75rem; /* rounded-xl */
    padding: 1.5rem; /* p-6 */
    transition: box-shadow 0.3s ease;
}

.publication-card:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06); /* hover:shadow-md */
}

.publication-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.125rem; /* text-lg */
    font-weight: 600; /* font-semibold */
    color: hsl(var(--foreground));
    margin-bottom: 0.75rem; /* mb-3 */
    line-height: 1.375; /* leading-tight */
}

.publication-description {
    color: hsl(var(--muted-foreground));
    font-size: 0.875rem; /* text-sm */
    margin-bottom: 1rem; /* mb-4 */
    line-height: 1.625; /* leading-relaxed */
}

.publication-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem; /* gap-4 */
    font-size: 0.875rem; /* text-sm */
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem; /* gap-2 */
    color: hsl(var(--muted-foreground));
}

.meta-icon {
    width: 1rem; /* w-4 */
    height: 1rem; /* h-4 */
}

/* ============================================
   PROJECTS
   ============================================ */
.projects-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem; /* gap-6 */
}

@media (min-width: 768px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr); /* md:grid-cols-2 */
    }
}

.project-card {
    background-color: hsl(var(--card));
    border: 1px solid hsla(var(--border) / 0.5);
    border-radius: 0.75rem; /* rounded-xl */
    overflow: hidden;
    transition: all 0.3s ease;
}

.project-card:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05); /* hover:shadow-lg */
}

.project-image-wrapper {
    aspect-ratio: 16 / 9; /* aspect-video */
    overflow: hidden;
}

.project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-card:hover .project-image {
    transform: scale(1.05); /* group-hover:scale-105 */
}

.project-content {
    padding: 1.5rem; /* p-6 */
}

.project-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.125rem; /* text-lg */
    font-weight: 600; /* font-semibold */
    color: hsl(var(--foreground));
    margin-bottom: 0.75rem; /* mb-3 */
}

.project-description {
    color: hsl(var(--muted-foreground));
    font-size: 0.875rem; /* text-sm */
    margin-bottom: 1rem; /* mb-4 */
    line-height: 1.625; /* leading-relaxed */
}

.project-members {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem; /* gap-2 */
    font-size: 0.875rem; /* text-sm */
    color: hsl(var(--muted-foreground));
}

.members-icon {
    width: 1rem; /* w-4 */
    height: 1rem; /* h-4 */
    margin-top: 0.125rem; /* mt-0.5 */
    flex-shrink: 0;
}

.project-members span {
    line-height: 1.625; /* leading-relaxed */
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media (max-width: 767px) {
    .profile-name {
        font-size: 1.75rem;
    }
    
    .section-main-title {
        font-size: 1.5rem;
    }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.back-button:focus,
.btn-external:focus {
    outline: 2px solid hsl(var(--primary));
    outline-offset: 2px;
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .back-button,
    .external-links {
        display: none;
    }
    
    .project-card,
    .publication-card {
        break-inside: avoid;
        page-break-inside: avoid;
    }
}

/* Ocultar el innerbanner en páginas de perfil */
.page-template-page-miembros .innerbanner,
.single-investigador .innerbanner {
    display: none !important;
}