/* ==========================================================================
   BASE.CSS - VERSIÓN INTEGRAL RESTAURADA (Switch Ads)
   ========================================================================== */

/* 1. CONFIGURACIÓN Y FUENTES */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700&family=Playfair+Display:ital,wght@0,700;1,700&display=swap');

:root {
    --bg-dark: #1b1b1b;
    --text-light: #ffffff;
    --accent: #ff4c3b;
    --gray-text: #a0a0a0;
    --border-color: #2a2a2a;
    --transition-speed: 0.7s;
    --ease-premium: cubic-bezier(0.77, 0, 0.175, 1);
}

/* 2. RESET Y BASES */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background-color: var(--bg-dark);
    color: var(--text-light);
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    line-height: 1.6;
}

/* 3. LAYOUT PRINCIPAL */
.portfolio-wrapper {
    display: flex;
    min-height: 100vh;
    transition: all var(--transition-speed) var(--ease-premium);
}

.project-visuals {
    width: 60%;
    background-color: #111;
    position: relative;
    transition: width var(--transition-speed) var(--ease-premium);
}

.project-info {
    width: 40%;
    height: 100vh;
    position: sticky;
    top: 0;
    padding: 60px 5%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-color: var(--bg-dark);
    border-left: 1px solid var(--border-color);
    transition: all var(--transition-speed) var(--ease-premium);
}

/* 4. MODO ENFOQUE (FOCUS MODE) */
.expand-toggle-container {
    position: fixed;
    bottom: 40px;
    left: 40px;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(20, 20, 20, 0.85);
    backdrop-filter: blur(15px);
    padding: 10px 20px;
    border-radius: 50px;
    border: 1px solid var(--border-color);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.4s ease;
}

.project-visuals:hover .expand-toggle-container {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.toggle-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--gray-text);
}

/* UI SWITCH */
.switch-track {
    width: 36px; height: 18px;
    background: #333;
    border-radius: 20px;
    position: relative;
    transition: background 0.3s;
}

.switch-handle {
    width: 12px; height: 12px;
    background: var(--text-light);
    border-radius: 50%;
    position: absolute;
    top: 3px; left: 3px;
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Estado Expandido */
.expanded .project-visuals { width: 100%; }
.expanded .project-info { width: 0%; padding: 0; opacity: 0; visibility: hidden; border-left: none; }
.expanded .switch-track { background: var(--accent); }
.expanded .switch-handle { transform: translateX(18px); }

/* 5. CONTENIDO DEL PROYECTO (TEXTOS E IMÁGENES) */
.image-sheet img { 
    width: 100%; 
    height: auto; 
    display: block; 
    filter: grayscale(10%); 
    transition: filter 0.8s ease; 
}

.image-sheet img:hover { filter: grayscale(0%); }

.meta-data { 
    color: var(--accent); 
    font-size: 11px; 
    font-weight: 600; 
    letter-spacing: 2.5px; 
    text-transform: uppercase; 
    margin-bottom: 15px; 
    display: block; 
}

.project-title { 
    font-family: 'Playfair Display', serif; 
    font-size: clamp(2.5rem, 4.5vw, 4rem); 
    line-height: 1.1; 
    margin-bottom: 25px; 
}

.project-description { 
    font-size: 15px; 
    color: var(--gray-text); 
    margin-bottom: 45px; 
    max-width: 450px; 
}

/* TABLA DE DETALLES */
.details-table { 
    display: grid; 
    grid-template-columns: repeat(3, 1fr); 
    gap: 20px; 
    padding-top: 35px; 
    border-top: 1px solid var(--border-color); 
    margin-bottom: 40px; 
}

.detail-group h4 { 
    font-size: 10px; 
    letter-spacing: 1.5px; 
    text-transform: uppercase; 
    color: var(--text-light); 
    margin-bottom: 8px; 
}

.detail-group p { font-size: 12px; color: var(--gray-text); }

/* 6. NAVEGACIÓN Y CONTADORES */
.project-navigation {
    position: absolute;
    bottom: 40px;
    right: 40px;
    display: flex;
    align-items: center;
    gap: 30px;
}

.project-counter {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 2px;
    color: var(--gray-text);
}

.project-counter span { color: var(--text-light); }

.nav-controls { display: flex; gap: 10px; }

.nav-btn {
    text-decoration: none;
    color: var(--gray-text);
    font-size: 18px;
    width: 45px;
    height: 45px;
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.nav-btn:hover {
    color: var(--text-light);
    border-color: var(--accent);
    background-color: rgba(255, 76, 59, 0.05);
    transform: translateY(-2px);
}

.close-icon { 
    position: absolute; 
    top: 30px; 
    right: 40px; 
    text-decoration: none; 
    color: var(--text-light); 
    font-size: 28px; 
    transition: 0.3s; 
}

.close-icon:hover { color: var(--accent); transform: rotate(90deg); }

/* 7. RESPONSIVO */
@media (max-width: 1024px) {
    .portfolio-wrapper { flex-direction: column; }
    .project-visuals, .project-info { width: 100% !important; }
    .expand-toggle-container { display: none; }
    .project-info { height: auto; padding: 80px 10%; position: relative; border-left: none; }
}