/* ===================================
   RESET / BASE
   =================================== */
body {
    font-family: Arial, sans-serif;
    background-color: #ffffff;
    margin: 0;
    padding: 0;
    height: 100vh;
}

/* ===================================
   HEADER / NAVIGATION
   =================================== */
.logo {
    letter-spacing: 0.4rem;
    line-height: 1.2rem;
    font-size: 0.9rem;
    color: #000;
    text-decoration: none;
}

.navbar .nav-link {
    color: #000;
    font-size: 0.9rem;
    margin-left: 1rem;
    padding: 0.2rem 0.5rem;
}

.navbar-toggler {
    border-color: rgba(0, 0, 0, 0.1);
}

.navbar-toggler-icon {
    filter: invert(0);
}

/* ===================================
   HOME PAGE - HORIZONTAL SCROLL
   =================================== */
.scroll-container {
    width: 100%;
    height: 100%;
    overflow-x: auto;
    white-space: nowrap;
    padding-top: 40px;
}

.art-item {
    position: relative;
    display: inline-block;
    margin: 0 60px;
    vertical-align: top;
    height: auto;
}

.home-gallery-container .art-img {
    width: auto;
    height: 70vh;
    max-width: none;
}

.art-img {
    width: 380px;
    max-width: 70vw;
    height: auto;
    object-fit: cover;
    transition: 0.3s ease;
    display: block;
}

.art-item:hover .art-img {
    filter: blur(4px) brightness(1) contrast(1);
    transform: scale(1.05);
}

/* Hover text overlay */
.art-hover-text {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 6%;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.art-hover-text p {
    margin: 0;
    max-width: 100%;
    text-align: center;
    white-space: normal;

    word-break: break-word;
    line-height: 1.45;
    font-size: clamp(0.9rem, 1.4vw, 1.15rem);
    padding: 10px 18px;
}

.art-item:hover .art-hover-text {
    opacity: 1;
}

/* Year pin below image */
.year-pin {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 12px;
    white-space: normal;
}

.year-pin .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: black;
    margin-bottom: 6px;
}

.year-pin span {
    font-size: 0.9rem;
    color: black;
}

/* Legacy art-title (kept for compatibility) */
.art-title {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
    transition: 0.3s ease;
    color: #000;
    font-size: 1.2rem;
    font-weight: bold;
    background: rgba(255, 255, 255, 0.6);
    padding: 10px 20px;
    backdrop-filter: blur(5px);
    border-radius: 5px;
}

.art-item:hover .art-title {
    opacity: 1;
}

/* ===================================
   OBRAS PAGE - GALLERY
   =================================== */
.page-title {
    font-weight: 400;
    letter-spacing: 0.08em;
    font-size: 1.25rem;
    color: #222;
}

.gallery {
    overflow-y: hidden;
    overflow-x: auto;
    flex-grow: 1;
}

.gallery-horizontal {
    height: auto;
}

.gallery-horizontal .art-item {
    margin: 20px;
}

.gallery-horizontal .art-item img {
    width: auto;
    height: 23vh;
}

.gallery-horizontal .art-item p {
    font-size: 0.75rem;
}

/* ===================================
   EXPOSIÇÕES PAGE
   =================================== */
.expo-horizontal {
    height: calc(100vh - 120px);
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    padding: 20px 40px;
    box-sizing: border-box;
}

.expo-track {
    display: flex;
    align-items: center;
    gap: 36px;
    height: 100%;
    padding: 10px 0;
    box-sizing: border-box;
}

.expo-card {
    width: auto;
    display: flex;
    flex: 0 0 auto;
    cursor: pointer;
    overflow: hidden;
    background: #fff;
    border-radius: 4px;
    position: relative;
    align-items: center;
    justify-content: center;
    height: calc(100% - 20px);
    box-shadow: 0 0 0 rgba(0, 0, 0, 0.04);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.expo-card:focus {
    outline: none;
    box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.06);
}

.expo-card:hover {
    transform: scale(1.02);
}

.expo-card:hover img {
    filter: blur(4px) brightness(1) contrast(1);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.06);
}

.expo-card:hover .art-hover-text {
    opacity: 1;
    transform: scale(1.30);
}

.expo-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Modal styles */
.modal-image {
    height: 70vh;
    overflow: hidden;
}

.modal-image img.object-cover {
    object-fit: cover;
    height: 100%;
}

.modal-text h3 {
    font-size: 1.6rem;
    letter-spacing: 0.02em;
}

.modal-text .lead {
    font-size: 1rem;
    line-height: 1.6;
    color: #111;
}

/* ===================================
   SOBRE PAGE
   =================================== */
.sobre-section {
    max-width: 1400px;
    margin: 0 auto;
}

.sobre-img {
    border-radius: 4px;
    object-fit: cover;
    width: 70%;
}

.sobre-title {
    font-size: 2rem;
    letter-spacing: 0.04em;
    font-weight: 400;
}

.sobre-text {
    font-size: 1rem;
    line-height: 1.65;
    color: #222;
    margin-bottom: 1.2rem;
}

/* ===================================
   MEDIA QUERIES
   =================================== */

