* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: url('bg.jpg') no-repeat center center fixed;
    background-size: cover;
    font-family: Tahoma, Verdana, Arial, sans-serif;
    font-size: 11px;
    color: #000;
    padding: 60px 40px;
    line-height: 1.6;
}

.window {
    max-width: 800px;
    margin: 0 auto;
    background: #ece9d8;
    border: 3px solid;
    border-color: #fff #999 #999 #fff;
    box-shadow: 2px 2px 0 rgba(0,0,0,0.2);
}

.window.wide {
    max-width: 900px;
}

.titlebar {
    background: linear-gradient(to bottom, #0997ff 0%, #0053ee 100%);
    padding: 3px 5px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 26px;
}

.titlebar-text {
    color: #fff;
    font-weight: bold;
    font-size: 11px;
    letter-spacing: 0.5px;
}

.titlebar-buttons {
    display: flex;
    gap: 2px;
}

.titlebar-button {
    width: 21px;
    height: 21px;
    background: linear-gradient(to bottom, #f0f0f0 0%, #c0c0c0 100%);
    border: 1px solid;
    border-color: #fff #666 #666 #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    color: #000;
    cursor: pointer;
    transition: background 0.1s;
}

.titlebar-button:active {
    background: linear-gradient(to bottom, #c0c0c0 0%, #f0f0f0 100%);
    border-color: #666 #fff #fff #666;
}

.content {
    padding: 15px 20px;
    background: #fff;
    min-height: 500px;
}

.header {
    border-bottom: 1px solid #c0c0c0;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.site-title {
    font-size: 18px;
    font-weight: bold;
    color: #0053ee;
    margin-bottom: 5px;
}

.site-subtitle {
    font-size: 11px;
    color: #666;
    font-style: italic;
}

.nav {
    margin: 15px 0;
    padding: 8px;
    background: #f0f0f0;
    border: 1px solid #c0c0c0;
}

.nav a {
    color: #0053ee;
    text-decoration: none;
    margin-right: 15px;
}

.nav a:hover {
    text-decoration: underline;
}

.nav a.active {
    font-weight: bold;
}

.intro {
    margin: 20px 0;
    padding: 15px;
    background: #f9f9f9;
    border: 1px solid #c0c0c0;
    line-height: 1.8;
}

/* ============================================
   MEJORAS PARA LA GALERÍA DE DIBUJOS
   ============================================ */

.gallery {
    margin-top: 30px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

.art-item {
    border: 2px solid #c0c0c0;
    background: #f0f0f0;
    padding: 10px;
    cursor: pointer;
    transition: all 0.15s ease;
    position: relative;
}

/* Efecto hover mejorado */
.art-item:hover {
    border-color: #0053ee;
    background: #fff;
    transform: translateY(-2px);
    box-shadow: 3px 3px 0 rgba(0,0,0,0.15);
}

.art-item:active {
    transform: translateY(0);
    box-shadow: 1px 1px 0 rgba(0,0,0,0.15);
}

.art-preview {
    width: 100%;
    aspect-ratio: 1;
    background: #fff;
    border: 2px solid #999;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* Placeholder styling */
.art-preview.art-placeholder {
    color: #999;
    font-size: 10px;
    text-align: center;
    padding: 10px;
}

.art-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Icono de zoom al hacer hover */
.art-item:hover .art-preview::after {
    content: '🔍';
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid #999;
    padding: 4px 8px;
    font-size: 12px;
    box-shadow: 1px 1px 0 rgba(0,0,0,0.2);
}

.art-info {
    margin-top: 10px;
    padding: 5px;
    background: #fff;
    border: 1px solid #c0c0c0;
}

.art-title {
    font-size: 11px;
    font-weight: bold;
    color: #000;
    margin-bottom: 3px;
}

.art-date {
    font-size: 10px;
    color: #666;
}

/* ============================================
   LIGHTBOX ESTILO WINDOWS 98
   ============================================ */

.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.lightbox-window {
    background: #ece9d8;
    border: 3px solid;
    border-color: #fff #999 #999 #fff;
    box-shadow: 4px 4px 0 rgba(0,0,0,0.3);
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.lightbox-content {
    background: #fff;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    min-height: 400px;
    position: relative;
}

.lightbox-image-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 800px;
    max-height: 70vh;
}

.lightbox-image-container img {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border: 2px solid #999;
    background: #fff;
    box-shadow: 2px 2px 0 rgba(0,0,0,0.2);
}

/* Botones de navegación */
.lightbox-nav {
    background: linear-gradient(to bottom, #f0f0f0 0%, #c0c0c0 100%);
    border: 2px solid;
    border-color: #fff #666 #666 #fff;
    width: 40px;
    height: 40px;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
    font-family: Tahoma, Verdana, Arial, sans-serif;
    flex-shrink: 0;
}

.lightbox-nav:hover {
    background: linear-gradient(to bottom, #fff 0%, #d0d0d0 100%);
}

.lightbox-nav:active {
    background: linear-gradient(to bottom, #c0c0c0 0%, #f0f0f0 100%);
    border-color: #666 #fff #fff #666;
}

.lightbox-info {
    padding: 10px 15px;
    background: #f0f0f0;
    border-top: 2px solid #999;
}

.lightbox-title {
    font-weight: bold;
    font-size: 12px;
    color: #000;
    margin-bottom: 3px;
}

.lightbox-date {
    font-size: 10px;
    color: #666;
}

/* Footer */
.footer {
    margin-top: 40px;
    padding-top: 15px;
    border-top: 1px solid #c0c0c0;
    text-align: center;
    color: #666;
    font-size: 10px;
}

::selection {
    background: #0053ee;
    color: #fff;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    body {
        padding: 20px 10px;
    }
    
    .content {
        padding: 10px 15px;
    }
    
    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 15px;
    }
    
    .art-item {
        padding: 8px;
    }
    
    .lightbox {
        padding: 10px;
    }
    
    .lightbox-window {
        max-width: 95vw;
        max-height: 95vh;
    }
    
    .lightbox-content {
        padding: 10px;
        min-height: 300px;
        gap: 8px;
    }
    
    .lightbox-image-container {
        max-height: 60vh;
    }
    
    .lightbox-image-container img {
        max-height: 60vh;
    }
    
    .lightbox-nav {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }
    
    .art-item:hover .art-preview::after {
        font-size: 10px;
        padding: 3px 6px;
    }
}

@media (max-width: 480px) {
    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 10px;
    }
    
    .lightbox-nav {
        width: 30px;
        height: 30px;
        font-size: 12px;
    }
    
    .lightbox-content {
        padding: 5px;
        gap: 5px;
    }
}