/*
 * galerias.css — parte 3 de 5
 * Tags populares, CTA del mapa, banner Tribu Colab, footer, modal de términos y botón de equipo
 *
 * Fragmento de la hoja original de la página de galerías. El ORDEN de
 * carga de estas partes reproduce el del archivo único y debe mantenerse:
 * cambiarlo altera la cascada. Ver el orden en public/galerias.html.
 */
/* ============================================
   TAGS POPULARES
   ============================================ */

.popular-tags-section {
    margin-top: 0;
}

/* Espacio superior solo en desktop */
@media (min-width: 769px) {
    .popular-tags-section {
        margin-top: 2.5rem;
    }
}

/* Contenedor con flechas de navegación */
.popular-tags-container {
    position: relative;
}

.popular-tags-scroll {
    display: flex;
    gap: 1.5rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 0.5rem 0 1rem 0;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE y Edge */
}

.popular-tags-scroll::-webkit-scrollbar {
    display: none; /* Chrome, Safari y Opera */
}

/* Flechas de navegación */
.tags-nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: none;
    align-items: center;
    justify-content: center;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(8px);
}

.tags-nav-arrow:hover {
    background: white;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
    transform: translateY(-50%) scale(1.1);
}

.tags-nav-arrow.visible {
    display: flex;
}

.tags-nav-arrow.tags-nav-left {
    left: -12px;
}

.tags-nav-arrow.tags-nav-right {
    right: -12px;
}

.tags-nav-arrow i {
    font-size: 1.5rem;
    color: #1f2937;
    font-weight: 600;
}

.tags-nav-arrow:active {
    transform: translateY(-50%) scale(1.05);
}

/* Tarjetas de tags */
.popular-tag-card {
    position: relative;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    flex: 0 0 300px;
    min-width: 300px;
}

.popular-tag-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.2);
}

/* ---- Esqueleto de carga ---- */
.popular-tag-skeleton {
    pointer-events: none;
    cursor: default;
}

.popular-tag-skeleton:hover {
    transform: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.popular-tag-skeleton .popular-tag-image {
    background: #eef0f4;
}

.popular-tag-skeleton .sk-line {
    border-radius: 6px;
    background: #eef0f4;
}

.sk-shimmer {
    position: relative;
    overflow: hidden;
}

.sk-shimmer::after {
    content: '';
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.65), transparent);
    animation: sk-shimmer 1.3s ease-in-out infinite;
}

@keyframes sk-shimmer {
    100% { transform: translateX(100%); }
}

@media (prefers-reduced-motion: reduce) {
    .sk-shimmer::after { animation: none; }
}

/* ---- Estado de error ---- */
.popular-tags-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 2.25rem 1rem;
    text-align: center;
    color: #6b7280;
}

.popular-tags-error i {
    font-size: 2rem;
    color: #9ca3af;
}

.popular-tags-error p {
    margin: 0;
    font-size: 0.9375rem;
}

.popular-tags-retry {
    margin-top: 0.5rem;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 1.1rem;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    background: #fff;
    color: #8b5cf6;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.popular-tags-retry:hover {
    border-color: #8b5cf6;
    background: #8b5cf6;
    color: #fff;
}

.popular-tag-image {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
}

.popular-tag-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.popular-tag-card:hover .popular-tag-image img {
    transform: scale(1.05);
}

.popular-tag-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.3));
}

