/**
 * ART FOR SALE - Regras de Responsividade (CSS3)
 * Adaptação para Desktop, Laptop, Tablet e Mobile
 * Mantendo total consistência visual e proporções elegantes
 */

/* ==========================================================
   Telas Médias / Laptops Pequenos (max-width: 1200px)
   ========================================================== */
@media (max-width: 1200px) {
    .section-container,
    .header-container,
    .hero-container,
    .about-container,
    .team-banner-container,
    .footer-container,
    .footer-bottom-container {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }

    .hero-title {
        font-size: 3.4rem;
    }

    .categories-grid {
        gap: 0.85rem;
    }

    .category-name {
        font-size: 0.72rem;
    }

    .featured-carousel-track {
        gap: 1.15rem;
    }

    .footer-container {
        grid-template-columns: 1.35fr 0.8fr 1.5fr 1.15fr;
        padding: 55px 24px 45px;
    }

    .footer-col {
        padding: 0 1.5rem;
    }

    .footer-sculpture-wrap {
        width: 320px;
        opacity: 0.55;
    }

    /* Detalhe da Obra (1200px) */
    .obra-layout-grid {
        gap: 2.5rem;
    }

    .obra-page-title {
        font-size: 2.75rem;
    }
}

/* ==========================================================
   Tablets em Paisagem / Notebooks (max-width: 992px)
   ========================================================== */
@media (max-width: 992px) {
    /* Header & Navegação */
    .header-nav {
        display: none;
    }

    .mobile-toggle-btn {
        display: flex;
    }

    .btn-consultar-obra {
        display: none;
    }

    /* Hero */
    .hero-section {
        height: auto;
        min-height: 560px;
        padding: 4.5rem 0 3.5rem;
    }

    .hero-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 3rem;
    }

    .hero-content {
        max-width: 100%;
    }

    .hero-title {
        font-size: 3.1rem;
    }

    .hero-quote-box {
        margin-left: 0;
        max-width: 100%;
        padding-top: 1.5rem;
        border-top: 1px solid rgba(255, 255, 255, 0.15);
    }

    /* Categorias: 4 por linha no Tablet */
    .categories-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.25rem;
    }

    .category-name {
        font-size: 0.8125rem;
    }

    /* Obras em Destaque: 2 por página no Tablet */
    .featured-carousel-track .artwork-card {
        flex: 0 0 calc(50% - 0.75rem);
        min-width: 240px;
    }

    /* Catálogo de Obras: 2 por linha no Tablet */
    .catalogo-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    .catalogo-title {
        font-size: 2.75rem;
    }

    .carousel-arrow.prev {
        left: -12px;
    }

    .carousel-arrow.next {
        right: -12px;
    }

    /* Seção Sobre */
    .about-container {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .about-image-wrapper {
        aspect-ratio: 1.7 / 1;
    }

    .differentials-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    /* Seção Equipe */
    .team-banner-container {
        grid-template-columns: 1fr;
        gap: 2.25rem;
    }

    .team-intro-col {
        max-width: 100%;
    }

    .team-cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .team-card-email {
        grid-column: span 2;
    }

    /* Rodapé */
    .footer-container {
        grid-template-columns: 1.2fr 0.8fr;
        row-gap: 3rem;
        column-gap: 2rem;
        padding: 50px 24px 40px;
    }

    .footer-col {
        padding: 0 1.25rem;
    }

    .footer-col-brand {
        padding-left: 0;
    }

    .footer-col-cats {
        border-left: none;
        padding-left: 0;
    }

    .footer-col-contact {
        border-left: 1px solid rgba(185, 138, 69, 0.18);
    }

    .footer-sculpture-wrap {
        width: 240px;
        opacity: 0.35;
    }

    .footer-bottom-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 1.25rem;
    }

    .footer-bottom-left,
    .footer-bottom-right {
        justify-content: center;
    }

    /* Detalhe da Obra (992px) */
    .obra-layout-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .obra-gallery-col {
        position: static;
    }

    .obra-page-title {
        font-size: 2.5rem;
    }

    .obra-stage-inner {
        aspect-ratio: 1.45 / 1;
    }
}