/* Mobile - up to 576px */
@media (max-width: 576px) {

    /* Gallery */
    .gallery-column {
        min-width: 240px;
        gap: 18px;
    }

    .gallery-column .art-img {
        width: 220px;
        max-width: 75vw;
    }

    .page-title {
        font-size: 1rem;
        padding-left: 8px;
    }

    header .navbar {
        padding: 8px;
    }

    /* Exposições */
    .expo-card {
        width: 260px;
    }

    .expo-horizontal {
        padding: 12px;
    }

    .modal-image {
        height: 35vh;
    }
}

/* Tablet - 577px to 768px */
@media (max-width: 768px) {

    /* Header */
    header {
        padding: 12px;
    }

    .logo {
        font-size: 0.85rem;
        letter-spacing: 0.25rem;
    }

    .nav-link {
        font-size: 0.85rem;
        margin-left: 0.5rem;
    }

    /* Home - art items */
    .art-img {
        width: 320px;
        max-width: 72vw;
    }

    .art-item {
        margin: 0 18px;
    }

    .scroll-container {
        padding: 24px 0 70px 0;
    }

    /* Sobre */
    .sobre-title {
        text-align: center;
        margin-top: 20px;
    }

    .sobre-text {
        text-align: left;
    }
}

/* Tablet large - 769px to 992px */
@media (max-width: 992px) {

    /* Gallery */
    .gallery-column {
        min-width: 300px;
    }

    .gallery-column .art-img {
        width: 260px;
    }

    /* Exposições */
    .expo-card {
        width: 360px;
    }

    .modal-image {
        height: 40vh;
    }
}

/* Desktop - 1200px and up */
@media (min-width: 1200px) {
    .gallery-column {
        min-width: 25vw;
    }

    .gallery-track {
        gap: 24px;
    }

    .gallery-column .art-img {
        width: 280px;
    }
}

/* CSS */
:root {
    --btn-radius: 999px;
    --btn-py: .6rem;
    --btn-px: 1.4rem;
    --btn-border: 1.5px;
    --btn-fs: 16px;

    --btn-text: #111;
    --btn-border-color: #111;
    --btn-bg: transparent;

    --btn-hover-bg: #111;
    --btn-hover-text: #fff;
}

.btn-pill {
    display: inline-block;
    font: 500 var(--btn-fs)/1.2 system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    color: var(--btn-text);
    background: var(--btn-bg);
    padding: var(--btn-py) var(--btn-px);
    border: var(--btn-border) solid var(--btn-border-color);
    border-radius: var(--btn-radius);
    text-decoration: none;
    transition:
        background-color .2s ease,
        color .2s ease,
        box-shadow .2s ease,
        transform .02s ease;
}

.btn-pill:hover {
    background: var(--btn-hover-bg);
    color: var(--btn-hover-text);
}

.btn-pill:focus-visible {
    outline: 3px solid #7aa2ff;
    /* acessibilidade */
    outline-offset: 2px;
}

.btn-pill:active {
    transform: translateY(1px);
}

/* tamanhos extras (opcional) */
.btn-pill--sm {
    font-size: 14px;
    padding: .45rem 1.1rem;
}

.btn-pill--lg {
    font-size: 18px;
    padding: .75rem 1.6rem;
}

/* ===================================
   LIGHTBOX - FULL SCREEN IMAGE VIEWER
   =================================== */
.lightbox {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    grid-template-rows: minmax(0, 1fr) auto auto;
    justify-items: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.lightbox-content {
    grid-row: 1;
    width: auto;
    height: 70vh;
    max-width: 92vw;
    max-height: 70vh;
    object-fit: contain;
    justify-self: center;
    align-self: center;
    margin: 0 auto;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 40px;
    font-size: 50px;
    font-weight: 300;
    color: #fff;
    cursor: pointer;
    transition: color 0.3s ease;
    line-height: 1;
    user-select: none;
}

.lightbox-close:hover {
    color: #ccc;
}

.lightbox-caption {
    grid-row: 3;
    color: #fff;
    text-align: center;
    padding: 20px 40px;
    max-width: 800px;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-top: 20px;
}

.lightbox-thumbs {
    grid-row: 2;
    display: none;
    gap: 10px;
    max-width: min(90vw, 900px);
    overflow-x: auto;
    padding: 12px 10px 4px;
    margin-top: 12px;
}

.lightbox-thumb {
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: transparent;
    padding: 0;
    cursor: pointer;
    opacity: 0.75;
    flex: 0 0 auto;
}

.lightbox-thumb img {
    width: 60px;
    height: 60px;
    object-fit: contain;
    background: rgba(0, 0, 0, 0.35);
    display: block;
}

.lightbox-thumb:hover {
    opacity: 1;
}

.lightbox-thumb.is-active {
    border-color: #fff;
    opacity: 1;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    border: 0;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    display: none;
    z-index: 10000;
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Mobile adjustments for lightbox */
@media (max-width: 768px) {
    .lightbox-content {
        height: 62vh;
        max-width: 95vw;
        max-height: 62vh;
    }
    
    .lightbox-close {
        top: 10px;
        right: 20px;
        font-size: 40px;
    }
    
    .lightbox-caption {
        font-size: 0.85rem;
        padding: 15px 20px;
    }

    .lightbox-thumbs {
        gap: 8px;
        padding-top: 10px;
    }

    .lightbox-thumb img {
        width: 52px;
        height: 52px;
    }

    .lightbox-nav {
        width: 38px;
        height: 38px;
        font-size: 22px;
    }
}