.popular-tag-content {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.popular-tag-name {
    font-size: 1.0625rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
    line-height: 1.3;
}

.popular-tag-description {
    font-size: 0.8125rem;
    color: #6b7280;
    line-height: 1.4;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.popular-tag-count {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    color: #8b5cf6;
    font-weight: 500;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.popular-tag-count i {
    font-size: 1.1rem;
}

/* Tarjeta "Ver todas" */
.ver-todas-card {
    background: white;
    border: 2px solid #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.ver-todas-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(139, 92, 246, 0.2);
    border-color: #8b5cf6;
}

.ver-todas-content {
    text-align: center;
    color: #111827;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

.ver-todas-content i {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    display: block;
    color: #8b5cf6;
}

.ver-todas-content h3 {
    font-size: 1.625rem;
    font-weight: 800;
    margin: 0 0 0.5rem 0;
    letter-spacing: -0.02em;
    color: #111827;
}

.ver-todas-content p {
    font-size: 1.0625rem;
    margin: 0;
    font-weight: 500;
    color: #6b7280;
}

/* Responsive */
@media (max-width: 768px) {
    /* Ocultar flechas en mobile */
    .tags-nav-arrow {
        display: none !important;
    }

    .popular-tag-card {
        flex: 0 0 260px;
        min-width: 260px;
    }

    .popular-tag-image {
        height: 150px;
    }

    .popular-tag-content {
        padding: 0.875rem;
        gap: 0.25rem;
    }

    .popular-tag-name {
        font-size: 0.9375rem;
    }

    .popular-tag-description {
        font-size: 0.75rem;
    }

    .popular-tag-count {
        font-size: 0.8125rem;
        margin-top: 0.125rem;
    }

    .ver-todas-content {
        padding: 1.75rem;
    }

    .ver-todas-content i {
        font-size: 3rem;
    }

    .ver-todas-content h3 {
        font-size: 1.375rem;
    }

    .ver-todas-content p {
        font-size: 1rem;
    }
}


/* ============================================
   BLOQUE CTA MAPA DE FOTOS
   ============================================ */

.map-cta-section {
    padding: 2rem 0;
    background: transparent;
}

.map-cta-card {
    position: relative;
    background: linear-gradient(135deg, #8b5cf6 0%, #ec4899 100%);
    border-radius: 16px;
    padding: 1.75rem 2rem;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(139, 92, 246, 0.25);
}

.map-cta-content {
    position: relative;
    z-index: 1;
    color: white;
}

.map-cta-header {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    margin-bottom: 0.75rem;
}

.map-cta-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.map-cta-icon i {
    font-size: 1.5rem;
    color: white;
}

.map-cta-title {
    font-size: 1.375rem;
    font-weight: 700;
    margin: 0;
    color: white;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.map-cta-description {
    font-size: 0.9375rem;
    line-height: 1.5;
    margin: 0 0 1.25rem 0;
    color: rgba(255, 255, 255, 0.95);
    max-width: 700px;
}

.map-cta-button {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.75rem 1.5rem;
    background: white;
    color: #8b5cf6;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.map-cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
    background: #fef3c7;
}

.map-cta-button i:first-child {
    font-size: 1.25rem;
}

.map-cta-button i:last-child {
    font-size: 1.125rem;
    transition: transform 0.3s ease;
}

.map-cta-button:hover i:last-child {
    transform: translateX(4px);
}

.map-cta-decoration {
    position: absolute;
    right: -30px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 15px;
    opacity: 0.15;
    pointer-events: none;
}

.map-cta-circle {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 2px solid white;
}

/* Responsive */
@media (max-width: 1024px) {
    .map-cta-card {
        padding: 1.5rem 1.75rem;
    }
    
    .map-cta-title {
        font-size: 1.25rem;
    }
    
    .map-cta-description {
        font-size: 0.875rem;
    }
}

@media (max-width: 768px) {
    .map-cta-section {
        padding: 1.5rem 0;
    }
    
    .map-cta-card {
        padding: 1.5rem;
    }
    
    .map-cta-header {
        gap: 0.75rem;
        margin-bottom: 0.625rem;
    }
    
    .map-cta-icon {
        width: 40px;
        height: 40px;
        border-radius: 10px;
    }
    
    .map-cta-icon i {
        font-size: 1.25rem;
    }
    
    .map-cta-title {
        font-size: 1.125rem;
    }
    
    .map-cta-description {
        font-size: 0.875rem;
        margin-bottom: 1rem;
        line-height: 1.5;
    }
    
    .map-cta-button {
        width: 100%;
        justify-content: center;
        padding: 0.75rem 1.25rem;
        font-size: 0.9375rem;
    }
    
    .map-cta-decoration {
        display: none;
    }
}

/* ============================================
   BANNER TRIBU COLAB
   ============================================ */

.tribu-colab-banner-section {
    padding: 1.5rem 0 2.5rem 0;
    background: transparent;
}

.tribu-colab-banner {
    position: relative;
    background: linear-gradient(135deg, #1e1b4b 0%, #312e81 50%, #4c1d95 100%);
    border-radius: 20px;
    padding: 1.75rem 2rem;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(30, 27, 75, 0.35);
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 1.5rem;
    align-items: center;
}

.tribu-banner-content {
    position: relative;
    z-index: 2;
}

.tribu-banner-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.75rem;
}

.tribu-banner-icon {
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, #8b5cf6 0%, #ec4899 100%);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.4);
}

.tribu-banner-icon i {
    font-size: 1.625rem;
    color: white;
}

.tribu-banner-text {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.tribu-banner-title {
    font-size: 1.5rem;
    font-weight: 800;
    margin: 0;
    background: linear-gradient(90deg, #fff 0%, #c4b5fd 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.tribu-banner-subtitle {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
    font-weight: 500;
}

.tribu-banner-description {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
    margin: 0 0 1.25rem 0;
    max-width: 480px;
}

.tribu-banner-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.tribu-banner-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    border: none;
}

.tribu-banner-btn.primary {
    background: linear-gradient(135deg, #8b5cf6 0%, #a855f7 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.4);
    padding: 0.875rem 1.5rem;
    font-size: 1.0625rem;
}

.tribu-banner-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.5);
    background: linear-gradient(135deg, #7c3aed 0%, #9333ea 100%);
}

.tribu-banner-btn.secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1.5px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
}

.tribu-banner-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
}

.tribu-banner-btn i {
    font-size: 1.125rem;
}

.tribu-banner-btn.primary i {
    font-size: 1.25rem;
}

/* Preview de galerías */
.tribu-banner-preview {
    display: flex;
    gap: 0.75rem;
    position: relative;
    z-index: 2;
    align-self: stretch;
    align-items: center;
}

.tribu-preview-thumb {
    width: 115px;
    height: 115px;
    border-radius: 16px;
    overflow: hidden;
    border: 3px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.tribu-preview-thumb:hover {
    transform: scale(1.06);
    border-color: rgba(255, 255, 255, 0.7);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.tribu-preview-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Decoración */
.tribu-banner-decoration {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 40%;
    pointer-events: none;
    overflow: hidden;
}

.tribu-deco-circle {
    position: absolute;
    border-radius: 50%;
    border: 2px solid rgba(139, 92, 246, 0.2);
}

.tribu-deco-circle:first-child {
    width: 200px;
    height: 200px;
    right: -60px;
    top: -40px;
}

.tribu-deco-circle:nth-child(2) {
    width: 150px;
    height: 150px;
    right: 40px;
    bottom: -50px;
    border-color: rgba(236, 72, 153, 0.15);
}

.tribu-deco-dots {
    position: absolute;
    right: 80px;
    top: 50%;
    transform: translateY(-50%);
    width: 60px;
    height: 60px;
    background-image: radial-gradient(rgba(255, 255, 255, 0.15) 2px, transparent 2px);
    background-size: 12px 12px;
}

/* Responsive */
@media (max-width: 900px) {
    .tribu-colab-banner {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
    
    .tribu-banner-preview {
        justify-content: flex-start;
    }
}

@media (max-width: 768px) {
    .tribu-colab-banner-section {
        padding: 1rem 0 2rem 0;
    }
    
    .tribu-colab-banner {
        padding: 1.5rem;
        border-radius: 16px;
    }
    
    .tribu-banner-header {
        gap: 0.75rem;
        margin-bottom: 0.5rem;
    }
    
    .tribu-banner-icon {
        width: 44px;
        height: 44px;
        border-radius: 12px;
    }
    
    .tribu-banner-icon i {
        font-size: 1.375rem;
    }
    
    .tribu-banner-title {
        font-size: 1.25rem;
    }
    
    .tribu-banner-subtitle {
        font-size: 0.8125rem;
    }
    
    .tribu-banner-description {
        font-size: 0.875rem;
        margin-bottom: 1rem;
        line-height: 1.5;
    }
    
    .tribu-banner-actions {
        flex-direction: row;
        gap: 0.5rem;
    }
    
    .tribu-banner-btn {
        flex: 1;
        justify-content: center;
        padding: 0.625rem 0.75rem;
        font-size: 0.8125rem;
        border-radius: 10px;
    }
    
    .tribu-banner-btn.primary {
        padding: 0.75rem 0.875rem;
        font-size: 0.875rem;
    }
    
    .tribu-banner-btn.secondary {
        padding: 0.5rem 0.625rem;
        font-size: 0.75rem;
    }
    
    .tribu-banner-btn i {
        font-size: 1rem;
    }
    
    .tribu-banner-btn.primary i {
        font-size: 1.125rem;
    }
    
    .tribu-banner-preview {
        gap: 0.375rem;
    }
    
    .tribu-preview-thumb {
        width: 60px;
        height: 60px;
        border-radius: 10px;
    }
    
    .tribu-banner-decoration {
        display: none;
    }
}

@media (max-width: 480px) {
    .tribu-banner-preview {
        display: none;
    }
    
    .tribu-banner-btn {
        padding: 0.5rem 0.625rem;
        font-size: 0.75rem;
        gap: 0.375rem;
    }
    
    .tribu-banner-btn.primary {
        padding: 0.625rem 0.75rem;
        font-size: 0.8125rem;
    }
    
    .tribu-banner-btn.secondary {
        padding: 0.5rem 0.625rem;
        font-size: 0.6875rem;
    }
    
    .tribu-banner-btn i {
        font-size: 0.875rem;
    }
    
    .tribu-banner-btn.primary i {
        font-size: 1rem;
    }
}

/* ========================================
   FOOTER
======================================== */
.page-footer {
    background: #f9fafb;
    border-top: 1px solid #e5e7eb;
    padding: 0.875rem 1rem;
    margin-top: 1rem;
    margin-bottom: 0; /* Sin espacio extra después del footer */
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    align-items: center;
}

.footer-copyright {
    font-size: 0.8125rem;
    color: #6b7280;
    margin: 0;
    line-height: 1.4;
}

.footer-link {
    background: none;
    border: none;
    color: #6b7280;
    font-size: 0.875rem;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    transition: all 0.2s ease;
    text-decoration: none;
}

.footer-link:hover {
    color: #4b5563;
    text-decoration: underline;
}

/* ========================================
   MODAL DE TÉRMINOS Y CONDICIONES
======================================== */
.terms-modal-overlay {
    position: fixed;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.terms-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.terms-modal {
    background: white;
    border-radius: 16px;
    max-width: 800px;
    width: 100%;
    max-height: 75vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9);
    transition: transform 0.3s ease;
    margin: auto !important;
    position: relative !important;
}

.terms-modal-overlay.active .terms-modal {
    transform: scale(1);
}

.terms-modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}

.terms-modal-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111827;
    margin: 0;
}

.terms-modal-close {
    background: #f3f4f6;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #6b7280;
    font-size: 1.25rem;
}

.terms-modal-close:hover {
    background: #e5e7eb;
    color: #111827;
}

.terms-modal-body {
    padding: 1.5rem;
    overflow-y: auto;
    flex: 1;
}

.terms-subtitle {
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
}

.terms-update {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1.5rem;
    font-style: italic;
}

.terms-section {
    margin-bottom: 2rem;
}

.terms-section h3 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #8b5cf6;
    margin-bottom: 0.75rem;
}

.terms-section h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.terms-section p {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: #4b5563;
    margin-bottom: 0.75rem;
}

.terms-section ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0.75rem;
}

.terms-section ul li {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: #4b5563;
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.5rem;
}

.terms-section ul li::before {
    content: "•";
    position: absolute;
    left: 0.5rem;
    color: #8b5cf6;
    font-weight: bold;
}

.contact-list li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.contact-list li i {
    color: #8b5cf6;
    font-size: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    /* Deshabilitar selección de texto en mobile */
    .galerias-page-body {
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
        -webkit-touch-callout: none;
    }

    .page-footer {
        padding: 0.5rem 1rem 55px 1rem; /* Reducido al mínimo */
        margin-top: 0.5rem;
        margin-bottom: 0;
    }

    .footer-copyright {
        font-size: 0.75rem;
    }

    .footer-link {
        font-size: 0.8125rem;
    }

    .terms-modal {
        max-height: 80vh;
        border-radius: 12px;
    }

    .terms-modal-header {
        padding: 1rem;
    }

    .terms-modal-header h2 {
        font-size: 1.25rem;
    }

    .terms-modal-body {
        padding: 1rem;
    }

    .terms-section h3 {
        font-size: 1rem;
    }

    .terms-section h4 {
        font-size: 0.9375rem;
    }

    .terms-section p,
    .terms-section ul li {
        font-size: 0.875rem;
    }
}

@media (max-width: 480px) {
    .terms-modal-overlay {
        padding: 0.5rem;
    }

    .terms-modal {
        border-radius: 8px;
    }
}

/* ========================================
   BOTÓN ÚNETE AL EQUIPO (PEQUEÑO)
======================================== */
.unete-equipo-button-small {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.875rem;
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
    color: white;
    border-radius: 8px;
    font-size: 0.8125rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.25);
    margin: 0.5rem 0 0 0;
}

.unete-equipo-button-small:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.35);
}

.unete-equipo-button-small:active {
    transform: translateY(0);
}

.unete-equipo-button-small i:first-child {
    font-size: 1rem;
}

.unete-equipo-button-small i:last-child {
    font-size: 0.875rem;
    transition: transform 0.3s ease;
}

.unete-equipo-button-small:hover i:last-child {
    transform: translateX(2px);
}

@media (max-width: 768px) {
    .unete-equipo-button-small {
        font-size: 0.75rem;
        padding: 0.4375rem 0.75rem;
        gap: 0.375rem;
    }
    
    .unete-equipo-button-small i:first-child {
        font-size: 0.875rem;
    }
    
    .unete-equipo-button-small i:last-child {
        font-size: 0.75rem;
    }
}

/* Categorías en bloques mixtos */
.categoria-en-bloque {
    flex: 0 0 auto;
    min-width: 0;
}

.galerias-grid .categoria-en-bloque {
    width: 100%;
}

.popular-tag-placeholder {
    background: linear-gradient(135deg, #f5f3ff 0%, #fce7f3 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.popular-tag-placeholder i {
    font-size: 3rem;
    color: #ec4899;
    opacity: 0.5;
}

/* Participante dentro de un bloque.
   Es un <div> y no un <a> porque un participante no tiene página propia: se abre
   en el modal de sus fotos. Al no ser enlace hay que devolverle a mano el cursor
   y el anillo de foco que el navegador sí da a los <a>. */
.participante-en-bloque {
    cursor: pointer;
}

.participante-en-bloque:focus-visible {
    outline: 2px solid #8b5cf6;
    outline-offset: 2px;
}

/* Retratos: en una persona o un participante lo que importa es la cara, así que
   la miniatura se encuadra arriba en vez de al centro, donde recorta la frente. */
.participante-en-bloque .popular-tag-image img,
.persona-en-bloque .popular-tag-image img {
    object-position: center 25%;
}

.participante-en-bloque .popular-tag-placeholder i,
.persona-en-bloque .popular-tag-placeholder i {
    color: #8b5cf6;
}

/* Ajustes para grid clásico con categorías */
.grid-clasico .categoria-en-bloque {
    display: flex;
    flex-direction: column;
}

/* Ajustes para mosaico con categorías */
.mosaico-pinterest .categoria-en-bloque {
    display: flex;
    flex-direction: column;
}

/* CHECKBOX PARA PERMITIR DESCARGAS */
.permiso-option-checkbox {
    display: flex;
    align-items: flex-start;
    padding: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
}

.permiso-option-checkbox:hover {
    border-color: #8b5cf6;
    background: #f5f3ff;
}

.permiso-option-checkbox.active {
    border-color: #8b5cf6;
    background: #f5f3ff;
}

.permiso-option-checkbox input[type="checkbox"] {
    margin-right: 1rem;
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: #8b5cf6;
    flex-shrink: 0;
}

.permiso-option-checkbox .permiso-content {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.permiso-option-checkbox .permiso-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.permiso-option-checkbox .permiso-info {
    flex: 1;
}

.permiso-option-checkbox .permiso-title {
    display: block;
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.25rem;
}

.permiso-option-checkbox .permiso-description {
    display: block;
    font-size: 0.875rem;
    color: #6b7280;
}