/* ==========================================================
   Tablets em Retrato / Celulares Grandes (max-width: 768px)
   ========================================================== */
@media (max-width: 768px) {
    .section-title {
        font-size: 1.85rem;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .section-link-all {
        align-self: flex-start;
    }

    /* Hero */
    .hero-title {
        font-size: 2.65rem;
    }

    .hero-description {
        font-size: 0.875rem;
    }

    .hero-cta-group {
        flex-direction: column;
        align-items: stretch;
        gap: 0.85rem;
    }

    .btn-primary,
    .btn-outline-light {
        width: 100%;
    }

    /* Equipe */
    .team-cards-grid {
        grid-template-columns: 1fr;
    }

    .team-card-email {
        grid-column: span 1;
    }

    /* Rodapé */
    .footer-container {
        grid-template-columns: 1fr;
        gap: 2.75rem;
        padding: 45px 1.25rem 35px;
    }

    .footer-col {
        padding: 0 !important;
        border-left: none !important;
    }

    .footer-sculpture-wrap {
        display: none;
    }

    .footer-cats-columns {
        gap: 1.5rem;
    }

    .footer-bottom {
        padding: 1.25rem 0;
    }

    .footer-bottom-container {
        display: flex;
        flex-direction: column;
        gap: 1.15rem;
        text-align: center;
        padding: 0 1.25rem;
    }

    .footer-bottom-left {
        justify-content: center;
    }

    .footer-bottom-center {
        order: 2;
    }

    .footer-bottom-right {
        order: 3;
        flex-direction: column;
        gap: 0.85rem;
        justify-content: center;
    }

    .footer-legal-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.6rem;
    }

    /* Catálogo de Obras (max-width: 768px) */
    .catalogo-header-section {
        padding: 2.25rem 0;
    }

    .catalogo-title {
        font-size: 2.45rem;
    }

    .catalogo-search-wrapper {
        max-width: 100%;
    }

    .catalogo-meta-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .catalogo-sort-box {
        width: 100%;
        justify-content: space-between;
    }

    /* Modal de Consulta / Atendimento (768px) */
    .inquiry-modal-backdrop {
        padding: 1.25rem;
        align-items: center;
        justify-content: center;
    }

    .inquiry-modal-content {
        width: 100%;
        max-width: min(500px, calc(100vw - 2.5rem));
        margin: auto;
        padding: 2rem 1.5rem;
        max-height: calc(100dvh - 2.5rem);
    }

    /* Detalhe da Obra (768px) */
    .obra-breadcrumb-bar {
        padding: 0.85rem 0;
    }

    .obra-main-section {
        padding-top: 1.5rem;
    }

    .obra-page-title {
        font-size: 2.25rem;
    }

    .obra-specs-grid {
        grid-template-columns: 1fr 1fr;
        padding: 1.25rem;
        gap: 0.75rem 1.25rem;
    }

    .obra-inquiry-action-card {
        padding: 1.75rem 1.5rem;
    }

    .inquiry-card-price {
        font-size: 1.95rem;
    }

    .zoom-modal-toolbar {
        padding: 0.85rem 1rem;
    }

    .zoom-artwork-artist {
        display: none;
    }
}

/* ==========================================================
   Celulares Pequenos (max-width: 576px)
   ========================================================== */
@media (max-width: 576px) {
    .section-container,
    .header-container,
    .hero-container,
    .about-container,
    .team-banner-container,
    .footer-container,
    .footer-bottom-container {
        padding-left: 1.15rem;
        padding-right: 1.15rem;
    }

    .logo-image {
        height: 38px;
    }

    .header-actions {
        gap: 0.65rem;
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .hero-eyebrow {
        font-size: 0.6875rem;
    }

    /* Categorias: 2 colunas no celular */
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.85rem;
    }

    /* Obras em Destaque: 1 card por visualização no celular com swipe */
    .featured-carousel-track .artwork-card {
        flex: 0 0 calc(90% - 0.5rem);
        min-width: 240px;
    }

    .carousel-arrow {
        display: none; /* Em celular navega pelos dots e swipe */
    }

    /* Diferenciais Sobre */
    .differentials-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .about-title {
        font-size: 2.25rem;
    }

    .team-title {
        font-size: 1.85rem;
    }

    .search-modal {
        padding: 1.5rem 1.15rem;
    }

    /* Modal de Atendimento / Tenho Interesse no Celular (576px) */
    .inquiry-modal-backdrop {
        padding: 0.75rem;
        align-items: center;
        justify-content: center;
    }

    .inquiry-modal-content {
        width: 100% !important;
        max-width: calc(100vw - 1.5rem) !important;
        margin: auto !important;
        padding: 1.65rem 1.1rem !important;
        border-radius: var(--radius-md);
        box-sizing: border-box !important;
        max-height: calc(100dvh - 1.5rem);
        overflow-y: auto;
    }

    .inquiry-modal-close {
        top: 0.75rem;
        right: 0.75rem;
        width: 32px;
        height: 32px;
        font-size: 1.1rem;
    }

    .inquiry-modal-header {
        margin-bottom: 1.15rem;
        padding-right: 2rem;
    }

    .modal-eyebrow {
        font-size: 0.625rem;
        letter-spacing: 0.18em;
    }

    .modal-title {
        font-size: 1.35rem;
        line-height: 1.25;
        word-break: break-word;
    }

    .modal-subtitle {
        font-size: 0.75rem;
        line-height: 1.4;
        word-break: break-word;
    }

    .inquiry-preview-box {
        padding: 0.65rem;
        gap: 0.75rem;
        margin-bottom: 1rem;
        min-width: 0;
    }

    .inquiry-preview-img {
        width: 60px;
        height: 48px;
        flex-shrink: 0;
    }

    .inquiry-preview-meta {
        min-width: 0;
        overflow: hidden;
    }

    .inquiry-meta-title {
        font-size: 0.8125rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .inquiry-meta-artist,
    .inquiry-meta-dim {
        font-size: 0.6875rem;
    }

    .inquiry-meta-price {
        font-size: 0.6875rem;
    }

    .inquiry-instruction {
        font-size: 0.75rem;
        margin-bottom: 0.85rem;
        line-height: 1.4;
    }

    .inquiry-options-grid {
        gap: 0.65rem;
    }

    .inquiry-channel-btn {
        padding: 0.75rem 0.95rem;
        min-width: 0;
        box-sizing: border-box;
    }

    .channel-info {
        min-width: 0;
        overflow: hidden;
    }

    .channel-info strong {
        font-size: 0.8125rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .channel-info span {
        font-size: 0.6875rem;
        word-break: break-all;
    }

    /* Catálogo de Obras: 1 por linha no Celular */
    .catalogo-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .catalogo-filters-scroll {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 0.5rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .catalogo-filters-scroll::-webkit-scrollbar {
        display: none;
    }

    .catalogo-title {
        font-size: 2.15rem;
    }

    .catalogo-description {
        font-size: 0.9375rem;
    }

    .catalogo-search-input {
        font-size: 0.875rem;
        padding: 0.75rem 0.5rem;
    }

    .catalogo-meta-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 0.85rem;
    }

    .catalogo-sort-box {
        justify-content: space-between;
    }

    .sort-select-wrapper,
    .catalogo-sort-select {
        width: 100%;
    }

    .catalogo-pagination {
        gap: 0.3rem;
    }

    .page-btn {
        min-width: 36px;
        height: 36px;
        font-size: 0.8125rem;
        padding: 0 0.45rem;
    }

    .page-arrow {
        padding: 0 0.55rem;
    }

    .state-title {
        font-size: 1.65rem;
    }

    .state-description {
        font-size: 0.875rem;
    }

    .state-buttons-row {
        flex-direction: column;
        width: 100%;
    }

    .btn-state-reset,
    .btn-state-outline {
        width: 100%;
    }

    /* ==========================================================
       Detalhe da Obra no Celular (max-width: 576px)
       Ordem estrita requerida:
       1. Imagem
       2. Miniaturas
       3. Informações
       4. Preço sob consulta
       5. Botão de interesse
       ========================================================== */
    .obra-layout-grid {
        display: flex;
        flex-direction: column;
        gap: 2rem;
    }

    .obra-gallery-col {
        display: flex;
        flex-direction: column;
        width: 100%;
        position: static;
    }

    /* 1. Imagem principal */
    .obra-stage-wrapper {
        order: 1;
        width: 100%;
        border-radius: var(--radius-sm);
    }

    .obra-stage-inner {
        aspect-ratio: 1.25 / 1;
    }

    .gallery-nav-arrow {
        width: 38px;
        height: 38px;
    }

    .gallery-nav-arrow.gallery-prev {
        left: 8px;
    }

    .gallery-nav-arrow.gallery-next {
        right: 8px;
    }

    .gallery-caption-badge {
        bottom: 8px;
        left: 8px;
        font-size: 0.7rem;
        padding: 0.3rem 0.65rem;
    }

    .btn-zoom-trigger {
        top: 8px;
        right: 8px;
        padding: 0.35rem 0.75rem;
        font-size: 0.7rem;
    }

    /* 2. Miniaturas */
    .obra-thumbnails-wrapper {
        order: 2;
        margin-top: 0.85rem;
    }

    .obra-thumbnails-track {
        gap: 0.5rem;
    }

    .thumb-img-wrapper {
        aspect-ratio: 1.25 / 1;
    }

    .thumb-label {
        font-size: 0.625rem;
        display: -webkit-box;
        -webkit-line-clamp: 1;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .obra-assurance-box {
        order: 3;
        margin-top: 1rem;
        padding: 0.85rem 1rem;
        gap: 0.5rem;
    }

    .assurance-item {
        font-size: 0.75rem;
    }

    /* Coluna de Informações */
    .obra-info-col {
        display: flex;
        flex-direction: column;
        width: 100%;
    }

    /* 3. Informações (Header, Sobre, Ficha Técnica) */
    .obra-header {
        order: 1;
        margin-bottom: 0.85rem;
    }

    .obra-type-row {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .obra-page-title {
        font-size: 2rem;
        line-height: 1.15;
    }

    .obra-page-artist {
        font-size: 0.95rem;
    }

    .obra-divider {
        order: 2;
        margin: 1rem 0;
    }

    .obra-description-block {
        order: 3;
        margin-bottom: 1.25rem;
    }

    .obra-description-text {
        font-size: 0.875rem;
        line-height: 1.65;
    }

    .obra-specs-block {
        order: 4;
        margin: 1rem 0 1.25rem;
    }

    .obra-specs-grid {
        grid-template-columns: 1fr;
        padding: 1.15rem;
        gap: 0.65rem;
    }

    .spec-item {
        flex-direction: row;
        justify-content: space-between;
        align-items: baseline;
        padding-bottom: 0.5rem;
    }

    .spec-label {
        margin-bottom: 0;
    }

    /* 4 e 5. Card: Preço sob consulta (4) e Botão de interesse (5) */
    .obra-inquiry-action-card {
        order: 5;
        padding: 1.5rem 1.25rem;
        margin-top: 0.5rem;
    }

    .inquiry-card-price {
        font-size: 1.75rem;
    }

    .inquiry-card-subtext {
        font-size: 0.8125rem;
        margin-bottom: 1.25rem;
    }

    .btn-primary-interest {
        padding: 0.95rem 1.25rem;
        font-size: 0.8125rem;
    }

    /* Lightbox Zoom no Celular */
    .zoom-modal-toolbar {
        padding: 0.75rem 1rem;
    }

    .zoom-artwork-name {
        font-size: 1.05rem;
    }

    .zoom-view-caption {
        display: none;
    }

    .zoom-arrow {
        width: 38px;
        height: 38px;
    }

    .zoom-arrow.zoom-prev {
        left: 8px;
    }

    .zoom-arrow.zoom-next {
        right: 8px;
    }

    .zoom-thumbs-row {
        gap: 0.4rem;
    }

    .zoom-thumb-btn {
        width: 44px;
        height: 34px;
    }

    .zoom-help-hint {
        font-size: 0.6875rem;
        text-align: center;
    }
}

/* ==========================================================
   Smartphones Médios e Compactos (max-width: 414px)
   Cobre: 390px (iPhone 12-15), 375px (iPhone SE/X), 414px (Plus/Max)
   ========================================================== */
@media (max-width: 414px) {
    .section-container,
    .header-container,
    .hero-container,
    .about-container,
    .team-banner-container,
    .footer-container,
    .footer-bottom-container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .hero-title {
        font-size: 2.15rem;
        line-height: 1.12;
    }

    /* Categorias: 2 colunas proporcionais com alinhamento impecável */
    .categories-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.75rem;
    }

    .category-thumb-wrapper {
        aspect-ratio: 1.5 / 1;
    }

    .category-name {
        font-size: 0.75rem;
        min-height: 2.4em;
    }

    /* Pinceladas discretas em telas menores */
    .artistic-flank-decor.flank-left {
        width: 160px;
        opacity: 0.35;
        top: 440px;
    }

    .artistic-flank-decor.flank-right {
        width: 170px;
        opacity: 0.35;
        top: 480px;
    }

    /* Botão Tenho interesse nesta obra: ultra destacado */
    .btn-primary-interest {
        min-height: 52px;
        padding: 1.05rem 1.25rem;
        font-size: 0.8125rem;
        font-weight: 700;
        letter-spacing: 0.07em;
        background: linear-gradient(135deg, #caa267 0%, #b38a54 50%, #9c7543 100%);
        box-shadow: 0 6px 22px rgba(179, 138, 84, 0.42);
        border-radius: 4px;
    }
}

/* ==========================================================
   Smartphones Ultra Compactos (max-width: 360px)
   Cobre: 320px e 360px (Samsung Galaxy compactos, telas estreitas)
   ========================================================== */
@media (max-width: 360px) {
    .section-container,
    .header-container,
    .hero-container,
    .about-container,
    .team-banner-container,
    .footer-container,
    .footer-bottom-container {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }

    .header-logo img {
        height: 34px;
        width: auto;
    }

    .hero-title {
        font-size: 1.85rem;
    }

    .categories-grid {
        gap: 0.55rem;
    }

    .category-name {
        font-size: 0.6875rem;
        min-height: 2.3em;
    }

    .featured-carousel-track .artwork-card {
        min-width: 220px;
    }

    .btn-primary-interest {
        font-size: 0.75rem;
        padding: 0.95rem 0.75rem;
        letter-spacing: 0.04em;
        min-height: 48px;
    }

    .obra-page-title {
        font-size: 1.75rem;
    }

    /* Modal de Atendimento em Telas Ultra Estreitas (360px) */
    .inquiry-modal-backdrop {
        padding: 0.5rem;
    }

    .inquiry-modal-content {
        max-width: calc(100vw - 1rem) !important;
        padding: 1.35rem 0.85rem !important;
    }

    .modal-title {
        font-size: 1.2rem;
    }

    .inquiry-channel-btn {
        padding: 0.65rem 0.75rem;
    }
}

